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

body {
    margin: 0;
    font-family: system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;
    background: #f3f4f6;
    color: #111827;
}

/* Landing */
.landing-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at top, #e0f2fe, #f9fafb);
}
.landing-wrapper {
    max-width: 420px;
    width: 100%;
    padding: 1.5rem;
}
.landing-card {
    background: #ffffff;
    border-radius: 1.25rem;
    padding: 1.5rem 1.75rem;
    box-shadow: 0 24px 60px rgba(15,23,42,0.1);
}
.landing-card h1 {
    margin-top: 0;
    margin-bottom: 0.4rem;
    font-size: 1.5rem;
}
.landing-card p { margin-top: 0; color: #6b7280; font-size: 0.95rem; }
.landing-form .form-group { margin-bottom: 0.9rem; }
.form-group label { display:block; font-size:0.8rem; margin-bottom:0.2rem; color:#4b5563; }
.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    border-radius: 0.8rem;
    border: 1px solid #e5e7eb;
    padding: 0.5rem 0.65rem;
    font-size: 0.9rem;
}
.form-group textarea { min-height: 80px; resize: vertical; }
.form-actions { margin-top: 0.6rem; }
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid #3b82f6;
    background: #3b82f6;
    color: #f9fafb;
    padding: 0.4rem 1.1rem;
    font-size: 0.9rem;
    cursor: pointer;
}
.btn-primary:hover { filter: brightness(0.9); }
.btn-whatsapp {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid #16a34a;
    background: #22c55e;
    color: #f9fafb;
    padding: 0.4rem 1.1rem;
    font-size: 0.9rem;
    text-decoration:none;
}
.landing-links { margin-top:1rem; font-size:0.85rem; text-align:center; }
.landing-links a { color:#3b82f6; text-decoration:none; }
.landing-links a:hover { text-decoration:underline; }

/* Invitation */
.invitation-wrapper {
    min-height: 100vh;
    display:flex;
    align-items:center;
    justify-content:center;
    padding: 1rem;
}
.invitation-book {
    width: 100%;
    max-width: 640px;
    position: relative;
}
.open-cover {
    position: relative;
    z-index: 20;
}
.wd-content {
    margin-top: 1rem;
    border-radius: 1.5rem;
    background: rgba(255,255,255,0.9);
    box-shadow: 0 20px 50px rgba(15,23,42,0.25);
    padding: 1.5rem 1.4rem 1.7rem;
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 10;
}

/* Envelope */
.envelope {
    position: relative;
    width: 100%;
    padding: 1.5rem 1.4rem 1.6rem;
    border-radius: 1.5rem;
    background: linear-gradient(135deg, #f9fafb, #e5e7eb);
    box-shadow: 0 24px 60px rgba(15,23,42,0.3);
    overflow: hidden;
}
.envelope-flap {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 0 0, rgba(129,140,248,0.18), transparent 55%),
                radial-gradient(circle at 100% 0, rgba(236,72,153,0.2), transparent 60%);
    opacity: 0.8;
}
.envelope-paper {
    position: relative;
    border-radius: 1.3rem;
    background: rgba(249,250,251,0.95);
    padding: 1.2rem 1.1rem 1.4rem;
}
.envelope-text {
    text-align: center;
}
.envelope-text .small-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: #9ca3af;
    margin-bottom: 0.3rem;
}
.envelope-text .names-script {
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}
.envelope-text .date-line {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.7rem;
}
.open-btn { margin-top: 0.3rem; }

/* Switch cover -> content */
.invitation-book.book-opened .open-cover {
    display: none;
}

/* Sections */
.wd-section {
    margin-bottom: 1.1rem;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.55s ease, transform 0.55s ease;
}
.wd-section.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.wd-section-card {
    background: rgba(255,255,255,0.9);
    border-radius: 1.2rem;
    padding: 1rem 1rem 1rem;
    border: 1px solid rgba(148,163,184,0.35);
}
.wd-section-title {
    margin-top: 0;
    margin-bottom: 0.4rem;
    font-size: 1.1rem;
}
.wd-section-text {
    margin-top: 0;
    font-size: 0.9rem;
    color: #4b5563;
}

/* Hero */
.wd-hero-section {
    position: relative;
    margin-bottom: 1.2rem;
}
.wd-hero-bg {
    position: absolute;
    inset: 0;
    border-radius: 1.2rem;
    background: radial-gradient(circle at top, rgba(129,140,248,0.25), transparent 60%),
                radial-gradient(circle at bottom, rgba(248,250,252,0.9), #e5e7eb);
    z-index: -1;
}
.wd-hero-card {
    padding: 1.1rem 1.2rem;
    border-radius: 1.2rem;
    border: 1px solid rgba(148,163,184,0.4);
    background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(249,250,251,0.95));
}
.wd-hero-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: #9ca3af;
}
.wd-hero-names {
    margin: 0.15rem 0 0.25rem;
    font-size: 1.5rem;
    font-family: "Cormorant Garamond", "Times New Roman", serif;
}
.wd-hero-date {
    font-size: 0.9rem;
    color: #6b7280;
    margin-bottom: 0.15rem;
}
.wd-hero-venue {
    font-size: 0.9rem;
    color: #4b5563;
}

/* Petals background decorative */
.wd-hero-petals {
    position:absolute;
    inset:0;
    pointer-events:none;
    background-image:
        radial-gradient(circle at 10% 10%, rgba(244,114,182,0.4) 0, transparent 55%),
        radial-gradient(circle at 90% 0, rgba(129,140,248,0.35) 0, transparent 60%);
    opacity:0.4;
    z-index:-2;
}

/* Guest card (kepada Yth) */
.wd-guest-card {
    margin-top: 1.3rem;
    padding: 0.8rem 1.1rem;
    border-radius: 1rem;
    background: rgba(15,23,42,0.03);
    border: 1px dashed rgba(148,163,184,0.7);
}
.wd-guest-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: #9ca3af;
    margin-bottom: 0.1rem;
}
.wd-guest-name {
    font-size: 1rem;
    font-weight: 600;
    color: #111827;
}
.wd-guest-sub {
    font-size: 0.8rem;
    color: #6b7280;
}

/* Couple section */
.wd-couple-card { position: relative; }
.wd-couple-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.4rem;
    margin-top: 0.6rem;
}
.wd-person { text-align: center; }
.wd-person-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #9ca3af;
    margin-bottom: 0.2rem;
}
.wd-person-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}
.wd-person-desc {
    font-size: 0.9rem;
    color: #6b7280;
}

/* Countdown */
.wd-countdown-card { text-align: center; }
#countdown {
    display: inline-flex;
    gap: 0.8rem;
    margin-top: 0.5rem;
}
#countdown .cd-item {
    min-width: 60px;
    padding: 0.45rem 0.5rem;
    border-radius: 0.9rem;
    background: #0f172a;
    color: #e5e7eb;
    display: flex;
    flex-direction: column;
    align-items: center;
}
#countdown .cd-item span {
    font-size: 1.1rem;
    font-weight: 600;
}
#countdown .cd-item small {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    opacity: 0.8;
}
@media (max-width: 480px) {
    #countdown { gap: 0.4rem; }
    #countdown .cd-item {
        min-width: 52px;
        padding: 0.3rem 0.4rem;
    }
}

/* Info grid */
.wd-info-grid {
    display:grid;
    grid-template-columns: repeat(auto-fit, minmax(150px,1fr));
    gap:0.9rem;
    margin-top:0.6rem;
    font-size:0.9rem;
}
.wd-info-grid h3 {
    margin:0 0 0.15rem;
    font-size:0.9rem;
}
.wd-info-grid p {
    margin:0;
    color:#4b5563;
}
.wd-maps-wrapper { margin-top:0.8rem; }
.wd-maps-embed iframe {
    width:100%;
    border:0;
    border-radius:1rem;
    min-height:230px;
}
.wd-cta-row {
    margin-top:0.8rem;
}

/* Forms */
.wd-form-grid .form-group { margin-bottom:0.6rem; }
.wd-form-grid .form-group label {
    display:block;
    font-size:0.8rem;
    margin-bottom:0.15rem;
    color:#4b5563;
}
.wd-form-grid input,
.wd-form-grid textarea,
.wd-form-grid select {
    width:100%;
    border-radius:0.75rem;
    border:1px solid #e5e7eb;
    padding:0.45rem 0.6rem;
    font-size:0.9rem;
}
.wd-form-grid textarea {
    min-height:80px;
    resize:vertical;
}
.wd-soft-bg {
    background: linear-gradient(135deg, rgba(239,246,255,0.9), rgba(248,250,252,0.95));
}
.wd-rsvp-stats {
    margin-top:0.5rem;
    font-size:0.85rem;
    color:#4b5563;
    display:flex;
    flex-wrap:wrap;
    gap:0.6rem;
}

/* Wishes */
.wd-wishes-list {
    margin-top:0.7rem;
    max-height:260px;
    overflow:auto;
}
.wd-wish-item {
    padding:0.45rem 0.5rem;
    border-bottom:1px solid #e5e7eb;
}
.wd-wish-name {
    font-weight:600;
    font-size:0.9rem;
}
.wd-wish-message {
    font-size:0.9rem;
    color:#4b5563;
}
.wd-wish-date {
    font-size:0.75rem;
    color:#9ca3af;
}

/* Gift */
.wd-gift-grid {
    display:grid;
    grid-template-columns: repeat(auto-fit, minmax(190px,1fr));
    gap:0.7rem;
    margin-top:0.6rem;
}
.wd-gift-card {
    border-radius:0.9rem;
    border:1px dashed #d1d5db;
    padding:0.6rem 0.7rem;
    font-size:0.9rem;
}
.wd-qris-wrapper {
    margin-top:0.8rem;
    text-align:center;
}
.wd-qris-image {
    max-width:220px;
    width:100%;
    border-radius:0.8rem;
    border:1px solid #e5e7eb;
}

/* Footer */
.inv-footer {
    margin-top:0.8rem;
    font-size:0.8rem;
    color:#9ca3af;
    text-align:center;
}

/* Music player */
.music-player {
    position:fixed;
    right:1rem;
    bottom:1rem;
    z-index:50;
}
#music-toggle {
    width:42px;
    height:42px;
    border-radius:999px;
    border:none;
    background:#111827;
    color:#f9fafb;
    cursor:pointer;
    box-shadow:0 10px 25px rgba(15,23,42,0.4);
    opacity:0.7;
}

/* Lang switch */
.lang-switch {
    position:fixed;
    top:0.6rem;
    right:0.8rem;
    font-size:0.8rem;
    z-index:60;
}
.lang-switch a {
    color:#4b5563;
    text-decoration:none;
}
.lang-switch a:hover { text-decoration:underline; }

/* Simple alerts */
.alert {
    border-radius:0.75rem;
    padding:0.45rem 0.7rem;
    font-size:0.85rem;
    margin-bottom:0.5rem;
}
.alert-success {
    background:#dcfce7;
    border:1px solid #22c55e;
    color:#166534;
}

/* Simple table for admin/client */
.table {
    width:100%;
    border-collapse:collapse;
    font-size:0.9rem;
}
.table th,
.table td {
    border:1px solid #e5e7eb;
    padding:0.4rem 0.5rem;
}
.table th {
    background:#f3f4f6;
    text-align:left;
}
.badge {
    display:inline-block;
    padding:0.1rem 0.4rem;
    border-radius:999px;
    font-size:0.75rem;
}
.badge-success { background:#dcfce7; color:#166534; }
.badge-warning { background:#fef9c3; color:#854d0e; }
.badge-danger  { background:#fee2e2; color:#b91c1c; }

/* Layout for admin/client */
.page-wrap {
    max-width:980px;
    margin:1.2rem auto;
    padding:0 1rem;
}
.card {
    background:#ffffff;
    border-radius:1rem;
    padding:1rem 1.1rem 1.2rem;
    box-shadow:0 10px 30px rgba(15,23,42,0.1);
}
.card-header {
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:0.7rem;
}
.card-header h1,
.card-header h2 {
    margin:0;
    font-size:1.2rem;
}
.link { color:#3b82f6; text-decoration:none; font-size:0.85rem; }
.link:hover { text-decoration:underline; }
.nav-top {
    margin-bottom:0.8rem;
    font-size:0.85rem;
}
.nav-top a { margin-right:0.6rem; color:#3b82f6; text-decoration:none; }
.nav-top a:hover { text-decoration:underline; }
