/* ===== CSS Variables & Design System ===== */
:root {
    /* Romantic Color Palette */
    --color-primary: #ff6b9d;
    --color-primary-light: #ffb3d9;
    --color-primary-dark: #c9184a;
    --color-secondary: #ffd700;
    --color-accent: #ff8fab;

    /* Neutrals */
    --color-bg: #fff5f8;
    --color-bg-dark: #1a1a2e;
    --color-text: #2d2d2d;
    --color-text-light: #666;
    --color-white: #ffffff;

    /* Gradients */
    --gradient-romantic: linear-gradient(135deg, #ff6b9d 0%, #ffc3a0 100%);
    --gradient-sunset: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #ffdde1 100%);
    --gradient-overlay: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.7) 100%);
    --overlay-hero: rgba(0, 0, 0, 0.6);

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Poppins', sans-serif;
    --font-script: 'Great Vibes', cursive;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;

    /* Effects */
    --shadow-sm: 0 2px 8px rgba(255, 107, 157, 0.1);
    --shadow-md: 0 4px 20px rgba(255, 107, 157, 0.2);
    --shadow-lg: 0 8px 40px rgba(255, 107, 157, 0.3);
    --blur-glass: blur(10px);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
}

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

.hidden {
    display: none !important;
}

/* ===== Typography ===== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

.script-text {
    font-family: var(--font-script);
    font-weight: 400;
}

/* ===== PIN Entry Screen ===== */
.pin-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--gradient-sunset);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.5s ease;
}

.pin-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: var(--blur-glass);
    padding: var(--spacing-lg);
    border-radius: 30px;
    box-shadow: var(--shadow-lg);
    text-align: center;
    max-width: 400px;
    width: 90%;
    animation: slideUp 0.6s ease;
}

.pin-header h1 {
    font-size: 3.5rem;
    color: var(--color-primary);
    margin-bottom: var(--spacing-sm);
}

.heart-icon {
    font-size: 3rem;
    animation: heartbeat 1.5s ease infinite;
}

.pin-hint {
    color: var(--color-text-light);
    font-size: 0.95rem;
    margin: var(--spacing-md) 0;
    font-style: italic;
}

.pin-form {
    margin-top: var(--spacing-md);
}

.pin-input {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1.1rem;
    border: 2px solid var(--color-primary-light);
    border-radius: 50px;
    outline: none;
    font-family: var(--font-body);
    text-align: center;
    transition: var(--transition);
    letter-spacing: 0.5rem;
}

.pin-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(255, 107, 157, 0.1);
}

.pin-button {
    width: 100%;
    padding: 1rem 2rem;
    margin-top: var(--spacing-md);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-white);
    background: var(--gradient-romantic);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font-body);
    box-shadow: var(--shadow-md);
}

.pin-button:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.pin-button:active {
    transform: translateY(0);
}

.pin-error {
    color: var(--color-primary-dark);
    margin-top: var(--spacing-sm);
    font-size: 0.9rem;
    min-height: 1.5rem;
}

/* ===== Main Content ===== */
.main-content {
    animation: fadeIn 0.8s ease;
}

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

.hero-image-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--overlay-hero);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--color-white);
    padding: var(--spacing-md);
}

.hero-title {
    font-size: clamp(3rem, 8vw, 6rem);
    margin-bottom: var(--spacing-sm);
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease 0.2s both;
}

.hero-subtitle {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    font-weight: 300;
    margin-bottom: var(--spacing-md);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease 0.4s both;
}

.heart-divider {
    font-size: 2rem;
    animation: fadeInUp 1s ease 0.6s both, heartbeat 2s ease infinite;
}

/* ===== Section Styles ===== */
.section {
    padding: var(--spacing-xl) var(--spacing-md);
}

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

.section-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    text-align: center;
    color: var(--color-primary);
    margin-bottom: var(--spacing-md);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--gradient-romantic);
    margin: var(--spacing-sm) auto 0;
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-light);
    font-size: 1.1rem;
    margin-bottom: var(--spacing-lg);
}

/* ===== Our Story Section ===== */
.our-story {
    background: var(--color-white);
}

.story-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    align-items: start;
}

.story-text h3 {
    color: var(--color-primary);
    font-size: 2rem;
    margin-bottom: var(--spacing-md);
}

.story-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--color-text);
}

.story-timeline {
    position: relative;
    padding-left: var(--spacing-md);
}

.story-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient-romantic);
}

.timeline-item {
    position: relative;
    margin-bottom: var(--spacing-lg);
}

.timeline-dot {
    position: absolute;
    left: -2.2rem;
    top: 0.5rem;
    width: 20px;
    height: 20px;
    background: var(--color-primary);
    border-radius: 50%;
    border: 4px solid var(--color-white);
    box-shadow: 0 0 0 4px var(--color-primary-light);
}

.timeline-content h4 {
    color: var(--color-primary-dark);
    font-size: 1.3rem;
    margin-bottom: var(--spacing-xs);
}

.timeline-content p {
    color: var(--color-text-light);
}

/* ===== Memories Gallery ===== */
.memories-gallery {
    background: var(--color-bg);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.gallery-item {
    position: relative;
    aspect-ratio: 3/4;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.gallery-item:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.gallery-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: var(--transition);
}

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

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--gradient-overlay);
    color: var(--color-white);
    padding: var(--spacing-md);
    transform: translateY(100%);
    transition: var(--transition);
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-xs);
}

.gallery-overlay p {
    font-size: 0.95rem;
    opacity: 0.9;
}

/* ===== Reasons Section ===== */
.reasons-section {
    background: var(--color-white);
}

.reasons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.reason-card {
    background: var(--gradient-sunset);
    padding: var(--spacing-lg);
    border-radius: 20px;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.reason-card:hover {
    transform: translateY(-10px) rotate(2deg);
    box-shadow: var(--shadow-lg);
}

.reason-number {
    font-family: var(--font-script);
    font-size: 3rem;
    color: var(--color-primary-dark);
    margin-bottom: var(--spacing-sm);
}

.reason-card h3 {
    font-size: 1.5rem;
    color: var(--color-primary-dark);
    margin-bottom: var(--spacing-sm);
}

.reason-card p {
    color: var(--color-text);
    line-height: 1.6;
}

/* ===== Future Dreams ===== */
.future-dreams {
    background: var(--color-bg);
}

.dreams-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    align-items: center;
    margin-top: var(--spacing-lg);
}

.dream-image {
    aspect-ratio: 4/3;
    border-radius: 20px;
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow-md);
}

.dreams-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.dream-item {
    display: flex;
    gap: var(--spacing-md);
    align-items: start;
    background: var(--color-white);
    padding: var(--spacing-md);
    border-radius: 15px;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.dream-item:hover {
    transform: translateX(10px);
    box-shadow: var(--shadow-md);
}

.dream-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.dream-item h3 {
    color: var(--color-primary);
    font-size: 1.3rem;
    margin-bottom: var(--spacing-xs);
}

.dream-item p {
    color: var(--color-text-light);
}

/* ===== Love Letter ===== */
.love-letter {
    background: var(--color-white);
}

.letter-container {
    max-width: 800px;
    margin: 0 auto;
    background: linear-gradient(145deg, #fff 0%, #fff5f8 100%);
    padding: var(--spacing-xl);
    border-radius: 20px;
    box-shadow: var(--shadow-md);
    border: 2px solid var(--color-primary-light);
}

.letter-container h2 {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.letter-content p {
    font-size: 1.15rem;
    line-height: 1.9;
    color: var(--color-text);
    margin-bottom: var(--spacing-md);
}

.letter-signature {
    margin-top: var(--spacing-lg);
    font-style: italic;
    color: var(--color-text-light);
}

.letter-signature span {
    font-size: 2rem;
    color: var(--color-primary);
    display: block;
    margin-top: var(--spacing-sm);
}

/* ===== Footer ===== */
.footer {
    background: var(--color-bg-dark);
    color: var(--color-white);
    text-align: center;
    padding: var(--spacing-lg);
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heartbeat {

    0%,
    100% {
        transform: scale(1);
    }

    10%,
    30% {
        transform: scale(1.1);
    }

    20%,
    40% {
        transform: scale(1);
    }
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {

    .story-content,
    .dreams-content {
        grid-template-columns: 1fr;
    }

    .section {
        padding: var(--spacing-lg) var(--spacing-md);
    }

    .pin-container {
        padding: var(--spacing-md);
    }

    .pin-header h1 {
        font-size: 2.5rem;
    }

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

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

    .letter-container {
        padding: var(--spacing-md);
    }
}

/* ===== Content Protection ===== */
img,
.gallery-image,
.hero-image,
.dream-image {
    user-select: none;
    -webkit-user-drag: none;
    -webkit-touch-callout: none;
}

/* CSS for Actual Images in Gallery */
.actual-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

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

/* Ensure container hides overflow */
.gallery-image {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
    /* Remove background size/pos since we use img now, but keep for fallback */
}/* ===== Relationship Timer ===== */
.relationship-timer {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-xs);
}

.timer-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--gradient-romantic);
    padding: 0.5rem;
    border-radius: 10px;
    min-width: 60px;
    color: var(--color-white);
    box-shadow: var(--shadow-sm);
}

.timer-value {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1;
}

.timer-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    margin-top: 2px;
    opacity: 0.9;
}