:root {
    --bg-dark: #0b0b0f;
    --bg-card: rgba(20, 20, 30, 0.6);
    --text-gold: #eebb55;
    --text-silver: #cccccc;
    --accent-blue: #00aaff;
    --accent-glow: rgba(0, 170, 255, 0.4);
    --font-heading: 'Cinzel', serif;
    --font-body: 'Inter', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-silver);
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- Waiting Page --- */
.waiting-mode {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: radial-gradient(circle at center, #1a1a2e 0%, #000000 100%);
    position: relative;
}

/* Animated Background Stars */
.stars {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: transparent url('https://s3-us-west-2.amazonaws.com/s.cdpn.io/1231630/stars.png') repeat top center;
    z-index: 0;
}

.twinkling {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: transparent url('https://s3-us-west-2.amazonaws.com/s.cdpn.io/1231630/twinkling.png') repeat top center;
    z-index: 1;
    animation: move-twink-back 200s linear infinite;
    opacity: 0.5;
}

@keyframes move-twink-back {
    from {background-position:0 0;}
    to {background-position:-10000px 5000px;}
}

.waiting-mode .container {
    z-index: 2;
    text-align: center;
    padding: 4rem;
    border: 1px solid rgba(238, 187, 85, 0.3);
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 2px;
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.8);
    max-width: 600px;
}

.epic-title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    color: var(--text-gold);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(238, 187, 85, 0.3);
}

.epic-subtitle {
    font-family: var(--font-body);
    font-size: 1.2rem;
    color: var(--accent-blue);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 3rem;
}

.lock-icon {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    opacity: 0.9;
}

.lock-icon.pulse {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.1); opacity: 1; }
}

.countdown-container {
    margin: 2rem 0;
    font-size: 1.1rem;
    padding: 2rem 0;
    border-top: 1px solid rgba(238, 187, 85, 0.2);
    border-bottom: 1px solid rgba(238, 187, 85, 0.2);
}

.arrival-text {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-silver);
}

.date-display {
    font-size: 2.5rem;
    color: var(--text-gold);
    font-weight: 700;
    margin: 1rem 0;
    font-family: var(--font-heading);
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { text-shadow: 0 0 5px rgba(238, 187, 85, 0.3); }
    to { text-shadow: 0 0 20px rgba(238, 187, 85, 0.6), 0 0 30px rgba(238, 187, 85, 0.3); }
}

.promise-text {
    font-size: 1rem;
    color: var(--accent-blue);
    margin-top: 1rem;
    font-style: italic;
}

.message-box {
    margin-top: 2.5rem;
    padding: 1.5rem;
    background: rgba(0, 170, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(0, 170, 255, 0.2);
}

.message-box p {
    margin: 0.7rem 0;
    line-height: 1.6;
    color: var(--text-silver);
}

.final-hint {
    margin-top: 1.5rem !important;
    font-weight: 600;
    color: var(--text-gold) !important;
    font-size: 1.1rem;
}

/* --- Birthday Page --- */
.birthday-mode {
    background: #0b0b0f;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(76, 29, 149, 0.1) 0%, transparent 25%), 
        radial-gradient(circle at 85% 30%, rgba(0, 170, 255, 0.05) 0%, transparent 25%);
    position: relative;
}

/* Particle Canvas */
#particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.hero-section {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    position: relative;
    z-index: 10;
}

.hero-section h1 {
    font-family: var(--font-heading);
    font-size: 5rem;
    background: linear-gradient(to right, #eebb55, #ffdd88, #eebb55);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 15px rgba(238, 187, 85, 0.3));
    animation: heroEntrance 1.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    transform: scale(0);
}

@keyframes heroEntrance {
    0% { transform: scale(0) rotate(-10deg); opacity: 0; }
    60% { transform: scale(1.1) rotate(2deg); }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-silver);
    letter-spacing: 1px;
    max-width: 600px;
    animation: fadeInUp 1s ease-out 0.5s backwards;
    margin-bottom: 4rem;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.scroll-indicator {
    position: absolute;
    bottom: 20px;
    font-size: 0.9rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    opacity: 0.5;
    animation: bounce 2s infinite, colorShift 5s infinite;
}

@keyframes colorShift {
    0%, 100% { color: var(--text-silver); }
    50% { color: var(--accent-blue); }
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 1000px;
    margin: 50px auto;
    padding: 20px;
}

/* The Line */
.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: linear-gradient(to bottom, transparent, var(--accent-blue), var(--text-gold), transparent);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
    opacity: 0.5;
}

.chapter {
    padding: 20px 50px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
    opacity: 0; /* For animation */
    transform: translateY(30px);
    animation: fadeUp 0.8s forwards;
}

/* Stagger animations */
.chapter:nth-child(1) { animation-delay: 0.2s; }
.chapter:nth-child(2) { animation-delay: 0.4s; }
.chapter:nth-child(3) { animation-delay: 0.6s; }
.chapter:nth-child(4) { animation-delay: 0.8s; }
.chapter:nth-child(5) { animation-delay: 1.0s; }

@keyframes fadeUp {
    0% { opacity: 0; transform: translateY(30px) scale(0.95); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

.chapter.left { left: 0; text-align: right; }
.chapter.right { left: 50%; text-align: left; }

/* The Dot */
.chapter::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    background-color: var(--bg-dark);
    border: 2px solid var(--accent-blue);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
    box-shadow: 0 0 10px var(--accent-glow);
}

.chapter.left::after { right: -8px; }
.chapter.right::after { left: -8px; }

/* Content Card */
.content {
    background: var(--bg-card);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-width: 300px;
}

.content:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0, 170, 255, 0.3), 0 0 30px rgba(238, 187, 85, 0.2);
    border-color: rgba(0, 170, 255, 0.3);
    animation: contentGlow 1s ease-in-out;
}

@keyframes contentGlow {
    0%, 100% { box-shadow: 0 20px 50px rgba(0, 170, 255, 0.3); }
    50% { box-shadow: 0 20px 60px rgba(0, 170, 255, 0.5), 0 0 40px rgba(238, 187, 85, 0.4); }
}

.content h2 {
    font-family: var(--font-heading);
    color: var(--accent-blue);
    font-size: 1.5rem;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(0, 170, 255, 0.5);
    transition: all 0.3s;
}

.content:hover h2 {
    transform: scale(1.05);
    text-shadow: 0 0 20px rgba(0, 170, 255, 0.8);
}

.content img {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    filter: brightness(0.9);
    transition: filter 0.3s;
    background: rgba(0,0,0,0.3);
}

.content:hover img {
    filter: brightness(1.1);
}

.content p {
    font-size: 1rem;
    color: var(--text-silver);
}

/* Bro Message */
.bro-message {
    max-width: 800px;
    margin: 6rem auto 4rem;
    padding: 3rem;
    text-align: center;
    background: linear-gradient(145deg, rgba(20,20,30,0.8), rgba(10,10,15,0.9));
    border: 1px solid var(--accent-blue);
    border-radius: 4px;
    position: relative;
    box-shadow: 0 0 40px rgba(0, 170, 255, 0.1);
}

.bro-message::before {
    content: 'INCOMING TRANSMISSION';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-dark);
    padding: 0 10px;
    font-size: 0.8rem;
    color: var(--accent-blue);
    letter-spacing: 2px;
}

.bro-message h2 {
    font-family: var(--font-heading);
    color: var(--text-gold);
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.bro-message p {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: #e0e0e0;
}

/* Footer */
.epic-footer {
    text-align: center;
    padding: 6rem 1rem;
    background: linear-gradient(to top, #000, transparent);
    position: relative;
    z-index: 10;
}

.gift-box {
    font-size: 4rem;
    cursor: pointer;
    margin-bottom: 1rem;
    display: inline-block;
    transition: transform 0.3s;
    animation: floatGift 3s ease-in-out infinite;
}

@keyframes floatGift {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.gift-box:hover {
    transform: scale(1.3) rotate(15deg) !important;
    animation: none;
}

.click-hint {
    animation: fadeInOut 2s ease-in-out infinite;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.final-message {
    max-width: 700px;
    margin: 0 auto;
    animation: finalSlideIn 1s ease-out backwards;
    animation-delay: 0.5s;
}

@keyframes finalSlideIn {
    from { opacity: 0; transform: translateY(50px); }
    to { opacity: 1; transform: translateY(0); }
}

.footer-img {
    max-width: 100%;
    border-radius: 12px;
    margin: 2rem 0;
    box-shadow: 0 0 30px rgba(0, 170, 255, 0.2);
    border: 1px solid rgba(0, 170, 255, 0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.footer-img:hover {
    transform: scale(1.05);
    box-shadow: 0 0 50px rgba(0, 170, 255, 0.4);
}

.funny-text {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--text-gold);
    margin-bottom: 0.5rem;
    animation: textGlow 2s ease-in-out infinite alternate;
}

@keyframes textGlow {
    from { text-shadow: 0 0 10px rgba(238, 187, 85, 0.3); }
    to { text-shadow: 0 0 20px rgba(238, 187, 85, 0.6), 0 0 30px rgba(238, 187, 85, 0.4); }
}

/* Responsive */
@media screen and (max-width: 768px) {
    .hero-section h1 { font-size: 3rem; }
    
    .timeline::after { left: 30px; }
    
    .chapter {
        width: 100%;
        padding-left: 70px;
        padding-right: 20px;
        text-align: left;
    }
    
    .chapter.left, .chapter.right { left: 0; text-align: left; }
    
    .chapter.left::after, .chapter.right::after {
        left: 21px;
        right: auto;
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-10px);}
    60% {transform: translateY(-5px);}
}
