/* =====================================================================
   PRO DESIGN LAYER (v1.1)

   Loaded after style.css on every public page and after the operator
   stylesheet on the operator's pages. style.css keeps the layout of each feature; this file gives
   every shared component the Pro look: near-black surfaces, one orange
   accent with dark text on it, sky blue for premium, DM Sans / DM Mono,
   8px corners, uppercase micro labels, one 1200px column from header to
   footer, and a bottom bar that is always on screen.
   ===================================================================== */

:root {
  --page-max: 1120px;
  --gutter: 40px;
  --on-accent: #111111;
  --pro-glow: 0 0 0 1px rgba(245,165,36,.35), 0 10px 30px -8px rgba(245,165,36,.45);
  --pro-card: #0A0A0A;
  --pro-card-2: #111111;
  --pro-line: rgba(255,255,255,.08);
  --pro-line-2: rgba(255,255,255,.14);
  --pro-bar: rgba(8,8,8,.96);
  --tabbar-h: 62px;
}
:root[data-theme="light-palette"] {
  --on-accent: #FFFFFF;
  --pro-glow: 0 0 0 1px rgba(180,83,9,.25), 0 10px 26px -10px rgba(180,83,9,.40);
  --pro-card: #FFFFFF;
  --pro-card-2: #F4F5F7;
  --pro-line: rgba(0,0,0,.09);
  --pro-line-2: rgba(0,0,0,.16);
  --pro-bar: rgba(250,250,248,.95);
}
:root[data-theme="contrast"] { --pro-line: rgba(255,255,255,.28); --pro-line-2: rgba(255,255,255,.45); }
@media (max-width: 1100px) { :root { --gutter: 32px; } }
@media (max-width: 640px)  { :root { --gutter: 16px; } }

/* ---------- type ---------- */
body { font-family: var(--font-sans); background: var(--bg); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { font-family: var(--font-sans); letter-spacing: -0.02em; }
h1, h2 { font-weight: 700; }
h3 { font-weight: 650; }
code, kbd, .mono, .num, .cnt, .live-num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
::selection { background: color-mix(in srgb, var(--accent) 35%, transparent); }

/* ---------- one column, top to bottom ---------- */
.layout, .footer, .fold-grid, .page-wrap:not(.narrow), .pro-col {
  max-width: calc(var(--page-max) + 2 * var(--gutter));
  padding-left: var(--gutter); padding-right: var(--gutter);
  box-sizing: border-box; margin-left: auto; margin-right: auto;
}
.page-wrap.narrow { padding-left: var(--gutter); padding-right: var(--gutter); box-sizing: border-box; }

/* =====================================================================
   HEADER
   ===================================================================== */
.topbar.pro-top {
  display: flex; align-items: center; gap: 10px; flex-wrap: nowrap;
  height: 72px; padding: 0 max(var(--gutter), calc((100% - var(--page-max)) / 2));
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--pro-line);
  position: sticky; top: 0; z-index: 70;
}
.pro-brand { display: inline-flex; align-items: center; gap: 12px; color: var(--text); text-decoration: none; flex: 0 0 auto; min-width: 0; }
.pro-badge {
  width: 42px; height: 42px; flex: 0 0 auto; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(140deg, color-mix(in srgb, var(--accent) 30%, transparent), color-mix(in srgb, var(--up) 10%, transparent) 60%, color-mix(in srgb, var(--brass) 22%, transparent));
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  box-shadow: 0 0 22px color-mix(in srgb, var(--accent) 28%, transparent);
}
.pro-badge .logo-img { width: 30px; height: 30px; border-radius: 6px; }
.pro-brand-txt { display: flex; flex-direction: column; line-height: 1.12; min-width: 0; }
.pro-brand-txt strong { font-size: 21px; font-weight: 700; letter-spacing: -0.015em; white-space: nowrap; }
.pro-tagline { font-size: 12px; color: var(--muted); white-space: nowrap; }
.pro-nav { display: flex; align-items: center; gap: 0; margin-left: 14px; flex: 0 0 auto; }
.pro-link {
  position: relative; height: 38px; padding: 0 11px; border-radius: 6px;
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 500; white-space: nowrap;
  transition: color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}
.pro-link:hover { color: var(--text); }
.pro-link.on { color: var(--text); background: color-mix(in srgb, var(--accent) 16%, transparent); }
.pro-spacer { flex: 1 1 auto; }
.pro-lock { width: 6px; height: 6px; border-radius: 50%; background: var(--brass); display: inline-block; flex: none; }
.pro-btn-ghost, .topbar .pro-login {
  height: 40px; padding: 0 14px; border-radius: 6px; display: inline-flex; align-items: center;
  border: 1px solid var(--pro-line-2); color: var(--text); text-decoration: none; font-size: 15px; white-space: nowrap; flex: 0 0 auto;
}
.pro-btn-ghost:hover { background: color-mix(in srgb, var(--text) 5%, transparent); }
.topbar .nav-btn.accent.pro-cta {
  height: 40px; padding: 0 16px; border-radius: 8px; display: inline-flex; align-items: center;
  font-size: 14px; font-weight: 700; white-space: nowrap; flex: 0 0 auto;
}
.pro-ic {
  width: 44px; height: 44px; flex: 0 0 auto; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--pro-line-2); background: transparent; color: var(--text);
  cursor: pointer; text-decoration: none; padding: 0; font: inherit;
}
.pro-ic:hover { background: color-mix(in srgb, var(--text) 6%, transparent); }
.pro-avatar { border-radius: 999px; padding: 4px; }
.pro-avatar span {
  width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--accent), var(--brass)); color: #111; font-weight: 700; font-size: 13px;
}
.pro-avatar.is-paid { border-color: var(--brass); }
.pro-acct {
  display: none; position: absolute; right: max(var(--gutter), calc((100% - var(--page-max)) / 2)); top: 66px;
  width: 260px; padding: 6px; flex-direction: column; gap: 2px; z-index: 75;
  background: var(--pro-card); border: 1px solid var(--pro-line-2); border-radius: 8px;
  box-shadow: 0 20px 50px -20px rgba(0,0,0,.6);
}
.pro-acct.open { display: flex; animation: proRise .22s var(--ease-out); }
.pro-acct-who { padding: 10px 12px 8px; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; border-bottom: 1px solid var(--pro-line); margin-bottom: 4px; }
.pro-acct-who b { display: block; margin-top: 2px; color: var(--text); text-transform: none; letter-spacing: 0; font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pro-acct a { display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 12px; border-radius: 6px; color: var(--muted); text-decoration: none; font-size: 14px; }
.pro-acct a:hover { background: color-mix(in srgb, var(--text) 5%, transparent); color: var(--text); }
.pro-acct a.pro-acct-out { color: var(--down); border-top: 1px solid var(--pro-line); border-radius: 0 0 6px 6px; margin-top: 2px; }
@keyframes proRise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* fewer things on narrower screens, never a wrapped line */
@media (max-width: 1500px) { .pro-tagline { display: none; } }
@media (max-width: 1180px) { .topbar .pro-login { display: none; } }
@media (max-width: 960px)  { .pro-nav { display: none; } }
@media (max-width: 640px)  {
  .topbar.pro-top { height: 64px; gap: 8px; }
  .pro-badge { width: 38px; height: 38px; }
  .pro-brand-txt strong { font-size: 19px; }
  .topbar .nav-btn.accent.pro-cta { display: none; }
  .pro-acct { right: 12px; left: 12px; width: auto; top: 60px; }
}

/* =====================================================================
   BOTTOM BAR + MENU SHEET
   ===================================================================== */
body { padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px)); }
.tabbar.pro-tabbar {
  display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 200;
  background: var(--pro-bar); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-top: 1px solid var(--pro-line); padding: 0 6px env(safe-area-inset-bottom, 0px);
}
.pro-tabbar-in { max-width: 560px; margin: 0 auto; display: flex; }
.pro-tab {
  flex: 1 1 0; min-width: 0; height: 58px; position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  border: 0; background: transparent; color: var(--muted); text-decoration: none; cursor: pointer;
  font: 600 12px/1 var(--font-sans); padding: 0;
}
.pro-tab span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.pro-tab:hover { color: var(--text); }
.pro-tab.on { color: var(--text); }
.pro-tab.on::before, .pro-tile.on::before {
  content: ""; position: absolute; top: 0; left: 50%; width: 44px; margin-left: -22px; height: 3px;
  border-radius: 0 0 3px 3px; background: var(--accent); box-shadow: 0 0 12px var(--accent);
}
.pro-tab .pro-lock, .pro-tile .pro-lock { position: absolute; top: 10px; left: 50%; margin-left: 10px; }
.pro-scrim {
  position: fixed; inset: 0; z-index: 180; background: rgba(3,3,3,.6);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); animation: proFade .2s ease;
}
.pro-sheet {
  position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px)); z-index: 190;
  display: flex; justify-content: center; pointer-events: none;
}
.pro-sheet[hidden], .pro-scrim[hidden] { display: none; }
.pro-sheet-in {
  pointer-events: auto; width: min(560px, 100%); box-sizing: border-box; padding: 8px 6px 6px;
  background: var(--pro-bar); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border: 1px solid var(--pro-line); border-bottom: 0; border-radius: 12px 12px 0 0;
  max-height: calc(calc(100vh / var(--zf, 1)) - 90px); overflow: auto; animation: proRise .25s var(--ease-out); position: relative;
}
.pro-sheet-head { display: flex; align-items: center; gap: 6px; padding: 8px 6px 0 10px; }
.pro-sheet-head b { flex: 1 1 auto; font-size: 15px; }
.pro-sheet-head .pro-ic { width: 38px; height: 38px; }
.pro-grip { position: absolute; left: 50%; margin-left: -18px; top: 6px; width: 36px; height: 4px; border-radius: 2px; background: var(--pro-line-2); }
.pro-sheet-lbl { display: block; padding: 12px 8px 2px; font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.pro-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2px; }
.pro-tile {
  position: relative; height: 70px; border-radius: 8px; min-width: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  color: var(--muted); text-decoration: none; font: 600 12px/1.1 var(--font-sans); text-align: center;
}
.pro-tile span { max-width: 100%; padding: 0 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pro-tile:hover { background: color-mix(in srgb, var(--text) 5%, transparent); color: var(--text); }
.pro-tile.on { color: var(--text); }
@keyframes proFade { from { opacity: 0; } to { opacity: 1; } }
html.pro-sheet-open { overflow: hidden; }
/* popups that sit at the bottom keep the bar visible above them */
.scan-pop { bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px)) !important; }

/* =====================================================================
   COMPONENTS
   ===================================================================== */
/* surfaces */
.panel, .card, .feat, .empty-state, .stat, .pstat, .ct-tile, .upsell-card, .plan, .plan-card, .price-card, .notice, .wallet-row, .prefs-box {
  border-radius: 8px;
}
.panel, .card, .feat, .empty-state, .upsell-card, .plan-card, .price-card {
  background: var(--pro-card); border-color: var(--pro-line);
  box-shadow: none;
}
.panel { border: 1px solid var(--pro-line); -webkit-backdrop-filter: none; backdrop-filter: none; }

/* buttons */
button.primary, .cta-main, .btn-primary, .nav-btn.accent, .btn.primary, .plan-cta, .upsell-go, .ai-ask-btn {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 92%, #fff), var(--accent-fill)) !important;
  color: var(--on-accent) !important; border: 0 !important; font-weight: 700 !important;
  box-shadow: var(--pro-glow) !important; border-radius: 8px !important;
}
button.primary:hover, .cta-main:hover, .btn-primary:hover, .nav-btn.accent:hover, .plan-cta:hover, .upsell-go:hover { filter: brightness(1.06); }
.cta-ghost, .btn, .btn-ghost, button.secondary {
  border-radius: 8px;
}
.cta-ghost {
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--pro-line-2) !important; color: var(--text) !important; text-decoration: none !important;
  background: color-mix(in srgb, var(--text) 3%, transparent);
}
.cta-ghost:hover { background: color-mix(in srgb, var(--text) 7%, transparent); }
.btn { border: 1px solid var(--pro-line-2); color: var(--text); background: transparent; }
.btn:hover { background: color-mix(in srgb, var(--text) 6%, transparent); }

/* inputs */
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="search"], input[type="url"], input[type="tel"], select, textarea {
  background: var(--pro-card); border: 1px solid var(--pro-line-2); color: var(--text);
  border-radius: 8px; font-family: var(--font-sans);
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }

/* segmented controls / tabs */
.tf, .tabs a, .perf-tab, .rtab-btn, .ct-btn, .scan-tabs .tab, .seg button {
  border-radius: 8px;
}
.tf.on, .tf.active, .tabs a.on, .tabs a.active, .perf-tab.on, .perf-tab.active, .rtab-btn.on, .rtab-btn.active, .ct-btn.on, .scan-tabs .tab.on, .scan-tabs .tab.active {
  background: var(--accent) !important; color: var(--on-accent) !important; border-color: transparent !important;
}

/* labels */
.lbl, .ticket-label, .stat .lbl, .pstat span, .perf-slide-h {
  font-family: var(--font-sans); text-transform: uppercase; letter-spacing: .07em; font-weight: 600;
}

/* tables */
table { border-collapse: collapse; }
.perf-table th, .tbl th, table.data th, .mkt-table th {
  font-family: var(--font-sans); font-size: 10.5px; text-transform: uppercase; letter-spacing: .07em; font-weight: 600; color: var(--muted);
  border-bottom: 1px solid var(--pro-line-2);
}
.perf-table td, .tbl td, table.data td, .mkt-table td { border-bottom: 1px solid var(--pro-line); }
.perf-table tbody tr:hover td, .mkt-table tbody tr:hover td { background: color-mix(in srgb, var(--text) 3%, transparent); }

/* page heads */
.page-head { padding-top: 14px; }
.page-head h1 { font-size: clamp(30px, calc(4vw / var(--zf, 1)), 48px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 700; }
.page-head p { font-size: 15px; }
.page-head[data-kicker]::before {
  content: attr(data-kicker); display: block; margin-bottom: 8px;
  font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent);
}

/* footer */
.footer { border-top: 1px solid var(--pro-line); margin-top: 40px; padding-top: 22px; }
.footer a { color: var(--accent); }

/* popups */
.upsell-card, .scan-pop-card, dialog { border-radius: 8px; border: 1px solid var(--pro-line-2); background: var(--pro-card); }

@media (prefers-reduced-motion: reduce) {
  .pro-acct.open, .pro-sheet-in, .pro-scrim { animation: none; }
}

/* page kickers for heads that are not .page-head */
.perf-head::before, .pp-head::before {
  display: block; margin-bottom: 10px; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
}
.perf-head::before { content: "Verified results"; }
.perf-head h1, .pp-head h1, .up-box h1 { font-size: clamp(32px, calc(4.4vw / var(--zf, 1)), 52px); letter-spacing: -0.035em; font-weight: 700; line-height: 1.05; }
.perf-head .h1-ic-wrap { display: none; }
.pp-head::before { content: "Pricing"; }

/* ---------- account (member) ---------- */
.acct-wrap:has(.acct-grid) { max-width: calc(var(--page-max) + 2 * var(--gutter)); padding: 0 var(--gutter); margin: 0 auto; box-sizing: border-box; }
.acct-box:has(.acct-grid) { max-width: none; width: auto; background: none; border: 0; box-shadow: none; padding: 26px 0 0; margin: 0; }
.acct-head { margin-bottom: 22px; }
.acct-grid { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 20px; align-items: start; }
.acct-side { position: sticky; top: 92px; background: var(--pro-card); border: 1px solid var(--pro-line); border-radius: 8px; padding: 20px; }
.acct-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.acct-main > form, .acct-main > div, .acct-main > details { background: var(--pro-card); border: 1px solid var(--pro-line); border-radius: 8px; padding: 20px 22px; margin: 0 !important; }
.acct-main > a.back { align-self: flex-start; }
.acct-main .prefs-head { margin: 22px -22px 10px !important; padding: 16px 22px 0 !important; border-top: 1px solid var(--pro-line); font-size: 11px !important; text-transform: uppercase; letter-spacing: .08em; color: var(--accent) !important; }
.acct-main .prefs-head:first-of-type { margin-top: 0 !important; padding-top: 0 !important; border-top: 0; }
.acct-main .prefs-head strong { font-weight: 700; color: inherit; }
.acct-side .btn, .acct-side a.btn { height: 46px; display: flex !important; align-items: center; justify-content: center; }
@media (max-width: 900px) {
  .acct-grid { grid-template-columns: minmax(0, 1fr); }
  .acct-side { position: static; }
}
.acct-head h1 { font-size: clamp(30px, calc(4vw / var(--zf, 1)), 48px) !important; letter-spacing: -0.035em; margin: 0 0 6px !important; }
.acct-main .prefs-head { background: none !important; }
.acct-main > a.back { padding: 0 4px 20px; }
