/* Luxcar · estilos
   Layout: showroom con ficha técnica. Bandas negras arriba y abajo para el logo dorado,
   dorado del logo como único acento, datos en monoespaciada, tarjetas con foto primero. */
:root {
  --bg: #F1F1EF;
  --surface: #FFFFFF;
  --surface-2: #F6F6F4;
  --ink: #141414;
  --muted: #5F5E59;
  --line: #DDDCD6;
  --accent: #C9A443;
  --accent-hover: #B8922F;
  --accent-ink: #121212;
  --accent-soft: #F4EBCF;
  --accent-text: #8A6815;
  --gold: #8A6815;
  --warn: #8F540A;
  --warn-soft: #F6E7CF;
  --bad: #A3241C;
  --bad-soft: #F6DAD7;
  --wa: #C9A443;
  --wa-ink: #121212;
  --band: #0D0D0D;
  --band-2: #1C1C1C;
  --band-line: #2A2A2A;
  --band-ink: #F2F2F0;
  --band-muted: #A9A8A2;
  --band-gold: #D6B655;
  --ph-a: #E6E5E1;
  --ph-b: #D6D5CF;
  --ph-car: #B9B8B1;
  --overlay: rgba(8, 8, 8, .93);
  --on-ovl: #F2F2F0;
  --shadow: 0 1px 2px rgba(20, 20, 20, .05), 0 10px 30px -12px rgba(20, 20, 20, .22);

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --r: 4px;
  --r-lg: 10px;
  --maxw: 1200px;
  --hdr-h: 80px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0A0A0A; --surface: #151515; --surface-2: #1C1C1B; --ink: #EDEDEA; --muted: #A3A29B; --line: #2A2A28;
    --accent: #D3B04F; --accent-hover: #E2C266; --accent-ink: #111111; --accent-soft: #2B2513; --accent-text: #DDBD62;
    --gold: #DDBD62; --warn: #E8A951; --warn-soft: #33260F; --bad: #F2867B; --bad-soft: #3A1916;
    --wa: #D3B04F; --wa-ink: #111111;
    --band: #000000; --band-2: #161616; --band-line: #222222; --band-ink: #F2F2F0; --band-muted: #9C9B95; --band-gold: #D6B655;
    --ph-a: #1A1A19; --ph-b: #242422; --ph-car: #3A3A37;
    --overlay: rgba(0, 0, 0, .94);
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 12px 32px -12px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0A0A0A; --surface: #151515; --surface-2: #1C1C1B; --ink: #EDEDEA; --muted: #A3A29B; --line: #2A2A28;
  --accent: #D3B04F; --accent-hover: #E2C266; --accent-ink: #111111; --accent-soft: #2B2513; --accent-text: #DDBD62;
  --gold: #DDBD62; --warn: #E8A951; --warn-soft: #33260F; --bad: #F2867B; --bad-soft: #3A1916;
  --wa: #D3B04F; --wa-ink: #111111;
  --band: #000000; --band-2: #161616; --band-line: #222222; --band-ink: #F2F2F0; --band-muted: #9C9B95; --band-gold: #D6B655;
  --ph-a: #1A1A19; --ph-b: #242422; --ph-car: #3A3A37;
  --overlay: rgba(0, 0, 0, .94);
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 12px 32px -12px rgba(0, 0, 0, .6);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10;
  background: var(--band);
}
img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }

.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.sel { user-select: all; -webkit-user-select: all; }
.eyebrow {
  font-family: var(--f-mono); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); font-weight: 500;
}
.caps {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 750;
  text-transform: uppercase; letter-spacing: .02em; line-height: 1.12;
}
.lead { font-size: 1.1rem; max-width: 60ch; }
.h3 { font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 1.25rem; line-height: 1.2; }
.mt { margin-top: 10px; }
.note {
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r);
  padding: 12px 14px; font-size: .92rem;
}

/* Barra de demostración y de administración */
.demo-bar {
  background: var(--warn-soft); color: var(--warn); font-size: .85rem; font-weight: 600;
  text-align: center; padding-block: 8px;
}
.abar { background: var(--ink); color: var(--bg); font-size: .85rem; }
.abar-in { display: flex; align-items: center; gap: 6px 18px; flex-wrap: wrap; min-height: 42px; padding-block: 6px; }
.abar .tag { font-family: var(--f-mono); letter-spacing: .1em; text-transform: uppercase; font-size: .7rem; opacity: .75; margin-right: auto; }
.abar a, .abar button {
  color: inherit; background: none; border: 0; padding: 4px 0; cursor: pointer; font-size: inherit;
  text-decoration: underline; text-underline-offset: 3px;
}

/* Encabezado */
.hdr { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--band); color: var(--band-ink); border-bottom: 1px solid var(--band-line); }
.hdr-in { display: flex; align-items: center; gap: 20px; min-height: var(--hdr-h); }
.brand { display: flex; align-items: center; text-decoration: none; margin-right: auto; min-width: 0; }
.brand .logo-img { height: 58px; max-height: none; width: auto; max-width: 100%; }
.ftr .brand .logo-img { height: 64px; }
@media (max-width: 520px) { .brand .logo-img { height: 44px; } }
.wordmark {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 800; font-size: 1.32rem;
  letter-spacing: .09em; line-height: 1; white-space: nowrap; color: var(--band-ink);
}
.wordmark::after {
  content: ""; display: inline-block; width: .38em; height: .38em; margin-left: .2em;
  background: var(--accent); border-radius: 1px; vertical-align: baseline;
}
.nav { display: flex; gap: 2px; }
.nav a {
  padding: 8px 12px; border-radius: var(--r); text-decoration: none; font-weight: 500;
  font-size: .95rem; color: var(--band-muted); white-space: nowrap;
}
.nav a:hover { color: var(--band-ink); background: var(--band-2); }
.nav a.on { color: var(--band-ink); box-shadow: inset 0 -2px 0 var(--band-gold); border-radius: 0; }
.nav-toggle {
  display: none; width: 44px; height: 44px; border: 1px solid var(--band-line); border-radius: var(--r);
  background: transparent; color: var(--band-ink); cursor: pointer; align-items: center; justify-content: center;
}
.nav-toggle svg { width: 22px; height: 22px; }
@media (max-width: 960px) {
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column;
    background: var(--band); border-bottom: 1px solid var(--band-line); box-shadow: var(--shadow);
    padding: 8px max(16px, env(safe-area-inset-right, 0px)) 16px max(16px, env(safe-area-inset-left, 0px));
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px; font-size: 1rem; }
  .nav a.on { box-shadow: inset 3px 0 0 var(--band-gold); }
  .nav-toggle { display: inline-flex; }
  .hdr-wa span { display: none; }
  .hdr-wa { padding: 10px; }
}

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 18px; border-radius: var(--r); border: 1px solid transparent;
  font-weight: 600; font-size: .95rem; line-height: 1.2; text-decoration: none; cursor: pointer;
  background: none; transition: background-color .15s, border-color .15s, color .15s, filter .15s;
  text-align: center;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { border-color: var(--line); background: var(--surface); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-wa { background: var(--wa); color: var(--wa-ink); }
.btn-wa:hover { filter: brightness(1.07); }
.btn-danger { color: var(--bad); border-color: var(--line); background: var(--surface); }
.btn-danger:hover { border-color: var(--bad); }
.btn-sm { padding: 8px 12px; font-size: .875rem; }
.btn-sm svg { width: 16px; height: 16px; }
.btn-link { border: 0; background: none; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; padding: 8px 4px; }
.btn-link:hover { color: var(--ink); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
body.busy .btn { cursor: progress; }
.lnk {
  background: none; border: 0; padding: 0; color: var(--accent-text); font-weight: 600; cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px; font-size: inherit;
}
.links { display: flex; gap: 6px 16px; flex-wrap: wrap; margin-top: 6px; }
.links a { color: var(--accent-text); font-weight: 600; text-decoration: none; }
.links a:hover { text-decoration: underline; }

/* Portada */
.hero { background: var(--surface); border-bottom: 1px solid var(--line); }
.hero-in {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 48px; align-items: center;
  padding-block: clamp(32px, 6vw, 76px);
}
.hero-title {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 800;
  font-size: clamp(2rem, 1.05rem + 3.4vw, 3.8rem); line-height: 1.02; letter-spacing: -.015em; margin-top: 14px;
}
.hero-text { margin-top: 18px; font-size: 1.1rem; color: var(--muted); max-width: 50ch; }
.search {
  margin-top: 28px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 8px;
  padding: 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-lg);
}
.hero-stats { display: flex; gap: 6px 22px; flex-wrap: wrap; margin-top: 18px; font-size: .82rem; color: var(--muted); }
.hero-stats b { color: var(--ink); font-weight: 500; }
.hero-card {
  display: flex; flex-direction: column; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; text-decoration: none; color: inherit; min-width: 0;
}
.hero-card .card-media { aspect-ratio: 16 / 10; }
.hero-card-body { display: flex; justify-content: space-between; align-items: end; gap: 10px 16px; padding: 18px 20px; flex-wrap: wrap; }
.hero-card-title { font-size: 1.28rem; margin-top: 4px; }
@media (hover: hover) { a.hero-card:hover { border-color: var(--muted); } }
@media (max-width: 900px) {
  .hero-in { grid-template-columns: 1fr; gap: 32px; }
  .search { grid-template-columns: 1fr 1fr; }
  .search .btn { grid-column: 1 / -1; }
}
@media (max-width: 520px) { .search { grid-template-columns: 1fr; } }

/* Secciones */
.sec { padding-block: clamp(40px, 6vw, 72px); }
.sec + .sec { padding-top: 0; }
.sec-head { display: flex; align-items: end; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 24px; }
.sec-title { font-family: var(--f-display); font-stretch: 118%; font-weight: 750; font-size: clamp(1.4rem, 1rem + 1.4vw, 2rem); line-height: 1.1; }
.more { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; color: var(--accent-text); }
.more svg { width: 18px; height: 18px; }
.page-head { background: var(--surface); border-bottom: 1px solid var(--line); padding-block: 28px 26px; }
.page-title { font-family: var(--f-display); font-stretch: 125%; font-weight: 800; font-size: clamp(1.7rem, 1.1rem + 2vw, 2.6rem); line-height: 1.05; margin-top: 8px; }
.page-sub { margin-top: 10px; color: var(--muted); max-width: 62ch; }

/* Tarjetas de autos */
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 268px), 1fr)); }
.card {
  display: flex; flex-direction: column; min-width: 0; background: var(--surface); color: inherit;
  border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; text-decoration: none;
  transition: border-color .15s, transform .15s;
}
@media (hover: hover) { .card:hover { border-color: var(--muted); transform: translateY(-2px); } }
.card-media {
  position: relative; aspect-ratio: 4 / 3; max-width: 100%; overflow: hidden;
  background: linear-gradient(160deg, var(--ph-a), var(--ph-b)); display: grid; place-items: center;
}
.card-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sil { width: 76%; height: auto; }
.sil .b { fill: var(--ph-car); }
.sil .g { fill: var(--ph-b); }
.sil .h { fill: var(--ph-a); }
.sil .m { fill: none; stroke: var(--ph-car); stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; }
.badges { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.badges.inline { position: static; }
.badges.r { left: auto; right: 10px; }
.badge {
  display: inline-block; font-family: var(--f-mono); font-size: .66rem; letter-spacing: .08em;
  text-transform: uppercase; padding: 4px 8px; border-radius: 3px; font-weight: 500; line-height: 1.25;
}
.b-new { background: var(--accent); color: var(--accent-ink); }
.b-res { background: var(--warn-soft); color: var(--warn); }
.b-sold { background: var(--band); color: var(--band-gold); border: 1px solid var(--band-gold); font-size: .72rem; padding: 5px 10px; }
.b-ex { background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.card-body { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px 18px; flex: 1; }
.card-title { font-size: 1rem; }
.card-ver { color: var(--muted); font-size: .92rem; }
.specs { color: var(--muted); font-size: .8rem; margin-top: 4px; }
.specs span + span::before { content: "·"; margin: 0 7px; color: var(--muted); opacity: .6; }
.card-price, .price {
  font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 1.22rem;
  font-variant-numeric: tabular-nums; margin-top: auto; padding-top: 10px;
}
.empty {
  grid-column: 1 / -1; padding: 40px 24px; text-align: center; background: var(--surface);
  border: 1px dashed var(--line); border-radius: var(--r-lg); display: flex; flex-direction: column; gap: 12px; align-items: center;
}
.sk { background: linear-gradient(90deg, var(--ph-a), var(--ph-b), var(--ph-a)); background-size: 200% 100%; animation: sk 1.4s ease infinite; border-radius: 4px; }
@keyframes sk { to { background-position: -200% 0; } }
.sk-card { min-height: 320px; border-radius: var(--r-lg); }

/* Bloques de servicios y nosotros */
.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.duo a {
  display: flex; flex-direction: column; gap: 12px; padding: clamp(24px, 4vw, 40px); min-height: 230px;
  border-radius: var(--r-lg); text-decoration: none; border: 1px solid var(--line); background: var(--surface);
}
.duo a.alt { background: var(--band); color: var(--band-ink); border-color: var(--band); }
.duo a.alt .eyebrow, .duo a.alt .go { color: var(--band-gold); }
.duo a .go { color: var(--accent-text); }
.duo h3 { font-family: var(--f-display); font-stretch: 118%; font-weight: 750; font-size: 1.5rem; line-height: 1.15; }
.duo p { max-width: 46ch; opacity: .88; }
.duo .go { margin-top: auto; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.duo .go svg { width: 18px; height: 18px; }
@media (max-width: 720px) { .duo { grid-template-columns: 1fr; } }
.about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 48px; align-items: start; }
.about .lead { margin-top: 12px; color: var(--muted); }
.pts > div { border-top: 1px solid var(--line); padding-block: 18px; display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 16px; }
.pts h3 { font-size: 1rem; font-weight: 650; }
@media (max-width: 800px) { .about { grid-template-columns: 1fr; gap: 24px; } .pts > div { grid-template-columns: 1fr; gap: 4px; } }
.visit {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 24px;
  padding: clamp(20px, 3vw, 28px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
}
.info-item { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 12px; }
.info-item > svg { width: 20px; height: 20px; color: var(--accent-text); margin-top: 3px; }
.info-item h3 { margin-bottom: 4px; }
.info { display: flex; flex-direction: column; gap: 22px; }

/* Stock y filtros */
.stock-in { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 32px; padding-block: 28px 64px; }
.fform { display: flex; flex-direction: column; gap: 14px; position: sticky; top: calc(var(--hdr-h) + 18px + env(safe-area-inset-top, 0px)); }
.results-bar { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; margin-bottom: 16px; min-height: 40px; }
.sort { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.mob-filt { display: none; }
@media (max-width: 900px) {
  .stock-in { grid-template-columns: 1fr; gap: 16px; }
  .filters { display: none; }
  .filters.open { display: block; }
  .fform { position: static; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
  .mob-filt { display: flex; }
}

/* Formularios */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span, .lbl { font-size: .8rem; font-weight: 600; color: var(--muted); }
.help { color: var(--muted); font-size: .78rem; }
.inp {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--r);
  background: var(--surface); color: var(--ink); font-size: 16px; line-height: 1.3; min-width: 0;
}
.inp:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-soft); }
textarea.inp { min-height: 96px; resize: vertical; }
.inp.bad { border-color: var(--bad); box-shadow: 0 0 0 3px var(--bad-soft); }
.inp-sm { padding: 6px 8px; font-size: .875rem; width: auto; }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.g3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.check { display: flex; align-items: center; gap: 10px; font-size: .95rem; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.range { width: 100%; accent-color: var(--accent); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.seg { display: flex; flex-direction: column; gap: 8px; }
.seg-o { display: flex; gap: 6px; flex-wrap: wrap; }
.seg-o label { position: relative; }
.seg-o input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg-o span {
  display: inline-block; padding: 9px 14px; border: 1px solid var(--line); border-radius: 999px;
  font-weight: 600; font-size: .9rem; background: var(--surface); cursor: pointer;
}
.seg-o input:checked + span { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.seg-o input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 40px; align-items: start; padding-block: 36px 64px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(18px, 3vw, 28px); min-width: 0; }
.form { display: flex; flex-direction: column; gap: 14px; position: relative; }
.form-note { font-size: .86rem; color: var(--muted); }
.form-note.ok { color: var(--accent-text); font-weight: 600; }
.form-note.err, .err { color: var(--bad); font-weight: 600; font-size: .9rem; }
.stack { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; counter-reset: s; }
.steps li { counter-increment: s; padding-top: 14px; border-top: 2px solid var(--ink); }
.steps li::before { content: counter(s, decimal-leading-zero); font-family: var(--f-mono); font-size: .78rem; color: var(--accent-text); display: block; margin-bottom: 4px; }
.steps h3 { font-size: 1.02rem; font-weight: 650; margin-bottom: 2px; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .g3, .row2 { grid-template-columns: 1fr; } }

.sim-out { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sim-out > div { background: var(--surface-2); border-radius: var(--r); padding: 14px; min-width: 0; }
.sim-out .big { grid-column: 1 / -1; background: var(--accent-soft); }
.sim-out .v { font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 1.25rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.sim-out .big .v { font-size: 2rem; color: var(--accent-text); }

/* Ficha del auto */
.det { padding-block: 22px 64px; }
.back {
  display: inline-flex; gap: 6px; align-items: center; font-weight: 600; text-decoration: none;
  color: var(--muted); margin-bottom: 16px; background: none; border: 0; padding: 0; cursor: pointer;
}
.back svg { width: 18px; height: 18px; }
.back:hover { color: var(--ink); }
.det-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.gal-main { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-lg); overflow: hidden; background: linear-gradient(160deg, var(--ph-a), var(--ph-b)); display: grid; place-items: center; }
.gal-main img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; }
.gal-pend { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; }
.gal-nav, .lb-btn {
  position: absolute; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--surface);
  color: var(--ink); box-shadow: var(--shadow); display: grid; place-items: center; cursor: pointer;
}
.gal-nav { top: 50%; transform: translateY(-50%); opacity: .94; }
.gal-nav svg, .lb-btn svg { width: 22px; height: 22px; }
.gal-prev { left: 12px; }
.gal-next { right: 12px; }
.gal-count { position: absolute; right: 12px; bottom: 12px; background: var(--surface); padding: 4px 8px; border-radius: 3px; font-size: .74rem; }
.thumbs { display: flex; gap: 8px; overflow-x: auto; margin-top: 10px; padding-bottom: 4px; }
.thumbs button { flex: none; width: 88px; aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; border: 2px solid transparent; padding: 0; background: var(--ph-a); cursor: pointer; }
.thumbs button.on { border-color: var(--accent); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
.det-info {
  position: sticky; top: calc(var(--hdr-h) + 20px + env(safe-area-inset-top, 0px));
  display: flex; flex-direction: column; gap: 14px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(18px, 3vw, 26px); min-width: 0;
}
.det-title { font-size: clamp(1.45rem, 1.05rem + 1.4vw, 2.05rem); }
.det-ver { color: var(--muted); font-size: 1.05rem; margin-top: 4px; }
.det-sub { font-weight: 600; color: var(--accent-text); }
.det-price { font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 2rem; font-variant-numeric: tabular-nums; line-height: 1.1; }
.det-ctas { display: grid; gap: 8px; }
.det-mini { display: flex; gap: 4px 14px; flex-wrap: wrap; }
.det-mini .btn-link { display: inline-flex; gap: 6px; align-items: center; }
.det-mini svg { width: 16px; height: 16px; }
.phones { display: flex; flex-direction: column; gap: 6px; border-top: 1px solid var(--line); padding-top: 14px; }
.phone { display: flex; align-items: center; gap: 4px 12px; flex-wrap: wrap; }
.loc { display: flex; gap: 8px; align-items: flex-start; font-size: .9rem; color: var(--muted); }
.loc svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }
@media (max-width: 900px) { .det-grid { grid-template-columns: 1fr; gap: 20px; } .det-info { position: static; } }
.det-sec { margin-top: 44px; }
.det-sec > h2 { font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 1.35rem; }
.spec-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); gap: 0 24px; margin: 14px 0 0; }
.spec-grid > div { border-top: 1px solid var(--line); padding-block: 12px; min-width: 0; }
.spec-grid dt { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.spec-grid dd { margin: 4px 0 0; font-weight: 600; overflow-wrap: anywhere; }
.desc { max-width: 68ch; white-space: pre-line; margin-top: 12px; }
.equip { columns: 2 240px; column-gap: 32px; padding: 0; margin: 12px 0 0; list-style: none; }
.equip li { padding: 6px 0 6px 22px; position: relative; break-inside: avoid; }
.equip li::before { content: ""; position: absolute; left: 0; top: 17px; width: 10px; height: 2px; background: var(--accent); }

/* Pie de página */
.ftr { background: var(--band); color: var(--band-ink); }
.ftr .muted, .ftr .eyebrow { color: var(--band-muted); }
.ftr .lnk, .ftr .links a { color: var(--band-gold); }
.ftr-in { display: flex; flex-wrap: wrap; gap: 32px 48px; padding-block: 44px 28px; }
.ftr-in > div { flex: 1 1 170px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ftr-in > .ftr-brand { flex: 2 1 260px; gap: 12px; }
.ftr h3 { margin-bottom: 6px; }
.flist { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.flist a { text-decoration: none; color: var(--band-muted); }
.flist a:hover { color: var(--band-ink); }
.ftr-base { padding-block: 16px 26px; border-top: 1px solid var(--band-line); font-size: .74rem; color: var(--band-muted); display: flex; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; }
.ftr-base a { color: inherit; }

/* Botón flotante de WhatsApp */
.fab {
  position: fixed; z-index: 30; width: 56px; height: 56px; border-radius: 50%;
  right: calc(18px + env(safe-area-inset-right, 0px)); bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  background: var(--wa); color: var(--wa-ink); display: grid; place-items: center; box-shadow: var(--shadow);
}
.fab svg { width: 26px; height: 26px; }

/* Administración */
.adm { padding-block: 26px 96px; display: flex; flex-direction: column; gap: 22px; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs button {
  padding: 12px 14px; border: 0; background: none; font-weight: 600; color: var(--muted); cursor: pointer;
  border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap;
}
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }
.tabs .count { font-family: var(--f-mono); font-size: .75rem; margin-left: 6px; color: var(--muted); }
.checklist { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px; display: grid; gap: 10px; }
.ck { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ck .dot { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line); flex: none; display: grid; place-items: center; }
.ck .dot svg { width: 12px; height: 12px; }
.ck.done .dot { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.ck.done .t { color: var(--muted); }
.adm-tools { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.adm-filter { display: flex; gap: 8px; flex-wrap: wrap; flex: 1 1 320px; justify-content: flex-end; }
.adm-filter .inp { width: auto; flex: 1 1 160px; max-width: 280px; }
.alist { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); overflow: hidden; }
.arow { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 16px; padding: 14px 16px; border-top: 1px solid var(--line); align-items: center; }
.arow:first-child { border-top: 0; }
.arow-th { aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; background: linear-gradient(160deg, var(--ph-a), var(--ph-b)); display: grid; place-items: center; position: relative; }
.arow-th img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.arow-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.arow-title { font-size: .95rem; }
.arow-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.arow-ctl { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; align-items: center; max-width: 470px; }
.chip {
  display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); background: var(--surface);
  border-radius: 999px; padding: 6px 11px; font-size: .8rem; font-weight: 600; cursor: pointer; color: var(--muted);
}
.chip svg { width: 13px; height: 13px; }
.chip[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); color: var(--ink); }
.chip.star[aria-pressed="true"] { background: var(--surface); border-color: var(--gold); color: var(--gold); }
.chip.star[aria-pressed="true"] svg { fill: currentColor; }
@media (max-width: 760px) { .arow { grid-template-columns: 84px minmax(0, 1fr); } .arow-ctl { grid-column: 1 / -1; justify-content: flex-start; max-width: none; } }
.empty-sm { padding: 28px 20px; text-align: center; color: var(--muted); }
.editor { display: flex; flex-direction: column; gap: 20px; padding-block: 18px 40px; }
.editor fieldset { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); padding: clamp(16px, 3vw, 24px); margin: 0; display: grid; gap: 14px; min-width: 0; }
.editor legend { font-family: var(--f-display); font-stretch: 112%; font-weight: 750; font-size: 1.05rem; padding: 0 8px; }
.ed-head { padding-top: 24px; display: flex; flex-direction: column; gap: 4px; }
.ed-actions {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center; position: sticky; bottom: 0; z-index: 5;
  background: var(--bg); padding-block: 12px calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line);
}
.ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 10px; }
.ph { position: relative; border-radius: 6px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--ph-a); border: 1px solid var(--line); }
.ph img { width: 100%; height: 100%; object-fit: cover; }
.ph-cover { position: absolute; top: 6px; left: 6px; }
.ph-tools { position: absolute; left: 6px; right: 6px; bottom: 6px; display: flex; gap: 4px; justify-content: space-between; }
.ph-tools span { display: flex; gap: 4px; }
.ph-tools button { width: 32px; height: 32px; border-radius: 4px; border: 0; background: var(--surface); color: var(--ink); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); }
.ph-tools button[disabled] { opacity: .4; cursor: default; }
.ph-tools svg { width: 16px; height: 16px; }
.upl-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.logo-row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.logo-prev { min-width: 150px; min-height: 72px; display: grid; place-items: center; padding: 10px 18px; border: 1px dashed var(--band-line); border-radius: var(--r); background: var(--band); }
.logo-prev img { max-height: 56px; width: auto; }
.logo-ctl { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.login { min-height: 60vh; display: grid; place-items: center; padding-block: 48px; }
.login-box { width: min(420px, 100%); display: flex; flex-direction: column; gap: 16px; }
.leads { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.lcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.lcard.is-new { border-color: var(--accent); }
.lead-top { display: flex; justify-content: space-between; gap: 8px; align-items: center; flex-wrap: wrap; }
.lead-name { font-size: 1.05rem; font-weight: 650; }
.lead-dl { margin: 0; display: grid; gap: 6px; }
.lead-dl div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; font-size: .9rem; }
.lead-dl dt { color: var(--muted); }
.lead-dl dd { margin: 0; overflow-wrap: anywhere; white-space: pre-line; }
.lead-act { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: auto; padding-top: 6px; }

/* Capas: galería ampliada, aviso, ventana */
.lb {
  position: fixed; inset: 0; z-index: 100; background: var(--overlay); display: flex; align-items: center; justify-content: center;
  padding: max(64px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(56px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
}
.lb img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lb-close { top: calc(12px + env(safe-area-inset-top, 0px)); right: calc(12px + env(safe-area-inset-right, 0px)); }
.lb-prev { left: calc(12px + env(safe-area-inset-left, 0px)); top: 50%; transform: translateY(-50%); }
.lb-next { right: calc(12px + env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); }
.lb-n { position: absolute; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); left: 50%; transform: translateX(-50%); color: var(--on-ovl); font-size: .85rem; }
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 120;
  background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: var(--r); font-weight: 600; font-size: .9rem;
  box-shadow: var(--shadow); max-width: calc(100% - 32px); width: max-content;
}
.mdl { position: fixed; inset: 0; z-index: 110; background: var(--overlay); display: grid; place-items: center; padding: 16px; }
.mdl-box { background: var(--surface); color: var(--ink); border-radius: var(--r-lg); padding: 20px; width: min(520px, 100%); display: grid; gap: 12px; }
.ovl { position: fixed; inset: 0; z-index: 90; background: var(--overlay); display: grid; place-items: center; color: var(--on-ovl); font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
