/* ==============================================================
   SocialSignal — Design tokens
   Palette: deep navy surface, warm gold + teal growth accents
   Type: Sora (display) / Inter (body) / JetBrains Mono (data)
   Signature: "signal bars" growth motif used as bullets & dividers
   ============================================================== */

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@400;600;700;800&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    --bg: #0F1424;
    --surface: #171D33;
    --surface-2: #1E2540;
    --border: #2A3255;
    --text: #F1F0EA;
    --text-muted: #8891AC;
    --gold: #E8A33D;
    --gold-soft: #F0C078;
    --teal: #2BB8A3;
    --danger: #E15B5B;
    --radius: 10px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', sans-serif;
    scroll-behavior: smooth;
}

h1, h2, h3, h4, .display {
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
}

.mono { font-family: 'JetBrains Mono', monospace; }

a { color: inherit; text-decoration: none; }

.container {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Signal bars signature ---------- */
.signal-bars {
    display: inline-flex;
    align-items: flex-end;
    gap: 3px;
    height: 16px;
}
.signal-bars span {
    display: block;
    width: 4px;
    background: var(--gold);
    border-radius: 2px;
}
.signal-bars span:nth-child(1) { height: 40%; }
.signal-bars span:nth-child(2) { height: 65%; background: var(--gold-soft); }
.signal-bars span:nth-child(3) { height: 100%; background: var(--teal); }

.divider-bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 22px;
    margin: 8px 0 18px;
}
.divider-bars span {
    width: 5px;
    border-radius: 2px;
    background: var(--border);
}
.divider-bars span.active { background: var(--gold); }

/* ---------- Navbar ---------- */
.navbar {
    border-bottom: 1px solid var(--border);
    background: rgba(15,20,36,0.9);
    backdrop-filter: blur(8px);
    position: sticky;
    top: 0;
    z-index: 50;
}
.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    max-width: 1180px;
    margin: 0 auto;
}
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Sora', sans-serif;
    font-weight: 800;
    font-size: 20px;
}
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { color: var(--text-muted); font-weight: 500; font-size: 14.5px; transition: color .15s; }
.nav-links a:hover { color: var(--text); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 14.5px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: transform .12s ease, background .15s;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--gold); color: #1a1204; }
.btn-primary:hover { background: var(--gold-soft); }
.btn-outline { border-color: var(--border); color: var(--text); background: transparent; }
.btn-outline:hover { border-color: var(--gold); }
.btn-teal { background: var(--teal); color: #06231f; }
.btn-teal:hover { filter: brightness(1.08); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ---------- Cards ---------- */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}
.card-soft {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

/* ---------- Hero ---------- */
.hero {
    padding: 90px 0 70px;
    position: relative;
    overflow: hidden;
}
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 24px;
}
.hero h1 {
    font-size: 52px;
    line-height: 1.08;
    max-width: 760px;
}
.hero h1 span { color: var(--gold); }
.hero p { color: var(--text-muted); font-size: 17px; max-width: 560px; margin-top: 20px; line-height: 1.6; }
.hero-actions { display: flex; gap: 14px; margin-top: 32px; }

.stat-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    margin-top: 60px;
}
.stat-cell { background: var(--surface); padding: 22px 20px; }
.stat-cell .num { font-family: 'JetBrains Mono', monospace; font-size: 26px; font-weight: 600; color: var(--gold); }
.stat-cell .label { color: var(--text-muted); font-size: 13px; margin-top: 4px; }

/* ---------- Service grid (landing) ---------- */
.section { padding: 70px 0; }
.section-head { margin-bottom: 36px; }
.section-head .kicker { color: var(--teal); font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.section-head h2 { font-size: 32px; margin-top: 10px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }

.svc-card { padding: 22px; }
.svc-card .cat { color: var(--text-muted); font-size: 12.5px; text-transform: uppercase; letter-spacing: .05em; }
.svc-card h3 { font-size: 17px; margin-top: 8px; }
.svc-card .price { font-family: 'JetBrains Mono', monospace; color: var(--teal); font-size: 20px; margin-top: 14px; }
.svc-card .price small { color: var(--text-muted); font-family: 'Inter'; font-size: 12px; }

/* ---------- Forms ---------- */
.form-group { margin-bottom: 18px; }
label { display: block; font-size: 13.5px; color: var(--text-muted); margin-bottom: 7px; font-weight: 500; }
input, select, textarea {
    width: 100%;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 11px 14px;
    border-radius: 8px;
    font-size: 14.5px;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: border-color .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--gold); }
input::placeholder { color: #5c6488; }

.auth-wrap {
    min-height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}
.auth-card { width: 100%; max-width: 420px; }
.auth-card h1 { font-size: 26px; margin-bottom: 8px; }
.auth-card .sub { color: var(--text-muted); font-size: 14px; margin-bottom: 28px; }
.auth-foot { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-muted); }
.auth-foot a { color: var(--gold); font-weight: 600; }

/* ---------- App shell (dashboard) ---------- */
.app-shell { display: flex; min-height: 100vh; }
.sidebar {
    width: 240px;
    background: var(--surface);
    border-right: 1px solid var(--border);
    padding: 24px 16px;
    flex-shrink: 0;
}
.sidebar .brand { padding: 0 8px 26px; }
.side-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 12px;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 14.5px;
    font-weight: 500;
    margin-bottom: 4px;
}
.side-link:hover { background: var(--surface-2); color: var(--text); }
.side-link.active { background: var(--surface-2); color: var(--gold); }
.side-section-label { color: #545c80; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; margin: 20px 0 8px 12px; }

.main { flex: 1; padding: 30px 36px; max-width: calc(100% - 240px); }
.topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.topbar h1 { font-size: 24px; }
.balance-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    padding: 9px 16px;
    border-radius: 999px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    color: var(--teal);
}

.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.kpi { padding: 20px; }
.kpi .label { color: var(--text-muted); font-size: 13px; }
.kpi .value { font-family: 'JetBrains Mono', monospace; font-size: 24px; margin-top: 8px; font-weight: 600; }

/* ---------- Tables ---------- */
table { width: 100%; border-collapse: collapse; }
th {
    text-align: left;
    color: var(--text-muted);
    font-size: 12.5px;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-weight: 600;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}
td {
    padding: 14px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}
tr:last-child td { border-bottom: none; }
.table-wrap { overflow-x: auto; }

/* ---------- Badges ---------- */
.badge {
    display: inline-block;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}
.badge-pending { background: rgba(232,163,61,0.15); color: var(--gold); }
.badge-progress { background: rgba(43,184,163,0.15); color: var(--teal); }
.badge-completed { background: rgba(74,196,120,0.15); color: #4AC478; }
.badge-partial { background: rgba(232,163,61,0.15); color: var(--gold); }
.badge-cancelled { background: rgba(225,91,91,0.15); color: var(--danger); }

/* ---------- Alerts ---------- */
.alert { padding: 13px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 20px; border: 1px solid; }
.alert-success { background: rgba(74,196,120,0.1); border-color: rgba(74,196,120,0.3); color: #4AC478; }
.alert-error { background: rgba(225,91,91,0.1); border-color: rgba(225,91,91,0.3); color: #f18b8b; }
.alert-info { background: rgba(43,184,163,0.1); border-color: rgba(43,184,163,0.3); color: var(--teal); }

.footer { border-top: 1px solid var(--border); padding: 30px 0; color: var(--text-muted); font-size: 13.5px; text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero h1 { font-size: 36px; }
    .stat-strip { grid-template-columns: repeat(2, 1fr); }
    .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .app-shell { flex-direction: column; }
    .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border); }
    .main { max-width: 100%; padding: 22px; }
    .kpi-grid { grid-template-columns: repeat(2, 1fr); }
    .nav-links { display: none; }
}

/* Accessibility: visible focus */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
}
