/* Owner dashboard (2026-11-01). Frank's own palette, no separate dashboard palette
   (docs/design/FRANK-DESIGN.md). Colour has a job here: brick red only on the armed
   email state, wheat on the panel that carries personality, sage and evergreen for
   structure. Numbers wear ink, never a status colour. */

.ad-loading, .ad-empty { color: var(--muted); font-size: 14px; margin: 0; }
.ad-empty { padding: 14px 0; }
.ad-warn {
  background: var(--white); border: 1px solid var(--red); border-radius: var(--panel-radius);
  color: var(--red); padding: 12px 16px; margin: 0 0 20px; font-size: 14px; line-height: 1.5;
}

/* The one status on the page. Colour plus the word On or Off plus a drawn mark. */
.ad-banner { border-radius: var(--panel-radius); padding: 18px 20px; margin: 0 0 24px; border: 1px solid var(--line); background: var(--white); }
.ad-banner-armed { border-color: var(--red); background: #fdf6f4; }
.ad-banner-quiet { border-color: var(--line); background: var(--sage); }
.ad-banner-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.ad-banner h2 { font: 400 21px/1.2 Georgia, serif; margin: 0; letter-spacing: -0.2px; }
.ad-banner-armed h2 { color: var(--red); }
.ad-banner-quiet h2 { color: var(--green); }
.ad-banner p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--ink); }
.ad-banner-note { margin-top: 8px !important; font-size: 13px !important; color: var(--muted) !important; }
.ad-mark { width: 22px; height: 22px; flex: none; }
.ad-banner-armed .ad-mark { color: var(--red); }
.ad-banner-quiet .ad-mark { color: var(--green); }

/* Stat tiles. The number leads; the rule above it is the only colour. */
.ad-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin: 0 0 26px; }
.ad-tile { background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--green); border-radius: var(--panel-radius); padding: 16px 18px; }
.ad-tile-green { border-top-color: var(--ochre); }
.ad-tile-value { font: 400 32px/1.05 Georgia, serif; color: var(--ink); margin: 0 0 6px; letter-spacing: -0.5px; }
.ad-tile-label { font: 600 13px/1.3 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); margin: 0; text-transform: none; letter-spacing: 0; }
.ad-tile-note { font-size: 12px; line-height: 1.45; color: var(--muted); margin: 4px 0 0; }

.ad-panel { margin-bottom: 22px; }
.ad-sub { font: 600 13px/1.3 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); margin: 0 0 8px; }
.ad-sub + .ad-table-wrap + .ad-sub, .ad-table-wrap + .ad-sub { margin-top: 20px; }
.ad-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 26px; }

.ad-table-wrap { overflow-x: auto; }
.ad-table-wrap:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.ad-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.ad-table th, .ad-table td { text-align: left; padding: 9px 12px 9px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.ad-table th { font-weight: 600; font-size: 12px; color: var(--muted); }
.ad-table tr:last-child td { border-bottom: 0; }

/* The three doors out, as real targets. */
.ad-links { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.ad-link {
  display: flex; flex-direction: column; gap: 3px; min-height: 64px; justify-content: center;
  background: var(--wheat); border: 1px solid var(--wheat-line); border-radius: var(--panel-radius);
  padding: 14px 16px; text-decoration: none; color: var(--green);
  font: 600 15px/1.25 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.ad-link span { font-weight: 400; font-size: 12px; color: var(--muted); }
.ad-link:hover { background: #efdfae; }
.ad-link:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }

@media (max-width: 700px) {
  .ad-tiles { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
  .ad-tile { padding: 13px 14px; }
  .ad-tile-value { font-size: 27px; }
  .ad-split { gap: 22px; }
}

/* Feature adoption. The bar is a reading aid beside the number, never instead of it:
   the count and its denominator are always written out. */
.ad-bar { display: inline-block; vertical-align: middle; width: 72px; height: 6px; margin-left: 10px;
  background: var(--sage); border-radius: 3px; overflow: hidden; }
.ad-bar > span { display: block; height: 100%; background: var(--green); border-radius: 3px; }
.ad-dim { color: var(--muted); }
.ad-note { font-size: 12px; color: var(--muted); margin: 12px 0 0; line-height: 1.5; }
.ad-request-id { font-size: 11px; overflow-wrap: anywhere; user-select: all; }

/* Keep scrollable owner tables inside narrow phone panels. */
.ad-split > * { min-width: 0; }
@media (max-width: 360px) {
  .notebook .topbar:has(.mobile-owner) { flex-wrap: wrap; gap: 4px 12px; }
  .notebook .topbar:has(.mobile-owner) .topbar-right { margin-left: auto; }
}
