/* =========================================================
   OB Soluciones · Aire acondicionado
   Paleta tomada del logo: gris carbón + amarillo ámbar
   ========================================================= */
:root {
  --charcoal: #2b2e33;
  --charcoal-900: #1e2024;
  --charcoal-700: #3a3e45;
  --amber: #f5b52e;
  --amber-600: #e09d14;
  --amber-100: #fdf1d6;
  --ink: #23262b;
  --muted: #5e636b;
  --line: #e4e2dc;
  --bg: #ffffff;
  --bg-alt: #f6f5f1;

  --radius: 14px;
  --shadow: 0 1px 2px rgba(30, 32, 36, .06), 0 8px 24px rgba(30, 32, 36, .06);
  --font-head: "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --header-h: 92px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--font-head);
  line-height: 1.15;
  margin: 0 0 .5em;
  color: var(--charcoal);
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.1rem, 4.6vw, 3.5rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }

.container { width: min(1140px, 100% - 2.5rem); margin-inline: auto; }
.accent { color: var(--amber); }
.muted { color: var(--muted); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--amber-600);
  margin-bottom: .75rem;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  padding: .85rem 1.5rem;
  border-radius: 999px;
  border: 2px solid transparent;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
  cursor: pointer;
}
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.btn-primary { background: var(--amber); color: var(--charcoal-900); }
.btn-primary:hover { background: var(--amber-600); }
.btn-ghost { border-color: rgba(255, 255, 255, .35); color: #fff; }
.btn-ghost:hover { border-color: var(--amber); color: var(--amber); }
.btn-dark { background: var(--charcoal); color: #fff; }
.btn-dark:hover { background: var(--charcoal-900); }
.btn-sm { padding: .55rem 1.1rem; font-size: .92rem; }
.btn-block { width: 100%; }

a:focus-visible, button:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* El PNG del logo trae mucho margen blanco: lo recortamos con CSS.
   Área útil del logo en la imagen de 640x640: x 58→592, y 148→492 */
.brand-logo {
  --h: 72px;
  display: block;
  height: var(--h);
  width: calc(var(--h) * 534 / 344);
  overflow: hidden;
}
.brand-logo img {
  width: calc(var(--h) * 640 / 344);
  max-width: none;
  margin-left: calc(var(--h) * -58 / 344);
  margin-top: calc(var(--h) * -148 / 344);
}

.nav { display: flex; align-items: center; gap: 1.75rem; }
.nav a:not(.btn) {
  text-decoration: none;
  font-weight: 500;
  font-size: .95rem;
  color: var(--charcoal);
  position: relative;
}
.nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: var(--amber);
  transform: scaleX(0);
  transition: transform .2s;
}
.nav a:not(.btn):hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 10px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  margin: 5px 0;
  background: var(--charcoal);
  border-radius: 2px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--charcoal);
  color: #e9e9ea;
  padding: clamp(4rem, 9vw, 7rem) 0 clamp(3rem, 6vw, 4.5rem);
}
.hero h1 { color: #fff; max-width: 21ch; }
.hero .lead { font-size: 1.15rem; max-width: 56ch; color: #cfd1d4; }
.hero .lead strong { color: #fff; }
.hero-inner { position: relative; z-index: 1; }
.hero .eyebrow { color: var(--amber); }

.hero-gear { position: absolute; pointer-events: none; }
.hero-gear-lg {
  width: 720px; height: 720px;
  right: -300px; top: 50%;
  transform: translateY(-50%);
  color: var(--charcoal-700);
  animation: spin 90s linear infinite;
}
.hero-gear-sm {
  width: 260px; height: 260px;
  right: 230px; top: 40px;
  color: var(--amber);
  opacity: .9;
  animation: spin-rev 45s linear infinite;
}
@keyframes spin { to { transform: translateY(-50%) rotate(360deg); } }
@keyframes spin-rev { to { transform: rotate(-360deg); } }

.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; margin: 2rem 0 3rem; }

.hero-facts {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 820px;
}
.hero-facts li {
  background: rgba(30, 32, 36, .85);
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
}
.hero-facts strong {
  font-family: var(--font-head);
  font-size: 1.35rem;
  color: var(--amber);
  line-height: 1.2;
}
.hero-facts span { font-size: .9rem; color: #b9bcc1; }

/* ---------- Secciones ---------- */
.section { padding: clamp(4rem, 8vw, 6.5rem) 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 640px; margin-bottom: 3rem; }
.section-head p:last-child { color: var(--muted); font-size: 1.08rem; }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}
.card p { color: var(--muted); }
.card-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--amber-100);
  display: grid;
  place-items: center;
  margin-bottom: 1.25rem;
}
.card-icon svg {
  width: 28px; height: 28px;
  fill: none;
  stroke: var(--charcoal);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.checks { list-style: none; padding: 0; margin: 1.25rem 0 0; }
.checks li { position: relative; padding-left: 1.9rem; margin-bottom: .55rem; font-weight: 500; }
.checks li::before {
  content: "";
  position: absolute;
  left: 0; top: .3em;
  width: 1.15rem; height: 1.15rem;
  border-radius: 50%;
  background: var(--amber) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231e2024' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 70% no-repeat;
}

/* ---------- Pasos ---------- */
.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  counter-reset: step;
}
.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow);
}
.step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 2.6rem;
  right: -1.5rem;
  width: 1.5rem;
  height: 2px;
  background: var(--amber);
}
.step-num {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--charcoal);
  color: var(--amber);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.15rem;
  margin-bottom: 1rem;
}
.step h3 { margin-bottom: .2rem; }
.step-time {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .88rem;
  color: var(--amber-600);
  margin-bottom: .75rem;
}
.step p:last-child { color: var(--muted); font-size: .96rem; margin: 0; }

.pay {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: center;
  background: var(--charcoal);
  color: #d4d6d9;
  border-radius: var(--radius);
  padding: 2rem 2.25rem;
}
.pay h3 { color: #fff; font-size: 1.4rem; }
.pay p { margin: 0; }
.pay-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: 12px;
  overflow: hidden;
  font-family: var(--font-head);
}
.pay-bar div { padding: 1rem 1.25rem; display: flex; flex-direction: column; }
.pay-bar div:first-child { background: var(--amber); color: var(--charcoal-900); }
.pay-bar div:last-child { background: var(--charcoal-700); color: #fff; }
.pay-bar strong { font-size: 1.8rem; line-height: 1.1; }
.pay-bar span { font-size: .9rem; font-weight: 600; }

/* ---------- Garantía ---------- */
.guarantee {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
  max-width: 980px;
}
.guarantee p { color: var(--muted); font-size: 1.08rem; max-width: 60ch; }
.guarantee p strong { color: var(--charcoal); }
.guarantee-badge {
  position: relative;
  width: 220px; height: 220px;
  display: grid;
  place-items: center;
}
.guarantee-gear {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--amber);
  animation: rotate 45s linear infinite; /* misma velocidad que el engranaje ámbar del hero */
}
@keyframes rotate { to { transform: rotate(360deg); } }
.guarantee-badge span {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
}
.guarantee-badge strong { font-size: 3.6rem; font-weight: 800; }
.link-arrow {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--charcoal);
  text-decoration: none;
  border-bottom: 2px solid var(--amber);
  padding-bottom: 2px;
}
.link-arrow::after { content: " →"; }

/* ---------- Servicios ---------- */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }

.tenant {
  position: relative;
  overflow: hidden;
  margin-top: 1.5rem;
  background: var(--amber);
  border-radius: var(--radius);
  padding: clamp(2rem, 5vw, 3rem);
  color: var(--charcoal-900);
}
.tenant-body { position: relative; z-index: 1; max-width: 640px; }
.tenant h3 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); font-weight: 800; color: var(--charcoal-900); }
.tenant .tag {
  display: inline-block;
  background: var(--charcoal);
  color: var(--amber);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .75rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: .35rem .8rem;
  border-radius: 999px;
}
.tenant-steps { list-style: none; padding: 0; margin: 1.25rem 0 1.75rem; }
.tenant-steps li { display: flex; align-items: center; gap: .85rem; margin-bottom: .7rem; font-weight: 500; }
.tenant-steps span {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--charcoal);
  color: var(--amber);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: .9rem;
}
.tenant-gear {
  position: absolute;
  width: 440px; height: 440px;
  right: -120px; bottom: -160px;
  color: rgba(30, 32, 36, .09);
}

/* ---------- Contacto ---------- */
.contact {
  position: relative;
  overflow: hidden;
  background: var(--charcoal);
  color: #cfd1d4;
}
.contact h2 { color: #fff; }
.contact .eyebrow { color: var(--amber); }
.contact .lead strong { color: #fff; }
.contact-gear {
  position: absolute;
  width: 520px; height: 520px;
  left: -260px; bottom: -220px;
  color: var(--charcoal-700);
}
.contact-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.contact-info .btn { margin-top: .5rem; }
.contact-list { list-style: none; padding: 0; margin: 2rem 0 0; }
.contact-list li {
  display: flex;
  flex-direction: column;
  padding: .85rem 0;
  border-top: 1px solid rgba(255, 255, 255, .12);
  color: #fff;
  font-weight: 500;
}
.contact-list span {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #9da1a7;
}
.contact-list a { text-decoration: none; }
.contact-list a:hover { color: var(--amber); }

/* ---------- Formulario ---------- */
.contact-form {
  background: #fff;
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  color: var(--ink);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .25);
}
.contact-form h3 { font-size: 1.3rem; margin-bottom: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.contact-form label {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  font-size: .88rem;
  font-weight: 600;
  color: var(--charcoal);
  margin-bottom: 1rem;
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  font: inherit;
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink);
  background: var(--bg-alt);
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: .7rem .85rem;
  width: 100%;
  transition: border-color .2s, background .2s;
}
.contact-form textarea { resize: vertical; min-height: 90px; }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--amber);
  background: #fff;
}
.contact-form button { margin-top: .25rem; }
.contact-form button:disabled { opacity: .7; cursor: wait; transform: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-status { margin: 1rem 0 0; font-size: .95rem; }
.form-status:empty { display: none; }
.form-status.ok { color: #1f7a3d; font-weight: 600; }
.form-status.error { color: #b42318; }
.form-status a { font-weight: 600; }

.card .link-arrow { display: inline-block; margin-top: .25rem; font-size: .95rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--charcoal-900);
  color: #9da1a7;
  padding: 2rem 0;
  font-size: .92rem;
}
.footer-inner { display: flex; flex-wrap: wrap; gap: .5rem 2rem; align-items: center; justify-content: space-between; }
.footer-inner p { margin: 0; }
.footer-inner a { text-decoration: none; }
.footer-inner a:hover { color: var(--amber); }
.footer-brand { font-family: var(--font-head); font-weight: 800; font-size: 1.2rem; color: #fff; }

/* ---------- Botón flotante WhatsApp ---------- */
.wa-float {
  --wa: #25d366;
  --size: 60px;
  position: fixed;
  z-index: 60;
  right: max(1.25rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: .75rem;
  text-decoration: none;
}
.wa-float-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  background: var(--wa);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .25), 0 0 0 3px #fff;
  transition: transform .2s, box-shadow .2s;
}
.wa-float-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--wa);
  z-index: -1;
  animation: wa-pulse 2.6s ease-out infinite;
}
.wa-float-btn svg { width: 58%; height: 58%; }
.wa-bubble { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linejoin: round; }
.wa-phone { fill: #fff; }
.wa-float-label {
  background: var(--charcoal);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .9rem;
  white-space: nowrap;
  padding: .55rem 1rem;
  border-radius: 999px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .2);
  opacity: 0;
  transform: translateX(8px);
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.wa-float:hover .wa-float-btn,
.wa-float:focus-visible .wa-float-btn { transform: scale(1.07); box-shadow: 0 10px 24px rgba(0, 0, 0, .3), 0 0 0 3px #fff; }
.wa-float:focus-visible { outline: none; }
.wa-float:focus-visible .wa-float-btn { outline: 3px solid var(--amber); outline-offset: 4px; }
@media (hover: hover) {
  .wa-float:hover .wa-float-label,
  .wa-float:focus-visible .wa-float-label { opacity: 1; transform: none; }
}
@keyframes wa-pulse {
  0% { transform: scale(1); opacity: .55; }
  70%, 100% { transform: scale(1.6); opacity: 0; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step::after { display: none; }
  .services { grid-template-columns: 1fr 1fr; }
  .hero-facts { grid-template-columns: repeat(2, 1fr); }
  .hero-gear-sm { display: none; }
  .contact-inner, .pay { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  :root { --header-h: 72px; }
  .brand-logo { --h: 54px; }
  .nav-toggle { display: block; }
  .nav {
    position: absolute;
    top: var(--header-h);
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: .5rem 1.25rem 1.25rem;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a:not(.btn) { padding: .85rem 0; border-bottom: 1px solid var(--line); }
  .nav a:not(.btn)::after { display: none; }
  .nav .btn { margin-top: 1rem; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .grid-2, .services, .steps, .form-row { grid-template-columns: 1fr; }
  .form-row { gap: 0; }
  .hero-gear-lg { width: 480px; height: 480px; right: -280px; opacity: .7; }
  .guarantee { grid-template-columns: 1fr; }
  .guarantee-badge { width: 170px; height: 170px; }
  .hero-facts li { padding: .9rem 1rem; }
  .hero-facts strong { font-size: 1.1rem; }
  .card { padding: 1.5rem; }
  .pay { padding: 1.5rem; }
  .wa-float { --size: 54px; right: max(1rem, env(safe-area-inset-right)); bottom: max(1rem, env(safe-area-inset-bottom)); }
  .wa-float-label { display: none; }
  .site-footer { padding-bottom: 5.5rem; } /* que el botón no tape el pie */
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-gear-lg, .hero-gear-sm, .guarantee-gear, .wa-float-btn::before { animation: none; }
}
