/* ====================================================
   INVITO 18ESIMO — STYLE SHEET (LUXURY VIP PASS THEME)
   ==================================================== */

:root {
    --bg-dark:       #060a12; /* Deepest black-blue */
    --navy-text:     #d5e3f2; /* Soft white-blue text */
    --navy-light:    #0f1c30; /* Medium navy for containers */
    
    --card-bg:       #070d19; /* Deep navy marble base */
    --gold:          #c5a059; /* Elegant warm gold */
    --gold-bright:   #f5dd9f; /* Shiny gold highlight */
    --gold-dark:     #8a6f27; /* Dark gold shadows */
    --gold-text:     #d5b86a;
    
    --text-muted:    #8ca0b5; /* Soft slate gray */
    
    --font-script:   'Great Vibes', cursive;
    --font-display:  'Playfair Display', serif;
    --font-body:     'Cormorant Garamond', serif;
    --font-text:     'Montserrat', sans-serif;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: var(--bg-dark);
    color: var(--navy-text);
    font-family: var(--font-body);
    overflow: hidden;
    min-height: 100vh;
    min-height: 100dvh;
    -webkit-font-smoothing: antialiased;
}

/* ====================================================
   PHASES
   ==================================================== */
.phase {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .8s ease;
}
.phase.active { opacity: 1; pointer-events: auto; }

/* ====================================================
   PHASE 1: COVER VIDEO (WAX SEAL)
   ==================================================== */
#cover-phase {
    background: #06090e;
    flex-direction: column;
}
#cover-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #06090e;
}
.seal-tap-area {
    position: absolute;
    top: 54.5%; /* Perfectly centered on the gold wax seal in busta_18.png */
    left: 50%;
    transform: translate(-50%, -50%);
    width: 85px;
    height: 85px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
}
.seal-pulse {
    position: absolute;
    inset: -10px;
    border-radius: 50%;
    border: 2px solid rgba(213,184,106,.5);
    animation: sealPulse 2s ease-in-out infinite;
}
.seal-pulse.delay { animation-delay: 1s; }
@keyframes sealPulse {
    0%   { transform: scale(.8); opacity: 1; }
    100% { transform: scale(1.8); opacity: 0; }
}
.cover-cta {
    position: absolute;
    bottom: 12%;
    left: 0; right: 0;
    text-align: center;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.cta-icon { font-size: 1.4rem; animation: ctaFloat 2s ease-in-out infinite; }
@keyframes ctaFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}
.cta-text {
    font-family: var(--font-text);
    font-size: .8rem;
    font-weight: 500;
    color: #fff;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0,0,0,.8);
    background: rgba(10,15,24,.6);
    padding: 6px 18px;
    border-radius: 20px;
    backdrop-filter: blur(4px);
}

/* ====================================================
   PHASE 2: INVITATION CARD (VIP PASS STYLE)
   ==================================================== */
#invite-phase {
    display: block;
    overflow-y: auto;
    overflow-x: hidden;
    width: 100%;
    height: 100%;
}

/* Luxury Royal Blue background */
.luxury-bg {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 10% 20%, rgba(197,160,89,.06) 0%, transparent 55%),
        radial-gradient(circle at 90% 80%, rgba(15,28,48,.45) 0%, transparent 55%),
        linear-gradient(135deg, #060b13 0%, #020306 100%);
    z-index: 0;
}

#gold-sparkle-canvas {
    position: fixed;
    inset: 0;
    width: 100%; height: 100%;
    z-index: 1;
    pointer-events: none;
}

.invite-scroll {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 24px 14px 40px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease, transform 1s ease;
}
#invite-phase.active .invite-scroll {
    opacity: 1;
    transform: translateY(0);
}

/* ====================================================
   THE CARD (Deep Navy Marble & Gold Frame)
   ==================================================== */
.card {
    position: relative;
    width: 100%;
    background-color: var(--card-bg);
    background-image: 
        radial-gradient(circle at 0% 0%, rgba(16, 29, 49, 0.9) 0%, transparent 50%),
        radial-gradient(circle at 100% 0%, rgba(12, 22, 38, 0.9) 0%, transparent 50%),
        radial-gradient(circle at 100% 100%, rgba(8, 15, 27, 0.95) 0%, transparent 50%),
        radial-gradient(circle at 0% 100%, rgba(4, 8, 15, 0.98) 0%, transparent 50%),
        url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.015' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.075'/%3E%3C/svg%3E");
    border-radius: 20px;
    box-shadow:
        0 15px 35px rgba(0,0,0,0.6),
        0 35px 80px rgba(0,0,0,0.85),
        inset 0 0 50px rgba(197,160,89,0.05);
    overflow: hidden;
}

/* Responsive SVG border overlay with top notch */
.card-borders-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
}

/* Card Content padding */
.card-content {
    position: relative;
    z-index: 5;
    padding: 34px 22px 30px;
    text-align: center;
}

/* ====================================================
   POLISHED METALLIC GOLD EFFECT
   ==================================================== */
.gold-text-metallic {
    background: linear-gradient(135deg, #a67c1e 0%, #fbf5b7 30%, #d5b86a 50%, #fbf5b7 70%, #91712a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 2.5px rgba(0,0,0,0.65));
    font-weight: 700;
}

/* ====================================================
   CENTRAL LAUREL WREATH CREST
   ==================================================== */
.crest-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 6px;
    margin-bottom: 2px;
}
.central-crest-svg {
    width: 165px;
    height: 165px;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.4));
}

/* Typography for VIP titles */
.vip-name {
    font-family: var(--font-display);
    font-size: 2.15rem;
    font-weight: 700;
    letter-spacing: 5px;
    margin-top: 10px;
    margin-bottom: 2px;
    line-height: 1.1;
}
.vip-title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 4px;
    margin-bottom: 2px;
    line-height: 1.1;
}
.vip-subtitle {
    font-family: var(--font-script);
    font-size: 2.1rem;
    font-weight: 400;
    margin-bottom: 12px;
    line-height: 1.1;
}

.gold-scroll-divider {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 4px 0 10px;
    opacity: 0.9;
}

/* ====================================================
   PASS DETAILS ROWS & DIVIDERS
   ==================================================== */
.pass-details {
    padding: 0 8px;
    margin: 18px 0;
    text-align: left;
}
.pass-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 4px;
}
.pass-icon-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1.2px solid var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.pass-icon-circle span {
    font-size: 16px;
}
.pass-row-text {
    font-family: var(--font-text);
    font-size: 0.86rem;
    color: #fff;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}
.pass-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(197, 160, 89, 0.25) 20%, rgba(197, 160, 89, 0.25) 80%, transparent);
    margin: 2px 0;
}

/* ====================================================
   DRESS CODE BOX WITH BOWTIE BADGE
   ==================================================== */
.dress-code-box {
    position: relative;
    border: 1px solid rgba(197,160,89,0.38);
    border-radius: 8px;
    padding: 20px 12px 14px;
    margin: 26px 4px 16px;
    text-align: center;
    box-shadow: inset 0 0 15px rgba(197,160,89,0.02);
}
.dress-code-badge {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #070d19; /* Match background texture of card to hide line */
    padding: 0 8px;
    width: 58px;
    height: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.bowtie-svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.4));
}
.dress-code-label {
    font-family: var(--font-text);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    margin-bottom: 5px;
}
.dress-code-text {
    font-family: var(--font-text);
    font-size: 0.8rem;
    color: #d0dbe5;
    line-height: 1.4;
    letter-spacing: 0.3px;
    text-shadow: 0 1px 1.5px rgba(0,0,0,0.4);
}

/* ====================================================
   PASS FOOTER
   ==================================================== */
.pass-footer {
    margin-top: 22px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}
.footer-seal {
    display: flex;
    justify-content: center;
}
.tiny-crown-svg {
    width: 32px;
    height: 18px;
    opacity: 0.85;
    filter: drop-shadow(0 1.5px 3px rgba(0,0,0,0.4));
}
.footer-rsvp-row {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}
.pass-icon-circle.small {
    width: 23px;
    height: 23px;
    border-width: 1px;
}
.footer-rsvp-text {
    font-family: var(--font-text);
    font-size: 0.74rem;
    color: #fff;
    letter-spacing: 0.5px;
    font-weight: 600;
    text-shadow: 0 1px 1.5px rgba(0,0,0,0.4);
}

/* ====================================================
   INTERACTIVE UTILITIES (CONTROL PANEL BELOW CARD)
   ==================================================== */
.interactive-utilities {
    display: flex;
    gap: 10px;
    margin: 16px 0;
    width: 100%;
}
.utility-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: var(--font-text);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--gold-bright);
    background: rgba(19, 30, 48, 0.4);
    border: 1.2px solid var(--gold);
    border-radius: 100px;
    padding: 11px 0;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.25);
    backdrop-filter: blur(4px);
}
.utility-btn span {
    font-size: 15px;
}
.utility-btn:hover {
    background: var(--gold);
    color: #060a12;
    box-shadow: 0 5px 15px rgba(197,160,89,0.3);
}

/* ====================================================
   INTERACTIVE RSVP FORM CARD (PDF STAMP STYLE)
   ==================================================== */
.form-card {
    background: rgba(15, 28, 48, 0.6);
    border: 1.2px solid rgba(197,160,89,0.25);
    border-radius: 8px;
    padding: 22px 18px;
    margin: 16px 0;
    text-align: left;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
    backdrop-filter: blur(6px);
}
.form-title {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-align: center;
    margin-bottom: 2px;
}
.form-sub {
    font-family: var(--font-text);
    font-size: 0.72rem;
    color: var(--text-muted);
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.35;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 14px;
}
.input-group label {
    font-family: var(--font-text);
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}
.input-group input[type="text"],
.input-group select,
.input-group textarea {
    width: 100%;
    background: #09101b;
    border: 1px solid rgba(197,160,89,0.25);
    border-radius: 4px;
    padding: 9px 12px;
    font-family: var(--font-text);
    font-size: 0.82rem;
    color: #fff;
    outline: none;
    transition: border-color 0.2s ease;
}
.input-group input[type="text"]::placeholder,
.input-group textarea::placeholder {
    color: #556c82;
    font-weight: 400;
}
.input-group input[type="text"]:focus,
.input-group select:focus,
.input-group textarea:focus {
    border-color: var(--gold);
}
.input-group select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23c5a059' viewBox='0 0 24 24'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
}

/* Submit button */
.submit-btn {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: var(--font-text);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #060a12;
    background: var(--gold);
    border: none;
    border-radius: 40px;
    padding: 12px 0;
    cursor: pointer;
    margin-top: 8px;
    transition: all 0.3s ease;
}
.submit-btn:hover {
    background: var(--gold-bright);
    box-shadow: 0 4px 12px rgba(197,160,89,0.3);
    transform: translateY(-1px);
}
.submit-btn:active {
    transform: translateY(0);
}

/* ====================================================
   GIFT REGISTRY SECTION (TOGGLE)
   ==================================================== */
.registry-section {
    margin: 18px 0;
    border-top: 1.2px solid rgba(197,160,89,0.18);
    padding-top: 18px;
}
.registry-toggle-btn {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    font-family: var(--font-text);
    font-size: 0.75rem;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    outline: none;
    padding: 4px 2px;
    letter-spacing: 1px;
}
.registry-toggle-btn:hover {
    color: var(--gold-bright);
}
.toggle-arrow {
    transition: transform 0.3s ease;
    color: var(--gold);
}
.registry-toggle-btn.active .toggle-arrow {
    transform: rotate(180deg);
}

.registry-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, margin-top 0.3s ease;
    text-align: left;
}
.registry-content.show {
    max-height: 240px;
    margin-top: 12px;
}
.registry-desc {
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.4;
    color: var(--text-muted);
    margin-bottom: 10px;
    padding: 0 4px;
}

.iban-card {
    background: rgba(9, 16, 27, 0.9);
    border: 1.2px dashed var(--gold);
    border-radius: 6px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.iban-label {
    font-family: var(--font-text);
    font-size: 0.55rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--gold);
}
.iban-val {
    font-family: var(--font-text);
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
    word-break: break-all;
}
.copy-iban-btn {
    align-self: flex-start;
    background: none;
    border: 1.2px solid rgba(197,160,89,0.4);
    border-radius: 100px;
    font-family: var(--font-text);
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--gold-bright);
    padding: 5px 12px;
    cursor: pointer;
    outline: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.copy-iban-btn:hover {
    background: var(--gold);
    color: #060a12;
}

/* Footer bow */
.footer-bow-container {
    margin-top: 18px;
    opacity: 0.9;
}

.bottom-flourish {
    text-align: center;
    margin-top: 16px;
    font-size: .8rem;
    color: var(--gold);
    letter-spacing: 8px;
    opacity: .6;
}

/* ====================================================
   SUCCESS OVERLAY MODAL (GLASS-MORPHIC DEEP BLUE)
   ==================================================== */
.success-overlay {
    position: fixed;
    inset: 0;
    background: rgba(6,10,18,0.92);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}
.success-overlay.show {
    opacity: 1;
    pointer-events: auto;
}
.success-card {
    background: linear-gradient(135deg, var(--navy-light) 0%, var(--bg-dark) 100%);
    border: 1.5px solid var(--gold);
    border-radius: 10px;
    padding: 30px 24px;
    width: calc(100% - 32px);
    max-width: 320px;
    text-align: center;
    box-shadow: 0 15px 40px rgba(0,0,0,0.6);
    transform: translateY(20px);
    transition: transform 0.4s ease;
}
.success-overlay.show .success-card {
    transform: translateY(0);
}
.success-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 12px;
    animation: iconBounce 1s ease infinite alternate;
    color: var(--gold);
}
@keyframes iconBounce {
    0% { transform: translateY(0); }
    100% { transform: translateY(-8px); }
}
.success-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--gold-bright);
    margin-bottom: 8px;
}
.success-msg {
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: #fff;
    line-height: 1.4;
    margin-bottom: 20px;
}
.success-close {
    font-family: var(--font-text);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--gold-bright);
    background: none;
    border: 1px solid var(--gold);
    border-radius: 100px;
    padding: 8px 22px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.success-close:hover {
    background: var(--gold);
    color: var(--bg-dark);
}

/* ====================================================
   OPENING TRANSITIONS
   ==================================================== */
.seal-tap-area.breaking {
    animation: sealBreak .6s ease forwards;
}
@keyframes sealBreak {
    0%   { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    30%  { transform: translate(-50%, -50%) scale(1.3); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(2); opacity: 0; }
}

.flash-overlay {
    position: fixed;
    inset: 0;
    background: rgba(253,239,191,.4);
    z-index: 100;
    animation: flashFade .8s ease forwards;
}
@keyframes flashFade {
    0% { opacity: 1; } 100% { opacity: 0; }
}

/* Staggered card contents */
.card-content > * {
    opacity: 0;
    transform: translateY(15px);
    transition: opacity .5s ease, transform .5s ease;
}
#invite-phase.active .card-content > * {
    opacity: 1;
    transform: translateY(0);
}
#invite-phase.active .card-content > *:nth-child(1)  { transition-delay: .2s; }
#invite-phase.active .card-content > *:nth-child(2)  { transition-delay: .4s; }
#invite-phase.active .card-content > *:nth-child(3)  { transition-delay: .6s; }
#invite-phase.active .card-content > *:nth-child(4)  { transition-delay: .8s; }
#invite-phase.active .card-content > *:nth-child(5)  { transition-delay: .9s; }
#invite-phase.active .card-content > *:nth-child(6)  { transition-delay: 1.0s; }
#invite-phase.active .card-content > *:nth-child(7)  { transition-delay: 1.1s; }
#invite-phase.active .card-content > *:nth-child(8)  { transition-delay: 1.2s; }

/* ====================================================
   RESPONSIVE
   ==================================================== */
@media (max-height: 820px) {
    .card-content { padding: 28px 18px 24px; }
    .pass-row { padding: 6px 4px; }
    .dress-code-box { margin: 20px 4px 12px; padding: 16px 12px 10px; }
    .form-card { margin: 14px 0; padding: 18px 14px; }
}

@media (max-height: 720px) {
    .pass-row { padding: 4px 2px; }
    .pass-icon-circle { width: 28px; height: 28px; }
    .pass-icon-circle span { font-size: 14px; }
    .pass-row-text { font-size: 0.8rem; }
    .dress-code-text { font-size: 0.76rem; }
}
