/*
Theme Name: GLC Command
Theme URI: https://github.com/whowe/glc-theme
Author: Willie Howe
Author URI: https://github.com/whowe
Description: A refined executive companion theme for the GLC (Golf Logged Calculations) plugin. Built for facility executives and operators who need a clean, distraction-free command center for daily metrics, dashboards, and reporting.
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: glc-theme
Tags: one-column, custom-logo, custom-menu, featured-images, full-width-template, theme-options
*/

/* ============================================================
   GLC Command v1.1 — Flat Report Aesthetic
   Dark sidebar · Light/Dark content canvas · Metric separators
   Reduced radii · Editorial readability
   ============================================================ */

/* ---------- GOOGLE FONTS ---------- */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300..700;1,9..40,300..700&family=Plus+Jakarta+Sans:wght@600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');


/* ============================================================
   LIGHT MODE TOKENS (default)
   ============================================================ */
:root,
[data-theme="light"] {
    --glc-t-accent: var(--glc-accent, #00bb55);
    --glc-t-accent-soft: color-mix(in srgb, var(--glc-t-accent) 10%, transparent);
    --glc-t-accent-hover: color-mix(in srgb, var(--glc-t-accent) 80%, #000);

    /* Surface */
    --glc-t-bg: #f0f1f4;
    --glc-t-surface: #ffffff;
    --glc-t-surface-raised: #ffffff;
    --glc-t-border: #d9dce2;
    --glc-t-border-subtle: #e8ebf0;
    --glc-t-border-separator: #c8cdd6;

    /* Nav (always dark) */
    --glc-t-nav-bg: #0f1117;
    --glc-t-nav-text: #8b92a5;
    --glc-t-nav-text-active: #ffffff;

    /* Typography */
    --glc-t-text: #111827;
    --glc-t-text-secondary: #4b5563;
    --glc-t-text-muted: #7c8498;

    /* Status */
    --glc-t-success: #059669;
    --glc-t-success-bg: #ecfdf5;
    --glc-t-warning: #d97706;
    --glc-t-warning-bg: #fffbeb;
    --glc-t-danger: #dc2626;
    --glc-t-danger-bg: #fef2f2;

    /* Radii — flat, editorial */
    --glc-t-radius: 6px;
    --glc-t-radius-sm: 4px;
    --glc-t-radius-lg: 8px;

    /* Shadows — minimal */
    --glc-t-shadow-sm: 0 1px 2px rgba(0,0,0,.04);
    --glc-t-shadow: 0 1px 4px rgba(0,0,0,.06);
    --glc-t-shadow-lg: 0 4px 16px rgba(0,0,0,.08);

    /* Sizing */
    --glc-t-nav-width: 252px;
    --glc-t-content-max: 1200px;

    /* Fonts */
    --glc-t-font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --glc-t-font-display: 'Plus Jakarta Sans', 'DM Sans', sans-serif;
    --glc-t-font-mono: 'JetBrains Mono', 'SF Mono', 'Consolas', monospace;
}


/* ============================================================
   DARK MODE TOKENS
   ============================================================ */
[data-theme="dark"] {
    --glc-t-accent: var(--glc-accent, #34d399);
    --glc-t-accent-soft: color-mix(in srgb, var(--glc-t-accent) 12%, transparent);
    --glc-t-accent-hover: color-mix(in srgb, var(--glc-t-accent) 85%, #fff);

    --glc-t-bg: #0f1117;
    --glc-t-surface: #181b23;
    --glc-t-surface-raised: #1e222c;
    --glc-t-border: #2a2f3a;
    --glc-t-border-subtle: #232830;
    --glc-t-border-separator: #363c4a;

    --glc-t-nav-bg: #0a0c10;

    --glc-t-text: #e8eaf0;
    --glc-t-text-secondary: #9ca3b4;
    --glc-t-text-muted: #636d82;

    --glc-t-success: #34d399;
    --glc-t-success-bg: rgba(52,211,153,.08);
    --glc-t-warning: #fbbf24;
    --glc-t-warning-bg: rgba(251,191,36,.08);
    --glc-t-danger: #f87171;
    --glc-t-danger-bg: rgba(248,113,113,.08);
}

/* Respect OS preference when no explicit toggle */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --glc-t-accent: var(--glc-accent, #34d399);
        --glc-t-accent-soft: color-mix(in srgb, var(--glc-t-accent) 12%, transparent);
        --glc-t-accent-hover: color-mix(in srgb, var(--glc-t-accent) 85%, #fff);
        --glc-t-bg: #0f1117;
        --glc-t-surface: #181b23;
        --glc-t-surface-raised: #1e222c;
        --glc-t-border: #2a2f3a;
        --glc-t-border-subtle: #232830;
        --glc-t-border-separator: #363c4a;
        --glc-t-nav-bg: #0a0c10;
        --glc-t-text: #e8eaf0;
        --glc-t-text-secondary: #9ca3b4;
        --glc-t-text-muted: #636d82;
        --glc-t-success: #34d399;
        --glc-t-success-bg: rgba(52,211,153,.08);
        --glc-t-warning: #fbbf24;
        --glc-t-warning-bg: rgba(251,191,36,.08);
        --glc-t-danger: #f87171;
        --glc-t-danger-bg: rgba(248,113,113,.08);
    }
}


/* ============================================================
   RESET & FOUNDATION
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
body {
    margin: 0; padding: 0;
    font-family: var(--glc-t-font);
    color: var(--glc-t-text);
    background: var(--glc-t-bg);
    line-height: 1.6;
    transition: background .25s ease, color .25s ease;
}
a {
    color: var(--glc-t-accent);
    text-decoration: none;
    transition: color .15s ease;
}
a:hover { color: var(--glc-t-accent-hover); }
img { max-width: 100%; height: auto; }


/* ============================================================
   LAYOUT
   ============================================================ */
.glc-t-shell { display: flex; min-height: 100vh; }

/* ---------- SIDEBAR ---------- */
.glc-t-sidebar {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    width: var(--glc-t-nav-width);
    background: var(--glc-t-nav-bg);
    color: var(--glc-t-nav-text);
    display: flex;
    flex-direction: column;
    z-index: 100;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.06) transparent;
    transition: transform .3s cubic-bezier(.4,0,.2,1);
}
.glc-t-sidebar-brand {
    padding: 20px 18px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(255,255,255,.06);
    flex-shrink: 0;
}
.glc-t-sidebar-brand img { height: 32px; width: auto; border-radius: 4px; }
.glc-t-sidebar-brand-text { display: flex; flex-direction: column; }
.glc-t-sidebar-brand-name {
    font-family: var(--glc-t-font-display);
    font-weight: 800; font-size: 16px;
    color: #fff; letter-spacing: -.02em; line-height: 1.2;
}
.glc-t-sidebar-brand-sub {
    font-size: 10px; color: rgba(255,255,255,.3);
    font-weight: 600; letter-spacing: .06em;
    text-transform: uppercase; margin-top: 1px;
}

.glc-t-nav { flex: 1; padding: 14px 10px; }
.glc-t-nav-section { margin-bottom: 20px; }
.glc-t-nav-section-label {
    display: block; padding: 0 8px 6px;
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .1em;
    color: rgba(255,255,255,.22);
}
.glc-t-nav-link {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 10px; border-radius: var(--glc-t-radius-sm);
    font-size: 13.5px; font-weight: 500;
    color: var(--glc-t-nav-text);
    transition: all .12s ease;
    text-decoration: none; position: relative;
}
.glc-t-nav-link:hover {
    background: rgba(255,255,255,.06);
    color: var(--glc-t-nav-text-active);
}
.glc-t-nav-link.is-active {
    background: rgba(255,255,255,.08);
    color: var(--glc-t-nav-text-active);
    font-weight: 600;
}
.glc-t-nav-link.is-active::before {
    content: '';
    position: absolute;
    left: 0; top: 50%;
    transform: translateY(-50%);
    width: 3px; height: 18px;
    background: var(--glc-t-accent);
    border-radius: 0 2px 2px 0;
}
.glc-t-nav-icon { width: 18px; height: 18px; flex-shrink: 0; opacity: .55; }
.glc-t-nav-link.is-active .glc-t-nav-icon { opacity: 1; }

.glc-t-sidebar-footer {
    padding: 14px 18px 16px;
    border-top: 1px solid rgba(255,255,255,.06);
    flex-shrink: 0;
}
.glc-t-sidebar-user { display: flex; align-items: center; gap: 10px; }
.glc-t-sidebar-avatar {
    width: 30px; height: 30px; border-radius: 50%;
    background: rgba(255,255,255,.1);
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 12px; color: #fff; flex-shrink: 0;
}
.glc-t-sidebar-user-name { font-size: 13px; font-weight: 600; color: #fff; line-height: 1.3; }
.glc-t-sidebar-user-role { font-size: 10.5px; color: rgba(255,255,255,.35); }


/* ---------- MAIN ---------- */
.glc-t-main {
    margin-left: var(--glc-t-nav-width);
    flex: 1; min-width: 0;
    display: flex; flex-direction: column;
}

/* Top bar */
.glc-t-topbar {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--glc-t-bg) 85%, transparent);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glc-t-border);
    padding: 0 28px; height: 52px;
    display: flex; align-items: center;
    justify-content: space-between; gap: 16px;
}
.glc-t-topbar-left { display: flex; align-items: center; gap: 14px; }
.glc-t-topbar-title {
    font-family: var(--glc-t-font-display);
    font-weight: 700; font-size: 16px;
    color: var(--glc-t-text); letter-spacing: -.01em;
}
.glc-t-topbar-right { display: flex; align-items: center; gap: 6px; }

/* Theme toggle */
.glc-t-theme-toggle {
    width: 34px; height: 34px;
    display: flex; align-items: center; justify-content: center;
    background: transparent;
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius-sm);
    cursor: pointer;
    color: var(--glc-t-text-muted);
    padding: 0;
    transition: background .15s, color .15s, border-color .15s;
}
.glc-t-theme-toggle:hover {
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
    border-color: var(--glc-t-border-separator);
}
.glc-t-theme-toggle svg { width: 16px; height: 16px; }
.glc-t-icon-sun  { display: none; }
.glc-t-icon-moon { display: block; }
[data-theme="dark"] .glc-t-icon-sun  { display: block; }
[data-theme="dark"] .glc-t-icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .glc-t-icon-sun  { display: block; }
    :root:not([data-theme="light"]) .glc-t-icon-moon { display: none; }
}

/* Mobile toggle */
.glc-t-mobile-toggle {
    display: none;
    width: 34px; height: 34px;
    background: none; border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius-sm);
    cursor: pointer; align-items: center; justify-content: center;
    padding: 0; color: var(--glc-t-text);
}
.glc-t-mobile-toggle svg { width: 18px; height: 18px; }

/* Canvas */
.glc-t-canvas {
    flex: 1;
    padding: 24px 28px 48px;
    max-width: var(--glc-t-content-max);
    width: 100%; margin: 0 auto;
}

/* Overlay */
.glc-t-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,.5); z-index: 99;
}

/* Footer */
.glc-t-footer {
    padding: 16px 28px;
    border-top: 1px solid var(--glc-t-border);
    color: var(--glc-t-text-muted);
    font-size: 11.5px; text-align: center;
}

/* Admin bar */
body.admin-bar .glc-t-sidebar { top: 32px; }
body.admin-bar .glc-t-topbar  { top: 32px; }
@media (max-width: 782px) {
    body.admin-bar .glc-t-sidebar { top: 46px; }
    body.admin-bar .glc-t-topbar  { top: 46px; }
}


/* ============================================================
   GLC PLUGIN OVERRIDES — Flat Report Aesthetic
   ============================================================ */

/* Wrap */
.glc-t-canvas .glc-wrap { max-width: 100%; padding: 0; }

/* Header panel — flat, bordered */
.glc-t-canvas .glc-header {
    border-radius: var(--glc-t-radius);
    border: 1px solid var(--glc-t-border);
    box-shadow: none;
    background: var(--glc-t-surface);
    padding: 16px 20px;
}
.glc-t-canvas .glc-title {
    color: var(--glc-t-text);
}
.glc-t-canvas .glc-subtitle {
    color: var(--glc-t-text-secondary);
}

/* Buttons — flat, compact */
.glc-t-canvas .glc-btn {
    border-radius: var(--glc-t-radius-sm);
    padding: 8px 14px;
    font-size: 13px; font-weight: 600;
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
    transition: background .12s, border-color .12s;
}
.glc-t-canvas .glc-btn:hover {
    background: var(--glc-t-surface-raised);
    border-color: var(--glc-t-border-separator);
}
.glc-t-canvas .glc-btn-primary {
    background: var(--glc-t-accent); color: #fff;
    border-color: transparent;
}
.glc-t-canvas .glc-btn-primary:hover { opacity: .9; }

/* ── Section titles (metric group headers) with report separator ── */
.glc-t-canvas .glc-section-title {
    font-family: var(--glc-t-font-display);
    font-weight: 700; font-size: 13px;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--glc-t-text-muted);
    margin: 32px 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--glc-t-border-separator);
}

/* ── KPI Grid: flat bordered grid with internal dividers ── */
.glc-t-canvas .glc-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    margin-top: 0;
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    overflow: hidden;
    background: var(--glc-t-surface);
}

/* Cards — flat, no shadow, no rounding */
.glc-t-canvas .glc-card {
    background: var(--glc-t-surface);
    border: none; border-radius: 0;
    box-shadow: none;
    padding: 16px 18px;
    position: relative;
    transition: background .12s;
}
.glc-t-canvas .glc-card:hover {
    background: var(--glc-t-surface-raised);
    box-shadow: none; transform: none;
}

/* Vertical + horizontal separators */
.glc-t-canvas .glc-kpi-grid > .glc-card {
    border-right: 1px solid var(--glc-t-border-subtle);
    border-bottom: 1px solid var(--glc-t-border-subtle);
}
.glc-t-canvas .glc-kpi-grid > .glc-card:nth-child(4n) {
    border-right: none;
}
/* Remove bottom border from last row dynamically */
.glc-t-canvas .glc-kpi-grid > .glc-card:nth-last-child(-n+4):nth-child(4n+1),
.glc-t-canvas .glc-kpi-grid > .glc-card:nth-last-child(-n+4):nth-child(4n+1) ~ .glc-card {
    border-bottom: none;
}

/* Card labels */
.glc-t-canvas .glc-card-title {
    font-family: var(--glc-t-font); font-weight: 600;
    font-size: 11px; text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--glc-t-text-muted);
    margin-bottom: 4px;
}
.glc-t-canvas .glc-card-title a {
    color: var(--glc-t-text-muted); text-decoration: none;
}
.glc-t-canvas .glc-card-title a:hover { color: var(--glc-t-accent); }

/* Card values */
.glc-t-canvas .glc-card-value {
    font-family: var(--glc-t-font-display);
    font-weight: 800; font-size: 22px;
    letter-spacing: -.02em;
    color: var(--glc-t-text); line-height: 1.2;
}

/* Card sub-info */
.glc-t-canvas .glc-card-sub {
    margin-top: 6px; font-size: 12px;
    color: var(--glc-t-text-muted);
}

/* Deltas */
.glc-t-canvas .glc-delta.up   { color: var(--glc-t-success); }
.glc-t-canvas .glc-delta.down { color: var(--glc-t-danger); }

/* Target badges */
.glc-t-canvas .glc-target {
    margin-top: 6px; font-size: 11px;
    padding: 4px 8px;
    border-radius: var(--glc-t-radius-sm);
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface-raised);
    color: var(--glc-t-text-secondary);
}
.glc-t-canvas .glc-target-on   { border-color: var(--glc-t-success); background: var(--glc-t-success-bg); color: var(--glc-t-success); }
.glc-t-canvas .glc-target-watch { border-color: var(--glc-t-warning); background: var(--glc-t-warning-bg); color: var(--glc-t-warning); }
.glc-t-canvas .glc-target-off  { border-color: var(--glc-t-danger);  background: var(--glc-t-danger-bg);  color: var(--glc-t-danger); }

/* Sparklines */
.glc-t-canvas .glc-card-sparkline { margin-top: 8px; opacity: .7; }

/* ── Tables ── */
.glc-t-canvas .glc-table-wrap {
    margin-top: 12px;
    background: var(--glc-t-surface);
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    padding: 0; overflow: hidden;
}
.glc-t-canvas .glc-table { width: 100%; border-collapse: collapse; }
.glc-t-canvas .glc-table th {
    font-family: var(--glc-t-font);
    font-size: 10.5px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .07em;
    color: var(--glc-t-text-muted);
    padding: 10px 14px;
    border-bottom: 2px solid var(--glc-t-border-separator);
    background: var(--glc-t-surface);
    text-align: left;
}
.glc-t-canvas .glc-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--glc-t-border-subtle);
    font-size: 14px; color: var(--glc-t-text);
}
.glc-t-canvas .glc-table tr:last-child td { border-bottom: none; }
.glc-t-canvas .glc-table tr:hover td { background: var(--glc-t-surface-raised); }

/* ── Notices ── */
.glc-t-canvas .glc-notice {
    padding: 12px 16px;
    border-radius: var(--glc-t-radius);
    margin: 12px 0;
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    font-size: 14px; color: var(--glc-t-text);
}
.glc-t-canvas .glc-notice-success {
    border-color: var(--glc-t-success);
    border-left: 3px solid var(--glc-t-success);
    background: var(--glc-t-success-bg);
}
.glc-t-canvas .glc-notice-warning {
    border-color: var(--glc-t-warning);
    border-left: 3px solid var(--glc-t-warning);
    background: var(--glc-t-warning-bg);
}

/* ── Narrative ── */
.glc-t-canvas .glc-narrative {
    background: var(--glc-t-surface);
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    padding: 16px 20px;
}
.glc-t-canvas .glc-narrative .glc-narrative-list {
    color: var(--glc-t-text);
}

/* ── Confidence ── */
.glc-t-canvas .glc-confidence {
    font-family: var(--glc-t-font-mono);
    font-size: 11.5px; font-weight: 500;
    padding: 2px 8px;
    border-radius: var(--glc-t-radius-sm);
}
.glc-t-canvas .glc-conf-good { border-color: var(--glc-t-success); color: var(--glc-t-success); }
.glc-t-canvas .glc-conf-warn { border-color: var(--glc-t-warning); color: var(--glc-t-warning); }
.glc-t-canvas .glc-conf-bad  { border-color: var(--glc-t-danger);  color: var(--glc-t-danger); }

/* ── Period ── */
.glc-t-canvas .glc-period select {
    padding: 8px 12px;
    border-radius: var(--glc-t-radius-sm);
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
    font-family: var(--glc-t-font);
    font-size: 13px;
}

/* ── Help / Footnotes ── */
.glc-t-canvas .glc-help { color: var(--glc-t-text-muted); font-size: 12px; }
.glc-t-canvas .glc-footnote {
    margin-top: 20px; padding-top: 12px;
    border-top: 1px solid var(--glc-t-border-subtle);
    color: var(--glc-t-text-muted); font-size: 12px;
}

/* ── Forms ── */
.glc-t-canvas .glc-form {
    background: var(--glc-t-surface);
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    padding: 16px 20px;
}
.glc-t-canvas .glc-metric {
    background: var(--glc-t-surface-raised);
    border: 1px solid var(--glc-t-border-subtle);
    border-radius: var(--glc-t-radius);
    padding: 12px;
}
.glc-t-canvas .glc-grid { gap: 10px; }

/* All inputs */
.glc-t-canvas input[type="text"],
.glc-t-canvas input[type="number"],
.glc-t-canvas input[type="date"],
.glc-t-canvas input[type="password"],
.glc-t-canvas input[type="time"],
.glc-t-canvas select,
.glc-t-canvas textarea {
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius-sm);
    padding: 8px 12px;
    font-family: var(--glc-t-font);
    font-size: 13.5px; color: var(--glc-t-text);
    background: var(--glc-t-surface);
    transition: border-color .12s, box-shadow .12s;
}
.glc-t-canvas input:focus,
.glc-t-canvas select:focus,
.glc-t-canvas textarea:focus {
    outline: none;
    border-color: var(--glc-t-accent);
    box-shadow: 0 0 0 2px var(--glc-t-accent-soft);
}

/* ── Timeline ── */
.glc-t-canvas .glc-timeline-item {
    background: var(--glc-t-surface);
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    padding: 12px 16px; margin-top: 8px;
}
.glc-t-canvas .glc-timeline-date {
    font-family: var(--glc-t-font-mono);
    font-size: 13px; font-weight: 500;
    color: var(--glc-t-text);
}
.glc-t-canvas .glc-timeline-tags { font-size: 12px; color: var(--glc-t-text-muted); }
.glc-t-canvas .glc-timeline-notes { color: var(--glc-t-text-secondary); }

/* ── Charts ── */
.glc-t-canvas .glc-charts-grid { gap: 16px; }
.glc-t-canvas .glc-chart-wrap { background: transparent; }
.glc-t-canvas .glc-chart-caption { color: var(--glc-t-text-muted); }

/* ── Sysadmin tabs ── */
.glc-t-canvas .glc-sysadmin-tabs .glc-tab {
    border-radius: var(--glc-t-radius-sm);
    font-size: 13px;
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    color: var(--glc-t-text-secondary);
    padding: 7px 12px;
}
.glc-t-canvas .glc-sysadmin-tabs .glc-tab.active {
    background: var(--glc-t-accent-soft);
    border-color: var(--glc-t-accent);
    color: var(--glc-t-accent); font-weight: 600;
}
.glc-t-canvas .glc-sysadmin-subtabs .glc-subtab {
    border-radius: 999px;
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    color: var(--glc-t-text-secondary);
    font-size: 12px; padding: 5px 10px;
}
.glc-t-canvas .glc-sysadmin-subtabs .glc-subtab.active {
    border-color: var(--glc-t-text);
    color: var(--glc-t-text); font-weight: 600;
}
.glc-t-canvas .glc-sysadmin input,
.glc-t-canvas .glc-sysadmin select,
.glc-t-canvas .glc-sysadmin textarea { border-radius: var(--glc-t-radius-sm); }
.glc-t-canvas .glc-sysadmin .glc-btn { border-radius: var(--glc-t-radius-sm); }
.glc-t-canvas .glc-sysadmin .glc-btn-danger {
    background: var(--glc-t-danger);
    border-color: var(--glc-t-danger);
    color: #fff;
}

/* ── Executive Summary ── */
.glc-t-canvas .glc-exec-summary-big {
    font-family: var(--glc-t-font-display);
    font-weight: 800; letter-spacing: -.03em;
    color: var(--glc-t-text);
}
.glc-t-canvas .glc-exec-summary-mini-grid div {
    border: 1px solid var(--glc-t-border-subtle);
    border-radius: var(--glc-t-radius);
    background: var(--glc-t-surface-raised);
}
.glc-t-canvas .glc-exec-summary-mini-grid span { color: var(--glc-t-text-muted); }
.glc-t-canvas .glc-exec-summary-mini-grid strong { color: var(--glc-t-text); }
.glc-t-canvas .glc-exec-summary-table th {
    background: var(--glc-t-surface);
    color: var(--glc-t-text-muted);
}
.glc-t-canvas .glc-exec-summary-group td {
    background: var(--glc-t-surface-raised);
    color: var(--glc-t-text-secondary);
}
.glc-t-canvas .glc-exec-summary-weather-card {
    border: 1px solid var(--glc-t-border-subtle);
    border-radius: var(--glc-t-radius);
    background: var(--glc-t-surface-raised);
}
.glc-t-canvas .glc-exec-summary-weather-copy span { color: var(--glc-t-text-muted); }
.glc-t-canvas .glc-exec-summary-weather-temp { color: var(--glc-t-text); }

/* ── Dashboard pages ── */
.glc-t-canvas .glc-dashboard-audience-badge {
    font-family: var(--glc-t-font);
    font-size: 11px; letter-spacing: .06em;
    border-radius: var(--glc-t-radius-sm);
    background: var(--glc-t-accent-soft);
    color: var(--glc-t-accent);
}
.glc-t-canvas .glc-dashboard-intro { color: var(--glc-t-text-secondary); }
.glc-t-canvas .glc-dashboard-grid {
    gap: 0;
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    overflow: hidden;
    background: var(--glc-t-surface);
}
.glc-t-canvas .glc-dashboard-grid .glc-card {
    border-right: 1px solid var(--glc-t-border-subtle);
    border-bottom: 1px solid var(--glc-t-border-subtle);
}
.glc-t-canvas .glc-dashboard-card .glc-card-value {
    font-size: 26px;
}
.glc-t-canvas .glc-dashboard-delta { color: var(--glc-t-text-muted); }
.glc-t-canvas .glc-dashboard-delta.glc-delta-up   { color: var(--glc-t-success); }
.glc-t-canvas .glc-dashboard-delta.glc-delta-down { color: var(--glc-t-danger); }
.glc-t-canvas .glc-dashboard-tag {
    border-radius: var(--glc-t-radius-sm);
    background: var(--glc-t-surface-raised);
    color: var(--glc-t-text-secondary);
    font-size: 11.5px;
}

/* ── Builder ── */
.glc-t-canvas .glc-builder-chip {
    border-radius: var(--glc-t-radius-sm);
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
}
.glc-t-canvas .glc-builder-chip.is-selected,
.glc-t-canvas .glc-builder-chip:has(input:checked) {
    background: var(--glc-t-accent-soft);
    border-color: var(--glc-t-accent);
}
.glc-t-canvas .glc-builder-chip span { color: var(--glc-t-text); }
.glc-t-canvas .glc-builder-url {
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius-sm);
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
}

/* ── Ticket form ── */
.glc-t-canvas .glc-ticket-form input,
.glc-t-canvas .glc-ticket-form select,
.glc-t-canvas .glc-ticket-form textarea {
    border-radius: var(--glc-t-radius-sm);
    border: 1px solid var(--glc-t-border);
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
}
.glc-t-canvas .glc-ticket-form .glc-btn {
    border-radius: var(--glc-t-radius-sm);
    background: var(--glc-t-accent);
    color: #fff; border-color: var(--glc-t-accent);
}

/* ── Board packet select ── */
.glc-t-canvas .glc-board-packet-form select {
    border-radius: var(--glc-t-radius-sm) !important;
    border: 1px solid var(--glc-t-border) !important;
    background: var(--glc-t-surface) !important;
    color: var(--glc-t-text) !important;
}

/* ── Logo ── */
.glc-t-canvas .glc-logo { border-radius: var(--glc-t-radius-sm); }

/* ── Weather badge ── */
.glc-t-canvas .glc-weather-badge { color: var(--glc-t-text-secondary); }

/* ── Export bar ── */
.glc-t-canvas .glc-export { gap: 6px; }

/* ── Two-column layout (Event Attribution + Narrative) ── */
.glc-t-canvas .glc-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}
.glc-t-canvas .glc-grid-2 > .glc-card {
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius);
    padding: 16px 20px;
}

/* Nested KPI grids inside cards (Event Attribution) */
.glc-t-canvas .glc-card .glc-kpi-grid {
    border: 1px solid var(--glc-t-border-subtle);
    border-radius: var(--glc-t-radius);
}

/* ── Textareas (Narrative builder) ── */
.glc-t-canvas textarea {
    border: 1px solid var(--glc-t-border);
    border-radius: var(--glc-t-radius-sm);
    background: var(--glc-t-surface);
    color: var(--glc-t-text);
    font-family: var(--glc-t-font);
    font-size: 13.5px;
    padding: 10px 12px;
}


/* ============================================================
   UTILITY
   ============================================================ */
.glc-t-sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap; border: 0;
}
.glc-t-shell--nosidebar .glc-t-main { margin-left: 0; }
.glc-t-shell--nosidebar .glc-t-sidebar { display: none; }


/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
    .glc-t-canvas .glc-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .glc-t-canvas .glc-kpi-grid > .glc-card:nth-child(4n) {
        border-right: 1px solid var(--glc-t-border-subtle);
    }
    .glc-t-canvas .glc-kpi-grid > .glc-card:nth-child(2n) {
        border-right: none;
    }
    .glc-t-canvas .glc-grid-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    :root, [data-theme="light"], [data-theme="dark"] {
        --glc-t-nav-width: 232px;
    }
    .glc-t-canvas { padding: 20px 20px 40px; }
}

@media (max-width: 782px) {
    .glc-t-mobile-toggle { display: flex; }
    .glc-t-sidebar { transform: translateX(-100%); width: 272px; }
    .glc-t-sidebar.is-open { transform: translateX(0); }
    .glc-t-overlay.is-visible { display: block; }
    .glc-t-main { margin-left: 0; }
    .glc-t-canvas { padding: 16px; }
    .glc-t-topbar { padding: 0 16px; }
    .glc-t-canvas .glc-kpi-grid {
        grid-template-columns: 1fr;
    }
    .glc-t-canvas .glc-kpi-grid > .glc-card {
        border-right: none !important;
    }
}


/* ============================================================
   PRINT
   ============================================================ */
@media print {
    .glc-t-sidebar,
    .glc-t-topbar,
    .glc-t-footer,
    .glc-t-mobile-toggle,
    .glc-t-overlay,
    .glc-t-theme-toggle { display: none !important; }
    .glc-t-main { margin-left: 0 !important; }
    .glc-t-canvas { padding: 0 !important; max-width: 100% !important; }
    body { background: #fff !important; color: #000 !important; }
    .glc-t-canvas .glc-card,
    .glc-t-canvas .glc-kpi-grid,
    .glc-t-canvas .glc-table-wrap,
    .glc-t-canvas .glc-notice { border-color: #ccc !important; }
    .glc-t-canvas .glc-card-title { color: #666 !important; }
    .glc-t-canvas .glc-card-value { color: #000 !important; }
}
