@import url("tokens/fonts.css");
@import url("tokens/colors.css");
@import url("tokens/typography.css");
@import url("tokens/spacing.css");
@import url("tokens/shadows.css");
@import url("tokens/base.css");

/* ============================================================
   Base
   ============================================================ */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body { margin: 0; }

a { color: var(--color-primary); text-decoration: none; }
a:hover { color: var(--color-primary-hover); text-decoration: underline; }

img { max-width: 100%; display: block; }

.container {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 24px;
}

@keyframes dimmaDash { from { stroke-dashoffset: 3000; } to { stroke-dashoffset: 0; } }
@keyframes dimmaBlip { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
@keyframes dimmaDrift { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  white-space: nowrap;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-weight: var(--weight-medium);
  cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--duration-fast) var(--ease-standard), opacity var(--duration-fast);
  text-decoration: none !important;
}

.btn--gradient { background: var(--gradient-medical); color: #fff; }
.btn--gradient:hover { opacity: 0.9; }

.btn--outline { background: var(--color-surface); color: var(--color-text); border-color: var(--color-border); }
.btn--outline:hover { background: var(--color-surface-muted); }

.btn--sm { height: 2.25rem; padding: 0 0.75rem; font-size: var(--text-sm); }
.btn--lg { height: 2.75rem; padding: 0 2rem; font-size: var(--text-base); }
.btn--full { width: 100%; }

/* ============================================================
   Card
   ============================================================ */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  padding: var(--space-6);
  transition: all var(--duration-base) var(--ease-standard);
}

.card--hover:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(var(--lift-hover));
}

.card--flush { padding: 0; overflow: hidden; }

/* ============================================================
   Form fields
   ============================================================ */
.field { display: flex; flex-direction: column; gap: 6px; }

.field label { font-size: 13.5px; font-weight: var(--weight-semibold); }

.input,
.textarea {
  width: 100%;
  padding: 0 0.75rem;
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  outline: none;
  box-sizing: border-box;
  transition: box-shadow var(--duration-fast), border-color var(--duration-fast);
}

.input { height: 2.5rem; }

.textarea { padding: 10px 12px; resize: vertical; line-height: 1.5; }

.input:focus,
.textarea:focus {
  box-shadow: 0 0 0 2px var(--color-primary);
  border-color: transparent;
}

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
}

.site-header .container {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none !important;
}

.logo img {
  display: block;
  height: 48px;
  width: auto;
}

.main-nav { display: flex; align-items: center; gap: 28px; }

.main-nav a {
  color: var(--color-text-muted);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none !important;
}

.main-nav a:hover { color: var(--color-primary); }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-sidebar);
}

.hero__anim {
  position: absolute;
  inset: 0;
  opacity: .9;
}

.hero__content {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
  padding: 110px 24px 130px;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(18, 161, 149, .15);
  border: 1px solid rgba(18, 161, 149, .4);
  color: #5eead4;
  font-size: 13px;
  font-weight: 600;
}

.hero h1 {
  margin: 0;
  max-width: 640px;
  font-size: 52px;
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  text-wrap: pretty;
}

.hero p {
  margin: 0;
  max-width: 520px;
  font-size: 18px;
  line-height: 1.6;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

.hero__actions { display: flex; gap: 14px; margin-top: 8px; }

/* ============================================================
   Stats
   ============================================================ */
.stats {
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface);
}

.stats .container {
  padding: 36px 24px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  text-align: center;
}

.stat--mid {
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
}

.stat .value {
  font-size: 34px;
  font-weight: 700;
  color: var(--color-primary);
  font-variant-numeric: tabular-nums;
}

.stat .label { font-size: 14px; color: var(--color-text-muted); }

/* ============================================================
   Section header (eyebrow + title + intro)
   ============================================================ */
.eyebrow {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--color-primary);
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 40px;
  max-width: 620px;
}

.section-head h2 {
  margin: 0;
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.section-head p {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text-muted);
  text-wrap: pretty;
}

/* ============================================================
   Servicios
   ============================================================ */
.services { padding: 90px 24px 80px; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-icon {
  display: inline-flex;
  width: 46px;
  height: 46px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: var(--color-primary-soft);
  color: var(--color-primary);
  margin-bottom: 14px;
}

.service-card h3 { margin: 0 0 14px; font-size: 19px; font-weight: 700; }

.service-card p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--color-text-muted); text-wrap: pretty; }

/* ============================================================
   Producto — Dimma QC
   ============================================================ */
.product {
  position: relative;
  overflow: hidden;
  background: var(--gradient-sidebar);
  border-top: 1px solid var(--color-border);
}

.product__glow {
  position: absolute;
  top: -140px;
  left: 50%;
  width: 900px;
  height: 420px;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(18, 161, 149, .22), transparent);
  pointer-events: none;
}

.product .container { position: relative; padding: 90px 24px; }

.product__head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  max-width: 720px;
  margin: 0 auto 40px;
  text-align: center;
}

.product__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(18, 161, 149, .15);
  border: 1px solid rgba(18, 161, 149, .4);
  color: #5eead4;
  font-size: 13px;
  font-weight: 600;
}

.product__head h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  text-wrap: pretty;
}

.product__head p {
  margin: 0;
  font-size: 16.5px;
  line-height: 1.7;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

.product__video { margin: 0 0 40px; }

.product__video video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  background: var(--color-background);
  border: 1px solid rgba(94, 234, 212, .22);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
}

.product__video figcaption {
  margin-top: 14px;
  font-size: 13px;
  line-height: 1.55;
  color: hsl(210 15% 62%);
  text-align: center;
  text-wrap: pretty;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.product-card {
  padding: 26px 26px 28px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, .04);
  transition: border-color var(--duration-base) var(--ease-standard), background var(--duration-base) var(--ease-standard);
}

.product-card:hover {
  border-color: rgba(94, 234, 212, .35);
  background: rgba(255, 255, 255, .06);
}

.product-icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: rgba(18, 161, 149, .18);
  color: #5eead4;
  margin-bottom: 14px;
}

.product-card h3 { margin: 0 0 10px; font-size: 18px; font-weight: 700; color: #fff; }

.product-card p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.65;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

.product-card strong { color: #5eead4; font-weight: 600; }

.product__cta {
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, .1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.product__cta h3 { margin: 0 0 6px; font-size: 20px; font-weight: 700; color: #fff; }

.product__cta p { margin: 0; max-width: 460px; font-size: 14.5px; line-height: 1.6; color: hsl(210 20% 78%); }

/* ============================================================
   Quiénes somos
   ============================================================ */
.about {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.about .container {
  padding: 90px 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.about__text { display: flex; flex-direction: column; gap: 16px; }

.about__text h2 { margin: 0; font-size: 34px; font-weight: 700; letter-spacing: -0.01em; }

.about__text p { margin: 0; font-size: 16px; line-height: 1.7; color: var(--color-text-muted); text-wrap: pretty; }

.about__people {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 8px;
}

.person-card { padding: 18px !important; }

.person {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--color-primary-soft);
  color: var(--color-primary);
  font-weight: 700;
  flex-shrink: 0;
}

.avatar--44 { width: 44px; height: 44px; font-size: 16px; }
.avatar--40 { width: 40px; height: 40px; font-size: 14px; }

.person__meta { display: flex; flex-direction: column; gap: 2px; }
.person__meta .name { font-weight: 700; font-size: 15px; }
.person__meta .role { font-size: 13px; color: var(--color-text-muted); }

.about__photo img {
  width: 100%;
  height: 460px;
  object-fit: cover;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card);
}

/* ============================================================
   Presencia — mapa animado de la Argentina
   ============================================================ */
.coverage {
  position: relative;
  overflow: hidden;
  background: var(--gradient-sidebar);
  border-bottom: 1px solid var(--color-border);
}

.coverage__glow {
  position: absolute;
  top: 50%;
  left: 22%;
  width: 720px;
  height: 720px;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(18, 161, 149, .18), transparent);
  pointer-events: none;
}

.coverage .container { position: relative; padding: 90px 24px; }

.coverage__grid {
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: 64px;
  align-items: center;
}

.coverage__side { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; }

.coverage__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(18, 161, 149, .15);
  border: 1px solid rgba(18, 161, 149, .4);
  color: #5eead4;
  font-size: 13px;
  font-weight: 600;
}

.coverage__side h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  text-wrap: pretty;
}

.coverage__side > p {
  margin: 0;
  max-width: 560px;
  font-size: 16px;
  line-height: 1.7;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

.coverage__note {
  margin: 6px 0 0;
  max-width: 520px;
  font-size: 14px;
  line-height: 1.6;
  color: hsl(210 15% 62%);
  text-wrap: pretty;
}

/* --- El mapa --------------------------------------------------------- */
.ar-map {
  position: relative;
  margin: 0;
  display: flex;
  justify-content: center;
}

.ar-map__svg {
  width: 100%;
  max-width: 330px;
  height: auto;
  overflow: visible;
}

/* Etiqueta con el nombre de la jurisdicción; JS la ubica sobre el marcador. */
.ar-map__tip {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  max-width: 180px;
  padding: 6px 12px;
  border: 1px solid rgba(94, 234, 212, .45);
  border-radius: var(--radius-full);
  background: rgba(15, 23, 42, .94);
  box-shadow: 0 8px 20px rgba(0, 0, 0, .45);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  text-align: center;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 12px)) scale(.94);
  transition: opacity var(--duration-fast) var(--ease-standard),
              transform var(--duration-fast) var(--ease-standard);
}

/* CABA no entra en una línea: sólo esa etiqueta se parte en dos. */
.ar-map__tip--wrap { white-space: normal; }

.ar-map__tip.is-visible {
  opacity: 1;
  transform: translate(-50%, calc(-100% - 12px)) scale(1);
}

.ar-map__base path {
  fill: rgba(255, 255, 255, .05);
  stroke: rgba(255, 255, 255, .2);
  stroke-width: .9;
  stroke-linejoin: round;
}

.ar-prov {
  fill: #12A195;
  fill-opacity: .62;
  stroke: #5eead4;
  stroke-width: 1;
  stroke-linejoin: round;
  cursor: pointer;
  transform-box: fill-box;
  transform-origin: center;
  transition: fill-opacity var(--duration-base) var(--ease-standard),
              stroke-width var(--duration-base) var(--ease-standard);
}

.ar-map__on { filter: drop-shadow(0 0 5px rgba(94, 234, 212, .45)); }

.ar-link {
  fill: none;
  stroke: #5eead4;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 4 7;
  opacity: .7;
  transition: opacity var(--duration-base) var(--ease-standard);
}

.ar-pin__ping {
  fill: none;
  stroke: #5eead4;
  stroke-width: 1.4;
  stroke-opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
}

.ar-pin__dot {
  fill: #fff;
  stroke: #12A195;
  stroke-width: 1.4;
  transition: fill-opacity var(--duration-base) var(--ease-standard);
}

.ar-pin--hub .ar-pin__dot { fill: #5eead4; stroke: #0f766e; }

.ar-pin__hit { fill: transparent; cursor: pointer; }

/* --- Estado inicial: el mapa se arma cuando entra en pantalla --------- */
.coverage.is-armed .ar-map__base path {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  fill-opacity: 0;
}

.coverage.is-armed .ar-prov,
.coverage.is-armed .ar-pin { opacity: 0; }

.coverage.is-armed .ar-prov { transform: scale(.9); }

.coverage.is-armed .ar-link { opacity: 0; }

/* Antes de que el mapa se dibuje no hay nada que señalar. */
.coverage.is-armed:not(.is-visible) .ar-map__svg { pointer-events: none; }

/* --- Secuencia de entrada -------------------------------------------- */
.coverage.is-armed.is-visible .ar-map__base path {
  stroke-dashoffset: 0;
  fill-opacity: 1;
  transition: stroke-dashoffset .9s var(--ease-standard) calc(var(--i) * .035s),
              fill-opacity .7s var(--ease-standard) calc(.5s + var(--i) * .035s);
}

.coverage.is-armed.is-visible .ar-prov {
  opacity: 1;
  transform: none;
  transition: opacity .5s var(--ease-standard) calc(1.25s + var(--i) * .14s),
              transform .55s cubic-bezier(.34, 1.3, .64, 1) calc(1.25s + var(--i) * .14s),
              fill-opacity var(--duration-base) var(--ease-standard),
              stroke-width var(--duration-base) var(--ease-standard);
}

.coverage.is-armed.is-visible .ar-pin {
  opacity: 1;
  transition: opacity .4s var(--ease-standard) calc(1.5s + var(--i) * .14s);
}

.coverage.is-armed.is-visible .ar-link {
  opacity: .7;
  transition: opacity .6s var(--ease-standard) calc(1.95s + var(--i) * .12s);
}

/* Los enlaces "laten" y los marcadores emiten un pulso, en bucle. */
.coverage.is-visible .ar-link { animation: arFlow 1.8s linear infinite; }

.coverage.is-visible .ar-pin__ping {
  animation: arPing 2.6s var(--ease-standard) calc(1.7s + var(--i) * .14s) infinite;
}

@keyframes arFlow { to { stroke-dashoffset: -11; } }

@keyframes arPing {
  0%        { transform: scale(.7); stroke-opacity: .9; }
  60%, 100% { transform: scale(2.6); stroke-opacity: 0; }
}

/* --- Jurisdicción señalada: se atenúa el resto ------------------------ */
.coverage.is-focused .ar-prov { fill-opacity: .14; }
.coverage.is-focused .ar-prov.is-focus { fill-opacity: .9; stroke-width: 1.6; }
.coverage.is-focused .ar-link { opacity: .1; }
.coverage.is-focused .ar-link.is-focus { opacity: .95; }
.coverage.is-focused .ar-pin__dot { fill-opacity: .2; }
.coverage.is-focused .ar-pin.is-focus .ar-pin__dot { fill-opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .coverage.is-armed .ar-map__base path,
  .coverage.is-armed .ar-prov,
  .coverage.is-armed .ar-pin,
  .coverage.is-armed .ar-link {
    opacity: 1;
    transform: none;
    fill-opacity: unset;
    stroke-dashoffset: 0;
  }

  .coverage .ar-map__base path,
  .coverage .ar-prov,
  .coverage .ar-pin,
  .coverage .ar-link,
  .coverage .ar-pin__ping { transition: none !important; animation: none !important; }

  /* La etiqueta sigue apareciendo, pero sin desplazamiento ni escala. */
  .coverage .ar-map__tip { transition: opacity var(--duration-fast) linear; transform: translate(-50%, calc(-100% - 12px)); }
  .coverage .ar-map__tip.is-visible { transform: translate(-50%, calc(-100% - 12px)); }

  .coverage.is-armed .ar-link { opacity: .7; }
  .coverage .ar-pin__ping { stroke-opacity: .35; }
}

/* ============================================================
   Blog
   ============================================================ */
.blog { padding: 90px 24px 80px; }

.blog__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 40px;
}

.blog__head .section-head { margin-bottom: 0; }

.blog__head > a { font-size: 14px; font-weight: 600; white-space: nowrap; }

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.article-card {
  display: flex;
  flex-direction: column;
}

.article-card img { width: 100%; height: 180px; object-fit: cover; }

.article-card__body {
  padding: 20px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.article-card__meta { font-size: 12.5px; font-weight: 600; color: var(--color-text-muted); }

.article-card h3 { margin: 0; font-size: 17px; font-weight: 700; line-height: 1.35; text-wrap: pretty; }

.article-card p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--color-text-muted); text-wrap: pretty; }

.article-card__link { margin-top: auto; font-size: 14px; font-weight: 600; }

/* ============================================================
   Contacto
   ============================================================ */
.contact {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
}

.contact__divider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 120px;
  pointer-events: none;
}

.contact .container {
  position: relative;
  padding: 100px 24px 90px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}

.contact__info { display: flex; flex-direction: column; gap: 18px; }

.contact__info h2 { margin: 0; font-size: 34px; font-weight: 700; letter-spacing: -0.01em; }

.contact__info > p { margin: 0; font-size: 16px; line-height: 1.7; color: var(--color-text-muted); text-wrap: pretty; }

.contact__people { display: flex; flex-direction: column; gap: 14px; margin-top: 8px; }

.contact-person {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  background: var(--color-background);
}

.contact-person .person__meta a { font-size: 13.5px; }

.contact__meta-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
}

.contact__location {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--color-text-muted);
}

.contact__meta-row .sep { color: var(--color-border); }

.social-link {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  text-decoration: none !important;
}

.social-link:hover { color: var(--color-primary); border-color: var(--color-primary); }

.contact-card { padding: 32px !important; }

#contact-form { display: flex; flex-direction: column; gap: 18px; }

#contact-form h3 { margin: 0; font-size: 20px; font-weight: 700; }

.form-note { margin: 0; font-size: 12.5px; color: var(--color-text-muted); text-align: center; }

/* Campo trampa para bots: no debe verse ni ocupar lugar. */
.field--trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-error {
  display: none;
  margin: 0;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: hsl(0 86% 97%);
  color: hsl(0 70% 35%);
  font-size: 13.5px;
  line-height: 1.5;
  text-align: center;
}

.form-error.is-visible { display: block; }

#contact-form button[type="submit"]:disabled { opacity: 0.65; cursor: progress; }

.thanks {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 40px 12px;
  text-align: center;
}

.thanks.is-visible { display: flex; }
#contact-form.is-hidden { display: none; }

.thanks__icon {
  display: inline-flex;
  width: 56px;
  height: 56px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--color-ok-soft);
  color: var(--color-ok-text);
}

.thanks h3 { margin: 0; font-size: 20px; font-weight: 700; }

.thanks p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--color-text-muted); }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--gradient-sidebar);
  color: hsl(210 20% 78%);
}

.site-footer .container {
  padding: 48px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
}

.footer-brand img {
  display: block;
  height: 40px;
  width: auto;
}

.footer-nav { display: flex; gap: 24px; flex-wrap: wrap; }

.footer-nav a {
  color: hsl(210 20% 78%);
  font-size: 13.5px;
  text-decoration: none !important;
}

.footer-nav a:hover { color: #5eead4; }

.footer-copy { font-size: 13px; color: hsl(210 15% 55%); }

/* ============================================================
   Encabezado de página interna (índice del blog)
   ============================================================ */
.page-hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-sidebar);
}

.page-hero__anim {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 120px;
  pointer-events: none;
}

.page-hero .container { position: relative; padding: 44px 24px 72px; }

.page-hero .eyebrow { color: #5eead4; }

.page-hero h1 {
  margin: 12px 0 0;
  max-width: 720px;
  font-size: 40px;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  text-wrap: pretty;
}

.page-hero p {
  margin: 16px 0 0;
  max-width: 620px;
  font-size: 17px;
  line-height: 1.65;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

/* ============================================================
   Listado de artículos
   ============================================================ */
.blog-list { padding: 64px 24px 24px; }

.blog-list__count {
  margin: 0 0 24px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--color-text-muted);
}

.blog-list__cta { margin-bottom: 80px; }

.blog-list__cta .post-cta { margin-top: 40px; }

/* ============================================================
   Artículo — barra de progreso de lectura
   ============================================================ */
.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--gradient-medical);
  z-index: 60;
  transition: width var(--duration-fast) linear;
}

/* ============================================================
   Artículo — encabezado
   ============================================================ */
.post-hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-sidebar);
}

.post-hero__anim {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 120px;
  pointer-events: none;
}

.post-hero .container {
  position: relative;
  max-width: 820px;
  padding: 44px 24px 100px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  font-size: 13px;
  color: hsl(210 15% 62%);
}

.breadcrumb a { color: hsl(210 20% 78%); text-decoration: none !important; }
.breadcrumb a:hover { color: #5eead4; }
.breadcrumb .sep { color: hsl(210 12% 42%); }

.post-hero h1 {
  margin: 16px 0 0;
  font-size: 42px;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  text-wrap: pretty;
}

.post-hero__lead {
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.65;
  color: hsl(210 20% 78%);
  text-wrap: pretty;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, .1);
}

.post-meta .avatar { background: rgba(18, 161, 149, .2); color: #5eead4; }

.post-meta__text { display: flex; flex-direction: column; gap: 2px; }
.post-meta__text .name { font-size: 14px; font-weight: 600; color: #fff; }
.post-meta__text .detail { font-size: 13px; color: hsl(210 15% 62%); }

/* ============================================================
   Artículo — portada
   ============================================================ */
.post-cover {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin: -68px auto 0;
  padding: 0 24px;
}

.post-cover img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card-hover);
}

.post-cover figcaption {
  margin-top: 12px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--color-text-muted);
  text-align: center;
}

/* ============================================================
   Artículo — cuerpo
   ============================================================ */
.post-body {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 0;
}

.prose > * { margin: 0; }
.prose > * + * { margin-top: 1.15em; }

.prose p {
  font-size: 17px;
  line-height: 1.75;
  color: hsl(210 10% 30%);
  text-wrap: pretty;
}

.prose h2 {
  margin: 2.2em 0 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  scroll-margin-top: 90px;
  text-wrap: pretty;
}

.prose h3 {
  margin: 1.8em 0 0;
  font-size: 19px;
  font-weight: 700;
  text-wrap: pretty;
}

.prose ul,
.prose ol {
  padding-left: 1.3em;
  display: flex;
  flex-direction: column;
  gap: 0.55em;
}

.prose li {
  font-size: 16.5px;
  line-height: 1.7;
  color: hsl(210 10% 30%);
  text-wrap: pretty;
}

.prose li::marker { color: var(--color-primary); font-weight: 700; }

.prose strong { color: var(--color-text); font-weight: 700; }

.prose a { text-decoration: underline; text-underline-offset: 3px; }

.prose blockquote {
  padding: 6px 0 6px 22px;
  border-left: 3px solid var(--color-primary);
  font-size: 18px;
  line-height: 1.65;
  font-style: italic;
  color: var(--color-text);
}

.prose blockquote p { margin: 0; font-size: inherit; color: inherit; }

.prose hr { border: none; border-top: 1px solid var(--color-border); margin: 2.4em 0; }

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  background: var(--color-surface);
}

.prose table { width: 100%; border-collapse: collapse; font-size: 14.5px; }

.prose th,
.prose td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
  line-height: 1.5;
  vertical-align: top;
}

.prose th:first-child,
.prose td:first-child { white-space: nowrap; }

.prose thead th {
  background: var(--color-surface-muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}

.prose tbody tr:last-child td { border-bottom: none; }

.callout {
  display: flex;
  gap: 14px;
  padding: 20px 22px;
  border-radius: var(--radius-xl);
  background: var(--color-primary-soft);
  border: 1px solid rgba(18, 161, 149, .3);
}

.callout__icon { color: var(--color-primary); flex-shrink: 0; margin-top: 1px; }

.callout h4 { margin: 0 0 5px; font-size: 15px; font-weight: 700; }

.callout p { margin: 0; font-size: 14.5px; line-height: 1.65; color: hsl(210 10% 30%); }

/* ============================================================
   Artículo — pie (tags, autor, CTA)
   ============================================================ */
.post-footer { max-width: 760px; margin: 0 auto; padding: 0 24px; }

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--color-border);
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 13px;
  border-radius: var(--radius-full);
  background: var(--color-surface-muted);
  border: 1px solid var(--color-border);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--color-text-muted);
}

.author-card { display: flex; gap: 16px; align-items: flex-start; margin-top: 24px; }

.author-card__text { display: flex; flex-direction: column; gap: 4px; }

.author-card__text .name { font-size: 15px; font-weight: 700; }

.author-card__text .role { font-size: 13px; font-weight: 600; color: var(--color-primary); }

.author-card__text p { margin: 4px 0 0; font-size: 14px; line-height: 1.6; color: var(--color-text-muted); }

.post-cta {
  margin-top: 28px;
  padding: 34px 32px;
  border-radius: var(--radius-xl);
  background: var(--gradient-sidebar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.post-cta h3 { margin: 0 0 6px; font-size: 20px; font-weight: 700; color: #fff; }

.post-cta p { margin: 0; max-width: 400px; font-size: 14.5px; line-height: 1.6; color: hsl(210 20% 78%); }

/* ============================================================
   Artículo — relacionados
   ============================================================ */
.related {
  margin-top: 72px;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

.related .container { padding: 64px 24px 76px; }

.related .blog-grid { grid-template-columns: repeat(2, 1fr); }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .main-nav { gap: 16px; }
  .main-nav a:not(.btn) { display: none; }

  .hero h1 { font-size: 38px; }
  .hero p { font-size: 16px; }
  .hero__content { padding: 80px 24px 90px; }

  .stats .container,
  .services-grid,
  .product-grid,
  .blog-grid,
  .about .container,
  .contact .container {
    grid-template-columns: 1fr;
  }

  .product .container { padding: 64px 24px; }
  .product__head h2 { font-size: 27px; }
  .product__head p { font-size: 15.5px; }
  .product__cta { flex-direction: column; align-items: flex-start; }
  .product__cta .btn { width: 100%; }

  .stat--mid {
    border-left: none;
    border-right: none;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    padding: 16px 0;
  }

  .about__photo { order: -1; }
  .about__photo img { height: 280px; }

  .coverage .container { padding: 64px 24px; }
  .coverage__grid { grid-template-columns: 1fr; gap: 40px; }
  .coverage__side h2 { font-size: 27px; }
  .coverage__side > p { font-size: 15.5px; }
  .coverage__side .btn { width: 100%; }
  .ar-map__svg { max-width: 280px; }

  .blog__head { flex-direction: column; align-items: flex-start; }

  .page-hero .container { padding: 32px 24px 60px; }
  .page-hero h1 { font-size: 30px; }
  .page-hero p { font-size: 16px; }

  .blog-list { padding-top: 48px; }

  .post-hero .container { padding: 32px 24px 88px; }
  .post-hero h1 { font-size: 30px; }
  .post-hero__lead { font-size: 16px; }

  .post-cover img { height: 220px; }

  .post-body { padding-top: 44px; }
  .prose p { font-size: 16px; }
  .prose li { font-size: 15.5px; }
  .prose h2 { font-size: 22px; }
  .prose blockquote { font-size: 16.5px; }

  .post-cta { flex-direction: column; align-items: flex-start; padding: 28px 24px; }
  .post-cta .btn { width: 100%; }

  .related .blog-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .about__people { grid-template-columns: 1fr; }
  .hero__actions { flex-direction: column; width: 100%; }
  .hero__actions .btn { width: 100%; }
}
