  :root {
    --bg: #f5f7fb;
    --panel: #ffffff;
    --border: #e3e8f0;
    --text: #1f2937;
    --muted: #6b7280;
    --primary: #2f5bea;
    --primary-soft: #e8eefe;
    --side: #111827;
    --side-text: #cbd5e1;
    --free: #0f8a5f;
    --free-soft: #e3f6ee;
    --paid: #b45309;
    --paid-soft: #fdf1e0;
    --ok: #0f8a5f;
    --warn: #b45309;
    --ng: #b91c1c;
    --radius: 10px;
  }
  * { box-sizing: border-box; }
  html, body { margin: 0; height: 100%; }
  body {
    font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    font-size: 14px;
    line-height: 1.6;
    display: flex;
  }

  /* ---------- Sidebar ---------- */
  .sidebar {
    width: 248px;
    flex-shrink: 0;
    background: var(--side);
    color: var(--side-text);
    min-height: 100vh;
    padding: 20px 14px;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
  }
  .brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 20px; }
  .brand-mark {
    width: 32px; height: 32px; border-radius: 8px;
    background: linear-gradient(135deg, #3b82f6, #1e40af);
    display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 15px;
  }
  .brand-name { color: #fff; font-weight: 700; font-size: 15px; letter-spacing: .02em; }
  .brand-sub { font-size: 11px; color: #94a3b8; }
  .nav-label { font-size: 11px; color: #64748b; padding: 12px 10px 6px; letter-spacing: .08em; }
  .nav a {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    color: var(--side-text); text-decoration: none;
    padding: 9px 10px; border-radius: 8px; margin-bottom: 2px; font-size: 13.5px;
  }
  .nav a:hover { background: #1f2937; color: #fff; }
  .nav .static {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    padding: 9px 10px; font-size: 13.5px; color: #64748b;
  }
  /* active state (set by React state) */
  .nav a.active {
    background: #1e293b; color: #fff; box-shadow: inset 3px 0 0 #3b82f6;
  }
  .legend {
    margin-top: auto;
    border: 1px solid #1f2937; border-radius: 10px; padding: 12px; font-size: 12px; background: #0b1220;
  }
  .legend-title { color: #e2e8f0; font-weight: 600; margin-bottom: 8px; }
  .legend-row { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 8px; color: #94a3b8; }
  .legend-row:last-child { margin-bottom: 0; }

  /* ---------- Badges ---------- */
  .badge {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 11px; font-weight: 600; line-height: 1;
    padding: 4px 7px; border-radius: 999px; white-space: nowrap;
  }
  .badge-free { background: var(--free-soft); color: var(--free); border: 1px solid #b7e6d2; }
  .badge-paid { background: var(--paid-soft); color: var(--paid); border: 1px solid #f3d3a5; }
  .sidebar .badge-free { background: #0d2e24; color: #5ee0a8; border-color: #14532d; }
  .sidebar .badge-paid { background: #33220b; color: #fbbf63; border-color: #713f12; }
  .badge-sample { background: #fef3c7; color: #92400e; border: 1px solid #fcd34d; }
  .status { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
  .st-ok { background: var(--free-soft); color: var(--ok); }
  .st-none { background: #f1f5f9; color: var(--muted); }
  .st-revoked { background: #fdecec; color: var(--ng); }
  .st-warn { background: var(--paid-soft); color: var(--warn); }
  .st-info { background: var(--primary-soft); color: var(--primary); }

  /* ---------- Main ---------- */
  .main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
  .topbar {
    height: 56px; background: var(--panel); border-bottom: 1px solid var(--border);
    display: flex; align-items: center; justify-content: space-between; padding: 0 28px;
  }
  .org { display: flex; align-items: center; gap: 10px; font-weight: 600; }
  .org small { color: var(--muted); font-weight: 400; }
  .mock-note { font-size: 12px; color: var(--muted); }
  .avatar {
    width: 30px; height: 30px; border-radius: 50%; background: var(--primary-soft); color: var(--primary);
    display: grid; place-items: center; font-weight: 700; font-size: 12px;
  }
  .top-right { display: flex; align-items: center; gap: 16px; }
  .content { padding: 28px; max-width: 1180px; width: 100%; }

  /* Screen switching is done by React state: only the current screen is rendered. */
  .screen { display: block; }

  .page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
  .page-head h1 { font-size: 22px; margin: 0 0 4px; display: flex; align-items: center; gap: 10px; }
  .page-head p { margin: 0; color: var(--muted); }
  .btn {
    display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 8px;
    font-size: 13px; font-weight: 600; border: 1px solid var(--border); background: var(--panel); color: var(--text);
    white-space: nowrap;
  }
  .btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
  .btn-disabled { background: #f1f5f9; color: #94a3b8; border-color: var(--border); }
  .btn-danger { background: var(--ng); border-color: var(--ng); color: #fff; }
  .btn-danger-lg { font-size: 16px; padding: 14px 22px; border-radius: 10px; box-shadow: 0 0 0 4px #fdecec; }
  .btn-row { display: flex; gap: 8px; }

  .card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
  .card + .card { margin-top: 16px; }
  .card h2 { font-size: 15px; margin: 0 0 14px; display: flex; align-items: center; gap: 8px; }
  .grid { display: grid; gap: 16px; }
  .grid + .card, .card + .grid, .grid + .grid { margin-top: 16px; }
  .g4 { grid-template-columns: repeat(4, 1fr); }
  .g3 { grid-template-columns: repeat(3, 1fr); }
  .g2 { grid-template-columns: repeat(2, 1fr); }

  .notice {
    display: flex; gap: 10px; align-items: flex-start;
    background: #eef4ff; border: 1px solid #c7d7fe; color: #1e3a8a;
    border-radius: var(--radius); padding: 12px 14px; margin-bottom: 16px; font-size: 13px;
  }
  .notice-sample { background: #fffbeb; border-color: #fcd34d; color: #92400e; font-weight: 600; }
  .notice-paid { background: var(--paid-soft); border-color: #f3d3a5; color: #7c3a06; }
  .notice .ico { font-weight: 700; }

  .stat { padding: 16px 18px; }
  .stat-label { color: var(--muted); font-size: 12px; }
  .stat-value { font-size: 26px; font-weight: 700; margin-top: 2px; }
  .stat-sub { font-size: 12px; color: var(--muted); }

  /* Table */
  .table { width: 100%; border-collapse: collapse; font-size: 13px; }
  .table th {
    text-align: left; font-weight: 600; color: var(--muted); font-size: 12px;
    padding: 10px 12px; border-bottom: 1px solid var(--border); background: #f8fafc;
  }
  .table td { padding: 11px 12px; border-bottom: 1px solid var(--border); }
  .table tr:last-child td { border-bottom: none; }
  .table .dim { color: var(--muted); }
  .table .num { text-align: right; font-variant-numeric: tabular-nums; }
  .table .mono { font-variant-numeric: tabular-nums; white-space: nowrap; }
  .target-yes { color: var(--ok); font-weight: 600; }
  .target-no { color: #94a3b8; }
  .toolbar { display: flex; gap: 8px; margin-bottom: 12px; align-items: center; flex-wrap: wrap; }
  .fake-input {
    border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; background: #fff;
    color: #94a3b8; font-size: 13px; min-width: 0;
  }
  .fake-input.filled { color: var(--text); }
  .chip { border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px; font-size: 12px; background: #fff; }
  .chip.on { background: var(--primary-soft); border-color: #c7d7fe; color: var(--primary); font-weight: 600; }
  .chip.ok { background: var(--free-soft); border-color: #b7e6d2; color: var(--ok); font-weight: 600; }
  .chip.ok::before { content: "✓ "; }

  /* Form-like mock controls */
  .field { margin-bottom: 16px; }
  .field:last-child { margin-bottom: 0; }
  .field-label { font-size: 12px; font-weight: 600; color: #374151; margin-bottom: 6px; display: flex; gap: 8px; align-items: center; }
  .field-help { font-size: 12px; color: var(--muted); margin-top: 4px; }
  .select { display: flex; justify-content: space-between; align-items: center; }
  .select::after { content: "▾"; color: var(--muted); margin-left: 8px; }
  .lock-field { background: #f8fafc; color: var(--text); display: flex; justify-content: space-between; align-items: center; }
  .radio-row { display: flex; gap: 8px; flex-wrap: wrap; }
  .radio { display: flex; align-items: center; gap: 8px; border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; font-size: 13px; background: #fff; }
  .radio .dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #cbd5e1; }
  .radio.on { border-color: var(--primary); background: var(--primary-soft); }
  .radio.on .dot { border-color: var(--primary); box-shadow: inset 0 0 0 3px #fff; background: var(--primary); }
  .toggle-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border); }
  .toggle-row:last-child { border-bottom: none; }
  .toggle { width: 36px; height: 20px; border-radius: 999px; background: #cbd5e1; position: relative; flex-shrink: 0; }
  .toggle::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; }
  .toggle.on { background: var(--primary); }
  .toggle.on::after { left: 18px; }
  .toggle.locked { background: #22c55e; opacity: .6; }
  .toggle.locked::after { left: 18px; }
  .kv { display: grid; grid-template-columns: 140px 1fr; gap: 8px 12px; font-size: 13px; }
  .kv dt { color: var(--muted); }
  .kv dd { margin: 0; }
  .file-chip {
    display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--border); border-radius: 8px;
    padding: 6px 10px; background: #f8fafc; font-size: 13px;
  }
  .file-chip .ext { font-size: 10px; font-weight: 700; color: #fff; background: var(--ng); border-radius: 3px; padding: 1px 4px; }

  /* Gate / warning card */
  .gate-card { border: 2px solid #f3d3a5; background: #fffaf2; display: flex; gap: 16px; align-items: center; justify-content: space-between; }
  .gate-card h2 { margin-bottom: 4px; color: #7c3a06; }
  .gate-card p { margin: 0; font-size: 13px; color: #7c3a06; }
  .gate-state { text-align: center; flex-shrink: 0; }
  .gate-state .status { font-size: 15px; padding: 6px 18px; }
  .gate-state small { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; }

  /* Stop card */
  .stop-card { border: 2px solid #f5b5b5; background: #fff7f7; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
  .stop-card h2 { color: #7f1d1d; margin-bottom: 4px; }
  .stop-card p { margin: 0; font-size: 13px; color: #991b1b; }

  /* Learning page preview (shown to employees after click) */
  .preview-frame { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: #f8fafc; }
  .preview-bar { background: #e5e9f0; padding: 6px 12px; font-size: 11px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
  .preview-bar i { width: 8px; height: 8px; border-radius: 50%; background: #cbd5e1; display: inline-block; }
  .preview-body { padding: 22px 26px; background: #fff; }
  .preview-body .big { font-size: 22px; font-weight: 800; color: var(--primary); margin: 0 0 6px; }
  .preview-body p { margin: 0 0 12px; font-size: 13px; }
  .preview-body ul { margin: 0; padding-left: 18px; font-size: 13px; }
  .preview-body li { margin-bottom: 4px; }

  /* Bars */
  .bar-row { display: grid; grid-template-columns: 110px 1fr 56px; align-items: center; gap: 12px; margin-bottom: 12px; }
  .bar-row:last-child { margin-bottom: 0; }
  .bar-track { height: 14px; background: #eef2f7; border-radius: 999px; overflow: hidden; }
  .bar { height: 100%; border-radius: 999px; }
  .bar-open { background: #60a5fa; }
  .bar-click { background: #f59e0b; }
  .bar-report { background: #10b981; }
  .bar-val { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
  .vchart { display: flex; align-items: flex-end; gap: 18px; height: 180px; padding: 0 8px; border-bottom: 1px solid var(--border); }
  .vgroup { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 4px; height: 100%; }
  .vbar { width: 16px; border-radius: 4px 4px 0 0; }
  .vlabels { display: flex; gap: 18px; padding: 6px 8px 0; }
  .vlabels span { flex: 1; text-align: center; font-size: 12px; color: var(--muted); }
  .chart-legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); margin-top: 12px; }
  .chart-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 4px; vertical-align: -1px; }
  .mini-bar { display: inline-block; height: 8px; border-radius: 999px; vertical-align: 1px; margin-right: 6px; }

  /* Report document */
  .doc-wrap { background: #e5e9f0; border-radius: var(--radius); padding: 28px; }
  .doc {
    background: #fff; max-width: 760px; margin: 0 auto; padding: 48px 56px;
    box-shadow: 0 6px 24px rgba(15,23,42,.12); border-radius: 4px; position: relative;
    font-family: "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif JP", serif;
  }
  .doc .sans { font-family: "Hiragino Sans", "Noto Sans JP", system-ui, sans-serif; }
  .watermark {
    position: absolute; top: 46%; left: 50%; transform: translate(-50%, -50%) rotate(-24deg);
    font-size: 88px; font-weight: 800; color: rgba(180, 83, 9, .07); pointer-events: none; white-space: nowrap;
    font-family: "Hiragino Sans", system-ui, sans-serif;
  }
  .doc-head { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); border-bottom: 2px solid #111827; padding-bottom: 10px; margin-bottom: 28px; }
  .doc h3 { font-size: 22px; text-align: center; margin: 0 0 6px; }
  .doc .doc-sub { text-align: center; color: var(--muted); font-size: 13px; margin-bottom: 32px; }
  .doc h4 { font-size: 15px; border-left: 4px solid #1e40af; padding-left: 10px; margin: 28px 0 12px; }
  .doc p { font-size: 14px; margin: 0 0 10px; }
  .doc table { width: 100%; border-collapse: collapse; font-size: 13px; }
  .doc th, .doc td { border: 1px solid #cbd5e1; padding: 8px 10px; text-align: left; }
  .doc th { background: #f1f5f9; }
  .doc .num { text-align: right; font-variant-numeric: tabular-nums; }
  .doc .up { color: var(--ok); font-weight: 600; }
  .sample-tag { font-size: 10px; color: #92400e; background: #fef3c7; border: 1px solid #fcd34d; border-radius: 4px; padding: 1px 4px; margin-left: 4px; font-family: system-ui, sans-serif; vertical-align: 1px; }
  .doc ul, .doc ol { margin: 0; padding-left: 20px; font-size: 14px; }
  .doc li { margin-bottom: 4px; }
  .doc-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 4px; }
  .doc-kpi { border: 1px solid #cbd5e1; border-radius: 4px; padding: 10px; text-align: center; }
  .doc-kpi b { display: block; font-size: 20px; }
  .doc-kpi span { font-size: 11px; color: var(--muted); }
  .doc-foot { margin-top: 36px; border-top: 1px solid #cbd5e1; padding-top: 10px; font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; }

  /* AI draft flow */
  .badge-ai { background: #f3e8ff; color: #6d28d9; border: 1px solid #ddd6fe; }
  .ai-prompt { display: flex; gap: 10px; align-items: center; }
  .ai-prompt .fake-input { flex: 1; padding: 11px 14px; font-size: 14px; }
  .ai-prompt .btn { padding: 11px 16px; text-decoration: none; }
  .banner-stop {
    display: flex; gap: 12px; align-items: center;
    background: #fdecec; border: 2px solid #f5b5b5; color: #7f1d1d;
    border-radius: var(--radius); padding: 14px 16px; margin-bottom: 16px; font-size: 15px; font-weight: 700;
  }
  .banner-stop .ico {
    width: 26px; height: 26px; border-radius: 50%; background: var(--ng); color: #fff;
    display: grid; place-items: center; font-size: 14px; flex-shrink: 0;
  }
  .banner-stop small { display: block; font-weight: 400; font-size: 12px; color: #991b1b; }
  .ai-card { display: flex; flex-direction: column; }
  .ai-card .ai-body { flex: 1; font-size: 13px; }
  .ai-card .ai-body p { margin: 0 0 8px; }
  .ai-card .ai-body ul { margin: 0; padding-left: 18px; }
  .ai-card .btn-row { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }
  .tentative { display: inline-block; margin-left: 3px; padding: 0 4px; font-size: 10px; font-weight: 600; line-height: 16px; border: 1px dashed currentColor; border-radius: 3px; opacity: .85; }
  .badge-manual { background: #f1f5f9; color: #475569; border: 1px solid #cbd5e1; }
  .manual-card { background: #f8fafc; }
  .pack-slot { flex: 1; display: flex; flex-direction: column; gap: 8px; }
  .pack-slot .slot-label { font-size: 12px; font-weight: 600; color: var(--muted); }
  .pack-slot .slot-box { flex: 1; min-height: 120px; border: 2px dashed var(--border); border-radius: 8px; background: #fff; }
  .quote { background: #f8fafc; border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; }
  .step-final { margin-top: 16px; border: 2px solid var(--primary); background: var(--primary-soft); }
  .step-final .step-no { font-size: 12px; font-weight: 700; color: var(--primary); letter-spacing: .04em; }
  .step-final .step-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; }

  /* Import: fake checkboxes */
  .check-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
  .check-row:last-child { border-bottom: none; }
  .check { display: inline-flex; align-items: center; gap: 8px; }
  .check .box { width: 16px; height: 16px; border: 2px solid #cbd5e1; border-radius: 4px; background: #fff; display: inline-grid; place-items: center; font-size: 11px; line-height: 1; color: #fff; flex-shrink: 0; }
  .check.on .box { background: var(--primary); border-color: var(--primary); }
  .check.on .box::after { content: "✓"; }
  .check.locked .box { opacity: .55; }
  .link-hint { font-size: 12px; font-weight: 600; color: var(--primary); text-decoration: none; }

  .footer-note { margin-top: 24px; font-size: 12px; color: var(--muted); text-align: center; }

/* Mamori: calm, human-centered practice. */
:root { --bg:#f5f5ef; --border:#dfe5dc; --text:#243c33; --muted:#66766c; --primary:#245c47; --primary-soft:#e8efe2; --side:#153f35; --radius:14px; }
body { display:block; }
#root { min-height:100vh; }
body:has(.sidebar) #root { display:flex !important; }
.sidebar { width:280px; background:#153f35; overflow-y:auto; }
.brand { padding:8px 4px 28px; }
.brand-mark { width:42px; height:42px; background:none; border-radius:12px; }
.brand-name { font-size:18px; letter-spacing:-.04em; }
.brand-sub { color:#b6cbbd; font-size:10px; }
.nav-label { color:#b2c4b7; font-size:10px; letter-spacing:.15em; }
.nav a { font-size:12px; padding:11px 10px; }
.nav a.active { background:#2b5548; box-shadow:inset 3px 0 #d6e5b5; }
.nav a:hover { background:#244e40; }
.sidebar .badge-free { background:#264d3f; color:#d5e7b9; border-color:#466658; font-size:9px; }
.sidebar .badge-paid { background:#514936; color:#f5d8aa; border-color:#746044; font-size:9px; }
.legend { background:#12382f; border-color:#416052; margin-top:30px; }
.legend-row { color:#bdcdbf; font-size:10px; }
.legend-title { color:#e4ead8; }
.topbar { height:72px; background:#fafbf6; }
.back-home { color:var(--primary); font-size:12px; text-decoration:none; }
.content { padding:34px; max-width:1440px; }
.page-head h1 { font-size:25px; letter-spacing:-.04em; }
.card { box-shadow:0 3px 12px #183a2614; }
.stat { border-top:3px solid #b6c997; padding:22px; }
.stat-value { font-size:32px; letter-spacing:-.04em; }
.btn { text-decoration:none; }
.notice:not(.notice-sample):not(.notice-paid) { background:#edf2e8; color:#31583f; border-color:#cbd9bd; }
.table th { background:#f1f4ec; }
:focus-visible { outline:3px solid #b28341; outline-offset:4px; }
.landing { background:#f8f8f0; color:#183e31; }
.landing a { color:inherit; text-decoration:none; }
.lp-header { max-width:1320px; margin:auto; height:104px; padding:0 48px; display:flex; align-items:center; justify-content:space-between; }
.lp-brand { display:flex; align-items:center; gap:12px; font-size:23px; font-weight:750; letter-spacing:-.05em; }
.lp-brand small { display:block; font-size:10px; font-weight:400; letter-spacing:.07em; margin-top:1px; }
.lp-header nav { display:flex; gap:32px; align-items:center; font-size:12px; }
.lp-nav-cta { border:1px solid #bbc7b5; border-radius:6px; padding:11px 18px; }
.lp-hero { max-width:1320px; margin:auto; padding:64px 48px 80px; display:grid; grid-template-columns:1.1fr 1fr; gap:24px; align-items:center; }
.eyebrow { font-size:10px; font-weight:650; letter-spacing:.18em; display:flex; align-items:center; gap:8px; }
.eyebrow>span { width:6px; height:6px; background:#658957; border-radius:50%; }
.lp-hero h1 { font-size:clamp(40px,4.6vw,64px); line-height:1.4; letter-spacing:-.065em; margin:26px 0 22px; font-weight:750; }
.lp-hero h1>span { color:#64874d; }
.hero-lead { font-size:21px; line-height:1.8; letter-spacing:.03em; }
.hero-description { font-size:14px; color:#69776a; line-height:2; margin:24px 0 30px; }
.hero-actions { display:flex; align-items:center; gap:24px; flex-wrap:wrap; }
.landing .lp-button { display:inline-flex; justify-content:space-between; align-items:center; gap:30px; background:#204f3d; color:#fff; border-radius:6px; padding:16px 24px; font-size:13px; box-shadow:0 4px 0 #153d2f15; transition:background .2s,transform .2s; }
.landing .lp-button:hover { background:#37684c; transform:translateY(-2px); }
.text-link { font-size:12px; border-bottom:1px solid #a8b79b; padding:6px 0; }
.hero-caption { font-size:10px; color:#71806d; margin-top:18px; }
.hero-art { min-height:490px; position:relative; display:grid; place-items:center; overflow:hidden; background:radial-gradient(ellipse,#e0e7cc 0%,#eef1df 45%,transparent 72%); }
.orbit { position:absolute; width:360px; height:360px; border:1px solid #ccd6b9; border-radius:50%; }
.orbit-two { width:450px; height:450px; border-style:dashed; opacity:.7; }
.gate-emblem { transform:rotate(-7deg); box-shadow:18px 24px 40px #244c3526; border-radius:44px; width:210px; height:210px; }
.gate-emblem img { width:100%; }
.art-label { position:absolute; top:16px; font-size:11px; letter-spacing:.18em; color:#6e8062; }
.floating-note { position:absolute; display:flex; align-items:center; gap:12px; background:#fffffff2; border:1px solid #e1e7d6; padding:17px 22px; border-radius:10px; box-shadow:0 8px 28px #1b3a2510; }
.floating-note small { display:block; font-size:9px; letter-spacing:.14em; color:#6f8069; }
.floating-note strong { font-size:13px; font-weight:600; }
.note-icon { background:#edf1df; color:#3c6b46; width:32px; height:32px; display:grid; place-items:center; border-radius:50%; }
.note-one { top:94px; right:0; transform:rotate(3deg); }
.note-two { bottom:88px; left:0; transform:rotate(-3deg); }
.art-bottom { position:absolute; bottom:14px; font-size:11px; letter-spacing:.09em; }
.art-bottom span { margin-left:18px; }
.principles-strip { border-top:1px solid #dce1d1; border-bottom:1px solid #dce1d1; display:flex; justify-content:center; gap:40px; padding:23px 32px; font-size:11px; flex-wrap:wrap; }
.principles-strip span:not(:first-child)::before { content:'✓'; color:#6b8650; margin-right:8px; }
.lp-approach,.lp-flow,.lp-deploy,.lp-demo { max-width:1224px; margin:auto; padding:88px 0; }
.approach-grid { display:grid; grid-template-columns:1fr 1fr; gap:70px; margin-top:24px; }
.landing h2 { font-size:32px; letter-spacing:-.045em; line-height:1.6; margin:0 0 20px; }
.approach-grid h2 { font-size:38px; }
.approach-grid em { font-style:normal; color:#6b8650; }
.approach-grid p,.lp-demo p { font-size:14px; color:#69776a; line-height:2.1; margin:0 0 20px; }
.lp-flow { border-top:1px solid #dce1d1; }
.section-head { display:flex; justify-content:space-between; align-items:center; gap:20px; }
.section-head .eyebrow { margin-bottom:16px; }
.section-head>span { font-size:10px; color:#758266; letter-spacing:.12em; }
.lp-deploy { border-top:1px solid #dce1d1; }
.deploy-lead { font-size:14px; color:#69776a; line-height:2.1; margin:0 0 8px; max-width:720px; }
.deploy-grid { display:grid; grid-template-columns:repeat(2,1fr); gap:20px; margin-top:20px; }
.deploy-grid .flow-card:hover { transform:none; }
.flow-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:20px; margin-top:20px; }
.flow-card { background:#fff; border:1px solid #dce1d1; border-radius:10px; padding:28px; transition:transform .2s; }
.flow-card:hover { transform:translateY(-4px); }
.flow-top { display:flex; justify-content:space-between; color:#71865a; margin-bottom:36px; font-family:Georgia,serif; font-size:28px; }
.flow-card small { color:#72845d; font-size:11px; }
.flow-card h3 { font-size:18px; letter-spacing:-.04em; margin:8px 0 16px; }
.flow-card p { font-size:13px; color:#69776a; line-height:1.9; }
.flow-link { display:block; font-size:11px; margin-top:24px; }
.lp-demo { display:grid; grid-template-columns:1fr 1fr; gap:80px; align-items:center; padding-top:30px; }
.lp-demo .eyebrow { margin-bottom:20px; }
.mini-dashboard { background:#fff; border:1px solid #dce1d1; padding:28px; border-radius:14px; box-shadow:0 15px 40px #28452b09; transform:rotate(-2deg); }
.mini-head { display:flex; justify-content:space-between; font-size:13px; font-weight:600; }
.sample-label { color:#778666; font-size:10px; font-weight:400; }
.mini-dashboard p { font-size:11px; margin:8px 0 20px; }
.mini-metrics { display:flex; gap:60px; }
.mini-metrics small { display:block; font-size:11px; color:#69776a; }
.mini-metrics strong { font-size:40px; font-weight:500; }
.mini-metrics strong span { font-size:15px; margin-left:5px; }
.mini-bars { height:100px; display:flex; align-items:end; gap:14px; border-bottom:1px solid #dce1d1; margin:16px 0; }
.mini-bars i { flex:1; background:#c5d3ac; border-radius:4px 4px 0 0; }
.mini-bars i:last-child { background:#36634a; }
.mini-dashboard>small { font-size:9px; color:#71806d; }
.lp-start { background:#e9eedc; text-align:center; padding:64px 24px; }
.lp-start h2 { margin:18px 0 12px; }
.lp-start>p { font-size:13px; color:#69776a; margin-bottom:26px; }
.lp-start .hero-caption { font-size:10px; margin-bottom:0; }
.lp-footer { max-width:1320px; margin:auto; display:flex; align-items:center; justify-content:space-between; padding:32px 48px; gap:20px; }
.lp-footer .lp-brand { font-size:16px; }
.lp-footer>span,.lp-footer>a:last-child { font-size:10px; color:#69776a; }
@media(min-width:761px) and (max-width:1320px) { .lp-approach,.lp-flow,.lp-deploy,.lp-demo { margin:0 48px; } }
@media(max-width:1000px) { .sidebar { width:235px; } .sidebar .badge { display:none; } .g4 { grid-template-columns:repeat(2,minmax(0,1fr)); } .g2 { grid-template-columns:1fr; } .topbar { padding:0 18px; } .mock-note { display:none; } .lp-header nav { gap:16px; } .hero-actions { gap:12px; } .lp-demo { gap:28px; } .principles-strip { gap:16px; } }
@media(max-width:760px) { .lp-header { height:86px; padding:0 22px; } .lp-header nav>a:not(:last-child) { display:none; } .lp-brand { font-size:19px; } .lp-brand small { font-size:9px; } .lp-nav-cta { padding:9px 12px; font-size:11px; } .lp-hero { grid-template-columns:1fr; padding:36px 24px 40px; } .lp-hero h1 { font-size:clamp(29px,9vw,38px); } .hero-art { min-height:420px; } .hero-lead { font-size:19px; } .principles-strip { justify-content:flex-start; gap:14px 20px; padding:22px 24px; } .principles-strip span:first-child { width:100%; } .lp-approach,.lp-flow,.lp-deploy,.lp-demo { padding:52px 24px; } .approach-grid,.lp-demo { grid-template-columns:1fr; gap:24px; } .approach-grid h2 { font-size:32px; } .landing h2 { font-size:26px; } .flow-grid,.deploy-grid { grid-template-columns:1fr; } .flow-top { margin-bottom:18px; } .section-head>span { display:none; } .lp-footer { padding:28px 24px; flex-wrap:wrap; } .lp-footer>span { order:3; width:100%; } body:has(.sidebar) #root { flex-direction:column; } .sidebar { width:100%; height:auto; min-height:0; position:static; padding:12px 16px; } .sidebar .brand { padding:0 0 12px; } .sidebar .brand-sub,.sidebar .legend,.sidebar .nav-label,.sidebar .nav .static { display:none; } .sidebar .nav { display:flex; overflow-x:auto; gap:6px; padding-bottom:6px; } .sidebar .nav a { flex-shrink:0; white-space:nowrap; padding:8px 12px; } .content { padding:22px 16px; } .topbar { height:60px; } .org { display:block; font-size:12px; } .org small { display:block; } .avatar { display:none; } .page-head { flex-direction:column; } .page-head h1 { font-size:22px; flex-wrap:wrap; } .g3,.g2 { grid-template-columns:1fr; } .card { padding:16px; overflow-x:auto; } .table { min-width:560px; } .btn-row { flex-wrap:wrap; } .doc { padding:24px; min-width:540px; } .doc-wrap { overflow-x:auto; } .ai-prompt { flex-wrap:wrap; } .step-final .step-row { flex-wrap:wrap; } }
@media(prefers-reduced-motion:reduce) { .landing * { transition:none!important; scroll-behavior:auto!important; } }

/* Production UI: the landing page's forest, paper and sage palette. */
:root {
  --bg: #f5f5ef;
  --panel: #fff;
  --text: #243c33;
  --muted: #596d61;
  --border: #d8e1d6;
  --primary: #245c47;
  --primary-soft: #edf2e8;
  --ok: #246148;
  --free-soft: #e8f2ea;
  --radius: 16px;
  --shadow: 0 4px 18px #153f3508;
}
body { line-height: 1.75; }
a { color: var(--primary); text-underline-offset: 4px; }
h1, h2 { line-height: 1.5; text-wrap: pretty; }
p { margin: 0; }
.app-shell { width: 100%; min-width: 0; }
.sidebar { width: 248px; padding: 0; position: static; height: auto; overflow: visible; align-self: stretch; }
.sidebar-inner { position: sticky; top: 0; max-height: 100vh; overflow-y: auto; padding: 28px 16px; }
.sidebar .badge { display: none; }
.sidebar .brand { padding: 0 4px 30px; }
.sidebar .brand-name { font-size: 19px; }
.nav a { min-height: 44px; font-size: 13px; margin-bottom: 5px; }
.main { min-width: 0; }
.topbar { min-height: 88px; height: auto; padding: 16px 32px; gap: 24px; }
.org { font-size: 13px; flex-shrink: 0; max-width: 30%; overflow-wrap: anywhere; }
.top-right { flex-wrap: wrap; justify-content: flex-end; gap: 6px 16px; font-size: 12px; min-width: 0; }
.account { overflow-wrap: anywhere; }
.top-right form { flex-shrink: 0; }
.mock-note { flex-basis: 100%; text-align: right; font-size: 11px; }
.content { padding: 36px 32px 64px; max-width: 1440px; margin: 0 auto; }
.page-head { margin-bottom: 28px; padding-bottom: 20px; border-bottom: 1px solid var(--border); }
.page-head h1 { font-size: 26px; letter-spacing: -.035em; margin: 0; }
.stack > * + * { margin-top: 20px; }
/* A hidden input renders nothing; the next element should not get a gap as if it followed something. */
.stack > input[type="hidden"]:first-child + * { margin-top: 0; }
.card { padding: 24px; box-shadow: var(--shadow); overflow: visible; min-width: 0; }
.card h2 { font-size: 16px; margin: 0 0 18px; flex-wrap: wrap; }
.card.stack h2 { margin-bottom: 0; }
.card + .card { margin-top: 20px; }
.grid { gap: 20px; }
.grid > .card + .card { margin-top: 0; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { border-top: 3px solid #b6c997; padding: 20px; }
.stat-value { font-size: clamp(24px, 2.8vw, 36px); line-height: 1.4; margin: 8px 0; }
.stat-label, .stat-sub { color: var(--muted); font-size: 12px; }
.btn { justify-content: center; min-height: 42px; padding: 9px 16px; line-height: 1.5; text-decoration: none; border-radius: 9px; }
button.btn { font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.btn:hover { background: #f0f4ec; border-color: #91a88e; }
.btn-primary:hover { background: #153f35; border-color: #153f35; }
.btn-danger:hover { background: #922323; color: #fff; }
.btn:disabled { background: #edf0eb; border-color: var(--border); color: #647369; cursor: not-allowed; }
.btn-row, .toolbar { flex-wrap: wrap; gap: 10px; }
.toolbar { margin-bottom: 18px; }
.toolbar h2 { margin: 0 auto 0 0; }
.chip { display: inline-flex; align-items: center; min-height: 40px; text-decoration: none; }
.field { display: block; min-width: 0; margin-bottom: 0; }
.field-label { display: block; font-size: 13px; color: var(--text); margin-bottom: 7px; }
.field-help { font-size: 12px; color: var(--muted); line-height: 1.8; margin-top: 8px; overflow-wrap: anywhere; }
.input, .textarea { display: block; width: 100%; min-width: 0; min-height: 46px; font: inherit; padding: 10px 12px; border: 1px solid #b9c9bb; border-radius: 9px; background: #fff; color: var(--text); }
.input::placeholder, .textarea::placeholder { color: #68756c; opacity: 1; }
.textarea { min-height: 180px; resize: vertical; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; line-height: 1.8; }
label.radio-row { display: flex; flex-wrap: nowrap; align-items: flex-start; gap: 10px; padding: 10px 12px; min-height: 44px; border: 1px solid var(--border); border-radius: 9px; background: #fafbf7; cursor: pointer; }
label.radio-row + label.radio-row { margin-top: 8px; }
.tag { flex-shrink: 0; display: inline-block; font-size: 11px; font-weight: 600; line-height: 1.5; padding: 2px 8px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); border: 1px solid #c3d4bb; white-space: nowrap; }
label.radio-row:has(:checked) { background: var(--primary-soft); border-color: #8da782; }
input[type="checkbox"], input[type="radio"] { flex-shrink: 0; width: 17px; height: 17px; margin: 4px 0 0; accent-color: var(--primary); }
.notice { font-size: 13px; line-height: 1.8; padding: 16px 18px; margin-bottom: 0; font-weight: 400; }
.notice-success { border-left: 4px solid #63886c; }
.notice-sample, .notice-paid { background: #fff8ed; border-color: #e2c9a1; color: #775022; }
.errors, .notice-error, .notice.notice-error:not(.notice-sample):not(.notice-paid) { background: #fff2ef; color: #922d27; border: 1px solid #e6bdb6; border-radius: 10px; padding: 14px 18px; font-weight: 400; }
ul.errors { padding-left: 30px; }
.notice-error .errors { padding-top: 0; padding-bottom: 0; border: 0; background: none; }
.table-scroll { width: 100%; overflow-x: auto; border: 1px solid var(--border); border-radius: 10px; scrollbar-color: #90a58b #f0f3eb; scrollbar-width: thin; }
.table { min-width: 100%; width: 100%; font-size: 13px; }
.table th { padding: 12px 14px; white-space: nowrap; color: var(--muted); }
.table td { padding: 14px; min-width: 90px; vertical-align: top; }
.table td:first-child { min-width: 125px; }
.table td[colspan] { text-align: center; padding: 30px 18px; background: #fafbf7; color: var(--muted); }
#exclusions > form, #exclusions > .notice { margin-top: 20px; }
.toolbar + .field-help { margin-top: 0; margin-bottom: 16px; }
.table tr:hover td { background: #fafbf7; }
.table .field-help { min-width: 160px; }
.table td .btn { min-width: max-content; }
.kv { grid-template-columns: 130px minmax(0, 1fr); padding: 14px 16px; border-radius: 9px; background: #f3f5ef; }
.kv > div { overflow-wrap: anywhere; min-width: 0; }
.kv > div:first-child { color: var(--muted); }
.preview-text { white-space: pre-wrap; overflow-wrap: anywhere; font-family: inherit; margin: 0; line-height: 1.9; }
pre.preview-text, .quote { padding: 20px; border: 1px solid var(--border); border-radius: 10px; background: #fafbf7; }
.gate-card { background: #f3f5ea; border-color: #c8d4b5; gap: 24px; }
.gate-card h2, .gate-card p { color: var(--text); }
.gate-card p { font-size: 13px; }
.gate-state { min-width: 130px; }
.center { min-height: 100vh; width: 100%; display: grid; place-items: center; padding: 56px 24px; border-top: 6px solid #153f35; background: radial-gradient(ellipse at 50% 0, #e8eddd, transparent 65%), var(--bg); }
.narrow { width: 100%; max-width: 560px; }
.plain-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 36px; }
.plain-wordmark { font-size: 24px; font-weight: 750; letter-spacing: -.04em; color: #153f35; }
.plain-tagline { font-size: 12px; color: var(--muted); }
.narrow h1 { font-size: 27px; letter-spacing: -.035em; margin: 0 0 24px; }
.narrow > .card { padding: 28px; }
.qr { display: block; max-width: 100%; width: 200px; height: 200px; background: #fff; }
body:has(.learning) .narrow { max-width: 680px; }
body:has(.learning) .center { place-items: start center; }
.learning h1 { font-size: 32px; margin-bottom: 24px; }
.learning .card { padding: 28px 32px; box-shadow: none; }
.learning .learning-reassurance { background: #eaf0e2; border-color: #c7d5ba; border-top: 4px solid #9ab47f; }
.learning-reassurance p:first-child { font-size: 16px; font-weight: 600; line-height: 1.9; }
.learning p { line-height: 1.9; }
.clues { margin: 0; padding-left: 24px; }
.clues li { padding: 12px 0 12px 6px; line-height: 1.9; }
.clues li + li { border-top: 1px solid var(--border); }
.clues li::marker { color: #5d7b4e; }
:focus-visible { outline: 3px solid #966729; outline-offset: 3px; }
.sidebar :focus-visible { outline-color: #e7edc7; }
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }

/* Public pages (terms, privacy, help, contact): a readable document column with links to each other. */
.public { max-width: 760px; margin: 0 auto; padding: 24px 16px 48px; }
.public-head { margin-bottom: 24px; }
.lp-brand-mini { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: inherit; text-decoration: none; }
.public-doc { line-height: 1.8; }
.public-doc h2 { margin-top: 32px; font-size: 18px; }
.public-doc h3 { margin-top: 24px; font-size: 16px; }
.public-doc ol, .public-doc ul { padding-left: 24px; }
.public-doc .table { width: 100%; border-collapse: collapse; font-size: 13px; }
.public-doc .table th, .public-doc .table td { border: 1px solid var(--border); padding: 6px 8px; text-align: left; vertical-align: top; }
.faq dt { font-weight: 700; margin-top: 16px; }
.faq dd { margin: 4px 0 0; }
.steps li + li { margin-top: 8px; }
mark.legal-todo { background: #fef3c7; color: #92400e; padding: 0 2px; }
.public-links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 40px; padding-top: 16px; border-top: 1px solid var(--border); font-size: 13px; }
.inline-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline-form .input { width: auto; }
.codes { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.codes li { padding: 8px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff; font-size: 15px; letter-spacing: 0.04em; }
.survey fieldset { border: 0; padding: 0; margin: 0; }
.survey legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.survey label.radio { cursor: pointer; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 12px; border: 1px solid var(--border); border-radius: 9px; background: #fafbf7; }
.survey .radio-row { display: flex; flex-wrap: wrap; gap: 8px; }
.survey fieldset + fieldset { margin-top: 28px; }
.survey label.radio input { margin: 0; accent-color: var(--primary); }
.survey label.radio:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.table-scroll + .table-scroll { margin-top: 12px; }
/* Invitation links are long; let them wrap so the resend and revoke buttons stay in view. */
.table td.invite-link { word-break: break-all; min-width: 180px; max-width: 300px; font-size: 12px; }
.table td .inline-form { flex-wrap: nowrap; }
@media (max-width: 1100px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .topbar { padding: 16px 24px; }
}
@media (max-width: 760px) {
  .sidebar { padding: 18px 16px 8px; width: 100%; height: auto; min-height: 0; position: static; overflow: visible; }
  .sidebar-inner { position: static; max-height: none; overflow: visible; padding: 0; }
  .sidebar .brand { padding: 0 4px 18px; }
  .sidebar .brand-mark { width: 36px; height: 36px; }
  .sidebar .brand-name { font-size: 21px; }
  .sidebar .nav { margin: 0 -16px; padding: 0 16px 10px; scrollbar-width: thin; scrollbar-color: #9bb48a #244e40; }
  .sidebar .nav a { min-height: 42px; margin: 0; }
  .topbar { position: relative; display: block; min-height: 92px; padding: 14px 116px 14px 16px; }
  .org { max-width: none; font-size: 12px; }
  .top-right { display: block; font-size: 11px; }
  .account { display: block; margin-top: 4px; }
  .mock-note { display: none; }
  .top-right form { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); }
  .top-right .btn { padding: 9px 12px; font-size: 12px; }
  .content { padding: 26px 16px 40px; }
  .page-head { margin-bottom: 22px; padding-bottom: 18px; }
  .page-head h1 { font-size: 23px; display: block; }
  .card { padding: 20px 16px; overflow: visible; }
  .g2, .g3 { grid-template-columns: minmax(0, 1fr); }
  .g4, .g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .stat { padding: 18px; }
  .stat-value { font-size: 29px; }
  .g4 .stat, .g5 .stat { padding: 14px; }
  .g4 .stat-value, .g5 .stat-value { font-size: 24px; }
  .toolbar { align-items: stretch; }
  .toolbar h2 { flex-basis: 100%; margin-bottom: 4px; }
  .toolbar .btn { width: 100%; white-space: normal; }
  .btn { white-space: normal; text-align: center; height: auto; }
  .public-doc .table { min-width: 0; }
  .public-doc .table td, .public-doc .table td:first-child { min-width: 0; }
  .table { min-width: 480px; }
  .table:not(:has(th:nth-child(3))) { min-width: 100%; }
  .table-scroll { margin-top: 16px; }
  .input, .textarea { font-size: 16px; }
  .kv { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .gate-card { flex-direction: column; align-items: stretch; }
  .gate-state { align-items: flex-start; }
  .center { padding: 32px 16px 40px; }
  .plain-brand { margin-bottom: 28px; }
  .narrow h1, .learning h1 { font-size: 25px; }
  .narrow > .card, .learning .card { padding: 22px 20px; }
  .learning-reassurance p:first-child { font-size: 15px; }
  /* Phones: lay content out from the top. Centering in 100vh pushed short pages (ログインを続ける)
     halfway down, because mobile browsers count their own toolbars in 100vh. */
  .center { place-items: start center; padding-top: 24px; }
  /* Wrap the menu instead of a sideways strip whose last items are off screen with no hint. */
  .sidebar .nav { display: flex; flex-wrap: wrap; gap: 6px; overflow: visible; margin: 0; padding: 0 0 10px; }
  .sidebar .nav a { flex: 1 1 auto; justify-content: center; min-height: 44px; padding: 8px 12px; white-space: normal; text-align: center; line-height: 1.4; }
  .sidebar .nav a.active { box-shadow: inset 0 -3px #d6e5b5; }
  /* Tap targets: 44px or more. */
  .btn, .chip { min-height: 44px; }
  .lp-brand-mini { min-height: 44px; }
  /* Tables scroll inside .table-scroll; headers may wrap so their text is not cut off. */
  .table th { white-space: normal; }
  .mono, code { overflow-wrap: anywhere; }
  /* Sign-in style pages: the one main action spans the card, within easy reach of a thumb. */
  .narrow form > .btn-primary, .narrow .card > .btn-primary { width: 100%; }
}
fieldset.field { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.field legend { padding: 0; margin-bottom: 8px; }
fieldset.field .notice { margin-top: 8px; }
.scope-list { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0; }
.scope-list li { border: 1px solid var(--border); border-radius: 999px; padding: 2px 12px; background: #fafbf7; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* The folded menu is for phones only; wider screens keep the menu as it is. */
.nav-menu { display: none; }
@media (max-width: 639.98px) {
  /* Phones: fold the 8-item menu behind one row ("メニュー" and the current screen) so the page
     starts on the first screen. <details> opens with a tap, Enter or Space; no JavaScript. */
  .sidebar { padding-bottom: 14px; }
  .sidebar .brand { padding-bottom: 12px; }
  .sidebar .brand-mark { width: 30px; height: 30px; }
  .sidebar .brand-name { font-size: 19px; }
  .sidebar .nav-wide { display: none; }
  .nav-menu { display: block; }
  .nav-menu > summary { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 8px 14px; border: 1px solid #466658; border-radius: 9px; background: #244e40; color: #fff; font-size: 14px; font-weight: 600; line-height: 1.4; cursor: pointer; list-style: none; }
  .nav-menu > summary::-webkit-details-marker { display: none; }
  .nav-menu > summary::after { content: ""; flex-shrink: 0; width: 8px; height: 8px; margin: 0 2px 4px auto; border: solid #d6e5b5; border-width: 0 2px 2px 0; transform: rotate(45deg); }
  .nav-menu[open] > summary::after { margin-bottom: -4px; transform: rotate(-135deg); }
  .nav-menu-current { min-width: 0; color: #d6e5b5; font-weight: 400; overflow-wrap: anywhere; }
  .nav-menu-current::before { content: "／" / ""; margin-right: 8px; color: #91a88e; }
  .nav-menu > .nav { padding: 10px 0 0; }

  /* Lists whose rows are one thing each (a training, a person, a log entry) become one card per
     row, each value under its column name. Tables that compare columns (results by department)
     keep scrolling sideways. */
  .table-scroll:has(> .table-cards) { border: 0; border-radius: 0; overflow: visible; }
  .table.table-cards { display: block; min-width: 0; }
  .table-cards thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .table-cards tbody, .table-cards tr { display: block; }
  .table-cards tr { padding: 4px 14px; border: 1px solid var(--border); border-radius: 10px; background: #fff; }
  .table-cards tr + tr { margin-top: 10px; }
  .table.table-cards tr td { display: flow-root; min-width: 0; max-width: none; padding: 9px 0 9px 96px; border-bottom: 1px solid var(--border); white-space: normal; overflow-wrap: anywhere; text-align: left; }
  .table.table-cards tr td:last-child, .table.table-cards tr td:has(+ td:empty:last-child) { border-bottom: 0; }
  .table.table-cards td::before { content: attr(data-label); float: left; width: 88px; margin-left: -96px; color: var(--muted); font-size: 12px; font-weight: 600; line-height: 1.9; }
  .table.table-cards tr td:not([data-label]) { padding-left: 0; }
  .table.table-cards td:not([data-label]) > a:not(.btn) { display: inline-flex; align-items: center; min-height: 44px; }
  .table.table-cards td:empty { display: none; }
  .table.table-cards tr td[colspan] { padding: 22px 0; text-align: center; background: none; }
  .table.table-cards tr:hover td { background: none; }
  .table.table-cards .mono { white-space: normal; }
  .table.table-cards td .inline-form { flex-wrap: wrap; }
  .table.table-cards td .btn { min-width: 0; }
}
/* Date and time fields. iOS WebKit draws them as its own control: it ignores box-sizing (so
   width: 100% plus padding and border stuck 26px out of the card) and centres the date. Drawn as a
   plain field they size like the other inputs; tapping still opens the native date picker. */
.input[type="date"], .input[type="time"], .input[type="datetime-local"], .input[type="month"] { -webkit-appearance: none; appearance: none; max-width: 100%; text-align: left; }
.input::-webkit-date-and-time-value { text-align: left; }
