/* Panel theme: sidebar layout, graphite-green palette, rounded pill controls.
   Loaded AFTER style.css. Only colors, fonts, shapes and positions are changed;
   element ids, classes, roles and aria attributes are untouched so main.js,
   accessibility.js and the backend keep working. */
:root {
    --bg-dark: #0e1512;
    --bg-card: #17211c;
    --bg-input: #1f2d26;
    --border-color: #5f8a76;
    --primary-color: #2dd4bf;
    --primary-hover: #14b8a6;
    --primary-solid: #0f766e;
    --primary-solid-hover: #115e59;
    --success-color: #4ade80;
    --warning-color: #fbbf24;
    --danger-color: #fb7185;
    --text-main: #f1ece2;
    --text-muted: #b5b9ad;
    --sidebar-w: 252px;
    --ui-radius: 14px;
    --ui-serif: "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
}
* { font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif; }
h1, h2, h3, h4, .brand-title, .card-header { font-family: var(--ui-serif); letter-spacing: 0.01em; }

/* Shapes */
.card { border-radius: var(--ui-radius); box-shadow: none; }
.card-header { border-radius: var(--ui-radius) var(--ui-radius) 0 0; }
.btn { border-radius: 999px; padding-left: 16px; padding-right: 16px; }
.btn-sm { padding-left: 12px; padding-right: 12px; }
.form-control { border-radius: 10px; }
.badge { border-radius: 999px; }
.table th { text-transform: uppercase; font-size: 0.72rem; letter-spacing: 0.08em; }
.verse-of-day { border-radius: var(--ui-radius); border-left: 6px solid var(--primary-color); background: var(--bg-card); }
.verse-of-day blockquote p { font-family: var(--ui-serif); font-size: 1.05rem; }

/* Top bar: slim, no shadow */
.navbar { background-color: var(--bg-dark); box-shadow: none; border-bottom: 2px solid var(--primary-solid); padding: 10px 24px; }
.brand-title { color: var(--text-main); font-size: 1.2rem; }
.brand-sub { color: var(--primary-color); }

/* Sub-tabs: segmented control */
.subtabs { gap: 6px; border-bottom: 0; padding: 4px; background: var(--bg-input); border-radius: 999px; display: inline-flex; flex-wrap: wrap; }
.subtab-btn { border-radius: 999px; border: 0; }
.subtab-btn.active { background: var(--primary-solid); color: #fff; }

/* Dashboard shell: vertical sidebar navigation */
body.ui-shell .tabs {
    position: fixed; top: var(--navbar-h, 62px); left: 0; bottom: 0;
    width: var(--sidebar-w); overflow-y: auto;
    flex-direction: column; flex-wrap: nowrap; gap: 4px;
    padding: 16px 10px; margin: 0;
    background: var(--bg-card); border-bottom: 0; border-right: 1px solid var(--border-color);
    z-index: 250;
}
body.ui-shell .tab-btn {
    width: 100%; justify-content: flex-start; text-align: left;
    border: 0; border-left: 4px solid transparent; border-radius: 0 999px 999px 0;
    padding: 11px 14px; color: var(--text-muted);
}
body.ui-shell .tab-btn .badge { margin-left: auto; }
body.ui-shell .tab-btn:hover { background: rgba(45, 212, 191, 0.08); color: var(--text-main); }
body.ui-shell .tab-btn.active { background: rgba(45, 212, 191, 0.14); border-left-color: var(--primary-color); color: var(--text-main); }
body.ui-shell main.container { max-width: none; margin: 0; padding: 28px 36px 48px calc(var(--sidebar-w) + 36px); }

/* Narrow windows and zoom: sidebar becomes a scrolling bar again */
@media (max-width: 900px) {
    body.ui-shell .tabs { position: sticky; top: var(--navbar-h, 62px); width: auto; bottom: auto; flex-direction: row; overflow-x: auto; overflow-y: visible; padding: 8px; border-right: 0; border-bottom: 1px solid var(--border-color); }
    body.ui-shell .tab-btn { width: auto; white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; border-radius: 10px 10px 0 0; }
    body.ui-shell .tab-btn.active { border-bottom-color: var(--primary-color); }
    body.ui-shell main.container { padding: 16px; }
}

/* Public pages: centered narrow column */
body.bg-dark:not(.ui-shell) main.container { max-width: 760px; }

/* Keep code-like text monospace (the universal font rule above would override the browser default) */
code, pre, kbd, samp, .mono { font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; }
