:root {
  /* Dark/gold design system (design_handoff_leftafy). Gold replaces the old
     cyan accent; savings/success stays mint. Class names are unchanged so the
     wired dashboard.js keeps working — only the look changes. */
  --bg: #0A0C10;
  --surface: #11151C;
  --surface-2: #141A23;
  --card: #141922;
  --text: #F2F5F9;
  --text-2: #C9D2DE;
  --muted: #8A94A6;
  --faint: #5C6572;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.18);
  --accent: #F6C445;          /* gold (Lefta / primary) */
  --accent-2: #2CE3A0;        /* mint (savings / success) */
  --lefta: var(--accent);
  --warning: #FF7A2F;
  --danger: #F4483A;
  --gold-grad: linear-gradient(120deg, #F8CE5A, #E0A82E);
  --gold-ink: #231A04;
  --gold-line: rgba(246, 196, 69, 0.14);
  --display: "Bebas Neue", "Arial Narrow", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(1000px 620px at 50% -8%, rgba(246, 196, 69, 0.08), transparent 60%),
    radial-gradient(900px 520px at 10% 100%, rgba(0, 84, 154, 0.16), transparent 62%),
    radial-gradient(900px 520px at 92% 100%, rgba(110, 66, 255, 0.12), transparent 62%),
    var(--bg);
  color: var(--text);
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  min-height: 100vh;
}

.dash-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 0 4vw;
  height: 64px;
  border-bottom: 1px solid var(--gold-line);
  background: linear-gradient(180deg, rgba(8, 10, 14, 0.94) 0%, rgba(8, 10, 14, 0.78) 100%);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.brand {
  font-family: var(--display);
  font-size: 25px;
  letter-spacing: 0.14em;
  color: var(--accent);
  line-height: 1;
  text-decoration: none;
  text-shadow: 0 0 22px rgba(246, 196, 69, 0.35);
}
.brand:hover { color: var(--accent); }

.subtitle { display: none; }

/* Desktop primary nav (hidden on mobile — bottom bar takes over) */
.dash-nav-links {
  display: flex;
  gap: 2px;
  align-items: center;
}
.dash-nav-link {
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 13.5px;
  padding: 6px 10px;
  font-weight: 500;
  color: #98A2B3;
  transition: color 160ms ease;
}
.dash-nav-link:hover { color: #fff; }
.dash-nav-link.active { color: #fff; font-weight: 700; }

.nav-actions {
  margin-left: auto;
  display: flex;
  gap: 0.55rem;
  align-items: center;
  justify-content: flex-end;
}

.user-badge[hidden] { display: none; }

.nav-location { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.nav-lefta {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  font-family: inherit; font-size: 13px; font-weight: 700; color: var(--accent);
  border: 1px solid rgba(246, 196, 69, 0.5); border-radius: 999px; padding: 6px 13px;
  background: linear-gradient(120deg, rgba(246, 196, 69, 0.16), rgba(246, 196, 69, 0.06));
  transition: background 160ms ease, box-shadow 160ms ease;
}
.nav-lefta:hover { background: rgba(246, 196, 69, 0.22); box-shadow: 0 0 18px rgba(246, 196, 69, 0.25); }
.nav-coin { width: 9px; height: 9px; border-radius: 50%; flex: none; display: inline-block; background: radial-gradient(circle at 35% 30%, #FFE9A8, #F6C445 60%, #C89218); box-shadow: 0 0 8px rgba(246, 196, 69, 0.5); }
.nav-avatar {
  width: 32px; height: 32px; border-radius: 8px; cursor: pointer;
  border: 1px solid rgba(246, 196, 69, 0.4); background: linear-gradient(135deg, #F8CE5A, #C89218);
  color: #231A04; font-weight: 700; font-size: 14px; font-family: inherit;
  display: flex; align-items: center; justify-content: center;
}
@media (max-width: 760px) { .nav-location { display: none; } }

main {
  width: 100%;
  margin: 0 0 3rem;
  padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px));
}

/* Summary bar */
.summary-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  padding: 1rem 4vw 0;
}

.summary-item {
  flex: 1 1 160px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.summary-label {
  font-size: 0.82rem;
  color: var(--muted);
}

.summary-item strong {
  font-family: var(--display);
  font-size: 2rem;
  letter-spacing: 0.02em;
  line-height: 1;
}

.summary-lefta strong {
  color: var(--accent);
}

.summary-savings strong {
  color: var(--accent-2);
}

/* ============ Billboard carousel (Home hero) ============
   No `display` on .billboard itself, so the .hidden view toggle still wins. */
.billboard {
  position: relative;
  overflow: hidden;
}
.bb-slide {
  position: relative;
  display: flex;
  align-items: center;
  min-height: max(560px, 66vh);
  overflow: hidden;
  animation: bbFade 480ms ease;
}
@keyframes bbFade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes bbPulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.bb-ghost {
  position: absolute;
  right: 2vw;
  top: 46%;
  transform: translateY(-50%);
  font-family: var(--display);
  font-size: min(22vw, 320px);
  line-height: 0.8;
  color: rgba(246, 196, 69, 0.14);
  text-shadow: 0 0 90px rgba(246, 196, 69, 0.25);
  user-select: none;
  pointer-events: none;
}
.bb-fade {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 170px;
  background: linear-gradient(180deg, rgba(10, 12, 16, 0) 0%, rgba(10, 12, 16, 0.72) 92%);
}
.bb-inner { position: relative; z-index: 2; padding: 92px 4vw 68px; max-width: 940px; }
.bb-eyebrow {
  display: flex; align-items: center; gap: 9px;
  font-size: 12px; letter-spacing: 0.22em; font-weight: 700;
  color: var(--accent); text-transform: uppercase;
}
.bb-coin {
  width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none;
  background: radial-gradient(circle at 35% 30%, #FFE9A8, #F6C445 60%, #C89218);
  box-shadow: 0 0 10px rgba(246, 196, 69, 0.55);
  animation: bbPulse 2.6s ease infinite;
}
.bb-head { display: flex; align-items: flex-end; gap: 20px; margin-top: 14px; }
.bb-logo {
  position: relative; width: 72px; height: 72px; border-radius: 16px; overflow: hidden; flex: none;
  margin-bottom: 10px; border: 1px solid rgba(255, 255, 255, 0.2); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}
.bb-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 70%; max-height: 40px; object-fit: contain; }
.bb-logo-wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 30px; color: rgba(255, 255, 255, 0.94); }
.bb-title {
  margin: 0;
  font-family: var(--display); font-weight: 400;
  font-size: clamp(46px, 7vw, 108px); line-height: 0.92; letter-spacing: 0.012em;
}
@media (max-width: 760px) { .bb-logo { width: 50px; height: 50px; border-radius: 12px; } }
.bb-title .gold { color: var(--accent); text-shadow: 0 0 48px rgba(246, 196, 69, 0.4); }
.bb-pitch { margin: 16px 0 0; font-size: 15px; line-height: 1.6; color: #C6CEDA; max-width: 54ch; }
.bb-pitch strong { color: var(--accent); }
.bb-chips { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.bb-chip {
  border: 1px solid var(--border-strong); background: rgba(255, 255, 255, 0.06);
  border-radius: 999px; padding: 5px 12px; font-size: 12px; color: var(--text-2);
}
.bb-cta-row { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.bb-cta { padding: 13px 22px; font-size: 15px; display: inline-flex; align-items: center; gap: 9px; }
.bb-cta-est { background: rgba(35, 26, 4, 0.18); border-radius: 999px; padding: 2px 10px; font-size: 12.5px; }
.bb-fine { margin-top: 12px; font-size: 11px; color: var(--muted); max-width: 56ch; }
.bb-dots { display: flex; align-items: center; gap: 7px; margin-top: 18px; }
.bb-dot {
  width: 10px; height: 6px; border-radius: 999px; border: none; padding: 0; cursor: pointer;
  background: rgba(255, 255, 255, 0.28); transition: width 300ms ease, background 300ms ease;
}
.bb-dot.active { width: 26px; background: var(--accent); }
.bb-counter { font-size: 11px; color: var(--muted); margin-left: 8px; }
@media (max-width: 760px) {
  .bb-slide { min-height: 360px; }
  .bb-inner { padding: 26px 22px; }
  .bb-ghost { font-size: min(34vw, 200px); }
}

/* ============ My Subscriptions view ============ */
.view-title { font-family: var(--display); font-weight: 400; font-size: 46px; letter-spacing: 0.02em; line-height: 1; margin: 0; }
.subs-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 0.4rem; }
.subs-stats { display: flex; gap: 44px; flex-wrap: wrap; margin: 22px 0 8px; }
.subs-stat-num { font-family: var(--display); font-size: 34px; letter-spacing: 0.02em; line-height: 1; }
.subs-stat-num.warn { color: var(--warning-text, #FFB38A); }
.subs-stat-num.mint { color: var(--accent-2); }
.subs-stat-num.gold { color: var(--accent); }
.subs-stat-label { font-size: 12px; color: var(--muted); margin-top: 4px; }
.subs-note { margin: 0 0 22px; font-size: 11.5px; color: var(--faint); }
.subs-list { display: flex; flex-direction: column; gap: 12px; }
.subrow {
  display: flex; align-items: center; gap: 16px;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 14px 18px; transition: border-color 180ms ease, background 180ms ease;
}
.subrow:hover { border-color: rgba(246, 196, 69, 0.4); background: #161C26; }
.subrow-tile {
  position: relative; overflow: hidden;
  width: 44px; height: 44px; border-radius: 10px; flex: none;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-size: 20px; color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.subrow-wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.subrow-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 76%; max-height: 26px; object-fit: contain; }
.subrow-main { flex: 1; min-width: 0; }
.subrow-name { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; }
.subrow-plan { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.subrow-prog { width: 190px; flex: none; }
.subrow-bar { height: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.subrow-bar-fill { height: 100%; border-radius: 999px; }
.subrow-renew { font-size: 11.5px; margin-top: 6px; }
.subrow-price { width: 100px; text-align: right; flex: none; }
.subrow-price strong { font-size: 15px; }
.subrow-price span { font-size: 11px; color: var(--muted); }
.subrow-manage {
  flex: none; border: 1px solid rgba(246, 196, 69, 0.45); background: rgba(246, 196, 69, 0.08);
  color: var(--accent); border-radius: 999px; padding: 8px 16px; font-size: 12.5px; font-weight: 700;
  font-family: inherit; cursor: pointer; transition: background 160ms ease;
}
.subrow-manage:hover { background: rgba(246, 196, 69, 0.18); }
.subs-trust {
  margin-top: 18px; display: flex; align-items: center; gap: 10px;
  border: 1px solid var(--border); border-radius: 12px; padding: 13px 16px; background: rgba(255, 255, 255, 0.02);
}
.subs-trust svg { flex: none; }
.subs-trust span { font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) {
  .view-title { font-size: 38px; }
  .subs-stats { gap: 18px 30px; }
  .subrow { flex-wrap: wrap; row-gap: 10px; }
  .subrow-prog { order: 5; width: 100%; }
}

/* ============ Ranked "Top offers" row (Netflix ghost numerals) ============ */
.ranked-row { display: flex; gap: 14px; overflow-x: auto; padding: 16px 2px 20px; align-items: flex-end; scrollbar-width: none; }
.ranked-row::-webkit-scrollbar { display: none; }
.ranked { display: flex; align-items: flex-end; flex: 0 0 auto; }
.ranked-num {
  font-family: var(--display); font-size: 172px; line-height: 0.68;
  color: rgba(246, 196, 69, 0.13); text-shadow: 0 0 40px rgba(246, 196, 69, 0.1);
  margin-right: -30px; position: relative; z-index: 0; user-select: none;
}
.tile {
  position: relative; z-index: 1; flex: 0 0 auto; width: 290px; height: 190px;
  border-radius: 12px; overflow: hidden; cursor: pointer; padding: 0; font-family: inherit; text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}
.tile:hover { transform: scale(1.05) translateY(-6px); box-shadow: 0 20px 48px rgba(0, 0, 0, 0.55); border-color: rgba(246, 196, 69, 0.45); z-index: 4; }
.tile-wordmark {
  position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%);
  width: 86%; text-align: center; font-family: var(--display); font-size: 30px; letter-spacing: 0.08em;
  line-height: 0.95; color: rgba(255, 255, 255, 0.94); text-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}
.tile-chip {
  position: absolute; top: 9px; font-size: 10px; font-weight: 700; letter-spacing: 0.06em;
  border-radius: 999px; padding: 3px 8px; backdrop-filter: blur(4px); display: inline-flex; align-items: center; gap: 4px;
}
.tile-chip.save { left: 9px; background: rgba(6, 25, 18, 0.72); border: 1px solid rgba(44, 227, 160, 0.55); color: var(--accent-2); }
.tile-chip.reward { right: 9px; background: rgba(10, 8, 2, 0.6); border: 1px solid rgba(246, 196, 69, 0.45); color: var(--accent); }
.tile-chip.track { right: 9px; background: rgba(10, 12, 16, 0.6); border: 1px solid rgba(255, 255, 255, 0.22); color: #98A2B3; }
.tile-coin { width: 7px; height: 7px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #FFE9A8, #F6C445 60%, #C89218); display: inline-block; }
.tile-foot {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 34px 14px 11px;
  background: linear-gradient(180deg, rgba(6, 8, 11, 0) 0%, rgba(6, 8, 11, 0.9) 72%);
  display: flex; justify-content: space-between; align-items: flex-end; gap: 10px;
}
.tile-foot-main { min-width: 0; }
.tile-name { display: block; font-size: 15px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-plan { display: block; font-size: 11.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-price { font-size: 13px; font-weight: 700; color: #E7ECF3; white-space: nowrap; }
.tile-chip { font-size: 10.5px; padding: 4px 9px; }

/* Compact horizontal cards: Action this week (reminders) + Switch & save (alternatives) */
.mini-row { display: flex; flex-wrap: wrap; gap: 14px; padding: 8px 4vw 14px; }
.mini-card {
  display: flex; align-items: center; gap: 14px; flex: 1 1 360px; min-width: 300px;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px;
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.mini-card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45); border-color: rgba(246, 196, 69, 0.35); }
.mini-tile { position: relative; overflow: hidden; width: 40px; height: 40px; border-radius: 10px; flex: none; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 18px; color: #fff; border: 1px solid rgba(255, 255, 255, 0.1); }
.mini-wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.mini-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 76%; max-height: 24px; object-fit: contain; }
.mini-icon { width: 40px; height: 40px; border-radius: 10px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 700; }
.mini-icon.warn { background: rgba(255, 122, 47, 0.16); border: 1px solid rgba(255, 122, 47, 0.5); color: #FFB38A; }
.mini-icon.gold { background: rgba(246, 196, 69, 0.14); border: 1px solid rgba(246, 196, 69, 0.45); color: var(--accent); }
.mini-main { flex: 1; min-width: 0; }
.mini-title { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-sub { font-size: 12px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-chip { display: inline-block; margin-top: 6px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.04em; border-radius: 999px; padding: 3px 9px; }
.mini-chip.save { background: rgba(44, 227, 160, 0.14); color: var(--accent-2); border: 1px solid rgba(44, 227, 160, 0.4); }
.mini-btn { flex: none; padding: 8px 16px; font-size: 12.5px; }

/* Continue paying cards */
.cont-card {
  flex: 0 0 320px; width: 320px; text-align: left; font-family: inherit; cursor: pointer;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px;
  transition: transform 200ms ease, border-color 200ms ease, box-shadow 200ms ease;
}
.cont-card:hover { transform: translateY(-4px); border-color: rgba(246, 196, 69, 0.4); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45); }
.cont-head { display: flex; align-items: center; gap: 12px; }
.cont-logo { position: relative; width: 42px; height: 42px; border-radius: 10px; overflow: hidden; flex: none; border: 1px solid rgba(255, 255, 255, 0.1); }
.cont-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 74%; max-height: 26px; object-fit: contain; }
.cont-wordmark { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 18px; color: rgba(255, 255, 255, 0.94); }
.cont-main { flex: 1; min-width: 0; }
.cont-name { display: flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cont-plan { font-size: 12px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cont-price { text-align: right; flex: none; }
.cont-price strong { font-size: 14.5px; }
.cont-price span { font-size: 11px; color: var(--muted); }
.cont-bar { margin-top: 14px; height: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.cont-bar-fill { height: 100%; border-radius: 999px; }
.cont-foot { margin-top: 10px; display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 12px; }
.cont-relief { font-weight: 700; color: var(--accent); white-space: nowrap; }

/* Horizontal tile rows with scroll arrows (Top offers + marketplace categories) */
.row-scroll-wrap { position: relative; }
.tile-row {
  display: flex; gap: 16px; overflow-x: auto; padding: 16px 4vw 22px;
  align-items: flex-end; scrollbar-width: none; scroll-behavior: smooth;
}
.tile-row::-webkit-scrollbar { display: none; }
.tile-grid { display: flex; flex-wrap: wrap; gap: 16px; padding: 12px 4vw 22px; }

/* ============ Provider Finder (price-free, address-handoff) ============ */
.finder-list { display: flex; flex-direction: column; gap: 12px; padding: 12px 4vw 24px; max-width: 920px; }
.finder-card { display: flex; align-items: center; gap: 16px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.finder-logo { position: relative; overflow: hidden; width: 52px; height: 52px; border-radius: 12px; flex: none; border: 1px solid var(--border-strong); }
.finder-wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 24px; color: rgba(255, 255, 255, 0.94); }
.finder-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 76%; max-height: 30px; object-fit: contain; }
.finder-main { flex: 1 1 auto; min-width: 0; }
.finder-name { font-weight: 600; font-size: 1.02rem; color: var(--text); }
.finder-meta { font-size: 0.82rem; color: var(--muted); margin: 2px 0 6px; }
.finder-tier { color: var(--text-2); }
.finder-reward { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8rem; font-weight: 600; color: var(--accent); }
.finder-reward.track { color: var(--muted); font-weight: 500; }
.finder-cta { display: flex; flex-direction: column; gap: 6px; flex: none; align-items: stretch; }
.finder-btn { white-space: nowrap; }
.finder-details { font-size: 0.78rem; padding: 4px 10px; }
@media (max-width: 620px) {
  .finder-card { flex-wrap: wrap; }
  .finder-cta { flex-direction: row; width: 100%; }
  .finder-btn { flex: 1; }
}
.row-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 6;
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(10, 13, 18, 0.82); color: #E7ECF3;
  cursor: pointer; backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center;
  font-size: 22px; line-height: 1; transition: background 160ms ease, border-color 160ms ease;
}
.row-arrow:hover { background: rgba(22, 28, 37, 0.95); border-color: rgba(255, 255, 255, 0.32); }
.row-arrow.left { left: 8px; }
.row-arrow.right { right: 8px; }
.tile-logo {
  position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%);
  max-width: 58%; max-height: 62px; object-fit: contain; z-index: 2;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.5));
}
@media (max-width: 760px) { .row-arrow { display: none; } }

/* ============ Provider detail modal ============ */
.provider-dialog { width: min(560px, 96vw); max-height: 92vh; padding: 0; overflow: hidden; }
#providerContent { display: flex; flex-direction: column; max-height: 92vh; }
.pm-header { position: relative; height: 168px; flex: none; overflow: hidden; }
.pm-wordmark {
  position: absolute; left: 50%; top: 40%; transform: translate(-50%, -50%);
  font-family: var(--display); font-size: 40px; letter-spacing: 0.08em; color: rgba(255, 255, 255, 0.5); user-select: none;
}
.pm-close {
  position: absolute; top: 12px; right: 12px; z-index: 3; width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2); background: rgba(10, 13, 18, 0.6); color: #fff; cursor: pointer;
  font-size: 13px; backdrop-filter: blur(6px);
}
.pm-header-fade { position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(180deg, rgba(20, 25, 34, 0) 0%, #141922 96%); }
.pm-header-inner { position: absolute; left: 20px; right: 20px; bottom: 14px; z-index: 2; display: flex; align-items: flex-end; gap: 14px; }
.pm-logo { position: relative; overflow: hidden; width: 62px; height: 62px; border-radius: 14px; flex: none; border: 1px solid rgba(255, 255, 255, 0.14); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4); }
.pm-logo-wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 30px; color: rgba(255, 255, 255, 0.94); }
.pm-logo-img { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: 74%; max-height: 36px; object-fit: contain; }
.pm-header-text { min-width: 0; }
.pm-name { margin: 0; font-family: var(--display); font-weight: 400; font-size: 40px; letter-spacing: 0.02em; line-height: 1; }
.pm-chips { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 8px; }
.pm-chip { border: 1px solid var(--border-strong); background: rgba(255, 255, 255, 0.08); border-radius: 999px; padding: 4px 10px; font-size: 11.5px; color: var(--text-2); }
.pm-chip.warn { border-color: rgba(255, 122, 47, 0.5); color: #FFB38A; background: rgba(255, 122, 47, 0.12); }
.pm-body { padding: 16px 20px 22px; overflow-y: auto; }
.pm-promo { margin: 0 0 14px; font-size: 13.5px; line-height: 1.5; color: var(--text-2); }
.pm-section-label { font-size: 11px; letter-spacing: 0.16em; font-weight: 700; color: var(--muted); margin-bottom: 8px; }
.pm-banner { border-radius: 12px; padding: 14px 16px; font-size: 13.5px; line-height: 1.55; margin-bottom: 18px; }
.pm-banner.earn { border: 1px solid rgba(246, 196, 69, 0.4); background: rgba(246, 196, 69, 0.06); }
.pm-banner.track { border: 1px solid rgba(148, 163, 184, 0.3); background: rgba(148, 163, 184, 0.08); color: var(--text-2); }
.pm-earn-line { display: flex; align-items: center; gap: 7px; font-size: 15px; color: var(--accent); }
.pm-earn-line strong { color: var(--accent); }
.pm-earn-note { margin-top: 8px; font-size: 12px; color: var(--muted); }
.pm-fine { margin-top: 8px; font-size: 11px; color: var(--faint); }
.pm-cta-row { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.pm-yourplan { border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 12px; padding: 14px 16px; margin-bottom: 18px; }
.pm-plan-row { display: flex; justify-content: space-between; font-size: 14px; font-weight: 600; }
.bill-slider { width: 100%; margin: 6px 0; accent-color: var(--accent); }
.bill-readout { font-size: 12px; color: var(--muted); }
.bill-readout .bill-lefta, .bill-readout .bill-dollars { color: var(--accent); font-weight: 700; }
.pm-plans { display: flex; flex-direction: column; gap: 8px; }
.pm-plan { display: flex; align-items: center; justify-content: space-between; gap: 12px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; background: rgba(255, 255, 255, 0.02); }
.pm-plan-name { font-size: 13.5px; font-weight: 600; }
.pm-plan-price { font-size: 12px; color: var(--muted); margin-top: 2px; }
.pm-plan-btn { flex: none; padding: 7px 16px; font-size: 12.5px; }
.pm-footnote { margin: 16px 0 0; font-size: 11px; line-height: 1.5; color: var(--faint); }

/* Full-bleed sections (Netflix layout) — no box; children carry the 4vw gutter. */
.section {
  margin-top: 1.8rem;
  padding: 0;
  border: none;
  background: none;
}
.search-section,
#accountSetup {
  padding: 96px 4vw 0;
}

.hidden {
  display: none;
}

.setup-hidden {
  display: none;
}

.section-head {
  padding: 0 4vw;
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
  flex-wrap: wrap;
}
.section-head h3 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #EDF1F7;
}

.section-head p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}
.explore-all {
  margin-left: auto;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--muted);
  transition: color 160ms ease;
}
.explore-all:hover { color: var(--text); }

.row-scroller {
  margin-top: 0.7rem;
}

.carousel {
  margin-top: 0.7rem;
  display: flex;
  gap: 0.45rem;
  align-items: center;
}

.carousel.no-scroll .carousel-btn {
  display: none;
}

.carousel-track {
  flex: 1;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(270px, 310px);
  gap: 0.7rem;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  min-height: 100%;
  scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-btn {
  width: 34px;
  min-width: 34px;
  height: 100%;
  min-height: 42px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  color: #cfe7ff;
  font-size: 0.95rem;
  cursor: pointer;
}

.carousel-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.carousel-btn.is-hidden {
  display: none;
}

.grid-cards {
  margin-top: 0.65rem;
  display: grid;
  gap: 0.7rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.85rem;
  background: var(--card);
  transition: transform 200ms ease, border-color 200ms ease, box-shadow 200ms ease;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(246, 196, 69, 0.4);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.provider-badge {
  display: inline-flex;
  margin-bottom: 0.55rem;
  border-radius: 999px;
  padding: 0.2rem 0.48rem;
  font-size: 0.72rem;
  background: rgba(255, 255, 255, 0.08);
}

.provider-head {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.provider-logo {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--border);
  padding: 0.12rem;
}

.provider-logo-fallback {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
}

.card h4 {
  margin: 0;
  font-size: 1rem;
}

.meta-list {
  margin: 0.6rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.34rem;
}

.meta-list li {
  font-size: 0.82rem;
  color: #d5dff2;
}

.meta-list strong {
  color: var(--accent);
}

.card-actions {
  margin-top: 0.72rem;
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.btn {
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 0.5rem 0.85rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  transition: filter 160ms ease, background 160ms ease, border-color 160ms ease;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn.primary {
  background: var(--gold-grad);
  border: 0;
  color: var(--gold-ink);
  font-weight: 700;
  box-shadow: 0 6px 22px rgba(246, 196, 69, 0.22);
}

.btn.primary:hover {
  filter: brightness(1.08);
  background: var(--gold-grad);
}

.btn.ghost {
  background: rgba(255, 255, 255, 0.06);
}

.btn.critical {
  border-color: rgba(244, 72, 58, 0.45);
  color: var(--danger-text, #FF9C93);
  background: rgba(244, 72, 58, 0.1);
}

.plan-switcher {
  margin-top: 0.6rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  padding: 0.32rem 0.36rem;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.35rem;
}

.plan-switch-btn {
  padding: 0.24rem 0.48rem;
  min-width: 30px;
  font-size: 0.76rem;
  font-weight: 700;
}

.plan-counter {
  margin: 0;
  font-size: 0.76rem;
  color: #d5e7ff;
  text-align: center;
}

.plan-description {
  margin: 0.5rem 0 0;
  color: #bfcae3;
  font-size: 0.8rem;
  line-height: 1.45;
}

.search-form {
  margin-top: 0.3rem;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 0.65rem;
  align-items: end;
}

label {
  display: grid;
  gap: 0.35rem;
  font-size: 0.85rem;
}

input,
select {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  padding: 0.52rem 0.64rem;
  font: inherit;
}

.search-actions {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.ai-search-btn {
  background: linear-gradient(120deg, rgba(246, 196, 69, 0.22), rgba(246, 196, 69, 0.08));
  border-color: rgba(246, 196, 69, 0.5);
  color: var(--accent);
  font-weight: 700;
}

.ai-search-btn:hover {
  background: rgba(246, 196, 69, 0.28);
}

.ai-search-btn.loading {
  opacity: 0.6;
  cursor: wait;
}

.ai-search-status {
  margin-top: 0.5rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.ai-search-status:empty {
  display: none;
}

.assistant-narration {
  margin-top: 0.72rem;
  border: 1px solid rgba(246, 196, 69, 0.3);
  border-radius: 12px;
  background: rgba(246, 196, 69, 0.06);
  padding: 0.8rem 0.95rem;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-2);
}

.assistant-cards {
  margin-top: 0.7rem;
}

.ai-badge {
  display: inline-block;
  font-size: 0.65rem;
  padding: 0.12rem 0.38rem;
  border-radius: 999px;
  background: rgba(246, 196, 69, 0.18);
  color: var(--accent);
  margin-left: 0.4rem;
  vertical-align: middle;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-weight: 700;
}

.profile-form {
  margin-top: 0.35rem;
  display: grid;
  gap: 0.65rem;
  grid-template-columns: 1fr 1fr auto;
  align-items: end;
}

.profile-actions {
  display: flex;
  align-items: flex-end;
}

.profile-summary {
  margin: 0.5rem 0 0;
  color: #c8d8f3;
}

.search-summary {
  margin-top: 0.72rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  padding: 0.7rem;
  font-size: 0.84rem;
  color: #cad8f4;
}

.search-summary:empty {
  display: none;
}

.market-group {
  margin-top: 0.8rem;
}

.market-row-head {
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  align-items: baseline;
}

.market-row-title {
  margin: 0;
  font-size: 0.94rem;
}

.market-row-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
}

.empty-state {
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 0.9rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.pill {
  margin-top: 0.5rem;
  display: inline-block;
  border-radius: 999px;
  padding: 0.15rem 0.5rem;
  font-size: 0.74rem;
}

.pill-trial {
  background: rgba(255, 122, 47, 0.16);
  color: #FFB38A;
  border: 1px solid rgba(255, 122, 47, 0.5);
}

.pill-live {
  background: rgba(44, 227, 160, 0.14);
  color: #7FEEC4;
}

.pill-local {
  background: rgba(44, 227, 160, 0.14);
  color: #7FEEC4;
}

.pill-availability {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-2);
  border: 1px solid var(--border);
}

.pill-trackonly {
  background: rgba(148, 163, 184, 0.18);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.32);
}

.pill-cashback {
  background: rgba(246, 196, 69, 0.14);
  color: var(--accent);
  border: 1px solid rgba(246, 196, 69, 0.4);
}

.card-disclosure {
  margin: 0.6rem 0 0;
  font-size: 0.72rem;
  line-height: 1.45;
  color: var(--muted);
}

.card-disclosure a {
  color: var(--accent);
}

dialog {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 0;
  width: min(520px, 94vw);
  background: #141922;
  color: var(--text);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}

dialog h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.75rem;
  letter-spacing: 0.02em;
  line-height: 1;
}

dialog::backdrop {
  background: rgba(6, 8, 11, 0.7);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

dialog label {
  color: var(--text);
}

dialog input,
dialog select {
  background: var(--input, #141A23);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

dialog input:focus,
dialog select:focus {
  outline: none;
  border-color: rgba(246, 196, 69, 0.6);
  box-shadow: 0 0 0 3px rgba(246, 196, 69, 0.12);
}

dialog select option {
  background: var(--surface-2);
  color: var(--text);
}

#subscriptionForm,
#paymentForm {
  padding: 1rem;
  display: grid;
  gap: 0.65rem;
  background: #11151C;
  color: var(--text);
}

#subscriptionForm h3,
#paymentForm h3 {
  margin: 0 0 0.2rem;
  color: #edf5ff;
}

.muted {
  color: var(--muted);
}

.payment-provider-name {
  margin: 0;
  color: #d4e3ff;
  font-size: 0.84rem;
}

.payment-note {
  margin: 0;
  font-size: 0.8rem;
  color: #b9cae8;
}

.dialog-actions {
  display: flex;
  gap: 0.45rem;
}

.floating-add {
  position: fixed;
  bottom: calc(70px + env(safe-area-inset-bottom, 0px));
  right: 20px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 0;
  font-size: 1.55rem;
  color: var(--gold-ink);
  background: var(--gold-grad);
  box-shadow: 0 8px 30px rgba(246, 196, 69, 0.28);
  cursor: pointer;
  z-index: 9;
}

.toast {
  position: fixed;
  left: 50%;
  transform: translate(-50%, 8px);
  bottom: calc(80px + env(safe-area-inset-bottom, 0px));
  background: #12151C;
  border: 1px solid rgba(246, 196, 69, 0.5);
  border-radius: 999px;
  padding: 0.72rem 1.1rem;
  color: var(--text);
  font-size: 0.88rem;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
  z-index: 11;
}

.toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Bottom navigation — mobile only (desktop uses the header nav links) */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 70;
  display: none;
  justify-content: space-around;
  align-items: center;
  height: 60px;
  padding-bottom: env(safe-area-inset-bottom, 0px);
  border-top: 1px solid rgba(246, 196, 69, 0.16);
  background: rgba(10, 12, 16, 0.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.bottom-nav-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.18rem;
  background: none;
  border: none;
  color: var(--muted);
  font-family: inherit;
  font-size: 0.68rem;
  cursor: pointer;
  padding: 0.35rem 0.6rem;
  -webkit-tap-highlight-color: transparent;
}

.bottom-nav-tab.active {
  color: var(--accent);
}

.nav-icon {
  width: 22px;
  height: 22px;
}

/* Calendar view — contained, compact, 2-column (month grid + event rail) */
.cal-wrap { max-width: 1240px; margin: 0 auto; padding: 40px 4vw 0; }
.cal-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.cal-nav { display: flex; align-items: center; gap: 10px; }
.cal-nav-btn {
  width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-family: inherit; font-size: 18px; line-height: 1;
  border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(255, 255, 255, 0.05); color: #E7ECF3;
  transition: background 160ms ease;
}
.cal-nav-btn:hover { background: rgba(255, 255, 255, 0.12); }
.cal-month-label { font-size: 16px; font-weight: 700; min-width: 150px; text-align: center; }
.cal-legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 14px; }
.cal-leg { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-2); }
.cal-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.cal-dot.renew { background: #fff; }
.cal-dot.trial { background: var(--warning); }
.cal-dot.cashback { background: var(--accent); }
.cal-grid-wrap { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr); gap: 22px; margin-top: 22px; align-items: start; }
.cal-month { border: 1px solid var(--border); border-radius: 16px; background: var(--surface); padding: 18px; }
.cal-dow { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-dow span { text-align: center; font-size: 11px; letter-spacing: 0.14em; font-weight: 700; color: var(--faint); padding: 4px 0 8px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-cell {
  min-height: 74px; border-radius: 10px; border: 1px solid var(--border); background: rgba(255, 255, 255, 0.02);
  padding: 8px 9px; display: flex; flex-direction: column; gap: 5px; cursor: pointer; overflow: hidden;
  transition: border-color 160ms ease;
}
.cal-cell:hover { border-color: rgba(246, 196, 69, 0.35); }
.cal-cell.cal-empty { border: none; background: none; cursor: default; }
.cal-cell.cal-today { border-color: var(--accent); }
.cal-cell-top { display: flex; align-items: center; justify-content: space-between; }
.cal-day { font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.cal-today .cal-day { color: var(--accent); }
.cal-today-badge { font-size: 9px; font-weight: 700; letter-spacing: 0.1em; color: #231A04; background: var(--accent); border-radius: 999px; padding: 2px 6px; }
.cal-cell-events { display: flex; flex-direction: column; gap: 3px; }
.cal-ev-line { display: flex; align-items: center; gap: 5px; font-size: 10.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-ev-line .cal-dot { width: 6px; height: 6px; }
.cal-rail { display: flex; flex-direction: column; gap: 10px; }
.cal-rail-head { font-size: 12px; letter-spacing: 0.18em; font-weight: 700; color: var(--muted); }
.cal-ev-card { display: flex; align-items: center; gap: 13px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); padding: 12px 14px; }
.cal-ev-date { flex: none; width: 44px; text-align: center; border-right: 1px solid var(--border); padding-right: 11px; }
.cal-ev-d { display: block; font-family: var(--display); font-size: 22px; line-height: 1; color: var(--text); }
.cal-ev-m { display: block; font-size: 9.5px; letter-spacing: 0.12em; color: var(--muted); }
.cal-ev-main { flex: 1; min-width: 0; }
.cal-ev-title { display: flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; }
.cal-ev-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-amt { flex: none; font-size: 13px; font-weight: 700; }
.cal-amt.neg { color: var(--text-2); }
.cal-amt.pos { color: var(--accent); }
@media (max-width: 860px) { .cal-grid-wrap { grid-template-columns: 1fr; } }

/* Contain the non-Home views (Home stays full-bleed) */
#subsView, #accountContent { max-width: 1140px; margin: 0 auto; padding: 40px 4vw 0; }

/* Account view */
.account-section {
  padding: 1rem 0.5rem;
  border-bottom: 1px solid var(--border);
}

.account-section:last-child {
  border-bottom: none;
}

.account-section h3 {
  margin: 0 0 0.6rem;
  font-size: 1.04rem;
}

.account-lefta-display {
  font-family: var(--display);
  font-size: 3.4rem;
  letter-spacing: 0.02em;
  color: var(--accent);
  line-height: 1;
  text-shadow: 0 0 40px rgba(246, 196, 69, 0.28);
}

.account-lefta-sub {
  font-size: 0.88rem;
  color: var(--muted);
  margin-top: 0.2rem;
}

.account-logout-btn {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid rgba(239, 68, 68, 0.45);
  border-radius: 12px;
  background: rgba(239, 68, 68, 0.08);
  color: #fecaca;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 0.5rem;
}

.account-provider-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.4rem;
}

.account-provider-list li {
  font-size: 0.88rem;
  color: #d5dff2;
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

/* OAuth dialog */
.oauth-dialog {
  width: min(420px, 94vw);
}

.oauth-provider-header {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 1rem;
  border-bottom: 1px solid var(--border);
}

.oauth-provider-logo {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--border);
  padding: 0.15rem;
}

.oauth-provider-logo-fallback {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent);
}

.oauth-login-form {
  padding: 1rem;
  display: grid;
  gap: 0.65rem;
}

.oauth-login-form h3 {
  margin: 0;
  font-size: 1.04rem;
  color: #edf5ff;
}

.oauth-action-context {
  margin: 0;
  font-size: 0.84rem;
  color: var(--muted);
}

.oauth-disclaimer {
  margin: 0.5rem 0 0;
  font-size: 0.72rem;
  color: rgba(157, 173, 200, 0.7);
  line-height: 1.4;
}

/* Action confirmation dialog */
.action-confirm-dialog {
  width: min(480px, 94vw);
}

.action-confirm-content {
  padding: 1rem;
  display: grid;
  gap: 0.7rem;
}

.action-confirm-content h3 {
  margin: 0;
  font-size: 1.04rem;
  color: #edf5ff;
}

.action-account-info {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem;
  background: rgba(255, 255, 255, 0.03);
  display: grid;
  gap: 0.3rem;
  font-size: 0.84rem;
  color: #d5dff2;
}

.action-account-info strong {
  color: var(--accent);
}

.action-reward-preview {
  border: 1px solid rgba(246, 196, 69, 0.35);
  border-radius: 10px;
  padding: 0.7rem;
  background: rgba(246, 196, 69, 0.07);
  font-size: 0.88rem;
  color: var(--accent);
  font-weight: 600;
}

.action-confirm-note {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.45;
}

.btn.critical {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.45);
  color: #fecaca;
  font-weight: 600;
}

.btn.critical:hover {
  background: rgba(239, 68, 68, 0.22);
}

/* Cashout dialog */
.cashout-dialog {
  width: min(480px, 94vw);
}

#cashoutForm {
  padding: 1rem;
  display: grid;
  gap: 0.65rem;
  background: #11151C;
  color: var(--text);
}

#cashoutForm h3 {
  margin: 0 0 0.2rem;
  color: #edf5ff;
}

.cashout-balance-display {
  font-family: var(--display);
  font-size: 1.9rem;
  letter-spacing: 0.02em;
  color: var(--accent);
}

/* Bill-only redemption: the dialog picks which bill the Lefta pays toward. */
#cashoutForm label {
  display: grid;
  gap: 0.3rem;
  font-size: 0.85rem;
  color: var(--muted);
}

.cashout-note {
  margin: 0.1rem 0 0;
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--muted);
}

/* Virtual card display — gold Lefta card */
.virtual-card-display {
  background: radial-gradient(120% 140% at 12% 0%, #FFE9A8 0%, #F6C445 42%, #C89218 100%);
  border: 1px solid rgba(255, 233, 168, 0.6);
  border-radius: 16px;
  padding: 1.2rem;
  font-family: "Courier New", monospace;
  color: var(--gold-ink);
  position: relative;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 16px 44px rgba(246, 196, 69, 0.3);
}

.virtual-card-header {
  font-family: var(--display);
  font-size: 1.3rem;
  letter-spacing: 0.14em;
  color: var(--gold-ink);
  margin-bottom: 0.6rem;
}

.virtual-card-number {
  font-size: 1.3rem;
  letter-spacing: 0.15em;
  color: var(--gold-ink);
  font-weight: 700;
  margin-bottom: 0.7rem;
}

.virtual-card-row {
  display: flex;
  gap: 1.5rem;
  align-items: flex-end;
}

.virtual-card-field {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.virtual-card-field-label {
  font-size: 0.62rem;
  color: rgba(35, 26, 4, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-family: "Space Grotesk", sans-serif;
}

.virtual-card-field-value {
  font-size: 0.95rem;
  color: var(--gold-ink);
  font-weight: 600;
}

.virtual-card-amount {
  margin-top: 0.6rem;
  font-size: 0.82rem;
  color: var(--gold-ink);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
}

.copy-btn {
  background: rgba(35, 26, 4, 0.12);
  border: 1px solid rgba(35, 26, 4, 0.3);
  border-radius: 6px;
  color: rgba(35, 26, 4, 0.8);
  font-size: 0.68rem;
  padding: 0.15rem 0.35rem;
  cursor: pointer;
  margin-left: 0.35rem;
  font-family: "Space Grotesk", sans-serif;
}

.copy-btn:hover {
  background: rgba(35, 26, 4, 0.2);
  color: var(--gold-ink);
}

/* Cashout success */
.cashout-success {
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 10px;
  padding: 0.7rem;
  background: rgba(34, 197, 94, 0.06);
  font-size: 0.88rem;
  color: var(--accent-2);
  font-weight: 600;
}

.cashout-bank-confirm {
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 10px;
  padding: 0.8rem;
  background: rgba(34, 197, 94, 0.06);
  display: grid;
  gap: 0.3rem;
  font-size: 0.84rem;
  color: #d5dff2;
}

.cashout-bank-confirm strong {
  color: var(--accent-2);
}

/* Cashout history */
.cashout-history {
  margin-top: 0.6rem;
}

.cashout-history-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.82rem;
  color: #d5dff2;
}

.cashout-history-item:last-child {
  border-bottom: none;
}

/* Nav swap: desktop header links ↔ mobile bottom tab bar */
@media (max-width: 760px) {
  .dash-nav-links {
    display: none;
  }
  .bottom-nav {
    display: flex;
  }
  .dash-nav {
    gap: 12px;
  }
}

@media (max-width: 920px) {
  .search-form {
    grid-template-columns: 1fr;
  }

  .profile-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .summary-bar {
    flex-direction: column;
  }

  .cal-cell {
    min-height: 32px;
    font-size: 0.74rem;
  }

  .dialog-actions {
    flex-direction: column;
  }
}

@media (max-width: 620px) {
  .dialog-actions {
    flex-direction: column;
  }
}
