/* ============================================================
   styles.css — QuilpuéFix
   Fuente: DM Sans (display) + JetBrains Mono (accents)
   Paleta: dark tech + electric blue
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;700&display=swap');

/* ============================================================
   CSS VARIABLES
   ============================================================ */
:root {
  --bg:         #0A0F1E;
  --bg-card:    #111827;
  --bg-input:   #1a2236;
  --bg-hover:   #1e2d42;
  --border:     #1e2d42;
  --border-bright: #2a3f5c;

  --blue:       #2563EB;
  --blue-light: #3B82F6;
  --cyan:       #38BDF8;
  --cyan-dim:   #0ea5e940;

  --white:      #F8FAFC;
  --gray-100:   #E2E8F0;
  --gray-400:   #94A3B8;
  --gray-500:   #64748B;
  --gray-600:   #475569;

  --green:      #22C55E;
  --green-dim:  #16a34a;
  --yellow:     #FACC15;
  --orange:     #F97316;
  --red:        #EF4444;
  --purple:     #A855F7;
  --teal:       #14B8A6;

  --radius:     10px;
  --radius-lg:  16px;
  --shadow:     0 4px 24px rgba(0,0,0,0.4);
  --shadow-lg:  0 8px 40px rgba(0,0,0,0.6);

  --font:       'DM Sans', system-ui, sans-serif;
  --mono:       'JetBrains Mono', monospace;
  --transition: 0.18s ease;
}

/* ============================================================
   BASE RESET
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ============================================================
   UTILITY
   ============================================================ */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.text-blue  { color: var(--cyan); }
.text-gray  { color: var(--gray-400); }
.text-green { color: var(--green); }
.text-center { text-align: center; }
.truncate   { max-width: 180px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.empty      { color: var(--gray-500); font-style: italic; padding: 1rem 0; }
.error      { color: var(--red); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  border: none;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: var(--blue);
  color: var(--white);
}
.btn-primary:hover { background: var(--blue-light); transform: translateY(-1px); }

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

.btn-ghost {
  background: var(--bg-hover);
  color: var(--gray-100);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--border-bright); }

.btn-danger-ghost {
  background: transparent;
  color: var(--red);
  border: 1px solid transparent;
}
.btn-danger-ghost:hover { background: rgba(239,68,68,0.1); border-color: var(--red); }

.btn-whatsapp {
  background: #25D366;
  color: #fff;
}
.btn-whatsapp:hover { background: #1ebd59; }

.btn-sm { padding: 0.35rem 0.75rem; font-size: 13px; }

.btn-lg {
  padding: 0.85rem 2rem;
  font-size: 16px;
  border-radius: 12px;
}

/* ============================================================
   BADGES
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-family: var(--mono);
}

.badge-gray   { background: rgba(100,116,139,0.2); color: var(--gray-400); }
.badge-blue   { background: rgba(37,99,235,0.2);   color: var(--blue-light); }
.badge-purple { background: rgba(168,85,247,0.2);  color: var(--purple); }
.badge-yellow { background: rgba(250,204,21,0.2);  color: var(--yellow); }
.badge-orange { background: rgba(249,115,22,0.2);  color: var(--orange); }
.badge-green  { background: rgba(34,197,94,0.2);   color: var(--green); }
.badge-teal   { background: rgba(20,184,166,0.2);  color: var(--teal); }
.badge-red    { background: rgba(239,68,68,0.2);   color: var(--red); }

/* ============================================================
   FORMS
   ============================================================ */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-group.full { grid-column: 1 / -1; }

label {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
  background: var(--bg-input);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  color: var(--white);
  padding: 0.6rem 0.85rem;
  font-size: 14px;
  transition: var(--transition);
  width: 100%;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(56,189,248,0.15);
}

select option { background: var(--bg-card); }

textarea { resize: vertical; min-height: 80px; }

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.card-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
}
.card-header h3 { font-size: 15px; font-weight: 700; }
.card-body { padding: 1.25rem; }

/* ============================================================
   TABLES
   ============================================================ */
.table-wrap { overflow-x: auto; }

.data-table, .mini-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table th,
.mini-table th {
  background: var(--bg);
  color: var(--gray-400);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 700;
  white-space: nowrap;
  border-bottom: 1px solid var(--border);
}

.data-table td,
.mini-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.data-table tr:last-child td,
.mini-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td,
.mini-table tr:hover td { background: var(--bg-hover); }

.data-table .actions { white-space: nowrap; display: flex; gap: 0.25rem; }
.clickable { cursor: pointer; }
.row-dim td { opacity: 0.5; }

/* ============================================================
   TOAST
   ============================================================ */
#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  z-index: 9999;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--white);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow);
  transform: translateX(120%);
  transition: transform 0.25s ease;
  max-width: 320px;
}
.toast.show { transform: translateX(0); }
.toast-success { border-left: 3px solid var(--green); }
.toast-error   { border-left: 3px solid var(--red); }

/* ============================================================
   MODAL
   ============================================================ */
#modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
#modal-overlay.active { display: flex; }

#modal {
  background: var(--bg-card);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 680px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
}

#modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
#modal-title { font-size: 17px; font-weight: 700; }
#modal-close {
  background: none; border: none; color: var(--gray-500);
  font-size: 22px; line-height: 1; padding: 0.25rem;
  transition: color var(--transition);
}
#modal-close:hover { color: var(--white); }

#modal-body { padding: 1.5rem; overflow-y: auto; }

#modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

/* ============================================================
   SPINNER / LOADING
   ============================================================ */
.loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem;
  gap: 1rem;
  color: var(--gray-500);
}
.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--cyan);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   REVEAL ANIMATIONS (index)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* ============================================================
   ▌INDEX.HTML — PUBLIC PAGE
   ============================================================ */

/* — NAVBAR — */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1.1rem 0;
  transition: background var(--transition), box-shadow var(--transition);
}
#navbar.scrolled {
  background: rgba(10,15,30,0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.nav-logo {
  font-size: 1.35rem;
  font-weight: 800;
  font-family: var(--mono);
  letter-spacing: -0.02em;
}
.nav-logo span { color: var(--cyan); }

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-menu a {
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-400);
  transition: color var(--transition);
}
.nav-menu a:hover { color: var(--white); }

.nav-cta { display: flex; align-items: center; gap: 1rem; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  width: 24px; height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
  display: block;
}
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* — HERO — */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 60% 40%, rgba(37,99,235,0.18) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(56,189,248,0.08) 0%, transparent 70%);
}

.hero-grid-lines {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(56,189,248,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56,189,248,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
}

.hero-content {
  position: relative;
  max-width: 680px;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--cyan-dim);
  border: 1px solid var(--cyan);
  color: var(--cyan);
  border-radius: 999px;
  padding: 0.3rem 1rem;
  font-size: 13px;
  font-weight: 600;
  font-family: var(--mono);
  margin-bottom: 1.5rem;
}

.hero-content h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
}
.hero-content h1 em {
  font-style: normal;
  color: var(--cyan);
}

.hero-content p {
  font-size: 1.05rem;
  color: var(--gray-400);
  max-width: 520px;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.hero-btns {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Stats bar */
.hero-stats {
  display: flex;
  gap: 2.5rem;
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}
.stat-item .num {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--white);
  font-family: var(--mono);
}
.stat-item .num .cyan { color: var(--cyan); }
.stat-item p { font-size: 13px; color: var(--gray-500); margin-top: 0.2rem; }

/* — SECTIONS GENERAL — */
section { padding: 6rem 0; }

.section-tag {
  display: inline-block;
  color: var(--cyan);
  font-size: 12px;
  font-weight: 700;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-sub {
  color: var(--gray-400);
  max-width: 540px;
  font-size: 1rem;
  line-height: 1.7;
}

/* — SERVICES — */
#servicios { background: linear-gradient(180deg, var(--bg) 0%, rgba(17,24,39,0.5) 100%); }

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 3rem;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  position: relative;
  overflow: hidden;
}
.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  opacity: 0;
  transition: opacity var(--transition);
}
.service-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.service-card:hover::before { opacity: 1; }

.service-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.service-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 0.5rem; }
.service-card p  { font-size: 13.5px; color: var(--gray-400); line-height: 1.6; }

/* — PRICING — */
#precios { background: var(--bg); }

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 3rem;
}

.price-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
  transition: var(--transition);
}
.price-card:hover { border-color: var(--cyan); }
.price-card.featured {
  border-color: var(--blue);
  background: linear-gradient(135deg, #111827, #1a2236);
  box-shadow: 0 0 30px rgba(37,99,235,0.15);
}
.price-card h3 { font-size: 14px; font-weight: 700; color: var(--gray-100); margin-bottom: 0.5rem; }
.price-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--cyan);
  font-family: var(--mono);
  margin: 0.75rem 0;
}
.price-card p { font-size: 12.5px; color: var(--gray-500); }

.pricing-note {
  text-align: center;
  color: var(--gray-500);
  font-size: 13px;
  margin-top: 1.5rem;
  font-style: italic;
}

/* — CÓMO TRABAJAMOS — */
#como-trabajamos { background: linear-gradient(180deg, rgba(17,24,39,0.5) 0%, var(--bg) 100%); }

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0;
  margin-top: 3rem;
  position: relative;
}

.step {
  text-align: center;
  padding: 1.5rem 1rem;
  position: relative;
}

.step-num {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--blue);
  background: rgba(37,99,235,0.1);
  color: var(--cyan);
  font-family: var(--mono);
  font-weight: 800;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.step h3 { font-size: 14px; font-weight: 700; margin-bottom: 0.4rem; }
.step p  { font-size: 13px; color: var(--gray-500); }

/* — CONFIANZA — */
#confianza { background: var(--bg); }

.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 3rem;
}

.trust-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.trust-icon { font-size: 1.5rem; flex-shrink: 0; }
.trust-item h4 { font-size: 14px; font-weight: 700; margin-bottom: 0.3rem; }
.trust-item p  { font-size: 13px; color: var(--gray-500); }

/* — CTA FINAL — */
#cta {
  background: linear-gradient(135deg, #0d1928 0%, #111827 100%);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
  padding: 5rem 0;
}

#cta h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); font-weight: 800; margin-bottom: 1rem; }
#cta p  { color: var(--gray-400); margin-bottom: 2rem; font-size: 1rem; }

/* — FOOTER — */
footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 3rem 0 2rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-brand .logo { font-size: 1.25rem; font-weight: 800; font-family: var(--mono); }
.footer-brand .logo span { color: var(--cyan); }
.footer-brand p { color: var(--gray-500); font-size: 13px; margin-top: 0.5rem; }

.footer-links { display: flex; gap: 2rem; flex-wrap: wrap; }
.footer-link {
  color: var(--gray-500);
  font-size: 14px;
  transition: color var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.footer-link:hover { color: var(--cyan); }

.footer-copy {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--gray-600);
  font-size: 13px;
}

/* ============================================================
   ▌ADMIN.HTML — PANEL
   ============================================================ */
body.admin-body { overflow: hidden; }

/* — LOGIN — */
#login-screen {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

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

.login-logo {
  font-family: var(--mono);
  font-weight: 800;
  font-size: 1.4rem;
  text-align: center;
  margin-bottom: 2rem;
}
.login-logo span { color: var(--cyan); }

.login-box h2 { font-size: 1.3rem; font-weight: 700; margin-bottom: 1.75rem; text-align: center; }
.login-box .form-group { margin-bottom: 1rem; }
.login-box .form-group label { display: block; }
.login-box button[type="submit"] {
  width: 100%;
  margin-top: 0.75rem;
  padding: 0.75rem;
  font-size: 15px;
  font-weight: 700;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
}
.login-box button[type="submit"]:hover { background: var(--blue-light); }
.login-box button[type="submit"]:disabled { opacity: 0.6; cursor: not-allowed; }

#login-error {
  color: var(--red);
  font-size: 13px;
  text-align: center;
  margin-top: 0.75rem;
  min-height: 1.2em;
}

/* — APP SHELL — */
#app-shell {
  display: none;
  height: 100vh;
  overflow: hidden;
}

/* — TOPBAR — */
#topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 56px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  z-index: 200;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.topbar-logo {
  font-family: var(--mono);
  font-weight: 800;
  font-size: 1.05rem;
}
.topbar-logo span { color: var(--cyan); }

.topbar-divider { color: var(--gray-600); }
.topbar-subtitle { color: var(--gray-500); font-size: 13px; }

.topbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

#user-email { font-size: 13px; color: var(--gray-400); }

#menu-toggle {
  display: none;
  background: none; border: none;
  color: var(--white); font-size: 1.2rem;
  cursor: pointer;
}

/* — SIDEBAR — */
#sidebar {
  position: fixed;
  top: 56px;
  left: 0;
  width: 220px;
  height: calc(100vh - 56px);
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  overflow-y: auto;
  z-index: 150;
  display: flex;
  flex-direction: column;
}

.sidebar-nav { padding: 1rem 0; flex: 1; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1.25rem;
  color: var(--gray-400);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  border-left: 2px solid transparent;
  text-decoration: none;
  background: none; border-right: none; border-top: none; border-bottom: none;
  width: 100%;
  text-align: left;
}
.nav-item:hover { color: var(--white); background: var(--bg-hover); }
.nav-item.active { color: var(--cyan); border-left-color: var(--cyan); background: var(--cyan-dim); }
.nav-item .icon { font-size: 1.05rem; width: 20px; text-align: center; }

.nav-separator { height: 1px; background: var(--border); margin: 0.75rem 0; }

.nav-logout {
  color: var(--red);
  border-left-color: transparent !important;
}
.nav-logout:hover { background: rgba(239,68,68,0.08); color: var(--red); }

/* — MAIN CONTENT — */
#main-content {
  margin-top: 56px;
  margin-left: 220px;
  height: calc(100vh - 56px);
  overflow-y: auto;
  padding: 1.75rem;
}

/* — SECTION HEADER — */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}
.section-header h1 { font-size: 1.5rem; font-weight: 800; }

/* — TOOLBAR — */
.toolbar {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  align-items: center;
}

.search-input {
  flex: 1;
  min-width: 200px;
  max-width: 380px;
}

.filter-select { min-width: 170px; }

.toggle-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 13.5px;
  color: var(--gray-400);
  cursor: pointer;
}

/* — STATS GRID — */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.stat-card.stat-highlight { border-color: rgba(37,99,235,0.4); }
.stat-card.stat-highlight-green { border-color: rgba(34,197,94,0.3); }

.stat-icon { font-size: 1.75rem; }
.stat-value { font-size: 1.4rem; font-weight: 800; font-family: var(--mono); }
.stat-label { font-size: 12px; color: var(--gray-500); margin-top: 0.15rem; }

/* — DASHBOARD GRID — */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.25rem;
}

.followup-list { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }
.followup-list li { display: flex; flex-direction: column; gap: 0.2rem; }
.fu-note { font-size: 14px; font-weight: 500; }
.fu-meta { font-size: 12px; color: var(--gray-500); }

/* — TICKET DETAIL — */
.ticket-detail { display: flex; flex-direction: column; gap: 1.25rem; }
.td-section h4 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--cyan); font-family: var(--mono); margin-bottom: 0.4rem; }
.td-section p  { font-size: 14px; color: var(--gray-100); }
.td-row { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
.fu-list { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.fu-list li { display: flex; align-items: center; gap: 0.5rem; font-size: 13px; }
.fu-list li.completed { text-decoration: line-through; opacity: 0.5; }

/* — CONFIG — */
.config-note { color: var(--gray-400); font-size: 14px; margin-bottom: 1.5rem; }
.config-table { display: flex; flex-direction: column; gap: 0.1rem; }
.config-row { display: flex; padding: 0.75rem 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.config-row span { width: 220px; color: var(--gray-500); flex-shrink: 0; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  .dashboard-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  /* Navbar */
  .nav-menu {
    position: fixed;
    top: 0; right: -100%; bottom: 0;
    width: 260px;
    background: var(--bg-card);
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem 1.5rem 2rem;
    gap: 1.5rem;
    transition: right 0.3s ease;
    border-left: 1px solid var(--border);
    z-index: 200;
  }
  .nav-menu.active { right: 0; }
  .nav-menu a { font-size: 16px; color: var(--white); }
  .hamburger { display: flex; z-index: 300; }
  .nav-cta .btn { display: none; }

  /* Hero */
  .hero-stats { gap: 1.5rem; flex-wrap: wrap; }

  /* Sections */
  section { padding: 4rem 0; }
  .services-grid, .pricing-grid, .trust-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr 1fr; }

  /* Footer */
  .footer-inner { flex-direction: column; }
  .footer-links { gap: 1rem; }

  /* Admin */
  #menu-toggle { display: block; }
  #sidebar {
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 180;
  }
  #sidebar.open { transform: translateX(0); }
  #main-content { margin-left: 0; padding: 1rem; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .form-group.full { grid-column: 1; }
  .toolbar { gap: 0.5rem; }
  .search-input { max-width: 100%; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .hero-btns { flex-direction: column; }
}
