/* AnyDayOut owner dashboard (/business, /business/<place>; static/owner.js, #213).
   Uses the site's tokens from index.html (--bg, --surface, --ink, --muted, --line, --accent,
   --chip, --ok), so dark mode follows the site's. Phones first: tabs scroll across the top;
   from 900px the tabs become a left rail. */
main:has(> .od) { max-width: 1240px; }
.od { --od-r: 16px; }
.od h1, .od h2 { font-family: "Fraunces", Georgia, serif; letter-spacing: -.01em; }
.od h1 { font-size: 28px; line-height: 1.15; margin: 4px 0 6px; font-weight: 800; }
.od h2 { font-size: 19px; margin: 0 0 10px; font-weight: 700; }
.od h3 { font-size: 15px; margin: 0 0 8px; }
.od .meta { color: var(--muted); }
.od > p a:not([class]), .od-panel a:not([class]) { color: var(--accent); font-weight: 600; text-underline-offset: 2px; }
.od-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--od-r); padding: 18px; margin-bottom: 14px; min-width: 0; }
.od-card > :last-child { margin-bottom: 0; }
.od-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.od a:focus-visible, .od button:focus-visible, .od select:focus-visible, .od input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---- business home ---- */
.od-home-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 10px; margin-bottom: 18px; }
.od-biz { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.od-bcard { display: flex; flex-direction: column; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 18px; }
.od-bcard h2 { margin: 0; font-size: 21px; }
.od-bcard .od-btop { display: flex; justify-content: space-between; gap: 8px; align-items: start; }
.od-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.od-mini div { background: var(--chip); border-radius: 12px; padding: 10px; display: grid; gap: 2px; min-width: 0; }
.od-mini b { font-size: 20px; line-height: 1.1; }
.od-mini .meta { font-size: 12px; }
.od-bacts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: auto; }
.od-add { display: grid; place-items: center; text-align: center; gap: 6px; min-height: 200px; border: 2px dashed var(--line); border-radius: 20px; padding: 18px; color: inherit; text-decoration: none; }
.od-add:hover { border-color: var(--accent); }
.od-add .ic { font-size: 32px; }
.od-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 8px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
.od-btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.od-btn:disabled { opacity: .55; cursor: default; }

/* ---- pills ---- */
.od-pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--chip); color: var(--muted); white-space: nowrap; }
.od-pill.pro { background: var(--accent); color: var(--accent-ink); }
.od-chg { font-size: 12px; font-weight: 700; white-space: nowrap; }
.od-chg.up { color: var(--ok); } .od-chg.down { color: var(--muted); }

/* ---- per-business layout ---- */
.od-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 4px; }
.od-crumb { font-size: 14px; color: var(--muted); text-decoration: none; }
.od-crumb:hover { color: var(--ink); }
.od-tabs { position: sticky; top: var(--od-sticky, 0px); z-index: 3; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; background: var(--bg); border-bottom: 1px solid var(--line); margin: 10px -16px 16px; padding: 0 16px; }
.od-tabs::-webkit-scrollbar { display: none; }
.od-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 11px 10px; color: var(--muted); font-weight: 600; text-decoration: none; white-space: nowrap; border-bottom: 2px solid transparent; }
.od-tabs a[aria-current="page"] { color: var(--ink); border-color: var(--accent); }
.od-tabs .ic { font-size: 16px; }
.od-tabs .od-lockic { font-size: 11px; }
.od-panel { min-width: 0; }
.od-admin { background: var(--chip); border-radius: 12px; padding: 8px 12px; margin: 6px 0 0; font-size: 14px; }
@media (min-width: 900px) {
  .od-shell { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 28px; align-items: start; }
  .od-tabs { position: sticky; top: 90px; flex-direction: column; border: 0; margin: 0; padding: 0; overflow: visible; background: none; }
  .od-tabs a { border: 0; border-radius: 12px; padding: 10px 12px; }
  .od-tabs a:hover { background: var(--chip); color: var(--ink); }
  .od-tabs a[aria-current="page"] { background: var(--surface); color: var(--ink); box-shadow: inset 3px 0 0 var(--accent); }
}

/* ---- range picker ---- */
.od-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 12px; }
.od-head h2 { margin: 0; }
.od-seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; background: var(--surface); }
.od-seg button { font: inherit; font-size: 13px; font-weight: 600; border: 0; background: none; color: var(--muted); padding: 7px 13px; cursor: pointer; min-height: 34px; }
.od-seg button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

/* ---- KPI tiles ---- */
.od-kpis { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 14px; }
@media (min-width: 640px) { .od-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.od-kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; display: grid; gap: 2px; min-width: 0; text-align: left; font: inherit; color: inherit; }
button.od-kpi { cursor: pointer; }
.od-kpi[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.od-kpi b { font-size: 24px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.od-kpi .meta { font-size: 13px; }

/* ---- checklist / next steps ---- */
.od-grid2 { display: grid; gap: 14px; }
.od-grid2 > div { min-width: 0; }
@media (min-width: 1100px) { .od-grid2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.od-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.od-steps li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 12px; background: var(--chip); border-radius: 12px; }
.od-steps .n { width: 26px; height: 26px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-weight: 700; font-size: 13px; }

/* ---- chart ---- */
.od-chart { width: 100%; height: auto; display: block; color: var(--accent); }
.od-chart .grid { stroke: var(--line); stroke-width: 1; }
.od-chart text { fill: var(--muted); font-size: 11px; font-family: inherit; }
.od-chart rect.bar { fill: currentColor; }
.od-chart rect.bar.zero { fill: var(--line); }
.od-chart rect.hit { fill: transparent; }
.od-chart rect.hit:hover + rect.bar, .od-chart g:focus rect.bar { opacity: .75; }
.od-table { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.od-table th, .od-table td { text-align: left; padding: 5px 6px; border-bottom: 1px solid var(--line); }
.od-table td.num, .od-table th.num { text-align: right; }
.od details summary { cursor: pointer; color: var(--muted); font-size: 14px; margin-top: 8px; }

/* ---- sources ---- */
.od-bars { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.od-bars li { display: grid; gap: 4px; }
.od-bars .row { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.od-bars .track { height: 10px; border-radius: 999px; background: var(--chip); overflow: hidden; }
.od-bars .fill { height: 100%; border-radius: 999px; background: var(--accent); }
.od-bars li.muted .fill { background: var(--muted); opacity: .5; }
.od-terms { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.od-terms li { background: var(--chip); border-radius: 999px; padding: 6px 12px; font-size: 14px; }
.od-terms b { margin-left: 6px; font-variant-numeric: tabular-nums; }

/* ---- benchmark ---- */
.od-bench { display: grid; gap: 14px; }
.od-bench .row { display: grid; gap: 6px; }
.od-bench .lab { display: flex; justify-content: space-between; font-size: 14px; gap: 10px; }
.od-bench .lines { position: relative; height: 26px; background: var(--chip); border-radius: 8px; }
.od-bench .you, .od-bench .med { position: absolute; top: 3px; bottom: 3px; border-radius: 6px; }
.od-bench .you { left: 0; background: var(--accent); }
.od-bench .med { width: 3px; background: var(--ink); }

/* ---- locked (Pro) ---- */
.od-locked { position: relative; overflow: hidden; }
.od-ghost { position: absolute; inset: 58px 18px 18px; filter: blur(5px); opacity: .55; pointer-events: none; user-select: none; display: grid; gap: 10px; align-content: start; }
.od-ghost i { display: block; height: 14px; border-radius: 8px; background: var(--line); }
.od-ghost .bars { display: flex; align-items: end; gap: 4px; height: 120px; }
.od-ghost .bars i { flex: 1; height: auto; border-radius: 4px 4px 0 0; background: var(--muted); opacity: .45; }
.od-unlock { position: relative; display: grid; place-items: center; min-height: 120px; padding: 8px 0; }
.od-unlock > div { max-width: 420px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.od-unlock p { margin: 0 0 12px; }

/* ---- specials ---- */
.od-posts { list-style: none; padding: 0; margin: 0 0 12px; }
.od-posts li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); }
.od-posts li:first-child { border-top: 0; }
.od-form { display: grid; gap: 10px; }
.od-form .two { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.od-form label { display: grid; gap: 4px; font-size: 14px; color: var(--muted); }
.od-form input, .od-form select, .od-form textarea { font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px; min-height: 40px; width: 100%; }
.od-form textarea { min-height: 70px; resize: vertical; }

/* ---- photos ---- */
.od-photos { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.od-ph { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--chip); display: grid; place-items: center; text-align: center; font-size: 13px; color: var(--muted); }
.od-ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.od-ph .tag { position: absolute; left: 8px; bottom: 8px; background: rgba(20, 17, 13, .78); color: #fff; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.od-ph .pos { position: absolute; left: 8px; top: 8px; background: var(--accent); color: var(--accent-ink); padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.od-ph.dim img { opacity: .4; }

/* ---- listing (the existing editor, minus what the dashboard's tabs already show) ---- */
.od-listing .biz-dash, .od-listing [data-billing], .od-listing .biz-pro, .od-listing [data-insights] { display: none; }
.od-listing h3:first-child { display: none; }
.od-listing .cform { grid-template-columns: minmax(0, 1fr); }
.od-listing .claim-hours { grid-template-columns: 44px minmax(0, 1fr); }
.od-listing input, .od-listing textarea, .od-listing select { min-width: 0; max-width: 100%; box-sizing: border-box; }

/* ---- settings ---- */
.od-owners { list-style: none; padding: 0; margin: 0 0 10px; }
.od-owners li { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); }
.od-owners li:first-child { border-top: 0; }
/* Promote: badges for your website (#184) */
.od-kit .od-snip { border-top: 1px solid var(--line); padding: 12px 0; display: grid; gap: 8px; }
.od-kit .od-snip-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.od-kit .od-snip img { max-width: 100%; height: auto; justify-self: start; }
.od-kit textarea { width: 100%; box-sizing: border-box; font: 12.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px; resize: vertical; overflow-wrap: anywhere; }
