/* AstroDeni v10 — consolidated audit fixes */

/* Accessible controls and stable editorial hierarchy */
nav .left > a:not(.navlink),
nav .right > a,
footer .f-soc a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
}

.hero-photo-mobile { display: none; }

.sobre .rol-sub {
  font-size: 12.5px !important;
  line-height: 1.65 !important;
  letter-spacing: 1.45px !important;
  text-wrap: balance;
}

#reportes-card .report-title span {
  white-space: normal !important;
}

/* Replace the harsh divider treatment with a soft information capsule. */
.stack .service-details {
  position: static !important;
  width: 100% !important;
  max-width: 620px !important;
  margin: 17px 0 0 !important;
  padding: 0 16px !important;
  border: 0 !important;
  border-radius: 16px !important;
  background: rgba(99, 17, 28, .07) !important;
  color: inherit !important;
  box-shadow: none !important;
}

.stack .c2 .service-details,
.stack .c5 .service-details {
  background: rgba(246, 245, 223, .13) !important;
}

.stack .service-details summary {
  min-height: 54px;
  padding: 8px 0 !important;
  border: 0 !important;
  font-size: 14px;
  line-height: 1.3;
}

.stack .service-details summary span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(99, 17, 28, .10);
  font-size: 20px;
  margin: 0 !important;
  position: static !important;
  transform: none;
}

.stack .c2 .service-details summary span,
.stack .c5 .service-details summary span {
  background: rgba(246, 245, 223, .14);
}

.stack .service-details[open] > div {
  position: static !important;
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  max-height: none !important;
  padding: 2px 0 16px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
  overflow: visible !important;
}

.stack .service-details[open] summary span { transform: rotate(45deg); }

@media (max-width: 900px) {
  html { scroll-padding-top: 18px !important; }
  section[id], .section-anchor { scroll-margin-top: 18px !important; }
  body { overflow-x: hidden; }

  /* The navigation appears once at the top and no longer covers content while scrolling. */
  nav {
    position: absolute !important;
    top: max(10px, env(safe-area-inset-top)) !important;
    left: 12px !important;
    right: 12px !important;
    transform: none !important;
    width: auto !important;
    min-height: 58px !important;
    margin: 0 !important;
    padding: 7px 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  nav .left {
    position: absolute !important;
    left: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    margin: 0 !important;
    gap: 0 !important;
  }

  nav .right {
    position: absolute !important;
    right: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    margin: 0 !important;
  }

  nav .left > a:not(.navlink),
  nav .right > a,
  nav .lang-sw {
    min-width: 44px !important;
    min-height: 44px !important;
  }

  nav .lang-sw {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    font-size: 10px !important;
    letter-spacing: 1.2px !important;
  }

  nav .logo {
    padding: 0 !important;
    font-size: clamp(25px, 7.6vw, 31px) !important;
  }

  /* Mobile hero: image and copy are deliberately separated. */
  .hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    overflow: hidden !important;
    background: var(--burdeos) !important;
  }

  .hero::before,
  .hero::after { display: none !important; }

  .hero-photo-mobile {
    position: relative;
    z-index: 0;
    order: 0;
    display: block;
    width: 100%;
    height: clamp(390px, 75vw, 560px);
    background: #2e2620;
    overflow: hidden;
  }

  .hero-photo-mobile img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 24%;
  }

  .hero-content {
    position: relative !important;
    z-index: 2 !important;
    order: 1;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 30px 28px 42px !important;
    background: var(--burdeos) !important;
    color: var(--crema) !important;
    text-align: left !important;
  }

  .hero-content .kicker {
    display: block !important;
    max-width: 46ch;
    margin: 0 0 18px !important;
    color: #f0c9cb !important;
    font-size: 11.5px !important;
    line-height: 1.65 !important;
    letter-spacing: 1.65px !important;
    text-shadow: none !important;
  }

  .hero h1 {
    max-width: 12ch !important;
    margin: 0 !important;
    color: var(--crema) !important;
    line-height: .98 !important;
    text-shadow: none !important;
  }

  .hero h1 .hero-q1,
  .hero h1 .hero-qmid,
  .hero h1 .hero-q2 {
    display: block !important;
    max-width: 100% !important;
    color: var(--crema) !important;
    font-size: clamp(32px, 9.4vw, 45px) !important;
    line-height: .98 !important;
    white-space: normal !important;
  }

  .hero-content p {
    max-width: 38ch !important;
    margin: 22px 0 26px !important;
    color: #fff !important;
    font-size: 16px !important;
    line-height: 1.55 !important;
    text-shadow: none !important;
  }

  .hero-content .btn {
    width: auto !important;
    min-width: 210px !important;
    margin: 0 !important;
    text-align: center;
  }

  .hero .sello { display: none !important; }

  /* Mobile services are a readable sequence, not overlapping sticky folders. */
  .servicios { padding: 44px 0 12px !important; }
  .servicios .wrap { padding-inline: 16px !important; }
  .serv-titulo { margin: 0 0 28px !important; }
  .stack { max-width: 680px !important; }

  .stack .carpeta {
    position: relative !important;
    inset: auto !important;
    top: auto !important;
    margin: 0 0 24px !important;
    padding: 0 !important;
  }

  .stack .tab {
    position: relative !important;
    inset: auto !important;
    display: inline-flex !important;
    align-items: center;
    width: auto !important;
    max-width: calc(100% - 32px) !important;
    min-height: 44px !important;
    margin: 0 0 -1px 16px !important;
    padding: 10px 17px !important;
    border-radius: 14px 14px 0 0 !important;
    overflow: visible !important;
    font-size: 10.5px !important;
    line-height: 1.15 !important;
    letter-spacing: 1.1px !important;
    text-overflow: clip !important;
    white-space: normal !important;
  }

  .stack .tab::before {
    content: attr(data-mobile) " · ";
    margin-right: 4px;
    opacity: .72;
  }

  .stack .tab::after {
    content: none !important;
    display: none !important;
  }

  .stack .cuerpo {
    position: relative !important;
    z-index: 1 !important;
    display: block !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 26px 22px 28px !important;
    border-radius: 22px !important;
    overflow: visible !important;
    text-align: left !important;
    box-shadow: 0 13px 32px rgba(42, 34, 38, .12) !important;
  }

  .stack .carpeta.mobile-covered .cuerpo > div:last-child {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  .stack .pol-desk { display: none !important; }
  .stack .pol-mov {
    display: block !important;
    width: 108px !important;
    min-width: 108px !important;
    margin: 0 !important;
    padding: 6px 6px 17px !important;
    transform: rotate(2deg) !important;
  }

  .stack .pol-mov .ph { height: 104px !important; }

  .stack .svc-top {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 108px !important;
    align-items: start !important;
    gap: 16px !important;
    margin-bottom: 22px !important;
  }

  .stack .svc-title { min-width: 0 !important; }
  .stack .cuerpo h3 {
    margin: 0 0 9px !important;
    font-size: clamp(23px, 7vw, 30px) !important;
    line-height: 1.02 !important;
    white-space: normal !important;
  }

  .stack .cuerpo p,
  .stack .cuerpo li {
    max-width: none !important;
    font-size: 15px !important;
    line-height: 1.55 !important;
  }

  .stack .cuerpo p { margin: 0 0 18px !important; }
  .stack .cuerpo ul { margin: 0 !important; }
  .stack .cuerpo .inc { margin-top: 4px !important; }

  .stack .service-details {
    margin-top: 17px !important;
    overflow: hidden !important;
  }

  .stack .cuerpo .precio-sv {
    position: static !important;
    inset: auto !important;
    margin: 20px 0 0 !important;
    font-size: clamp(34px, 10vw, 46px) !important;
    line-height: 1 !important;
  }

  .stack .cuerpo > div:last-child > .btn {
    position: static !important;
    inset: auto !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100% !important;
    min-height: 54px !important;
    margin: 18px 0 0 !important;
    padding: 14px 22px !important;
  }

  .stack .service-note { margin-top: 12px !important; }

  #reportes-card .svc-top {
    grid-template-columns: minmax(0, 1fr) 128px !important;
  }

  #reportes-card .pol-mov {
    width: 128px !important;
    min-width: 128px !important;
  }

  #reportes-card .pol-mov .ph { height: auto !important; }
  #reportes-card .report-title {
    max-width: 7.5ch;
    font-size: clamp(25px, 7.8vw, 33px) !important;
    line-height: .94 !important;
  }

  #reportes-card .report-title span { white-space: normal !important; }
  .report-pricing { display: block !important; }
  .report-regular { margin-bottom: 18px; }

  .wsp { display: none !important; }

  .sobre { padding: 52px 0 !important; }
  .sobre .sobre-grid { gap: 28px !important; }
  .sobre .sobre-foto {
    max-width: 230px !important;
    margin-inline: auto !important;
  }

  .sobre .rol-sub {
    max-width: 40ch !important;
    margin-inline: auto !important;
    font-size: 12px !important;
    line-height: 1.7 !important;
  }

  footer .f-col a,
  footer .f-soc a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  /* English testimonials become a short swipeable row instead of a tall stack. */
  .lang-en .reviews { overflow: hidden !important; }
  .lang-en .reviews .wrap { padding-inline: 0 !important; }
  .lang-en .reviews .rev-head { padding-inline: 24px !important; }
  .lang-en .reviews .rev-grid {
    display: flex !important;
    width: auto !important;
    max-width: 100% !important;
    gap: 14px !important;
    padding: 0 24px 12px !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory;
    animation: none !important;
    scrollbar-width: none;
  }

  .lang-en .reviews .rev-grid::-webkit-scrollbar { display: none; }
  .lang-en .reviews .r-card {
    position: relative !important;
    top: auto !important;
    flex: 0 0 min(82vw, 330px) !important;
    width: min(82vw, 330px) !important;
    min-height: 250px !important;
    margin: 0 !important;
    scroll-snap-align: start;
  }

  .lang-en .of-col {
    border: 1px solid rgba(99, 17, 28, .10) !important;
    background: rgba(246, 245, 223, .94) !important;
    color: var(--burdeos) !important;
  }

  .lang-en .of-col li,
  .lang-en .of-col h3 { color: var(--burdeos) !important; }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }

  .lang-en .oferta,
  .lang-en .fit,
  .lang-en .reviews {
    max-width: 100vw;
    overflow-x: hidden !important;
  }

  .lang-en .oferta .wrap,
  .lang-en .fit .wrap {
    width: 100% !important;
    max-width: 100% !important;
    padding-inline: 16px !important;
  }

  .lang-en .of-card,
  .lang-en .of-col,
  .lang-en .fit-card {
    width: 100% !important;
    min-width: 0 !important;
  }

  .lang-en .of-list li,
  .lang-en .fit-card li {
    min-width: 0 !important;
    overflow-wrap: anywhere;
  }
}

@media (min-width: 600px) and (max-width: 900px) {
  .hero h1 { max-width: 17ch !important; }
  .hero-content p { max-width: 50ch !important; }
}

@media (max-width: 360px) {
  .hero-content { padding-inline: 22px !important; }
  .stack .cuerpo { padding-inline: 18px !important; }
  .stack .svc-top { grid-template-columns: minmax(0, 1fr) 92px !important; gap: 11px !important; }
  .stack .pol-mov { width: 92px !important; min-width: 92px !important; }
  .stack .pol-mov .ph { height: 90px !important; }
  #reportes-card .svc-top { grid-template-columns: minmax(0, 1fr) 106px !important; }
  #reportes-card .pol-mov { width: 106px !important; min-width: 106px !important; }
}
