/* Portal de búsqueda */

/* Buscador */
.sbox { display: flex; gap: 0; background: var(--surface); border: 1.5px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 6px; align-items: stretch; position: relative; }
.sbox.big { padding: 8px; border-radius: 22px; }
.sbox:focus-within { border-color: var(--brand); }
.sbox-q { flex: 1; display: flex; align-items: center; gap: 10px; padding-inline: 14px; position: relative; color: var(--muted); min-width: 0; }
.sbox-input { flex: 1; border: 0; background: none; color: var(--ink); font: 500 1rem var(--font); padding: 12px 0; min-width: 0; }
.sbox-input:focus { outline: none; }
.sbox-c { display: flex; align-items: center; gap: 6px; padding-inline: 12px; border-left: 1px solid var(--line); color: var(--muted); }
.sbox-c select { border: 0; background-color: transparent; color: var(--ink); font: 500 0.95rem var(--font); max-width: 170px; cursor: pointer; }
.sbox-c select:focus { outline: none; }
.sbox-sug { position: absolute; top: calc(100% + 14px); left: -6px; right: -240px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-l); list-style: none; margin: 0; padding: 6px; z-index: 30; max-width: 640px; }
.sbox-sug li a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 9px; color: var(--ink); }
.sbox-sug li a:hover, .sbox-sug li.sel a { background: var(--brand-soft); text-decoration: none; }
.sug-type { font: 700 0.65rem var(--font); text-transform: uppercase; letter-spacing: 0.08em; color: var(--brand); background: var(--brand-soft); padding: 3px 7px; border-radius: 6px; min-width: 66px; text-align: center; }
@media (max-width: 640px) {
  .sbox { flex-wrap: wrap; }
  .sbox-q { flex-basis: 100%; }
  .sbox-c { border-left: 0; border-top: 1px solid var(--line); flex: 1; padding-block: 6px; }
  .sbox-sug { right: -6px; }
}

/* Hero */
.hero { position: relative; overflow: hidden; padding-block: clamp(40px, 7vw, 88px) clamp(36px, 5vw, 64px); background: var(--hero-wash); }
.hero::before { content: ''; position: absolute; inset: -20% -10% auto auto; width: 620px; height: 620px; border-radius: 50%; background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 62%); pointer-events: none; }
.hero::after { content: ''; position: absolute; left: -140px; bottom: -200px; width: 460px; height: 460px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 24%, transparent), transparent 65%); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center; position: relative; z-index: 1; }
.hero h1 em { font-style: normal; color: var(--brand); background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent) 55%, transparent) 62%); }
.hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 52ch; margin-block: 18px 26px; }
.quick { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; align-items: center; }
.hero-demo { position: relative; display: flex; flex-direction: column; gap: 12px; }
.hd-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; box-shadow: var(--shadow); display: flex; gap: 12px; align-items: center; }
.hd-card:nth-child(2) { margin-left: 28px; } .hd-card:nth-child(3) { margin-left: 8px; }
.hd-card .grow b { display: block; }
.hd-tag { position: absolute; top: -14px; right: 10px; background: var(--ink); color: var(--bg); font: 700 0.72rem var(--font); padding: 5px 12px; border-radius: 99px; z-index: 2; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } .hero-demo { display: none; } }

.statbar { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-top: 36px; position: relative; z-index: 1; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 18px; box-shadow: var(--shadow-s); }
.stat b { font: 800 1.7rem var(--font-d); display: block; letter-spacing: -0.02em; }
.stat span { color: var(--muted); font-size: 0.85rem; }

.cat-tile { display: flex; gap: 14px; align-items: center; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; color: var(--ink); transition: all 0.15s; }
.cat-tile:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--brand); }
.cat-ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; flex: none; background: hsl(var(--ch) 70% 92%); color: hsl(var(--ch) 60% 30%); }
[data-theme='dark'] .cat-ic { background: hsl(var(--ch) 40% 20%); color: hsl(var(--ch) 70% 75%); }
.cat-tile b { display: block; line-height: 1.2; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; counter-reset: s; }
.step-card { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 24px; position: relative; }
.step-card::before { content: counter(s); position: absolute; top: 18px; right: 20px; font: 800 3rem var(--font-d); color: var(--brand-soft); line-height: 1; }
.step-card .ic-box { width: 46px; height: 46px; border-radius: 14px; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; margin-bottom: 14px; }
.cta-band { background: linear-gradient(135deg, var(--brand-deep), var(--brand)); color: #fff; border-radius: 26px; padding: clamp(28px, 5vw, 52px); display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
[data-theme='dark'] .cta-band { background: linear-gradient(135deg, #0d3d34, #135a4d); }
.cta-band h2 { color: #fff; max-width: 22ch; } .cta-band p { color: rgba(255, 255, 255, 0.8); margin-top: 8px; max-width: 52ch; }

.deal { display: flex; gap: 12px; align-items: center; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; color: var(--ink); }
.deal:hover { text-decoration: none; border-color: var(--brand); }
.deal .grow b { display: block; font-size: 0.95rem; line-height: 1.25; }

/* Búsqueda */
.search-layout { display: grid; grid-template-columns: 280px 1fr; gap: 28px; align-items: start; }
.filters { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; max-height: calc(100vh - 100px); overflow-y: auto; }
.filters h4 { font: 700 0.82rem var(--font); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 8px; }
.filters-toggle { display: none; }
@media (max-width: 900px) {
  .search-layout { grid-template-columns: 1fr; }
  .filters { display: none; position: static; max-height: none; }
  .filters.show { display: flex; }
  .filters-toggle { display: inline-flex; }
}
.results-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.picks { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-bottom: 20px; }
.pick { background: linear-gradient(135deg, var(--brand-soft), var(--surface)); border: 1px solid color-mix(in srgb, var(--brand) 30%, var(--line)); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 8px; color: var(--ink); }
.pick:hover { text-decoration: none; border-color: var(--brand); }
.pick .lbl { display: inline-flex; gap: 6px; align-items: center; font: 800 0.72rem var(--font); letter-spacing: 0.08em; text-transform: uppercase; color: var(--brand-deep); }
.pick .row b { line-height: 1.2; }
.map-split { display: grid; grid-template-columns: minmax(340px, 1fr) 1.1fr; gap: 18px; align-items: start; }
.map-split .map { height: calc(100vh - 160px); min-height: 420px; position: sticky; top: 84px; }
.map-split .list { display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 1100px) { .map-split { grid-template-columns: 1fr; } .map-split .map { position: static; height: 360px; order: -1; } }
.active-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.active-filters a.chip { background: var(--brand-soft); border-color: transparent; color: var(--brand-deep); }

/* Detalle de proveedor */
.cover { height: 170px; background: linear-gradient(120deg, hsl(var(--h) 55% 30%), hsl(calc(var(--h) + 40) 60% 40%)); position: relative; overflow: hidden; }
.cover::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.2), transparent 50%), repeating-linear-gradient(135deg, transparent 0 22px, rgba(255, 255, 255, 0.04) 22px 44px); }
.prof-head { margin-top: -60px; position: relative; z-index: 2; display: flex; gap: 20px; align-items: flex-end; flex-wrap: wrap; }
.prof-head .avatar { border: 5px solid var(--bg); box-shadow: var(--shadow); }
.prof-head h1 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
.prof-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px; margin-top: 26px; align-items: start; }
@media (max-width: 960px) { .prof-grid { grid-template-columns: 1fr; } .prof-aside { order: -1; } }
.prof-aside { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 960px) { .prof-aside { position: static; } }
.prof-nav { position: sticky; top: 66px; z-index: 20; background: var(--bg); margin-top: 18px; }
.sect { scroll-margin-top: 130px; }
.sect > h2 { font-size: 1.4rem; margin-bottom: 14px; display: flex; align-items: center; gap: 10px; }
.svc { display: grid; grid-template-columns: 1fr auto; gap: 8px 18px; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; align-items: center; }
.svc + .svc { margin-top: 10px; }
.svc h4 { font: 700 1.02rem var(--font-d); }
.svc .p { text-align: right; } .svc .p .price { font-size: 1.25rem; display: block; }
.svc .acts { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 560px) { .svc { grid-template-columns: 1fr; } .svc .p { text-align: left; } }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin-top: 16px; }
.fact { background: var(--surface-2); border-radius: 12px; padding: 12px 14px; }
.fact .k { font: 700 0.72rem var(--font); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.office { display: flex; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.office + .office { margin-top: 10px; }
.office .n { width: 30px; height: 30px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-weight: 800; flex: none; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.gallery img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 12px; cursor: zoom-in; border: 1px solid var(--line); }
.rating-box { display: grid; grid-template-columns: 140px 1fr; gap: 20px; align-items: center; margin-bottom: 18px; }
.rating-box .big { font: 800 3.2rem var(--font-d); line-height: 1; }
.bar { display: grid; grid-template-columns: 14px 1fr 28px; gap: 8px; align-items: center; font-size: 0.82rem; color: var(--muted); }
.bar i { height: 7px; border-radius: 99px; background: var(--line); overflow: hidden; display: block; } .bar i b { display: block; height: 100%; background: var(--accent); }
.review { padding: 16px 0; border-bottom: 1px solid var(--line); }
.review .reply { margin: 10px 0 0 14px; padding: 10px 14px; background: var(--surface-2); border-left: 3px solid var(--brand); border-radius: 0 10px 10px 0; font-size: 0.9rem; }
.star-pick { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.star-pick input { display: none; }
.star-pick label { cursor: pointer; color: var(--line); font-size: 1.6rem; line-height: 1; }
.star-pick input:checked ~ label, .star-pick label:hover, .star-pick label:hover ~ label { color: var(--accent); }

/* Comparador / presupuesto / listas */
.cmp-head { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; min-width: 190px; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 10px; overflow: hidden; }
.qty button { border: 0; background: var(--surface-2); width: 30px; height: 32px; cursor: pointer; color: var(--ink); }
.qty span { min-width: 34px; text-align: center; font-weight: 700; }
.total-box { background: var(--brand-soft); border-radius: 16px; padding: 18px 20px; display: flex; flex-direction: column; gap: 8px; }
.total-box .big { font: 800 1.9rem var(--font-d); color: var(--brand-deep); }
.rfq-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.resp { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-2); }
.resp.won { border-color: var(--ok); background: var(--ok-soft); }
.resp.dim { opacity: 0.6; }
@media (max-width: 640px) { .resp { grid-template-columns: auto 1fr; } .resp .right { grid-column: 1 / -1; text-align: left; } .resp .right .row { justify-content: flex-start !important; } }
.rfq-items { margin: 0; padding-left: 18px; font-size: 0.92rem; }

/* Asistente */
.wiz { max-width: 760px; margin-inline: auto; }
.wiz-steps { display: flex; gap: 8px; margin-bottom: 22px; }
.wiz-steps i { flex: 1; height: 6px; border-radius: 99px; background: var(--line); } .wiz-steps i.on { background: var(--brand); }
.big-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.big-choice label { display: flex; gap: 8px; align-items: center; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: var(--surface); font-weight: 500; }
.big-choice input { accent-color: var(--brand); }
.big-choice label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.match-ring { --p: 80; width: 58px; height: 58px; border-radius: 50%; background: conic-gradient(var(--brand) calc(var(--p) * 1%), var(--line) 0); display: grid; place-items: center; flex: none; }
.match-ring b { width: 46px; height: 46px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font: 800 0.9rem var(--font-d); }
.demo-banner { background: var(--accent-soft); color: var(--gold); font-size: 0.82rem; text-align: center; padding: 6px var(--gutter); border-bottom: 1px solid var(--line); }
.cmp-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 50; background: var(--ink); color: var(--bg); border-radius: 99px; padding: 8px 10px 8px 18px; display: flex; gap: 12px; align-items: center; box-shadow: var(--shadow-l); width: max-content; max-width: calc(100vw - 24px); white-space: nowrap; font-size: 0.92rem; }
.cmp-bar .btn { border-color: transparent; }
