/* ═══════════════════════════════════════════════════════════════
   SISTEMA DE ESTACIONAMENTO — CSS PRINCIPAL
   Design Mobile First | Paleta Azul Moderna
════════════════════════════════════════════════════════════════ */

/* ── Reset & Base ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:       #1e40af;
  --primary-dark:  #1e3a8a;
  --primary-light: #3b82f6;
  --primary-pale:  #dbeafe;

  --green:   #16a34a;
  --orange:  #ea580c;
  --red:     #dc2626;
  --purple:  #7c3aed;
  --teal:    #0891b2;
  --yellow:  #ca8a04;

  --bg:        #f1f5f9;
  --bg-card:   #ffffff;
  --border:    #e2e8f0;
  --text:      #0f172a;
  --text-muted:#64748b;
  --text-light:#94a3b8;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 4px 12px rgba(0,0,0,.06);
  --shadow-lg: 0 8px 32px rgba(0,0,0,.12);

  --header-h: 60px;
  --sidebar-w: 260px;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  min-height: 100dvh;
  overflow-x: hidden;
}

/* ── Telas ────────────────────────────────────────────────────── */
.screen { display: none; }
.screen.active { display: block; }
.screen.hidden { display: none; }
.hidden { display: none !important; }

/* ── LOGIN ────────────────────────────────────────────────────── */
#login-screen {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #3b82f6 100%);
  padding: 1rem;
}

.login-container {
  background: var(--bg-card);
  border-radius: 20px;
  padding: 2.5rem 2rem;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-lg);
}

.login-logo {
  text-align: center;
  margin-bottom: 2rem;
}
.login-logo i {
  font-size: 3rem;
  color: var(--primary);
  display: block;
  margin-bottom: .5rem;
}
.login-logo h1 { font-size: 1.6rem; font-weight: 800; color: var(--primary-dark); }
.login-logo p  { color: var(--text-muted); font-size: .9rem; }

.login-logo-img {
  width: 120px;
  height: 120px;
  object-fit: contain;
  border-radius: 12px;
  margin: 0 auto .75rem;
  display: block;
}
.login-logo-img.hidden { display: none; }

.login-footer {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: .75rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.login-footer strong { color: var(--primary); }

/* ── Header ───────────────────────────────────────────────────── */
.app-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  padding: 0 1rem;
  gap: .75rem;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}

.btn-menu {
  background: none; border: none; color: white;
  font-size: 1.3rem; cursor: pointer; padding: .5rem;
  border-radius: 8px;
  transition: background .2s;
}
.btn-menu:hover { background: rgba(255,255,255,.15); }

.header-title { flex: 1; font-size: 1.1rem; font-weight: 600; }

.header-right {
  display: flex; align-items: center; gap: .5rem;
}
.header-clock { font-size: .85rem; opacity: .85; font-variant-numeric: tabular-nums; }

.btn-icon {
  background: none; border: none; color: white;
  font-size: 1.1rem; cursor: pointer; padding: .5rem;
  border-radius: 8px;
  transition: background .2s;
}
.btn-icon:hover { background: rgba(255,255,255,.15); }

/* ── Sidebar ──────────────────────────────────────────────────── */
.sidebar {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--primary-dark);
  color: white;
  display: flex;
  flex-direction: column;
  z-index: 200;
  transform: translateX(-100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}
.sidebar.open { transform: translateX(0); }

.sidebar-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 190;
}
.sidebar-overlay.show { display: block; }

.sidebar-user {
  display: flex; align-items: center; gap: .75rem;
  padding: calc(var(--header-h) + 1rem) 1.25rem 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.user-avatar {
  width: 44px; height: 44px;
  background: rgba(255,255,255,.15);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
}
.user-name  { font-weight: 600; font-size: .95rem; }
.user-role  { font-size: .78rem; opacity: .7; text-transform: uppercase; letter-spacing: .04em; }

.sidebar-menu { list-style: none; padding: .75rem 0; flex: 1; }
.sidebar-menu li a {
  display: flex; align-items: center; gap: .75rem;
  padding: .85rem 1.25rem;
  color: rgba(255,255,255,.8);
  text-decoration: none;
  font-size: .95rem;
  transition: background .2s, color .2s;
  border-radius: 0;
}
.sidebar-menu li a i { width: 20px; text-align: center; }
.sidebar-menu li a:hover,
.sidebar-menu li a.active { background: rgba(255,255,255,.12); color: white; }
.sidebar-menu li a.active { border-left: 3px solid #60a5fa; }

.sidebar-footer { padding: 1rem 1.25rem; }

.sidebar-credits {
  margin-top: .75rem;
  font-size: .68rem;
  color: rgba(255,255,255,.35);
  text-align: center;
  line-height: 1.4;
}

/* ── Main Content ─────────────────────────────────────────────── */
.main-content {
  margin-top: var(--header-h);
  padding: 1rem;
  min-height: calc(100dvh - var(--header-h));
}

/* ── Pages ────────────────────────────────────────────────────── */
.page { display: none; }
.page.active { display: block; }
.page.hidden { display: none; }

/* ── Cards ────────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  margin-bottom: 1rem;
}
.card-title {
  font-size: 1rem; font-weight: 600;
  margin-bottom: 1.25rem;
  color: var(--primary-dark);
  display: flex; align-items: center; gap: .5rem;
}
.card-list { display: flex; flex-direction: column; gap: .75rem; }

/* ── Stats Grid ───────────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem;
  margin-bottom: 1rem;
}

.stat-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: .75rem;
}
.stat-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.stat-value { font-size: 1.3rem; font-weight: 700; line-height: 1; }
.stat-label { font-size: .75rem; color: var(--text-muted); margin-top: .2rem; }

.stat-card.blue   .stat-icon { background: var(--primary-pale); color: var(--primary); }
.stat-card.green  .stat-icon { background: #dcfce7; color: var(--green); }
.stat-card.orange .stat-icon { background: #ffedd5; color: var(--orange); }
.stat-card.purple .stat-icon { background: #ede9fe; color: var(--purple); }
.stat-card.teal   .stat-icon { background: #cffafe; color: var(--teal); }
.stat-card.red    .stat-icon { background: #fee2e2; color: var(--red); }

/* ── Quick Actions ─────────────────────────────────────────────── */
.section-title {
  font-size: .85rem; font-weight: 600;
  color: var(--text-muted); text-transform: uppercase;
  letter-spacing: .05em;
  margin: 1rem 0 .5rem;
}
.quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem;
  margin-bottom: 1rem;
}
.quick-btn {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  font-size: .9rem; font-weight: 600;
  transition: all .2s;
  box-shadow: var(--shadow);
}
.quick-btn i { font-size: 1.6rem; }
.quick-btn:active { transform: scale(.97); }
.quick-btn.blue   { color: var(--primary);  border-color: var(--primary-pale); }
.quick-btn.green  { color: var(--green);    border-color: #bbf7d0; }
.quick-btn.teal   { color: var(--teal);     border-color: #a5f3fc; }
.quick-btn.purple { color: var(--purple);   border-color: #ddd6fe; }
.quick-btn:hover  { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

/* ── Tabs ─────────────────────────────────────────────────────── */
.tab-bar {
  display: flex; gap: .5rem;
  margin-bottom: 1rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: .4rem;
  box-shadow: var(--shadow);
}
.tab-btn {
  flex: 1;
  background: none; border: none;
  padding: .75rem .5rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: .9rem; font-weight: 500;
  color: var(--text-muted);
  transition: all .2s;
  display: flex; align-items: center; justify-content: center; gap: .4rem;
}
.tab-btn.active {
  background: var(--primary);
  color: white;
  box-shadow: 0 2px 8px rgba(30,64,175,.3);
}
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ── Forms ────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1rem; }
.form-group label {
  display: block; font-size: .875rem; font-weight: 500;
  margin-bottom: .4rem; color: var(--text);
}

input[type="text"], input[type="email"], input[type="tel"],
input[type="number"], input[type="password"], input[type="date"],
input[type="time"], select, textarea {
  width: 100%;
  padding: .75rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 1rem;
  color: var(--text);
  background: var(--bg-card);
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none;
  appearance: none;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary-light);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}
textarea { resize: vertical; }

.input-plate {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  text-align: center !important;
  letter-spacing: .1em !important;
  text-transform: uppercase !important;
}

.input-search-row {
  display: flex; gap: .5rem;
}
.input-search-row input { flex: 1; }

.input-password { position: relative; }
.input-password input { padding-right: 3rem; }
.btn-toggle-password {
  position: absolute; right: .75rem; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  cursor: pointer; color: var(--text-muted);
  font-size: 1rem; padding: .25rem;
}

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .75rem 1.25rem;
  border: none; border-radius: var(--radius-sm);
  font-family: var(--font); font-size: .95rem; font-weight: 600;
  cursor: pointer; transition: all .2s;
  text-decoration: none;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }

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

.btn-success  { background: var(--green);          color: white; }
.btn-success:hover  { background: #15803d; }

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

.btn-warning  { background: var(--yellow);         color: white; }
.btn-warning:hover  { background: #a16207; }

.btn-outline  {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text);
}
.btn-outline:hover { background: var(--bg); }

.btn-whatsapp { background: #25d366; color: white; }
.btn-whatsapp:hover { background: #128c7e; }

.btn-block { width: 100%; }
.btn-lg { padding: 1rem 1.5rem; font-size: 1.05rem; }
.btn-sm { padding: .5rem .75rem; font-size: .85rem; }

/* ── Payment methods ──────────────────────────────────────────── */
.payment-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .5rem;
}
.payment-opt input { display: none; }
.payment-opt span {
  display: flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .75rem .5rem;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: .875rem; font-weight: 500;
  transition: all .2s;
}
.payment-opt input:checked + span {
  border-color: var(--primary);
  background: var(--primary-pale);
  color: var(--primary);
}

/* ── Entry result ─────────────────────────────────────────────── */
.entry-success {
  text-align: center;
}
.success-icon { font-size: 3rem; color: var(--green); margin-bottom: .75rem; }
.result-info  { background: var(--bg); border-radius: var(--radius-sm); padding: 1rem; margin: 1rem 0; }
.result-row   { display: flex; justify-content: space-between; align-items: center; padding: .4rem 0; }
.result-row:not(:last-child) { border-bottom: 1px solid var(--border); }
.monthly-badge span { background: #ede9fe; color: var(--purple); padding: .3rem .75rem; border-radius: 20px; font-size: .85rem; font-weight: 600; }

/* ── Exit card ────────────────────────────────────────────────── */
.exit-info-card { }
.plate-badge {
  font-size: 2rem; font-weight: 900;
  text-align: center;
  background: var(--primary-dark);
  color: white;
  padding: .75rem;
  border-radius: var(--radius-sm);
  letter-spacing: .15em;
  margin-bottom: 1rem;
}
.exit-details { margin-bottom: 1rem; }
.exit-details .result-row { border-bottom: 1px solid var(--border); padding: .6rem 0; }
.exit-details .result-row i { color: var(--primary); margin-right: .3rem; }
.amount-row strong { font-size: 1.4rem; color: var(--green); }

/* ── Receipt ──────────────────────────────────────────────────── */
.receipt-card { }
.receipt-header {
  display: flex; align-items: center; gap: .5rem;
  font-size: 1.1rem; font-weight: 700;
  margin-bottom: 1rem;
  color: var(--primary-dark);
}
.receipt-header i { font-size: 1.3rem; }
.receipt-body { background: var(--bg); border-radius: var(--radius-sm); padding: 1rem; margin-bottom: 1rem; }
.receipt-row {
  display: flex; justify-content: space-between;
  padding: .4rem 0;
  font-size: .9rem;
}
.receipt-row:not(:last-child) { border-bottom: 1px dashed var(--border); }
.receipt-row.total {
  font-size: 1.1rem; font-weight: 700;
  color: var(--primary-dark);
  border-top: 2px solid var(--primary);
  margin-top: .5rem; padding-top: .75rem;
}
.receipt-actions { display: flex; flex-direction: column; gap: .5rem; }

/* ── Service grid ─────────────────────────────────────────────── */
.service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .5rem;
}
.service-opt input { display: none; }
.service-opt label {
  display: flex; flex-direction: column; align-items: center;
  padding: .75rem;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: .875rem; font-weight: 500;
  text-align: center;
  transition: all .2s;
}
.service-opt label .service-price { font-size: .8rem; color: var(--text-muted); margin-top: .2rem; }
.service-opt input:checked + label {
  border-color: var(--primary);
  background: var(--primary-pale);
  color: var(--primary);
}
.amount-display {
  font-size: 1.5rem; font-weight: 700;
  color: var(--green);
  padding: .5rem 0;
}

/* ── Table / History ──────────────────────────────────────────── */
.table-container { overflow-x: auto; }
.data-table {
  width: 100%; border-collapse: collapse;
  font-size: .875rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.data-table th {
  background: var(--primary-dark);
  color: white;
  padding: .75rem 1rem;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}
.data-table td { padding: .75rem 1rem; border-bottom: 1px solid var(--border); }
.data-table tr:hover td { background: var(--bg); }
.data-table tr:last-child td { border-bottom: none; }

/* ── Monthly / Wash list items ───────────────────────────────── */
.client-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  display: flex;
  align-items: flex-start;
  gap: .75rem;
}
.client-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--primary-pale);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0; font-weight: 700;
}
.client-info { flex: 1; min-width: 0; }
.client-name { font-weight: 600; font-size: .95rem; }
.client-plates { font-size: .8rem; color: var(--primary); font-weight: 600; letter-spacing: .05em; }
.client-phone  { font-size: .8rem; color: var(--text-muted); }
.client-actions { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .5rem; }

.badge {
  display: inline-flex; align-items: center; gap: .25rem;
  padding: .2rem .6rem; border-radius: 20px; font-size: .75rem; font-weight: 600;
}
.badge-green  { background: #dcfce7; color: var(--green); }
.badge-red    { background: #fee2e2; color: var(--red); }
.badge-yellow { background: #fef9c3; color: var(--yellow); }
.badge-blue   { background: var(--primary-pale); color: var(--primary); }
.badge-purple { background: #ede9fe; color: var(--purple); }

/* ── Modais ───────────────────────────────────────────────────── */
.modal {
  position: fixed; inset: 0;
  z-index: 300;
  display: flex; align-items: flex-end;
  animation: fadeIn .2s ease;
}
@media (min-width: 600px) {
  .modal { align-items: center; justify-content: center; }
}
.modal.hidden { display: none; }

.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 0;
}
.modal-box {
  position: relative; z-index: 1;
  background: var(--bg-card);
  border-radius: 20px 20px 0 0;
  width: 100%;
  max-height: 90dvh;
  overflow-y: auto;
  animation: slideUp .3s cubic-bezier(.4,0,.2,1);
}
@media (min-width: 600px) {
  .modal-box { border-radius: 20px; max-width: 520px; animation: scaleIn .2s ease; }
  .modal-box.modal-sm { max-width: 400px; }
}

@keyframes slideUp   { from { transform: translateY(100%); } to { transform: translateY(0); } }
@keyframes scaleIn   { from { opacity: 0; transform: scale(.95); } to { opacity: 1; transform: scale(1); } }
@keyframes fadeIn    { from { opacity: 0; } to { opacity: 1; } }

.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem 1.25rem .75rem;
  border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-size: 1.05rem; font-weight: 700; }
.modal-header button {
  background: none; border: none; cursor: pointer;
  font-size: 1.25rem; color: var(--text-muted); padding: .25rem;
}
.modal-body   { padding: 1.25rem; }
.modal-footer {
  display: flex; gap: .75rem; justify-content: flex-end;
  padding: .75rem 1.25rem 1.25rem;
  border-top: 1px solid var(--border);
}

/* ── Reports ──────────────────────────────────────────────────── */
.report-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem;
  margin-bottom: 1rem;
}
.report-stat {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  text-align: center;
}
.report-stat-value { font-size: 1.4rem; font-weight: 700; color: var(--primary); }
.report-stat-label { font-size: .8rem; color: var(--text-muted); margin-top: .2rem; }

/* ── Settings grid ────────────────────────────────────────────── */
.settings-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: .75rem;
  margin-bottom: 1rem;
}
@media (min-width: 600px) {
  .settings-grid { grid-template-columns: 1fr 1fr; }
}

.settings-section-title {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  padding-bottom: .4rem;
  margin: 1.25rem 0 .75rem;
}

.logo-upload-area { margin-bottom: 1rem; }

.logo-preview {
  width: 100%;
  min-height: 130px;
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  color: var(--text-muted);
  font-size: .875rem;
  background: var(--bg);
  cursor: pointer;
  transition: border-color .2s;
  overflow: hidden;
}
.logo-preview:hover { border-color: var(--primary-light); }
.logo-preview i { font-size: 2rem; color: var(--text-light); }
.logo-preview img {
  max-height: 120px;
  max-width: 100%;
  object-fit: contain;
  border-radius: 8px;
}

.login-logo-img {
  width: 120px;
  height: 120px;
  object-fit: contain;
  border-radius: 12px;
  margin: 0 auto .75rem;
  display: block;
}
.login-logo-img.hidden { display: none; }

.login-footer {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: .75rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.login-footer strong { color: var(--primary); }

.sidebar-credits {
  margin-top: .75rem;
  font-size: .68rem;
  color: rgba(255,255,255,.35);
  text-align: center;
  line-height: 1.4;
}

/* ── Toast ────────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 1.5rem; left: 50%;
  transform: translateX(-50%);
  background: #1e293b;
  color: white;
  padding: .85rem 1.5rem;
  border-radius: 40px;
  font-size: .9rem; font-weight: 500;
  z-index: 500;
  box-shadow: var(--shadow-lg);
  max-width: calc(100vw - 2rem);
  text-align: center;
  animation: toastIn .3s ease;
}
.toast.success { background: var(--green); }
.toast.error   { background: var(--red); }
.toast.warning { background: var(--yellow); }
@keyframes toastIn { from { opacity: 0; transform: translateX(-50%) translateY(20px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }

/* ── Loading ──────────────────────────────────────────────────── */
.loading-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.4);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
}
.loading-spinner { font-size: 2.5rem; color: white; }

/* ── Alerts ───────────────────────────────────────────────────── */
.alert {
  padding: .75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  margin-bottom: 1rem;
}
.alert-danger  { background: #fee2e2; color: var(--red); border: 1px solid #fecaca; }
.alert-success { background: #dcfce7; color: var(--green); border: 1px solid #bbf7d0; }
.alert-warning { background: #fef9c3; color: var(--yellow); border: 1px solid #fde047; }

/* ── Page actions ─────────────────────────────────────────────── */
.page-actions {
  display: flex; gap: .75rem; flex-wrap: wrap;
  margin-bottom: 1rem;
}

/* ── Filter row ───────────────────────────────────────────────── */
.filter-row {
  display: flex; gap: .5rem; align-items: center; flex-wrap: wrap;
}
.filter-row .input-sm { flex: 1; min-width: 120px; }
.input-sm { padding: .6rem .75rem; font-size: .9rem; }
.flex-1 { flex: 1; }

/* ── Patio items ──────────────────────────────────────────────── */
.patio-item {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: .875rem 1rem;
  box-shadow: var(--shadow);
  display: flex; align-items: center; gap: .75rem;
}
.patio-plate { font-size: 1.1rem; font-weight: 800; color: var(--primary-dark); letter-spacing: .08em; }
.patio-meta  { font-size: .8rem; color: var(--text-muted); }
.patio-time  { margin-left: auto; text-align: right; }
.patio-duration { font-size: .9rem; font-weight: 600; color: var(--orange); }
.patio-amount   { font-size: .8rem; color: var(--text-muted); }

/* ── Overdue section ──────────────────────────────────────────── */
.overdue-item {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: var(--radius);
  padding: 1rem;
  display: flex; align-items: center; gap: .75rem;
}
.overdue-item .client-avatar { background: #ffedd5; color: var(--orange); }

/* ── Responsive Desktop ───────────────────────────────────────── */
@media (min-width: 768px) {
  .sidebar {
    transform: translateX(0);
    position: fixed;
  }
  .sidebar-overlay { display: none !important; }
  .app-header { left: var(--sidebar-w); }
  .main-content { margin-left: var(--sidebar-w); }
  .btn-menu { display: none; }

  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .quick-actions { grid-template-columns: repeat(4, 1fr); }

  .tab-content, .page { max-width: 800px; margin-left: auto; margin-right: auto; }
}

@media (min-width: 1024px) {
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .main-content { padding: 1.5rem 2rem; }
}

/* ── Scrollbar ────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-light); }

/* ── Pix brand fix ────────────────────────────────────────────── */
.fa-pix::before { content: "PIX"; font-style: normal; font-size: .8em; }
