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

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    min-height: 100%;
    overflow-x: hidden;
}

:root {
    /* Màu sắc truyền thống Việt Nam - nâng cấp */
    --primary-red: #b91c3c;
    --primary-red-dark: #8b1538;
    --primary-red-light: #dc3545;
    --gold: #d4a537;
    --gold-light: #e8c252;
    --gold-dark: #b8960c;
    --gold-gradient: linear-gradient(135deg, #d4a537 0%, #f4d03f 50%, #d4a537 100%);
    --cream: #fef9f0;
    --cream-dark: #f5e6c8;
    --text-dark: #3d1a1a;
    --text-light: #6b3030;
    --white: #ffffff;
    --black: #1a0505;
    --shadow-soft: 0 10px 40px rgba(139, 21, 56, 0.15);
    --shadow-gold: 0 5px 30px rgba(212, 165, 55, 0.3);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: linear-gradient(135deg, var(--cream) 0%, var(--cream-dark) 100%);
    overflow-x: hidden;
}

.hidden {
    display: none !important;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== HIỆU ỨNG TRÁI TIM NHỊP ĐẬP ===== */
.heart {
    position: fixed;
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23e63946'%3E%3Cpath d='M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    filter: drop-shadow(0 2px 4px rgba(230, 57, 70, 0.4));
    animation: heartPulse 2s ease-in-out forwards;
}

.heart.pink {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ff6b9d'%3E%3Cpath d='M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z'/%3E%3C/svg%3E");
}

.heart.gold {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23d4a537'%3E%3Cpath d='M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z'/%3E%3C/svg%3E");
}

@keyframes heartPulse {
    0% {
        opacity: 0;
        transform: scale(0);
    }
    20% {
        opacity: 1;
        transform: scale(1);
    }
    40% {
        transform: scale(1.3);
    }
    60% {
        transform: scale(1);
    }
    80% {
        transform: scale(1.2);
        opacity: 1;
    }
    100% {
        transform: scale(0);
        opacity: 0;
    }
}

/* ===== WELCOME SCREEN - THIỆP MỜI MỞ RA ===== */
.welcome-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    perspective: 2000px;
    background: linear-gradient(135deg, #8b0000 0%, #5c0000 100%);
}

/* Welcome Info - hiển thị chính giữa, phía sau thiệp */
.welcome-info {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 0;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.welcome-info.visible {
    opacity: 1;
}

.welcome-date {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    color: var(--gold);
    letter-spacing: 5px;
    margin-bottom: 10px;
}

.welcome-names {
    font-family: 'Dancing Script', cursive;
    font-size: 2.2rem;
    color: var(--gold-light);
    margin-bottom: 25px;
    white-space: nowrap;
}

.welcome-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(212, 175, 55, 0.3);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    letter-spacing: 2px;
}

/* Container thiệp */
.envelope-container {
    position: relative;
    width: 90vw;
    max-width: 350px;
    height: 70vh;
    max-height: 500px;
    transform-style: preserve-3d;
}

/* Phần bìa thiệp (2 cánh) */
.envelope-left,
.envelope-right {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    transition: transform 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    backface-visibility: hidden;
    border: 3px solid var(--gold);
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
    overflow: hidden;
}

.envelope-left {
    left: 0;
    transform-origin: left center;
    border-radius: 10px 0 0 10px;
    border-right: none;
}

.envelope-right {
    right: 0;
    transform-origin: right center;
    border-radius: 0 10px 10px 0;
    border-left: none;
}

/* Hoa văn trên bìa thiệp */
.envelope-left::before,
.envelope-right::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23d4af37' fill-opacity='0.15'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* Chữ Song Hỷ trên bìa - MÀU ĐỎ ĐẬM trên nền vàng */
.envelope-left .half-hy,
.envelope-right .half-hy {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 8rem;
    color: var(--primary-red-dark);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 50%, var(--gold) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(2px 2px 3px rgba(0,0,0,0.3));
}

.envelope-left .half-hy {
    right: -20px;
    clip-path: inset(0 50% 0 0);
}

.envelope-right .half-hy {
    left: -20px;
    clip-path: inset(0 0 0 50%);
}

/* Viền vàng trang trí */
.envelope-left::after,
.envelope-right::after {
    content: '';
    position: absolute;
    top: 20px;
    bottom: 20px;
    width: 3px;
    background: linear-gradient(to bottom, transparent, var(--gold), transparent);
}

.envelope-left::after {
    right: 0;
}

.envelope-right::after {
    left: 0;
}

/* Trạng thái mở thiệp */
.envelope-container.opened .envelope-left {
    transform: rotateY(-160deg);
}

.envelope-container.opened .envelope-right {
    transform: rotateY(160deg);
}

/* Nội dung bên trong thiệp */
.envelope-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--cream) 0%, #fff 50%, var(--cream) 100%);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    text-align: center;
    box-shadow: inset 0 0 50px rgba(196, 30, 58, 0.1);
    border: 2px solid var(--gold);
}

.envelope-content::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 1px solid var(--gold);
    border-radius: 5px;
    pointer-events: none;
}

/* Chữ Song Hỷ bên trong - MÀU ĐỎ truyền thống */
.inner-double-happiness {
    font-size: 4rem;
    color: var(--primary-red);
    font-family: 'Ma Shan Zheng', cursive;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(196, 30, 58, 0.3);
}

.inner-title {
    font-family: 'Dancing Script', cursive;
    font-size: 1.8rem;
    color: var(--primary-red);
    margin-bottom: 10px;
    white-space: nowrap;
}

.inner-subtitle {
    font-size: 0.9rem;
    color: var(--text-light);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.name-input-wrapper {
    width: 100%;
    margin-bottom: 20px;
}

#guest-name {
    width: 100%;
    padding: 12px 20px;
    font-size: 1rem;
    border: 2px solid var(--primary-red);
    border-radius: 50px;
    background: var(--white);
    text-align: center;
    font-family: 'Montserrat', sans-serif;
    transition: all 0.3s ease;
    color: var(--text-dark);
}

#guest-name:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

#guest-name.shake {
    animation: shake 0.5s ease;
    border-color: var(--primary-red-light);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.name-hint {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 8px;
}

.enter-btn {
    padding: 12px 35px;
    font-size: 0.95rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    border: 2px solid var(--gold);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 1px;
}

.enter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(196, 30, 58, 0.4);
}

/* Ẩn welcome screen sau khi mở */
.welcome-screen.fade-out {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

/* ===== MAIN INVITATION ===== */
.main-invitation {
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
}

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

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

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

/* ===== COVER SECTION ===== */
.cover-section {
    position: relative;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('../images2/2429421820728032246 (2).jpg') center center / cover no-repeat;
    background-color: var(--primary-red);
    background-attachment: fixed;
    margin: 0;
    padding: 0;
}

.cover-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg,
        rgba(139, 21, 56, 0.3) 0%,
        rgba(61, 26, 26, 0.5) 50%,
        rgba(139, 21, 56, 0.4) 100%);
}

.cover-content {
    position: relative;
    text-align: center;
    color: var(--white);
    padding: 40px;
    animation: fadeInUp 1.2s ease-out;
}

/* Chữ Song Hỷ trên cover */
.cover-double-happiness {
    font-size: 5rem;
    color: var(--gold);
    font-family: 'Ma Shan Zheng', cursive;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    padding: 15px 30px;
    display: inline-block;
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    /* Bo tròn và cách điệu - nền đỏ đậm */
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    border-radius: 50%;
    width: 110px;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid var(--gold);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4),
                0 0 20px rgba(212, 165, 55, 0.4),
                inset 0 2px 10px rgba(255, 255, 255, 0.1);
    animation: floatHy 3s ease-in-out infinite;
}

@keyframes floatHy {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(-8px);
    }
}

.save-the-date {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.2rem, 4vw, 1.8rem);
    letter-spacing: clamp(6px, 3vw, 14px);
    text-transform: uppercase;
    margin-bottom: 15px;
    color: var(--gold-light);
    position: relative;
    display: inline-block;
    font-weight: 600;
}

.save-the-date::before,
.save-the-date::after {
    content: '✦';
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gold);
    font-size: 0.5rem;
}

.save-the-date::before { left: -20px; }
.save-the-date::after { right: -20px; }

.couple-names {
    font-family: 'Dancing Script', cursive;
    font-size: clamp(1.8rem, 8vw, 3.2rem);
    font-weight: 700;
    margin-bottom: 15px;
    text-shadow: 2px 2px 20px rgba(0,0,0,0.4);
    color: var(--white);
    white-space: nowrap;
    position: relative;
}

.couple-names span {
    font-size: clamp(1.4rem, 5vw, 2.2rem);
    margin: 0 10px;
    color: var(--gold);
    display: inline-block;
    animation: heartBeat 2s ease-in-out infinite;
}

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

.wedding-date-header {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.1rem, 4vw, 1.6rem);
    font-weight: 700;
    letter-spacing: clamp(4px, 2vw, 8px);
    color: var(--white);
    position: relative;
    padding: 12px 25px;
    border: 2px solid var(--gold);
    display: inline-block;
    margin-top: 10px;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    background: rgba(0, 0, 0, 0.2);
}

/* Cover Ornaments */
.cover-ornament {
    position: absolute;
    width: 120px;
    height: 120px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M50 5 Q60 20 75 25 Q60 30 50 50 Q40 30 25 25 Q40 20 50 5' fill='%23d4af37' opacity='0.6'/%3E%3Cpath d='M50 15 Q55 25 65 28 Q55 31 50 40 Q45 31 35 28 Q45 25 50 15' fill='%23f4d03f' opacity='0.8'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0.5;
    pointer-events: none;
}

.cover-ornament.top-left {
    top: 20px;
    left: 20px;
    transform: rotate(-45deg);
}

.cover-ornament.top-right {
    top: 20px;
    right: 20px;
    transform: rotate(45deg);
}

.cover-ornament.bottom-left {
    bottom: 20px;
    left: 20px;
    transform: rotate(-135deg);
}

.cover-ornament.bottom-right {
    bottom: 20px;
    right: 20px;
    transform: rotate(135deg);
}

/* Countdown */
.countdown-wrapper {
    display: flex;
    justify-content: center;
    gap: 8px;
    position: absolute;
    bottom: 110px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid rgba(212, 165, 55, 0.4);
    min-width: 55px;
}

.countdown-number {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.2rem, 4vw, 1.8rem);
    font-weight: 700;
    color: var(--gold-light);
    line-height: 1;
}

.countdown-label {
    font-size: clamp(0.5rem, 1.5vw, 0.65rem);
    color: rgba(255, 255, 255, 0.85);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 4px;
}

/* Music Toggle Button */
.music-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    border: 2px solid var(--gold);
    cursor: pointer;
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.music-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.music-icon {
    color: var(--gold);
    font-size: 1.5rem;
}

.music-toggle.playing .music-icon {
    display: none;
}

.music-bars {
    display: none;
    align-items: flex-end;
    gap: 3px;
    height: 20px;
}

.music-toggle.playing .music-bars {
    display: flex;
}

.music-bars span {
    width: 4px;
    background: var(--gold);
    border-radius: 2px;
    animation: musicBar 0.8s ease infinite;
}

.music-bars span:nth-child(1) {
    height: 8px;
    animation-delay: 0s;
}

.music-bars span:nth-child(2) {
    height: 16px;
    animation-delay: 0.2s;
}

.music-bars span:nth-child(3) {
    height: 12px;
    animation-delay: 0.4s;
}

@keyframes musicBar {
    0%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.5); }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: var(--gold-light);
    animation: bounce 2s infinite;
    cursor: pointer;
    z-index: 100;
    transition: opacity 0.3s ease;
}

.scroll-indicator span {
    font-size: 0.85rem;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 8px;
}

.scroll-arrow {
    width: 24px;
    height: 24px;
    margin: 0 auto;
    border-right: 2px solid var(--gold-light);
    border-bottom: 2px solid var(--gold-light);
    transform: rotate(45deg);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* ===== INVITATION MESSAGE ===== */
.invitation-message {
    padding: 60px 20px;
    background: linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Ảnh nền mờ cho section lời mời */
.invitation-message::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2429421820728032246 (6).jpg') center center / cover no-repeat;
    opacity: 0.06;
    pointer-events: none;
}

/* Decorative corners */
.invitation-message::after {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    bottom: 20px;
    border: 1px solid rgba(212, 165, 55, 0.3);
    pointer-events: none;
}

.ornament {
    font-size: 2.5rem;
    color: var(--primary-red);
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

/* Chữ Song Hỷ nhỏ */
.song-hy-small {
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 3rem;
    color: var(--primary-red);
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
    display: inline-block;
    padding: 0 30px;
}

.song-hy-small::before,
.song-hy-small::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 50px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.song-hy-small::before { right: 100%; }
.song-hy-small::after { left: 100%; }

.greeting {
    font-family: 'Dancing Script', cursive;
    font-size: 1.6rem;
    color: var(--primary-red);
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
}

#guest-display {
    font-weight: 700;
    color: var(--primary-red-dark);
    font-size: 1.8rem;
}

.message-text {
    font-size: 1.05rem;
    line-height: 2.2;
    max-width: 550px;
    margin: 0 auto;
    color: var(--text-light);
    position: relative;
    z-index: 1;
    font-style: italic;
}

/* ===== SECTION TITLE ===== */
.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--primary-red);
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    letter-spacing: 2px;
}

.section-title::before {
    content: '✦';
    display: block;
    font-size: 1rem;
    color: var(--gold);
    margin-bottom: 10px;
}

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


/* ===== COUPLE SECTION ===== */
.couple-section {
    padding: 50px 15px;
    background: linear-gradient(180deg, var(--cream) 0%, var(--white) 50%, var(--cream) 100%);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho couple section */
.couple-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2482208456212628373 (2).jpg') center center / cover no-repeat;
    opacity: 0.05;
    pointer-events: none;
}

/* Single Photo Layout */
.couple-wrapper-single {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
    position: relative;
    z-index: 1;
}

.couple-photo-single {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid var(--gold);
    box-shadow: 0 15px 50px rgba(139, 21, 56, 0.25),
                0 0 0 10px rgba(212, 165, 55, 0.1),
                0 0 0 15px rgba(139, 21, 56, 0.05);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.couple-photo-single:hover {
    transform: scale(1.03);
    box-shadow: 0 20px 60px rgba(139, 21, 56, 0.3),
                0 0 0 12px rgba(212, 165, 55, 0.15),
                0 0 0 18px rgba(139, 21, 56, 0.08);
}

.couple-photo-single img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 20%;
    transition: transform 0.4s ease;
}

.couple-photo-single:hover img {
    transform: scale(1.1);
}

.couple-names-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.couple-name-item {
    text-align: center;
}

.couple-name-item h3 {
    font-family: 'Dancing Script', cursive;
    font-size: 1.8rem;
    color: var(--primary-red);
    margin-bottom: 5px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.couple-heart {
    font-size: 2rem;
    color: var(--primary-red);
    animation: pulse 1.5s ease infinite;
    text-shadow: 0 5px 20px rgba(139, 21, 56, 0.3);
}

.person-role {
    font-size: 0.8rem;
    color: var(--gold-dark);
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 500;
}

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

/* ===== FAMILY SECTION ===== */
.family-section {
    padding: 50px 15px;
    background: var(--white);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho family section */
.family-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2429421820728032246 (4).jpg') center center / cover no-repeat;
    opacity: 0.05;
    pointer-events: none;
}

/* Chữ Song Hỷ watermark */
.family-section::after {
    content: '囍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12rem;
    color: var(--primary-red);
    opacity: 0.03;
    font-family: 'Ma Shan Zheng', cursive;
    pointer-events: none;
}

.family-wrapper {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 0;
    flex-wrap: nowrap;
    position: relative;
    z-index: 1;
    max-width: 450px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 10px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(212, 165, 55, 0.2);
}

.family {
    text-align: center;
    flex: 1;
    min-width: 0;
    padding: 25px 20px;
    background: transparent;
    position: relative;
}

.family h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    color: var(--gold-dark);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.family h3::after {
    content: '';
    display: block;
    width: 30px;
    height: 2px;
    background: var(--gold-gradient);
    margin: 10px auto 0;
}

.parent-name {
    font-family: 'Dancing Script', cursive;
    font-size: 1.3rem;
    color: var(--primary-red);
    line-height: 1.8;
    font-weight: 600;
}

.family-divider {
    width: 1px;
    background: linear-gradient(to bottom, transparent, var(--gold), var(--gold), transparent);
    align-self: stretch;
    margin: 15px 0;
    position: relative;
}

.family-divider::before {
    content: '♥';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--primary-red);
    font-size: 0.9rem;
    background: var(--white);
    padding: 8px;
    border-radius: 50%;
}

/* ===== EVENT SECTION ===== */
.event-section {
    padding: 60px 20px;
    background: linear-gradient(160deg, var(--primary-red) 0%, var(--primary-red-dark) 60%, #5c1025 100%);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho event section */
.event-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2482208456212628373.jpg') center center / cover no-repeat;
    opacity: 0.12;
    pointer-events: none;
}

/* Decorative pattern */
.event-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 20% 80%, rgba(212, 165, 55, 0.1) 0%, transparent 50%),
                      radial-gradient(circle at 80% 20%, rgba(212, 165, 55, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.event-section .section-title {
    color: var(--gold);
}

.event-section .section-title::before {
    display: none;
}

/* Event Compact Layout */
.event-compact {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
    padding: 0;
    position: relative;
    z-index: 1;
}

.event-date-big {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 25px 40px;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    margin-bottom: 10px;
    border: 1px solid rgba(212, 165, 55, 0.3);
    position: relative;
}

.event-date-big::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 20%;
    right: 20%;
    height: 3px;
    background: var(--gold-gradient);
    border-radius: 3px;
}

.event-date-big .day {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.event-date-big .month {
    font-size: 1.1rem;
    color: var(--gold-light);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-top: 8px;
}

.event-date-big .year {
    font-size: 1.2rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-top: 5px;
}

.event-info {
    text-align: center;
    background: rgba(255, 255, 255, 0.08);
    padding: 25px 30px;
    border-radius: 15px;
    backdrop-filter: blur(5px);
}

.event-info .event-lunar {
    font-size: 1rem;
    color: var(--gold-light);
    font-style: italic;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(212, 165, 55, 0.2);
}

.event-times {
    margin-bottom: 20px;
}

.event-times p {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.event-times strong {
    color: var(--gold);
    font-size: 1.15rem;
    font-family: 'Playfair Display', serif;
}

.event-location p {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    margin-bottom: 20px;
}

.map-link {
    display: inline-block;
    padding: 12px 30px;
    color: var(--primary-red-dark);
    background: var(--gold-gradient);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(212, 165, 55, 0.3);
}

.map-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(212, 165, 55, 0.5);
}

/* ===== CALENDAR SECTION ===== */
.calendar-section {
    padding: 40px 20px;
    background: var(--white);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho calendar section */
.calendar-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2482208456212628373 (5).jpg') center center / cover no-repeat;
    opacity: 0.05;
    pointer-events: none;
}

.calendar {
    max-width: 400px;
    margin: 0 auto;
    background: rgba(255,255,255,0.95);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 40px rgba(196, 30, 58, 0.15);
    border: 2px solid var(--gold);
    position: relative;
    z-index: 1;
}

.calendar-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.calendar-day-name {
    text-align: center;
    font-weight: 600;
    color: var(--primary-red);
    padding: 10px 0;
    font-size: 0.85rem;
}

.calendar-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.calendar-day {
    text-align: center;
    padding: 12px 0;
    border-radius: 50%;
    font-size: 0.95rem;
    color: var(--text-dark);
    transition: all 0.3s ease;
}

.calendar-day.empty {
    visibility: hidden;
}

.calendar-day.wedding-day {
    background: transparent;
    color: var(--white);
    font-weight: 700;
    position: relative;
    z-index: 1;
    border-radius: 0;
}

.calendar-day.wedding-day::before {
    content: '♥';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3.5rem;
    color: var(--primary-red);
    z-index: -1;
    text-shadow: 0 3px 10px rgba(196, 30, 58, 0.5);
    animation: heartBeat-calendar 1.5s ease infinite;
}

@keyframes heartBeat-calendar {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.15);
    }
}

/* ===== GALLERY SECTION ===== */
.gallery-section {
    padding: 50px 20px;
    background: linear-gradient(180deg, var(--cream) 0%, var(--white) 50%, var(--cream) 100%);
}

.gallery-grid {
    column-count: 2;
    column-gap: 12px;
    max-width: 520px;
    margin: 0 auto;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    cursor: pointer;
    opacity: 0;
    transform: scale(0.9) translateY(20px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    border: 3px solid transparent;
    background: linear-gradient(var(--white), var(--white)) padding-box,
                var(--gold-gradient) border-box;
    box-shadow: 0 8px 25px rgba(139, 21, 56, 0.1);
    margin-bottom: 12px;
    break-inside: avoid;
}

.gallery-item.animate-in {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease, filter 0.3s ease;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 60%, rgba(139, 21, 56, 0.4) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

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

.gallery-item:hover {
    box-shadow: 0 15px 40px rgba(139, 21, 56, 0.2);
    transform: translateY(-5px);
}

/* ===== ALBUM LIGHTBOX ===== */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.lightbox.active {
    display: flex;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 5, 5, 0.97);
}

.lightbox-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 1;
}

.lightbox-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(212, 165, 55, 0.2);
    border: 2px solid var(--gold);
    color: var(--gold);
    font-size: 2rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.lightbox-close:hover {
    background: var(--gold);
    color: var(--primary-red-dark);
    transform: scale(1.1);
}

.lightbox-main {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1200px;
    flex: 1;
    gap: 10px;
}

.lightbox-img-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    max-height: 70vh;
    overflow: hidden;
}

.lightbox-img-wrapper img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border: 4px solid var(--gold);
    border-radius: 10px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    animation: lightboxFadeIn 0.3s ease;
}

@keyframes lightboxFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.lightbox-prev,
.lightbox-next {
    background: rgba(212, 165, 55, 0.15);
    border: 2px solid var(--gold);
    color: var(--gold);
    font-size: 1.5rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: var(--gold);
    color: var(--primary-red-dark);
    transform: scale(1.1);
}

.lightbox-counter {
    color: var(--gold-light);
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    margin: 15px 0;
    letter-spacing: 3px;
}

.lightbox-counter span:first-child {
    color: var(--gold);
    font-weight: 700;
    font-size: 1.3rem;
}

/* Thumbnails */
.lightbox-thumbnails {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 15px 10px;
    max-width: 100%;
    scrollbar-width: thin;
    scrollbar-color: var(--gold) rgba(255, 255, 255, 0.1);
}

.lightbox-thumbnails::-webkit-scrollbar {
    height: 6px;
}

.lightbox-thumbnails::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.lightbox-thumbnails::-webkit-scrollbar-thumb {
    background: var(--gold);
    border-radius: 3px;
}

.lightbox-thumb {
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 3px solid transparent;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.lightbox-thumb:hover {
    opacity: 0.8;
    border-color: rgba(212, 165, 55, 0.5);
}

.lightbox-thumb.active {
    opacity: 1;
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(212, 165, 55, 0.5);
}

.lightbox-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .lightbox-container {
        padding: 10px;
    }

    .lightbox-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 1.5rem;
    }

    .lightbox-prev,
    .lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .lightbox-img-wrapper {
        max-height: 60vh;
    }

    .lightbox-img-wrapper img {
        max-height: 60vh;
        border-width: 3px;
    }

    .lightbox-thumb {
        width: 55px;
        height: 55px;
    }

    .lightbox-counter {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .lightbox-main {
        gap: 5px;
    }

    .lightbox-prev,
    .lightbox-next {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .lightbox-img-wrapper img {
        border-radius: 8px;
    }

    .lightbox-thumb {
        width: 50px;
        height: 50px;
        border-width: 2px;
    }

    .lightbox-thumbnails {
        gap: 8px;
        padding: 10px 5px;
    }
}

/* ===== RSVP SECTION ===== */
.rsvp-section {
    padding: 40px 20px;
    background: var(--white);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho RSVP section */
.rsvp-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2429421820728032246 (1).jpg') center center / cover no-repeat;
    opacity: 0.05;
    pointer-events: none;
}

/* Chữ Song Hỷ watermark - MÀU ĐỎ */
.rsvp-section::after {
    content: '囍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20rem;
    color: var(--primary-red);
    opacity: 0.03;
    font-family: 'Ma Shan Zheng', cursive;
    pointer-events: none;
}

.rsvp-form {
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

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

.form-group label {
    display: block;
    font-weight: 500;
    color: var(--primary-red);
    margin-bottom: 10px;
}

.form-group input[type="text"],
.form-group textarea {
    width: 100%;
    padding: 15px;
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    border: 2px solid var(--gold);
    border-radius: 10px;
    background: rgba(255,255,255,0.95);
    transition: all 0.3s ease;
    color: var(--text-dark);
}

.form-group input[type="text"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-red);
    box-shadow: 0 0 15px rgba(196, 30, 58, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.attendance-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.radio-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 15px;
    border: 2px solid var(--gold);
    border-radius: 10px;
    background: rgba(255,255,255,0.95);
    transition: all 0.3s ease;
}

.radio-option:hover {
    border-color: var(--primary-red);
    background: rgba(196, 30, 58, 0.05);
}

.radio-option:has(input:checked) {
    border-color: var(--primary-red);
    background: linear-gradient(135deg, rgba(196, 30, 58, 0.1) 0%, rgba(196, 30, 58, 0.05) 100%);
    box-shadow: 0 4px 15px rgba(196, 30, 58, 0.2);
    transform: scale(1.02);
}

.radio-option input {
    display: none;
}

.radio-custom {
    width: 24px;
    height: 24px;
    border: 2px solid var(--primary-red);
    border-radius: 50%;
    margin-right: 12px;
    position: relative;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.radio-option input:checked + .radio-custom {
    background: var(--primary-red);
    border-color: var(--primary-red);
}

.radio-option input:checked + .radio-custom::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 14px;
    font-weight: bold;
}

.radio-option input:checked ~ .radio-label {
    color: var(--primary-red);
    font-weight: 600;
}

.radio-label {
    color: var(--text-dark);
    transition: all 0.3s ease;
}

/* Nhắc nhở chọn phương án tham dự */
.form-group.attendance-required label {
    color: var(--primary-red);
    font-weight: 600;
}

.form-group.attendance-required label::after {
    content: ' - Vui lòng chọn một phương án!';
    color: var(--primary-red);
    font-size: 0.9em;
    animation: blink 0.5s ease-in-out infinite;
}

.form-group.attendance-required .attendance-options {
    animation: shake 0.5s ease-in-out;
}

.form-group.attendance-required .radio-option {
    border-color: var(--primary-red);
    animation: pulse-border 1s ease-in-out infinite;
}

@keyframes pulse-border {
    0%, 100% {
        border-color: var(--primary-red);
        box-shadow: 0 0 0 0 rgba(196, 30, 58, 0.4);
    }
    50% {
        border-color: var(--gold);
        box-shadow: 0 0 15px 3px rgba(196, 30, 58, 0.3);
    }
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.submit-btn {
    width: 100%;
    padding: 18px;
    font-size: 1.1rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    border: 2px solid var(--gold);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 1px;
}

.submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(196, 30, 58, 0.4);
}

/* ===== THANK POPUP ===== */
.thank-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thank-popup.hidden {
    display: none;
}

.thank-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 5, 5, 0.95);
}

.thank-popup-content {
    position: relative;
    width: 95%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    background: linear-gradient(180deg, var(--cream) 0%, var(--white) 100%);
    border-radius: 20px;
    border: 3px solid var(--gold);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    padding: 30px 20px;
    animation: popupSlideIn 0.4s ease;
}

@keyframes popupSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.thank-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    border: 2px solid var(--gold);
    background: var(--white);
    color: var(--primary-red);
    font-size: 1.5rem;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thank-popup-close:hover {
    background: var(--primary-red);
    color: var(--white);
}

.thank-popup-header {
    text-align: center;
    margin-bottom: 20px;
}

.thank-popup-icon {
    font-size: 3rem;
    color: var(--primary-red);
    animation: heartBeat 1.5s ease infinite;
    margin-bottom: 10px;
}

.thank-popup-header h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    color: var(--primary-red);
    margin-bottom: 8px;
}

.thank-popup-header #thank-name {
    color: var(--primary-red-dark);
    font-weight: 700;
}

.thank-popup-message {
    font-size: 0.95rem;
    color: var(--text-light);
}

.thank-popup .qr-gift-section {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--gold);
}

.thank-popup .qr-gift-section h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.thank-popup .qr-subtitle {
    font-size: 0.85rem;
    margin-bottom: 15px;
}

.thank-popup .qr-code-item img {
    width: 160px;
    height: 160px;
}

.thank-popup-btn {
    display: block;
    width: 100%;
    max-width: 200px;
    margin: 20px auto 0;
    padding: 12px 30px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-dark) 100%);
    border: 2px solid var(--gold);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.thank-popup-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(196, 30, 58, 0.4);
}

@media (max-width: 480px) {
    .thank-popup-content {
        padding: 25px 15px;
    }

    .thank-popup-header h2 {
        font-size: 1.6rem;
    }

    .thank-popup-icon {
        font-size: 2.5rem;
    }

    .thank-popup .qr-code-item img {
        width: 140px;
        height: 140px;
    }
}

/* ===== QR GIFT SECTION ===== */
.qr-gift-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid var(--gold);
}

.qr-gift-section h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--primary-red);
    margin-bottom: 10px;
}

.qr-subtitle {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 25px;
}

.qr-codes-wrapper {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.qr-code-item {
    text-align: center;
    background: var(--white);
    padding: 15px;
    border-radius: 15px;
    border: 2px solid var(--gold);
    box-shadow: 0 5px 20px rgba(196, 30, 58, 0.1);
    transition: transform 0.3s ease;
}

.qr-code-item:hover {
    transform: translateY(-5px);
}

.qr-code-item img {
    width: 220px;
    height: 220px;
    object-fit: contain;
    border-radius: 10px;
    margin-bottom: 15px;
}

.qr-code-item .qr-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-red);
    margin-bottom: 5px;
}

.qr-code-item .qr-bank {
    font-size: 0.85rem;
    color: var(--gold-dark);
    font-weight: 500;
    margin-bottom: 3px;
}

.qr-account-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 5px;
}

.qr-code-item .qr-account {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-red-dark);
    letter-spacing: 1px;
    background: rgba(212, 165, 55, 0.15);
    padding: 8px 15px;
    border-radius: 20px;
}

.copy-btn {
    width: 36px;
    height: 36px;
    border: 2px solid var(--gold);
    background: var(--white);
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: var(--gold);
    transform: scale(1.1);
}

.copy-btn.copied {
    background: #4caf50;
    border-color: #4caf50;
    color: white;
}

@media (max-width: 480px) {
    .qr-code-item img {
        width: 180px;
        height: 180px;
    }

    .qr-codes-wrapper {
        gap: 20px;
    }

    .qr-code-item .qr-name {
        font-size: 0.9rem;
    }

    .qr-code-item .qr-account {
        font-size: 1rem;
    }
}

/* ===== THANK YOU SECTION ===== */
.thankyou-section {
    padding: 35px 20px;
    background: linear-gradient(160deg, var(--primary-red) 0%, var(--primary-red-dark) 60%, #5c1025 100%);
    text-align: center;
    color: var(--white);
    position: relative;
    overflow: hidden;
}

/* Ảnh nền cho thank you section */
.thankyou-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images2/2429421820728032246 (7).jpg') center center / cover no-repeat;
    opacity: 0.12;
    pointer-events: none;
}

/* Decorative pattern */
.thankyou-section::after {
    content: '囍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20rem;
    color: var(--gold);
    opacity: 0.03;
    font-family: 'Ma Shan Zheng', cursive;
    pointer-events: none;
}

.thankyou-section .ornament {
    color: var(--gold);
    position: relative;
    z-index: 1;
    font-size: 2rem;
}

.thankyou-section h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2.4rem;
    color: var(--gold);
    margin-bottom: 15px;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.thankyou-section p {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.95);
    max-width: 550px;
    margin: 0 auto;
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

.couple-signature {
    font-family: 'Dancing Script', cursive;
    font-size: 1.8rem;
    color: var(--gold);
    margin-top: 20px !important;
    position: relative;
    z-index: 1;
}

.couple-signature::before {
    content: '♥';
    display: block;
    font-size: 1.2rem;
    margin-bottom: 10px;
    opacity: 0.8;
}

/* ===== FOOTER ===== */
.footer {
    padding: 30px 20px;
    background: linear-gradient(180deg, #3d1020 0%, #2a0a15 100%);
    text-align: center;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.footer-date {
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    color: var(--gold);
    letter-spacing: 5px;
    margin-bottom: 8px;
}

.footer-names {
    font-family: 'Dancing Script', cursive;
    font-size: 1.5rem;
    color: var(--gold-light);
}

/* ===== ANIMATIONS ===== */
.section-title {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.section-title.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .envelope-left .half-hy,
    .envelope-right .half-hy {
        font-size: 6rem;
    }

    .inner-double-happiness {
        font-size: 3rem;
    }

    .inner-title {
        font-size: 1.5rem;
    }

    .cover-double-happiness {
        font-size: 4rem;
        top: 10%;
        width: 95px;
        height: 95px;
    }

    .countdown-wrapper {
        bottom: 100px;
        gap: 6px;
    }

    .countdown-item {
        padding: 8px 12px;
        min-width: 50px;
    }

    .wedding-date-header {
        padding: 10px 20px;
    }

    .couple-photo-single {
        width: 240px;
        height: 240px;
    }

    .couple-name-item h3 {
        font-size: 1.5rem;
    }

    .couple-heart {
        font-size: 1.8rem;
    }

    .family-wrapper {
        gap: 0;
        padding: 8px;
    }

    .family {
        padding: 20px 15px;
    }

    .family h3 {
        font-size: 1rem;
    }

    .parent-name {
        font-size: 1.1rem;
    }

    .family-divider {
        margin: 15px 0;
    }

    .event-date-big {
        padding: 20px 30px;
    }

    .event-date-big .day {
        font-size: 3rem;
    }

    .event-date-big .month {
        font-size: 0.9rem;
    }

    .event-date-big .year {
        font-size: 1rem;
    }

    .event-info {
        padding: 20px;
    }

    .event-times p {
        font-size: 0.95rem;
    }

    .event-location p {
        font-size: 0.85rem;
    }

    .gallery-grid {
        column-count: 2;
        column-gap: 10px;
    }

    .thankyou-section h2 {
        font-size: 2.2rem;
    }

    .couple-signature {
        font-size: 1.8rem;
    }

    .gallery-item {
        margin-bottom: 8px;
    }

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

    .greeting {
        font-size: 1.2rem;
    }

    .message-text {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .envelope-left .half-hy,
    .envelope-right .half-hy {
        font-size: 5rem;
    }

    .inner-double-happiness {
        font-size: 2.5rem;
    }

    .inner-title {
        font-size: 1.3rem;
    }

    #guest-name {
        padding: 10px 15px;
        font-size: 0.9rem;
    }

    .enter-btn {
        padding: 10px 25px;
        font-size: 0.85rem;
    }

    .cover-double-happiness {
        font-size: 3.2rem;
        top: 10%;
        width: 80px;
        height: 80px;
    }

    .save-the-date::before,
    .save-the-date::after {
        display: none;
    }

    .wedding-date-header {
        padding: 8px 15px;
    }

    .countdown-wrapper {
        bottom: 85px;
        gap: 5px;
    }

    .countdown-item {
        padding: 6px 10px;
        min-width: 45px;
        border-radius: 8px;
    }

    .couple-photo-single {
        width: 200px;
        height: 200px;
    }

    .couple-name-item h3 {
        font-size: 1.3rem;
    }

    .couple-heart {
        font-size: 1.5rem;
    }

    .couple-names-info {
        gap: 15px;
    }

    .gallery-grid {
        column-count: 2;
        column-gap: 8px;
    }

    .gallery-item {
        margin-bottom: 8px;
        border-radius: 8px;
    }

    .calendar {
        padding: 15px;
    }

    .calendar-day {
        padding: 8px 0;
        font-size: 0.85rem;
    }

    .family-wrapper {
        padding: 5px;
    }

    .family {
        padding: 15px 10px;
    }

    .family h3 {
        font-size: 0.9rem;
    }

    .parent-name {
        font-size: 1rem;
    }

    .family-divider::before {
        font-size: 0.7rem;
        padding: 5px;
    }

    .family-wrapper {
        gap: 0;
    }

    .event-compact {
        gap: 15px;
    }

    .event-date-big {
        padding: 15px 25px;
    }

    .event-date-big .day {
        font-size: 2.5rem;
    }

    .event-date-big .month {
        font-size: 0.8rem;
        letter-spacing: 2px;
    }

    .event-date-big .year {
        font-size: 0.9rem;
    }

    .event-info {
        padding: 15px;
    }

    .event-info .event-lunar {
        font-size: 0.85rem;
        margin-bottom: 12px;
        padding-bottom: 10px;
    }

    .event-times p {
        font-size: 0.9rem;
        margin-bottom: 8px;
    }

    .event-times strong {
        font-size: 1rem;
    }

    .event-location p {
        font-size: 0.8rem;
        margin-bottom: 12px;
    }

    .map-link {
        padding: 10px 20px;
        font-size: 0.8rem;
    }

    .thankyou-section h2 {
        font-size: 1.8rem;
    }

    .thankyou-section p {
        font-size: 0.9rem;
    }

    .couple-signature {
        font-size: 1.5rem;
    }

    .scroll-indicator {
        bottom: 20px;
    }

    .scroll-indicator span {
        font-size: 0.75rem;
    }

    .scroll-arrow {
        width: 18px;
        height: 18px;
    }

    .countdown-wrapper {
        gap: 8px;
    }

    .countdown-item {
        padding: 10px 12px;
        min-width: 55px;
    }

    .countdown-number {
        font-size: 1.5rem;
    }

    .countdown-label {
        font-size: 0.65rem;
    }

    .cover-ornament {
        width: 60px;
        height: 60px;
    }

    .music-toggle {
        width: 40px;
        height: 40px;
        top: 15px;
        right: 15px;
    }

    .music-icon {
        font-size: 1.2rem;
    }
}

/* ===== MOBILE OPTIMIZATIONS ===== */
/* Touch-friendly buttons */
@media (hover: none) and (pointer: coarse) {
    .enter-btn,
    .submit-btn,
    .map-link {
        min-height: 48px;
        padding: 14px 30px;
    }

    .radio-option {
        min-height: 52px;
    }

    .gallery-item {
        -webkit-tap-highlight-color: transparent;
    }
}

/* Safe area for notched phones */
@supports (padding: env(safe-area-inset-bottom)) {
    .footer {
        padding-bottom: calc(30px + env(safe-area-inset-bottom));
    }

    .welcome-screen {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* Prevent text selection on mobile */
.cover-section,
.welcome-screen {
    -webkit-user-select: none;
    user-select: none;
}

/* Smooth scrolling for iOS */
html {
    -webkit-overflow-scrolling: touch;
}

/* Fix for 100vh on mobile browsers */
@supports (-webkit-touch-callout: none) {
    .welcome-screen,
    .cover-section {
        min-height: -webkit-fill-available;
    }
}
