﻿/* =============================================
   JA AGENDOU - Design System (AgendaEA-inspired)
   ============================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sidebar-bg: #1e3a5f;
  --sidebar-width: 190px;
  --primary: #1e3a5f;
  --primary-hover: #16304f;
  --white: #ffffff;
  --bg: #f0f2f5;
  --card-bg: #ffffff;
  --border: #e2e8f0;
  --text: #1a1a2e;
  --text-muted: #6b7280;
  --green: #28a745;
  --green-light: #d4edda;
  --yellow-light: #fff3cd;
  --red: #dc3545;
  --red-light: #f8d7da;
  --blue-light: #cce5ff;
  --navy-light: #d0dcea;
  --radius: 6px;
  --shadow: 0 1px 4px rgba(0,0,0,0.08);
}

body { font-family: 'Segoe UI', Arial, sans-serif; background: var(--bg); color: var(--text); display: flex; min-height: 100vh; font-size: 14px; }

/* ========== SIDEBAR ========== */
.sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--sidebar-bg);
  color: var(--white);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0;
  height: 100vh;
  z-index: 100;
  padding-bottom: 16px;
}

.sidebar-brand {
  padding: 18px 16px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 8px;
  display: flex;
  justify-content: center;
}

.sidebar-brand .brand-logo {
  width: 160px;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 6px;
}

.sidebar-nav { flex: 1; padding: 0 8px; overflow-y: auto; }

.nav-link {
  display: block;
  padding: 10px 14px;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  border-radius: var(--radius);
  margin-bottom: 2px;
  font-size: 14px;
  transition: background 0.15s, color 0.15s;
}

.nav-link:hover { background: rgba(255,255,255,0.12); color: var(--white); }
.nav-link.active { background: var(--white); color: var(--sidebar-bg); font-weight: 600; }

.sidebar-footer {
  padding: 12px 16px;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 12px;
  color: rgba(255,255,255,0.6);
  margin-top: auto;
}

.sidebar-footer .user-name { color: var(--white); font-weight: 600; display: block; }
.sidebar-footer .user-role { display: block; margin-bottom: 8px; }
.sidebar-footer a { color: rgba(255,255,255,0.7); text-decoration: underline; font-size: 12px; }
.sidebar-footer a:hover { color: var(--white); }

/* Hamburger toggle — visible only on mobile */
.sidebar-toggle {
  display: none;
}

/* Sidebar backdrop overlay — hidden by default */
.sidebar-overlay {
  display: none;
}

/* ========== MAIN CONTENT ========== */
.content {
  margin-left: var(--sidebar-width);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bg);
}

.page-header {
  padding: 28px 32px 12px;
}

.page-header h1 { font-size: 24px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.page-header p { font-size: 13px; color: var(--text-muted); }

.page-body {
  padding: 0 32px 32px;
  flex: 1;
}

.license-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  border-radius: var(--radius);
  padding: 12px 14px;
  margin-bottom: 16px;
  border: 1px solid #c9def5;
  background: #eaf4ff;
  color: #0b3b66;
}

.license-banner.warning {
  border-color: #f1d088;
  background: #fff5df;
  color: #7c5100;
}

.license-banner-tag {
  font-size: 12px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.7);
  padding: 4px 8px;
  border-radius: 999px;
  cursor: pointer;
}

.renew-details {
  position: relative;
}

.renew-form {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #ecd19b;
  border-radius: 10px;
  padding: 8px;
}

.renew-form label {
  margin-bottom: 0;
  font-size: 12px;
  color: inherit;
}

.renew-form select {
  min-width: 110px;
}

.license-banner.warning .renew-form .btn {
  background: #976200;
  border-color: #976200;
}

/* ========== CARDS ========== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 20px;
}

.card h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

/* ========== KPI CARDS ========== */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.kpi-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 20px;
}

.kpi-card span { font-size: 13px; color: var(--text-muted); display: block; margin-bottom: 6px; }
.kpi-card strong { font-size: 26px; font-weight: 700; color: var(--text); }

/* ========== FILTER BAR ========== */
.filter-bar {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  gap: 16px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.filter-bar label { font-size: 12px; font-weight: 600; color: var(--primary); display: block; margin-bottom: 4px; }

.filter-bar input,
.filter-bar select {
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--text);
  background: var(--white);
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus { border-color: var(--primary); }

/* ========== TABS ========== */
.tabs { display: flex; gap: 4px; margin-bottom: 20px; }

.tab-btn {
  padding: 8px 20px;
  border-radius: 20px;
  border: none;
  background: var(--card-bg);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: all 0.15s;
}

.tab-btn.active,
.tab-btn:hover { background: var(--primary); color: var(--white); }

/* ========== WEEK GRID ========== */
.week-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
}

.week-col { background: var(--card-bg); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }

.week-col-header {
  background: var(--primary);
  color: var(--white);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
}

.week-col-header.today { background: #2d5a8e; }

.week-col-body { padding: 6px; min-height: 120px; }

/* ========== APPOINTMENT CARD ========== */
.appt-card {
  border-radius: 4px;
  padding: 6px 8px;
  margin-bottom: 6px;
  font-size: 12px;
  line-height: 1.4;
  border-left: 3px solid transparent;
}

.appt-card .appt-time { font-weight: 700; display: block; }
.appt-card .appt-dentist { color: inherit; opacity: 0.8; display: block; }
.appt-card .appt-patients { display: block; }
.appt-card .appt-status { display: block; font-size: 11px; margin-top: 2px; }

/* Status colors */
.status-agendado    { background: var(--yellow-light); border-left-color: #f59e0b; color: #92400e; }
.status-confirmado  { background: var(--green-light);  border-left-color: var(--green); color: #155724; }
.status-concluido   { background: #d0dcea; border-left-color: var(--primary); color: var(--primary); }
.status-atendido    { background: var(--navy-light); border-left-color: var(--primary); color: var(--primary); }
.status-falta       { background: var(--red-light);    border-left-color: var(--red); color: #721c24; }
.status-cancelado   { background: #f3f4f6; border-left-color: #9ca3af; color: #6b7280; }

/* Agenda fechada override */
.appt-card.agenda-fechada { background: #c0392b; color: var(--white); border-left-color: #922b21; }

/* ========== NEXT APPOINTMENTS PANEL ========== */
.proximos-panel { display: flex; flex-direction: column; gap: 10px; }

.proximo-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 12px 14px;
}

.proximo-card.status-agendado   { background: var(--yellow-light); }
.proximo-card.status-confirmado { background: var(--green-light); }
.proximo-card.status-concluido  { background: var(--navy-light); }
.proximo-card.status-atendido   { background: #1e3a5f; color: var(--white); }
.proximo-card.status-atendido .proximo-name { color: var(--white); }
.proximo-card.status-atendido .proximo-info { color: rgba(255,255,255,0.8); }
.proximo-card.status-falta      { background: var(--red-light); }
.proximo-card.status-cancelado  { background: #f3f4f6; }

.proximo-name { font-weight: 600; font-size: 13px; margin-bottom: 2px; }
.proximo-info { font-size: 12px; color: var(--text-muted); margin-bottom: 6px; }
.proximo-actions { display: flex; gap: 6px; align-items: center; }

/* ========== TABLES ========== */
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead th { text-align: left; padding: 10px 12px; color: var(--primary); font-weight: 600; font-size: 12px; border-bottom: 1px solid var(--border); }
tbody td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: #f8fafc; }

/* Table row status colors */
tbody tr.row-agendado   { background: var(--yellow-light); }
tbody tr.row-confirmado { background: var(--green-light); }
tbody tr.row-concluido  { background: var(--navy-light); }
tbody tr.row-atendido   { background: #1e3a5f; color: var(--white); }
tbody tr.row-atendido td { color: var(--white); }
tbody tr.row-falta      { background: var(--red-light); }
tbody tr.row-cancelado  { background: #f3f4f6; color: var(--text-muted); }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 8px 18px;
  background: var(--primary);
  color: var(--white);
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s;
  line-height: 1;
}

.btn:hover { background: var(--primary-hover); border-color: var(--primary-hover); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}
.btn-outline:hover { background: var(--primary); color: var(--white); }

.btn-green { background: var(--green); border-color: var(--green); color: var(--white); }
.btn-green:hover { background: #218838; border-color: #218838; }

.btn-red { background: var(--red); border-color: var(--red); color: var(--white); }
.btn-red:hover { background: #c82333; border-color: #c82333; }

.btn-sm { padding: 5px 12px; font-size: 12px; }

.btn-whatsapp {
  background: #25d366; border-color: #25d366; color: var(--white);
  font-size: 12px; padding: 5px 10px;
}
.btn-whatsapp:hover { background: #1da851; }

/* ========== FORMS ========== */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }

label { display: block; font-size: 12px; font-weight: 600; color: var(--primary); margin-bottom: 4px; }

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="time"],
input[type="number"],
input[type="month"],
select,
textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--text);
  background: var(--white);
  outline: none;
  font-family: inherit;
}

input:focus, select:focus, textarea:focus { border-color: var(--primary); }
textarea { resize: vertical; }

.form-actions { display: flex; gap: 10px; align-items: center; margin-top: 4px; padding-top: 10px; border-top: 1px solid var(--border); }

/* ========== TWO-COLUMN LAYOUT ========== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}

.two-col-left { }
.two-col-right { }

/* ========== BADGES ========== */
.badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.badge-green  { background: var(--green-light); color: #155724; }
.badge-yellow { background: var(--yellow-light); color: #856404; }
.badge-red    { background: var(--red-light); color: #721c24; }
.badge-blue   { background: var(--blue-light); color: #004085; }
.badge-gray   { background: #f3f4f6; color: #6b7280; }
.badge-navy   { background: var(--navy-light); color: var(--primary); }
.badge-pendente { background: #fff1cc; color: #8a6100; }
.badge-ativo { background: var(--green-light); color: #155724; }
.badge-inativo { background: var(--red-light); color: #721c24; }

/* ========== ALERTS ========== */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 13px;
}
.alert-success { background: var(--green-light); color: #155724; border: 1px solid #c3e6cb; }
.alert-error   { background: var(--red-light);   color: #721c24; border: 1px solid #f5c6cb; }
.alert-info    { background: var(--blue-light);  color: #004085; border: 1px solid #b8daff; }

/* ========== FINANCEIRO DO MES ========== */
.fin-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 8px;
}

.fin-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
}

.fin-card span { font-size: 12px; color: var(--text-muted); display: block; margin-bottom: 4px; }
.fin-card strong { font-size: 18px; font-weight: 700; color: var(--text); }

/* ========== DASHBOARD LAYOUT ========== */
.dashboard-row {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
  align-items: start;
}

/* ========== MONTH CALENDAR ========== */
.month-calendar table { width: 100%; }
.month-calendar th { text-align: center; font-size: 11px; background: #f3f4f6; padding: 6px; }
.month-calendar td { text-align: center; vertical-align: top; padding: 4px; min-width: 40px; font-size: 12px; cursor: pointer; }
.month-calendar td:hover { background: #e8edf2; }
.month-calendar td.today { font-weight: 700; color: var(--primary); }
.month-calendar td.selected { background: var(--primary); color: var(--white); border-radius: 50%; }
.month-calendar .dot-count { font-size: 10px; color: var(--primary); }

.month-week-grid .week-col-body {
  min-height: 150px;
}

.month-day-link {
  color: inherit;
  text-decoration: none;
  display: block;
}

.month-day-link:hover {
  text-decoration: underline;
}

.month-day-col.selected {
  outline: 2px solid #2d5a8e;
  outline-offset: -2px;
}

.month-empty-col {
  opacity: 0.55;
}

.month-empty-col .week-col-header {
  background: #94a3b8;
}

/* ========== AGENDA PAGE ========== */
.agenda-hero {
  background: linear-gradient(125deg, #f6fbff 0%, #ffffff 52%, #f4f8fc 100%);
  border: 1px solid #d9e6f2;
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 10px 22px rgba(15, 45, 75, 0.06);
  position: relative;
  overflow: hidden;
}

.agenda-hero::before {
  content: "";
  position: absolute;
  inset: -20% auto auto -10%;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(36, 117, 195, 0.14) 0%, rgba(36, 117, 195, 0) 70%);
  pointer-events: none;
}

.agenda-hero-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
}

.agenda-hero-head h2 {
  font-size: 19px;
  color: #0d355b;
  margin-bottom: 4px;
}

.agenda-hero-head p {
  color: #526477;
  font-size: 13px;
}

.agenda-status-legend {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.agenda-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.agenda-kpi-card {
  border: 1px solid #d5e4f3;
  background: #fff;
  border-radius: 12px;
  padding: 12px;
}

.agenda-kpi-card span {
  display: block;
  font-size: 12px;
  color: #5d6e80;
  margin-bottom: 4px;
}

.agenda-kpi-card strong {
  font-size: 28px;
  line-height: 1;
  color: #0f3f6b;
}

.agenda-kpi-card.agenda-kpi-risk {
  border-color: #f7d6d9;
  background: #fff6f7;
}

.agenda-kpi-card.agenda-kpi-risk strong {
  color: #b4232f;
}

.badge-status-agendado { background: var(--yellow-light); color: #8a6100; }
.badge-status-confirmado { background: var(--green-light); color: #14532d; }
.badge-status-concluido { background: var(--navy-light); color: #14395c; }
.badge-status-falta { background: var(--red-light); color: #9f1239; }
.badge-status-cancelado { background: #f3f4f6; color: #596273; }

.agenda-note {
  margin-top: 14px;
  padding: 12px;
  background: #f0f4f8;
  border-radius: 8px;
  font-size: 12px;
  color: #4b5563;
}

.agenda-help-text {
  font-size: 12px;
  color: #6b7280;
  margin-top: 10px;
}

.agenda-tabs-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 0;
  border-bottom: 1px solid #dce7f2;
  padding: 6px;
  border-radius: 12px 12px 0 0;
  background: linear-gradient(180deg, #f8fbff 0%, #f1f6fb 100%);
}

.agenda-tab {
  background: transparent;
  border: 1px solid transparent;
  padding: 10px 20px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: #4f5f70;
  border-radius: 10px;
  margin-bottom: -1px;
  transition: color 0.18s, border-color 0.18s, background 0.18s, transform 0.18s;
}

.agenda-tab.active {
  color: #0f3f6b;
  border-color: #cfe1f2;
  background: #ffffff;
  box-shadow: 0 5px 14px rgba(9, 41, 72, 0.08);
}

.agenda-tab:hover {
  color: #0f3f6b;
  transform: translateY(-1px);
}

.agenda-panel { display: none; }
.agenda-panel.active {
  display: block;
  animation: agendaReveal 0.24s ease;
}

@keyframes agendaReveal {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.agenda-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.agenda-list-title h3 {
  margin-bottom: 0;
  border-bottom: none;
}

.agenda-list-title p {
  font-size: 12px;
  color: #6b7280;
  margin-top: 2px;
}

.agenda-search-form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.agenda-search-input { width: 260px; }

.agenda-empty-cell {
  text-align: center;
  color: #9ca3af;
  padding: 24px;
}

.agenda-row-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}

.agenda-table {
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 12px;
  overflow: hidden;
}

.agenda-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f5f9fd;
  color: #0f3f6b;
}

.agenda-table tbody tr {
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.agenda-table tbody tr:hover {
  transform: translateX(2px);
  box-shadow: inset 3px 0 0 #7aa7d4;
}

.agenda-calendar-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.cal-nav-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cal-nav button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 7px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 4px 10px rgba(17, 58, 95, 0.18);
}

.cal-nav button:hover { background: var(--primary-hover); }

.cal-btn-light {
  background: #ffffff;
  color: #0f3f6b;
  border: 1px solid #c8dced;
  box-shadow: none;
}

.cal-btn-light:hover {
  background: #f3f8fd;
}

.cal-nav span {
  font-weight: 700;
  font-size: 15px;
}

.cal-week {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 13px;
}

.cal-week th {
  background: var(--primary);
  color: #fff;
  padding: 8px 4px;
  text-align: center;
  font-weight: 600;
  font-size: 12px;
  position: sticky;
  top: 0;
  z-index: 2;
}

.cal-week td {
  border: 1px solid var(--border);
  vertical-align: top;
  height: 52px;
  padding: 4px;
  cursor: pointer;
  transition: background 0.1s, box-shadow 0.1s;
}

.cal-week td:hover {
  background: #eef4fb;
  box-shadow: inset 0 0 0 1px #cfe1f2;
}

.cal-week td.cal-hour {
  background: #f9fafb;
  font-weight: 600;
  font-size: 11px;
  color: var(--text-muted);
  cursor: default;
  width: 54px;
  text-align: center;
}

.cal-week td.cal-hour:hover { background: #f9fafb; }

.cal-week .cal-evt {
  font-size: 11px;
  padding: 3px 6px;
  border-radius: 6px;
  margin-bottom: 3px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  cursor: pointer;
  line-height: 1.25;
  border: 1px solid rgba(10, 37, 64, 0.08);
}

.cal-month {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 13px;
}

.cal-month th {
  background: var(--primary);
  color: #fff;
  padding: 8px;
  text-align: center;
  font-weight: 600;
  font-size: 12px;
}

.cal-month td {
  border: 1px solid var(--border);
  vertical-align: top;
  height: 88px;
  padding: 4px 6px;
  cursor: pointer;
  transition: background 0.1s, transform 0.1s;
}

.cal-month td:hover {
  background: #eef3fb;
  transform: translateY(-1px);
}

.cal-month td.outro-mes {
  color: #ccc;
  background: #fafafa;
}

.cal-month .dia-num {
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 2px;
}

.cal-month .dia-hoje .dia-num {
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cal-month .cal-mini {
  font-size: 10px;
  line-height: 1.4;
  overflow: hidden;
  max-height: 52px;
}

.cal-mini-item {
  display: block;
  margin: 1px 0;
}

.cal-more {
  color: #6b7280;
  font-size: 10px;
}

.cal-evt-agendado { background: #cce5ff; color: #004085; }
.cal-evt-confirmado { background: #d4edda; color: #155724; }
.cal-evt-concluido { background: #b8daff; color: #004085; }
.cal-evt-cancelado { background: #f8d7da; color: #721c24; }
.cal-evt-falta { background: #fff3cd; color: #856404; }

.agenda-row-actions .btn,
.agenda-row-actions form .btn {
  min-height: 30px;
}

.agenda-queue-card {
  margin-top: 16px;
  border: 1px solid #d7e5f2;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(14, 43, 75, 0.08);
}

.agenda-queue-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.agenda-queue-head h3 {
  margin-bottom: 2px;
  border-bottom: none;
  padding-bottom: 0;
}

.agenda-queue-head p {
  font-size: 12px;
  color: #607082;
}

.agenda-empty-state {
  border: 1px dashed #c8d9ea;
  border-radius: 10px;
  background: #f8fbff;
  color: #5d6f81;
  padding: 14px;
  font-size: 13px;
  text-align: center;
}

.agenda-queue-list {
  display: grid;
  gap: 8px;
}

.agenda-queue-item {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) auto auto;
  gap: 12px;
  align-items: center;
  border: 1px solid #e1eaf3;
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
}

.agenda-queue-item.is-risk {
  border-color: #f5ced4;
  background: #fff8f9;
}

.agenda-queue-item.is-confirmed {
  border-color: #cfe8d8;
  background: #f5fcf8;
}

.agenda-queue-time {
  font-size: 12px;
  color: #607082;
  margin-bottom: 2px;
}

.agenda-queue-patient {
  font-size: 15px;
  font-weight: 700;
  color: #0f3358;
  margin-bottom: 2px;
}

.agenda-queue-meta {
  font-size: 12px;
  color: #66768a;
}

.agenda-queue-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* ========== AUTH ========== */
.auth-body { background: linear-gradient(135deg, #1e3a5f 0%, #2d5a8e 100%); display: flex; align-items: center; justify-content: center; min-height: 100vh; }

.auth-box {
  background: var(--white);
  border-radius: 12px;
  padding: 40px;
  width: 480px;
  max-width: 95vw;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  text-align: center;
}

.auth-logo {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  margin: 0 auto 24px;
}

.auth-box h1 { font-size: 22px; font-weight: 700; margin-bottom: 18px; color: var(--text); }
.auth-box p  { font-size: 13px; color: var(--text-muted); margin-bottom: 24px; }

.auth-box label { text-align: left; font-weight: 600; font-size: 12px; color: var(--primary); }
.auth-box input { margin-bottom: 14px; }
.auth-box .btn  { width: 100%; padding: 10px; margin-top: 4px; }

.auth-secondary-link {
  margin: -4px 0 14px;
  text-align: right;
}

.auth-secondary-link a {
  color: var(--primary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.auth-secondary-link a:hover {
  text-decoration: underline;
}

.auth-alt-link {
  margin-top: 14px;
  font-size: 13px;
  display: flex;
  justify-content: center;
  gap: 8px;
}

.auth-alt-link a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}

.auth-alt-link a:hover {
  text-decoration: underline;
}

.auth-alt-link span {
  color: #9ca3af;
}

.signup-box {
  width: 560px;
}

/* ========== SALES PAGE ========== */
.sales-body {
  display: block;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 10%, #cfe2f8 0%, transparent 36%),
    radial-gradient(circle at 85% 25%, #cdeee6 0%, transparent 40%),
    #f7fafc;
  color: #0f172a;
}

.sales-body.sales-modal-open {
  overflow: hidden;
}

.sales-header {
  max-width: 1140px;
  margin: 0 auto;
  padding: 22px 20px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(8px);
}

.sales-brand {
  display: flex;
  align-items: center;
}

.sales-logo {
  width: 190px;
  max-width: 100%;
  border-radius: 10px;
}

.sales-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.sales-nav a {
  color: #0f172a;
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
  padding: 4px 6px;
  border-radius: 8px;
}

.sales-nav a:hover {
  background: rgba(255, 255, 255, 0.75);
}

.sales-nav .btn {
  color: var(--white);
}

.sales-nav .nav-cta {
  padding: 11px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 10px 22px rgba(14, 43, 79, 0.25);
  background: linear-gradient(140deg, #0f4c81 0%, #1f6fb0 100%);
  border-color: #145da0;
}

.sales-nav .nav-cta:hover {
  background: linear-gradient(140deg, #0d416d 0%, #195d92 100%);
  border-color: #0d416d;
  transform: translateY(-1px);
}

.sales-nav .btn-outline {
  color: var(--primary);
}

.hero-sales {
  max-width: 1140px;
  margin: 10px auto 10px;
  padding: 26px 20px;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 22px;
  align-items: stretch;
}

.hero-sales-text {
  background: linear-gradient(165deg, #ffffff 0%, #f6faff 100%);
  border-radius: 18px;
  border: 1px solid #d7e5f4;
  box-shadow: 0 22px 38px rgba(14, 43, 79, 0.1);
  padding: 30px;
}

.hero-kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 11px;
  color: #145da0;
  font-weight: 700;
  margin-bottom: 10px;
}

.hero-sales-text h1 {
  font-size: 44px;
  line-height: 1.08;
  margin-bottom: 12px;
  color: #072f53;
}

.hero-sales-text p {
  color: #334155;
  font-size: 16px;
  max-width: 62ch;
  margin-bottom: 18px;
}

.hero-sales-ctas {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-hero-primary {
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 700;
  border-radius: 999px;
  background: linear-gradient(140deg, #145da0 0%, #1f6fb0 100%);
  border-color: #145da0;
}

.btn-hero-primary:hover {
  background: linear-gradient(140deg, #104d85 0%, #1a5f96 100%);
  border-color: #104d85;
}

.sales-mobile-cta {
  display: none;
}

.sales-proof-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.sales-proof-inline span {
  border: 1px solid #d2e3f3;
  background: #f7fbff;
  color: #0a3c67;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
}

.hero-sales-card {
  background: linear-gradient(160deg, #133f6a 0%, #1f5f97 100%);
  color: #eff6ff;
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 18px 38px rgba(12, 40, 70, 0.25);
}

.hero-sales-screenshot {
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(12, 40, 70, 0.22);
  border: 1px solid #d2e3f3;
  background: #fff;
}

.hero-sales-screenshot img {
  width: 100%;
  height: auto;
  display: block;
}

.screenshot-caption {
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  color: #0b2d4f;
  text-align: center;
  background: linear-gradient(135deg, #f6faff, #f0f7ff);
  border-top: 1px solid #e0ecf7;
}

/* ========== SCREENSHOT GALLERY ========== */
.screenshot-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.screenshot-item {
  background: #ffffff;
  border: 1px solid #d4e1ee;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(13, 43, 72, 0.08);
  transition: transform 0.2s, box-shadow 0.2s;
}

.screenshot-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(13, 43, 72, 0.14);
}

.screenshot-item img {
  width: 100%;
  height: auto;
  display: block;
  border-bottom: 1px solid #e0ecf7;
}

.screenshot-item h4 {
  font-size: 16px;
  color: #0b2d4f;
  padding: 14px 16px 4px;
  margin: 0;
}

.screenshot-item p {
  font-size: 13px;
  color: #475569;
  padding: 0 16px 16px;
  margin: 0;
}

.hero-sales-card h3 {
  border-bottom: 1px solid rgba(255,255,255,0.25);
  color: #ffffff;
  font-size: 20px;
  margin-bottom: 12px;
}

.hero-sales-card ul {
  list-style: none;
  display: grid;
  gap: 10px;
}

.hero-sales-card li {
  padding: 10px 12px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
}

.sales-section {
  max-width: 1140px;
  margin: 0 auto;
  padding: 28px 20px;
}

.sales-section h2 {
  font-size: 32px;
  color: #0b2d4f;
  margin-bottom: 14px;
}

.sales-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.sales-metrics {
  max-width: 1140px;
  margin: 4px auto 0;
  padding: 0 20px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.sales-metrics article {
  background: #ffffff;
  border: 1px solid #d5e5f3;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 10px 20px rgba(10, 40, 70, 0.06);
}

.sales-metrics strong {
  display: block;
  font-size: 28px;
  color: #0e4f86;
  margin-bottom: 6px;
}

.sales-metrics span {
  color: #475569;
  font-size: 13px;
}

.sales-feature {
  border-radius: 14px;
  border: 1px solid #d6e2ee;
  background: #ffffff;
  padding: 22px;
  box-shadow: 0 10px 22px rgba(15, 36, 61, 0.06);
}

.sales-feature h3 {
  border: none;
  margin-bottom: 6px;
  padding: 0;
  font-size: 20px;
  color: #0f3f6b;
}

.sales-feature p {
  color: #475569;
}

.sales-highlight {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 18px;
  align-items: stretch;
}

.sales-checklist {
  background: linear-gradient(140deg, #e8f4ff, #e8fff7);
  border: 1px solid #d5e7f4;
  border-radius: 14px;
  padding: 18px;
  display: grid;
  gap: 8px;
}

.sales-checklist p {
  font-weight: 600;
  color: #0b355e;
}

.sales-plan-card {
  border-radius: 16px;
  background: #ffffff;
  border: 2px solid #b7d4ee;
  box-shadow: 0 16px 34px rgba(15, 56, 89, 0.1);
  padding: 28px;
}

.sales-plan-card h3 {
  border: none;
  padding: 0;
  margin: 2px 0 8px;
  font-size: 24px;
  color: #0c365d;
}

.sales-plan-card p {
  color: #425466;
  margin-bottom: 14px;
}

.sales-pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.featured-plan {
  border-color: #2f7cc0;
  background: linear-gradient(165deg, #ffffff, #f2f9ff);
  transform: translateY(-6px);
}

.plan-badge {
  display: inline-block;
  background: #c3ecdf;
  color: #145f4d;
  font-weight: 700;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  margin-bottom: 8px;
}

.plan-price {
  font-size: 22px;
  font-weight: 700;
  color: #0b2d4f;
}

.sales-faq-grid {
  display: grid;
  gap: 10px;
}

.sales-faq-grid details {
  background: #ffffff;
  border: 1px solid #d4e1ee;
  border-radius: 12px;
  padding: 12px 14px;
}

.sales-faq-grid summary {
  cursor: pointer;
  font-weight: 700;
  color: #0f3f6b;
}

.sales-faq-grid p {
  margin-top: 8px;
  color: #475569;
}

.sales-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(8, 24, 43, 0.55);
  backdrop-filter: blur(8px);
}

.sales-modal-backdrop[hidden] {
  display: none;
}

.sales-trial-modal {
  position: relative;
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  background: linear-gradient(135deg, #f4fbff 0%, #ffffff 45%, #f8fffb 100%);
  border: 1px solid rgba(210, 228, 243, 0.85);
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(5, 25, 45, 0.28);
}

.sales-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  color: #0f172a;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.sales-modal-close:hover {
  background: rgba(15, 23, 42, 0.14);
}

.sales-trial-copy {
  padding: 38px;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.18), transparent 38%),
    linear-gradient(160deg, #0f4a7e 0%, #0d355d 58%, #0a2542 100%);
  color: #eff6ff;
}

.trial-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sales-trial-copy h2 {
  margin: 18px 0 12px;
  font-size: 38px;
  line-height: 1.08;
  color: #ffffff;
}

.sales-trial-copy > p {
  color: rgba(239, 246, 255, 0.9);
  font-size: 16px;
  max-width: 34ch;
}

.trial-proof-inline {
  margin: 18px 0 24px;
}

.trial-proof-inline span {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.12);
  color: #f8fafc;
}

.trial-benefits {
  display: grid;
  gap: 14px;
}

.trial-benefits article {
  display: grid;
  gap: 6px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
}

.trial-benefits strong {
  font-size: 17px;
}

.trial-benefits span {
  color: rgba(239, 246, 255, 0.84);
}

.sales-trial-form {
  display: grid;
  gap: 10px;
  padding: 38px;
  align-content: center;
}

.sales-trial-form h3 {
  margin: 0;
  font-size: 28px;
  color: #0b2d4f;
}

.trial-form-intro {
  margin-bottom: 8px;
  color: #475569;
}

.trial-secondary-cta {
  width: 100%;
}

.sales-lead-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: start;
}

.sales-price-table-wrap,
.sales-lead-form {
  background: #ffffff;
  border: 1px solid #d4e1ee;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(13, 43, 72, 0.08);
  padding: 18px;
}

.sales-price-table {
  width: 100%;
  border-collapse: collapse;
}

.sales-price-table thead th {
  color: #0b355e;
  font-size: 12px;
  border-bottom: 1px solid #dce8f3;
}

.sales-price-table tbody td {
  border-bottom: 1px solid #edf3f8;
  font-size: 13px;
}

.sales-price-table tbody tr:last-child td {
  border-bottom: 0;
}

.sales-price-note {
  margin-top: 10px;
  color: #475569;
  font-size: 13px;
}

.sales-lead-form {
  display: grid;
  gap: 8px;
}

.sales-form-field.is-hidden {
  display: none;
}

.sales-form-help {
  margin: -2px 0 4px;
  color: #526477;
  font-size: 12px;
}

.sales-lead-form .btn {
  margin-top: 4px;
}

.sales-final-cta {
  max-width: 1140px;
  margin: 0 auto 40px;
  padding: 28px 20px 8px;
  text-align: center;
}

.sales-final-cta h2 {
  color: #0b2d4f;
  font-size: 36px;
  margin-bottom: 8px;
}

.sales-final-cta p {
  color: #475569;
  margin-bottom: 14px;
}

/* ========== DEPOIMENTOS ========== */
.sales-testimonials {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 14px;
}

.testimonial-card {
  background: #ffffff;
  border: 1px solid #d4e1ee;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 10px 24px rgba(13, 43, 72, 0.07);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.testimonial-stars {
  color: #f59e0b;
  font-size: 18px;
  letter-spacing: 2px;
}

.testimonial-text {
  color: #334155;
  font-size: 14px;
  line-height: 1.6;
  font-style: italic;
  flex: 1;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid #edf3f8;
}

.testimonial-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0f4a7e, #1f6fad);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.testimonial-author strong {
  display: block;
  font-size: 14px;
  color: #0b2d4f;
}

.testimonial-author span {
  display: block;
  font-size: 12px;
  color: #64748b;
}

.testimonial-counter {
  text-align: center;
  margin-top: 20px;
  padding: 14px 20px;
  background: linear-gradient(135deg, #e8f4ff, #edfff7);
  border: 1px solid #d5e7f4;
  border-radius: 12px;
  font-size: 15px;
  color: #0b355e;
}

.testimonial-counter strong {
  color: #0e4f86;
  font-size: 18px;
}

/* ========== PRICING 3 COLUMNS ========== */
.sales-pricing-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}

.plan-features {
  list-style: none;
  padding: 0;
  margin: 14px 0 18px;
  display: grid;
  gap: 8px;
}

.plan-features li {
  font-size: 13px;
  color: #334155;
  padding-left: 22px;
  position: relative;
}

.plan-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #10b981;
  font-weight: 700;
}

.plan-period {
  font-size: 14px;
  font-weight: 400;
  color: #64748b;
}

.plan-badge-save {
  background: #fef3c7;
  color: #92400e;
}

.plan-payment {
  font-size: 13px;
  color: #64748b;
  margin-top: -8px;
  margin-bottom: 4px;
}

/* ========== CONTACT FORM CENTERED ========== */
.sales-lead-centered {
  max-width: 520px;
  margin: 0 auto;
}

.sales-lead-centered .sales-lead-form {
  background: #ffffff;
  border: 1px solid #d4e1ee;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(13, 43, 72, 0.08);
  padding: 24px;
  display: grid;
  gap: 8px;
}

/* ========== WHATSAPP FLUTUANTE ========== */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 50;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25d366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
  transition: transform 0.2s, box-shadow 0.2s;
  animation: wppBounce 2s infinite;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.55);
}

@keyframes wppBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.btn-pulse {
  animation: pulseGlow 2.4s infinite;
}

.reveal-up {
  animation: revealUp 0.8s ease both;
}

@keyframes pulseGlow {
  0% { box-shadow: 0 0 0 0 rgba(30, 58, 95, 0.35); }
  70% { box-shadow: 0 0 0 10px rgba(30, 58, 95, 0); }
  100% { box-shadow: 0 0 0 0 rgba(30, 58, 95, 0); }
}

@keyframes revealUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ========== ANIVERSARIANTES ========== */
.birthday-list { list-style: none; }
.birthday-list li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.birthday-list li:last-child { border-bottom: none; }
.birthday-date { font-size: 12px; color: var(--text-muted); }

/* ========== STATUS DROPDOWN (inline) ========== */
.status-select {
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 12px;
  background: var(--white);
  cursor: pointer;
}

/* ========== AUTOCOMPLETE ========== */
.autocomplete-wrapper { position: relative; }
.autocomplete-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  max-height: 200px;
  overflow-y: auto;
  z-index: 200;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.autocomplete-list li {
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13px;
  list-style: none;
  border-bottom: 1px solid var(--border);
}
.autocomplete-list li:hover { background: #f0f2f5; }
.autocomplete-hint { font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ========== EMPTY STATE ========== */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}
.empty-state p { font-size: 14px; }

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .fin-grid { grid-template-columns: repeat(2, 1fr); }
  .week-grid { grid-template-columns: repeat(4, 1fr); }
  .dashboard-row { grid-template-columns: 1fr; }

  .sales-metrics {
    grid-template-columns: 1fr;
  }

  .sales-pricing-grid,
  .sales-pricing-grid-3 {
    grid-template-columns: 1fr;
  }

  .sales-testimonials {
    grid-template-columns: 1fr;
  }

  .screenshot-gallery {
    grid-template-columns: 1fr;
  }

  .featured-plan {
    transform: none;
  }

  .sales-lead-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .sidebar { width: 160px; min-width: 160px; }
  .content { margin-left: 160px; }
  .sidebar-brand .brand-logo { width: 140px; }
  .two-col { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .week-grid { grid-template-columns: repeat(2, 1fr); }
  .kpi-row { grid-template-columns: 1fr 1fr; }

  .sales-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-sales {
    grid-template-columns: 1fr;
  }

  .hero-sales-text h1 {
    font-size: 33px;
  }

  .sales-grid-3,
  .sales-highlight {
    grid-template-columns: 1fr;
  }

  .sales-testimonials {
    grid-template-columns: 1fr;
  }

  .sales-pricing-grid-3 {
    grid-template-columns: 1fr;
  }

  .screenshot-gallery {
    grid-template-columns: 1fr;
  }

  .whatsapp-float {
    width: 52px;
    height: 52px;
    bottom: 16px;
    right: 16px;
  }

  .sales-trial-modal {
    grid-template-columns: 1fr;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
  }

  .sales-trial-copy,
  .sales-trial-form {
    padding: 28px 22px;
  }

  .sales-trial-copy h2 {
    font-size: 30px;
  }

  .sales-final-cta h2 {
    font-size: 30px;
  }

  .sales-nav {
    gap: 8px;
  }

  .sales-nav .nav-cta {
    width: 100%;
    justify-content: center;
  }

  .sales-body {
    padding-bottom: 86px;
  }

  .sales-mobile-cta {
    display: block;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid #d7e5f4;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    backdrop-filter: blur(8px);
  }

  .sales-mobile-cta .btn {
    width: 100%;
    min-height: 44px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 999px;
    background: linear-gradient(140deg, #145da0 0%, #1f6fb0 100%);
    border-color: #145da0;
  }

  .sales-mobile-cta .btn:hover {
    background: linear-gradient(140deg, #104d85 0%, #1a5f96 100%);
    border-color: #104d85;
  }

  .whatsapp-float {
    bottom: 82px;
  }

  .agenda-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .agenda-list-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .agenda-search-form {
    width: 100%;
  }

  .agenda-search-input {
    width: 100%;
  }

  .agenda-queue-item {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .agenda-queue-actions {
    justify-content: flex-start;
  }
}

/* ========== MOBILE RESPONSIVO (≤768px) ========== */
@media (max-width: 768px) {

  /* Hamburger button */
  .sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 300;
    background: var(--sidebar-bg);
    color: var(--white);
    border: none;
    border-radius: 6px;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
  }

  /* Sidebar hidden off-screen by default on mobile */
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 200;
    width: 220px;
    min-width: 220px;
  }

  /* Sidebar open state */
  .sidebar.sidebar-open {
    transform: translateX(0);
  }

  /* Content full-width on mobile */
  .content {
    margin-left: 0;
    padding-top: 60px; /* room for the hamburger button */
  }

  /* Backdrop overlay */
  .sidebar-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 150;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
  }

  .sidebar-overlay.active {
    opacity: 1;
    pointer-events: all;
  }

  /* Misc layout tweaks */
  .page-header { padding: 16px 16px 8px; }
  .page-body { padding: 0 16px 24px; }
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .two-col { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }

  .agenda-tab {
    padding: 8px 12px;
    font-size: 13px;
  }

  .agenda-tabs-bar {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }

  .cal-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .cal-nav-group {
    justify-content: space-between;
  }

  .cal-week td {
    height: 40px;
    font-size: 11px;
  }

  .cal-week .cal-evt {
    font-size: 10px;
  }

  .cal-month td {
    height: 60px;
    font-size: 11px;
  }

  .agenda-hero-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .agenda-queue-head {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Modal overlay */
.modal-overlay{position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:999;display:flex;align-items:center;justify-content:center;padding:20px}
.modal-box{background:#fff;border-radius:14px;padding:24px;width:100%;box-shadow:0 20px 60px rgba(0,0,0,.2);position:relative;max-height:90vh;overflow-y:auto}
