/* =====================
   CSS RESET & BASE
   Mobile-First Design
   ===================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Soft, romantic color palette */
    --cream: #faf8f5;
    --blush: #f8e8e8;
    --rose: #e8c4c4;
    --dusty-rose: #d4a5a5;
    --deep-rose: #c48888;
    --text-dark: #5c4a4a;
    --text-light: #8b7676;
    --text-muted: #a89999;
    --white: #ffffff;
    --gold: #d4af37;
    --gold-light: #f4e4bc;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Cormorant Garamond', Georgia, serif;
    background-color: var(--cream);
    color: var(--text-dark);
    line-height: 1.9;
    overflow-x: hidden;
}

/* =====================
   HANDWRITTEN FONT STYLES
   ===================== */
.handwritten {
    font-family: 'Caveat', cursive;
    font-weight: 500;
}

.handwritten.large {
    font-size: 1.6rem;
    line-height: 1.6;
    color: var(--deep-rose);
}

.handwritten.small {
    font-size: 1.1rem;
    color: var(--text-muted);
    font-style: italic;
}

.handwritten.highlight {
    font-size: 1.5rem;
    color: var(--deep-rose);
    display: block;
    margin: 1.5rem 0;
    padding-left: 1rem;
    border-left: 3px solid var(--rose);
}

/* =====================
   UTILITY CLASSES
   ===================== */
.hidden {
    display: none !important;
}

/* =====================
   PASSWORD SCREEN
   ===================== */
.password-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, var(--blush) 0%, var(--rose) 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.password-container {
    background: var(--white);
    padding: 2.5rem 2rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 25px 80px rgba(92, 74, 74, 0.15);
    max-width: 380px;
    width: 90%;
    animation: fadeInUp 0.8s ease;
}

.heart-icon {
    font-size: 3.5rem;
    color: var(--deep-rose);
    margin-bottom: 1rem;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.1); }
    50% { transform: scale(1); }
    75% { transform: scale(1.15); }
}

.password-container h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.password-container > .handwritten {
    color: var(--text-light);
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
}

#password-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--rose);
    border-radius: 12px;
    font-size: 1.1rem;
    font-family: 'Caveat', cursive;
    text-align: center;
    letter-spacing: 0.3rem;
    outline: none;
    transition: all 0.3s ease;
    background: var(--cream);
}

#password-input:focus {
    border-color: var(--deep-rose);
    box-shadow: 0 0 20px rgba(200, 136, 136, 0.2);
}

#unlock-btn {
    width: 100%;
    padding: 1rem;
    margin-top: 1rem;
    background: linear-gradient(135deg, var(--dusty-rose) 0%, var(--deep-rose) 100%);
    color: var(--white);
    border: none;
    border-radius: 12px;
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

#unlock-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(196, 136, 136, 0.4);
}

.error-message {
    color: var(--deep-rose);
    font-family: 'Caveat', cursive;
    font-size: 1.1rem;
    margin-top: 1rem;
    min-height: 1.5rem;
}

/* =====================
   HERO SECTION
   ===================== */
.hero {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    background: linear-gradient(180deg, var(--blush) 0%, var(--cream) 100%);
    padding: 2rem;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="90" opacity="0.03">♥</text></svg>');
    background-size: 80px;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    animation: fadeInUp 1s ease;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--dusty-rose);
    margin-bottom: 0.5rem;
    letter-spacing: 0.1em;
}

.hero-title {
    font-family: 'Dancing Script', cursive;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.hero-date {
    font-size: 1.3rem;
    color: var(--text-light);
    margin-bottom: 3rem;
}

.scroll-indicator {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.scroll-indicator .mouse {
    width: 24px;
    height: 40px;
    border: 2px solid var(--dusty-rose);
    border-radius: 12px;
    margin: 0 auto 0.5rem;
    position: relative;
}

.scroll-indicator .mouse::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--dusty-rose);
    border-radius: 2px;
    animation: scrollMouse 2s infinite;
}

@keyframes scrollMouse {
    0%, 100% { opacity: 1; top: 8px; }
    50% { opacity: 0.3; top: 20px; }
}

/* =====================
   STORY SECTIONS
   ===================== */
.story-section {
    padding: 4rem 1.5rem;
    max-width: 100%;
    overflow: hidden;
}

.story-section.alternate {
    background: var(--blush);
}

.story-section.special {
    background: linear-gradient(135deg, var(--cream) 0%, var(--blush) 100%);
}

.chapter-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.chapter-number {
    display: inline-block;
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.chapter-title {
    font-family: 'Dancing Script', cursive;
    font-size: 2.2rem;
    color: var(--text-dark);
    font-weight: 600;
}

.story-content {
    max-width: 800px;
    margin: 0 auto;
}

.story-text {
    margin-bottom: 2rem;
}

.story-text p {
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
    color: var(--text-dark);
}

.story-text.full-width {
    max-width: 700px;
    margin: 0 auto;
}

.story-image {
    margin: 2rem 0;
    text-align: center;
}

.story-image img {
    width: 100%;
    max-width: 400px;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(92, 74, 74, 0.15);
    transition: transform 0.5s ease;
}

.story-image img:hover {
    transform: scale(1.02);
}

.story-image.featured img {
    max-width: 100%;
    border-radius: 15px;
}

.image-caption {
    display: block;
    margin-top: 1rem;
    font-size: 1.2rem;
    color: var(--text-light);
}

/* =====================
   FIRST DATE SECTION
   ===================== */
.story-section.first-date {
    background: var(--white);
}

.date-story {
    max-width: 800px;
    margin: 0 auto;
}

.date-moment {
    margin-bottom: 3rem;
}

.moment-image {
    margin-bottom: 1.5rem;
}

.moment-image img {
    width: 100%;
    max-width: 350px;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 15px 50px rgba(92, 74, 74, 0.12);
}

.moment-text h3 {
    font-family: 'Dancing Script', cursive;
    font-size: 1.8rem;
    color: var(--deep-rose);
    margin-bottom: 1rem;
}

.moment-text p {
    font-size: 1.05rem;
    margin-bottom: 0.8rem;
    color: var(--text-dark);
}

.moment-text .handwritten {
    color: var(--deep-rose);
    font-size: 1.2rem;
}

/* =====================
   PROPOSAL SECTION
   ===================== */
.story-section.proposal {
    background: linear-gradient(180deg, var(--blush) 0%, var(--rose) 50%, var(--blush) 100%);
    padding: 5rem 1.5rem;
    text-align: center;
}

.proposal-content {
    max-width: 600px;
    margin: 0 auto;
}

.proposal-content .intro {
    font-size: 1.4rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.proposal-text {
    font-size: 1.15rem;
    color: var(--text-dark);
    margin-bottom: 2rem;
}

.proposal-question {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 2rem;
    line-height: 1.3;
}

.answer-reveal {
    padding: 2rem;
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(92, 74, 74, 0.1);
}

.answer-reveal .answer {
    font-size: 2rem;
    color: var(--deep-rose);
    margin-bottom: 0.5rem;
}

.answer-reveal .reason {
    font-size: 1.4rem;
    color: var(--text-light);
    font-style: italic;
}

.firstdate-image {
    margin-top: 3rem;
    text-align: center;
}

.firstdate-image img {
    width: 100%;
    max-width: 450px;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 25px 80px rgba(92, 74, 74, 0.2);
    transition: transform 0.5s ease;
}

.firstdate-image img:hover {
    transform: scale(1.02);
}

.firstdate-image .image-caption {
    display: block;
    margin-top: 1.2rem;
    font-size: 1.3rem;
    color: var(--text-light);
}

/* =====================
   GALLERY SECTION
   ===================== */
.gallery-section {
    padding: 4rem 1.5rem;
    background: var(--white);
    text-align: center;
}

.section-title {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.gallery-subtitle {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 2.5rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    max-width: 1000px;
    margin: 0 auto;
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(92, 74, 74, 0.1);
    cursor: pointer;
    aspect-ratio: 1;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(92, 74, 74, 0.15);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(212, 165, 165, 0.7) 0%, rgba(196, 136, 136, 0.7) 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay span {
    color: var(--white);
    font-size: 2.5rem;
    animation: heartbeat 1s ease-in-out infinite;
}

/* =====================
   LIGHTBOX
   ===================== */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(45, 35, 35, 0.95);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox img {
    max-width: 95%;
    max-height: 80vh;
    border-radius: 10px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.lightbox-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2.5rem;
    color: var(--white);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2001;
}

.lightbox-close:hover {
    color: var(--rose);
    transform: rotate(90deg);
}

.lightbox-nav {
    position: absolute;
    bottom: 25px;
    display: flex;
    gap: 1rem;
}

.lightbox-nav button {
    background: var(--white);
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-dark);
}

.lightbox-nav button:hover {
    background: var(--rose);
    color: var(--white);
    transform: scale(1.1);
}

/* =====================
   LOVE LETTER SECTION
   ===================== */
.letter-section {
    padding: 4rem 1.5rem;
    background: linear-gradient(180deg, var(--cream) 0%, var(--blush) 100%);
}

.letter-container {
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: 2.5rem 2rem;
    border-radius: 20px;
    box-shadow: 0 25px 80px rgba(92, 74, 74, 0.1);
    position: relative;
}

.letter-container::before {
    content: '♥';
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    color: var(--deep-rose);
    background: var(--white);
    padding: 0 1rem;
}

.letter-container h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    text-align: center;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
}

.letter-content {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--text-dark);
}

.letter-content p {
    margin-bottom: 1rem;
}

.letter-content .greeting {
    font-size: 1.4rem;
    color: var(--deep-rose);
    margin-bottom: 1.2rem;
}

.letter-content .signature {
    text-align: right;
    font-size: 1.5rem;
    color: var(--deep-rose);
    margin-top: 1.5rem;
}

/* =====================
   FOOTER
   ===================== */
.footer {
    padding: 3rem 1.5rem;
    text-align: center;
    background: var(--white);
}

.footer-hearts {
    font-size: 1.8rem;
    color: var(--deep-rose);
    margin-bottom: 1rem;
    letter-spacing: 0.5rem;
    animation: heartbeat 2s ease-in-out infinite;
}

.footer .handwritten {
    font-size: 1.3rem;
    color: var(--text-light);
}

.footer-note {
    font-family: 'Dancing Script', cursive;
    font-size: 1.1rem;
    color: var(--dusty-rose);
    margin-top: 0.5rem;
}

/* =====================
   ANIMATIONS
   ===================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

/* =====================
   TABLET STYLES (768px+)
   ===================== */
@media (min-width: 768px) {
    .hero-title {
        font-size: 5rem;
    }

    .hero-subtitle {
        font-size: 1.8rem;
    }

    .story-section {
        padding: 6rem 3rem;
    }

    .chapter-title {
        font-size: 2.8rem;
    }

    .story-content {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 3rem;
        align-items: center;
    }

    .story-content.reverse {
        direction: rtl;
    }

    .story-content.reverse > * {
        direction: ltr;
    }

    .story-text {
        margin-bottom: 0;
    }

    .story-image {
        margin: 0;
    }

    .story-image img {
        max-width: 100%;
    }

    .date-moment {
        display: grid;
        grid-template-columns: 300px 1fr;
        gap: 2.5rem;
        align-items: center;
        margin-bottom: 4rem;
    }

    .date-moment.reverse {
        grid-template-columns: 1fr 300px;
    }

    .date-moment.reverse .moment-image {
        order: 2;
    }

    .moment-image {
        margin-bottom: 0;
    }

    .proposal-question {
        font-size: 3rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }

    .letter-container {
        padding: 3rem;
    }

    .handwritten.highlight {
        font-size: 1.7rem;
    }

    .handwritten.large {
        font-size: 1.8rem;
    }
}

/* =====================
   DESKTOP STYLES (1024px+)
   ===================== */
@media (min-width: 1024px) {
    .hero-title {
        font-size: 6rem;
    }

    .story-section {
        padding: 8rem 4rem;
    }

    .chapter-title {
        font-size: 3.2rem;
    }

    .story-content {
        max-width: 1000px;
        gap: 4rem;
    }

    .story-text p {
        font-size: 1.15rem;
    }

    .date-moment {
        grid-template-columns: 350px 1fr;
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
    }

    .date-moment.reverse {
        grid-template-columns: 1fr 350px;
    }

    .proposal-content {
        max-width: 700px;
    }

    .proposal-question {
        font-size: 3.5rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }

    .gallery-item {
        border-radius: 15px;
    }

    .letter-container {
        max-width: 700px;
        padding: 4rem;
    }

    .lightbox img {
        max-width: 85%;
        max-height: 85vh;
    }
}

/* =====================
   LARGE SCREENS (1400px+)
   ===================== */
@media (min-width: 1400px) {
    .story-content {
        max-width: 1100px;
    }

    .gallery-grid {
        max-width: 1200px;
    }
}
