/* VertoCRM — app.css */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&display=swap');

/* ============================================================
   CSS VARIABLES
============================================================ */
:root {
  --bg:    #080C18;
  --bg2:   #0E1425;
  --bg3:   #141928;
  --card:  #111827;
  --bor:   #1E2A3D;
  --bor2:  #263347;
  --tx:    #E8EDF5;
  --tx2:   #B0BCCE;
  --mu:    #6B7A8F;
  --acc:   #3B82F6;
  --acc2:  #2563EB;
  --accs:  rgba(59,130,246,.12);
  --gr:    #22C55E;
  --grs:   rgba(34,197,94,.12);
  --re:    #F87171;
  --res:   rgba(248,113,113,.12);
  --ye:    #FBBF24;
  --yes:   rgba(251,191,36,.12);
  --pu:    #A78BFA;
  --pus:   rgba(167,139,250,.12);
  --cy:    #22D3EE;
  --cys:   rgba(34,211,238,.12);
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(0,0,0,.35);
  --shadow-lg: 0 8px 40px rgba(0,0,0,.5);
  --font: 'DM Sans', sans-serif;
  --font-display: 'Syne', sans-serif;
  --sb-w: 220px;
  --hdr-h: 56px;
  --bnav-h: 64px;
  --trans: .18s cubic-bezier(.4,0,.2,1);
}

/* ============================================================
   RESET & BASE
============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--tx);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font-family: inherit; }
a { color: var(--acc); text-decoration: none; }
a:hover { text-decoration: underline; }
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bor2); border-radius: 99px; }

/* ============================================================
   SCREENS
============================================================ */
.screen {
  position: fixed; inset: 0;
  display: none; flex-direction: column;
  background: var(--bg);
  z-index: 10;
}

/* ============================================================
   LOADING
============================================================ */
#loading-screen {
  align-items: center; justify-content: center;
  gap: 20px;
}
.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--bor);
  border-top-color: var(--acc);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   AUTH
============================================================ */
#auth-screen {
  align-items: center; justify-content: center;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(59,130,246,.08) 0%, transparent 70%), var(--bg);
  overflow-y: auto;
  padding: 20px;
}
.auth-box {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: 20px;
  padding: 32px 28px;
  width: 100%; max-width: 400px;
  box-shadow: var(--shadow-lg);
}

/* ============================================================
   INPUTS / FORM ELEMENTS
============================================================ */
.lbl {
  display: block;
  font-size: 12px; font-weight: 600;
  color: var(--tx2);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.inp {
  width: 100%;
  background: var(--bg2);
  border: 1px solid var(--bor);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  color: var(--tx);
  font-size: 14px;
  transition: border-color var(--trans), box-shadow var(--trans);
  outline: none;
}
.inp:focus { border-color: var(--acc); box-shadow: 0 0 0 3px var(--accs); }
.inp::placeholder { color: var(--mu); }
select.inp { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B7A8F' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }
textarea.inp { resize: vertical; min-height: 80px; }

/* ============================================================
   BUTTONS
============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border-radius: var(--radius-sm);
  padding: 9px 16px;
  font-size: 13px; font-weight: 600;
  transition: all var(--trans);
  white-space: nowrap;
}
.btn-p {
  background: var(--acc);
  color: #fff;
  box-shadow: 0 2px 12px rgba(59,130,246,.3);
}
.btn-p:hover { background: var(--acc2); transform: translateY(-1px); box-shadow: 0 4px 20px rgba(59,130,246,.4); }
.btn-p:active { transform: translateY(0); }
.btn-s {
  background: var(--bg2);
  color: var(--tx2);
  border: 1px solid var(--bor);
}
.btn-s:hover { border-color: var(--bor2); color: var(--tx); background: var(--bg3); }
.btn-g { background: var(--grs); color: var(--gr); border: 1px solid rgba(34,197,94,.2); }
.btn-g:hover { background: rgba(34,197,94,.2); }
.btn-r { background: var(--res); color: var(--re); border: 1px solid rgba(248,113,113,.2); }
.btn-r:hover { background: rgba(248,113,113,.2); }
.btn-x { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px; border-radius: 6px; font-size: 13px; color: var(--mu); transition: color var(--trans), background var(--trans); }
.btn-x:hover { color: var(--tx); background: var(--bg3); }
.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-icon { width: 34px; height: 34px; padding: 0; border-radius: var(--radius-sm); }

/* ============================================================
   TRIAL BANNER
============================================================ */
#trial-banner {
  background: linear-gradient(90deg, rgba(251,191,36,.15) 0%, rgba(251,191,36,.05) 100%);
  border-bottom: 1px solid rgba(251,191,36,.2);
  color: var(--ye);
  font-size: 12px; font-weight: 600;
  text-align: center;
  padding: 7px 16px;
  display: none;
}

/* ============================================================
   SIDEBAR
============================================================ */
#sb {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--sb-w);
  background: var(--bg2);
  border-right: 1px solid var(--bor);
  display: flex; flex-direction: column;
  z-index: 100;
  overflow-y: auto;
}
#app-screen { display: none; flex-direction: row; }

/* ============================================================
   MAIN WRAP
============================================================ */
#main-wrap {
  position: fixed;
  top: 0; bottom: 0;
  left: var(--sb-w); right: 0;
  overflow-y: auto;
  padding-bottom: 20px;
  background: var(--bg);
}
#main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 24px;
  animation: fadeIn .25s ease;
}
@keyframes fadeIn { from { opacity:0; transform:translateY(8px); } to { opacity:1; transform:none; } }

/* ============================================================
   MOBILE HEADER
============================================================ */
#mhdr {
  display: none;
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--hdr-h);
  background: var(--bg2);
  border-bottom: 1px solid var(--bor);
  padding: 0 16px;
  align-items: center;
  justify-content: space-between;
  z-index: 200;
}

/* ============================================================
   BOTTOM NAV (mobile)
============================================================ */
#bnav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0;
  height: var(--bnav-h);
  background: var(--bg2);
  border-top: 1px solid var(--bor);
  z-index: 200;
  padding: 0 4px 8px;
  align-items: flex-end;
  justify-content: space-around;
}
.bnv {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 6px 12px;
  border-radius: 10px;
  font-size: 10px; font-weight: 600;
  color: var(--mu);
  transition: all var(--trans);
  flex: 1;
  min-width: 0;
  cursor: pointer;
}
.bnv .bnv-ic { font-size: 20px; line-height: 1; }
.bnv.active { color: var(--acc); background: var(--accs); }

/* ============================================================
   DRAWER (mobile)
============================================================ */
#dov {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.6); z-index: 300;
  backdrop-filter: blur(2px);
}
#dr {
  position: fixed; top: 0; bottom: 0; left: -280px;
  width: 260px;
  background: var(--bg2);
  border-right: 1px solid var(--bor);
  z-index: 400;
  display: flex; flex-direction: column;
  transition: left .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}
#dr.open { left: 0; }

/* ============================================================
   NAV ITEMS
============================================================ */
.nv {
  display: flex; align-items: center; gap: 10px;
  width: 100%; padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 600;
  color: var(--mu);
  transition: all var(--trans);
  text-align: left;
}
.nv:hover { color: var(--tx); background: var(--bg3); }
.nv.active { color: var(--acc); background: var(--accs); }
.nv.sm { font-size: 12px; padding: 8px 12px; }
.nv .badge {
  margin-left: auto;
  background: var(--acc);
  color: #fff;
  font-size: 10px; font-weight: 700;
  border-radius: 99px;
  padding: 1px 6px;
}

/* ============================================================
   COMM PILL
============================================================ */
#comm-pill, #comm-pill2 {
  background: var(--grs);
  border: 1px solid rgba(34,197,94,.15);
  border-radius: 10px;
}
.comm-lbl { font-size: 10px; color: var(--mu); font-weight: 600; text-transform: uppercase; letter-spacing:.04em; margin-bottom:2px; }
.comm-val { font-size: 16px; font-weight: 800; color: var(--gr); font-family: var(--font-display); }

/* ============================================================
   PAGE HEADER
============================================================ */
.pg-hdr {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 24px; gap: 12px; flex-wrap: wrap;
}
.pg-title {
  font-family: var(--font-display);
  font-size: 22px; font-weight: 800;
  color: var(--tx);
}
.pg-sub { font-size: 13px; color: var(--mu); margin-top: 2px; }

/* ============================================================
   CARDS
============================================================ */
.card {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: var(--radius);
  padding: 20px;
}
.card-sm { padding: 14px 16px; }

/* ============================================================
   STAT CARDS (dashboard)
============================================================ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: var(--radius);
  padding: 16px 18px;
  transition: border-color var(--trans), transform var(--trans);
}
.stat-card:hover { border-color: var(--bor2); transform: translateY(-2px); }
.stat-ic { font-size: 22px; margin-bottom: 8px; }
.stat-val { font-size: 24px; font-weight: 800; font-family: var(--font-display); color: var(--tx); line-height: 1; }
.stat-lbl { font-size: 11px; color: var(--mu); font-weight: 600; margin-top: 4px; text-transform: uppercase; letter-spacing: .04em; }
.stat-delta { font-size: 11px; font-weight: 700; margin-top: 6px; }
.stat-delta.up { color: var(--gr); }
.stat-delta.dn { color: var(--re); }

/* ============================================================
   TABLE
============================================================ */
.tbl-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--bor); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead tr { background: var(--bg2); }
th { padding: 11px 14px; text-align: left; font-size: 11px; font-weight: 700; color: var(--mu); text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; border-bottom: 1px solid var(--bor); }
td { padding: 12px 14px; border-bottom: 1px solid var(--bor); color: var(--tx2); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr { transition: background var(--trans); }
tbody tr:hover { background: var(--bg2); }
.td-main { color: var(--tx); font-weight: 600; }
.td-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* ============================================================
   BADGES / TAGS
============================================================ */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 9px; border-radius: 99px;
  font-size: 11px; font-weight: 700;
  white-space: nowrap;
}
.badge-blue { background: var(--accs); color: var(--acc); }
.badge-green { background: var(--grs); color: var(--gr); }
.badge-red { background: var(--res); color: var(--re); }
.badge-yellow { background: var(--yes); color: var(--ye); }
.badge-purple { background: var(--pus); color: var(--pu); }
.badge-cyan { background: var(--cys); color: var(--cy); }
.badge-gray { background: rgba(107,122,143,.12); color: var(--mu); }

/* ============================================================
   SEARCH BAR
============================================================ */
.search-bar {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg2);
  border: 1px solid var(--bor);
  border-radius: var(--radius-sm);
  padding: 0 12px;
  flex: 1; max-width: 340px;
}
.search-bar input {
  flex: 1; background: none; border: none; outline: none;
  color: var(--tx); font-size: 13px; padding: 9px 0;
}
.search-bar input::placeholder { color: var(--mu); }

/* ============================================================
   FILTERS ROW
============================================================ */
.filters {
  display: flex; gap: 8px; align-items: center;
  flex-wrap: wrap; margin-bottom: 16px;
}

/* ============================================================
   MODAL
============================================================ */
#modal {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.6);
  z-index: 500;
  align-items: center; justify-content: center;
  padding: 16px;
  backdrop-filter: blur(4px);
}
#modal.open { display: flex; }
#modal-box {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: 16px;
  padding: 24px;
  width: 100%; max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: modalIn .2s cubic-bezier(.34,1.56,.64,1);
}
@keyframes modalIn { from { opacity:0; transform:scale(.94) translateY(12px); } to { opacity:1; transform:none; } }

/* ============================================================
   TOAST
============================================================ */
#toast {
  position: fixed; bottom: 80px; left: 50%; transform: translateX(-50%);
  z-index: 999;
  display: flex; flex-direction: column; gap: 8px;
  pointer-events: none;
}
.toast-item {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: 10px;
  padding: 10px 18px;
  font-size: 13px; font-weight: 600;
  box-shadow: var(--shadow);
  animation: toastIn .3s ease;
  white-space: nowrap;
}
.toast-item.success { border-color: rgba(34,197,94,.3); color: var(--gr); }
.toast-item.error { border-color: rgba(248,113,113,.3); color: var(--re); }
.toast-item.info { border-color: rgba(59,130,246,.3); color: var(--acc); }
@keyframes toastIn { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:none; } }

/* ============================================================
   EMPTY STATE
============================================================ */
.empty {
  text-align: center; padding: 56px 20px;
  color: var(--mu);
}
.empty-ic { font-size: 48px; margin-bottom: 12px; }
.empty-title { font-size: 16px; font-weight: 700; color: var(--tx2); margin-bottom: 6px; }
.empty-sub { font-size: 13px; color: var(--mu); }

/* ============================================================
   SECTION TITLE
============================================================ */
.sec-title {
  font-family: var(--font-display);
  font-size: 14px; font-weight: 700;
  color: var(--tx2);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 14px;
  display: flex; align-items: center; gap: 8px;
}
.sec-title::after { content:''; flex:1; height:1px; background:var(--bor); }

/* ============================================================
   GRID LAYOUTS
============================================================ */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.col-span-2 { grid-column: span 2; }

/* ============================================================
   FORM GRID
============================================================ */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .full { grid-column: 1/-1; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--bor); }

/* ============================================================
   AGENDA / CALENDAR
============================================================ */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}
.cal-day {
  aspect-ratio: 1;
  display: flex; flex-direction: column;
  align-items: center; justify-content: flex-start;
  padding: 6px 4px;
  border-radius: 8px;
  font-size: 12px;
  cursor: pointer;
  transition: background var(--trans);
  min-height: 60px;
}
.cal-day:hover { background: var(--bg3); }
.cal-day.today { background: var(--accs); color: var(--acc); font-weight: 700; }
.cal-day.other-month { opacity: .35; }
.cal-day .day-num { font-weight: 700; margin-bottom: 2px; font-size: 13px; }
.cal-day .ev-dot { width: 5px; height: 5px; border-radius: 50%; margin: 1px auto; }
.cal-hdr { display: grid; grid-template-columns: repeat(7,1fr); gap: 3px; margin-bottom: 6px; }
.cal-hdr-day { text-align: center; font-size: 11px; font-weight: 700; color: var(--mu); padding: 4px; text-transform: uppercase; letter-spacing: .04em; }

.appt-item {
  background: var(--bg2);
  border: 1px solid var(--bor);
  border-left: 3px solid var(--acc);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all var(--trans);
}
.appt-item:hover { border-color: var(--bor2); transform: translateX(3px); }
.appt-item.realizado { border-left-color: var(--gr); }
.appt-item.cancelado { border-left-color: var(--re); opacity: .6; }
.appt-item.faltou { border-left-color: var(--ye); }

/* ============================================================
   CHART PLACEHOLDER
============================================================ */
.chart-wrap { position: relative; height: 200px; }

/* ============================================================
   PATIENT CARD
============================================================ */
.patient-card {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: var(--radius);
  padding: 16px;
  cursor: pointer;
  transition: all var(--trans);
  display: flex; flex-direction: column; gap: 8px;
}
.patient-card:hover { border-color: var(--acc); transform: translateY(-2px); box-shadow: 0 4px 20px rgba(59,130,246,.1); }
.pat-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--accs);
  color: var(--acc);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 15px;
  font-family: var(--font-display);
  flex-shrink: 0;
}

/* ============================================================
   TABS
============================================================ */
.tabs { display: flex; gap: 2px; background: var(--bg2); border-radius: var(--radius-sm); padding: 3px; margin-bottom: 20px; overflow-x: auto; }
.tab-btn {
  flex: 1; min-width: max-content;
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 12px; font-weight: 700;
  color: var(--mu);
  transition: all var(--trans);
  text-align: center;
}
.tab-btn.active { background: var(--card); color: var(--tx); box-shadow: 0 1px 4px rgba(0,0,0,.3); }

/* ============================================================
   RANGE / PERIOD SELECTOR
============================================================ */
.period-btns { display: flex; gap: 4px; }
.period-btn { padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; color: var(--mu); border: 1px solid transparent; transition: all var(--trans); }
.period-btn.active { background: var(--accs); color: var(--acc); border-color: rgba(59,130,246,.2); }

/* ============================================================
   LEGAL MODAL
============================================================ */
.legal-content { font-size: 13px; color: var(--tx2); line-height: 1.7; max-height: 60vh; overflow-y: auto; padding-right: 4px; }
.legal-content h3 { color: var(--tx); font-family: var(--font-display); margin: 16px 0 6px; font-size: 14px; }
.legal-content p { margin-bottom: 10px; }

/* ============================================================
   SETTINGS
============================================================ */
.settings-section { margin-bottom: 28px; }
.settings-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--bor); gap: 12px; }
.settings-row:last-child { border-bottom: none; }
.toggle { position: relative; width: 42px; height: 24px; flex-shrink: 0; }
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; cursor: pointer; inset: 0; background: var(--bg3); border-radius: 99px; transition: var(--trans); }
.toggle-slider::before { content:''; position:absolute; width:18px; height:18px; left:3px; top:3px; background:#fff; border-radius:50%; transition:var(--trans); }
.toggle input:checked + .toggle-slider { background: var(--acc); }
.toggle input:checked + .toggle-slider::before { transform: translateX(18px); }

/* ============================================================
   RESPONSIVE — MOBILE
============================================================ */
@media (max-width: 768px) {
  #sb { display: none !important; }
  #mhdr { display: flex; }
  #bnav { display: flex; }
  #main-wrap {
    left: 0;
    top: var(--hdr-h);
    bottom: var(--bnav-h);
  }
  #main { padding: 16px; }
  .pg-hdr { margin-bottom: 16px; }
  .pg-title { font-size: 18px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-val { font-size: 20px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .full { grid-column: 1; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  table { font-size: 12px; }
  th, td { padding: 9px 10px; }
  #modal-box { padding: 18px; border-radius: 20px 20px 0 0; position: fixed; bottom: 0; left: 0; right: 0; width: 100%; max-width: none; max-height: 92vh; border-bottom: none; border-radius: 20px 20px 0 0; }
  #modal { align-items: flex-end; padding: 0; }
  #toast { bottom: calc(var(--bnav-h) + 12px); }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .filters { gap: 6px; }
  .cal-day { min-height: 44px; font-size: 11px; }
}

/* ============================================================
   V8 ADDITIONS
============================================================ */

/* Dash stat card */
.dash-stat-card {
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: var(--radius);
  padding: 16px 18px;
  transition: border-color var(--trans), transform var(--trans);
}
.dash-stat-card:hover { border-color: var(--bor2); transform: translateY(-2px); }

/* Kanban */
.kb-col { display: flex; flex-direction: column; }
.kb-drop { transition: background .15s; }
.kb-drop.drag-over { background: var(--bg3) !important; border: 1px dashed var(--acc); }
.kb-card { transition: all .15s; }
.kb-card:hover { border-color: var(--bor2) !important; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.3); }
.kb-card:active { cursor: grabbing; }

/* Patient row */
.pat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--bor);
  border-radius: var(--radius);
  margin-bottom: 8px;
  transition: all var(--trans);
  gap: 12px;
}
.pat-row:hover { border-color: var(--bor2); background: var(--bg2); }

/* Expand row */
.pat-row-expand { display: none; padding: 10px 16px 14px; border-top: 1px solid var(--bor); }

/* Week strip */
.week-day-btn { transition: all var(--trans); }
.week-day-btn:hover { transform: translateY(-2px); }

/* Commission bracket highlight */
.bracket-active {
  border-color: var(--gr) !important;
  background: rgba(34,197,94,.08) !important;
}

/* Subscription plan card hover */
.plan-card { transition: all var(--trans); }
.plan-card:hover { transform: translateY(-4px); box-shadow: 0 8px 32px rgba(0,0,0,.3); }

/* Print styles */
@media print {
  #sb, #mhdr, #bnav, #dr, #dov, .btn, .btn-x, .pg-hdr button { display: none !important; }
  #main-wrap { left: 0 !important; top: 0 !important; }
  body { background: white !important; color: black !important; }
}

/* Kanban board scroll */
#kanban-board { scroll-snap-type: x mandatory; }
#kanban-board .kb-col { scroll-snap-align: start; }

/* Stats grid responsive */
@media (max-width: 900px) {
  #dash-content .stats-grid,
  #dash-content > div:first-child { grid-template-columns: repeat(2, 1fr) !important; }
  #kanban-board .kb-col { min-width: 200px !important; }
  .subscription-plans { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 600px) {
  #dash-content > div:first-child { grid-template-columns: 1fr 1fr !important; }
  .subscription-plans { grid-template-columns: 1fr !important; }
}
