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

:root {
    --black: #000000;
    --dark: #0A0A0A;
    --pink: #FF10F0;
    --cyan: #00FFFF;
    --white: #FFFFFF;
    --gray: #888888;
    --gray-light: #B0B0B0;
    --purple-gray: #7B6B8B;
}

html, body {
    height: 100%;
    overflow: hidden;
    background: var(--black);
    color: var(--white);
    font-family: 'Inter', sans-serif;
    cursor: crosshair;
}

/* ── CRT Effects ── */
.crt-vignette {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 100;
    background: radial-gradient(ellipse at center, transparent 50%, rgba(0,0,0,0.75) 100%);
}

.scanlines {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 99;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.12) 2px,
        rgba(0, 0, 0, 0.12) 4px
    );
}

.scanline-sweep {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255, 16, 240, 0.06);
    z-index: 101;
    pointer-events: none;
    animation: sweep 7s linear infinite;
}

@keyframes sweep {
    0% { top: -3px; }
    100% { top: 100%; }
}

/* ── Synthwave Grid ── */
.grid-container {
    position: fixed;
    bottom: -15%;
    left: -60%;
    width: 220%;
    height: 75%;
    z-index: 1;
    overflow: hidden;
}

.grid-floor {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(transparent 93%, rgba(255,16,240,0.1) 93%, rgba(255,16,240,0.1) 100%),
        linear-gradient(90deg, transparent 93%, rgba(255,16,240,0.1) 93%, rgba(255,16,240,0.1) 100%);
    background-size: 80px 80px;
    transform: perspective(400px) rotateX(65deg);
    transform-origin: center top;
    mask-image: linear-gradient(to bottom, transparent 0%, black 25%, black 70%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 25%, black 70%, transparent 100%);
    animation: gridScroll 2.5s linear infinite;
}

@keyframes gridScroll {
    0% { background-position: 0 0; }
    100% { background-position: 0 80px; }
}

.horizon-glow {
    position: fixed;
    bottom: 22%;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, var(--pink) 50%, transparent 95%);
    opacity: 0.35;
    z-index: 2;
    box-shadow: 0 0 40px var(--pink), 0 0 80px rgba(255,16,240,0.3);
}

/* ── Particles ── */
#particles {
    position: fixed;
    inset: 0;
    z-index: 3;
    pointer-events: none;
}

/* ── Corner Brackets ── */
.corner {
    position: fixed;
    width: 28px;
    height: 28px;
    z-index: 10;
    opacity: 0.25;
}
.corner::before, .corner::after {
    content: '';
    position: absolute;
    background: var(--pink);
}
.corner-tl { top: 24px; left: 24px; }
.corner-tl::before { top: 0; left: 0; width: 18px; height: 1px; }
.corner-tl::after  { top: 0; left: 0; width: 1px;  height: 18px; }
.corner-tr { top: 24px; right: 24px; }
.corner-tr::before { top: 0; right: 0; width: 18px; height: 1px; }
.corner-tr::after  { top: 0; right: 0; width: 1px;  height: 18px; }
.corner-bl { bottom: 24px; left: 24px; }
.corner-bl::before { bottom: 0; left: 0; width: 18px; height: 1px; }
.corner-bl::after  { bottom: 0; left: 0; width: 1px;  height: 18px; }
.corner-br { bottom: 24px; right: 24px; }
.corner-br::before { bottom: 0; right: 0; width: 18px; height: 1px; }
.corner-br::after  { bottom: 0; right: 0; width: 1px;  height: 18px; }

/* ── Boot Terminal ── */
.boot-terminal {
    position: fixed;
    top: 58%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(11px, 1.8vw, 14px);
    color: var(--gray);
    z-index: 50;
    white-space: pre;
    line-height: 2;
    transition: opacity 0.6s ease-out;
}
.boot-terminal .prompt { color: var(--pink); }
.boot-terminal .ok     { color: var(--cyan); }
.boot-terminal .cursor {
    display: inline-block;
    width: 8px;
    height: 14px;
    background: var(--pink);
    vertical-align: middle;
    animation: blink 0.6s step-end infinite;
    margin-left: 2px;
}
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ── Main Content ── */
.main-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    padding: 2rem;
    gap: 0;
}

/* Logo */
.logo-area {
    position: relative;
    text-align: center;
    opacity: 0;
    transform: translateY(24px) scale(0.97);
    transition: all 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}
.logo-area.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.boot-logo-bg {
    position: fixed;
    top: 60%;
    left: 50%;
    width: clamp(180px, 20vw, 260px);
    max-width: 44vw;
    transform: translate(-50%, -50%);
    opacity: 0.14;
    filter: saturate(0.7);
    pointer-events: none;
    z-index: 45;
}

.logo-text {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 800;
    font-size: clamp(3rem, 9vw, 6.5rem);
    letter-spacing: -0.03em;
    color: var(--white);
    position: relative;
    display: inline-block;
    text-shadow: 0 0 30px rgba(255,16,240,0.4), 0 0 80px rgba(255,16,240,0.15);
    cursor: default;
    z-index: 1;
}
.logo-text .pink {
    color: var(--pink);
    text-shadow: 0 0 20px rgba(255,16,240,0.8), 0 0 60px rgba(255,16,240,0.3);
}
.logo-text:hover {
    animation: glitch 0.25s ease;
}
.logo-text::before,
.logo-text::after {
    content: 'onejooan';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0;
}
.logo-text::before {
    color: var(--cyan);
    clip-path: inset(20% 0 60% 0);
}
.logo-text::after {
    color: var(--pink);
    clip-path: inset(60% 0 10% 0);
}
.logo-text:hover::before {
    opacity: 0.6;
    animation: glitchShift1 0.25s ease;
}
.logo-text:hover::after {
    opacity: 0.6;
    animation: glitchShift2 0.25s ease;
}
@keyframes glitch {
    0%   { transform: translate(0); }
    20%  { transform: translate(-3px, 2px); }
    40%  { transform: translate(3px, -1px); }
    60%  { transform: translate(-1px, -2px); }
    80%  { transform: translate(2px, 1px); }
    100% { transform: translate(0); }
}
@keyframes glitchShift1 {
    0%   { transform: translate(0); clip-path: inset(20% 0 60% 0); }
    25%  { transform: translate(-4px, 0); clip-path: inset(45% 0 30% 0); }
    50%  { transform: translate(3px, 0); clip-path: inset(10% 0 70% 0); }
    75%  { transform: translate(-2px, 0); clip-path: inset(70% 0 5% 0); }
    100% { transform: translate(0); clip-path: inset(20% 0 60% 0); opacity: 0; }
}
@keyframes glitchShift2 {
    0%   { transform: translate(0); clip-path: inset(60% 0 10% 0); }
    25%  { transform: translate(4px, 0); clip-path: inset(30% 0 40% 0); }
    50%  { transform: translate(-3px, 0); clip-path: inset(75% 0 8% 0); }
    75%  { transform: translate(2px, 0); clip-path: inset(5% 0 80% 0); }
    100% { transform: translate(0); clip-path: inset(60% 0 10% 0); opacity: 0; }
}

.logo-subtext {
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(7px, 1.2vw, 11px);
    letter-spacing: 0.35em;
    color: var(--purple-gray);
    margin-top: 10px;
    text-transform: uppercase;
}

/* Tagline */
.tagline-area {
    margin-top: 2.5rem;
    text-align: center;
    max-width: 560px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.2s;
}
.tagline-area.visible {
    opacity: 1;
    transform: translateY(0);
}
.tagline-text {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: clamp(0.95rem, 2.2vw, 1.2rem);
    color: var(--gray-light);
    line-height: 1.7;
}
.tagline-text .hl {
    color: var(--white);
    font-weight: 500;
}

/* Divider */
.divider {
    width: 60px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--pink), transparent);
    margin-top: 2rem;
    opacity: 0;
    transition: opacity 0.8s ease 0.5s;
    box-shadow: 0 0 8px rgba(255,16,240,0.3);
}
.divider.visible { opacity: 1; }

/* Status */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 1.5rem;
    padding: 8px 22px;
    border: 1px solid rgba(255,16,240,0.2);
    border-radius: 2px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--pink);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    opacity: 0;
    transition: all 0.8s ease 0.6s;
}
.status-badge.visible { opacity: 1; }
.status-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--pink);
    box-shadow: 0 0 8px var(--pink);
    animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.3; transform: scale(0.8); }
}

/* ── Email Terminal ── */
.email-terminal {
    margin-top: 1.8rem;
    opacity: 0;
    transform: translateY(16px);
    transition: all 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.75s;
    width: 100%;
    max-width: 440px;
}
.email-terminal.visible {
    opacity: 1;
    transform: translateY(0);
}

.email-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--gray);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.email-label i {
    font-size: 11px;
    color: rgba(255,16,240,0.4);
}

.email-row {
    display: flex;
    align-items: stretch;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 2px;
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: rgba(255,255,255,0.015);
}
.email-row:focus-within {
    border-color: rgba(255,16,240,0.4);
    box-shadow: 0 0 20px rgba(255,16,240,0.08), inset 0 0 20px rgba(255,16,240,0.02);
}

.email-prompt {
    display: flex;
    align-items: center;
    padding: 0 14px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    color: var(--pink);
    user-select: none;
    flex-shrink: 0;
    border-right: 1px solid rgba(255,255,255,0.05);
    background: rgba(255,16,240,0.02);
}

.email-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 14px 16px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    color: var(--white);
    letter-spacing: 0.02em;
    min-width: 0;
}
.email-input::placeholder {
    color: rgba(255,255,255,0.18);
    font-style: italic;
}

.email-btn {
    flex-shrink: 0;
    background: rgba(255,16,240,0.1);
    border: none;
    border-left: 1px solid rgba(255,255,255,0.05);
    padding: 14px 22px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--pink);
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.email-btn:hover {
    background: rgba(255,16,240,0.2);
    color: var(--white);
    text-shadow: 0 0 8px rgba(255,16,240,0.5);
}
.email-btn:active {
    transform: scale(0.97);
}

/* Success state */
.email-terminal.success .email-row {
    border-color: rgba(0,255,255,0.3);
    box-shadow: 0 0 20px rgba(0,255,255,0.06);
}
.email-terminal.success .email-prompt {
    color: var(--cyan);
    border-right-color: rgba(0,255,255,0.1);
}
.email-success-msg {
    display: none;
    margin-top: 10px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--cyan);
    letter-spacing: 0.05em;
    animation: fadeSlideIn 0.4s ease;
}
.email-terminal.success .email-success-msg {
    display: flex;
    align-items: center;
    gap: 8px;
}
.email-terminal.success .email-label,
.email-terminal.success .email-btn {
    opacity: 0.4;
    pointer-events: none;
}
.email-terminal.success .email-input {
    opacity: 0.4;
}

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Error state */
.email-terminal.error .email-row {
    border-color: rgba(255,60,60,0.4);
    animation: inputShake 0.4s ease;
}
.email-error-msg {
    display: none;
    margin-top: 10px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: #ff4444;
    letter-spacing: 0.05em;
    animation: fadeSlideIn 0.3s ease;
}
.email-terminal.error .email-error-msg {
    display: block;
}

@keyframes inputShake {
    0%, 100% { transform: translateX(0); }
    20%  { transform: translateX(-6px); }
    40%  { transform: translateX(5px); }
    60%  { transform: translateX(-4px); }
    80%  { transform: translateX(3px); }
}

/* Social Links */
.social-grid {
    display: flex;
    gap: 12px;
    margin-top: 2rem;
    flex-wrap: wrap;
    justify-content: center;
    opacity: 0;
    transform: translateY(16px);
    transition: all 0.9s cubic-bezier(0.16, 1, 0.3, 1) 1s;
}
.social-grid.visible {
    opacity: 1;
    transform: translateY(0);
}

.social-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 2px;
    text-decoration: none;
    color: var(--gray);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.08em;
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
}
.social-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,16,240,0.08), transparent 60%);
    opacity: 0;
    transition: opacity 0.35s ease;
}
.social-link:hover::before { opacity: 1; }
.social-link:hover {
    border-color: rgba(255,16,240,0.35);
    color: var(--white);
    box-shadow: 0 0 20px rgba(255,16,240,0.1), inset 0 0 20px rgba(255,16,240,0.03);
    transform: translateY(-2px);
}
.social-link i {
    font-size: 15px;
    color: var(--gray);
    transition: all 0.35s ease;
    position: relative;
    z-index: 1;
}
.social-link:hover i {
    color: var(--pink);
    filter: drop-shadow(0 0 6px rgba(255,16,240,0.5));
}
.social-link .proto {
    color: rgba(255,16,240,0.35);
    font-size: 9px;
    position: relative;
    z-index: 1;
}
.social-link .label {
    position: relative;
    z-index: 1;
}

/* Footer */
.footer-text {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    font-family: 'JetBrains Mono', monospace;
    font-size: 9px;
    color: rgba(255,255,255,0.12);
    letter-spacing: 0.25em;
    text-transform: uppercase;
    z-index: 10;
    white-space: nowrap;
}

/* ── Responsive ── */
@media (max-width: 640px) {
    .social-link .label,
    .social-link .proto {
        display: none;
    }
    .social-link {
        padding: 12px 16px;
    }
    .email-terminal {
        max-width: 100%;
    }
    .email-btn {
        padding: 14px 16px;
        font-size: 10px;
        letter-spacing: 0.08em;
    }
    .email-prompt {
        padding: 0 10px;
        font-size: 12px;
    }
    .footer-text {
        font-size: 7px;
        letter-spacing: 0.15em;
    }
    .corner { display: none; }
}

/* ── Flicker ── */
@keyframes subtleFlicker {
    0%, 100% { opacity: 1; }
    91% { opacity: 1; }
    92% { opacity: 0.85; }
    93% { opacity: 1; }
    95.5% { opacity: 0.92; }
    96.5% { opacity: 1; }
}
.flicker { animation: subtleFlicker 10s ease-in-out infinite; }
