/* TurantBill — indigo + amber, desktop shell + mobile */
:root {
  --tb-ink: #0B1220;
  --tb-primary: #1E3A8A;
  --tb-primary-deep: #312E81;
  --tb-accent: #F59E0B;
  --tb-accent-soft: #FEF3C7;
  --tb-surface: #EEF2FF;
  --tb-card: #FFFFFF;
  --tb-muted: #64748B;
  --tb-line: #CBD5E1;
  --tb-danger: #B91C1C;
  --tb-ok: #0F766E;
  --tb-radius: 14px;
  --tb-font: "DM Sans", system-ui, sans-serif;
  --tb-display: "Fraunces", Georgia, serif;
  --tb-nav-h: 64px;
  --tb-top-h: 56px;
  --tb-sidebar-w: 240px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--tb-font);
  color: var(--tb-ink);
  background:
    radial-gradient(1200px 600px at 8% -8%, #312E8155, transparent 55%),
    radial-gradient(900px 500px at 100% 0%, #F59E0B28, transparent 45%),
    linear-gradient(165deg, #EEF2FF 0%, #F8FAFC 45%, #E2E8F0 100%);
  min-height: 100vh;
}
a { color: var(--tb-primary); text-decoration: none; }
.tb-main a:hover,
.tb-auth a:hover { color: var(--tb-primary-deep); }

.tb-shell { min-height: 100vh; width: 100%; }
.tb-authed .tb-shell { display: grid; grid-template-columns: 1fr; }

.tb-sidebar {
  display: none;
  flex-direction: column;
  background: linear-gradient(180deg, #0B1220 0%, #1E1B4B 100%);
  color: #E2E8F0;
  padding: 20px 16px;
  min-height: 100vh;
  width: var(--tb-sidebar-w);
  min-width: var(--tb-sidebar-w);
  max-width: var(--tb-sidebar-w);
  flex-shrink: 0;
  overflow-x: hidden;
  overflow-y: auto;
  box-sizing: border-box;
}
.tb-brand { font-family: var(--tb-display); font-weight: 700; letter-spacing: -0.02em; }
.tb-brand span { color: var(--tb-accent); }
.tb-brand-side { color: #F8FAFC !important; font-size: 1.45rem; margin-bottom: 4px; }
.tb-side-shop { color: #94A3B8; font-size: 0.8rem; margin: 0 0 20px; }
.tb-side-nav { display: grid; gap: 4px; flex: 1; align-content: start; }
.tb-side-nav a {
  color: #E2E8F0 !important;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  background: transparent;
}
.tb-side-nav a:hover,
.tb-side-nav a:focus-visible {
  background: rgba(245, 158, 11, 0.18) !important;
  color: #FFF7ED !important;
}
.tb-side-nav a.is-active {
  background: linear-gradient(135deg, #1E3A8A, #312E81) !important;
  color: #fff !important;
  box-shadow: inset 3px 0 0 var(--tb-accent);
}
.tb-side-nav a.is-active:hover {
  background: linear-gradient(135deg, #1E3A8A, #312E81) !important;
  color: #fff !important;
}
.tb-side-foot { display: grid; gap: 10px; margin-top: 16px; }
.tb-side-logout {
  background: transparent; border: 1px solid #334155; color: #94A3B8;
  border-radius: 999px; padding: 8px 12px; cursor: pointer; font: inherit;
}

.tb-app {
  min-height: 100vh;
  min-width: 0;
  width: 100%;
  position: relative;
  padding-bottom: calc(var(--tb-nav-h) + 12px);
  overflow-x: hidden;
}
.tb-top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  height: var(--tb-top-h); padding: 0 14px;
  background: color-mix(in srgb, #0B1220 90%, transparent);
  backdrop-filter: blur(12px); color: #E2E8F0;
}
.tb-brand-mobile { color: #F8FAFC !important; font-size: 1.2rem; }
.tb-menu-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border: 0; border-radius: 10px;
  background: #1E293B; color: #fff; font-size: 1.2rem; cursor: pointer;
}
.tb-top-right { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.tb-icon-link {
  width: 36px; height: 36px; border-radius: 999px; display: grid; place-items: center;
  background: var(--tb-accent); color: #0B1220 !important; font-weight: 800;
}

.tb-main { padding: 20px 16px 28px; max-width: 1100px; }
.tb-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  height: var(--tb-nav-h);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: #0B1220; border-top: 1px solid #1E293B;
}
.tb-nav a {
  display: flex; align-items: center; justify-content: center;
  color: #94A3B8; font-size: 0.78rem; font-weight: 700;
}
.tb-nav a.is-active { color: var(--tb-accent); }

.tb-sidebar-backdrop {
  position: fixed; inset: 0; background: rgba(11,18,32,0.45); z-index: 40;
}
body.tb-drawer-open .tb-sidebar {
  display: flex; position: fixed; inset: 0 auto 0 0; width: min(280px, 86vw); z-index: 50;
  animation: tb-slide 0.2s ease;
}

@keyframes tb-slide { from { transform: translateX(-12px); opacity: 0.6; } to { transform: none; opacity: 1; } }
@keyframes tb-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.tb-display {
  font-family: var(--tb-display); font-size: clamp(1.9rem, 4vw, 2.6rem);
  line-height: 1.08; margin: 0 0 8px; letter-spacing: -0.03em;
}
.tb-page-title { font-family: var(--tb-display); font-size: 1.7rem; margin: 0 0 6px; }
.tb-kicker {
  text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.7rem;
  color: var(--tb-primary); font-weight: 700; margin: 0 0 8px;
}
.tb-lead { color: var(--tb-muted); margin: 0 0 20px; font-size: 1.05rem; max-width: 42rem; }
.tb-lead-sm { color: var(--tb-muted); margin: 0 0 16px; }

.tb-dash {
  display: grid; gap: 18px;
  animation: tb-rise 0.45s ease both;
}
.tb-dash-hero {
  display: grid; gap: 16px;
  background: linear-gradient(135deg, #0B1220 0%, #1E3A8A 55%, #312E81 100%);
  color: #F8FAFC; border-radius: 22px; padding: 22px 20px;
  box-shadow: 0 30px 60px -36px #1E3A8Aaa;
  position: relative; overflow: hidden;
  align-items: stretch;
}
.tb-dash-hero::after {
  content: ""; position: absolute; right: -40px; top: -40px; width: 180px; height: 180px;
  border-radius: 50%; background: radial-gradient(circle, #F59E0B55, transparent 70%);
}
.tb-dash-hero .tb-kicker { color: #FCD34D; }
.tb-dash-hero .tb-lead { color: #C7D2FE; margin-bottom: 0; }
.tb-dash-actions { display: grid; gap: 10px; grid-template-columns: 1fr; }
.tb-cta {
  display: block; padding: 16px 16px; border-radius: var(--tb-radius);
  background: var(--tb-card); border: 1px solid var(--tb-line);
  box-shadow: 0 12px 28px -20px #1E3A8A88;
  transition: transform 0.15s ease, border-color 0.15s;
}
.tb-cta:hover { transform: translateY(-2px); border-color: var(--tb-primary); color: inherit; }
.tb-cta-primary {
  background: linear-gradient(135deg, var(--tb-accent), #D97706);
  border: none; color: #0B1220 !important;
}
.tb-cta-primary .tb-cta-sub { color: #78350F; }
.tb-cta-label { display: block; font-weight: 800; font-size: 1.1rem; }
.tb-cta-sub { display: block; font-size: 0.85rem; color: var(--tb-muted); margin-top: 4px; }

.tb-stat-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px;
}
.tb-stat-grid > div, .tb-panel {
  background: var(--tb-card); border-radius: 14px; padding: 14px;
  border: 1px solid var(--tb-line);
}
.tb-stat-label { font-size: 0.72rem; color: var(--tb-muted); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.tb-stat-value { font-size: 1.35rem; font-weight: 800; color: var(--tb-primary-deep); margin-top: 4px; }
.tb-panel-title { font-weight: 800; margin: 0 0 10px; font-size: 1rem; }
.tb-dash-split { display: grid; gap: 14px; }

.tb-form { display: grid; gap: 12px; }
.tb-field { display: grid; gap: 6px; font-size: 0.9rem; font-weight: 600; }
.tb-field span { color: var(--tb-muted); font-weight: 600; font-size: 0.8rem; }
input, select, textarea {
  width: 100%; border: 1px solid var(--tb-line); border-radius: 10px;
  padding: 12px; font: inherit; background: #fff; color: var(--tb-ink);
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid #F59E0B88; border-color: var(--tb-accent);
}

.tb-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--tb-line); background: #fff; color: var(--tb-ink);
  border-radius: 999px; padding: 11px 16px; font-weight: 700; cursor: pointer;
}
.tb-btn-accent {
  background: linear-gradient(135deg, var(--tb-accent), #D97706);
  border: none; color: #0B1220;
}
.tb-btn-primary {
  background: linear-gradient(135deg, var(--tb-primary), var(--tb-primary-deep));
  border: none; color: #fff;
}
.tb-btn-ghost { background: transparent; }
.tb-btn-block { width: 100%; }
.tb-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.tb-btn.is-listening {
  background: #FEE2E2; border-color: #FECACA; color: var(--tb-danger);
  animation: tb-pulse 1s ease infinite;
}
@keyframes tb-pulse { 50% { transform: scale(1.03); } }

.tb-chip {
  display: inline-flex; align-items: center; border-radius: 999px;
  padding: 6px 10px; font-size: 0.75rem; font-weight: 700;
  border: 1px solid transparent; background: #E2E8F0; color: var(--tb-ink);
}
.tb-chip-muted { background: #1E293B; color: #94A3B8; }
.tb-chip-amber { background: var(--tb-accent-soft); border-color: #F59E0B55; cursor: pointer; }
.tb-chip-ok { background: #CCFBF1; color: var(--tb-ok); }
.tb-chip-warn { background: #FEF3C7; color: #92400E; }
.tb-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; }
.tb-chips-label { width: 100%; font-size: 0.75rem; color: var(--tb-muted); font-weight: 700; }

.tb-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.tb-search-wrap { position: relative; }
.tb-suggest {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 15;
  background: #fff; border: 1px solid var(--tb-line); border-radius: 12px;
  box-shadow: 0 18px 40px -24px #0B1220aa; max-height: 280px; overflow: auto;
}
.tb-suggest button {
  display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; width: 100%;
  text-align: left; border: 0; background: transparent; padding: 10px 12px;
  border-bottom: 1px solid #F1F5F9; cursor: pointer; font: inherit;
}
.tb-suggest button:hover { background: #EEF2FF; }
.tb-suggest strong { font-size: 0.92rem; }
.tb-suggest em { font-style: normal; font-weight: 800; color: var(--tb-primary); }
.tb-suggest small { grid-column: 1; color: var(--tb-muted); }

.tb-bill-layout { display: grid; gap: 16px; }
.tb-lines { display: grid; gap: 10px; }
.tb-line-card {
  background: var(--tb-card); border: 1px solid var(--tb-line); border-radius: 12px; padding: 12px;
  display: grid; gap: 8px;
}
.tb-line-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tb-line-actions { display: flex; align-items: center; gap: 8px; }
.tb-line-actions .line-add { flex: 1; }
.tb-line-actions .line-remove {
  width: 40px; min-width: 40px; padding: 10px 0; font-size: 1.2rem; line-height: 1;
  color: var(--tb-muted);
}
.tb-opt { font-style: normal; font-weight: 500; color: var(--tb-muted); font-size: 0.75rem; }
.tb-totals {
  background: #0B1220; color: #E2E8F0; border-radius: 12px; padding: 14px;
  display: grid; gap: 8px; margin: 8px 0;
}
.tb-totals > div { display: flex; justify-content: space-between; }
.tb-totals-grand { color: var(--tb-accent); font-size: 1.15rem; }
.tb-pay {
  border: 1px solid var(--tb-line);
  border-radius: 12px;
  padding: 12px 14px;
  display: grid;
  gap: 10px;
  background: #fff;
}
.tb-pay legend { padding: 0 6px; font-weight: 700; }
.tb-pay label {
  font-weight: 600;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  margin: 0;
  line-height: 1.2;
  cursor: pointer;
}
.tb-pay input[type="radio"] {
  width: 16px;
  height: 16px;
  margin: 0;
  flex-shrink: 0;
  accent-color: var(--tb-primary);
}

.tb-modal {
  position: fixed; inset: 0; z-index: 60; display: grid; place-items: center;
  background: rgba(11,18,32,0.55); padding: 16px;
}
.tb-modal[hidden] { display: none !important; }
.tb-modal-card {
  width: min(520px, 100%); background: #fff; border-radius: 18px; padding: 18px;
  max-height: 85vh; overflow: auto;
}
.tb-modal-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.tb-voice-live {
  min-height: 72px; background: #0B1220; color: #E2E8F0; border-radius: 12px;
  padding: 12px; font-size: 0.95rem; margin: 10px 0;
}
.tb-photo-preview { width: 100%; max-height: 220px; object-fit: contain; border-radius: 12px; background: #0B1220; }

.tb-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; background: #fff; border-radius: 12px; overflow: hidden; }
.tb-table th { background: var(--tb-primary); color: #fff; text-align: left; padding: 8px; }
.tb-table td { padding: 8px; border-bottom: 1px solid var(--tb-line); vertical-align: top; }

.tb-list { list-style: none; padding: 0; margin: 12px 0; display: grid; gap: 8px; }
.tb-list a, .tb-list-static {
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto;
  gap: 2px 12px; padding: 12px; background: #fff; border-radius: 12px; border: 1px solid var(--tb-line);
  color: inherit;
}
.tb-list a strong, .tb-list-static strong { grid-column: 1; }
.tb-list a span, .tb-list-static span { grid-column: 1; color: var(--tb-muted); font-size: 0.85rem; }
.tb-list a em, .tb-list-static em { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-style: normal; font-weight: 700; }
.tb-debt { color: var(--tb-danger) !important; }
.tb-empty { color: var(--tb-muted); padding: 16px; text-align: center; }
.tb-section { font-size: 1.1rem; margin: 24px 0 8px; }
.tb-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.tb-row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.tb-muted-row { color: var(--tb-muted); font-size: 0.9rem; }
.tb-messages { padding: 8px 16px 0; }
.tb-flash { padding: 10px 12px; border-radius: 10px; margin-bottom: 8px; font-weight: 600; font-size: 0.9rem; }
.tb-flash-success { background: #CCFBF1; color: var(--tb-ok); }
.tb-flash-error { background: #FEE2E2; color: var(--tb-danger); }
.tb-error { color: var(--tb-danger); font-size: 0.85rem; }
.tb-pager { display: flex; gap: 10px; align-items: center; margin-top: 12px; }

/* ========== Auth (login / signup) — immersive TurantBill ========== */
body.tb-auth {
  background: #070B16;
}
body.tb-auth .tb-shell,
body.tb-auth .tb-app {
  min-height: 100vh;
  padding-bottom: 0;
  background: transparent;
}
body.tb-auth .tb-main {
  max-width: none;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: block;
  align-items: stretch;
}
body.tb-auth .tb-messages {
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  width: min(420px, calc(100% - 24px));
  padding: 0;
}

.tb-auth-stage {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 100vh;
  width: 100%;
}
.tb-auth-brand {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 500px at 10% 10%, rgba(245, 158, 11, 0.22), transparent 55%),
    radial-gradient(700px 480px at 90% 80%, rgba(49, 46, 129, 0.55), transparent 50%),
    linear-gradient(155deg, #0B1220 0%, #1E1B4B 42%, #1E3A8A 100%);
  color: #F8FAFC;
  padding: 36px 28px 48px;
  display: flex;
  align-items: center;
}
.tb-auth-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  pointer-events: none;
}
.tb-auth-orb-a {
  width: 280px; height: 280px; right: -60px; top: -40px;
  background: radial-gradient(circle, rgba(245,158,11,0.35), transparent 70%);
  animation: tb-float 8s ease-in-out infinite;
}
.tb-auth-orb-b {
  width: 220px; height: 220px; left: -50px; bottom: 10%;
  background: radial-gradient(circle, rgba(99,102,241,0.4), transparent 70%);
  animation: tb-float 10s ease-in-out infinite reverse;
}
@keyframes tb-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(18px); }
}
.tb-auth-brand-inner {
  position: relative;
  z-index: 1;
  width: min(480px, 100%);
  margin: 0 auto;
  animation: tb-rise 0.7s ease both;
}
.tb-auth-logo {
  display: inline-block;
  color: #F8FAFC !important;
  font-size: 1.7rem;
  margin-bottom: 18px;
}
.tb-auth-eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #FCD34D;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.tb-auth-headline {
  font-family: var(--tb-display);
  font-size: clamp(2.1rem, 5vw, 3.1rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 0 14px;
  font-weight: 700;
}
.tb-auth-copy {
  color: #C7D2FE;
  font-size: 1.05rem;
  line-height: 1.55;
  margin: 0 0 22px;
  max-width: 34rem;
}
.tb-auth-points {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: grid;
  gap: 10px;
}
.tb-auth-points li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  color: #E2E8F0;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 10px 12px;
}
.tb-auth-points li span {
  width: 28px; height: 28px; display: grid; place-items: center;
  border-radius: 8px; background: rgba(245,158,11,0.2);
}
.tb-auth-preview {
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 16px;
  padding: 14px 16px;
  backdrop-filter: blur(10px);
  box-shadow: 0 24px 50px -30px rgba(0,0,0,0.6);
}
.tb-auth-preview-top {
  display: flex; justify-content: space-between; align-items: center;
  color: #94A3B8; font-size: 0.8rem; font-weight: 700; margin-bottom: 10px;
}
.tb-auth-pill {
  background: linear-gradient(135deg, #F59E0B, #D97706);
  color: #0B1220;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
}
.tb-auth-preview-row,
.tb-auth-preview-total {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 8px 0;
  border-top: 1px solid rgba(148,163,184,0.15);
  font-size: 0.92rem;
}
.tb-auth-preview-total {
  color: #FCD34D;
  font-size: 1.05rem;
  border-top-color: rgba(245,158,11,0.35);
  margin-top: 4px;
}

.tb-auth-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 18px 40px;
  background:
    radial-gradient(600px 300px at 80% 0%, rgba(245,158,11,0.12), transparent 60%),
    linear-gradient(180deg, #F8FAFC 0%, #EEF2FF 100%);
}
.tb-auth-panel-card {
  width: min(420px, 100%);
  background: #fff;
  border: 1px solid #E2E8F0;
  border-radius: 24px;
  padding: 28px 24px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.8) inset,
    0 30px 60px -36px rgba(30, 58, 138, 0.45);
  animation: tb-rise 0.55s ease 0.08s both;
}
.tb-auth-panel-title {
  font-family: var(--tb-display);
  font-size: 1.85rem;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}
.tb-auth-panel-sub {
  color: var(--tb-muted);
  margin: 0 0 22px;
  font-size: 0.95rem;
}
.tb-auth-form .tb-field input,
.tb-auth-form .tb-field select,
.tb-auth-form .tb-field textarea {
  padding: 14px 14px;
  border-radius: 12px;
  border-color: #Dbe3f0;
  background: #F8FAFC;
}
.tb-auth-form .tb-field input:focus {
  background: #fff;
}
.tb-auth-submit {
  margin-top: 6px;
  padding: 14px 18px;
  font-size: 1.02rem;
  box-shadow: 0 12px 28px -12px rgba(217, 119, 6, 0.7);
}
.tb-auth-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid #E2E8F0;
  color: var(--tb-muted);
  font-size: 0.92rem;
}
.tb-auth-footer a {
  font-weight: 800;
  color: var(--tb-primary);
}
.tb-auth-trust {
  text-align: center;
  margin: 16px 0 0;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94A3B8;
}

/* ========== Dashboard pro extras ========== */
.tb-dash-pro { gap: 20px; }
.tb-dash-hero-glow {
  position: absolute;
  inset: auto -20% -40% 40%;
  height: 180px;
  background: radial-gradient(circle, rgba(245,158,11,0.35), transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.tb-dash-hero-copy { position: relative; z-index: 1; }
.tb-dash-hero-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.tb-dash-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.2);
  color: #FDE68A;
  font-size: 0.75rem;
  font-weight: 700;
}
.tb-dash-badge-soft {
  background: rgba(255,255,255,0.1);
  color: #C7D2FE;
}
.tb-dash-hero-cta {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 4px;
  align-content: center;
  padding: 16px 18px;
  border-radius: 16px;
  background: linear-gradient(135deg, #F59E0B, #D97706);
  color: #0B1220 !important;
  box-shadow: 0 18px 40px -20px rgba(245, 158, 11, 0.7);
  transition: transform 0.15s ease;
}
.tb-dash-hero-cta:hover { transform: translateY(-2px); color: #0B1220 !important; }
.tb-dash-hero-cta-kicker {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.75;
}
.tb-dash-hero-cta strong { font-size: 1.25rem; font-weight: 800; }
.tb-dash-hero-cta span:last-child { font-size: 0.85rem; font-weight: 600; opacity: 0.8; }

.tb-cta-ico {
  display: inline-grid;
  place-items: center;
  width: 32px; height: 32px;
  border-radius: 10px;
  background: rgba(30, 58, 138, 0.1);
  margin-bottom: 8px;
  font-weight: 800;
}
.tb-cta-primary .tb-cta-ico { background: rgba(11,18,32,0.12); }

.tb-stat-grid-pro > .tb-stat-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, #fff 0%, #F8FAFC 100%);
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 12px 28px -22px rgba(30,58,138,0.35);
}
.tb-stat-card::after {
  content: "";
  position: absolute;
  right: -10px; top: -10px;
  width: 70px; height: 70px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(49,46,129,0.12), transparent 70%);
}
.tb-stat-cash::after { background: radial-gradient(circle, rgba(15,118,110,0.15), transparent 70%); }
.tb-stat-upi::after { background: radial-gradient(circle, rgba(245,158,11,0.2), transparent 70%); }
.tb-stat-foot {
  margin-top: 6px;
  font-size: 0.72rem;
  color: var(--tb-muted);
  font-weight: 600;
}

.tb-panel-pro {
  box-shadow: 0 16px 36px -28px rgba(15, 23, 42, 0.35);
  border-radius: 16px;
}
.tb-panel-memory {
  background: linear-gradient(180deg, #FFFBEB 0%, #fff 40%);
  border-color: #FDE68A;
}
.tb-link-pill {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--tb-primary);
}
.tb-list-pro a {
  transition: border-color 0.15s, transform 0.15s;
}
.tb-list-pro a:hover {
  border-color: #93C5FD;
  transform: translateY(-1px);
  color: inherit;
}

@media (min-width: 900px) {
  .tb-auth-stage {
    grid-template-columns: 1.08fr 0.92fr;
  }
  .tb-auth-brand { padding: 48px 56px; }
  .tb-auth-panel { padding: 40px; }
  .tb-dash-hero {
    grid-template-columns: 1.45fr 0.65fr;
    align-items: stretch;
    padding: 28px 26px;
  }
  .tb-authed .tb-shell {
    grid-template-columns: var(--tb-sidebar-w) minmax(0, 1fr);
  }
  .tb-sidebar {
    display: flex;
    position: sticky;
    top: 0;
    height: 100vh;
    width: var(--tb-sidebar-w) !important;
    min-width: var(--tb-sidebar-w) !important;
    max-width: var(--tb-sidebar-w) !important;
  }
  body.tb-drawer-open .tb-sidebar {
    position: sticky;
    width: var(--tb-sidebar-w) !important;
    animation: none;
  }
  .tb-sidebar-backdrop, .tb-menu-btn, .tb-brand-mobile, .tb-nav, #tb-sync-chip-mobile { display: none !important; }
  .tb-app { padding-bottom: 24px; min-width: 0; }
  .tb-top { display: none; }
  .tb-main { padding: 28px 32px 40px; max-width: none; min-width: 0; }
  .tb-dash-actions { grid-template-columns: repeat(3, 1fr); }
  .tb-stat-grid { grid-template-columns: repeat(4, 1fr); }
  .tb-dash-split { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
  .tb-bill-layout { grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.9fr); align-items: start; }
  .tb-bill-side { position: sticky; top: 24px; min-width: 0; }
  .tb-bill-main { min-width: 0; }
  .tb-line-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* —— Plan & Billing —— */
.tb-plan-strip {
  margin: 0 16px;
  padding: 0.65rem 1rem;
  border-radius: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 600;
}
.tb-plan-strip.is-warn {
  background: #FEF3C7;
  color: #92400E;
  border: 1px solid #F59E0B55;
}
.tb-plan-strip.is-danger {
  background: #FEE2E2;
  color: #991B1B;
  border: 1px solid #FECACA;
}
.tb-plan-strip a { font-weight: 700; color: inherit; text-decoration: underline; }

.tb-plan-page { max-width: 920px; display: grid; gap: 1.25rem; }
.tb-plan-hero h1 {
  margin: 0.2rem 0 0.35rem;
  font-family: var(--tb-display);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
}
.tb-eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--tb-primary);
}
.tb-muted { color: var(--tb-muted); margin: 0; }
.tb-small { font-size: 0.82rem; }

.tb-plan-banner {
  padding: 0.85rem 1rem;
  border-radius: 12px;
  font-size: 0.92rem;
}
.tb-plan-banner.is-warn { background: #FEF3C7; color: #92400E; }
.tb-plan-banner.is-danger { background: #FEE2E2; color: #991B1B; }
.tb-plan-banner.is-info { background: #EEF2FF; color: #1E3A8A; }

.tb-plan-status {
  background: var(--tb-card);
  border: 1px solid var(--tb-line);
  border-radius: 18px;
  padding: 1.25rem;
  box-shadow: 0 16px 36px -28px rgba(30, 58, 138, 0.4);
}
.tb-plan-status-top {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
  margin-bottom: 1rem;
}
.tb-plan-label { margin: 0; font-size: 0.75rem; font-weight: 700; color: var(--tb-muted); text-transform: uppercase; letter-spacing: 0.06em; }
.tb-plan-name { margin: 0.2rem 0 0; font-family: var(--tb-display); font-size: 1.75rem; }
.tb-plan-name-silver { color: #64748B; }
.tb-plan-name-gold { color: #B45309; }

.tb-plan-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.85rem;
}
.tb-plan-facts > div {
  background: var(--tb-surface);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  display: grid;
  gap: 0.2rem;
}
.tb-plan-facts span { font-size: 0.78rem; color: var(--tb-muted); }
.tb-plan-facts strong { font-size: 1.05rem; }

.tb-plan-alert {
  margin: 1rem 0 0;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  font-size: 0.9rem;
}
.tb-plan-alert.is-danger { background: #FEE2E2; color: #991B1B; }
.tb-plan-alert.is-warn { background: #FEF3C7; color: #92400E; }
.tb-plan-alert.is-info { background: #EEF2FF; color: #1E3A8A; }

.tb-plan-note {
  background: linear-gradient(135deg, #EEF2FF, #FFFBEB);
  border: 1px solid #C7D2FE;
  border-radius: 16px;
  padding: 1.1rem 1.25rem;
}
.tb-plan-note h3 { margin: 0 0 0.5rem; font-size: 1rem; }
.tb-plan-note ul { margin: 0; padding-left: 1.1rem; display: grid; gap: 0.4rem; color: #334155; font-size: 0.92rem; }

.tb-plan-section-title {
  margin: 0.5rem 0 0;
  font-family: var(--tb-display);
  font-size: 1.35rem;
}

.tb-plan-chooser { display: grid; gap: 1rem; }
.tb-plan-chooser > input { position: absolute; opacity: 0; pointer-events: none; }
.tb-plan-cycle {
  display: inline-flex;
  background: #fff;
  border: 1px solid var(--tb-line);
  border-radius: 999px;
  padding: 4px;
  gap: 2px;
  width: fit-content;
}
.tb-plan-cycle label {
  padding: 0.45rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--tb-muted);
}
#cycle-monthly:checked ~ .tb-plan-cycle label[for="cycle-monthly"],
#cycle-yearly:checked ~ .tb-plan-cycle label[for="cycle-yearly"] {
  background: var(--tb-primary);
  color: #fff;
}

.tb-plan-grid {
  display: grid;
  gap: 1rem;
}
.tb-plan-card {
  background: #fff;
  border: 1px solid var(--tb-line);
  border-radius: 18px;
  padding: 1.25rem;
  display: grid;
  gap: 0.55rem;
  box-shadow: 0 14px 32px -26px rgba(15, 23, 42, 0.35);
}
.tb-plan-card.is-current { border-color: #93C5FD; }
.tb-plan-card-gold {
  background: linear-gradient(180deg, #FFFBEB 0%, #fff 48%);
  border-color: #F59E0B88;
}
.tb-plan-card-head {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: center;
}
.tb-plan-card h3 { margin: 0; font-size: 1.25rem; }
.tb-plan-price {
  margin: 0.2rem 0 0;
  font-family: var(--tb-display);
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
}
.tb-plan-price span { font-family: var(--tb-font); font-size: 0.95rem; color: var(--tb-muted); font-weight: 600; }
.tb-plan-features {
  margin: 0.3rem 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.35rem;
}
.tb-plan-features li {
  position: relative;
  padding-left: 1rem;
  font-size: 0.92rem;
  color: #334155;
}
.tb-plan-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--tb-accent);
}
.tb-plan-pay { margin-top: 0.35rem; }
.tb-plan-pay .tb-btn { width: 100%; justify-content: center; }

.tb-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.tb-pill-ok { background: #CCFBF1; color: #0F766E; }
.tb-pill-amber { background: #FEF3C7; color: #B45309; }
.tb-pill-danger { background: #FEE2E2; color: #B91C1C; }

.tb-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.7rem 1.1rem;
  border-radius: 12px;
  border: 1.5px solid var(--tb-primary);
  background: transparent;
  color: var(--tb-primary);
  font-weight: 700;
  cursor: pointer;
  font: inherit;
}
.tb-btn-ghost {
  display: inline-flex;
  padding: 0.65rem 1rem;
  color: var(--tb-muted);
  font-weight: 600;
}
.tb-btn-lg { padding: 0.85rem 1.35rem; font-size: 1.05rem; }

.tb-plan-how ol { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.35rem; color: #334155; }

.tb-table-wrap { overflow-x: auto; border: 1px solid var(--tb-line); border-radius: 14px; background: #fff; }
.tb-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.tb-table th, .tb-table td { padding: 0.75rem 0.9rem; text-align: left; border-bottom: 1px solid var(--tb-line); }
.tb-table th { background: var(--tb-surface); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--tb-muted); }
.tb-table .tb-num { text-align: right; font-variant-numeric: tabular-nums; }
.tb-empty { color: var(--tb-muted); text-align: center; }

.tb-checkout-card, .tb-pay-result {
  background: #fff;
  border: 1px solid var(--tb-line);
  border-radius: 18px;
  padding: 1.5rem;
  max-width: 520px;
  display: grid;
  gap: 0.85rem;
  box-shadow: 0 18px 40px -28px rgba(30, 58, 138, 0.4);
}
.tb-checkout-summary {
  display: grid;
  gap: 0.65rem;
}
.tb-checkout-summary > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--tb-line);
}
.tb-checkout-summary span { color: var(--tb-muted); font-size: 0.88rem; }
.tb-money { color: var(--tb-primary-deep); }

.tb-pay-result { text-align: center; justify-items: center; }
.tb-pay-result h1 { margin: 0; font-family: var(--tb-display); }
.tb-pay-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  font-weight: 700;
}
.tb-pay-result.is-ok .tb-pay-icon { background: #CCFBF1; color: #0F766E; }
.tb-pay-result.is-fail .tb-pay-icon { background: #FEE2E2; color: #B91C1C; }
.tb-pay-actions { display: flex; flex-wrap: wrap; gap: 0.65rem; justify-content: center; }

@media (min-width: 760px) {
  .tb-plan-facts { grid-template-columns: repeat(4, 1fr); }
  .tb-plan-grid { grid-template-columns: repeat(2, 1fr); }
  .tb-plan-strip { margin: 0 32px; }
}


