@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Cinzel:wght@700;900&family=Oswald:wght@700&family=Righteous&family=Teko:wght@700&family=Playfair+Display:wght@700;900&family=Creepster&family=Bungee+Shade&family=Orbitron:wght@900&family=Permanent+Marker&family=Metamorphous&family=Nosifer&family=Special+Elite&family=Staatliches&family=Rye&family=Black+Ops+One&family=Uncial+Antiqua&family=Metal+Mania&family=Amiri:wght@700&display=swap');

@font-face {
    font-family: 'GangOfThree';
    src: url('../fonts/gang_of_three/go3v2.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'hosikyo satsuki';
    src: url('../fonts/hoshiko_satsuki/Hoshiko Satsuki.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'african';
    src: url('../fonts/south_african/SouthAfrican_PersonalUse.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'mayan';
    src: url('../fonts/mayan_2/Mayan.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'motherland';
    src: url('../fonts/motherland/Motherland.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'flat_earth_scrybe';
    src: url('../fonts/flat_earth_scribe/FlatEarthScrybe.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'egypt';
    src: url('../fonts/mythology_of_egypt/Mythology\ Of\ Egypt.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'arabic';
    src: url('../fonts/arabic_ramadhan/Arabic\ Ramadhan.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'greek';
    src: url('../fonts/ancient_geek/geek.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'arcadian';
    src: url('../fonts/acadian_runes/Acadian_Runes-Regular_PERSONAL_USE.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'cf-the-rock';
    src: url('../fonts/cf-the-rock/CFTheRockPersonalUse-Regula.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

/* Navigation Bar - Inherits from main.css */
/* No navbar overrides needed - using main.css styles */

/* Animated starfield background */
.stars,
.stars2,
.stars,
.stars2,
.stars3 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}
    background: transparent url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVQYV2NgYGD4DwABBAEAW9JJQQAAAABJRU5ErkJggg==') repeat;
    background-size: 200px 200px;
    animation: animateStars 50s linear infinite;
    opacity: 0.3;
}

.stars2 {
    background: transparent url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFUlEQVQYV2NgYGD4z8DAwMDAAAAA//8CfgH/xxxxxxxxxxx') repeat;
    background-size: 300px 300px;
    animation: animateStars 100s linear infinite;
    opacity: 0.2;
}

.stars3 {
    background: transparent url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAADCAYAAABWKLW/AAAAHklEQVQYV2NgYGD4z8DAwMgABBgZGRkYGBgY/gMABP0B/xxxxxxxxx') repeat;
    background-size: 400px 400px;
    animation: animateStars 150s linear infinite;
    opacity: 0.15;
}

@keyframes animateStars {
    from { transform: translateY(0); }
    to { transform: translateY(-1000px); }
}

/* Timeline Header */
.timeline-header {
    position: relative;
    padding: 3rem 2rem 2rem;
    text-align: center;
    background: linear-gradient(180deg, rgba(0,0,0,0.9) 0%, transparent 100%);
    z-index: 100;
    margin-top: 60px; /* Account for navbar */
}

.timeline-title {
    font-family: 'Cinzel', serif;
    font-size: 4rem;
    font-weight: 900;
    letter-spacing: 8px;
    background: linear-gradient(45deg, #00ffff, #ffffff, #ff00ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 40px rgba(0, 255, 255, 0.5);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
}

/* Timeline Container */
.timeline-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 10;
    background: transparent; /* Ensure transparent to show body background */
}

/* Phase Navigation */
.phase-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
    position: sticky;
    top: 80px;
    z-index: 999;
    background: rgba(0, 0, 0, 0.7);
    padding: 0.6rem;
    border-radius: 40px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(0, 255, 255, 0.3);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.phase-nav-btn {
    background: linear-gradient(135deg, rgba(0, 255, 255, 0.1), rgba(255, 0, 255, 0.1));
    border: 2px solid rgba(0, 255, 255, 0.5);
    color: #00ffff;
    font-family: 'Cinzel', serif;
    font-size: 1.2rem;
    font-weight: 900;
    padding: 0.6rem 1.2rem;
    cursor: pointer;
    transition: all 0.4s;
    border-radius: 8px;
    min-width: 50px;
    position: relative;
    overflow: hidden;
}

.phase-nav-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(0, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.5s, height 0.5s;
}

.phase-nav-btn:hover::before {
    width: 300px;
    height: 300px;
}

.phase-nav-btn:hover {
    border-color: #00ffff;
    box-shadow: 0 0 30px rgba(0, 255, 255, 0.6);
    transform: scale(1.1);
}

.phase-nav-btn.active {
    background: linear-gradient(135deg, rgba(0, 255, 255, 0.3), rgba(255, 0, 255, 0.3));
    border-color: #ff00ff;
    box-shadow: 0 0 40px rgba(255, 0, 255, 0.8);
    color: #ffffff;
}

.phase-nav-btn span {
    position: relative;
    z-index: 0;
}

/* Phase Sections */
.phase-section {
    animation: fadeIn 0.8s ease-in-out;
    margin-bottom: 5rem;
    scroll-margin-top: 180px; /* Account for navbar + phase nav */
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.phase-header {
    text-align: center;
    margin: 4rem 0;
    position: relative;
}

.phase-header::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 182, 193, 0.5), transparent);
}

.phase-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 4.5rem;
    letter-spacing: 12px;
    margin-bottom: 0.5rem;
    text-shadow:
        0 0 20px rgba(255, 255, 255, 0.8),
        0 0 40px rgba(255, 255, 255, 0.5),
        0 0 60px rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 0;
    background-color: #000000;
    padding: 0 2rem;
    display: inline-block;
    color: #FFFFFF;
}

.phase-subtitle {
    font-family: 'Oswald', sans-serif;
    font-size: 2rem;
    background: linear-gradient(135deg, #FFB6C1, #B3E0FF);
    -webkit-background-clip: text;
    background-clip: text;
    letter-spacing: 6px;
    text-shadow: 0 0 15px rgba(255, 182, 193, 0.6);
    position: relative;
    z-index: 0;
    background-color: #000000;
    padding: 0 2rem;
    display: inline-block;
}

/* Stories Grid */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3rem;
    padding: 2rem 0;
}

/* Story Cards - Each gets unique styling */
.story-card {
    position: relative;
    padding: 3rem 2rem;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: visible;
    min-height: 250px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.story-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
    opacity: 0;
    transition: opacity 0.5s;
    z-index: 0;
}

.story-card:hover::before {
    opacity: 0;
}

.story-card:hover {
    transform: scale(1.15) translateY(-10px);
}

/* ========================================
   THEMED STORY CARDS
   ======================================== */

/* STONEFALL - Rocky, ancient stone texture */
.story-card[data-story="stonefall"] .story-title {
    font-family: 'cf-the-rock', serif;
    font-size: 5rem !important;
    color: #8B7355;
    text-shadow:
        3px 3px 0 rgba(101, 67, 33, 0.8),
        4px 4px 0 rgba(80, 55, 25, 0.6),
        0 0 20px rgba(139, 115, 85, 0.4);
    letter-spacing: 6px;
    position: relative;
    z-index: 2;
    filter: none;
}

/* MOONRISE - Pure milky white, ornate text, pale blue moon */
.story-card[data-story="moonrise"] .story-title {
    font-family: 'Playfair Display', serif;
    font-size: 5rem !important;
    color: #FFFFFF;
    text-shadow:
        0 0 40px rgba(255, 255, 255, 0.8),
        0 10px 20px rgba(173, 216, 230, 0.4),
        0 -2px 30px rgba(255, 255, 255, 0.6);
    position: relative;
    z-index: 2;
}

.story-card[data-story="moonrise"]::before {
    content: '';
    position: absolute;
    width: 400px;
    height:     400px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -68%);
    background: url('../images/moon.png') no-repeat center center;
    background-size: contain;
    opacity: 0.45;
    z-index: 0;
    pointer-events: none;
    filter: brightness(1.2) contrast(0.8);
}



/* MAYHEM IN MEXICO PART 1 - Sun-bleached, graffiti, aztec */
.story-card[data-story="mayhem-mexico-1"] {
    position: relative;
}

.story-card[data-story="mayhem-mexico-1"]::before {
    content: '▲';
    position: absolute;
    font-size: 15rem;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(180deg);
    color: #8B4513;
    opacity: 0.15;
    z-index: 0;
}

.story-card[data-story="mayhem-mexico-1"] .story-title {
    font-family: 'Permanent Marker', cursive;
    color: #8B4513;
    text-shadow:
        3px 3px 0 #2F4F2F,
        -2px -2px 0 rgba(218, 165, 32, 0.5),
        0 0 30px rgba(139, 69, 19, 0.8);
    transform: rotate(-2deg);
    position: relative;
    z-index: 2;
}

/* THE UNBINDING OF MANIA - Runic, golden orange, glowing */
.story-card[data-story="unbinding"] {
    position: relative;
}

.story-card[data-story="unbinding"] .story-title {
    font-family: 'Uncial Antiqua', serif;
    color: #FF8C00;
    text-shadow:
        0 0 40px rgba(255, 140, 0, 1),
        0 0 60px rgba(255, 215, 0, 0.8),
        2px 2px 0 rgba(139, 69, 0, 0.6);
    letter-spacing: 4px;
    position: relative;
    z-index: 2;
}

/* AIRE ASSAULT - Mechanical, grey and dark green, guns */
.story-card[data-story="aire-assault"] {
    position: relative;
}


.story-card[data-story="aire-assault"] .story-title {
    font-family: 'GangOfThree', sans-serif;
    color: #708090;
    text-shadow:
        0 0 20px rgba(0, 100, 0, 0.8),
        -2px 2px 0 #2F4F2F,
        0 0 40px rgba(112, 128, 144, 0.6);
    letter-spacing: 6px;
    position: relative;
    z-index: 2;
}

/* THE SUPER DAVE SUPERSHOW - Crazy red with confetti */
.story-card[data-story="super-dave"] {
    position: relative;
}


.story-card[data-story="super-dave"] .story-title {
    font-family: 'Bungee Shade', cursive;
    color: #FF0000;
    text-shadow:
        3px 3px 0 rgba(255, 215, 0, 1),
        -3px -3px 0 rgba(0, 255, 255, 0.6),
        0 0 30px rgba(255, 0, 0, 1);
    transform: rotate(3deg);
    animation: confettiShake 2s infinite;
    position: relative;
    z-index: 2;
}

@keyframes confettiShake {
    0%, 100% { transform: rotate(3deg); }
    25% { transform: rotate(-2deg); }
    75% { transform: rotate(5deg); }
}

/* THE SUPER DAVE SUPERSHOW SEASON 2 - EXPLOSIVE EXTRAVAGANZA */

.story-card[data-story="super-dave-2"]::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 150%;
    height: 150%;
    background:
        repeating-conic-gradient(from 0deg at 50% 50%,
            transparent 0deg,
            rgba(255, 0, 0, 0.003) 10deg,
            transparent 20deg,
            rgba(255, 215, 0, 0.003) 30deg,
            transparent 40deg,
            rgba(0, 128, 255, 0.003) 50deg,
            transparent 60deg);
    animation: spinRays 200s linear infinite;
    z-index: 0;
    pointer-events: none;
}

@keyframes spinRays {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

.story-card[data-story="super-dave-2"] .story-title {
    font-family: 'Bungee Shade', cursive;
    font-size: 2.5rem !important;
    background: linear-gradient(
        45deg,
        #FF0000 0%,
        #FFD700 33%,
        #0080FF 66%,
        #FF0000 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter:
        drop-shadow(0 0 20px rgba(255, 0, 0, 0.6))
        drop-shadow(0 0 40px rgba(255, 215, 0, 0.6))
        drop-shadow(0 0 60px rgba(0, 128, 255, 0.6))
        drop-shadow(3px 3px 0 rgba(255, 215, 0, 0.4))
        drop-shadow(-3px -3px 0 rgba(0, 128, 255, 0.4));
    animation: act2Pulse 3s linear infinite, superBounce 1.5s infinite;
    position: relative;
    z-index: 2;
    letter-spacing: 8px;
    text-transform: uppercase;
}


@keyframes superBounce {
    0%, 100% {
        transform: rotate(2deg) scale(1);
    }
    25% {
        transform: rotate(-3deg) scale(1.05) translateY(-5px);
    }
    50% {
        transform: rotate(4deg) scale(1.08);
    }
    75% {
        transform: rotate(-2deg) scale(1.05) translateY(-3px);
    }
}

.story-card[data-story="super-dave-2"] .story-subtitle {
    font-family: 'Permanent Marker', cursive;
    font-size: 1.3rem !important;
    background: linear-gradient(90deg, #FFD700, #FFA500, #FF4500, #FFD700);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 15px rgba(255, 215, 0, 1));
    animation: goldenShimmer 2s linear infinite;
    letter-spacing: 6px;
    transform: rotate(-3deg);
    margin-top: 0.5rem;
}

@keyframes goldenShimmer {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

.story-card[data-story="super-dave-2"] .confetti {
    position: absolute;
    opacity: 0.15;
    pointer-events: none;
    z-index: 1;
    animation: confettiFall 4s ease-in-out infinite;
    filter: drop-shadow(0 0 3px currentColor);
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(1) {
    animation-delay: 0s;
    animation-duration: 3.5s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(2) {
    animation-delay: 0.5s;
    animation-duration: 4.2s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(3) {
    animation-delay: 1s;
    animation-duration: 3.8s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(4) {
    animation-delay: 1.5s;
    animation-duration: 4.5s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(5) {
    animation-delay: 2s;
    animation-duration: 3.2s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(6) {
    animation-delay: 0.2s;
    animation-duration: 4s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(7) {
    animation-delay: 0.8s;
    animation-duration: 3.6s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(8) {
    animation-delay: 1.2s;
    animation-duration: 4.3s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(9) {
    animation-delay: 1.8s;
    animation-duration: 3.9s;
}

.story-card[data-story="super-dave-2"] .confetti:nth-child(10) {
    animation-delay: 0.3s;
    animation-duration: 4.1s;
}

@keyframes confettiFall {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.15;
    }
    50% {
        opacity: 0.25;
    }
    100% {
        transform: translateY(20px) rotate(360deg);
        opacity: 0.15;
    }
}

.story-card[data-story="super-dave-2"]:hover .confetti {
    animation-play-state: paused;
    opacity: 0.4;
    filter: drop-shadow(0 0 8px currentColor);
}


/* RETURNING TO HIS ROOTS - Greek themed, light browns/orange */
.story-card[data-story="roots"] {
    position: relative;
}

.story-card[data-story="roots"]::before {
    content: 'Ω';
    position: absolute;
    font-size: 18rem;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -120%);
    color: #D2691E;
    opacity: 0.15;
    z-index: 0;
}

.story-card[data-story="roots"] .story-title {
    font-family: 'greek', serif;
    color: #D2691E;
    text-shadow:
        0 0 30px rgba(210, 105, 30, 0.8),
        2px 2px 0 rgba(184, 134, 11, 0.6),
        0 0 50px rgba(255, 140, 0, 0.4);
    letter-spacing: 4px;
    position: relative;
    z-index: 2;
}

/* THE SALT LAKE'S SHADOW - Iranian inspired, Namak Lake */
.story-card[data-story="salt-lake"] {
    position: relative;
}

.story-card[data-story="salt-lake"]::before {
    content: '▬';
    position: absolute;
    font-size: 25rem;
    top: 50%;
    left: 50%;
    transform: translate(-84%, -173%);
    color: #B0C4DE;
    opacity: 0.12;
    z-index: 0;
    letter-spacing: -5rem;
}

.story-card[data-story="salt-lake"] .story-title {
    font-family: 'Amiri', serif;
    color: #B0C4DE;
    text-shadow:
        0 0 30px rgba(176, 196, 222, 0.6),
        0 4px 20px rgba(25, 25, 112, 0.8),
        0 -2px 10px rgba(255, 255, 255, 0.3);
    letter-spacing: 5px;
    position: relative;
    z-index: 2;
}

/* CRIMSON NIGHT - Chinese New Year red with stars */
.story-card[data-story="crimson"] {
    position: relative;
    overflow: hidden;
}

.story-card[data-story="crimson"] .story-title {
    font-family: 'hosikyo satsuki', serif;
    font-size: 5rem !important;
    color: #8B0000;
    text-shadow:
        0 0 40px rgba(139, 0, 0, 1),
        2px 2px 0 #4B0000,
        0 0 60px rgba(220, 20, 60, 0.8);
    position: relative;
    z-index: 2;
}

.story-card[data-story="crimson"] .star {
    position: absolute;
    color: #DC143C;
    opacity: 0.35;
    filter: drop-shadow(0 0 10px #8B0000);
    pointer-events: none;
    z-index: 0;
}


/* FALL OF THE SUN - Blazing oranges to ash gray */
.story-card[data-story="fall-sun"] .story-title {
    font-family: 'Metal Mania', cursive;
    background: linear-gradient(180deg, #FF4500 0%, #FFA500 30%, #D3D3D3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 60px rgba(255, 69, 0, 0.8);
    filter: drop-shadow(0 0 30px rgba(255, 140, 0, 0.6));
}

/* THE VAYNE MYSTERY - Noir blacks and blues, fogged glass */
.story-card[data-story="vayne"] .story-title {
    font-family: 'Special Elite', cursive;
    color: #4682B4;
    text-shadow:
        0 0 20px rgba(70, 130, 180, 0.6),
        2px 2px 10px rgba(0, 0, 0, 0.8);
    filter: blur(0.5px);
}

/* FIRST INTRODUCTIONS - Soft gold, stage lights */
.story-card[data-story="introductions"] .story-title {
    font-family: 'african', serif;
    color: #DAA520;
    text-shadow:
        0 0 40px rgba(218, 165, 32, 1),
        0 0 60px rgba(255, 215, 0, 0.6),
        2px 2px 0 rgba(184, 134, 11, 0.4);
}

/* PROJECT CORBEAU - Matte black, clinical white, blueprints */
.story-card[data-story="corbeau"] .story-title {
    font-family: 'Orbitron', sans-serif;
    color: #FFFFFF;
    text-shadow:
        0 0 20px rgba(255, 255, 255, 0.8),
        -2px 2px 0 #000000,
        0 0 40px rgba(135, 206, 250, 0.4);
    letter-spacing: 8px;
}

/* THE EVERMORE HOUSE - Antique sepia, Victorian */
.story-card[data-story="evermore"] .story-title {
    font-family: 'Playfair Display', serif;
    color: #DEB887;
    text-shadow:
        0 0 30px rgba(222, 184, 135, 0.8),
        2px 2px 0 rgba(139, 69, 19, 0.5),
        0 0 50px rgba(255, 140, 0, 0.4);
}

/* MAYHEM IN MEXICO PART 2 - Intense, shattered neon */
.story-card[data-story="mayhem-mexico-2"] .story-title {
    font-family: 'Black Ops One', cursive;
    color: #FF4500;
    text-shadow:
        4px 4px 0 #8B4513,
        -3px -3px 0 #00FFFF,
        0 0 40px rgba(255, 69, 0, 1);
    transform: skew(-5deg);
}

/* ONLY WITH THE EYE CAN YOU C RIGHTLY - Optical illusion */
.story-card[data-story="eye-c-rightly"] {
    position: relative;
}

.story-card[data-story="eye-c-rightly"]::before {
    content: '👁';
    position: absolute;
    font-size: 25rem;
    top: 50%;
    left: 50%;
    transform: translate(-82%, -180%);
    opacity: 0.08;
    z-index: 0;
    filter: grayscale(100%);
}

.story-card[data-story="eye-c-rightly"] .story-title {
    font-family: 'egypt', sans-serif;
    background: repeating-linear-gradient(
        45deg,
        #808080,
        #808080 10px,
        #A9A9A9 10px,
        #A9A9A9 20px
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: opticalShift 3s linear infinite;
    position: relative;
    z-index: 2;
}

@keyframes opticalShift {
    0% { background-position: 0 0; }
    100% { background-position: 40px 40px; }
}

/* AIRE CONTRACTS - Clean metallic blue, classified */
.story-card[data-story="aire-contracts"] .story-title {
    font-family: 'motherland', sans-serif;
    color: #4169E1;
    text-shadow:
        0 0 20px rgba(65, 105, 225, 0.8),
        -1px 1px 0 #000000,
        0 0 30px rgba(135, 206, 250, 0.6);
    letter-spacing: 4px;
}

/* ABDUCTED IN ARGENTINA - Concrete city, urban */
.story-card[data-story="argentina"] .story-title {
    font-family: 'Bebas Neue', sans-serif;
    color: #A9A9A9;
    text-shadow:
        0 0 30px rgba(169, 169, 169, 0.8),
        2px 2px 0 #696969,
        4px 4px 0 #505050,
        0 0 50px rgba(211, 211, 211, 0.6);
    letter-spacing: 6px;
}

/* COLD CASES OF MONGOLIA - Frosted whites, icy blues */
.story-card[data-story="mongolia"] .story-title {
    font-family: 'Oswald', sans-serif;
    color: #F0F8FF;
    text-shadow:
        0 0 40px rgba(173, 216, 230, 1),
        2px 2px 10px rgba(0, 191, 255, 0.6),
        0 0 60px rgba(255, 255, 255, 0.8);
}

/* THE DESERT SANDS - Golden dunes, heat shimmer */
.story-card[data-story="desert"] .story-title {
    font-family: 'arabic', cursive;
    color: #DAA520;
    text-shadow:
        0 0 40px rgba(218, 165, 32, 0.8),
        0 4px 20px rgba(184, 134, 11, 0.6);
    animation: heatShimmer 3s ease-in-out infinite;
}

@keyframes heatShimmer {
    0%, 100% { filter: blur(0px); }
    50% { filter: blur(1px); }
}

/* IT STIRS BELOW - Dark subterranean, glowing fissures */
.story-card[data-story="stirs"] {
    position: relative;
}

.story-card[data-story="stirs"]::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    height: 120%;
    background:
        linear-gradient(45deg, transparent 30%, rgba(138, 43, 226, 0.3) 31%, rgba(138, 43, 226, 0.3) 33%, transparent 34%),
        linear-gradient(-45deg, transparent 30%, rgba(138, 43, 226, 0.3) 31%, rgba(138, 43, 226, 0.3) 33%, transparent 34%),
        linear-gradient(135deg, transparent 48%, rgba(255, 69, 0, 0.4) 49%, rgba(255, 69, 0, 0.4) 51%, transparent 52%);
    z-index: 0;
    pointer-events: none;
}

.story-card[data-story="stirs"] .story-title {
    font-family: 'arcadian', serif;
    color: #5C4033;
    text-shadow:
        0 0 40px rgba(138, 43, 226, 0.9),
        0 4px 20px rgba(75, 0, 130, 0.8),
        0 0 60px rgba(255, 69, 0, 0.6);
    position: relative;
    z-index: 2;
    letter-spacing: 4px;
}

/* HAMZAH'S FIST - Bold bronze, Middle Eastern patterns */
.story-card[data-story="hamzah"] .story-title {
    font-family: 'Cinzel', serif;
    color: #CD7F32;
    text-shadow:
        0 0 30px rgba(205, 127, 50, 1),
        3px 3px 0 #8B0000,
        0 0 50px rgba(178, 34, 34, 0.6);
    letter-spacing: 6px;
}

/* TO HIRE A TEAM - Rustic brown */
.story-card[data-story="hire-team"] .story-title {
    font-family: 'Staatliches', sans-serif;
    color: #D2691E;
    text-shadow:
        0 0 30px rgba(210, 105, 30, 0.9),
        2px 2px 0 rgba(139, 69, 19, 0.8),
        0 0 50px rgba(244, 164, 96, 0.6);
    letter-spacing: 5px;
}

/* STARBORN ACT 1 - Cosmic blues, whites, pinks, runic */
.story-card[data-story="starborn-act1"] {
    position: relative;
}

.story-card[data-story="starborn-act1"]::before {
    content: '★';
    position: absolute;
    font-size: 20rem;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -175%);
    color: #FFFFFF;
    opacity: 0.25;
    z-index: 0;
    filter: brightness(1.5);
}

.story-card[data-story="starborn-act1"] .story-title {
    font-family: 'Cinzel', serif;
    font-size: 5rem !important;
    background: linear-gradient(135deg, #87CEEB 0%, #FFFFFF 25%, #FFB6C1 50%, #DDA0DD 75%, #87CEEB 100%);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: cosmicSwirl 8s ease-in-out infinite;
    filter: drop-shadow(0 0 40px rgba(255, 255, 255, 0.9));
    position: relative;
    z-index: 2;
}

@keyframes cosmicSwirl {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* STARBORN ACT 2 - Pulsing between crimson and Act 1 colors */
.story-card[data-story="starborn-act2"] {
    position: relative;
}

.story-card[data-story="starborn-act2"]::before {
    content: '★';
    position: absolute;
    font-size: 20rem;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -175%);
    color: #8B0000;
    opacity: 0.25;
    z-index: 0;
    animation: act2StarPulse 10s ease-in-out infinite;
    filter: brightness(1.5);
}

@keyframes act2StarPulse {
    0%, 100% {
        color: #DC143C;
        opacity: 0.25;
    }
    50% {
        color: #87CEEB;
        opacity: 0.35;
    }
}

.story-card[data-story="starborn-act2"] .story-title {
    font-family: 'Cinzel', serif;
    font-size: 5rem !important;
    background: linear-gradient(135deg, #8B0000 0%, #DC143C 15%, #87CEEB 35%, #FFFFFF 50%, #FFB6C1 65%, #DDA0DD 85%, #8B0000 100%);
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: act2Pulse 6s ease-in-out infinite;
    filter: drop-shadow(0 0 40px rgba(139, 0, 0, 0.8));
    position: relative;
    z-index: 2;
}

@keyframes act2Pulse {
    0%, 100% {
        background-position: 0% 50%;
        filter: drop-shadow(0 0 40px rgba(139, 0, 0, 0.8));
    }
    50% {
        background-position: 100% 50%;
        filter: drop-shadow(0 0 40px rgba(135, 206, 235, 0.9));
    }
}

/* STARBORN ACT 3 - Greyscale fading/dissolving effect */
.story-card[data-story="starborn-act3"] {
    position: relative;
    overflow: visible;
}

.story-card[data-story="starborn-act3"]::before {
    content: '★';
    position: absolute;
    font-size: 20rem;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -175%);
    color: #CCCCCC;
    opacity: 0.25;
    z-index: 0;
    animation: act3StarDissolve 4s ease-in-out infinite;
}

@keyframes act3StarDissolve {
    0%, 100% {
        opacity: 0.25;
        filter: blur(0px) brightness(1.3);
    }
    50% {
        opacity: 0.35;
        filter: blur(3px) brightness(1.3);
    }
}

.story-card[data-story="starborn-act3"] .story-title {
    font-family: 'Cinzel', serif;
    font-size: 5rem !important;
    background: linear-gradient(135deg,
        #adadad 0%,
        #7c7c7c 15%,
        #5f5f5f 30%,
        #636363 50%,
        #2d2d2d 70%,
        #bebebe 85%,
        #E0E0E0 100%);
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: act3Dissolve 12s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(0, 0, 0, 0.6));
    position: relative;
    z-index: 2;
}

@keyframes act3Dissolve {
    0%, 100% {
        background-position: 0% 50%;
        filter: drop-shadow(0 0 30px rgba(0, 0, 0, 0.6)) blur(0px);
        opacity: 1;
    }
    25% {
        background-position: 50% 50%;
        filter: drop-shadow(0 0 20px rgba(150, 150, 150, 0.4)) blur(1px);
        opacity: 0.85;
    }
    50% {
        background-position: 100% 50%;
        filter: drop-shadow(0 0 10px rgba(100, 100, 100, 0.3)) blur(2px);
        opacity: 0.7;
    }
    75% {
        background-position: 50% 50%;
        filter: drop-shadow(0 0 20px rgba(150, 150, 150, 0.4)) blur(1px);
        opacity: 0.85;
    }
}

/* SILVER STAR - Polished chrome, starlight */
.story-card[data-story="silver-star"] .story-title {
    font-family: 'Cinzel', serif;
    background: linear-gradient(135deg, #C0C0C0 0%, #FFFFFF 50%, #E8E8E8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 40px rgba(255, 255, 255, 1));
    animation: starShine 2s ease-in-out infinite;
}

@keyframes starShine {
    0%, 100% { filter: drop-shadow(0 0 40px rgba(255, 255, 255, 0.8)); }
    50% { filter: drop-shadow(0 0 60px rgba(255, 255, 255, 1)); }
}

.story-title {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: 6px;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 2;
    line-height: 1.2;
}

.story-subtitle {
    font-family: 'Oswald', sans-serif;
    font-size: 1.3rem;
    letter-spacing: 4px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1rem;
    position: relative;
    z-index: 2;
}

.story-meta {
    margin-top: 1.5rem;
    position: relative;
    z-index: 2;
}

.story-characters {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.8rem;
    letter-spacing: 2px;
    line-height: 1.6;
}

.story-dates {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.date-badge {
    background: rgba(0, 255, 255, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.5);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-family: 'Courier New', monospace;
    color: #00ffff;
    letter-spacing: 1px;
}

/* Special styling for major stories */
.story-card[data-story="stonefall"],
.story-card[data-story="moonrise"],
.story-card[data-story="starborn-act1"],
.story-card[data-story="starborn-act2"],
.story-card[data-story="starborn-act3"] {
    grid-column: 1 / -1;
    min-height: 350px;
    background: transparent;
}

/* Center lone cards that appear alone on their row */
.story-card[data-story="silver-star"],
.story-card[data-story="crimson"],
.story-card[data-story="hire-team"] {
    grid-column: 1 / -1;
    max-width: 600px;
    margin: 0 auto;
    justify-self: center;
}



/* Responsive */
@media (max-width: 1200px) {
    .stories-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 2rem;
    }

    .timeline-title {
        font-size: 3rem;
    }

    .phase-title {
        font-size: 4rem;
    }
}

@media (max-width: 768px) {
    .stories-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .timeline-title {
        font-size: 2rem;
        letter-spacing: 4px;
    }

    .phase-title {
        font-size: 3rem;
        letter-spacing: 8px;
    }

    .phase-subtitle {
        font-size: 1.5rem;
    }

    .story-title {
        font-size: 2rem;
    }

    .phase-nav {
        gap: 0.5rem;
        padding: 0.4rem;
    }

    .phase-nav-btn {
        font-size: 1rem;
        padding: 0.5rem 1rem;
        min-width: 40px;
    }
}

/* Add glow effect on scroll */
@keyframes pulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

.story-card.in-view {
    animation: fadeIn 0.8s ease-in-out, pulse 2s infinite;
}

/* Modal and Form Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: rgba(20, 20, 30, 0.95);
    border: 1px solid rgba(255, 179, 217, 0.3);
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid rgba(224, 179, 255, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    background: linear-gradient(135deg, #e0b3ff, #ffb3d9, #b3e0ff);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: marbleShift 8s ease infinite;
    font-size: 24px;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 32px;
    cursor: pointer;
    line-height: 1;
    transition: all 0.3s ease;
}

.modal-close:hover {
    color: #ffb3d9;
    transform: rotate(90deg);
}

.modal-body {
    padding: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #444;
    background: #22223a;
    color: #fff;
    font-size: 16px;
    box-sizing: border-box;
}

.form-input:focus {
    outline: none;
    border-color: #e0b3ff;
}

.submit-btn {
    width: 100%;
    padding: 10px;
    border-radius: 6px;
    border: none;
    background: linear-gradient(135deg, #e0b3ff, #ffb3d9, #b3e0ff);
    background-size: 200% 200%;
    color: #22223a;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.3s ease;
    animation: marbleShift 8s ease infinite;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(224, 179, 255, 0.4);
}

/* Notification */
.notification {
    position: fixed;
    top: 80px;
    right: 20px;
    background: rgba(20, 20, 30, 0.95);
    border: 1px solid rgba(224, 179, 255, 0.3);
    padding: 15px 25px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    z-index: 3000;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification.info {
    border-color: rgba(179, 224, 255, 0.5);
    color: #b3e0ff;
}

.notification.success {
    border-color: rgba(179, 255, 179, 0.5);
    color: #b3ffb3;
}

.notification.error {
    border-color: rgba(255, 179, 179, 0.5);
    color: #ffb3b3;
}
