/* ========================================= */
/* 1. CONFIGURATION & RESET (ROYAL HERITAGE) */
/* ========================================= */
:root {
    --bg-color: #2A0808;      /* Deep Regal Maroon */
    --card-bg: #1A0505;       /* Darker Maroon for cards */
    --primary: #D4AF37;       /* Antique Gold */
    --primary-dark: #997A3D;  /* Burnished Gold */
    --gold-accent: #E5C158;   /* Bright Gold */
    --gold-darker: #B5952F; 
    --text-dark: #FDF5E6;     /* Ivory for headings */
    --text-light: #D3C4A3;    /* Beige for body text */
    --border-color: rgba(212, 175, 55, 0.3); 
    --radius: 12px;           
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent;}
html.lenis, html.lenis body { height: auto; width: 100%; overflow-x: hidden; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
    background-color: var(--bg-color);
    background-image: linear-gradient(rgba(26, 5, 5, 0.3), rgba(17, 3, 3, 0.5)), url('../images/img1.webp');
    background-repeat: repeat;
    background-blend-mode: normal; 
    background-size: 350px;
    color: var(--text-light);
    font-family: 'Lato', sans-serif;
    line-height: 1.6;
    display: flex; flex-direction: column; min-height: 100vh; 
    position: relative;
}

/* =======================================================
   --- BROWSER OVERRIDES (NATIVE APP FEEL) ---
   ======================================================= */

/* 1. Removes the blue flash/box on tap for ALL elements (Mobile) */
* {
    -webkit-tap-highlight-color: transparent;
}

/* 2. Removes the blue focus ring on click (Desktop) */
a:focus, button:focus, .lang-switch:focus, input:focus, .event-row:focus, .modal-close-area:focus {
    outline: none !important;
}

/* 3. Prevents accidental text highlighting when double-tapping UI buttons */
button, a, .lang-switch, .modal-close-area, .event-row, .envelope-container, .shagun-box {
    -webkit-user-select: none; /* Safari/Chrome */
    -moz-user-select: none; /* Firefox */
    -ms-user-select: none; /* IE10+/Edge */
    user-select: none; /* Standard */
}

/* 4. Prevents "Ghost Image" dragging when interacting with elements */
img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
    pointer-events: none; /* Stops right-click save prompt on decorative images */
}

/* Re-enable pointer events ONLY for images that need to be interacted with/scanned */
.qr-placeholder, .qr-img-real {
    pointer-events: auto; 
}
/* ======================================================= */

h1, h2, h3, h4 { font-family: 'Playfair Display', serif; color: var(--text-dark); font-weight: 700; }
.text-center { text-align: center; }

/* ========================================= */
/* 2. NAVIGATION                             */
/* ========================================= */
nav { position: sticky; top: 0; z-index: 1000; text-align: center; background: var(--bg-color); padding: 1rem; border-bottom: 1px solid var(--border-color); transition: transform 0.4s ease-in-out; }
nav a { margin: 0 15px; text-decoration: none; color: var(--primary); font-weight: 600; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 2px; }
nav.nav-hidden { transform: translateY(-100%); }
.transparent-nav { position: fixed; top: 0; left: 0; width: 100%; background-color: transparent; display: flex; justify-content: space-between; align-items: center; padding: 15px 30px; z-index: 1000; transition: transform 0.4s ease, background-color 0.4s ease; border: none; }
.nav-white { background-color: rgba(26, 5, 5, 0.95); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border-color); }

.btn { display: inline-block; padding: 12px 28px; text-decoration: none; border-radius: 4px; font-family: 'Playfair Display', serif; font-weight: 700; cursor: pointer; transition: all 0.4s ease; text-align: center; font-size: 0.95rem; letter-spacing: 1px; border: 1px solid var(--primary); text-transform: uppercase; }
.btn.primary { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); color: var(--bg-color); box-shadow: 0 4px 15px rgba(212, 175, 55, 0.15); }

/* ========================================= */
/* 3. HERO SECTION                           */
/* ========================================= */
.hero {
    height: 100vh; width: 100%; margin: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; 
    padding-top: 30vh; text-align: center; color: var(--text-dark); position: relative; overflow: hidden;
}
.hero-bg { position: absolute; top: -5%; left: -5%; width: 110%; height: 110%; background-size: cover; background-position: center; z-index: 0; }
.hero-bg-home { background-image: linear-gradient(rgba(0,0,0,0.6), rgba(26,5,5,0.8)), url('../images/hero.webp'); }

.hero-content { position: relative; z-index: 2; }
.hero h1 { font-size: 5rem; margin: 0 0 10px; line-height: 1.1; display: flex; gap: 15px; justify-content: center; align-items: center; flex-wrap: wrap; color: var(--primary); }
.hero h1 span { display: inline-block; background: linear-gradient(to bottom, #FFF, var(--primary), var(--primary-dark)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; filter: drop-shadow(0 4px 12px rgba(0,0,0,0.8)); }
.hero-sub { font-size: 1.5rem; margin-top: 5px; color: var(--primary); font-family: 'Playfair Display', serif; font-style: italic; letter-spacing: 2px; text-shadow: 0 2px 10px rgba(0,0,0,0.8); }

/* ========================================= */
/* 4. ITINERARY CARDS                        */
/* ========================================= */
.section { padding: 80px 20px; max-width: 900px; margin: 0 auto; }
.section-title { text-align: center; font-size: 3rem; color: var(--primary); margin-bottom: 5px; text-transform: uppercase; letter-spacing: 3px; }

.custom-divider { display: flex; align-items: center; justify-content: center; margin: 20px auto 50px; width: 100%; max-width: 400px; }
.divider-icon-center { color: var(--primary); font-size: 1.5rem; margin: 0 20px; filter: drop-shadow(0 0 5px rgba(212,175,55,0.5)); }
.custom-divider::before, .custom-divider::after { content: ''; height: 2px; background: linear-gradient(to right, transparent, var(--primary), transparent); flex-grow: 1; transform: scaleX(0); transition: transform 1.5s cubic-bezier(0.16, 1, 0.3, 1); }
.custom-divider::before { transform-origin: right; }
.custom-divider::after { transform-origin: left; }
.custom-divider.bloom::before, .custom-divider.bloom::after { transform: scaleX(1); }

.timeline-list { display: flex; flex-direction: column; gap: 40px; }
.timeline-card { 
    --mouse-x: 50%; --mouse-y: 50%;
    background: radial-gradient(800px circle at var(--mouse-x) var(--mouse-y), rgba(212, 175, 55, 0.08), transparent 40%), var(--card-bg);
    border: 1px solid var(--border-color); border-radius: var(--radius); 
    padding: 35px 40px; display: flex; gap: 40px; align-items: center; 
    box-shadow: inset 0 0 20px rgba(0,0,0,0.5), 0 10px 30px rgba(0,0,0,0.4); 
    transition: transform 0.5s ease, box-shadow 0.5s ease; position: relative; overflow: hidden;
}
.timeline-card::before { content: ''; position: absolute; top: 5px; left: 5px; right: 5px; bottom: 5px; border: 1px solid rgba(212, 175, 55, 0.1); border-radius: 8px; pointer-events: none; }
.timeline-card::after { content: ''; position: absolute; top: 0; left: -100%; width: 50%; height: 100%; background: linear-gradient(to right, transparent, rgba(212, 175, 55, 0.1), transparent); transform: skewX(-20deg); transition: 0.7s cubic-bezier(0.19, 1, 0.22, 1); pointer-events: none; }

.timeline-icon { 
    width: 130px; height: 130px; 
    object-fit: contain; 
    filter: drop-shadow(0 0 20px rgba(212,175,55,0.4)); 
    flex-shrink: 0; 
    transform: scale(1.6); 
    margin: 15px; 
}

.timeline-info { flex-grow: 1; text-align: left; }
.timeline-info h3 { font-size: 2.2rem; color: var(--primary); margin-bottom: 15px; line-height: 1.2; }
.timeline-info p { display: flex; align-items: center; gap: 12px; color: var(--text-light); font-size: 1.05rem; margin-bottom: 8px; }
.timeline-info p i { color: var(--gold-accent); width: 20px; text-align: center; font-size: 1.1rem;}

.map-btn { display: inline-block; margin-top: 15px; font-size: 0.85rem; font-weight: 700; text-transform: uppercase; color: var(--gold-accent); text-decoration: none; border-bottom: 1px solid var(--border-color); padding-bottom: 4px; transition: all 0.4s; letter-spacing: 1px; }

/* ========================================= */
/* 5. 3D CAROUSEL SECTION                    */
/* ========================================= */
.date-header-row { display: flex; align-items: center; justify-content: center; margin: 70px 0 40px; position: relative; }
.date-pill { background: var(--bg-color); color: var(--primary); border: 1px solid var(--primary); padding: 12px 45px; border-radius: 4px; font-family: 'Playfair Display', serif; font-size: 1.4rem; z-index: 2; box-shadow: 0 4px 15px rgba(0,0,0,0.5); text-transform: uppercase; letter-spacing: 2px; }
.date-line { position: absolute; width: 100%; height: 1px; background: linear-gradient(to right, transparent, var(--primary), transparent); top: 50%; z-index: 1; opacity: 0.5; }

.carousel-section { position: relative; width: 100%; overflow: hidden; padding: 20px 0; }
.carousel-container { position: relative; height: 320px; display: flex; justify-content: center; align-items: center; width: 100%; }

.carousel-card { 
    position: absolute; width: 300px; height: 280px; background: var(--card-bg); padding: 30px 25px; 
    border-radius: var(--radius); border: 1px solid var(--border-color); box-shadow: inset 0 0 20px rgba(0,0,0,0.5), 0 8px 20px rgba(0,0,0,0.4); 
    display: flex; flex-direction: column; align-items: center; text-align: center;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.6s ease, box-shadow 0.6s ease, border-color 0.6s ease; cursor: pointer;
}
.carousel-card i { font-size: 2.2rem; color: var(--primary); margin-bottom: 15px; text-shadow: 0 0 10px rgba(212,175,55,0.3); }
.carousel-card h4 { font-family: 'Playfair Display', serif; font-size: 1.5rem; color: var(--text-dark); margin-bottom: 10px; }
.carousel-card p { color: white; font-size: 0.95rem; margin-bottom: 15px; line-height: 1.4;}

/* This controls ONLY the text inside the yellow box */
.card-highlight { 
    font-weight: 700; 
    color: #2b2205; /* Your custom dark color for the numbers */
    background: var(--primary); /* The yellow/gold box background */
    font-size: 0.9rem; 
    margin-top: auto; 
    padding: 6px 15px; 
    border-radius: 4px; 
    text-transform: uppercase; 
    letter-spacing: 1px; 
}
.card-link { display: inline-block; margin-top: auto; font-size: 0.85rem; text-transform: uppercase; font-weight: 700; color: var(--gold-accent); text-decoration: none; border-bottom: 1px solid var(--border-color); padding-bottom: 4px; position: relative; z-index: 10; }

.pos-center { transform: translate(-50%, -50%) scale(1); left: 50%; top: 50%; opacity: 1; z-index: 3; box-shadow: inset 0 0 20px rgba(0,0,0,0.5), 0 15px 40px rgba(212, 175, 55, 0.15); border-color: var(--primary); cursor: default; }
.pos-left { transform: translate(calc(-50% - 160px), -50%) scale(0.85); left: 50%; top: 50%; opacity: 0.4; z-index: 1; filter: grayscale(50%); }
.pos-right { transform: translate(calc(-50% + 160px), -50%) scale(0.85); left: 50%; top: 50%; opacity: 0.4; z-index: 1; filter: grayscale(50%); }
.pos-hidden { transform: translate(-50%, -50%) scale(0.5); left: 50%; top: 50%; opacity: 0; z-index: 0; pointer-events: none; }

/* ========================================= */
/* 6. CALL TO ACTION SECTION                 */
/* ========================================= */
.dark-mango-section {
    padding: 100px 20px; background-color: #0F291E; 
    background-image: linear-gradient(rgba(15, 41, 30, 0.85), rgba(15, 41, 30, 0.95)), url('../images/img1.webp');
    background-repeat: repeat; background-blend-mode: multiply;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    border-top: 2px solid var(--primary); color: var(--text-dark); text-align: center; position: relative; overflow: hidden;
}
.rsvp-cta-text { font-family: 'Playfair Display', serif; font-size: 2.5rem; margin-bottom: 30px; z-index: 2; position: relative; text-shadow: 0 4px 10px rgba(0,0,0,0.5); }

/* ========================================= */
/* 7. ANIMATIONS & FOOTER                    */
/* ========================================= */
footer { background-color: #110303; color: var(--text-light); padding: 40px 20px; text-align: center; border-top: 1px solid var(--border-color); width: 100%; position: relative; z-index: 5; font-family: 'Playfair Display', serif; letter-spacing: 1px; }

/* ========================================= */
/* 8. MOBILE RESPONSIVENESS                  */
/* ========================================= */
@media (max-width: 600px) {
    .section { padding: 50px 20px; }
    .hero { padding-top: 12vh; height: 100vh; justify-content: flex-start; } 
    .hero h1 { font-size: 3rem; gap: 8px; }
    .hero-sub { font-size: 1.2rem; }
    .transparent-nav .btn { padding: 8px 12px; font-size: 0.75rem; }
    .timeline-card { flex-direction: column; text-align: center; gap: 20px; padding: 35px 25px; }
    .timeline-info { text-align: center; display: flex; flex-direction: column; align-items: center; }
    .timeline-info h3 { font-size: 1.8rem; }
    .rsvp-cta-text { font-size: 1.8rem; }
    .carousel-container { height: 280px; }
    .carousel-card { width: 260px; height: 250px; padding: 25px 20px; }
    .carousel-card h4 { font-size: 1.3rem; }
    .carousel-card p { font-size: 0.85rem; }
    .pos-left { transform: translate(calc(-50% - 120px), -50%) scale(0.8); opacity: 0.3; }
    .pos-right { transform: translate(calc(-50% + 120px), -50%) scale(0.8); opacity: 0.3; }
    
    .timeline-icon { width: 100px !important; height: 100px !important; transform: scale(1.6) !important; margin-bottom: 10px !important; }
}

/* Removed .carousel-card:active to prevent transform conflicts with the 3D positioning */
.btn:active, .timeline-card:active, .date-pill:active { 
    transform: scale(0.97) !important; 
    border-color: var(--primary) !important;
    box-shadow: inset 0 0 30px rgba(0,0,0,0.8), 0 2px 5px rgba(0,0,0,0.5) !important;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease !important; 
}

@media (hover: hover) and (pointer: fine) {
    .btn.primary:hover { box-shadow: 0 6px 25px rgba(212, 175, 55, 0.3); transform: translateY(-2px); filter: brightness(1.1); }
    .timeline-card:hover { box-shadow: inset 0 0 20px rgba(0,0,0,0.5), 0 15px 40px rgba(0,0,0,0.6); border-color: var(--primary); }
    .carousel-card.pos-left:hover, .carousel-card.pos-right:hover { opacity: 0.8; filter: grayscale(0%); }
    .map-btn, .card-link { position: relative; border-bottom: none !important; padding-bottom: 4px; text-decoration: none; color: var(--primary); transition: color 0.4s; }
    .map-btn::after, .card-link::after { content: ''; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px; background-color: var(--primary); transform: scaleX(0); transform-origin: right center; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
    .map-btn:hover::after, .card-link:hover::after { transform: scaleX(1); transform-origin: left center; }
    .map-btn:hover { color: var(--gold-accent); text-shadow: 0 0 8px rgba(212,175,55,0.4); }
    .timeline-card:hover::after { left: 150%; } 
}

.shimmer-btn { position: relative; overflow: hidden; }
.shimmer-btn::after { 
    content: ''; position: absolute; top: 0; left: -150%; width: 50%; height: 100%; 
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%); 
    transform: skewX(-25deg); animation: shimmer-effect 6s infinite; 
}
@keyframes shimmer-effect { 0% { left: -150%; } 15% { left: 200%; } 100% { left: 200%; } }

/* ========================================= */
/* MICRO-INTERACTIONS & UI POLISH            */
/* ========================================= */

/* 1. Golden Dust Parallax */
.gold-dust-container { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; z-index: -1; pointer-events: none; overflow: hidden; }
.dust-particle { position: absolute; background: var(--primary); border-radius: 50%; opacity: 0; box-shadow: 0 0 4px var(--primary); animation: floatUp linear infinite; }
@keyframes floatUp { 0% { transform: translateY(110vh); opacity: 0; } 10% { opacity: 0.6; } 90% { opacity: 0.6; } 100% { transform: translateY(-10vh); opacity: 0; } }

/* 5. 3D Card Tilt (Prevents sharp corners on the glare overlay) */
.js-tilt-glare { border-radius: var(--radius); }

/* 6. Gold Flash for RSVP Selection */
@keyframes goldFlash { 
    0% { box-shadow: inset 0 0 10px rgba(0,0,0,0.5), 0 0 0px transparent; border-color: var(--border-color); } 
    50% { box-shadow: inset 0 0 10px rgba(0,0,0,0.5), 0 0 25px var(--primary); border-color: var(--primary); } 
    100% { box-shadow: inset 0 0 10px rgba(0,0,0,0.5), 0 4px 15px rgba(212,175,55,0.1); border-color: var(--primary); } 
}
@keyframes iconBounce { 0% { transform: scale(1); } 50% { transform: scale(1.4); } 100% { transform: scale(1); } }
.event-option-card.flash { animation: goldFlash 0.5s ease-out forwards; }
.event-option-card.flash .check-icon { animation: iconBounce 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); }

/* 8. Haptic Ripple Effect (Strictly for buttons to protect layouts) */
.ripple { position: absolute; border-radius: 50%; transform: scale(0); animation: ripple-anim 600ms linear; background: rgba(212, 175, 55, 0.3); pointer-events: none; z-index: 99; }
@keyframes ripple-anim { to { transform: scale(4); opacity: 0; } }
.btn, .date-pill { position: relative; overflow: hidden; }