/* === Reset & Base === */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-bg-dark: #1a1a2e;
    --color-bg-darker: #16213e;
    --color-bg-light: #fdf6f0;
    --color-bg-warm: #fff5eb;
    --color-accent: #e94560;
    --color-accent-light: #ff6b81;
    --color-gold: #d4a853;
    --color-gold-light: #f0d48a;
    --color-text-dark: #2d2d2d;
    --color-text-light: #f0f0f0;
    --color-text-muted: #888;
    --font-main: 'Inter', -apple-system, 'Segoe UI', sans-serif;
    --transition: 0.3s ease;
}

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

body {
    font-family: var(--font-main);
    color: var(--color-text-dark);
    background: var(--color-bg-light);
    overflow-x: hidden;
    line-height: 1.7;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

/* === Particles === */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.particle {
    position: absolute;
    background: var(--color-accent);
    border-radius: 50%;
    opacity: 0.15;
    animation: float linear infinite;
}

@keyframes float {
    0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
    10% { opacity: 0.15; }
    90% { opacity: 0.15; }
    100% { transform: translateY(-10vh) rotate(720deg); opacity: 0; }
}

/* === Hero === */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(26, 26, 46, 0.92) 0%,
        rgba(22, 33, 62, 0.85) 50%,
        rgba(26, 26, 46, 0.7) 100%
    );
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
    padding: 2rem;
    text-align: center;
}

.hero-names {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-gold-light);
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.hero-names .heart {
    color: var(--color-accent);
    display: inline-block;
    animation: pulse 1.5s ease infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.hero-pre {
    font-size: 1.1rem;
    color: var(--color-gold-light);
    margin-bottom: 1.5rem;
    font-style: italic;
    opacity: 0.8;
}

.hero-title {
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.title-line {
    display: block;
    font-size: 2.8rem;
    color: white;
    line-height: 1.2;
}

.title-line.accent {
    color: var(--color-accent);
    font-size: 3.5rem;
    font-style: italic;
}

.hero-divider {
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--color-accent), var(--color-gold));
    margin: 0 auto 1.5rem;
}

.hero-text {
    color: rgba(255,255,255,0.85);
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

.hero-btn {
    display: block;
    width: fit-content;
    margin: 2rem auto 4rem;
    position: relative;
    z-index: 3;
    padding: 0.9rem 2.5rem;
    background: var(--color-accent);
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    border-radius: 50px;
    transition: all var(--transition);
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.4);
}

.hero-btn:hover {
    background: var(--color-accent-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 69, 96, 0.5);
}

.hero-couple-img {
    position: relative;
    z-index: 2;
    width: 250px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    border: 3px solid rgba(255,255,255,0.2);
    margin-top: 1.5rem;
}

.hero-couple-img img {
    width: 100%;
}

/* === Sections === */
.section {
    position: relative;
    padding: 5rem 0;
    z-index: 1;
}

.section-light {
    background: var(--color-bg-light);
}

.section-dark {
    background: var(--color-bg-dark);
    color: var(--color-text-light);
}

.section-warm {
    background: var(--color-bg-warm);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    font-weight: 400;
    color: var(--color-gold);
    margin-top: 0.3rem;
}

.section-header {
    text-align: center;
    margin-bottom: 1rem;
}

.section-number {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--color-accent);
    opacity: 0.3;
    display: block;
    line-height: 1;
}

.divider {
    width: 60px;
    height: 3px;
    background: var(--color-accent);
    margin: 1rem auto 2.5rem;
}

.divider-light {
    background: var(--color-gold);
}

/* === Instructions === */
.instructions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.instruction-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    box-shadow: 0 3px 15px rgba(0,0,0,0.08);
    transition: transform var(--transition), box-shadow var(--transition);
    display: flex;
    gap: 1rem;
    align-items: start;
}

.instruction-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.instruction-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.instruction-card p {
    font-size: 0.95rem;
    line-height: 1.6;
}

.photo-collage {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 0.8rem;
    height: 100%;
    min-height: 350px;
}

.collage-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    cursor: pointer;
    transition: transform var(--transition);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.collage-img:hover {
    transform: scale(1.03);
}

/* === Challenge Text Full Width === */
.challenge-text-full {
    max-width: 800px;
    margin: 0 auto 2.5rem;
}

.challenge-text-full p {
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

.text-muted {
    color: var(--color-text-muted);
    font-style: italic;
    font-size: 0.95rem !important;
}

.section-dark .text-muted {
    color: rgba(255,255,255,0.5);
}

.text-accent {
    color: var(--color-accent);
    font-weight: 700;
}

/* === Grid Title === */
.grid-title {
    font-size: 1.3rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--color-gold);
}

.section-warm .grid-title {
    color: var(--color-accent);
}

/* === Photos Vertical (all game photos) === */
.photos-vertical {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 900px;
    margin: 0 auto;
}

.photos-vertical img {
    width: 100%;
    border-radius: 12px;
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.section-dark .photos-vertical img {
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.photos-vertical img:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.bonus-photo {
    position: relative;
    grid-column: 1 / -1;
}

.bonus-photo img {
    width: 100%;
    border-radius: 12px;
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.bonus-photo img:hover {
    transform: scale(1.02);
}

.bonus-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--color-accent);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    z-index: 5;
    box-shadow: 0 3px 10px rgba(233, 69, 96, 0.4);
}

/* === Final Section === */
.section-final {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.final-bg {
    position: absolute;
    inset: 0;
}

.final-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.final-overlay {
    position: absolute;
    inset: 0;
    background: rgba(26, 26, 46, 0.85);
}

.final-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
}

.final-title {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.final-text {
    font-size: 1.15rem;
    max-width: 600px;
    margin: 0 auto 1.5rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.8;
}

.final-wish {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--color-gold-light);
    margin-top: 1rem;
}

.final-photos-vertical {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-top: 2.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.final-photos-vertical img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 6px 25px rgba(0,0,0,0.4);
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
    border: 2px solid rgba(255,255,255,0.1);
}

.final-photos-vertical img:hover {
    transform: scale(1.02);
    box-shadow: 0 10px 35px rgba(0,0,0,0.5);
    border-color: var(--color-gold);
}

/* === Lightbox === */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.95);
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-content img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    font-size: 2.5rem;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10000;
    transition: color var(--transition);
    line-height: 1;
}

.lightbox-close:hover {
    color: var(--color-accent);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem;
    color: white;
    background: rgba(255,255,255,0.1);
    border: none;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: background var(--transition);
    z-index: 10000;
}

.lightbox-prev { left: 1.5rem; }
.lightbox-next { right: 1.5rem; }

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(233, 69, 96, 0.5);
}

/* === Animations === */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* === Responsive === */
@media (max-width: 1024px) {
    .title-line { font-size: 2.2rem; }
    .title-line.accent { font-size: 2.8rem; }
}

@media (max-width: 768px) {
    .hero {
        flex-direction: column;
        justify-content: center;
    }

    .hero-content {
        padding: 3rem 1.5rem 2rem;
        max-width: 100%;
    }

    .hero-names { font-size: 2.2rem; }
    .title-line { font-size: 1.8rem; }
    .title-line.accent { font-size: 2.2rem; }

    .hero-couple-img {
        width: 200px;
    }

    .hero-pre {
        font-size: 1rem;
    }

    .section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .instructions-grid {
        grid-template-columns: 1fr;
    }

    .photo-collage {
        min-height: 250px;
    }

    .photos-vertical {
        grid-template-columns: 1fr;
    }

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

    .final-wish {
        font-size: 1.2rem;
    }

    .lightbox-prev,
    .lightbox-next {
        font-size: 2rem;
        padding: 0.3rem 0.6rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .title-line { font-size: 1.5rem; }
    .title-line.accent { font-size: 1.8rem; }

    .hero-names { font-size: 1.8rem; }
    .section-number { font-size: 2.5rem; }
    .section-title { font-size: 1.4rem; }

    .instruction-card {
        flex-direction: column;
        text-align: center;
    }

    .hero-btn {
        padding: 0.7rem 1.8rem;
        font-size: 1rem;
    }
}
