/* ============================================================
   RainDay Deals — Dark theme, electric blue + bright yellow
   ============================================================ */
:root {
    --bg: #0f1117;
    --bg-card: #1a1d27;
    --bg-card-hover: #222633;
    --bg-surface: #151821;
    --border: #2a2e3d;
    --text: #e4e6ed;
    --text-muted: #8b8fa3;
    --text-dim: #5c6178;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --primary-glow: rgba(59, 130, 246, 0.25);
    --accent: #fbbf24;
    --accent-hover: #f59e0b;
    --success: #22c55e;
    --error: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    --rain-drop: rgba(59, 130, 246, 0.3);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
    --shadow: 0 4px 24px rgba(0,0,0,0.3);
    --shadow-lg: 0 8px 40px rgba(0,0,0,0.4);
    --transition: 0.2s ease;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

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

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ---- Rain animation ---- */
.rain-container {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none; z-index: 0; overflow: hidden;
}
.rain-drop {
    position: absolute; top: -20px;
    width: 2px; background: linear-gradient(transparent, var(--rain-drop));
    animation: rain-fall linear infinite;
}
@keyframes rain-fall {
    to { transform: translateY(105vh); }
}

/* ---- Nav ---- */
.nav {
    position: sticky; top: 0; z-index: 100;
    background: rgba(15, 17, 23, 0.92); backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px;
}
.nav-logo {
    display: flex; align-items: center; gap: 8px;
    font-size: 1.25rem; font-weight: 800; color: var(--text);
}
.nav-logo:hover { color: var(--text); }
.logo-icon { font-size: 1.5rem; }
.logo-accent { color: var(--primary); }
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-link {
    color: var(--text-muted); padding: 8px 12px; border-radius: var(--radius-sm);
    font-size: 0.9rem; font-weight: 500; transition: all var(--transition);
    display: flex; align-items: center; gap: 6px;
}
.nav-link:hover { color: var(--text); background: var(--bg-card); }
.nav-link-muted { color: var(--text-dim); }
.badge {
    background: var(--primary); color: #fff; font-size: 0.7rem;
    padding: 2px 7px; border-radius: 99px; font-weight: 700;
}
.nav-toggle {
    display: none; background: none; border: none; cursor: pointer;
    flex-direction: column; gap: 4px; padding: 8px;
}
.nav-toggle span {
    display: block; width: 22px; height: 2px; background: var(--text);
    border-radius: 2px; transition: var(--transition);
}

@media (max-width: 768px) {
    .nav-toggle { display: flex; }
    .nav-links {
        display: none; position: absolute; top: 64px; left: 0; right: 0;
        background: var(--bg-surface); flex-direction: column; padding: 16px;
        border-bottom: 1px solid var(--border);
    }
    .nav-links.open { display: flex; }
    .nav-link { width: 100%; padding: 12px 16px; }
}

/* ---- Weather bar ---- */
.weather-bar {
    background: linear-gradient(90deg, var(--primary), #2563eb);
    color: #fff; text-align: center; padding: 8px 0;
    font-size: 0.85rem; font-weight: 600;
}
.weather-icon { margin-right: 4px; }

/* ---- Flash messages ---- */
.flash-container { margin-top: 16px; }
.flash {
    padding: 12px 20px; border-radius: var(--radius-sm); margin-bottom: 8px;
    font-size: 0.9rem; font-weight: 500; animation: flash-in 0.3s ease;
}
@keyframes flash-in { from { opacity: 0; transform: translateY(-8px); } }
.flash-success { background: rgba(34,197,94,0.15); color: var(--success); border: 1px solid rgba(34,197,94,0.3); }
.flash-error { background: rgba(239,68,68,0.15); color: var(--error); border: 1px solid rgba(239,68,68,0.3); }
.flash-warning { background: rgba(245,158,11,0.15); color: var(--warning); border: 1px solid rgba(245,158,11,0.3); }
.flash-info { background: rgba(59,130,246,0.15); color: var(--info); border: 1px solid rgba(59,130,246,0.3); }

/* ---- Buttons ---- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 24px; border-radius: var(--radius-sm); font-weight: 600;
    font-size: 0.95rem; border: none; cursor: pointer; transition: all var(--transition);
    text-decoration: none;
}
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-lg { padding: 16px 32px; font-size: 1.1rem; }
.btn-primary {
    background: var(--primary); color: #fff;
    box-shadow: 0 0 20px var(--primary-glow);
}
.btn-primary:hover { background: var(--primary-hover); color: #fff; transform: translateY(-1px); }
.btn-accent { background: var(--accent); color: #000; }
.btn-accent:hover { background: var(--accent-hover); color: #000; transform: translateY(-1px); }
.btn-outline {
    background: transparent; color: var(--text); border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { color: var(--text); background: var(--bg-card); }
.btn-block { width: 100%; }

/* ---- Cards ---- */
.card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 24px;
    transition: all var(--transition);
}
.card:hover { border-color: rgba(59,130,246,0.3); background: var(--bg-card-hover); }

/* ---- Deal cards ---- */
.deal-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
}
.deal-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden;
    transition: all var(--transition); position: relative;
}
.deal-card:hover {
    border-color: rgba(59,130,246,0.4); transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}
.deal-card-header {
    padding: 20px 20px 12px; display: flex; justify-content: space-between;
    align-items: flex-start;
}
.deal-discount {
    background: var(--accent); color: #000; font-weight: 800;
    font-size: 1.3rem; padding: 6px 14px; border-radius: var(--radius-sm);
    line-height: 1;
}
.deal-weather-badge {
    font-size: 1.5rem; display: flex; align-items: center;
}
.deal-card-body { padding: 0 20px 16px; }
.deal-title {
    font-size: 1.15rem; font-weight: 700; margin-bottom: 4px;
    color: var(--text);
}
.deal-biz {
    font-size: 0.85rem; color: var(--text-muted); margin-bottom: 8px;
    display: flex; align-items: center; gap: 6px;
}
.deal-desc { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 12px; }
.deal-prices {
    display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px;
}
.deal-price-original {
    color: var(--text-dim); text-decoration: line-through; font-size: 0.9rem;
}
.deal-price-now {
    color: var(--accent); font-size: 1.3rem; font-weight: 800;
}
.deal-card-footer {
    padding: 12px 20px; border-top: 1px solid var(--border);
    display: flex; justify-content: space-between; align-items: center;
    font-size: 0.8rem; color: var(--text-muted);
}
.deal-timer {
    display: flex; align-items: center; gap: 4px;
    color: var(--primary); font-weight: 600;
}
.deal-claimed { display: flex; align-items: center; gap: 4px; }
.progress-bar {
    width: 60px; height: 4px; background: var(--border); border-radius: 99px;
    overflow: hidden;
}
.progress-fill {
    height: 100%; background: var(--primary); border-radius: 99px;
    transition: width 0.5s ease;
}
.deal-category-badge {
    font-size: 0.75rem; background: var(--bg-surface); padding: 3px 10px;
    border-radius: 99px; color: var(--text-muted); border: 1px solid var(--border);
}

/* ---- Hero ---- */
.hero {
    padding: 100px 0 80px; text-align: center; position: relative; z-index: 1;
}
.hero h1 {
    font-size: 3.5rem; font-weight: 900; line-height: 1.1; margin-bottom: 20px;
    background: linear-gradient(135deg, var(--text) 0%, var(--primary) 50%, var(--accent) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero .subtitle {
    font-size: 1.25rem; color: var(--text-muted); max-width: 600px;
    margin: 0 auto 36px; line-height: 1.6;
}
.hero-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-stats {
    display: flex; justify-content: center; gap: 48px; margin-top: 60px;
    flex-wrap: wrap;
}
.hero-stat { text-align: center; }
.hero-stat-num {
    font-size: 2.5rem; font-weight: 900; color: var(--accent);
    line-height: 1;
}
.hero-stat-label { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

@media (max-width: 768px) {
    .hero { padding: 60px 0 40px; }
    .hero h1 { font-size: 2.2rem; }
    .hero .subtitle { font-size: 1.05rem; }
    .hero-stats { gap: 24px; }
    .hero-stat-num { font-size: 1.8rem; }
}

/* ---- Section ---- */
.section { padding: 60px 0; position: relative; z-index: 1; }
.section-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 28px; flex-wrap: wrap; gap: 12px;
}
.section-title { font-size: 1.5rem; font-weight: 800; }
.section-subtitle { color: var(--text-muted); font-size: 0.95rem; }

/* ---- Filters ---- */
.filters {
    display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px;
}
.filter-btn {
    padding: 8px 16px; border-radius: 99px; font-size: 0.85rem;
    font-weight: 500; cursor: pointer; transition: all var(--transition);
    background: var(--bg-card); border: 1px solid var(--border);
    color: var(--text-muted); text-decoration: none;
}
.filter-btn:hover, .filter-btn.active {
    background: var(--primary); color: #fff; border-color: var(--primary);
}

/* ---- Forms ---- */
.form-page {
    max-width: 440px; margin: 60px auto; padding: 0 20px;
    position: relative; z-index: 1;
}
.form-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 36px;
}
.form-card h2 {
    font-size: 1.5rem; font-weight: 800; margin-bottom: 8px; text-align: center;
}
.form-card .form-subtitle {
    color: var(--text-muted); text-align: center; margin-bottom: 28px;
    font-size: 0.9rem;
}
.form-group { margin-bottom: 20px; }
.form-label {
    display: block; font-size: 0.85rem; font-weight: 600; color: var(--text-muted);
    margin-bottom: 6px;
}
.form-input, .form-select, .form-textarea {
    width: 100%; padding: 12px 16px; background: var(--bg-surface);
    border: 1px solid var(--border); border-radius: var(--radius-sm);
    color: var(--text); font-size: 0.95rem; font-family: inherit;
    transition: border-color var(--transition);
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}
.form-textarea { resize: vertical; min-height: 80px; }
.form-select { cursor: pointer; }
.form-check {
    display: flex; align-items: center; gap: 8px; font-size: 0.9rem;
    cursor: pointer; margin-bottom: 8px;
}
.form-check input[type="checkbox"] {
    width: 18px; height: 18px; accent-color: var(--primary);
}
.form-footer {
    text-align: center; margin-top: 20px; font-size: 0.85rem;
    color: var(--text-muted);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ---- Detail page ---- */
.detail-page { padding: 40px 0; position: relative; z-index: 1; }
.detail-grid { display: grid; grid-template-columns: 1fr 380px; gap: 32px; }
@media (max-width: 900px) {
    .detail-grid { grid-template-columns: 1fr; }
}
.detail-main {}
.detail-sidebar .card { position: sticky; top: 80px; }
.detail-back {
    display: inline-flex; align-items: center; gap: 6px;
    color: var(--text-muted); font-size: 0.9rem; margin-bottom: 20px;
}
.detail-back:hover { color: var(--primary); }

/* ---- Redeem code ---- */
.redeem-page { text-align: center; padding: 80px 0; position: relative; z-index: 1; }
.redeem-code {
    font-size: 3rem; font-weight: 900; letter-spacing: 6px;
    color: var(--accent); margin: 24px 0;
    text-shadow: 0 0 30px rgba(251,191,36,0.3);
}
.redeem-instructions {
    color: var(--text-muted); max-width: 400px; margin: 0 auto 32px;
    font-size: 0.95rem;
}

/* ---- Stats row ---- */
.stats-row {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px; margin-bottom: 32px;
}
.stat-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 20px; text-align: center;
}
.stat-value {
    font-size: 2rem; font-weight: 900; color: var(--accent); line-height: 1;
}
.stat-label { font-size: 0.8rem; color: var(--text-muted); margin-top: 6px; }

/* ---- Table ---- */
.table-wrap { overflow-x: auto; }
table {
    width: 100%; border-collapse: collapse; font-size: 0.9rem;
}
th {
    text-align: left; padding: 12px 16px; font-weight: 600;
    color: var(--text-muted); border-bottom: 1px solid var(--border);
    font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.5px;
}
td {
    padding: 12px 16px; border-bottom: 1px solid var(--border);
    color: var(--text);
}
tr:hover td { background: var(--bg-card-hover); }

/* ---- Marketing pages ---- */
.page-hero {
    text-align: center; padding: 80px 0 40px; position: relative; z-index: 1;
}
.page-hero h1 {
    font-size: 2.5rem; font-weight: 900; margin-bottom: 16px;
}
.page-hero p {
    color: var(--text-muted); font-size: 1.1rem; max-width: 600px;
    margin: 0 auto;
}
.steps-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px; margin: 40px 0;
}
.step-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 32px; text-align: center;
    position: relative;
}
.step-num {
    width: 48px; height: 48px; border-radius: 50%;
    background: var(--primary); color: #fff; font-weight: 800;
    font-size: 1.2rem; display: flex; align-items: center;
    justify-content: center; margin: 0 auto 16px;
}
.step-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.step-card p { color: var(--text-muted); font-size: 0.9rem; }

.feature-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}
.feature-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 28px;
}
.feature-icon { font-size: 2rem; margin-bottom: 12px; }
.feature-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: var(--text-muted); font-size: 0.9rem; }

/* ---- Pricing / Fees ---- */
.fee-card {
    max-width: 500px; margin: 40px auto; text-align: center;
    background: var(--bg-card); border: 2px solid var(--primary);
    border-radius: var(--radius-lg); padding: 48px;
    box-shadow: 0 0 40px var(--primary-glow);
}
.fee-pct {
    font-size: 5rem; font-weight: 900; color: var(--primary); line-height: 1;
}
.fee-label { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 24px; }
.fee-list { text-align: left; margin: 24px 0; }
.fee-item {
    display: flex; align-items: center; gap: 10px; padding: 10px 0;
    border-bottom: 1px solid var(--border); font-size: 0.95rem;
}
.fee-check { color: var(--success); font-size: 1.2rem; }
.fee-x { color: var(--error); font-size: 1.2rem; }

/* ---- Settings ---- */
.settings-page {
    max-width: 640px; margin: 40px auto; padding: 0 20px;
    position: relative; z-index: 1;
}

/* ---- History ---- */
.history-page { position: relative; z-index: 1; }
.savings-banner {
    background: linear-gradient(135deg, var(--bg-card), rgba(59,130,246,0.1));
    border: 1px solid var(--border); border-radius: var(--radius-lg);
    padding: 32px; text-align: center; margin-bottom: 32px;
}
.savings-amount {
    font-size: 3rem; font-weight: 900; color: var(--accent); line-height: 1;
}
.savings-label { color: var(--text-muted); font-size: 0.9rem; margin-top: 4px; }

/* ---- Biz dashboard ---- */
.biz-page { position: relative; z-index: 1; }

/* ---- Lightning flash for big discounts ---- */
.deal-card[data-discount="50"] .deal-discount,
.deal-card[data-discount="40"] .deal-discount {
    animation: lightning 3s infinite;
}
@keyframes lightning {
    0%, 94%, 100% { box-shadow: none; }
    95% { box-shadow: 0 0 20px var(--accent), 0 0 40px rgba(251,191,36,0.3); }
    97% { box-shadow: none; }
    98% { box-shadow: 0 0 15px var(--accent); }
}

/* ---- Footer ---- */
.footer {
    background: var(--bg-surface); border-top: 1px solid var(--border);
    padding: 48px 0 32px; margin-top: 80px; position: relative; z-index: 1;
}
.footer-grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px;
}
@media (max-width: 768px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
.footer-logo { font-size: 1.2rem; font-weight: 800; margin-bottom: 8px; }
.footer-tagline { color: var(--text-muted); font-size: 0.9rem; }
.footer-copy { color: var(--text-dim); font-size: 0.8rem; margin-top: 12px; }
.footer h4 {
    font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: 1px; color: var(--text-muted); margin-bottom: 12px;
}
.footer a {
    display: block; color: var(--text-dim); font-size: 0.9rem;
    padding: 4px 0; transition: color var(--transition);
}
.footer a:hover { color: var(--primary); }

/* ---- Empty state ---- */
.empty-state {
    text-align: center; padding: 60px 20px; color: var(--text-muted);
}
.empty-state-icon { font-size: 3rem; margin-bottom: 16px; }
.empty-state h3 { font-size: 1.2rem; color: var(--text); margin-bottom: 8px; }

/* ---- Lucide sizing (moved from inline base.html style) ---- */
.lucide { width: 1em; height: 1em; vertical-align: -0.125em; }

/* ---- Skip link (a11y) ---- */
.skip-link {
    position: absolute; left: -1000px; top: 0; z-index: 200;
    background: var(--primary); color: #fff; padding: 8px 16px;
    text-decoration: none; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---- Visually-hidden (a11y, screen-reader only) ---- */
.visually-hidden {
    position: absolute; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0;
}

/* ---- Hidden helper ---- */
.hidden { display: none !important; }

/* ---- Required field marker ---- */
.req { color: var(--error); font-weight: 700; }

/* ---- Form-validation states (matches UIKit pattern) ---- */
.form-input[aria-invalid="true"], .form-input.invalid {
    border: 2px solid var(--error);
}
.form-help { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }
.form-help.error { color: var(--error); }

/* ---- SSO divider ---- */
.sso-divider {
    display: flex; align-items: center; margin: 16px 0;
    color: var(--text-dim); font-size: 0.85rem;
}
.sso-divider hr { flex: 1; border: none; border-top: 1px solid var(--border); }
.sso-divider span { margin: 0 12px; }

/* ---- Btn variants ---- */
.btn-secondary {
    background: var(--bg-card); border: 1px solid var(--border); color: var(--text);
}
.btn-secondary:hover { background: var(--bg-card-hover); }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { color: var(--text); }

/* ---- Standard footer (injected by footer.js) ---- */
.site-footer {
    background: var(--bg-surface); border-top: 1px solid var(--border);
    padding: 48px 0 32px; margin-top: 48px;
}
.site-footer .footer-grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 32px; margin-bottom: 32px;
}
@media (max-width: 768px) {
    .site-footer .footer-grid { grid-template-columns: 1fr 1fr; }
}
.site-footer h4 {
    font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: 1px; color: var(--text-muted); margin-bottom: 12px;
}
.site-footer a {
    display: block; color: var(--text-dim); font-size: 0.9rem;
    padding: 4px 0; transition: color var(--transition);
}
.site-footer a:hover { color: var(--primary); }
.site-footer .footer-by { color: var(--text-dim); font-size: 0.85rem; margin-top: 8px; }
.site-footer .footer-meta {
    border-top: 1px solid var(--border); padding-top: 20px;
    text-align: center; color: var(--text-dim); font-size: 0.8rem;
}
.site-footer .footer-meta p { margin: 4px 0; }
.site-footer .footer-meta a { display: inline; color: var(--text-muted); text-decoration: underline; }

/* ---- Cookie consent banner ---- */
.cookie-banner {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
    background: var(--bg-card); border-top: 2px solid var(--primary);
    box-shadow: 0 -8px 24px rgba(0,0,0,0.4);
}
.cookie-banner-inner {
    max-width: 1200px; margin: 0 auto; padding: 16px 24px;
    display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.cookie-banner p { flex: 1 1 320px; margin: 0; color: var(--text); font-size: 0.9rem; }
.cookie-banner-actions { display: flex; align-items: center; gap: 12px; }
.cookie-banner-link { color: var(--text-muted); font-size: 0.85rem; text-decoration: underline; }

/* ---- Content pages (FAQ/Terms/Privacy/etc) ---- */
.content-page { padding: 48px 24px; max-width: 800px; }
.content-page h1 { font-size: 2rem; font-weight: 800; margin-bottom: 8px; color: var(--text); }
.content-page h2 { font-size: 1.4rem; font-weight: 700; margin: 32px 0 12px; color: var(--text); }
.content-page h3 { font-size: 1.1rem; font-weight: 600; margin: 24px 0 8px; color: var(--text); }
.content-page p, .content-page li { color: var(--text-muted); line-height: 1.65; margin-bottom: 12px; }
.content-page a { color: var(--primary); text-decoration: underline; }
.content-page .subtitle { color: var(--text-dim); font-size: 0.95rem; margin-bottom: 24px; }
.content-page ul, .content-page ol { padding-left: 24px; margin-bottom: 16px; }

/* ---- Contact grid ---- */
.contact-grid {
    display: grid; grid-template-columns: 1fr 2fr; gap: 32px; margin-top: 24px;
}
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }

/* ---- Admin metric cards + tables ---- */
.metric-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px; margin: 24px 0;
}
.metric-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 20px;
}
.metric-label {
    font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.5px;
    color: var(--text-muted); margin-bottom: 6px;
}
.metric-value { font-size: 1.8rem; font-weight: 800; color: var(--text); }
.data-table {
    width: 100%; border-collapse: collapse; margin: 16px 0;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden;
}
.data-table th, .data-table td {
    padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
}
.data-table th { color: var(--text-muted); font-weight: 600; background: var(--bg-surface); }
.data-table td { color: var(--text); }
.data-table tr:last-child td { border-bottom: none; }
.empty-row { text-align: center; color: var(--text-dim); padding: 24px; }

/* ---- Map popup styling (referenced by deals-page.js) ---- */
.map-marker {
    width: 28px; height: 28px; background: #3b82f6; border-radius: 50%;
    border: 3px solid #fbbf24; cursor: pointer;
    box-shadow: 0 0 10px rgba(59,130,246,0.5);
}
.map-popup { font-size: 13px; }
.map-popup-biz { color: var(--text-muted); }
.map-popup-link { color: var(--primary); font-weight: 600; }

/* ---- Distance pill on deal cards ---- */
.deal-distance { color: var(--text-dim); font-size: 0.8rem; }

/* ---- Search bar / view toggle ---- */
.search-bar { display: flex; gap: 8px; margin-bottom: 20px; }
.search-bar input { flex: 1; }
.view-toggle { display: flex; gap: 4px; }
.view-btn {
    padding: 8px 14px; border-radius: var(--radius-sm);
    font-size: 0.85rem; font-weight: 600; cursor: pointer;
    background: var(--bg-card); border: 1px solid var(--border);
    color: var(--text-muted); transition: all var(--transition);
}
.view-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }
#deal-map {
    width: 100%; height: 340px; border-radius: var(--radius);
    margin-bottom: 24px; border: 1px solid var(--border);
}
.mapboxgl-popup-content {
    background: var(--bg-card); color: var(--text);
    border-radius: 8px; padding: 12px 16px; box-shadow: var(--shadow);
}
.mapboxgl-popup-close-button { color: var(--text-muted); font-size: 18px; }
.mapboxgl-popup-tip { border-top-color: var(--bg-card); }

/* ---- Expired countdown ---- */
.deal-timer .expired { color: var(--error); }
