/* mores.dev - Phosphor Green Terminal Theme */
/* Palette: #0A0A0A (black), #33FF33 (green), #1A8A1A (dim), #80FF80 (bright), #FFA020 (amber) */

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background: #0A0A0A;
    color: #33FF33;
    font-family: 'Fira Code', monospace;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
    box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.6);
}

/* CRT Scanline Overlay */
#crt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.15) 2px,
        rgba(0, 0, 0, 0.15) 4px
    );
    pointer-events: none;
    z-index: 9999;
}

/* CRT Screen Flicker */
@keyframes flicker {
    0% { opacity: 0.97; }
    5% { opacity: 0.95; }
    10% { opacity: 0.98; }
    15% { opacity: 0.96; }
    20% { opacity: 0.99; }
    100% { opacity: 0.98; }
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        ellipse at center,
        transparent 60%,
        rgba(0, 0, 0, 0.8) 100%
    );
    pointer-events: none;
    z-index: 9998;
}

/* Terminal Column */
.terminal-col {
    max-width: 640px;
    margin: 0 auto;
    padding: 20px;
}

/* Boot Screen */
#boot-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

#boot-screen .terminal-col {
    width: 100%;
}

#boot-messages {
    margin-bottom: 24px;
}

#boot-messages .boot-line {
    color: #1A8A1A;
    margin-bottom: 4px;
    opacity: 0;
    transition: opacity 0.1s;
}

#boot-messages .boot-line.visible {
    opacity: 1;
}

/* ASCII Logo */
#ascii-logo {
    color: #33FF33;
    font-size: 12px;
    line-height: 1.2;
    margin-bottom: 24px;
    white-space: pre;
    text-shadow: 0 0 8px rgba(51, 255, 51, 0.4);
}

/* Cursor Prompt */
#cursor-prompt {
    display: flex;
    align-items: center;
}

.prompt-symbol {
    color: #FFA020;
    font-weight: 700;
}

/* Blinking Cursor */
.cursor-blink {
    color: #FFA020;
    animation: blink 0.8s step-end infinite;
    font-weight: 700;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

/* Navigation Section */
#nav-section {
    padding: 40px 0;
    border-top: 1px solid #1A8A1A;
    border-bottom: 1px solid #1A8A1A;
}

#command-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 16px;
}

.nav-command {
    color: #33FF33;
    text-decoration: none;
    padding: 4px 0;
    display: inline-block;
    transition: color 0.15s, text-shadow 0.15s;
}

.nav-command:hover {
    color: #80FF80;
    text-shadow: 0 0 10px rgba(128, 255, 128, 0.5);
}

.nav-command:hover .prompt-symbol {
    color: #FFA020;
    text-shadow: 0 0 10px rgba(255, 160, 32, 0.5);
}

/* Section Header */
.section-header {
    color: #80FF80;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 0 6px rgba(128, 255, 128, 0.3);
}

/* Terminal Sections */
.terminal-section {
    padding: 60px 0;
    border-bottom: 1px solid #1A8A1A;
}

/* Typewriter Blocks */
.typewriter-block {
    opacity: 0;
    transition: opacity 0.3s;
}

.typewriter-block.revealed {
    opacity: 1;
}

/* ASCII Art */
.ascii-art {
    color: #33FF33;
    font-size: 12px;
    line-height: 1.2;
    margin-bottom: 16px;
    white-space: pre;
    overflow-x: auto;
}

/* Terminal Text */
.terminal-text {
    margin-bottom: 4px;
    color: #33FF33;
}

.terminal-text.dim-text {
    color: #1A8A1A;
}

/* Contact Section */
#contact-prompt {
    display: flex;
    align-items: center;
}

.contact-input {
    color: #33FF33;
}

/* Footer */
#footer-section {
    padding: 40px 0;
}

.footer-line {
    color: #1A8A1A;
    margin: 8px 0;
}

/* Typewriter character animation */
.typewriter-char {
    opacity: 0;
    transition: opacity 0.02s;
}

.typewriter-char.visible {
    opacity: 1;
}

/* Phosphor glow effect on key elements */
#ascii-logo,
.ascii-art {
    text-shadow: 0 0 5px rgba(51, 255, 51, 0.3);
}

.section-header {
    position: relative;
}

.section-header::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, #1A8A1A, transparent);
}

/* Boot sequence animation classes */
.boot-line {
    font-size: 14px;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #0A0A0A;
}

::-webkit-scrollbar-thumb {
    background: #1A8A1A;
    border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
    background: #33FF33;
}

/* Selection color */
::selection {
    background: #1A8A1A;
    color: #80FF80;
}

/* Link resets */
a {
    color: inherit;
    text-decoration: none;
}

/* Responsive - maintain terminal feel on smaller screens */
@media (max-width: 680px) {
    .terminal-col {
        padding: 16px;
    }

    .ascii-art {
        font-size: 10px;
    }

    #ascii-logo {
        font-size: 8px;
    }
}

/* CRT power-on effect */
@keyframes crt-on {
    0% {
        transform: scaleY(0.005) scaleX(0.3);
        filter: brightness(30);
    }
    10% {
        transform: scaleY(0.005) scaleX(0.3);
        filter: brightness(30);
    }
    20% {
        transform: scaleY(1) scaleX(1);
        filter: brightness(1.5);
    }
    70% {
        transform: scaleY(1) scaleX(1);
        filter: brightness(1.5);
    }
    100% {
        transform: scaleY(1) scaleX(1);
        filter: brightness(1);
    }
}

#boot-screen {
    animation: crt-on 0.8s ease-out;
}

/* Text glow pulse for active elements */
@keyframes glow-pulse {
    0%, 100% {
        text-shadow: 0 0 5px rgba(51, 255, 51, 0.3);
    }
    50% {
        text-shadow: 0 0 15px rgba(51, 255, 51, 0.6), 0 0 30px rgba(51, 255, 51, 0.2);
    }
}

#cursor-prompt,
#contact-prompt {
    animation: glow-pulse 3s ease-in-out infinite;
}
