/* ============================================================
   ThePMO.biz -- assets/css/app.css
   Brand: Navy #1B3A6B | Teal #0E7C7B | Amber #E8A020
   Fonts: Raleway (display) | DM Sans (UI) | Space Mono (labels)
   Inherits design system from thepmoffice.co.uk stylesheet v2
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500;600;700&family=Raleway:wght@700;800&family=Space+Mono:wght@400;700&display=swap');

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --navy:   #1B3A6B;
  --teal:   #0E7C7B;
  --amber:  #E8A020;
  --white:  #FFFFFF;
  --light:  #F4F6F9;
  --mid:    #D9DDE4;
  --dark:   #12131F;
  --ink:    #1C1C1C;
  --body:   #4A4A5A;
  --brand-primary:   #1B3A6B;
  --brand-secondary: #0E7C7B;
  --brand-accent:    #E8A020;
  --bg-page:  #F4F6F9;
  --bg-card:  #FFFFFF;
  --border:   #D9DDE4;
  --text-primary: #1C1C1C;
  --text-muted:   #6B7280;
  --text-light:   #9CA3AF;
  --amber-lt: #FEF3DC;
  --navy-lt:  #EEF2F8;
  --rag-red:      #DC2626;
  --rag-red-lt:   #FEF2F2;
  --rag-amber:    #D97706;
  --rag-amber-lt: #FFFBEB;
  --rag-green:    #16A34A;
  --rag-green-lt: #F0FDF4;
  --rag-grey:     #6B7280;
  --rag-grey-lt:  #F9FAFB;
  --sidebar-width: 240px;
  --topbar-height: 56px;
  --radius-sm: 4px;
  --radius:    8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow:    0 2px 8px rgba(0,0,0,0.10);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
  --transition: 0.28s ease;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.9375rem;
  color: var(--body);
  background: var(--bg-page);
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--teal); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--navy); }

h1, h2 { font-family: 'Raleway', 'DM Sans', sans-serif; color: var(--navy); line-height: 1.15; }
h1 { font-size: 1.75rem; font-weight: 800; }
h2 { font-size: 1.375rem; font-weight: 700; }
h3 { font-family: 'DM Sans', sans-serif; font-size: 1.125rem; font-weight: 700; color: var(--navy); line-height: 1.3; }
h4 { font-family: 'Space Mono', monospace; font-size: 0.65rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: var(--amber); }
p { color: var(--body); margin-bottom: 0.75rem; }
p:last-child { margin-bottom: 0; }

/* ── App wrapper ───────────────────────────────────────────── */
.app-wrapper { display: flex; min-height: 100vh; }

/* ── Sidebar ───────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-width);
  min-height: 100vh;
  background: var(--navy);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 200;
  overflow-y: auto;
  overflow-x: hidden;
  transition: transform var(--transition);
  flex-shrink: 0;
}
.sidebar-brand { padding: 1.25rem 1rem 1rem; border-bottom: 1px solid rgba(255,255,255,0.08); flex-shrink: 0; }
.sidebar-logo { max-width: 168px; height: auto; display: block; }

/* Text fallback logo -- matches thepmoffice.co.uk nav style */
.sidebar-logo-text { display: flex; flex-direction: column; line-height: 1; }
.logo-the { font-family: 'DM Sans', sans-serif; font-size: 0.55rem; font-weight: 400; letter-spacing: 0.34em; text-transform: uppercase; color: rgba(255,255,255,0.4); margin-bottom: 1px; }
.logo-pm { font-family: 'DM Sans', sans-serif; font-size: 1.15rem; font-weight: 700; color: var(--white); letter-spacing: 0.01em; display: inline; }
.logo-office { font-family: 'DM Sans', sans-serif; font-size: 1.15rem; font-weight: 700; color: var(--teal); letter-spacing: 0.01em; display: inline; }
.logo-tag { font-family: 'Space Mono', monospace; font-size: 0.45rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--amber); margin-top: 3px; }

/* Nav */
.sidebar-nav { list-style: none; padding: 0.75rem 0; flex: 1; }
.nav-link { display: flex; align-items: center; gap: 0.625rem; padding: 0.625rem 1rem; color: rgba(255,255,255,0.65); font-family: 'DM Sans', sans-serif; font-size: 0.875rem; font-weight: 500; transition: background var(--transition), color var(--transition); text-decoration: none; }
.nav-link:hover { background: rgba(255,255,255,0.07); color: var(--white); text-decoration: none; }
.nav-link.active { background: rgba(14,124,123,0.2); color: var(--white); border-left: 3px solid var(--teal); }
.nav-icon { width: 18px; height: 18px; flex-shrink: 0; stroke: currentColor; stroke-width: 2; fill: none; }
.nav-divider { height: 1px; background: rgba(255,255,255,0.08); margin: 0.5rem 1rem; }
.nav-section-label { font-family: 'Space Mono', monospace; font-size: 0.55rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: rgba(255,255,255,0.3); padding: 0.5rem 1rem 0.25rem; }

/* Context switcher */
.sidebar-context { padding: 0.75rem 1rem; border-top: 1px solid rgba(255,255,255,0.08); border-bottom: 1px solid rgba(255,255,255,0.08); }
.context-label { font-family: 'Space Mono', monospace; font-size: 0.5rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: rgba(255,255,255,0.3); display: block; margin-bottom: 0.375rem; }
.context-select { width: 100%; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15); border-radius: var(--radius-sm); color: var(--white); font-size: 0.8125rem; padding: 0.375rem 0.5rem; cursor: pointer; }
.context-select option { background: var(--navy); }

/* User footer */
.sidebar-user { display: flex; align-items: center; gap: 0.625rem; padding: 0.875rem 1rem; border-top: 1px solid rgba(255,255,255,0.08); flex-shrink: 0; }
.user-avatar-sm { width: 32px; height: 32px; border-radius: 50%; background: var(--teal); color: var(--white); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; flex-shrink: 0; }
.user-info { flex: 1; min-width: 0; }
.user-name { font-size: 0.8125rem; font-weight: 600; color: var(--white); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-role { font-family: 'Space Mono', monospace; font-size: 0.5rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.35); }
.user-actions { display: flex; gap: 0.375rem; flex-shrink: 0; }
.user-actions a { color: rgba(255,255,255,0.4); display: flex; align-items: center; transition: color var(--transition); }
.user-actions a:hover { color: var(--white); }

/* ── Main content ──────────────────────────────────────────── */
.main-content { flex: 1; margin-left: var(--sidebar-width); display: flex; flex-direction: column; min-height: 100vh; }

/* ── Top bar ───────────────────────────────────────────────── */
.top-bar { height: var(--topbar-height); background: var(--bg-card); border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 1.5rem; gap: 1rem; position: sticky; top: 0; z-index: 100; flex-shrink: 0; }
.sidebar-toggle { background: none; border: none; cursor: pointer; color: var(--text-muted); display: none; padding: 0.25rem; }
.sidebar-toggle svg { width: 20px; height: 20px; }
.top-bar-right { margin-left: auto; display: flex; align-items: center; gap: 1rem; }

/* ── Page content ──────────────────────────────────────────── */
.page-content { flex: 1; padding: 1.75rem 2rem; max-width: 1400px; width: 100%; }

/* ── Page header ───────────────────────────────────────────── */
.page-header { display: flex; align-items: flex-start; gap: 1rem; margin-bottom: 1.75rem; }
.page-header-text { flex: 1; }
.page-title { font-family: 'Raleway', sans-serif; font-size: 1.625rem; font-weight: 800; color: var(--navy); margin: 0 0 0.25rem; }
.page-subtitle { font-size: 0.9375rem; color: var(--text-muted); margin: 0; }
.page-header-actions { display: flex; align-items: center; gap: 0.75rem; flex-shrink: 0; }

/* ── Cards ─────────────────────────────────────────────────── */
.card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.card-header { padding: 1.125rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 0.75rem; }
.card-title { font-family: 'DM Sans', sans-serif; font-size: 1rem; font-weight: 600; color: var(--navy); margin: 0; flex: 1; }
.card-body { padding: 1.5rem; }
.card-footer { padding: 1rem 1.5rem; border-top: 1px solid var(--border); background: var(--light); border-radius: 0 0 var(--radius-lg) var(--radius-lg); }

/* ── Stat cards ────────────────────────────────────────────── */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.25rem; margin-bottom: 1.75rem; }
.stat-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 1.25rem 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; box-shadow: var(--shadow-sm); }
.stat-card-label { font-family: 'Space Mono', monospace; font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.15em; color: var(--text-muted); }
.stat-card-value { font-family: 'Raleway', sans-serif; font-size: 2rem; font-weight: 800; color: var(--navy); line-height: 1; }
.stat-card-sub { font-size: 0.8125rem; color: var(--text-muted); }
.stat-card.accent-teal  { border-left: 4px solid var(--teal); }
.stat-card.accent-navy  { border-left: 4px solid var(--navy); }
.stat-card.accent-amber { border-left: 4px solid var(--amber); }
.stat-card.accent-green { border-left: 4px solid var(--rag-green); }
.stat-card.accent-red   { border-left: 4px solid var(--rag-red); }

/* ── Buttons ───────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.625rem 1.25rem; font-family: 'DM Sans', sans-serif; font-size: 0.875rem; font-weight: 600; border-radius: var(--radius-sm); border: 2px solid transparent; cursor: pointer; transition: all var(--transition); text-decoration: none; white-space: nowrap; line-height: 1.4; letter-spacing: 0.01em; }
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn-primary { background: var(--teal); color: var(--white); border-color: var(--teal); }
.btn-primary:hover { background: #0a6665; border-color: #0a6665; color: var(--white); text-decoration: none; }
.btn-navy { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-navy:hover { background: #142e56; border-color: #142e56; color: var(--white); text-decoration: none; }
.btn-outline { background: transparent; color: var(--navy); border-color: var(--mid); }
.btn-outline:hover { background: var(--light); border-color: var(--navy); text-decoration: none; }
.btn-danger { background: var(--rag-red); color: var(--white); border-color: var(--rag-red); }
.btn-danger:hover { background: #b91c1c; border-color: #b91c1c; color: var(--white); text-decoration: none; }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8125rem; }
.btn-lg { padding: 0.875rem 1.75rem; font-size: 0.95rem; }
.btn:disabled, .btn[disabled] { opacity: 0.55; cursor: not-allowed; pointer-events: none; }

/* ── Forms ─────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.125rem; }
.form-label { display: block; font-family: 'DM Sans', sans-serif; font-size: 0.875rem; font-weight: 600; color: var(--navy); margin-bottom: 0.4rem; }
.form-label .required { color: var(--rag-red); margin-left: 2px; }
.form-control { display: block; width: 100%; padding: 0.7rem 1rem; font-family: 'DM Sans', sans-serif; font-size: 0.9rem; color: var(--ink); background: var(--white); border: 1px solid var(--mid); border-radius: var(--radius-sm); transition: border-color var(--transition), box-shadow var(--transition); line-height: 1.5; -webkit-appearance: none; }
.form-control:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(14,124,123,0.12); }
.form-control::placeholder { color: rgba(74,74,90,0.4); }
select.form-control { cursor: pointer; }
textarea.form-control { resize: vertical; min-height: 100px; }
.form-hint { font-size: 0.8125rem; color: var(--text-muted); margin-top: 0.3rem; }
.form-error { font-size: 0.8125rem; color: var(--rag-red); margin-top: 0.3rem; }
.form-control.is-invalid { border-color: var(--rag-red); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; }

/* ── Tables ────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--border); background: var(--bg-card); box-shadow: var(--shadow-sm); }
.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table thead th { background: var(--navy); color: var(--white); font-family: 'Space Mono', monospace; font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; padding: 0.75rem 1rem; text-align: left; white-space: nowrap; }
.table tbody tr { border-bottom: 1px solid var(--border); transition: background var(--transition); }
.table tbody tr:last-child { border-bottom: none; }
.table tbody tr:hover { background: var(--navy-lt); }
.table td { padding: 0.875rem 1rem; color: var(--body); vertical-align: middle; }
.table-actions { display: flex; gap: 0.5rem; align-items: center; }

/* ── Badges ────────────────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.2rem 0.625rem; font-family: 'Space Mono', monospace; font-size: 0.58rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; border-radius: 999px; white-space: nowrap; }
.badge-navy   { background: var(--navy);         color: var(--white); }
.badge-teal   { background: var(--teal);         color: var(--white); }
.badge-amber  { background: var(--amber-lt);     color: #92400e; }
.badge-grey   { background: var(--light);        color: var(--text-muted); border: 1px solid var(--border); }
.badge-green  { background: var(--rag-green-lt); color: var(--rag-green); }
.badge-red    { background: var(--rag-red-lt);   color: var(--rag-red); }
.badge-orange { background: var(--rag-amber-lt); color: var(--rag-amber); }

.rag { display: inline-block; width: 12px; height: 12px; border-radius: 50%; flex-shrink: 0; }
.rag-R { background: var(--rag-red); }
.rag-A { background: var(--rag-amber); }
.rag-G { background: var(--rag-green); }
.rag-U { background: var(--rag-grey); }

/* ── Flash messages ────────────────────────────────────────── */
.flash { display: flex; align-items: center; gap: 0.75rem; padding: 0.875rem 1.5rem; font-size: 0.9rem; font-weight: 500; border-left: 4px solid; margin: 0; }
.flash svg { width: 18px; height: 18px; flex-shrink: 0; }
.flash-success { background: var(--rag-green-lt); border-color: var(--rag-green); color: #14532d; }
.flash-error   { background: var(--rag-red-lt);   border-color: var(--rag-red);   color: #7f1d1d; }
.flash-warning { background: var(--rag-amber-lt); border-color: var(--rag-amber); color: #78350f; }
.flash-info    { background: var(--navy-lt);       border-color: var(--teal);     color: var(--navy); }

/* ── Standalone / Auth pages ───────────────────────────────── */
body.standalone {
  background: linear-gradient(135deg, var(--navy) 0%, #0d2347 55%, var(--teal) 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-wrapper { width: 100%; max-width: 440px; padding: 1.5rem; }
.auth-card { background: var(--white); border-radius: var(--radius-xl); box-shadow: var(--shadow-lg); padding: 2.5rem; }

/* Logo on auth pages */
.auth-brand { display: flex; flex-direction: column; align-items: center; margin-bottom: 2rem; }
.auth-brand-logo { max-width: 220px; width: 100%; height: auto; display: block; margin: 0 auto; }

/* Text fallback */
.auth-brand .sidebar-logo-text { align-items: center; text-align: center; }
.auth-brand .logo-the { font-size: 0.6rem; color: var(--text-muted); letter-spacing: 0.25em; }
.auth-brand .logo-pm { font-size: 2.25rem; color: var(--navy); }
.auth-brand .logo-office { font-size: 2.25rem; color: var(--teal); }
.auth-brand .logo-tag { font-size: 0.5rem; color: var(--amber); text-align: center; margin-top: 4px; }

.auth-title { font-family: 'Raleway', sans-serif; font-size: 1.375rem; font-weight: 800; color: var(--navy); text-align: center; margin-bottom: 0.375rem; }
.auth-subtitle { font-size: 0.9rem; color: var(--text-muted); text-align: center; margin-bottom: 1.75rem; }
.auth-footer { text-align: center; font-size: 0.8125rem; color: var(--text-muted); margin-top: 1.5rem; }

/* ── Filter bar / Admin bar ────────────────────────────────── */
.filter-bar { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.filter-label { white-space: nowrap; font-family: 'Space Mono', monospace; font-size: 0.58rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.filter-field { flex: 1; min-width: 140px; max-width: 220px; }
.filter-field .form-control { height: 36px; padding: 0.375rem 0.75rem; font-size: 0.875rem; }
.admin-bar-search { position: relative; }
.admin-bar-search svg { position: absolute; left: 0.75rem; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; stroke: var(--text-muted); pointer-events: none; }
.admin-bar-search .form-control { padding-left: 2.25rem; }

/* ── Pagination ────────────────────────────────────────────── */
.pagination { display: flex; align-items: center; justify-content: space-between; padding: 0.875rem 1rem; border-top: 1px solid var(--border); font-size: 0.875rem; color: var(--text-muted); }
.pagination-links { display: flex; gap: 0.25rem; }
.pagination-links a, .pagination-links span { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 500; border: 1px solid var(--border); color: var(--ink); text-decoration: none; transition: background var(--transition); }
.pagination-links a:hover { background: var(--light); text-decoration: none; }
.pagination-links .current { background: var(--navy); color: var(--white); border-color: var(--navy); }

/* ── Empty state ───────────────────────────────────────────── */
.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-muted); }
.empty-state svg { width: 48px; height: 48px; stroke: var(--border); margin-bottom: 1rem; }
.empty-state h3 { font-size: 1.125rem; color: var(--text-muted); margin-bottom: 0.5rem; font-family: 'DM Sans', sans-serif; font-weight: 600; }

/* ── Callout ───────────────────────────────────────────────── */
.callout { display: flex; border-radius: var(--radius); overflow: hidden; margin-bottom: 1rem; }
.callout-bar { width: 4px; background: var(--amber); flex-shrink: 0; }
.callout-body { background: var(--amber-lt); padding: 0.75rem 1rem; font-size: 0.9rem; flex: 1; color: var(--ink); }

/* ── Spinner ───────────────────────────────────────────────── */
.spinner { width: 20px; height: 20px; border: 2px solid var(--border); border-top-color: var(--teal); border-radius: 50%; animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn-loading { position: relative; pointer-events: none; }
.btn-loading::after { content: ''; position: absolute; right: 0.75rem; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; border: 2px solid rgba(255,255,255,0.4); border-top-color: var(--white); border-radius: 50%; animation: spin 0.7s linear infinite; }

/* ── MFA badge ─────────────────────────────────────────────── */
.mfa-badge { display: inline-flex; align-items: center; gap: 0.25rem; font-family: 'Space Mono', monospace; font-size: 0.58rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.mfa-badge.on  { color: var(--rag-green); }
.mfa-badge.off { color: var(--text-muted); }

/* ── Audit log ─────────────────────────────────────────────── */
.audit-action { font-family: 'Space Mono', monospace; font-size: 0.65rem; background: var(--light); padding: 0.2rem 0.5rem; border-radius: var(--radius-sm); color: var(--navy); font-weight: 700; }

/* ── Colour picker ─────────────────────────────────────────── */
.colour-row { display: flex; align-items: center; gap: 0.75rem; }
.colour-preview { width: 36px; height: 36px; border-radius: var(--radius); border: 1.5px solid var(--border); flex-shrink: 0; cursor: pointer; }
.colour-row input[type="color"] { width: 0; height: 0; padding: 0; border: none; opacity: 0; position: absolute; }
.colour-row .form-control { font-family: 'Space Mono', monospace; font-size: 0.875rem; max-width: 110px; }

/* ── Settings grid ─────────────────────────────────────────── */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }

/* ── Utilities ─────────────────────────────────────────────── */
.text-muted   { color: var(--text-muted) !important; }
.text-navy    { color: var(--navy) !important; }
.text-teal    { color: var(--teal) !important; }
.text-amber   { color: var(--amber) !important; }
.text-danger  { color: var(--rag-red) !important; }
.text-success { color: var(--rag-green) !important; }
.text-sm  { font-size: 0.8125rem; }
.text-xs  { font-size: 0.75rem; }
.text-right  { text-align: right; }
.text-center { text-align: center; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.mono { font-family: 'Space Mono', monospace; font-size: 0.65rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--amber); }
.d-flex { display: flex; }
.align-center { align-items: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.mt-1 { margin-top: 0.5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; } .mb-2 { margin-bottom: 1rem; } .mb-3 { margin-bottom: 1.5rem; }
.ms-auto { margin-left: auto; }
.w-100 { width: 100%; }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .sidebar-toggle { display: flex; }
  .page-content { padding: 1.25rem; }
  .form-row, .form-row-3 { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .settings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 1.75rem 1.25rem; }
}
