/* ═══════════════════════════════════════════════════════════════
   Wedding Day Planner — Stylesheet
   Aesthetic: Soft romantic, pastel warmth, elegant serif typography
   ═══════════════════════════════════════════════════════════════ */

:root {
    --blush: #f2e1de;
    --rose: #c9a4a4;
    --rose-dk: #9b7a7a;
    --cream: #fdf8f5;
    --sage: #c5cfc0;
    --gold: #d4b896;
    --lav: #d8cfe5;
    --txt: #4a3f3f;
    --txt-l: #8a7575;
    --wh: #ffffff;
    --ff: 'Cormorant Garamond', 'Georgia', serif;
    --ff2: 'Lora', 'Georgia', serif;
}

/* ─── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: var(--ff);
    color: var(--txt);
    background: var(--cream);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

/* ─── Animations ─────────────────────────────────────────────── */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeIn 0.5s ease-out; }

/* ─── Auth Pages ─────────────────────────────────────────────── */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--cream) 0%, rgba(242,225,222,0.5) 50%, rgba(216,207,229,0.4) 100%);
    padding: 20px;
}
.auth-card {
    background: rgba(255,255,255,0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 44px 38px;
    max-width: 440px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(155,122,122,0.12), 0 0 0 1px rgba(201,164,164,0.15);
}
.auth-icon { font-size: 48px; margin-bottom: 8px; }
.auth-title { font-size: 32px; font-weight: 700; color: var(--rose-dk); margin-bottom: 4px; }
.auth-subtitle { font-size: 17px; color: var(--txt-l); font-style: italic; font-family: var(--ff2); }
.auth-desc { font-size: 17px; color: var(--txt-l); margin: 12px 0; }

.heart-divider { text-align: center; margin: 10px 0; opacity: 0.3; }

/* Type selector buttons */
.type-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 16px 20px;
    border: 1.5px solid var(--blush);
    border-radius: 14px;
    background: var(--wh);
    text-align: left;
    transition: all 0.15s ease;
    cursor: pointer;
}
.type-btn:hover {
    border-color: var(--rose);
    box-shadow: 0 4px 12px rgba(155,122,122,0.1);
    transform: translateY(-1px);
}
.type-icon { font-size: 28px; flex-shrink: 0; }
.type-label { display: block; font-size: 22px; font-weight: 700; color: var(--rose-dk); }
.type-desc { display: block; font-size: 15px; color: var(--txt-l); font-family: var(--ff2); }

/* Back link */
.back-link {
    display: inline-block;
    font-size: 13px;
    color: var(--txt-l);
    margin-bottom: 8px;
    transition: color 0.15s;
}
.back-link:hover { color: var(--rose-dk); }

/* ─── Form Fields (shared) ───────────────────────────────────── */
.field-group { text-align: left; margin-bottom: 16px; }
.field-label {
    display: block;
    font-size: 17px;
    font-weight: 600;
    color: var(--rose-dk);
    margin-bottom: 6px;
    letter-spacing: 0.3px;
    line-height: 1.4;
}
.field-input, .field-textarea, .field-select {
    width: 100%;
    padding: 13px 16px;
    border: 1.5px solid var(--blush);
    border-radius: 10px;
    font-size: 17px;
    font-family: var(--ff2);
    background: var(--wh);
    color: var(--txt);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.field-input:focus, .field-textarea:focus, .field-select:focus {
    border-color: var(--rose);
    box-shadow: 0 0 0 3px rgba(201,164,164,0.15);
}
.field-textarea { resize: vertical; }
.field-select { cursor: pointer; }

/* ─── Buttons ────────────────────────────────────────────────── */
.primary-btn {
    display: block;
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: 12px;
    font-size: 19px;
    font-weight: 700;
    font-family: var(--ff);
    cursor: pointer;
    margin-top: 10px;
    background: linear-gradient(135deg, var(--rose), var(--rose-dk));
    color: var(--wh);
    letter-spacing: 0.5px;
    transition: transform 0.1s, box-shadow 0.2s;
}
.primary-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(155,122,122,0.25);
}
.primary-btn:active { transform: translateY(0); }

.switch-text { font-size: 16px; color: var(--txt-l); margin-top: 16px; font-family: var(--ff2); }
.switch-link { color: var(--rose-dk); font-weight: 700; text-decoration: underline; }
.switch-link:hover { color: var(--txt); }

.error-msg {
    color: #c0392b;
    font-size: 15px;
    margin: 8px 0;
    background: #fde8e8;
    padding: 12px 16px;
    border-radius: 8px;
    text-align: left;
}

/* ─── App Layout ─────────────────────────────────────────────── */
.app-wrapper {
    min-height: 100vh;
    background: linear-gradient(180deg, var(--cream) 0%, rgba(242,225,222,0.3) 100%);
}

/* Header */
.app-header {
    background: rgba(255,255,255,0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 14px 20px 12px;
    border-bottom: 1px solid var(--blush);
    position: sticky;
    top: 0;
    z-index: 100;
}
.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    max-width: 1100px;
    margin: 0 auto;
}
.header-title { font-size: 24px; font-weight: 700; color: var(--rose-dk); }
.header-sub { font-size: 15px; color: var(--txt-l); margin-top: 2px; font-style: italic; font-family: var(--ff2); }
.header-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.header-btn {
    display: inline-block;
    padding: 9px 18px;
    border: 1.5px solid var(--rose);
    border-radius: 8px;
    background: var(--wh);
    color: var(--rose-dk);
    font-weight: 600;
    font-size: 15px;
    font-family: var(--ff);
    cursor: pointer;
    transition: all 0.15s;
}
.header-btn:hover { background: var(--blush); }
.logout-btn {
    display: inline-block;
    padding: 9px 18px;
    border: none;
    border-radius: 8px;
    background: var(--blush);
    color: var(--rose-dk);
    font-weight: 600;
    font-size: 15px;
    font-family: var(--ff);
    cursor: pointer;
    transition: background 0.15s;
}
.logout-btn:hover { background: var(--rose); color: var(--wh); }

/* Progress bar */
.progress-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}
.progress-bar { flex: 1; height: 5px; background: var(--blush); border-radius: 3px; overflow: hidden; }
.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--rose), var(--gold));
    border-radius: 3px;
    transition: width 0.5s ease;
}
.progress-text {
    font-size: 14px;
    color: var(--txt-l);
    font-weight: 600;
    min-width: 85px;
    text-align: right;
    font-family: var(--ff2);
}

/* Main Layout: Sidebar + Form */
.main-layout {
    display: flex;
    max-width: 1100px;
    margin: 0 auto;
}

/* ─── Sidebar ────────────────────────────────────────────────── */
.sidebar {
    width: 280px;
    min-width: 280px;
    background: rgba(255,255,255,0.5);
    border-right: 1px solid var(--blush);
    min-height: calc(100vh - 100px);
    overflow-y: auto;
    padding: 12px 8px;
    position: sticky;
    top: 80px;
    align-self: flex-start;
}
.side-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 11px 12px;
    border: none;
    border-radius: 8px;
    background: transparent;
    font-family: var(--ff);
    font-size: 16px;
    color: var(--txt);
    text-align: left;
    margin-bottom: 2px;
    transition: all 0.12s;
}
.side-item:hover { background: rgba(255,255,255,0.7); }
.side-item.active {
    background: var(--wh);
    box-shadow: 0 2px 6px rgba(201,164,164,0.12), inset 3px 0 0 var(--rose);
    font-weight: 700;
    color: var(--rose-dk);
}
.side-icon { font-size: 18px; width: 26px; text-align: center; flex-shrink: 0; }
.side-label { flex: 1; line-height: 1.3; }
.side-badge {
    font-size: 13px;
    color: var(--txt-l);
    background: var(--blush);
    border-radius: 5px;
    padding: 2px 8px;
    font-weight: 600;
    font-family: var(--ff2);
}

/* ─── Form Area ──────────────────────────────────────────────── */
.form-area { flex: 1; padding: 24px 28px 50px; max-width: 720px; }
.form-field { margin-bottom: 18px; }

.section-header { display: flex; align-items: center; gap: 10px; }
.section-icon { font-size: 36px; }
.section-title { font-size: 28px; font-weight: 700; color: var(--rose-dk); }

.save-row { display: flex; align-items: center; gap: 12px; margin-top: 20px; }
.save-btn {
    padding: 14px 32px;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 700;
    font-family: var(--ff);
    cursor: pointer;
    background: linear-gradient(135deg, var(--rose), var(--rose-dk));
    color: var(--wh);
    transition: transform 0.1s;
}
.save-btn:hover { transform: translateY(-1px); }
.save-status { font-size: 15px; color: var(--sage); font-style: italic; font-family: var(--ff2); }

.nav-row {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--blush);
}
.nav-back {
    padding: 12px 24px;
    border: 1.5px solid var(--rose);
    border-radius: 8px;
    background: var(--wh);
    color: var(--rose-dk);
    font-weight: 600;
    font-size: 16px;
    font-family: var(--ff);
    transition: all 0.15s;
}
.nav-back:hover { background: var(--blush); }
.nav-next {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    font-family: var(--ff);
    background: linear-gradient(135deg, var(--rose), var(--rose-dk));
    color: var(--wh);
    transition: transform 0.1s;
}
.nav-next:hover { transform: translateY(-1px); }

/* Mobile section picker */
.mobile-pick {
    display: none;
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1.5px solid var(--blush);
    font-size: 17px;
    font-family: var(--ff);
    background: var(--wh);
    margin-bottom: 14px;
}

/* ─── DJ Admin ───────────────────────────────────────────────── */
.couple-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--wh);
    border-radius: 14px;
    border: 1px solid var(--blush);
    margin-bottom: 10px;
    transition: box-shadow 0.15s, transform 0.1s;
    cursor: pointer;
}
.couple-card:hover {
    box-shadow: 0 4px 16px rgba(155,122,122,0.12);
    transform: translateY(-1px);
}
.couple-name { font-size: 20px; font-weight: 700; color: var(--rose-dk); }
.couple-meta { font-size: 15px; color: var(--txt-l); margin: 4px 0 8px; font-family: var(--ff2); }
.mini-progress { height: 4px; background: var(--blush); border-radius: 2px; overflow: hidden; width: 200px; max-width: 100%; }
.mini-fill { height: 100%; background: linear-gradient(90deg, var(--rose), var(--gold)); border-radius: 2px; }
.couple-arrow { font-size: 20px; color: var(--rose); }

/* Detail sections */
.detail-section-card {
    margin-bottom: 14px;
    background: var(--wh);
    border-radius: 12px;
    padding: 14px 18px;
    border: 1px solid var(--blush);
}
.detail-section-title {
    font-size: 19px;
    font-weight: 700;
    color: var(--rose-dk);
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--blush);
}
.detail-row-item { margin-bottom: 10px; }
.detail-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--txt-l);
}
.detail-value { font-size: 17px; color: var(--txt); line-height: 1.4; }

/* ─── QR Box ─────────────────────────────────────────────────── */
.qr-box {
    background: var(--cream);
    border-radius: 14px;
    padding: 24px;
    border: 1px solid var(--blush);
    text-align: center;
    margin-bottom: 20px;
}

/* ─── Song Request Cards ─────────────────────────────────────── */
.request-card {
    padding: 12px 16px;
    background: var(--wh);
    border-radius: 10px;
    border: 1px solid var(--blush);
    margin-bottom: 8px;
}

/* ─── Timeline ───────────────────────────────────────────────── */
.timeline { position: relative; padding-left: 44px; }
.timeline-line {
    position: absolute;
    left: 18px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(var(--rose), var(--gold));
    border-radius: 2px;
}
.timeline-event { position: relative; margin-bottom: 16px; }
.timeline-dot {
    position: absolute;
    left: -36px;
    top: 4px;
    width: 28px;
    height: 28px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.timeline-card {
    background: var(--wh);
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    border: 1px solid var(--blush);
}
.timeline-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}
.timeline-card-header strong { font-size: 18px; color: var(--rose-dk); }
.timeline-time {
    font-size: 15px;
    color: var(--gold);
    font-weight: 700;
    background: rgba(212,184,150,0.15);
    padding: 3px 10px;
    border-radius: 6px;
    white-space: nowrap;
}
.timeline-detail {
    font-size: 15px;
    color: var(--txt);
    line-height: 1.5;
    font-family: var(--ff2);
}

/* ─── Responsive ─────────────────────────────────────────────── */
.desk-only {}
.mob-only { display: none !important; }

/* Tablet (768px and below) */
@media (max-width: 768px) {
    .desk-only { display: none !important; }
    .mob-only { display: block !important; }
    .mobile-pick { display: block; }

    .main-layout { flex-direction: column; }
    .sidebar { display: none; }
    .form-area { padding: 20px 18px 40px; max-width: 100%; }

    .auth-card { padding: 32px 24px; max-width: 100%; }
    .auth-title { font-size: 26px; }
    .header-inner { flex-direction: column; align-items: flex-start; }
    .header-actions { width: 100%; flex-wrap: wrap; }
    .header-btn, .logout-btn { font-size: 14px; padding: 10px 14px; flex: 1; text-align: center; min-width: 0; }

    .section-title { font-size: 24px; }
    .section-icon { font-size: 30px; }

    .couple-card { flex-direction: column; align-items: flex-start; }
    .couple-arrow { display: none; }
    .mini-progress { width: 100%; }

    .nav-row { flex-wrap: wrap; }
    .nav-back, .nav-next { flex: 1; text-align: center; }

    .qr-box { padding: 16px; }
    .qr-box img { max-width: 160px; }

    .timeline { padding-left: 36px; }
    .timeline-dot { left: -30px; width: 24px; height: 24px; font-size: 11px; }
    .timeline-card { padding: 10px 14px; }
    .timeline-card-header { flex-direction: column; align-items: flex-start; gap: 4px; }

    .detail-section-card { padding: 12px 14px; }

    .type-btn { padding: 14px 16px; }
    .type-label { font-size: 19px; }
    .type-desc { font-size: 14px; }

    .progress-bar { height: 6px; }
}

/* Small phones (480px and below) */
@media (max-width: 480px) {
    .auth-wrapper { padding: 12px; }
    .auth-card { padding: 28px 18px; border-radius: 18px; }
    .auth-title { font-size: 22px; }
    .auth-subtitle { font-size: 15px; }
    .auth-icon { font-size: 40px; }

    .app-header { padding: 12px 14px 10px; }
    .header-title { font-size: 20px; }
    .header-sub { font-size: 13px; }
    .header-actions { gap: 4px; }
    .header-btn, .logout-btn { font-size: 13px; padding: 8px 10px; }

    .form-area { padding: 14px 12px 40px; }
    .section-title { font-size: 20px; }
    .section-icon { font-size: 26px; }
    .field-label { font-size: 15px; }
    .field-input, .field-textarea, .field-select { font-size: 16px; padding: 12px; }

    .save-btn { font-size: 15px; padding: 12px 20px; width: 100%; }
    .save-row { flex-direction: column; align-items: stretch; }

    .nav-row { flex-direction: column; }
    .nav-back, .nav-next { width: 100%; text-align: center; }

    .mobile-pick { font-size: 15px; padding: 11px; }

    .type-btn { gap: 10px; padding: 12px 14px; }
    .type-icon { font-size: 24px; }
    .type-label { font-size: 17px; }
    .type-desc { font-size: 13px; }

    .couple-card { padding: 14px; }
    .couple-name { font-size: 18px; }
    .couple-meta { font-size: 13px; }

    .detail-section-title { font-size: 16px; }
    .detail-label { font-size: 12px; }
    .detail-value { font-size: 15px; }

    .timeline-card-header strong { font-size: 15px; }
    .timeline-time { font-size: 13px; }
    .timeline-detail { font-size: 13px; }

    .primary-btn { font-size: 17px; padding: 14px; }
    .switch-text { font-size: 14px; }
    .progress-text { font-size: 13px; }
}

/* Large desktop (1200px+) */
@media (min-width: 1200px) {
    .form-area { padding: 28px 40px 60px; }
    .sidebar { width: 300px; min-width: 300px; }
}

/* ─── Print ──────────────────────────────────────────────────── */
@media print {
    .no-print,
    .app-header,
    .sidebar,
    .mobile-pick,
    .nav-row,
    .save-row,
    .header-actions { display: none !important; }

    body { background: #fff; }
    .app-wrapper { background: #fff; }
    .form-area { padding: 0; max-width: 100%; }
}

/* ─── Success Animation ──────────────────────────────────────── */
@keyframes checkPop {
    0%   { transform: scale(0); }
    70%  { transform: scale(1.2); }
    100% { transform: scale(1); }
}
.save-success { animation: checkPop 0.3s ease-out; color: var(--sage); }
