:root {
  --orange: #f97316;
  --orange-dark: #c2410c;
  --orange-deep: #9a3412;
  --amber: #f59e0b;
  --cream: #fdf3ea;
  --cream-2: #ffedd5;
  --bg: #fffcf8;
  --card: #ffffff;
  --text: #1f2937;
  --muted: #4b5563;
  --ink: #18181b;
  --ink-2: #27272a;
  --line: #f0e4d8;
  --line-2: #e7d6c5;
  --blue: #2563eb;
  --green: #15803d;
  --green-bg: #dcfce7;
  --red: #b91c1c;
  --red-bg: #fee2e2;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(31, 41, 55, .08);
  --shadow: 0 4px 16px rgba(194, 65, 12, .08);
  --shadow-lg: 0 12px 36px rgba(194, 65, 12, .16);
  --font: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
.theme-dark {
  --bg: #0b0b0d; --card: #18181b; --cream: #1c1917; --cream-2: #292524; --text: #f4f4f5; --muted: #a1a1aa;
  --line: #27272a; --line-2: #3f3f46; --orange-dark: #fb923c; --orange-deep: #fdba74;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.5; font-size: 16px; }
img { max-width: 100%; display: block; }
a { color: var(--orange-dark); }
a:hover { color: var(--orange-deep); }
h1, h2, h3 { line-height: 1.12; margin: 0; letter-spacing: -.02em; font-weight: 900; }
h1 { font-size: clamp(30px, 4vw, 44px); }
h2 { font-size: clamp(22px, 2.6vw, 30px); }
h3 { font-size: 19px; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 820px; }
.stack { display: flex; flex-direction: column; gap: var(--gap, 16px); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap, 12px); }
.between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.tiny { font-size: 13px; }
.bold { font-weight: 800; }
.center { text-align: center; }
.mt { margin-top: 16px; }
.page { padding-top: 32px; padding-bottom: 72px; }
.eyebrow { font-size: 14px; font-weight: 900; letter-spacing: .1em; color: var(--orange-dark); text-transform: uppercase; }
.split { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.split > .main { flex: 999 1 560px; min-width: 0; }
.split > .side { flex: 1 1 280px; min-width: 0; }
.grid { display: grid; gap: var(--gap, 16px); grid-template-columns: repeat(auto-fill, minmax(var(--min, 240px), 1fr)); }

/* Header */
.site-header { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.site-header .container { display: flex; align-items: center; gap: 12px; padding-top: 10px; padding-bottom: 10px; flex-wrap: wrap; }
.logo { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); font-size: 25px; font-weight: 900; letter-spacing: -.03em; }
.logo .mark { width: 34px; height: 34px; border-radius: 10px; background: var(--orange); display: inline-flex; align-items: center; justify-content: center; }
.logo .ut { color: var(--orange); }
.nav { display: flex; flex-wrap: wrap; gap: 2px; flex: 1 1 auto; }
.nav a { color: var(--muted); text-decoration: none; font-weight: 700; font-size: 15px; padding: 0 12px; min-height: 40px; border-radius: 10px; display: inline-flex; align-items: center; }
.nav a:hover { background: var(--cream); color: var(--text); }
.nav a[aria-current="page"] { background: var(--cream-2); color: var(--orange-deep); font-weight: 900; }
.header-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.icon-btn { position: relative; width: 42px; height: 42px; border-radius: 10px; border: 0; background: var(--cream); display: inline-flex; align-items: center; justify-content: center; color: var(--text); cursor: pointer; text-decoration: none; }
.dot { position: absolute; top: 7px; right: 7px; min-width: 18px; height: 18px; border-radius: 999px; background: var(--orange); color: var(--ink); font-size: 11px; font-weight: 900; display: inline-flex; align-items: center; justify-content: center; padding: 0 4px; }
.avatar { width: 42px; height: 42px; border-radius: 50%; background: #fed7aa; color: var(--orange-deep); display: inline-flex; align-items: center; justify-content: center; font-weight: 900; text-decoration: none; flex-shrink: 0; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 88px; height: 88px; font-size: 34px; border: 4px solid var(--card); }
.avatar.md { width: 56px; height: 56px; font-size: 22px; }
.pill-status { display: inline-flex; align-items: center; gap: 8px; background: var(--ink); color: #fff; text-decoration: none; font-size: 14px; font-weight: 800; padding: 0 14px; min-height: 40px; border-radius: 999px; }
.pill-status:hover { color: #fff; }
.live { width: 9px; height: 9px; border-radius: 50%; background: #4ade80; display: inline-block; }
.live.off { background: #a1a1aa; }
.menu-toggle { display: none; }
@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .nav { display: none; order: 3; flex-basis: 100%; flex-direction: column; }
  .nav.open { display: flex; }
  .pill-status .label { display: none; }
}

/* Botones */
.btn { font-family: inherit; font-size: 16px; font-weight: 900; border: 0; border-radius: var(--radius); padding: 0 20px; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; text-decoration: none; line-height: 1.2; text-align: center; }
.btn-primary { background: var(--orange); color: var(--ink); }
.btn-primary:hover { background: #fb8a3c; color: var(--ink); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #3f3f46; color: #fff; }
.btn-amber { background: var(--amber); color: var(--ink); }
.btn-amber:hover { color: var(--ink); }
.btn-outline { background: transparent; color: var(--text); box-shadow: inset 0 0 0 2px var(--text); }
.btn-outline:hover { background: var(--cream); color: var(--text); }
.btn-soft { background: var(--cream); color: var(--orange-deep); }
.btn-soft:hover { background: var(--cream-2); color: var(--orange-deep); }
.btn-danger { background: transparent; color: var(--red); box-shadow: inset 0 0 0 2px #fca5a5; }
.btn-sm { min-height: 40px; font-size: 14px; padding: 0 14px; }
.btn-lg { min-height: 56px; font-size: 18px; padding: 0 28px; }
.btn-block { width: 100%; }
.link-btn { font: inherit; font-weight: 900; background: none; border: 0; color: var(--orange-dark); cursor: pointer; padding: 0; min-height: 40px; }
button:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }

/* Tarjetas */
.card { background: var(--card); border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow); }
.card.flat { box-shadow: none; }
.card.dark { background: var(--ink); color: #fff; }
.card.dark .muted { color: #d4d4d8; }
.card.cream { background: var(--cream); box-shadow: none; }
.card.ring { box-shadow: inset 0 0 0 2px var(--orange), var(--shadow); }
.card-link { text-decoration: none; color: inherit; display: block; transition: transform .15s ease; }
.card-link:hover { transform: translateY(-2px); color: inherit; }

/* Chips y etiquetas */
.chip { display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: 15px; font-weight: 800; background: var(--card); color: var(--text); border: 1px solid #ead8c6; border-radius: 999px; padding: 0 16px; min-height: 40px; text-decoration: none; cursor: pointer; }
.chip:hover { color: var(--text); background: var(--cream); }
.chip.active, .chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 900; }
.tag { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 900; padding: 4px 10px; border-radius: 999px; background: var(--cream-2); color: var(--orange-deep); }
.tag.amber { background: #fef3c7; color: #92400e; }
.tag.green { background: var(--green-bg); color: #166534; }
.tag.red { background: var(--red-bg); color: #991b1b; }
.tag.gray { background: #f4f4f5; color: #52525b; }
.tag.dark { background: var(--ink); color: var(--amber); }
.ribbon { font-size: 12px; font-weight: 900; padding: 4px 10px; border-radius: 999px; }
.ribbon.azul { background: var(--blue); color: #fff; }
.ribbon.dorado { background: var(--amber); color: var(--ink); }
.dots { color: #d97706; letter-spacing: 2px; font-size: 12px; }

/* Formularios */
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span, .label { font-size: 14px; font-weight: 900; }
.input, .select, .textarea { font-family: inherit; font-size: 16px; color: var(--text); background: var(--card); border: 1px solid var(--line-2); border-radius: var(--radius); padding: 0 14px; min-height: 48px; width: 100%; }
.textarea { padding: 12px 14px; min-height: 110px; resize: vertical; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--orange); outline: 2px solid rgba(249, 115, 22, .25); outline-offset: 0; }
.form-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.check { display: flex; align-items: center; gap: 12px; min-height: 44px; font-weight: 700; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--orange); margin: 0; flex-shrink: 0; }
.choice { border: 2px solid #ead8c6; border-radius: 12px; padding: 12px 14px; display: flex; align-items: center; gap: 10px; font-weight: 800; cursor: pointer; background: var(--card); }
.choice:has(input:checked) { border-color: var(--orange); background: var(--cream-2); }
.choice input { accent-color: var(--orange); margin: 0; }
.choices { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.help { font-size: 13px; color: var(--muted); }
.dropzone { border: 2px dashed #f0b98a; border-radius: 14px; background: #fffbf6; padding: 18px; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; cursor: pointer; }
.theme-dark .dropzone { background: var(--cream); }
.searchbar { background: var(--card); border-radius: var(--radius-lg); padding: 8px; display: flex; flex-wrap: wrap; gap: 8px; box-shadow: 0 8px 24px rgba(194, 65, 12, .12); }
.searchbar label { flex: 1 1 220px; display: flex; flex-direction: column; padding: 4px 12px; gap: 2px; }
.searchbar label + label { border-left: 1px solid var(--line); }
.searchbar label span { font-size: 13px; font-weight: 800; color: var(--muted); }
.searchbar input, .searchbar select { font-family: inherit; font-size: 17px; font-weight: 700; border: 0; padding: 4px 0; color: var(--text); background: transparent; min-height: 32px; }
@media (max-width: 600px) { .searchbar label + label { border-left: 0; border-top: 1px solid var(--line); } }

/* Mensajes flash */
.flash { border-radius: 12px; padding: 12px 16px; font-weight: 800; margin: 16px 0 0; }
.flash.ok { background: var(--green-bg); color: #166534; }
.flash.error { background: var(--red-bg); color: #991b1b; }
.flash.info { background: var(--cream-2); color: var(--orange-deep); }

/* Hero */
.hero { background: radial-gradient(900px 420px at 85% -10%, #fed7aa 0%, rgba(254, 215, 170, 0) 70%), radial-gradient(700px 380px at 0% 0%, #fef3c7 0%, rgba(254, 243, 199, 0) 70%), var(--cream); }
.theme-dark .hero { background: var(--cream); }
.hero-inner { padding: 60px 0 68px; display: flex; flex-wrap: wrap; align-items: center; gap: 44px; }
.hero h1 { font-size: clamp(38px, 5.2vw, 62px); line-height: 1.03; letter-spacing: -.04em; }
.lead { font-size: 20px; color: var(--muted); max-width: 540px; }
.band { padding: 72px 0; }
.band.dark { background: var(--ink); color: #fff; }
.band.cream { background: var(--cream); }
.band.gradient { background: linear-gradient(120deg, var(--orange), var(--amber)); color: var(--ink); }
.section-head { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; margin-bottom: 32px; }

/* Teléfono de ejemplo */
.phone { width: 340px; max-width: 100%; background: var(--ink); border-radius: 40px; padding: 10px; box-shadow: 0 24px 60px rgba(194, 65, 12, .25); margin: 0 auto; }
.phone-screen { background: #f5efe8; border-radius: 32px; overflow: hidden; }
.chat { padding: 16px 12px; display: flex; flex-direction: column; gap: 9px; font-size: 15px; line-height: 1.4; }
.bubble { padding: 9px 12px; border-radius: 14px; max-width: 82%; white-space: pre-line; }
.bubble.in { align-self: flex-start; background: #fff; color: #1f2937; border-bottom-left-radius: 3px; box-shadow: var(--shadow-sm); }
.bubble.out { align-self: flex-end; background: var(--cream-2); color: #1f2937; border-bottom-right-radius: 3px; }
.theme-dark .bubble.out { background: #7c2d12; color: #fff; }
.bubble-meta { font-size: 12px; font-weight: 800; color: var(--orange-deep); align-self: flex-end; }

/* Tarjetas de trabajador */
.worker-card { background: var(--card); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; position: relative; text-decoration: none; color: inherit; }
.worker-card:hover { color: inherit; transform: translateY(-2px); }
.worker-card .band-top { height: 64px; }
.worker-card .body { padding: 0 16px 16px; display: flex; flex-direction: column; gap: 6px; }
.worker-card .avatar { width: 60px; height: 60px; border: 3px solid var(--card); margin-top: -30px; font-size: 24px; }
.worker-card .ribbon { position: absolute; top: 10px; right: 10px; }
.slot-note { background: var(--cream); border-radius: 10px; padding: 8px 10px; font-size: 13px; font-weight: 800; color: var(--orange-deep); }
.responds { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; color: #166534; }
.responds::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #16a34a; }

/* Perfil */
.profile-cover { height: 180px; background: linear-gradient(120deg, var(--orange), var(--amber)); background-size: cover; background-position: center; }
.profile-head { margin-top: -64px; }
.gallery { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.gallery img, .gallery .ph { aspect-ratio: 1; width: 100%; object-fit: cover; border-radius: 12px; background: #fed7aa; }
.slots { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
.slot { font: inherit; border: 2px solid var(--line); background: var(--card); border-radius: 12px; min-height: 56px; padding: 6px; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; color: var(--text); }
.slot small { font-size: 12px; font-weight: 700; color: var(--muted); }
.slot b { font-size: 16px; }
.slot:has(input:checked) { border-color: var(--orange); background: var(--cream-2); }
.slot input { position: absolute; opacity: 0; pointer-events: none; }

/* Tablas */
.table-wrap { background: var(--card); border-radius: var(--radius-lg); overflow-x: auto; box-shadow: var(--shadow); }
.table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 560px; }
.table th { text-align: left; background: var(--cream); padding: 12px 14px; font-weight: 900; }
.table td { padding: 12px 14px; border-top: 1px solid var(--line); vertical-align: middle; }

/* Estadísticas */
.stat { background: var(--card); border-radius: var(--radius-lg); padding: 18px; display: flex; flex-direction: column; gap: 2px; }
.stat .num { font-size: clamp(26px, 6vw, 32px); font-weight: 900; letter-spacing: -.02em; }
.bars { display: flex; align-items: flex-end; gap: 10px; height: 180px; border-bottom: 2px solid var(--line); padding-top: 18px; }
.bars .bar { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; }
.bars .bar i { display: block; width: 100%; max-width: 44px; background: #fdba74; border-radius: 6px 6px 0 0; min-height: 2px; }
.bars .bar:last-child i { background: var(--orange); }
.bars .bar span { font-size: 12px; font-weight: 900; color: var(--muted); }

/* Panel lateral */
.sidenav { display: flex; flex-direction: column; gap: 2px; background: var(--card); border-radius: var(--radius-lg); padding: 10px; }
.sidenav a { color: var(--text); text-decoration: none; font-size: 15px; font-weight: 800; padding: 0 14px; min-height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: space-between; }
.sidenav a:hover { background: var(--cream); }
.sidenav a[aria-current="page"] { background: var(--cream-2); color: var(--orange-deep); font-weight: 900; }

/* Listas */
.list-item { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.list-item:first-child { border-top: 0; }
.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty b { display: block; color: var(--text); font-size: 18px; margin-bottom: 4px; }

/* Mensajes */
.inbox { display: flex; flex-wrap: wrap; background: var(--card); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); min-height: 560px; }
.inbox-list { flex: 1 1 300px; border-right: 1px solid var(--line); display: flex; flex-direction: column; }
.inbox-list a { display: flex; gap: 12px; padding: 14px 18px; text-decoration: none; color: var(--text); border-left: 4px solid transparent; border-bottom: 1px solid var(--line); }
.inbox-list a[aria-current="true"] { background: var(--cream-2); border-left-color: var(--orange); }
.inbox-chat { flex: 999 1 480px; display: flex; flex-direction: column; min-width: 0; }
.inbox-thread { flex: 1; background: var(--bg); padding: 20px; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; max-height: 60vh; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Reels */
.reel { aspect-ratio: 9 / 16; border-radius: var(--radius-lg); background: linear-gradient(160deg, #c2410c, #18181b); position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; padding: 14px; color: #fff; text-decoration: none; }
.reel:hover { color: #fff; }
.reel .shade { background: linear-gradient(to top, rgba(24, 24, 27, .92), rgba(24, 24, 27, 0)); margin: -14px; padding: 40px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.reel .play { position: absolute; top: 50%; left: 50%; width: 54px; height: 54px; margin: -27px 0 0 -27px; border-radius: 50%; background: rgba(24, 24, 27, .7); display: flex; align-items: center; justify-content: center; }

/* Pie */
.site-footer { background: var(--ink); color: #d4d4d8; }
.site-footer .container { padding: 32px 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; font-size: 15px; }
.site-footer a { color: #d4d4d8; }

/* Precios */
.price { font-size: 46px; font-weight: 900; letter-spacing: -.03em; }
.price small { font-size: 16px; font-weight: 700; color: var(--muted); letter-spacing: 0; }
.plan-card { position: relative; display: flex; flex-direction: column; gap: 16px; }
.plan-card .flag { position: absolute; top: -14px; left: 24px; }
.ticks { display: flex; flex-direction: column; gap: 10px; font-weight: 700; margin: 0; padding: 0; list-style: none; }
.ticks li { display: flex; gap: 10px; }
.ticks li::before { content: '✓'; color: var(--orange-dark); font-weight: 900; }
.card.dark .ticks li::before { color: var(--amber); }

.swatch { width: 48px; height: 48px; border-radius: 12px; border: 1px solid var(--line-2); cursor: pointer; position: relative; }
.swatch input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.swatch:has(input:checked) { box-shadow: 0 0 0 3px var(--orange); }
.swatch.locked { opacity: .45; cursor: not-allowed; }
.progress { height: 10px; background: #f5ece3; border-radius: 999px; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--orange); }

details.faq { background: var(--card); border-radius: 14px; padding: 0 20px; box-shadow: var(--shadow-sm); }
details.faq summary { font-size: 17px; font-weight: 800; min-height: 56px; display: flex; align-items: center; cursor: pointer; }
details.faq p { padding-bottom: 18px; color: var(--muted); }
.grid.fit { grid-template-columns: repeat(auto-fit, minmax(var(--min, 240px), 1fr)); }
.field > .help { font-weight: 400; font-size: 13px; color: var(--muted); }
input[type="time"].input { width: 150px; }
.stack > *, .split > * { min-width: 0; }
.table-wrap { max-width: 100%; position: relative; }
