/*!**************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ../../node_modules/.pnpm/next@14.2.35_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[12].use[2]!../../node_modules/.pnpm/next@14.2.35_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[12].use[3]!./components/aoc-theme.css ***!
  \**************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
  @import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600;700&display=swap');
  .aoc-root {
    --violet-50:#E4DBFB; --violet-200:#C3ABF6; --violet-400:#A577F1; --violet-500:#8C3BEC;
    --violet-700:#6523AF; --violet-800:#3C116C; --violet-900:#17042F;
    --paper-50:#FAF9FB; --paper-200:#D7CEDF; --paper-400:#977EAC; --paper-700:#4C3B5A;
    --lilac-50:#F3ECFD; --lilac-300:#D7BAF8; --lilac-500:#BC84F4; --lilac-700:#7E25BE;
    --neutral-50:#EDEFF0; --neutral-200:#C2C9CC; --neutral-400:#7B8285; --neutral-600:#383B3D; --neutral-800:#191B1C;
    --bg: #0D0A13;
    --surface: rgba(25,27,28,0.55);
    --surface-2: #232028;
    /* aoc raw-colour hairline (used directly via var(--line)) */
    --line: rgba(76,59,90,0.4);
    /* shadcn border token must stay an HSL triplet so its base
       `* { border-color: hsl(var(--border)) }` resolves — an rgba here breaks
       every shadcn border inside .aoc-root (falls back to white currentColor). */
    --border: 268 24% 30%;
    --fg: #FAF9FB;
    --muted: #9BA3A8;
    --c-success:#10b981; --c-warning:#f59e0b; --c-danger:#ef4444; --success:160 84% 39%; --warning:38 92% 50%; --destructive:0 84% 60%;
    --topbar: 54px;
    background: radial-gradient(ellipse 120% 80% at 15% -10%, rgba(140,59,236,0.16), transparent 60%),
                radial-gradient(ellipse 100% 60% at 100% 0%, rgba(188,132,244,0.08), transparent 55%),
                radial-gradient(ellipse 90% 60% at 98% 108%, rgba(190,28,45,0.12), transparent 55%),
                var(--bg);
    color: var(--fg);
    font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
    min-height: 100vh; position: relative;
  }
  .aoc-root * { box-sizing: border-box; }
  .lucide { stroke-width: 1.6; }
  .aoc-display { font-family: 'Space Grotesk', 'Inter', sans-serif; letter-spacing: -0.01em; }
  .aoc-mono { font-family: ui-monospace, 'Cascadia Code', 'Source Code Pro', Menlo, Consolas, monospace; }

  .aoc-hexbg {
    position: fixed; inset: 0; opacity: 0.5; pointer-events: none; z-index: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='96' viewBox='0 0 84 96'%3E%3Cpath d='M42 0 L84 24 L84 72 L42 96 L0 72 L0 24 Z' fill='none' stroke='%233C116C' stroke-opacity='0.35' stroke-width='1'/%3E%3C/svg%3E");
    background-size: 84px 96px;
    -webkit-mask-image: radial-gradient(ellipse 70% 55% at 50% 0%, black, transparent 75%);
            mask-image: radial-gradient(ellipse 70% 55% at 50% 0%, black, transparent 75%);
  }

  .aoc-shell { position: relative; z-index: 1; display: flex; min-height: 100vh; padding-top: var(--topbar); }

  /* Sidebar */
  .aoc-sidebar {
    width: 248px; flex-shrink: 0; border-right: none;
    background: rgba(15,12,20,0.6); backdrop-filter: blur(14px);
    display: flex; flex-direction: column; padding: 14px 14px;
    position: fixed; top: var(--topbar); bottom:0; left:0; z-index: 40;
    transition: transform 240ms ease, width 220ms ease; overflow-y: auto;
    scrollbar-width: none; -ms-overflow-style: none;
  }
  .aoc-sidebar::-webkit-scrollbar { width: 0; height: 0; display: none; }
  .aoc-sidebar.closed { transform: translateX(-100%); }
  @media (min-width: 1024px) {
    .aoc-sidebar { position: sticky; top: var(--topbar); height: calc(100vh - var(--topbar)); transform: none !important; } .aoc-sidebar.rail { width: 76px; padding: 20px 10px; }
  }

  .aoc-logo { display:flex; align-items:center; gap:10px; padding: 4px 4px 12px 8px; }
  .aoc-sidebar.rail .aoc-logo { justify-content: center; padding: 6px 0 22px; }
  .aoc-logo-mark {
    width:32px; height:32px; border-radius: 9px; flex-shrink: 0;
    background: linear-gradient(135deg, var(--violet-500), var(--lilac-500));
    display:flex; align-items:center; justify-content:center;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.08) inset, 0 6px 18px rgba(140,59,236,0.35);
  }
  .aoc-logo-word { font-size: 16px; font-weight: 700; color: var(--paper-50); white-space: nowrap; }
  .aoc-logo-sub { font-size: 10.5px; color: var(--muted); margin-top: -2px; letter-spacing: 0.06em; white-space: nowrap; }
  .aoc-sidebar.rail .aoc-logo-text { display: none; }

  .aoc-railhead { height: 0; }
  .aoc-railtoggle {
    position: fixed; top: calc(var(--topbar) + 12px); z-index: 45; display: none;
    width: 28px; height: 28px; flex-shrink: 0;
    align-items: center; justify-content: center; color: var(--paper-50);
    background: rgba(15,12,20,0.95); border: 1px solid var(--line); border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4); cursor: pointer;
    transition: left 220ms ease, color 150ms ease, transform 150ms ease, background 150ms ease;
  }
  @media (min-width: 1024px) { .aoc-railtoggle { display: flex; } }
  .aoc-railtoggle:hover { color: var(--lilac-300); background: var(--surface-2); border-color: var(--lilac-500); transform: scale(1.12); }
  /* notch: carve a bite out of the sidebar's right edge so the toggle sits flush */
  .aoc-sidebar { -webkit-mask: radial-gradient(circle 18px at 100% calc(var(--topbar) + 26px - var(--topbar)), transparent 97%, #000 100%), linear-gradient(#000 0 0); -webkit-mask-composite: source-in; -webkit-mask: radial-gradient(circle 18px at 100% 26px, transparent 97%, #000 100%), linear-gradient(#000 0 0); mask: radial-gradient(circle 18px at 100% 26px, transparent 97%, #000 100%), linear-gradient(#000 0 0); -webkit-mask-composite: source-in, xor; mask-composite: intersect; }

  .aoc-navsection { font-size: 10px; text-transform: uppercase; letter-spacing: 0.09em; color: var(--paper-400); margin: 4px 10px 3px; white-space: nowrap; overflow: hidden; }
  /* live-event nav rows (under Events) */
  .aoc-liverow { display: flex; align-items: center; gap: 10px; margin: 2px 4px 2px 26px; padding: 7px 10px; border-radius: 8px; font-size: 12.5px; color: var(--paper-200, #cfc8e0); text-decoration: none; transition: background 0.13s; }
  .aoc-liverow:hover { background: rgba(255,255,255,0.05); }
  .aoc-liverow.active { background: rgba(224,30,46,0.1); }
  .aoc-liveicon { flex: none; color: var(--paper-300, #b7aecc); }
  .aoc-liverow.active .aoc-liveicon { color: #ff8087; }
  .aoc-livename { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .aoc-livedot { width: 6px; height: 6px; border-radius: 50%; background: #ff4d5a; flex: none; box-shadow: 0 0 6px rgba(224,30,46,0.9); animation: aoc-liveblink 1.3s steps(1,end) infinite; }
  @keyframes aoc-liveblink { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
  @media (prefers-reduced-motion: reduce) { .aoc-livedot { animation: none; } }
  .aoc-livepill { flex: none; display: inline-flex; align-items: center; gap: 5px; font-size: 9px; font-weight: 800; letter-spacing: 0.5px; color: #ff6b74; background: rgba(224,30,46,0.16); border: 1px solid rgba(224,30,46,0.45); border-radius: 999px; padding: 2px 7px; }
  /* the LIVE badge lives inside a live row — this higher-specificity rule keeps it
     RED and wins over the unrelated green .aoc-livepill declared later in this file */
  .aoc-liverow .aoc-livepill { color: #ff6b74; background: rgba(224,30,46,0.16); border-color: rgba(224,30,46,0.45); }

  /* Events nav row in collapse/expand mode: the left icon is its own toggle button
     (Events icon at rest → chevron on hover); the label still links to /events. */
  .aoc-evrow.active { color: var(--paper-50); background: linear-gradient(90deg, #6523AF, #8C3BEC); box-shadow: 0 4px 14px rgba(140,59,236,0.35); }
  .aoc-evtoggle { position: relative; flex: none; width: 20px; height: 20px; display: inline-flex; align-items: center; justify-content: center; background: none; border: none; cursor: pointer; color: inherit; }
  .aoc-evtoggle svg { width: 20px !important; height: 20px !important; }
  .aoc-evtoggle .ic-rest, .aoc-evtoggle .ic-hover { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); transition: opacity 0.12s; }
  .aoc-evtoggle .ic-hover { opacity: 0; }
  .aoc-evrow:hover .aoc-evtoggle .ic-rest { opacity: 0; }
  .aoc-evrow:hover .aoc-evtoggle .ic-hover { opacity: 1; }
  .aoc-evlink { flex: 1; min-width: 0; display: inline-flex; align-items: center; text-decoration: none; color: inherit; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

  /* rail (collapsed): center the event icon, name + pill are unmounted */
  .aoc-sidebar.rail .aoc-liverow { justify-content: center; margin-left: 4px; }
  .aoc-sidebar.rail .aoc-navsection { text-align: center; opacity: 0; height: 4px; margin: 6px 0; }
  /* breathing room between sidebar sections; removed in rail so icons cluster */
  .aoc-navgroup { margin-bottom: 16px; }
  .aoc-navgroup:last-child { margin-bottom: 0; }
  .aoc-sidebar.rail .aoc-navgroup { margin-bottom: 0; }
  .aoc-sidebar.rail .aoc-navsection { display: none; }

  .aoc-navitem {
    display:flex; align-items:center; gap:10px; padding: 4px 11px; border-radius: 8px;
    font-size: 12.5px; font-weight: 500; color: var(--muted); cursor: pointer;
    min-height: 28px; transition: background 150ms ease, color 150ms ease; position: relative;
  }
  .aoc-navitem:hover { background: rgba(255,255,255,0.04); color: var(--fg); }
  .aoc-navitem.active { color: var(--paper-50); box-shadow: 0 4px 14px rgba(140,59,236,0.35); }
  .aoc-navitem-svgbg { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; overflow: visible; }
  .aoc-navitem > svg.lucide, .aoc-navitem .label, .aoc-navitem .badge { position: relative; z-index: 1; }
  .aoc-navitem > svg.lucide, .aoc-sidebar.rail .aoc-navitem > svg.lucide { width: 17px; height: 17px; flex-shrink: 0; }
  .aoc-sidebar.rail .aoc-navitem { justify-content: center; padding: 6px; }
  .aoc-navitem .label, .aoc-navitem .badge { white-space: nowrap; overflow: hidden; transition: opacity 160ms ease; }
  .aoc-sidebar.rail .aoc-navitem .label, .aoc-sidebar.rail .aoc-navitem .badge { display: none; }
  .aoc-navitem .badge {
    margin-left:auto; font-size: 10.5px; font-weight: 600; padding: 1px 6px; border-radius: 6px;
    background: rgba(140,59,236,0.18); color: var(--lilac-300); flex-shrink: 0;
  }
  .aoc-navitem.active .badge { background: rgba(255,255,255,0.22); color: var(--paper-50); }

  .aoc-sidefoot { padding-top: 2px; margin-top: auto; }
  /* lecture routes: the portal rail is hidden, so centre the content column in
     the viewport (the default .aoc-content pins left on screens wider than its
     max-width). */
  .aoc-content.lecture-mode { margin-left: auto; margin-right: auto; }
  /* a running Outpost panel reserves space on the right: shrink the whole chrome
     (shell + fixed top bar) uniformly so the page just reflows into a narrower
     viewport instead of being covered or squished. */
  .aoc-shell { margin-right: var(--outpost-panel-w, 0px); transition: margin-right 180ms ease; }
  .aoc-topbar { right: var(--outpost-panel-w, 0px); transition: right 180ms ease; }
  .outpost-dragging .aoc-shell,
  .outpost-dragging .aoc-topbar { transition: none !important; }
  .aoc-sideline { border-top: 1px solid var(--line); margin: 8px 4px 2px; }
  .aoc-opnode { display:flex; align-items:center; gap:10px; padding: 6px 10px; border-radius: 10px; }
  .aoc-sidebar.rail .aoc-opnode { justify-content: center; padding: 8px 0; }
  .aoc-sidebar.rail .aoc-opnode .opnode-text, .aoc-sidebar.rail .aoc-opnode .opnode-chevron { display: none; }
  .aoc-avatar { width:32px; height:32px; border-radius:50%; background: var(--surface-2); display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:700; color: var(--lilac-300); border: 1px solid var(--line); flex-shrink: 0; }
  .aoc-logoutrow { display:flex; align-items:center; gap:10px; padding: 6px 12px; margin-top: 2px; border-radius: 10px; color: var(--muted); font-size: 13px; cursor: pointer; }
  .aoc-logoutrow:hover { color: var(--fg); background: rgba(255,255,255,0.04); }
  .aoc-sidebar.rail .aoc-logoutrow { justify-content: center; padding: 10px; }
  .aoc-sidebar.rail .aoc-logoutrow span { display: none; }

  /* Main */
  .aoc-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

  .aoc-topbar {
    display:flex; align-items:center; gap:10px; padding: 8px 18px;
    border-bottom: 1px solid var(--line); position: fixed; top:0; left:0; right:0; z-index: 50;
    min-height: var(--topbar);
    background: rgba(13,10,19,0.82); backdrop-filter: blur(14px);
  }
  .aoc-topbar-actions { display:flex; align-items:center; gap:10px; margin-left:auto; }
  .aoc-brandlink { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; border-radius: 8px; padding: 2px 4px; transition: transform 150ms ease, filter 150ms ease; }
  .aoc-brandword { font-size: 17px; font-weight: 700; color: #ffffff; letter-spacing: 0.05em; }
  .aoc-brandlink:hover { transform: scale(1.04); }
  .aoc-brandlink:focus-visible { outline: 2px solid var(--violet-500); outline-offset: 2px; }
  .aoc-brandlogo { height: 32px; width: auto; -o-object-fit: contain; object-fit: contain; display: block; filter: drop-shadow(0 2px 6px rgba(140,59,236,0.4)); }
  .aoc-iconbtn { width:34px; height:34px; border-radius:9px; display:flex; align-items:center; justify-content:center; color:var(--muted); background: transparent; border: 1px solid transparent; cursor:pointer; }
  .aoc-iconbtn:hover { background: var(--surface-2); color: var(--fg); border-color: var(--line); }
  .aoc-iconbtn:focus-visible, .aoc-navitem:focus-visible, .aoc-searchbar:focus-within, .aoc-btn:focus-visible {
    outline: 2px solid var(--violet-500); outline-offset: 2px;
  }
  .aoc-searchbar {
    flex:0 1 380px; display:flex; align-items:center; gap:9px;
    background: var(--surface-2); border: 1px solid var(--line); border-radius: 9px;
    padding: 7px 11px; color: var(--muted);
  }
  .aoc-searchbar input { background: transparent; border: none; outline: none; color: var(--fg); font-size: 13.5px; width: 100%; }
  .aoc-searchbar input::-moz-placeholder { color: var(--muted); }
  .aoc-searchbar input::placeholder { color: var(--muted); }
  .aoc-kbd { font-size: 10.5px; color: var(--muted); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; }

  .aoc-livepill { display:flex; align-items:center; gap:7px; padding: 6px 11px; border-radius: 999px; background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.3); color:#6ee7b7; font-size: 12px; font-weight: 600; }
  .aoc-dot { width:7px; height:7px; border-radius:50%; background: currentColor; box-shadow: 0 0 8px currentColor; }
  .aoc-pulse { animation: aocPulse 1.8s ease-in-out infinite; }
  @keyframes aocPulse { 0%,100%{opacity:1} 50%{opacity:0.35} }

  .aoc-content { padding: 24px; max-width: 1560px; width: 100%; flex: 1; }
  .aoc-pageheading { font-size: 22px; font-weight: 700; margin: 0; display:flex; align-items:center; gap:10px; }
  .aoc-pagesub { color: var(--muted); font-size: 13px; margin-top: 3px; max-width: 720px; }

  /* Cards */
  .aoc-card { background: var(--surface); border: none; border-radius: 16px; backdrop-filter: blur(10px); padding: 18px 20px; }
  .aoc-cardhead { display:flex; align-items:flex-start; justify-content:space-between; margin-bottom: 14px; gap: 12px; flex-wrap: wrap; }
  .aoc-cardtitle { font-size: 13.5px; font-weight: 600; color: var(--fg); }
  .aoc-cardsub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }

  .aoc-grid { display:grid; gap:16px; margin-top: 20px; }
  .aoc-g7 { grid-template-columns: repeat(7, 1fr); }
  .aoc-g6 { grid-template-columns: repeat(6, 1fr); }
  .aoc-g5 { grid-template-columns: repeat(5, 1fr); }
  .aoc-g4 { grid-template-columns: repeat(4, 1fr); }
  .aoc-g2 { grid-template-columns: repeat(2, 1fr); }
  @media (max-width:1240px){ .aoc-g7,.aoc-g6,.aoc-g5 { grid-template-columns: repeat(3,1fr);} .aoc-g4{grid-template-columns:repeat(2,1fr);} }
  @media (max-width:760px){ .aoc-g7,.aoc-g6,.aoc-g5,.aoc-g4,.aoc-g2 { grid-template-columns: 1fr 1fr;} }
  @media (max-width:520px){ .aoc-grid { grid-template-columns: 1fr !important;} }

  .aoc-kpi { position: relative; background: var(--surface); backdrop-filter: blur(10px); border: none; border-radius: 16px; padding: 16px 18px; }
  /* ── KpiCard (App.jsx original): card with two circular icon buttons that
     straddle the top edge, seated in mask-carved notches. ── */
  .aoc-kpi-wrap { position: relative; }
  .aoc-kpi-card {
    position: relative; background: var(--surface); backdrop-filter: blur(10px);
    border: none; border-radius: 16px; padding: 18px 20px 16px;
    -webkit-mask:
      radial-gradient(circle 19px at calc(100% - 57px) 0, transparent 98%, #000 100%),
      radial-gradient(circle 19px at calc(100% - 23px) 0, transparent 98%, #000 100%),
      linear-gradient(#000 0 0);
    -webkit-mask-composite: source-in;
    -webkit-mask:
      radial-gradient(circle 19px at calc(100% - 57px) 0, transparent 98%, #000 100%),
      radial-gradient(circle 19px at calc(100% - 23px) 0, transparent 98%, #000 100%),
      linear-gradient(#000 0 0);
            mask:
      radial-gradient(circle 19px at calc(100% - 57px) 0, transparent 98%, #000 100%),
      radial-gradient(circle 19px at calc(100% - 23px) 0, transparent 98%, #000 100%),
      linear-gradient(#000 0 0);
    -webkit-mask-composite: source-in, xor;
            mask-composite: intersect;
  }
  .aoc-kpi-inner { position: relative; z-index: 1; }
  /* reserve two lines for the label so single- and double-line KPIs align their
     values across the row (e.g. "Users" vs "Running deployments") */
  .aoc-kpi-inner .aoc-cardtitle {
    min-height: 2.5em; line-height: 1.25; display: flex; align-items: flex-start;
  }
  .aoc-kpi-topicons { position: absolute; top: 0; right: 0; width: 0; height: 0; z-index: 2; pointer-events: none; }
  .aoc-kpi-circle {
    position: absolute; top: 0; width: 28px; height: 28px; margin-top: -14px;
    border-radius: 50%; display:flex; align-items:center; justify-content:center;
    border: 1.5px solid var(--lilac-500); background: #2a2140; color: var(--lilac-300);
    box-shadow: 0 2px 8px rgba(0,0,0,0.35);
  }
  .aoc-kpi-circle.up { border-color: var(--c-success); background: rgba(16,185,129,0.16); color: #6ee7b7; }
  .aoc-kpi-circle.down { border-color: var(--c-danger); background: rgba(239,68,68,0.16); color: #fca5a5; }
  .aoc-kpi-value { font-size: 25px; font-weight: 700; margin-top: 4px; }
  .aoc-kpi-label { font-size: 12px; color: var(--muted); margin-top: 2px; }
  .aoc-kpi-delta { display:inline-flex; align-items:center; gap:4px; font-size: 12px; font-weight: 600; margin-top: 10px; padding: 3px 7px; border-radius: 6px; }
  .aoc-delta-up { color: #6ee7b7; background: rgba(16,185,129,0.1); }
  .aoc-delta-down { color: #fca5a5; background: rgba(239,68,68,0.1); }

  /* Table */
  .aoc-tablewrap { overflow-x:auto; }
  .aoc-table { width: 100%; border-collapse: collapse; font-size: 12px; }
  .aoc-table th { text-align:left; font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--line); white-space:nowrap; }
  .aoc-table td { padding: 7px 8px; font-size: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
  .aoc-table .aoc-badge { font-size: 10.5px; padding: 2px 7px; }
  .aoc-table .aoc-chip { font-size: 10px; padding: 2px 6px; }
  .aoc-table .aoc-level { padding: 2px 7px; }
  .aoc-table tr:last-child td { border-bottom: none; }
  .aoc-table tbody tr:hover td { background: rgba(255,255,255,0.02); }
  .aoc-link { color: var(--lilac-300); cursor:pointer; font-weight:600; }
  .aoc-link:hover { text-decoration: underline; }

  .aoc-badge { display:inline-flex; align-items:center; gap:6px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; white-space:nowrap; }
  .b-success { color:#6ee7b7; background: rgba(16,185,129,0.12); }
  .b-warning { color:#fcd34d; background: rgba(245,158,11,0.12); }
  .b-destructive { color:#fca5a5; background: rgba(239,68,68,0.12); }
  .b-secondary { color: var(--paper-200); background: rgba(123,130,133,0.15); }
  .b-default { color: var(--lilac-300); background: rgba(140,59,236,0.18); }
  .b-outline { color: var(--muted); background: transparent; border: 1px solid var(--line); }
  .aoc-chip { font-size: 11px; padding: 3px 8px; border-radius: 6px; background: var(--surface-2); color: var(--paper-200); border: 1px solid var(--line); white-space:nowrap; }

  .aoc-btn {
    display:inline-flex; align-items:center; gap:7px; font-size: 12.5px; font-weight: 600; padding: 8px 13px;
    border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--fg); cursor: pointer;
    min-height: 38px;
  }
  .aoc-btn:hover { border-color: var(--violet-500); }
  .aoc-btn-primary { background: linear-gradient(135deg, var(--violet-500), var(--violet-700)); border: none; box-shadow: 0 4px 16px rgba(140,59,236,0.35); }
  .aoc-btn-primary:hover { filter: brightness(1.08); }
  .aoc-btn-danger { color:#fca5a5; border-color: rgba(239,68,68,0.4); }
  .aoc-btn-danger:hover { background: rgba(239,68,68,0.12); border-color: var(--c-danger); }
  .aoc-btn-sm { min-height: 30px; padding: 5px 10px; font-size: 11.5px; }

  .aoc-scrim { position:fixed; inset:0; background: rgba(0,0,0,0.5); z-index: 35; }
  @media (min-width: 1024px) { .aoc-scrim { display:none; } }

  /* Skeleton */
  .aoc-sk { border-radius: 10px; background: linear-gradient(90deg, rgba(255,255,255,0.04) 25%, rgba(255,255,255,0.09) 37%, rgba(255,255,255,0.04) 63%); background-size: 400% 100%; animation: aocSk 1.4s ease infinite; }
  @keyframes aocSk { 0%{background-position:100% 0} 100%{background-position:-100% 0} }

  /* Empty */
  .aoc-empty { display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; gap:10px; padding: 48px 20px; color: var(--muted); }
  .aoc-empty-ic { width:52px;height:52px;border-radius:14px; background: var(--surface-2); border:1px solid var(--line); display:flex;align-items:center;justify-content:center; color: var(--lilac-300); }

  /* Bulk bar */
  .aoc-bulkbar { display:flex; align-items:center; gap:12px; padding: 10px 14px; background: rgba(140,59,236,0.12); border:1px solid rgba(140,59,236,0.3); border-radius: 11px; margin-bottom: 12px; font-size: 13px; }

  /* Dialog */
  .aoc-dialogscrim { position: fixed; inset:0; background: rgba(5,3,10,0.66); backdrop-filter: blur(3px); z-index: 60; display:flex; align-items:center; justify-content:center; padding: 24px 16px; overflow-y:auto; }
  .aoc-dialog { background: #14111b; border:1px solid var(--line); border-radius: 16px; width: 100%; max-width: 480px; box-shadow: 0 24px 60px rgba(0,0,0,0.6); }
  .aoc-dialog.wide { max-width: 640px; }
  .aoc-dialoghead { padding: 18px 20px 10px; }
  .aoc-dialogtitle { font-size: 16px; font-weight: 700; }
  .aoc-dialogdesc { font-size: 12.5px; color: var(--muted); margin-top: 4px; line-height: 1.5; }
  .aoc-dialogbody { padding: 6px 20px 4px; display:flex; flex-direction:column; gap: 14px; }
  .aoc-dialogfoot { padding: 14px 20px 18px; display:flex; justify-content:flex-end; gap: 10px; }

  .aoc-field { display:flex; flex-direction:column; gap:6px; }
  .aoc-field label { font-size: 12px; font-weight: 600; color: var(--paper-200); }
  .aoc-field .hint { font-size: 11px; color: var(--muted); font-weight: 400; }
  .aoc-input, .aoc-select, .aoc-textarea {
    background: var(--surface-2); border:1px solid var(--line); border-radius: 9px; padding: 9px 11px;
    color: var(--fg); font-size: 13px; font-family: inherit; width: 100%; outline: none;
  }
  .aoc-input:focus, .aoc-select:focus, .aoc-textarea:focus { border-color: var(--violet-500); }
  .aoc-textarea { min-height: 84px; resize: vertical; }
  .aoc-row-2 { display:grid; grid-template-columns: 1fr 1fr; gap: 12px; }

  /* Switch */
  .aoc-switch { width:38px; height:22px; border-radius: 999px; background: var(--surface-2); border:1px solid var(--line); position:relative; cursor:pointer; flex-shrink:0; transition: background 150ms; }
  .aoc-switch.on { background: var(--violet-500); border-color: var(--violet-500); }
  .aoc-switch::after { content:''; position:absolute; top:2px; left:2px; width:16px;height:16px;border-radius:50%; background:#fff; transition: transform 150ms; }
  .aoc-switch.on::after { transform: translateX(16px); }
  .aoc-switchrow { display:flex; align-items:center; justify-content:space-between; gap:12px; font-size:13px; }

  /* Level badge */
  .aoc-level { position: relative; display:inline-flex; align-items:center; gap:5px; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; overflow: hidden; }
  .aoc-level .aoc-mono { font-size: 11px; }
  .aoc-flames { position:absolute; inset:0; z-index:0; border-radius:999px; overflow:hidden; }
  .aoc-flames::before, .aoc-flames::after {
    content:''; position:absolute; left:-10%; right:-10%; bottom:-40%; height:180%;
    background:
      radial-gradient(closest-side at 20% 100%, #ffd24a 0%, rgba(255,120,20,0.9) 40%, transparent 72%),
      radial-gradient(closest-side at 50% 100%, #ff8a1e 0%, rgba(214,64,20,0.9) 45%, transparent 75%),
      radial-gradient(closest-side at 80% 100%, #ffcf4a 0%, rgba(255,90,20,0.85) 42%, transparent 72%);
    filter: blur(1px);
    animation: aocFlame 900ms ease-in-out infinite alternate;
  }
  .aoc-flames::after { animation-duration: 620ms; opacity: 0.75; mix-blend-mode: screen; }
  @keyframes aocFlame {
    0%   { transform: scaleY(1) translateY(0) skewX(0deg); }
    50%  { transform: scaleY(1.12) translateY(-6%) skewX(-3deg); }
    100% { transform: scaleY(0.94) translateY(2%) skewX(3deg); }
  }
  .aoc-level.flame { color:#fff7e6; text-shadow: 0 1px 2px rgba(120,30,0,0.8); box-shadow: 0 0 14px rgba(255,120,20,0.55); }
  .aoc-level.flame > * { position: relative; z-index: 1; }

  /* Footer */
  .aoc-footer {
    border-top: 1px solid var(--line); background: rgba(15,12,20,0.6); backdrop-filter: blur(12px);
    padding: 14px 24px; display:flex; align-items:center; justify-content:space-between; gap: 12px; flex-wrap:wrap;
    font-size: 12px; color: var(--muted);
  }
  .aoc-footer .brand { display:flex; align-items:center; gap:8px; color: var(--paper-200); font-weight:600; }

  /* Toast */
  .aoc-toasts { position: fixed; bottom: 20px; right: 20px; z-index: 80; display:flex; flex-direction:column; gap:10px; }
  .aoc-toast { background: #14111b; border:1px solid var(--line); border-left: 3px solid var(--violet-500); border-radius: 10px; padding: 11px 14px; font-size: 13px; min-width: 240px; box-shadow: 0 12px 30px rgba(0,0,0,0.5); animation: aocToast 200ms ease; }
  .aoc-toast.err { border-left-color: var(--c-danger); }
  .aoc-toast.ok { border-left-color: var(--c-success); }
  @keyframes aocToast { from{ transform: translateY(8px); opacity:0 } to{ transform:none; opacity:1 } }

  .aoc-tabs { display:flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 18px 0; flex-wrap: wrap; }
  .aoc-tab { padding: 9px 14px; font-size: 13px; font-weight: 600; color: var(--muted); cursor:pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
  .aoc-tab.active { color: var(--fg); border-bottom-color: var(--violet-500); }
  .aoc-tab:hover { color: var(--fg); }

  .aoc-canvas { border: 1px dashed var(--line); border-radius: 14px; min-height: 420px; background:
    linear-gradient(rgba(76,59,90,0.12) 1px, transparent 1px) 0 0/26px 26px,
    linear-gradient(90deg, rgba(76,59,90,0.12) 1px, transparent 1px) 0 0/26px 26px; position: relative; }

  .aoc-row2 { display:grid; grid-template-columns: 1.7fr 1fr; gap: 16px; margin-top: 20px; }
  @media (max-width: 980px) { .aoc-row2 { grid-template-columns: 1fr; } }
  .aoc-legend { display:flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
  .aoc-legend-item { display:flex; align-items:center; gap:6px; font-size: 11.5px; color: var(--muted); }
  .aoc-legend-swatch { width:8px; height:8px; border-radius:2px; }

  .aoc-menu { position:absolute; right:0; top:44px; z-index:50; background: rgba(17,14,23,0.86); backdrop-filter: blur(40px) saturate(1.8); border:1px solid rgba(188,132,244,0.25); border-radius:14px; box-shadow: 0 24px 60px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.07); padding:8px; }
  .aoc-menu-head { padding: 6px 10px 8px; border-bottom: 1px solid var(--line); margin-bottom: 4px; display:flex; align-items:center; justify-content:space-between; gap:10px; }
  .aoc-menuitem { display:flex; align-items:center; gap:10px; padding:8px 10px; border-radius:9px; font-size:13px; color:var(--fg); cursor:pointer; }
  .aoc-menuitem:hover { background: rgba(255,255,255,0.06); }
  .aoc-menuitem.sel { background: rgba(140,59,236,0.14); }
  /* AocSelect — themed dropdown (custom menu, not native <select>) */
  .aoc-selectbtn { display:flex; align-items:center; justify-content:space-between; gap:8px; width:100%; background: var(--surface-2); border:1px solid var(--line); border-radius:9px; padding:9px 11px; color:var(--fg); font-size:13px; cursor:pointer; text-align:left; font-family:inherit; }
  .aoc-selectbtn:hover { border-color: var(--violet-500); }
  .aoc-selectbtn:disabled { opacity:.5; cursor:not-allowed; }
  .aoc-selectbtn .ph { color: var(--muted); }
  .aoc-selectmenu { position:absolute; top:calc(100% + 4px); left:0; width:100%; max-height:260px; overflow-y:auto; z-index:70; }
  .aoc-notif { display:flex; gap:10px; padding:9px 10px; border-radius:10px; cursor:pointer; }
  .aoc-notif:hover { background: rgba(255,255,255,0.05); }
  .aoc-notif-dot { width:30px; height:30px; border-radius:9px; display:flex; align-items:center; justify-content:center; flex-shrink:0; }

  /* Round dark-red checkboxes */
  .aoc-root input[type="checkbox"] {
    -webkit-appearance:none; -moz-appearance:none; appearance:none; width:18px; height:18px; border-radius:50%;
    border:1.5px solid var(--paper-700); background: var(--surface-2); cursor:pointer;
    position:relative; flex-shrink:0; vertical-align:middle; margin:0;
    transition: background 120ms ease, border-color 120ms ease;
  }
  .aoc-root input[type="checkbox"]:hover { border-color: var(--violet-500); }
  .aoc-root input[type="checkbox"]:checked { background:#8a1220; border-color:#a3142a; box-shadow: 0 0 0 2px rgba(138,18,32,0.25); }
  .aoc-root input[type="checkbox"]:checked::after {
    content:''; position:absolute; left:5.5px; top:2px; width:4px; height:9px;
    border:solid #fff; border-width:0 2px 2px 0; transform:rotate(45deg);
  }

  /* Native select option theming */
  .aoc-root select option { background:#1a1622; color: var(--fg); }

  /* Colored action icons */
  .aoc-iconbtn.edit { color: var(--lilac-300); }
  .aoc-iconbtn.edit:hover { background: rgba(140,59,236,0.14); color: var(--lilac-300); border-color: rgba(140,59,236,0.45); }
  .aoc-iconbtn.del { color:#f28b8b; }
  .aoc-iconbtn.del:hover { background: rgba(239,68,68,0.14); color:#fca5a5; border-color: rgba(239,68,68,0.45); }

  /* Compact table */
  .aoc-table.compact th { padding: 6px 8px; font-size: 10px; }
  .aoc-table.compact td { padding: 7px 8px; font-size: 12px; }
  .aoc-table.compact .aoc-badge { font-size: 10.5px; padding: 2px 7px; }
  .aoc-table.compact .aoc-chip { font-size: 10px; padding: 2px 6px; }
  .aoc-table.compact .aoc-level { padding: 2px 7px; }

  /* ── Parity fixes: the original App.jsx ran under Vite with an index.css that
     set the root font to 18px; ported here (this app's global Tailwind CSS does
     not). Also pin sidebar icon sizes + a self-contained top-bar brand mark so
     nothing depends on an external logo asset. ── */
  .aoc-root { font-size: 18px; line-height: 1.45; letter-spacing: 0.18px; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
  @media (max-width: 1024px) { .aoc-root { font-size: 16px; } }
  .aoc-root .aoc-navitem > svg.lucide { width: 20px !important; height: 20px !important; }
  .aoc-root .aoc-sidebar.rail .aoc-navitem > svg.lucide { width: 20px !important; height: 20px !important; }
  .aoc-root .aoc-navitem { min-height: 34px; padding: 6px 11px; gap: 12px; font-size: 13px; }
  .aoc-root .aoc-navitem .label { font-size: 13px; }
  .aoc-brandmark {
    width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    font-family: 'Space Grotesk','Inter',sans-serif; font-weight: 700; font-size: 16px; color: #fff;
    background: linear-gradient(135deg, var(--violet-500), var(--lilac-500));
    box-shadow: 0 0 0 1px rgba(255,255,255,0.08) inset, 0 6px 18px rgba(140,59,236,0.4);
  }

  /* mobile menu button — visible only below the desktop breakpoint */
  .aoc-mobilemenu { display: flex; }
  @media (min-width: 1024px) { .aoc-mobilemenu { display: none; } }

  /* Dropdown menu open animation */
  @keyframes aocMenuIn { from { opacity: 0; transform: translateY(-6px) scale(0.98); } to { opacity: 1; transform: none; } }
  .aoc-menu, .aoc-selectmenu { animation: aocMenuIn 150ms cubic-bezier(0.2, 0.9, 0.3, 1.1); transform-origin: top; }

  /* Kill the browser's white/black focus ring on form controls — use the violet
     border/ring from the scheme instead. */
  .aoc-root input:focus, .aoc-root input:focus-visible,
  .aoc-root textarea:focus, .aoc-root textarea:focus-visible,
  .aoc-root select:focus, .aoc-root select:focus-visible,
  .aoc-selectbtn:focus, .aoc-selectbtn:focus-visible {
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(140, 59, 236, 0.35);
    border-color: var(--violet-500);
  }
  .aoc-root input[type="checkbox"]:focus-visible {
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(140, 59, 236, 0.4);
  }

  /* Markdown editor toolbar */
  .aoc-md { display: flex; flex-direction: column; }
  .aoc-md-bar { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; padding: 5px 6px; background: var(--surface-2); border: 1px solid var(--line); border-bottom: none; border-radius: 9px 9px 0 0; }
  .aoc-md-btn { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: transparent; border: none; color: var(--muted); cursor: pointer; transition: background 120ms, color 120ms; }
  .aoc-md-btn:hover { background: rgba(140, 59, 236, 0.16); color: var(--lilac-300); }
  .aoc-md-sep { width: 1px; height: 18px; background: var(--line); margin: 0 4px; }
  .aoc-md-area { border-radius: 0 0 9px 9px !important; }

  /* Challenge detail — main + side column layout */
  .aoc-detail-grid { display: grid; grid-template-columns: 1.9fr 1fr; gap: 16px; align-items: start; }
  @media (max-width: 980px) { .aoc-detail-grid { grid-template-columns: 1fr; } }

  /* Challenge detail — spawn / provisioning panel */
  @keyframes aocSpin { to { transform: rotate(360deg); } }
  .aoc-spin { animation: aocSpin 0.9s linear infinite; color: var(--lilac-300); }
  .aoc-spawn-box { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap;
    margin-top: 14px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line);
    background: var(--surface-2); animation: aocMenuIn 160ms ease; }
  .aoc-spawn-live { border-color: rgba(140,59,236,0.4); background: rgba(140,59,236,0.10); }
  .aoc-spawn-ok   { border-color: rgba(140,59,236,0.45); background: rgba(140,59,236,0.08); }
  .aoc-spawn-err  { border-color: rgba(239,68,68,0.45); background: rgba(239,68,68,0.10); }

  /* Difficulty vote chart — vertical bars + coloured 1..10 scale */
  .aoc-votechart { display: flex; align-items: flex-end; justify-content: space-between;
    gap: 4px; height: 150px; padding: 0 6px; border: 1px solid var(--line); border-radius: 6px; }
  .aoc-votebar-wrap { flex: 1; height: 100%; display: flex; align-items: flex-end; justify-content: center; }
  .aoc-votebar { width: 100%; max-width: 16px; min-height: 2px; border-radius: 3px 3px 0 0; transition: height 300ms ease; }
  .aoc-votescale { display: flex; justify-content: space-between; gap: 4px; padding: 10px 6px 0; }
  .aoc-votechip { flex: 1; max-width: 22px; aspect-ratio: 1; border-radius: 50%; color: #0B0A12;
    font-size: 10.5px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }

  /* ── User-portal parity: the admin pages were authored at an 18px root
     (.aoc-root font-size above). User-portal pages use Tailwind sized for a
     16px root, so reset the content area's base back to 16px. Sidebar/topbar
     keep the admin sizing. ── */
  .aoc-root .aoc-content { font-size: 16px; line-height: 1.5; letter-spacing: normal; }

  /* Feature-gated nav items (user portal): dimmed + not-allowed, no hover. */
  .aoc-navitem.disabled { opacity: 0.4; cursor: not-allowed; pointer-events: auto; }
  .aoc-navitem.disabled:hover { background: transparent; color: var(--muted); }

