/* Custom Silk Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: #000000; }
::-webkit-scrollbar-thumb { background: #a38f7a; border-radius: 10px; }

/* Reset & True OLED Black */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; background-color: #000000; color: #f4ebd9; font-family: 'Tahoma', sans-serif; overflow-x: hidden; }

/* Interactive Preloader */
#preloader {
    position: fixed; top: 0; left: 0; width: 100%; height: 100dvh;
    background: #000000; z-index: 99999;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    transition: opacity 0.8s cubic-bezier(0.25, 1, 0.5, 1), visibility 0.8s;
}
.monogram { font-size: 5rem; color: #a38f7a; margin-bottom: 40px; letter-spacing: 5px; }
.pulse-btn {
    background: transparent; border: 1px solid #a38f7a; color: #a38f7a;
    padding: 14px 30px; font-size: 16px; border-radius: 30px; cursor: pointer;
    animation: pulse-glow 2s infinite; font-family: inherit; transition: 0.3s;
}
.pulse-btn:active { background: #a38f7a; color: #000; }
@keyframes pulse-glow { 0%, 100% { box-shadow: 0 0 10px rgba(163,143,122,0.2); } 50% { box-shadow: 0 0 25px rgba(163,143,122,0.6); } }

/* Gold Scroll Progress */
#progress-bar { position: fixed; top: 0; left: 0; width: 0%; height: 2px; background: #a38f7a; z-index: 9999; box-shadow: 0 0 8px #a38f7a; }

/* Lang Toggle */
.lang-toggle { position: fixed; top: 20px; right: 20px; z-index: 999; }
#lang-btn {
    background: rgba(10, 10, 10, 0.8); border: 1px solid #a38f7a;
    color: #a38f7a; padding: 6px 18px; border-radius: 30px;
    cursor: pointer; backdrop-filter: blur(10px); font-size: 13px; font-weight: bold;
}

/* 60fps Hardware Reveal */
.smooth-reveal {
    opacity: 0; transform: translate3d(0, 40px, 0);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, opacity;
}
.smooth-reveal.reveal-active { opacity: 1; transform: translate3d(0, 0, 0); }
.delay-1 { transition-delay: 0.1s; } .delay-2 { transition-delay: 0.2s; } .delay-3 { transition-delay: 0.35s; }

/* Layout */
section {
    padding: 100px 20px; display: flex; flex-direction: column;
    align-items: center; justify-content: center; text-align: center;
    min-height: 85dvh; position: relative; overflow: hidden;
}

/* Gyroscope Hero */
.hero { min-height: 100dvh; background: #000000; }
#particle-canvas {
    position: absolute; top: -10%; left: -10%; width: 120%; height: 120%;
    z-index: 0; pointer-events: none;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.95)), url('../thumb.jpg') center/cover no-repeat;
    will-change: transform; /* Critical for Parallax GPU rendering */
}
.hero-content { z-index: 1; position: relative; }

.badge { font-size: 15px; color: #a38f7a; letter-spacing: 2px; }
.couple-names { font-size: 4.5rem; margin: 25px 0; color: #f4ebd9; font-weight: 300; }
.date-text { font-size: 18px; color: #a38f7a; }

/* Touch Gallery */
.gallery-section h2, .countdown-section h2 { font-size: 2.2rem; color: #f4ebd9; margin-bottom: 30px; }
.gallery-container {
    display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory;
    width: 100%; max-width: 900px; padding-bottom: 20px; -webkit-overflow-scrolling: touch;
}
.gallery-img {
    flex: 0 0 85%; max-width: 400px; height: 320px; object-fit: cover;
    border-radius: 8px; scroll-snap-align: center; border: 1px solid #1a1a1a;
}

/* Countdown */
#countdown { display: flex; gap: 30px; margin-top: 20px; }
.time-block span { font-size: 4.5rem; color: #a38f7a; display: block; line-height: 1; }
.time-block p { font-size: 13px; color: #f4ebd9; margin-top: 8px; text-transform: uppercase; letter-spacing: 1px; }

/* Dark Card */
.card {
    background: #050505; padding: 50px 30px; border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.9); max-width: 600px; width: 100%;
    border: 1px solid #141312;
}
.card h3 { font-size: 26px; margin-bottom: 20px; color: #f4ebd9; }
.dress-code-badge {
    display: inline-block; padding: 10px 20px; background: rgba(163, 143, 122, 0.08);
    border: 1px solid #a38f7a; color: #a38f7a; border-radius: 30px; margin-bottom: 35px; font-size: 13px;
}
.details-grid { display: flex; justify-content: space-between; margin-bottom: 40px; gap: 20px; flex-wrap: wrap; }
.detail-item { flex: 1; min-width: 200px; }
.detail-item h4 { font-size: 14px; color: #a38f7a; margin-bottom: 10px; text-transform: uppercase; }
.detail-item p { font-size: 16px; color: #f4ebd9; line-height: 1.6; }

/* Buttons & Form */
.btn-rsvp, .btn-submit, .btn-action {
    display: inline-block; background-color: #a38f7a; color: #000;
    padding: 16px 36px; font-weight: bold; border: none; border-radius: 4px;
    cursor: pointer; transition: transform 0.2s; text-decoration: none; font-size: 15px; width: 100%; max-width: 300px;
}
.btn-action { background: transparent; border: 1px solid #a38f7a; color: #a38f7a; padding: 12px 24px; font-size: 13px; margin-top: 15px; }
.btn-action:active, .btn-submit:active { transform: scale(0.96); }

.rsvp-form { display: flex; flex-direction: column; gap: 16px; max-width: 450px; width: 100%; margin-top: 30px; }
.rsvp-form input, .rsvp-form select, .rsvp-form textarea {
    padding: 16px; border: 1px solid #221f1c; border-radius: 6px;
    background-color: #030303; color: #f4ebd9; font-family: inherit; font-size: 15px; outline: none; text-align: right;
    transition: border-color 0.3s;
}
.rsvp-form input:focus, .rsvp-form select:focus, .rsvp-form textarea:focus { border-color: #a38f7a; }

/* Floating Music */
.music-btn {
    position: fixed; bottom: 30px; left: 30px; background-color: #a38f7a;
    border: none; border-radius: 50%; width: 55px; height: 55px;
    cursor: pointer; box-shadow: 0 6px 20px rgba(0,0,0,0.8); z-index: 9999;
    display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.music-btn.muted { background-color: #111; border: 1px solid #333; opacity: 0.7; }

/* Mobile Optimizations */
@media (max-width: 768px) {
    .couple-names { font-size: 3.5rem; }
    .time-block span { font-size: 3rem; }
    .details-grid { flex-direction: column; }
}
