/* ============================================================
   MONITOR TERMINÓW v2 — Design System (dark theme)
   ============================================================ */

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

:root {
    --bg:         #0f172a;
    --surface:    #1e293b;
    --surface2:   #263347;
    --border:     #334155;
    --text:       #f1f5f9;
    --text-muted: #94a3b8;
    --text-dim:   #475569;
    --primary:    #3b82f6;
    --primary-h:  #2563eb;
    --success:    #10b981;
    --danger:     #ef4444;
    --warning:    #f59e0b;
    --radius:     10px;
    --radius-lg:  16px;
}

html { font-size: 16px; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.5;
    min-height: 100vh;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    height: 60px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    gap: 8px;
}
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 16px;
    color: var(--text);
    text-decoration: none;
    flex-shrink: 0;
    min-width: 0;
}
.navbar-brand:hover { text-decoration: none; opacity: .85; }
.brand-icon { font-size: 18px; flex-shrink: 0; }
.brand-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.brand-badge {
    font-size: 10px;
    font-weight: 700;
    background: var(--warning);
    color: #000;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}
.navbar-user {
    color: var(--text-muted);
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

/* Mobile navbar — ukryj nazwę marki na bardzo małych ekranach */
@media (max-width: 480px) {
    .brand-name { display: none; }
    .navbar-actions .btn { padding: 6px 10px; font-size: 12px; }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: var(--radius);
    border: 1px solid transparent;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    line-height: 1;
    white-space: nowrap;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary  { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover:not(:disabled) { background: var(--primary-h); border-color: var(--primary-h); }
.btn-ghost    { background: transparent; color: var(--text-muted); border-color: var(--border); }
.btn-ghost:hover:not(:disabled) { background: var(--surface2); color: var(--text); }
.btn-danger   { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover:not(:disabled) { background: rgba(239,68,68,.1); }
.btn-sm  { padding: 6px 12px; font-size: 13px; }
.btn-lg  { padding: 13px 26px; font-size: 16px; }

/* ============================================================
   LANDING
   ============================================================ */
.landing { max-width: 960px; margin: 0 auto; padding: 60px 24px; }

.hero { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; margin-bottom: 80px; }
@media (max-width: 700px) { .hero { grid-template-columns: 1fr; gap: 40px; } }

.hero-tag {
    display: inline-block;
    background: rgba(59,130,246,.15);
    color: var(--primary);
    border: 1px solid rgba(59,130,246,.3);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 20px;
}
.hero-title { font-size: 42px; font-weight: 800; line-height: 1.15; margin-bottom: 16px; }
@media (max-width: 700px) { .hero-title { font-size: 30px; } }
.hero-desc { color: var(--text-muted); font-size: 17px; line-height: 1.65; margin-bottom: 28px; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; }

/* Hero tag dot */
.hero-tag { display: inline-flex; align-items: center; gap: 7px; }
.hero-tag-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--primary);
    display: inline-block;
    animation: pulse 2s infinite;
}

/* ============================================================
   HERO LIVE BOX
   ============================================================ */
.hero-live {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
}
.live-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}
.live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    flex-shrink: 0;
    animation: pulse 2s infinite;
}
.live-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--success);
}
.live-countdown-row {
    display: flex;
    gap: 24px;
    margin-bottom: 16px;
}
.live-stat { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.live-stat-val {
    font-size: 30px;
    font-weight: 800;
    color: var(--text);
    font-variant-numeric: tabular-nums;
    line-height: 1.1;
}
.live-stat-label { font-size: 12px; color: var(--text-muted); }
.live-last-check {
    font-size: 12px;
    color: var(--text-dim);
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
}
.live-last-check span { color: var(--text-muted); }
.live-facts {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.live-fact {
    font-size: 12px;
    color: var(--text-muted);
    background: var(--surface2);
    padding: 5px 10px;
    border-radius: 6px;
}
.live-fact strong { color: var(--text); }

/* ============================================================
   CATEGORIES SECTION
   ============================================================ */
.categories-section {
    margin-bottom: 64px;
    text-align: center;
}
.section-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
}
.section-sub {
    color: var(--text-muted);
    font-size: 15px;
    margin-bottom: 32px;
}
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
}
.cat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: border-color 0.15s, transform 0.15s;
}
.cat-card:hover { border-color: #4b6180; transform: translateY(-2px); }
.cat-card--highlight {
    border-color: rgba(59,130,246,.4);
    background: rgba(59,130,246,.06);
}
.cat-icon { font-size: 28px; line-height: 1; }
.cat-name { font-size: 12px; font-weight: 600; color: var(--text); text-align: center; }
.cat-codes { font-size: 11px; color: var(--text-muted); text-align: center; }

/* how-it-works section title override */
.how-it-works { margin-bottom: 60px; text-align: center; }

.hero-stats { display: flex; flex-direction: column; gap: 16px; }
.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px 24px;
}
.stat-value { font-size: 32px; font-weight: 800; color: var(--primary); }
.stat-label { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

.how-it-works { margin-bottom: 60px; }
.steps { display: flex; gap: 24px; }
@media (max-width: 700px) { .steps { flex-direction: column; } }
.step {
    flex: 1;
    display: flex;
    gap: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
}
.step-num {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.step-text { display: flex; flex-direction: column; gap: 4px; }
.step-text strong { font-size: 15px; }
.step-text span { font-size: 13px; color: var(--text-muted); }

/* finds ticker */
.finds-ticker { display: flex; align-items: center; gap: 12px; background: rgba(16,185,129,.07); border: 1px solid rgba(16,185,129,.2); border-radius: 10px; padding: 10px 16px; margin: 0 0 32px; }
.finds-ticker-label { font-size: 11px; font-weight: 800; color: #10b981; white-space: nowrap; text-transform: uppercase; letter-spacing: .5px; flex-shrink: 0; }
.finds-ticker-track { flex: 1; overflow: hidden; }
.finds-ticker-item { font-size: 13px; color: var(--text-muted); transition: opacity .4s; display: block; }
.finds-ticker-item strong { color: var(--text); }

/* faq */
.faq-section { margin-bottom: 56px; }
.faq-list { display: flex; flex-direction: column; gap: 8px; margin-top: 24px; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.faq-q { width: 100%; background: none; border: none; padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; cursor: pointer; color: var(--text); font-size: 15px; font-weight: 600; text-align: left; }
.faq-q:hover { background: var(--surface2); }
.faq-arrow { font-size: 16px; color: var(--text-dim); transition: transform .25s; flex-shrink: 0; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; font-size: 14px; color: var(--text-muted); line-height: 1.7; padding: 0 20px; }
.faq-item.open .faq-a { padding: 0 20px 18px; }

/* trend badge */
.trend-badge { display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; margin-left: 8px; }
.trend-up     { background: rgba(16,185,129,.12); color: #10b981; }
.trend-down   { background: rgba(239,68,68,.12);  color: #ef4444; }
.trend-stable { background: rgba(100,116,139,.12); color: #64748b; }

/* notification history */
.btn-history-toggle { background: none; border: none; border-top: 1px solid var(--border); width: 100%; padding: 8px; font-size: 12px; color: var(--text-dim); cursor: pointer; display: block; text-align: center; }
.btn-history-toggle:hover { color: var(--text-muted); background: var(--surface2); }
.sub-history { border-top: 1px solid var(--border); padding: 12px 16px; background: var(--bg); }
.history-list { display: flex; flex-direction: column; gap: 8px; }
.history-item { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.history-dot  { width: 6px; height: 6px; border-radius: 50%; background: #10b981; flex-shrink: 0; }
.history-date { color: var(--text-muted); flex: 1; }
.history-count{ color: var(--primary); font-weight: 600; }
.history-loading, .history-empty { font-size: 13px; color: var(--text-dim); text-align: center; padding: 8px 0; }

/* status chart */
.status-chart-wrap { margin: 12px 0 4px; }
.status-chart-wrap--dash { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; margin: 0 0 24px; }
.status-chart-label { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px; }
.status-chart-bars { display: flex; gap: 2px; align-items: flex-end; height: 28px; }
.sc-bar { flex: 1; min-width: 0; height: 100%; border-radius: 2px; cursor: default; transition: opacity .15s; }
.sc-bar:hover { opacity: .75; }
.sc-ok   { background: #10b981; }
.sc-err  { background: #ef4444; }
.sc-none { background: #1e293b; border: 1px solid #334155; }

/* origin story / ariel tribute */
.origin-story { margin: 0 0 56px; }
.origin-card { display: flex; align-items: flex-start; gap: 20px; background: linear-gradient(135deg, #1e293b 0%, #162032 100%); border: 1px solid #334155; border-left: 4px solid #f59e0b; border-radius: 16px; padding: 24px 28px; }
.origin-avatar { font-size: 36px; flex-shrink: 0; line-height: 1; margin-top: 2px; }
.origin-body { flex: 1; }
.origin-headline { font-size: 16px; font-weight: 700; color: var(--text); margin: 0 0 6px; line-height: 1.5; }
.origin-sub { font-size: 14px; color: var(--text-muted); margin: 0; line-height: 1.6; }
.origin-link { color: #f59e0b; text-decoration: none; font-weight: 700; display: inline-flex; align-items: center; gap: 3px; }
.origin-link:hover { text-decoration: underline; }
@media (max-width: 600px) { .origin-card { flex-direction: column; gap: 12px; padding: 20px; } }

.landing-footer { text-align: center; color: var(--text-dim); font-size: 14px; }
.landing-footer a { color: var(--text-dim); }
.landing-footer a:hover { color: var(--text-muted); }

/* auth page (reset hasła, wypisz) */
.auth-page { display: flex; justify-content: center; align-items: flex-start; padding: 60px 24px 80px; min-height: calc(100vh - 64px); }
.auth-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 36px 32px; width: 100%; max-width: 440px; }
.auth-icon { font-size: 40px; text-align: center; margin-bottom: 12px; }
.auth-title { font-size: 22px; font-weight: 800; margin: 0 0 6px; }
.auth-sub { color: var(--text-muted); font-size: 14px; margin: 0 0 24px; line-height: 1.5; }
.form-info { background: rgba(16,185,129,.1); border: 1px solid rgba(16,185,129,.3); color: #10b981; border-radius: 8px; padding: 10px 14px; font-size: 13px; }
.unsub-details { background: var(--surface2); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; margin: 8px 0; }
.unsub-details strong { display: block; color: var(--text); font-size: 15px; }
.unsub-details span { color: var(--text-muted); font-size: 13px; }

/* settings modal */
.settings-section { margin-bottom: 24px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.settings-section:last-child { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }
.settings-section-title { font-size: 14px; font-weight: 700; margin: 0 0 12px; color: var(--text); }
.settings-section-desc { font-size: 13px; color: var(--text-muted); margin: 0 0 12px; line-height: 1.5; }
.settings-section--danger .settings-section-title { color: #ef4444; }
.btn-danger { background: rgba(239,68,68,.15); color: #ef4444; border: 1px solid rgba(239,68,68,.3); }
.btn-danger:hover { background: rgba(239,68,68,.25); }

/* date range field */
.date-range-row { display: flex; align-items: center; gap: 8px; }
.date-range-row input[type="date"] { flex: 1; }
.field-hint-text { font-size: 12px; color: var(--text-dim); margin-top: 4px; }

/* sub-date-filter info */
.sub-date-filter { font-size: 12px; color: var(--text-muted); margin: 6px 0 0; padding: 6px 10px; background: var(--surface2); border-radius: 6px; }

/* ============================================================
   DASHBOARD
   ============================================================ */
.dashboard { max-width: 960px; margin: 0 auto; padding: 40px 24px; }
.dashboard-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 32px;
    gap: 16px;
}
.dashboard-header h1 { font-size: 28px; font-weight: 700; }
.dashboard-sub { color: var(--text-muted); margin-top: 4px; font-size: 14px; }

/* ============================================================
   COUNTDOWN WIDGET
   ============================================================ */
.countdown-bar {
    display: flex;
    align-items: center;
    gap: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--success);
    border-radius: var(--radius-lg);
    padding: 18px 24px;
    margin-bottom: 24px;
}
.countdown-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.countdown-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--success);
    flex-shrink: 0;
    animation: pulse 2s infinite;
}
.countdown-label-col {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.countdown-label-top {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--success);
}
.countdown-label-bot {
    font-size: 12px;
    color: var(--text-dim);
}
.countdown-timer {
    font-weight: 800;
    font-size: 36px;
    color: var(--text);
    font-variant-numeric: tabular-nums;
    letter-spacing: -1px;
    line-height: 1;
    margin-left: auto;
}
@media (max-width: 480px) {
    .countdown-bar { padding: 14px 16px; gap: 12px; }
    .countdown-timer { font-size: 28px; }
}

/* ============================================================
   SUBSCRIPTION CARDS
   ============================================================ */
#subscriptions-container { display: flex; flex-direction: column; gap: 16px; }

.sub-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px 24px;
    transition: border-color 0.15s;
}
.sub-card:hover { border-color: #4b6180; }
.sub-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}
.sub-card-title {
    display: flex;
    align-items: center;
    gap: 12px;
}
.sub-category-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(59,130,246,.15);
    color: var(--primary);
    border: 1px solid rgba(59,130,246,.3);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
}
.sub-category-badge .cat-emoji { font-size: 15px; line-height: 1; }

/* Przycisk "Terminy" z liczbą */
.btn-dates {
    background: rgba(59,130,246,.12);
    color: var(--primary);
    border: 1px solid rgba(59,130,246,.3);
    font-weight: 700;
    transition: all 0.15s;
}
.btn-dates:hover:not(:disabled) {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}
.dates-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: #fff;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    line-height: 1;
}
.btn-dates:hover .dates-badge { background: #fff; color: var(--primary); }

/* Alert wolnych terminów */
.sub-slots-alert {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(16,185,129,.08);
    border: 1px solid rgba(16,185,129,.25);
    border-radius: var(--radius);
    padding: 8px 14px;
    margin-top: 12px;
    font-size: 13px;
    color: var(--success);
    font-weight: 600;
}
.sub-slots-alert .alert-icon { font-size: 16px; }
.sub-word-name { font-weight: 700; font-size: 16px; }
.sub-province { font-size: 13px; color: var(--text-muted); margin-top: 2px; }
.sub-card-actions { display: flex; gap: 8px; }

.sub-stats {
    display: flex;
    gap: 24px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
}
.sub-stat { display: flex; flex-direction: column; gap: 2px; }
.sub-stat-value { font-weight: 700; font-size: 15px; }
.sub-stat-value.accent-green { color: var(--success); }
.sub-stat-label { font-size: 12px; color: var(--text-muted); }

.sub-last-check { font-size: 12px; color: var(--text-dim); margin-top: 8px; }

/* ============================================================
   EMPTY STATE / LOADING
   ============================================================ */
.empty-state {
    text-align: center;
    padding: 80px 24px;
    color: var(--text-muted);
}
.empty-icon { font-size: 48px; margin-bottom: 16px; }
.empty-state h3 { font-size: 20px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.empty-state p { margin-bottom: 24px; font-size: 15px; }

.loading-placeholder {
    color: var(--text-muted);
    font-size: 14px;
    padding: 40px;
    text-align: center;
}

/* ============================================================
   MODALS
   ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    padding: 20px;
    backdrop-filter: blur(4px);
}
.modal {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 440px;
    max-height: 90vh;
    overflow-y: auto;
}
.modal-lg { max-width: 640px; }

.modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-size: 18px; font-weight: 700; }
.modal-subtitle { font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    line-height: 1;
}
.modal-close:hover { background: var(--surface2); color: var(--text); }
.modal-body { padding: 20px 24px; }
.modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid var(--border);
}
.modal-switch { font-size: 13px; color: var(--text-muted); }

/* ============================================================
   FORM ELEMENTS
   ============================================================ */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.field-hint { font-weight: 400; color: var(--text-dim); }

input[type="text"],
input[type="email"],
input[type="password"],
select {
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 10px 12px;
    border-radius: var(--radius);
    font-size: 14px;
    width: 100%;
    transition: border-color 0.15s;
    appearance: none;
    -webkit-appearance: none;
}
input:focus, select:focus { outline: none; border-color: var(--primary); }
input::placeholder { color: var(--text-dim); }
select:disabled { opacity: 0.5; cursor: not-allowed; }

select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

.form-error {
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.3);
    color: #fca5a5;
    padding: 10px 14px;
    border-radius: var(--radius);
    font-size: 13px;
}

/* ============================================================
   DATES TABLE (in modal)
   ============================================================ */
.dates-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
.dates-table th {
    padding: 10px 12px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}
.dates-table td {
    padding: 11px 12px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
.dates-table tr:last-child td { border-bottom: none; }
.dates-table tr:hover td { background: var(--surface2); }

.tag {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}
.tag-blue   { background: rgba(59,130,246,.15); color: #60a5fa; }
.tag-green  { background: rgba(16,185,129,.15); color: #34d399; }
.tag-orange { background: rgba(245,158,11,.15); color: #fbbf24; }
.tag-red    { background: rgba(239,68,68,.15);  color: #f87171; }

.no-dates {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
    font-size: 14px;
}

/* ============================================================
   MODAL STATS BAR
   ============================================================ */
.modal-stats-bar {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}
.modal-stats-bar strong { color: var(--text); }

/* ============================================================
   MINI CALENDAR
   ============================================================ */
.mini-calendars {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.mini-cal {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 14px;
    flex: 1;
    min-width: 190px;
}
.mini-cal-title {
    font-weight: 700;
    font-size: 13px;
    text-align: center;
    margin-bottom: 8px;
    color: var(--text);
    letter-spacing: 0.2px;
}
.mini-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}
.cal-dow {
    font-size: 10px;
    font-weight: 700;
    text-align: center;
    color: var(--text-dim);
    padding: 2px 0 4px;
    text-transform: uppercase;
}
.cal-dow-wend { color: #64748b; }
.cal-cell {
    font-size: 12px;
    text-align: center;
    padding: 4px 2px;
    border-radius: 50%;
    color: var(--text-muted);
    line-height: 1.4;
    min-height: 22px;
}
.cal-past    { opacity: 0.25; }
.cal-today   { background: var(--surface2); color: var(--text); font-weight: 700; }
.cal-weekend { color: var(--text-dim); }
.cal-has-slot {
    background: var(--primary);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 0 0 2px rgba(59,130,246,.3);
}
.cal-has-slot:hover { background: var(--primary-h); }

/* ============================================================
   DAY GROUPS
   ============================================================ */
.day-groups { display: flex; flex-direction: column; gap: 8px; }

.day-group {
    background: var(--bg);
    border: 1px solid var(--border);
    border-left: 3px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    transition: border-color 0.15s;
}
.day-group--urgent { border-left-color: var(--danger); }
.day-group--soon   { border-left-color: var(--warning); }

.day-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}
.day-group-date   { display: flex; flex-direction: column; gap: 2px; }
.day-name         { font-weight: 700; font-size: 14px; color: var(--text); }
.day-full         { font-size: 12px; color: var(--text-muted); }
.day-group-meta   { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.places-count     { font-size: 12px; color: var(--text-muted); white-space: nowrap; }

.day-group-slots  { display: flex; gap: 8px; flex-wrap: wrap; }
.time-badge {
    background: rgba(59,130,246,.12);
    color: #60a5fa;
    border: 1px solid rgba(59,130,246,.25);
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.2px;
}

/* ============================================================
   NOTIFICATIONS STATS (in sub card)
   ============================================================ */
.pulse-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    margin-right: 6px;
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: .5; transform: scale(1.3); }
}

/* ============================================================
   DONATE BANNER
   ============================================================ */
.donate-banner {
    background: linear-gradient(135deg, rgba(245,158,11,.08), rgba(251,191,36,.03));
    border: 1px solid rgba(245,158,11,.2);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
    margin-top: 32px;
    text-align: center;
}
.donate-icon  { font-size: 36px; margin-bottom: 8px; }
.donate-title { font-size: 17px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.donate-desc  {
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.65;
    margin-bottom: 20px;
    max-width: 440px;
    margin-left: auto;
    margin-right: auto;
}
.donate-options { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.donate-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    text-decoration: none;
    transition: all 0.2s;
    flex: 1;
    max-width: 120px;
    min-width: 90px;
}
.donate-option:hover {
    border-color: #f59e0b;
    background: rgba(245,158,11,.08);
    transform: translateY(-2px);
    text-decoration: none;
}
.donate-coffee-icon { width: 36px; height: 36px; }
.donate-price { font-size: 15px; font-weight: 700; color: var(--text); }
.donate-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.donate-powered { margin-top: 14px; font-size: 12px; color: var(--text-dim); }
.donate-powered a { color: var(--text-dim); }
.donate-powered a:hover { color: #f59e0b; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 600px) {
    .dashboard-header { flex-direction: column; }
    .sub-card-header  { flex-direction: column; align-items: flex-start; }
    .modal-footer     { flex-direction: column-reverse; }
    .modal-switch     { text-align: center; }
}
