/* ==========================================================
   Accu-Chek SmartGuide — Mobile-first CSS
   Matches Figma design exactly
   ========================================================== */

/* Roche Sans — local font files */
@font-face {
  font-family: 'Roche Sans';
  src: url('fonts/RocheSans-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Roche Sans';
  src: url('fonts/RocheSans-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Roche Sans';
  src: url('fonts/RocheSans-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Roche Sans';
  src: url('fonts/RocheSans-Light.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

/* --- Custom Properties --- */
:root {
  --green: #8eb927;
  --green-dark: #7da421;
  --teal: #009ca6;
  --teal-light: #e5f5f6;
  --teal-bg: #eaf7f7;
  --dark: #2a2a2a;
  --text: #2a2a2a;
  --text-secondary: #2a2a2a;
  --text-light: #777777;
  --white: #ffffff;
  --gray-bg: #f1f1f1;
  --footer-bg: #2d2d2d;
  --font: "Roche Sans", system-ui, -apple-system, sans-serif;
  --menu-rapido-bar-height: 56px;
}

/* --- Reset --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-bottom: calc(var(--menu-rapido-bar-height) + env(safe-area-inset-bottom, 0px) + 16px);
}

body {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  background: #f1f1f1;
  line-height: 1.6;
  padding: 0 10px;
  padding-bottom: calc(var(--menu-rapido-bar-height) + env(safe-area-inset-bottom, 0px) + 16px);
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}
sup {
  font-size: 1em;
  vertical-align: super;
  position: relative;
  top: 0.35em;
  line-height: 0;
}

/* ==========================================================
   HEADER
   ========================================================== */
.header {
  background: #f1f1f1;
}

.header__inner {
  position: relative;
  max-width: 480px;
  margin: 0 auto;
  padding: 20px 20px 16px;
}

.header__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.header__logo {
  height: 36px;
  width: auto;
}

.header__name {
  font-size: 20px;
  font-weight: 400;
  color: #5c5c5c;
  letter-spacing: 0.02em;
}

/* Country navigation replaces the language switcher. */
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header__country {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 8px 12px;
  border: 1px solid #dce5e5;
  border-radius: 18px;
  background: var(--white);
  color: var(--text);
  box-shadow: 0 2px 6px rgb(42 42 42 / 3%);
  font-size: 13px;
  line-height: 1.3;
  text-align: left;
}

.header__country-arrow {
  flex-shrink: 0;
  color: #006b73;
  padding: 5px;
  border-radius: 50%;
  background: var(--teal-light);
}

.header__inner:has(.country-menu:popover-open) .header__country-arrow {
  transform: rotate(180deg);
}

.header__inner:has(.country-menu:popover-open) .header__country {
  border-color: var(--teal);
}

.header__country .country-flag {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gray-bg);
  font-size: 22px;
  line-height: 1;
}

.header__country-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-weight: 700;
}

.header__country-hint {
  color: #006b73;
  font-size: 11px;
  font-weight: 400;
}

.header__country:hover {
  border-color: var(--teal);
}

.country-menu {
  position: fixed;
  inset: clamp(16px, 104px, calc(100dvh - 390px)) max(16px, calc((100vw - 1200px) / 2)) auto auto;
  margin: 0;
  width: min(320px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px - env(safe-area-inset-bottom, 0px));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 10px;
  border: 1px solid #dce5e5;
  border-radius: 22px;
  background: var(--white);
  color: var(--text);
  box-shadow: 0 16px 40px rgb(42 42 42 / 12%), 0 3px 10px rgb(42 42 42 / 4%);
}

@supports (top: anchor(bottom)) {
  .header__country {
    anchor-name: --country-trigger;
  }

  .country-menu {
    position-anchor: --country-trigger;
    top: clamp(16px, calc(anchor(bottom) + 10px), calc(100dvh - 390px));
    right: clamp(16px, anchor(right), calc(100vw - 336px));
  }
}

.country-menu__heading {
  padding: 10px 12px 16px;
  margin-bottom: 6px;
  border-bottom: 1px solid #e9eeee;
}

.country-menu__heading p:first-child {
  font-size: 15px;
  font-weight: 700;
}

.country-menu__heading p:last-child {
  color: #626c6c;
  font-size: 12px;
  text-wrap: pretty;
}

.country-menu__option {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 62px;
  padding: 10px 12px;
  border-radius: 14px;
}

.country-menu__option + .country-menu__option {
  margin-top: 4px;
}

.country-menu__option:hover {
  background: var(--gray-bg);
}

.country-menu__option[aria-current="page"] {
  background: var(--teal-light);
  color: #006b73;
}

.country-menu__option:focus-visible {
  outline-offset: -2px;
}

.country-menu__option .country-flag {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gray-bg);
  font-size: 23px;
  line-height: 1;
}

.country-menu__option[aria-current="page"] .country-flag {
  background: var(--white);
}

.country-menu__text {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 2px;
}

.country-menu__name {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  text-wrap: balance;
}

.country-menu__status {
  font-size: 11px;
  line-height: 1.4;
}

.country-menu__check {
  flex-shrink: 0;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid #006b73;
  outline-offset: 4px;
}

/* Remove padding from main so cards handle their own spacing */
main {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ==========================================================
   CARD (shared)
   ========================================================== */
.card {
  background: var(--white);
  border-radius: 10px;
  overflow: hidden;
}

/* ==========================================================
   HERO
   ========================================================== */
.hero {
  margin-bottom: 10px;
}

.hero__content {
  padding: 28px 24px 0;
}

.hero__title {
  font-size: 37px;
  font-weight: 700;
  line-height: 22px;
  color: var(--dark);
  margin-bottom: 20px;
  max-width: 287px;
}

.hero__title-line1 {
  display: block;
  text-align: left;
}

.hero__title-line2 {
  display: block;
  text-align: right;
}

html[lang="en"] .hero__title {
  font-size: 32px;
  line-height: 1.05;
  max-width: 320px;
}

.hero__line {
  width: 80%;
  height: 3px;
  background: linear-gradient(90deg, var(--teal), var(--green));
  border: none;
  border-radius: 2px;
  /* margin: 0 0 20px; */
  margin-left: auto;
  margin-right: auto;
  margin-top: 40px;
  margin-bottom: 20px;
}

.hero__text {
  font-size: 15px;
  color: var(--text);
  line-height: 25px;
  text-align: center;
  margin-bottom: 0;
  padding: 0 0 24px;
}

.hero__image {
  width: 100%;
  display: block;
  clip-path: ellipse(100% 90% at 50% 90%);
}

.hero__image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.hero__image-placeholder {
  width: 100%;
  aspect-ratio: 407 / 247;
  background: linear-gradient(135deg, #4db8b8 0%, #7ecfc5 50%, #a5d6a7 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================================
   QUE ES SECTION
   ========================================================== */
.que-es__top {
  position: relative;
  display: flex;
  justify-content: center;
  padding-top: 10px;
  padding-bottom: 20px;
  background: var(--white);
}

.que-es__top::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 70%;
  background: #beecf1;
}

.que-es__top::after {
  content: "";
  position: absolute;
  top: 50%;
  left: -10%;
  width: 120%;
  height: 60px;
  background: var(--white);
  border-radius: 50% 50% 0 0;
  transform: translateY(-100%);
  margin-top: 80px;
}

.que-es__img {
  max-width: 75%;
  height: auto;
  display: block;
  position: relative;
  z-index: 1;
}

.que-es__bottom {
  background: var(--white);
  padding: 0 28px 24px 32px;
  text-align: center;
}

.que-es__title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.3;
  margin-bottom: 20px;
}

.que-es__text {
  font-size: 15px;
  color: var(--text);
  line-height: 25px;
  margin-bottom: 16px;
}

.que-es__text:last-of-type {
  margin-bottom: 28px;
}

/* --- Button --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 32px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 700;
  transition:
    background-color 0.2s,
    transform 0.1s;
}

.btn:active {
  transform: scale(0.97);
}

.btn--green {
  background: var(--green);
  color: var(--white);
}

.btn--green:hover {
  background: var(--green-dark);
}

.btn--gradient {
  background: linear-gradient(241.17deg, #26becf, #8eb927);
  color: var(--white);
  font-size: 18px;
  padding: 0;
  height: 50px;
  width: 100%;
  justify-content: center;
}

.btn--gradient:hover {
  opacity: 0.9;
}

/* ==========================================================
   QUE INCLUYE SECTION
   ========================================================== */
.incluye {
  padding: 32px 24px;
  text-align: center;
}

.incluye__title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.35;
  margin-bottom: 24px;
}

.incluye__img {
  width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================
   PASOS - COMO UTILIZAR
   ========================================================== */
.pasos {
  padding: 32px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.pasos__title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  text-align: center;
  margin-bottom: 12px;
}

.pasos__subtitle {
  font-size: 15px;
  color: var(--text);
  text-align: center;
  line-height: 25px;
  margin-bottom: 16px;
  padding: 0 20px;
}

.paso {
  display: grid;
  grid-template-columns: 40% 1fr;
  gap: 0;
  padding: 12px;
}

.paso--alt {
  direction: rtl;
}

.paso--alt > * {
  direction: ltr;
}

.paso__img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
}

.paso__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 16px;
}

.paso__number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--teal);
  color: var(--white);
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 10px;
}

.paso__text {
  font-size: 15px;
  font-weight: 400;
  color: var(--text);
  line-height: 20px;
}

.pasos__badge {
  display: flex;
  justify-content: center;
  padding: 12px 40px;
  border-radius: 50px;
  margin: 0 auto;
  width: fit-content;
  font-size: 15px;
  color: var(--text);
  background: var(--white);
  border: 2.5px solid transparent;
  background-image:
    linear-gradient(white, white),
    linear-gradient(135deg, var(--green), var(--teal));
  background-origin: border-box;
  background-clip: padding-box, border-box;
}

/* ==========================================================
   BLUETOOTH SECTION
   ========================================================== */
.bluetooth {
  background: #beecf1;
  padding: 10px 24px 44px 24px;
  text-align: center;
}

.bluetooth__img {
  max-width: 70%;
  height: auto;
  margin: 0 auto 24px;
}

.bluetooth__title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.3;
  margin-bottom: 16px;
}

.bluetooth__text {
  font-size: 15px;
  color: var(--text);
  line-height: 25px;
  margin-bottom: 16px;
}

.bluetooth .btn {
  margin-top: 12px;
}

/* ==========================================================
   CONTACTO
   ========================================================== */
.contacto {
  padding: 32px 0;
  text-align: center;
}

.contacto__title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  text-align: center;
  line-height: 1.35;
  margin-bottom: 24px;
  width: 90%;
  margin-left: auto;
  margin-right: auto;
}

.contacto__box {
  border-radius: 10px;
  padding: 24px 20px;
  margin-bottom: 16px;
  background: linear-gradient(#F1F1F1, #F1F1F1) padding-box, linear-gradient(180deg, #26becf, #82b93a) border-box;
  border: 2px solid transparent;
  width: 90%;
  margin-left: auto;
  margin-right: auto;
}

.contacto__country {
  font-size: 22px;
  font-weight: 700;
  color: var(--teal);
  margin-bottom: 12px;
}

.contacto__detail {
  font-size: 15px;
  color: var(--text);
  line-height: 25px;
}

.contacto__detail a {
  text-decoration: underline;
}

.contacto__btn {
  margin-top: 16px;
  width: 70%;
}

/* ==========================================================
   DOWNLOADS
   ========================================================== */
.downloads {
  overflow: hidden;
  background: transparent;
  border-radius: 0;
}

.downloads__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.downloads__col {
  padding: 20px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  border-radius: 10px;
}

.downloads__col--green {
  background: #D5E3C0;
}

.downloads__col--teal {
  background: #BEECF1;
}

.downloads__phone {
  width: 90%;
  height: 280px;
  object-fit: contain;
  object-position: bottom;
  margin-bottom: 16px;
}

.downloads__col--teal .downloads__phone {
  width: 86%;
}

.downloads__label {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.3;
  margin-bottom: 16px;
}

.downloads__badges {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.downloads__badges a {
  display: block;
}

.downloads__badges img {
  width: 80%;
  height: auto;
  margin: 0 auto;
}

/* ==========================================================
   FOOTER
   ========================================================== */
.footer {
  padding: 32px 24px 80px;
  border-radius: 0 !important;
  margin-top: 20px;
  margin-left: -10px;
  margin-right: -10px;
}

.footer__logos {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.footer__logo-roche {
  height: 32px;
  width: auto;
}

.footer__logo-accu {
  height: 28px;
  width: auto;
}

/* Social links */
.footer__social {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.footer__social-item {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #F1F1F1;
  border-radius: 50px;
  padding: 10px 28px;
  width: 80%;
}

.footer__social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.footer__social-icon svg {
  width: 28px;
  height: 28px;
}

.footer__social-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
}

/* Gradient line */
.footer__line {
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--teal), var(--green));
  border: none;
  border-radius: 2px;
  margin-bottom: 28px;
}

/* Legal */
.footer__legal {
  text-align: center;
}

.footer__legal-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 12px;
}

.footer__legal-text {
  font-size: 13px;
  color: var(--text);
  line-height: 22px;
  margin-bottom: 16px;
}

/* ==========================================================
   MENU RAPIDO STICKY
   ========================================================== */
.menu-rapido {
  position: fixed;
  bottom: 10px;
  left: 10px;
  right: 10px;
  z-index: 9999;
  background: linear-gradient(241.17deg, #26becf, #8eb927);
  border-radius: 50px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  overflow: hidden;
  max-height: 56px;
  transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1), border-radius 0.3s ease;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.menu-rapido.is-open {
  max-height: min(60vh, 520px);
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.2);
}

.menu-rapido__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  padding: 0 12px 0 24px;
  cursor: pointer;
  flex-shrink: 0;
}

.menu-rapido__label {
  font-size: 16px;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 0.05em;
}

.menu-rapido__toggle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
  flex-shrink: 0;
}

.menu-rapido__arrow {
  transition: transform 0.3s ease;
}

.menu-rapido.is-open .menu-rapido__arrow {
  transform: rotate(180deg);
}

.menu-rapido__panel {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 16px 16px;
}

.menu-rapido__item {
  display: block;
  background: rgba(255,255,255,0.7);
  border-radius: 50px;
  padding: 12px 22px;
  font-size: 14px;
  font-weight: 700;
  color: var(--dark);
}

/* Desktop artwork is represented as readable columns; mobile keeps its original diagram. */
.incluye__desktop {
  display: none;
}

/* ==========================================================
   COUNTRY PAGES — TABLET AND DESKTOP
   ========================================================== */
@media (min-width: 768px) {
  body:not(.country-gateway) {
    padding-inline: 24px;
  }

  .header__inner,
  body:not(.country-gateway) > main,
  .footer {
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
  }

  .header__inner {
    padding: 28px 0;
  }

  .header__logo {
    height: 42px;
  }

  body:not(.country-gateway) > main {
    gap: 24px;
  }

  .card {
    border-radius: 20px;
  }

  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
    margin-bottom: 0;
    min-height: 410px;
  }

  .hero__content {
    padding: 40px 32px;
    align-self: center;
  }

  .hero__title {
    max-width: none;
    margin-bottom: 0;
    font-size: clamp(38px, 4.3vw, 60px);
    line-height: 1.12;
    text-wrap: balance;
  }

  .hero__title br {
    display: none;
  }

  .hero__title-line2 {
    text-align: left;
  }

  .hero__line {
    width: 100%;
    max-width: 320px;
    margin: 24px 0;
  }

  .hero__text {
    max-width: 450px;
    padding: 0;
    font-size: 17px;
    line-height: 1.65;
    text-align: left;
    text-wrap: pretty;
  }

  .hero__image {
    height: 100%;
    min-height: 410px;
    /* Preserve the curved mobile crop and rectangular desktop photograph. */
    clip-path: none !important;
  }

  .hero__image img {
    height: 100%;
    object-fit: cover;
    object-position: 55% center;
  }

  .que-es {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  }

  .que-es__top {
    align-items: center;
    padding: 36px;
    background: #beecf1;
  }

  .que-es__top::before,
  .que-es__top::after {
    display: none;
  }

  .que-es__img {
    width: 100%;
    max-width: 290px;
  }

  .que-es__bottom {
    align-self: center;
    padding: 40px 32px;
    text-align: left;
  }

  .que-es__title,
  .incluye__title,
  .pasos__title,
  .bluetooth__title,
  .contacto__title {
    font-size: clamp(26px, 2.8vw, 34px);
    line-height: 1.25;
    text-wrap: balance;
  }

  .que-es__text,
  .bluetooth__text {
    font-size: 17px;
    line-height: 1.65;
    text-wrap: pretty;
  }

  .que-es__bottom .btn,
  .bluetooth .btn,
  .contacto__btn {
    width: auto;
    min-width: 220px;
    padding-inline: 28px;
  }

  .incluye {
    padding: 40px 32px;
  }

  .incluye__title {
    margin-bottom: 36px;
  }

  .incluye__img {
    display: none;
  }

  .incluye__desktop {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
    text-align: left;
  }

  .solution-item__image {
    width: 100%;
    height: 240px;
    object-fit: contain;
    margin-bottom: 24px;
  }

  .solution-item h3 {
    color: #006b73;
    font-size: 19px;
    line-height: 1.35;
    margin-bottom: 14px;
    text-wrap: balance;
  }

  .solution-item p,
  .solution-item li {
    font-size: 15px;
    line-height: 1.55;
    text-wrap: pretty;
  }

  .solution-item ul {
    padding-left: 18px;
  }

  .solution-item li + li {
    margin-top: 8px;
  }

  .solution-item span {
    white-space: nowrap;
  }

  .incluye__footnote {
    grid-column: 1 / -1;
    font-size: 12px;
    line-height: 1.6;
    color: var(--text-secondary);
  }

  .pasos {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    padding: 32px 0;
  }

  .pasos__title,
  .pasos__subtitle {
    grid-column: 1 / -1;
    margin: 0 auto;
    max-width: 700px;
  }

  .pasos__subtitle {
    font-size: 17px;
    line-height: 1.65;
    padding: 0 0 12px;
    text-wrap: pretty;
  }

  .paso,
  .paso--alt {
    direction: ltr;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    align-items: center;
    padding: 20px;
  }

  .paso__body {
    padding: 0 0 0 20px;
  }

  .paso__text {
    line-height: 1.5;
    text-wrap: pretty;
  }

  .paso__number {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }

  .pasos__badge {
    grid-column: 1 / -1;
  }

  .paso:last-child {
    grid-column: 1 / -1;
    width: calc((100% - 20px) / 2);
    justify-self: center;
  }

  .bluetooth {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    column-gap: 40px;
    padding: 40px 32px;
    align-items: center;
    text-align: left;
  }

  .bluetooth__img {
    grid-column: 1;
    grid-row: 1 / 4;
    width: 100%;
    max-width: 290px;
    margin: 0 auto;
  }

  .bluetooth__title,
  .bluetooth__text,
  .bluetooth .btn {
    grid-column: 2;
  }

  .bluetooth .btn {
    justify-self: start;
  }

  .contacto {
    padding: 32px 0;
  }

  .contacto__title {
    max-width: 680px;
  }

  .contacto__box {
    width: 100%;
    max-width: 700px;
    padding: 32px;
    border-radius: 20px;
  }

  .contacto__detail {
    font-size: 17px;
    line-height: 1.7;
  }

  .downloads__grid {
    gap: 24px;
  }

  .downloads__col {
    padding: 32px;
    border-radius: 20px;
  }

  .downloads__phone,
  .downloads__col--teal .downloads__phone {
    width: 100%;
    height: 320px;
    margin-bottom: 24px;
  }

  .downloads__badges {
    flex-direction: row;
    justify-content: center;
    gap: 12px;
  }

  .downloads__badges a {
    flex: 1;
    width: auto;
    max-width: 160px;
    min-width: 0;
  }

  .downloads__badges img {
    width: 100%;
  }

  .footer {
    margin-top: 40px;
    padding: 40px 40px 80px;
  }

  .footer__social {
    flex-direction: row;
    gap: 16px;
  }

  .footer__social-item {
    width: auto;
    flex: 1;
    justify-content: center;
    padding: 12px;
    gap: 8px;
    min-width: 0;
  }

  .footer__social-icon {
    width: 28px;
    height: 28px;
  }

  .footer__social-name {
    font-size: 13px;
    overflow-wrap: anywhere;
  }

  .footer__legal {
    max-width: 960px;
    margin-inline: auto;
  }

  .menu-rapido {
    width: calc(100% - 48px);
    max-width: 1200px;
    left: 0;
    right: 0;
    margin-inline: auto;
  }

  .menu-rapido__panel {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    overflow-y: auto;
    max-height: calc(60dvh - var(--menu-rapido-bar-height) - 24px);
  }
}

@media (min-width: 1024px) {
  .hero {
    min-height: 460px;
  }

  .hero__content {
    padding: 56px;
  }

  .hero__image {
    min-height: 460px;
  }

  .que-es__top,
  .que-es__bottom,
  .incluye,
  .bluetooth {
    padding: 48px;
  }

  .solution-item__image {
    height: 270px;
  }

  .paso__text {
    font-size: 17px;
  }

  .footer__social-name {
    font-size: 15px;
  }
}

/* ==========================================================
   mySugr configuration — Guatemala, Panamá and República Dominicana
   ========================================================== */
.country-page--mysugr .mysugr-sensor-caption {
  margin: 0 0 24px;
  font-size: 15px;
  line-height: 1.5;
  text-wrap: pretty;
}

.country-page--mysugr .incluye__img {
  margin-inline: auto;
  max-width: 428px;
}

.country-page--mysugr .downloads__grid {
  grid-template-columns: minmax(0, 1fr);
}

.country-page--mysugr .downloads__col {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 20px;
  align-items: center;
  padding: 32px 20px;
}

.country-page--mysugr .downloads__phone {
  width: 100%;
  max-width: 252px;
  height: auto;
  margin: 0 auto;
}

.country-page--mysugr .downloads__label {
  font-size: 22px;
}

.country-page--mysugr .downloads__badges {
  flex-direction: column;
  gap: 12px;
}

.country-page--mysugr .downloads__badges a {
  width: 100%;
  max-width: 220px;
  margin-inline: auto;
  flex: none;
}

.country-page--mysugr .downloads__badges img {
  width: 100%;
}

@media (min-width: 768px) {
  .country-page--mysugr .mysugr-sensor-caption {
    display: none;
  }

  .country-page--mysugr .mysugr-solution-overview {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
    align-items: center;
    gap: 48px;
    max-width: 860px;
    margin: 0 auto 16px;
  }

  .country-page--mysugr .mysugr-solution-overview img {
    width: 100%;
    max-width: 280px;
    height: auto;
    margin-inline: auto;
  }

  .country-page--mysugr .mysugr-solution-sensor {
    margin-bottom: 20px;
    font-size: 15px;
  }

  .country-page--mysugr .mysugr-solution-overview h3 {
    color: #006b73;
    font-size: 28px;
    line-height: 1.25;
    margin-bottom: 16px;
    text-wrap: balance;
  }

  .country-page--mysugr .mysugr-solution-overview p:last-child {
    font-size: 17px;
    line-height: 1.65;
    text-wrap: pretty;
  }

  .country-page--mysugr .mysugr-functions-heading {
    grid-column: 1 / -1;
    max-width: 680px;
    margin: 0 auto 8px;
    font-size: 20px;
    font-weight: 700;
    color: #006b73;
    text-align: center;
    text-wrap: balance;
  }

  .country-page--mysugr .mysugr-function-card {
    padding: 24px;
    border: 1px solid #d4dfdf;
    border-radius: 16px;
    background: var(--teal-bg);
  }

  .country-page--mysugr .mysugr-function-card p {
    margin-bottom: 16px;
  }

  .country-page--mysugr .mysugr-function-group {
    color: #006b73;
    font-size: 13px;
    font-weight: 700;
  }

  .country-page--mysugr .downloads__col {
    max-width: 860px;
    width: 100%;
    margin-inline: auto;
    padding: 48px;
    gap: 48px;
  }

  .country-page--mysugr .downloads__phone {
    max-height: 360px;
    object-fit: contain;
  }

  .country-page--mysugr .downloads__label {
    font-size: 30px;
    margin-bottom: 24px;
  }
}

/* ==========================================================
   COUNTRY GATEWAY
   ========================================================== */
.country-gateway {
  min-height: 100dvh;
  padding: 0 28px;
  background-color: var(--teal-bg);
  background-image:
    radial-gradient(ellipse at 5% 12%, rgb(142 185 39 / 18%), transparent 55%),
    radial-gradient(ellipse at 95% 85%, rgb(0 156 166 / 18%), transparent 60%),
    linear-gradient(135deg, #fafdf7 0%, #eef9f6 45%, #e6f5f6 100%);
  display: flex;
  flex-direction: column;
}

.gateway-header,
.gateway-footer {
  width: 100%;
  max-width: 1056px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.gateway-header {
  padding: 32px 0;
}

.gateway-header img {
  width: 159px;
  height: 42px;
}

.gateway-header__region {
  font-size: 13px;
  color: #466566;
}

.gateway-main {
  width: 100%;
  max-width: 1000px;
  margin: auto;
  padding: 36px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 80px;
}

.gateway-intro__eyebrow {
  color: #006b73;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 18px;
}

.gateway-intro h1 {
  font-size: clamp(36px, 4vw, 52px);
  line-height: 1.1;
  font-weight: 700;
  text-wrap: balance;
}

.gateway-intro__description {
  max-width: 360px;
  margin-top: 20px;
  font-size: 18px;
  line-height: 1.55;
  text-wrap: pretty;
}

.gateway-intro__product {
  display: block;
  width: 280px;
  height: auto;
  margin-top: 28px;
}

.gateway-intro__product img {
  width: 100%;
  height: auto;
}

.country-picker {
  padding: 36px;
  border-radius: 24px;
  background: var(--white);
  border: 1px solid #d8e8e8;
  box-shadow: 0 8px 24px rgb(0 0 0 / 5%);
}

.country-picker h2 {
  font-size: 28px;
  line-height: 1.2;
  text-wrap: balance;
}

.country-picker__description {
  margin-top: 12px;
  color: #526363;
  font-size: 16px;
  line-height: 1.5;
  text-wrap: pretty;
}

.country-options {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
}

.country-option {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 76px;
  padding: 16px 18px;
  border: 1px solid #d4dfdf;
  border-radius: 12px;
  background: var(--white);
}

.country-option:hover {
  border-color: var(--teal);
  background: var(--teal-bg);
}

.country-flag {
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
  font-size: 32px;
  line-height: 1;
  flex-shrink: 0;
}

.country-option__name {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.35;
}

.country-option__arrow {
  margin-left: auto;
  flex-shrink: 0;
  color: #006b73;
}

.country-picker__note {
  margin-top: 24px;
  color: #526363;
  font-size: 13px;
  line-height: 1.5;
  text-wrap: pretty;
}

.gateway-footer {
  padding: 28px 0 max(28px, env(safe-area-inset-bottom));
  font-size: 12px;
  color: #466566;
  line-height: 1.5;
}

.gateway-footer img {
  width: 64px;
  height: auto;
}

@media (max-width: 767px) {
  .country-gateway {
    padding: 0 20px;
  }

  .gateway-header {
    padding: 24px 0;
  }

  .gateway-header__region {
    max-width: 120px;
    text-align: right;
    font-size: 11px;
  }

  .gateway-main {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
    padding: 20px 0;
    max-width: 480px;
  }

  .gateway-intro__eyebrow {
    font-size: 14px;
    margin-bottom: 12px;
  }

  .gateway-intro__description {
    font-size: 16px;
    margin-top: 16px;
  }

  .gateway-intro__product {
    display: none;
  }

  .country-picker {
    padding: 24px;
    border-radius: 20px;
  }

  .country-picker h2 {
    font-size: 24px;
  }

  .country-options {
    margin-top: 24px;
  }

  .country-option {
    padding: 14px;
    gap: 12px;
    min-height: 70px;
  }

  .country-option__name {
    font-size: 16px;
  }
}

@media (max-width: 374px) {
  .header__inner {
    padding-inline: 8px;
    gap: 8px;
  }

  .header__logo {
    height: 30px;
  }

  .header__country {
    padding: 6px 8px;
    font-size: 11px;
  }
}

/* Supplied mySugr brand mark, used in Panama's solution and download panels. */
.country-page--pa .mysugr-logo {
  display: block;
  width: min(180px, 100%);
  height: auto;
  margin: 0 auto 12px;
}
.country-page--pa .mysugr-solution-overview .mysugr-logo {
  width: min(180px, 100%);
  height: auto;
  max-height: none;
  object-fit: contain;
  margin-inline: 0;
}
