:root {
    --bg-color: #050505;
    --text-primary: #ffffff;
    --text-muted: #888888;
    --accent: #39ff14; /* Neon green */
    --accent-glow: rgba(57, 255, 20, 0.5);
    --card-bg: #111111;
    --font-heading: 'Anton', sans-serif;
    --font-body: 'Space Mono', monospace;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* CRT Scanlines and Noise effects */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0),
        rgba(255, 255, 255, 0) 50%,
        rgba(0, 0, 0, 0.2) 50%,
        rgba(0, 0, 0, 0.2)
    );
    background-size: 100% 4px;
    z-index: 100;
    pointer-events: none;
    opacity: 0.3;
}

.noise {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.05;
    z-index: 99;
    pointer-events: none;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4rem;
    position: relative;
    z-index: 10;
}

/* Hero Section */
.hero {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

.logo-container {
    position: relative;
    width: 250px;
    height: 250px;
    margin-bottom: 1rem;
}

.hero-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 0 20px var(--accent-glow));
}

.glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 150%;
    height: 150%;
    background: radial-gradient(circle, var(--accent-glow) 0%, rgba(0,0,0,0) 70%);
    z-index: 1;
    opacity: 0.6;
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.4; transform: translate(-50%, -50%) scale(0.9); }
    50% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.1); }
}

.floating {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-15px) rotate(2deg); }
    66% { transform: translateY(10px) rotate(-2deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

.glitch {
    font-family: var(--font-heading);
    font-size: 5rem;
    text-transform: uppercase;
    position: relative;
    color: var(--text-primary);
    letter-spacing: 2px;
    margin: 0;
    line-height: 1;
    text-shadow: 0 0 10px rgba(255,255,255,0.3);
}

.glitch::before, .glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 red;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 var(--accent);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim2 5s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip: rect(10px, 9999px, 86px, 0); }
    5% { clip: rect(93px, 9999px, 6px, 0); }
    10% { clip: rect(38px, 9999px, 88px, 0); }
    15% { clip: rect(59px, 9999px, 2px, 0); }
    20% { clip: rect(21px, 9999px, 95px, 0); }
    25% { clip: rect(76px, 9999px, 44px, 0); }
    30% { clip: rect(42px, 9999px, 63px, 0); }
    35% { clip: rect(8px, 9999px, 18px, 0); }
    40% { clip: rect(53px, 9999px, 79px, 0); }
    45% { clip: rect(92px, 9999px, 35px, 0); }
    50% { clip: rect(15px, 9999px, 51px, 0); }
    55% { clip: rect(64px, 9999px, 91px, 0); }
    60% { clip: rect(27px, 9999px, 12px, 0); }
    65% { clip: rect(81px, 9999px, 73px, 0); }
    70% { clip: rect(33px, 9999px, 49px, 0); }
    75% { clip: rect(96px, 9999px, 24px, 0); }
    80% { clip: rect(48px, 9999px, 82px, 0); }
    85% { clip: rect(19px, 9999px, 57px, 0); }
    90% { clip: rect(72px, 9999px, 39px, 0); }
    95% { clip: rect(5px, 9999px, 98px, 0); }
    100% { clip: rect(85px, 9999px, 16px, 0); }
}

@keyframes glitch-anim2 {
    0% { clip: rect(82px, 9999px, 31px, 0); }
    5% { clip: rect(14px, 9999px, 65px, 0); }
    10% { clip: rect(57px, 9999px, 93px, 0); }
    15% { clip: rect(9px, 9999px, 47px, 0); }
    20% { clip: rect(73px, 9999px, 8px, 0); }
    25% { clip: rect(26px, 9999px, 52px, 0); }
    30% { clip: rect(91px, 9999px, 19px, 0); }
    35% { clip: rect(45px, 9999px, 76px, 0); }
    40% { clip: rect(88px, 9999px, 34px, 0); }
    45% { clip: rect(12px, 9999px, 83px, 0); }
    50% { clip: rect(68px, 9999px, 22px, 0); }
    55% { clip: rect(35px, 9999px, 96px, 0); }
    60% { clip: rect(79px, 9999px, 5px, 0); }
    65% { clip: rect(21px, 9999px, 48px, 0); }
    70% { clip: rect(95px, 9999px, 62px, 0); }
    75% { clip: rect(41px, 9999px, 15px, 0); }
    80% { clip: rect(6px, 9999px, 89px, 0); }
    85% { clip: rect(53px, 9999px, 37px, 0); }
    90% { clip: rect(87px, 9999px, 71px, 0); }
    95% { clip: rect(29px, 9999px, 11px, 0); }
    100% { clip: rect(64px, 9999px, 94px, 0); }
}

.subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
}

.action-buttons {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.btn {
    position: relative;
    display: inline-block;
    padding: 2px;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: linear-gradient(90deg, var(--accent), #fff, var(--accent));
    background-size: 200% auto;
    border-radius: 4px;
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
}

.btn:hover {
    background-position: right center;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px var(--accent-glow);
}

.btn:active {
    transform: translateY(1px);
}

.btn-content {
    display: block;
    background-color: var(--bg-color);
    padding: 0.8rem 2rem;
    color: var(--accent);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.btn:hover .btn-content {
    color: #000;
    background-color: transparent;
}

.btn-icon {
    border-radius: 50%;
}
.btn-icon .btn-content {
    padding: 0.8rem 1.2rem;
    border-radius: 50%;
}

/* Dictionary Section */
.dictionary-card {
    background-color: var(--card-bg);
    border: 1px solid #333;
    border-radius: 8px;
    width: 100%;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    position: relative;
}

.dictionary-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    box-shadow: inset 0 0 20px rgba(57, 255, 20, 0.05);
    pointer-events: none;
}

.terminal-header {
    background-color: #222;
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid #333;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.title {
    margin-left: auto;
    margin-right: auto;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.terminal-body {
    padding: 2rem;
}

.word {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: baseline;
    gap: 1rem;
    text-shadow: 0 0 5px var(--accent-glow);
}

.phonetic {
    font-family: var(--font-body);
    font-size: 1.2rem;
    color: var(--text-muted);
    text-transform: none;
    text-shadow: none;
}

.part-of-speech {
    color: var(--text-primary);
    font-style: italic;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed #333;
}

.definition {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: #ddd;
    line-height: 1.6;
}

.definition p {
    position: relative;
    padding-left: 1rem;
}

.cursor {
    display: inline-block;
    width: 10px;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Footer */
footer {
    border-top: 1px solid #222;
    padding: 3rem 1rem;
    text-align: center;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    z-index: 10;
    position: relative;
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.evolution {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--text-primary);
}

.disclaimer, .not-advice {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.not-advice {
    color: #555;
}

/* Responsive */
@media (max-width: 600px) {
    .glitch { font-size: 3.5rem; }
    .word { font-size: 2rem; flex-direction: column; gap: 0.2rem; }
    .action-buttons { flex-direction: column; width: 100%; }
    .btn { width: 100%; }
}
