/* Custom CSS for Boho Pampas / Esat & Duygu Digital Invitation */
:root {
    --bg-color: #fdfbf7;
    --card-bg: #ffffff;
    --primary-color: #2c3e35; /* Deep Olive Green */
    --accent-color: #4a6b57;  /* Sage Green */
    --gold-color: #c5a059;    /* Elegant Gold */
    --gold-hover: #b08b46;
    --text-color: #333333;
    --text-muted: #666666;
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-script: 'Great Vibes', cursive;
    --font-sans: 'Montserrat', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --shadow-soft: 0 10px 30px rgba(0,0,0,0.06);
    --shadow-card: 0 15px 35px rgba(44, 62, 53, 0.08);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    background-image: radial-gradient(var(--gold-color) 0.5px, transparent 0.5px), radial-gradient(var(--gold-color) 0.5px, var(--bg-color) 0.5px);
    background-size: 30px 30px;
    background-position: 0 0, 15px 15px;
}

/* Floating Audio Control */
.music-toggle {
    position: fixed;
    top: 15px;
    right: 15px;
    z-index: 999;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--gold-color);
    border: 2px solid var(--gold-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.25);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.disc-icon.playing {
    animation: spin 3s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ENVELOPE OVERLAY */
.envelope-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(44, 62, 53, 0.96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.envelope-overlay.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.envelope-wrapper {
    text-align: center;
    perspective: 1000px;
    max-width: 380px;
    width: 90vw;
}

.envelope {
    width: 100%;
    height: 250px;
    background: #f4eee0;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    border: 1px solid var(--gold-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.envelope-front {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #faf6ee 0%, #ede3ce 100%);
    padding: 15px;
}

.envelope-flap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: #e2d5bd;
    clip-path: polygon(0 0, 100% 0, 50% 100%);
    transform-origin: top;
    transition: transform 0.6s ease;
    z-index: 2;
}

.wax-seal {
    width: 85px;
    height: 85px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 22px rgba(0,0,0,0.35);
    cursor: pointer;
    z-index: 3;
    animation: pulseSeal 2s infinite ease-in-out;
    background: #fff;
    padding: 2px;
    border: 2px solid var(--gold-color);
}

.seal-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

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

.envelope-text {
    margin-top: 18px;
    z-index: 3;
}

.invite-to {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    color: var(--primary-color);
    font-weight: 600;
}

.invite-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.open-btn {
    margin-top: 22px;
    background: linear-gradient(135deg, var(--gold-color) 0%, var(--gold-hover) 100%);
    color: #fff;
    border: none;
    padding: 14px 32px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(197, 160, 89, 0.4);
    transition: all 0.3s ease;
    width: 100%;
    max-width: 280px;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.envelope.opening .envelope-flap {
    transform: rotateX(180deg);
}

.envelope.opening .wax-seal {
    transform: scale(1.4);
    opacity: 0;
}

/* MAIN INVITATION CONTAINER */
.invitation-container {
    max-width: 640px;
    margin: 20px auto;
    padding: 35px 20px;
    background: var(--card-bg);
    border-radius: 20px;
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(197, 160, 89, 0.3);
    position: relative;
    overflow: hidden;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.invitation-container.hidden {
    opacity: 0;
    transform: translateY(30px);
}

/* BOTANICAL LEAF ACCENTS */
.leaf-bg {
    position: absolute;
    width: 120px;
    height: 120px;
    opacity: 0.1;
    pointer-events: none;
    background-repeat: no-repeat;
    background-size: contain;
}

.leaf-top-left {
    top: -15px;
    left: -15px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path fill="%234a6b57" d="M10,10 Q50,0 90,50 Q40,90 10,10 Z"/></svg>');
}

.leaf-top-right {
    top: -15px;
    right: -15px;
    transform: scaleX(-1);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path fill="%234a6b57" d="M10,10 Q50,0 90,50 Q40,90 10,10 Z"/></svg>');
}

.leaf-bottom-left {
    bottom: -15px;
    left: -15px;
    transform: scaleY(-1);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path fill="%234a6b57" d="M10,10 Q50,0 90,50 Q40,90 10,10 Z"/></svg>');
}

.leaf-bottom-right {
    bottom: -15px;
    right: -15px;
    transform: scale(-1);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path fill="%234a6b57" d="M10,10 Q50,0 90,50 Q40,90 10,10 Z"/></svg>');
}

/* HEADER SECTION */
.header-section {
    margin-bottom: 30px;
}

.luxury-seal-wrapper {
    display: inline-block;
    margin-bottom: 12px;
    position: relative;
}

.header-seal-img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
    border: 3px solid var(--gold-color);
}

.subtitle-tag {
    display: block;
    font-size: 0.75rem;
    letter-spacing: 4px;
    color: var(--gold-color);
    font-weight: 600;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.couple-names {
    font-family: var(--font-serif);
    font-size: 2.8rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 1.15;
}

.divider-line {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 16px 0;
}

.divider-line::before,
.divider-line::after {
    content: '';
    height: 1px;
    width: 60px;
    background: linear-gradient(to right, transparent, var(--gold-color), transparent);
}

.diamond {
    color: var(--gold-color);
    font-size: 0.65rem;
    margin: 0 10px;
}

.main-quote {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-style: italic;
    color: var(--text-color);
    max-width: 480px;
    margin: 0 auto;
    line-height: 1.5;
}

/* CARD BOX */
.card-box {
    background: #faf8f5;
    border: 1px solid rgba(197, 160, 89, 0.25);
    border-radius: 16px;
    padding: 24px 18px;
    margin-bottom: 30px;
}

/* FAMILY SECTION */
.section-title {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 18px;
}

.family-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 15px;
    text-align: center;
}

.family-side {
    font-size: 0.7rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--gold-color);
    font-weight: 600;
    display: block;
    margin-bottom: 4px;
}

.parents-name {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    color: var(--primary-color);
    font-weight: 600;
}

.parents-name small {
    font-size: 0.75rem;
    font-style: italic;
    color: var(--text-muted);
}

.family-surname {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--gold-color);
    letter-spacing: 1px;
    margin-top: 2px;
}

.family-divider {
    width: 1px;
    height: 50px;
    background: linear-gradient(to bottom, transparent, var(--gold-color), transparent);
}

/* EVENTS SECTION */
.section-intro {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 25px;
}

.events-container {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.event-card {
    background: #ffffff;
    border: 1px solid rgba(74, 107, 87, 0.2);
    border-radius: 16px;
    padding: 24px 20px;
    position: relative;
    box-shadow: var(--shadow-soft);
}

.event-badge {
    position: absolute;
    top: -12px;
    left: 20px;
    background: var(--accent-color);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 14px;
    border-radius: 20px;
    letter-spacing: 1px;
}

.badge-purple {
    background: #6b4a69;
}

.event-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 1px stroke rgba(0,0,0,0.05);
}

.event-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f2f7f4;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.event-type {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: var(--primary-color);
}

.event-details {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}

.detail-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.detail-row i {
    color: var(--gold-color);
    font-size: 1.1rem;
    margin-top: 3px;
    flex-shrink: 0;
}

.date-highlight {
    font-size: 1.05rem;
    color: var(--primary-color);
    display: block;
}

.address-text {
    font-size: 0.9rem;
    color: var(--text-color);
    margin-top: 2px;
}

/* COUNTDOWN TIMER */
.countdown-wrapper {
    background: #fdfbf7;
    border-radius: 12px;
    padding: 14px 10px;
    text-align: center;
    margin-bottom: 20px;
    border: 1px stroke rgba(197, 160, 89, 0.3);
}

.countdown-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gold-color);
    font-weight: 600;
    display: block;
    margin-bottom: 8px;
}

.timer {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.time-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 48px;
}

.time-block span {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
}

.time-block label {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 3px;
}

/* BUTTONS */
.card-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s ease;
    border: none;
    width: 100%;
    min-height: 44px;
}

.btn-primary {
    background: var(--accent-color);
    color: #ffffff;
}

.btn-secondary {
    background: #333333;
    color: #ffffff;
}

.btn-outline {
    background: transparent;
    border: 1.5px solid var(--gold-color);
    color: var(--gold-color);
}

.btn-outline:active {
    background: var(--gold-color);
    color: #ffffff;
}

/* FOOTER & SHARE */
.footer-section {
    margin-top: 30px;
    border-top: 1px stroke #eee;
    padding-top: 25px;
}

.share-box {
    background: #fdfbf7;
    border: 1px dashed var(--gold-color);
    border-radius: 12px;
    padding: 20px 15px;
    margin-bottom: 25px;
}

.share-box h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.share-box p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.share-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-share {
    padding: 12px 20px;
    border-radius: 30px;
}

.btn-wa-share {
    background: #25D366;
    color: #fff;
}

.btn-copy {
    background: var(--gold-color);
    color: #fff;
}

.brand-footer {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.platform-link {
    display: inline-block;
    margin-top: 6px;
    color: var(--accent-color);
    text-decoration: none;
}

.toast {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--primary-color);
    color: #fff;
    padding: 10px 22px;
    border-radius: 30px;
    font-size: 0.85rem;
    opacity: 0;
    transition: all 0.4s ease;
    z-index: 2000;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

@media (min-width: 601px) {
    .invitation-container {
        margin: 40px auto;
        padding: 40px 30px;
    }

    .card-actions {
        flex-direction: row;
    }

    .card-actions .btn {
        flex: 1;
    }

    .share-buttons {
        flex-direction: row;
        justify-content: center;
    }

    .share-buttons .btn {
        width: auto;
    }
}
