:root{
  --bg:#ffffff;
  --surface:#f6f8fb;
  --surface2:#eef3f8;
  --text:#0f172a;
  --muted:#5b6475;
  --line:#e6ebf2;
  --primary:#0b4b7a;
  --primary2:#19a7a5;
  --radius:18px;
  --shadow: 0 10px 30px rgba(2,12,27,.10);
  --shadow2: 0 8px 20px rgba(2,12,27,.08);
  --maxw: 1120px;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color:var(--text);
  background:var(--bg);
}

a{color:inherit; text-decoration:none}
img{max-width:100%; display:block}

.container{max-width:var(--maxw); margin:0 auto; padding:0 18px}
.section{padding:76px 0}
.section.alt{background:linear-gradient(180deg,var(--surface), #fff)}
.kicker{
  display:inline-flex; gap:10px; align-items:center;
  padding:8px 12px; border:1px solid var(--line); border-radius:999px;
  color:var(--primary); background:#fff;
  font-weight:600; font-size:12px; letter-spacing:.08em; text-transform:uppercase;
}
.h2{font-size:38px; line-height:1.15; margin:14px 0 10px}
.lead{color:var(--muted); font-size:16px; line-height:1.7; max-width:64ch}
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:10px;
  padding:12px 16px; border-radius:12px; border:1px solid var(--line);
  background:#fff; font-weight:700;
  box-shadow: 0 8px 18px rgba(2,12,27,.06);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.btn:hover{transform:translateY(-1px); box-shadow: 0 12px 24px rgba(2,12,27,.10); border-color:#d9e2ef}
.btn.primary{
  background:linear-gradient(135deg, var(--primary), #0f2a43);
  border-color:transparent; color:#fff;
}
.btn.ghost{background:transparent; box-shadow:none}
.btn.small{padding:10px 12px; border-radius:10px; font-weight:700}
.btnRow{display:flex; gap:12px; flex-wrap:wrap; margin-top:18px}

.topbar{
  position:sticky; top:0; z-index:50;
  background:rgba(255,255,255,.86);
  backdrop-filter:saturate(140%) blur(12px);
  border-bottom:1px solid rgba(230,235,242,.9);
}
.navWrap{display:flex; align-items:center; justify-content:space-between; padding:14px 0}
.brand{display:flex; align-items:center; gap:12px; min-width:unset}
.brand img{
  /* Logo más grande (sin estirar) */
  height:clamp(56px, 6.5vw, 96px);
  width:auto;
  max-width:240px;
  object-fit:contain;
}
.brand .name{font-weight:900; letter-spacing:.02em}
.brand .tag{font-size:12px; color:var(--muted); margin-top:1px}

.nav{display:flex; gap:18px; align-items:center}
.nav a{
  padding:10px 10px; border-radius:10px;
  color:var(--muted); font-weight:800; font-size:13px; letter-spacing:.02em;
}
.nav a:hover{background:var(--surface); color:var(--text)}
.menuBtn{display:none}

.mobileNav{display:none}

.hero{
  position:relative; min-height:78vh;
  display:grid; place-items:center;
  overflow:hidden;
  background: radial-gradient(1200px 700px at 20% 0%, rgba(25,167,165,.18), transparent 55%),
              radial-gradient(1000px 600px at 100% 10%, rgba(11,75,122,.22), transparent 50%),
              linear-gradient(180deg, #fff, var(--surface));
  border-bottom:1px solid var(--line);
}
.heroGrid{
  display:grid; grid-template-columns: 1.1fr .9fr; gap:34px;
  align-items:center; padding:52px 0 70px;
}
.heroTitle{font-size:46px; line-height:1.06; margin:16px 0 12px; letter-spacing:-.02em}
.heroSubtitle{color:var(--muted); font-size:16px; line-height:1.7}
.heroBadge{display:inline-flex; gap:10px; align-items:center; padding:9px 12px; border-radius:999px;
  background:#fff; border:1px solid var(--line); box-shadow:var(--shadow2); font-weight:800; font-size:12px}
.heroBadge .dot{width:10px; height:10px; border-radius:99px; background:linear-gradient(135deg,var(--primary2),var(--primary))}
.heroCard{
  position:relative; border-radius:24px; overflow:hidden; border:1px solid var(--line);
  box-shadow: var(--shadow);
  background:#0f2a43;
}
.heroCard video{
  width:100%; height:430px; object-fit:cover; display:block; opacity:.55;
}
.heroCard .overlay{
  position:absolute; inset:0;
  background:linear-gradient(180deg, rgba(15,42,67,.10), rgba(15,42,67,.72));
}
.heroSlides{
  position:absolute; inset:0; mix-blend-mode:screen; opacity:.55;
}
.heroSlides img{
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover;
  opacity:0; transition:opacity 1.1s ease;
}
.heroSlides img.active{opacity:1}

.heroMini{
  position:absolute; left:18px; right:18px; bottom:18px;
  display:flex; align-items:center; justify-content:space-between; gap:10px;
}
.pills{display:flex; gap:8px; flex-wrap:wrap}
.pill{
  background:rgba(255,255,255,.12); border:1px solid rgba(255,255,255,.18);
  color:#fff; padding:8px 10px; border-radius:999px; font-weight:800; font-size:12px;
}
.controls{display:flex; gap:8px}
.iconBtn{
  width:40px; height:40px; border-radius:12px;
  background:rgba(255,255,255,.14); border:1px solid rgba(255,255,255,.22);
  color:#fff; display:grid; place-items:center; cursor:pointer;
}
.iconBtn:hover{background:rgba(255,255,255,.18)}

.featureGrid{
  display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-top:26px;
}
.card{
  border:1px solid var(--line); border-radius:var(--radius);
  background:#fff; box-shadow:var(--shadow2);
  padding:18px;
}
.card h3{margin:8px 0 6px; font-size:16px}
.card p{margin:0; color:var(--muted); line-height:1.6; font-size:14px}
.card .icon{
  width:46px; height:46px; border-radius:14px;
  background:linear-gradient(135deg, rgba(25,167,165,.18), rgba(11,75,122,.18));
  border:1px solid var(--line);
  display:grid; place-items:center; font-weight:900; color:var(--primary);
}

.split{
  display:grid; grid-template-columns: 1fr 1fr; gap:26px; align-items:start;
  margin-top:26px;
}
.panel{
  border:1px solid var(--line); border-radius:var(--radius);
  background:#fff; box-shadow:var(--shadow2);
  overflow:hidden;
}
.panelHead{
  padding:18px; border-bottom:1px solid var(--line);
  display:flex; align-items:center; justify-content:space-between; gap:10px;
}
.panelHead strong{font-size:14px}
.panelBody{padding:0}
.accordionItem{border-top:1px solid var(--line)}
.accordionBtn{
  width:100%; background:#fff; border:none; text-align:left;
  padding:14px 18px; display:flex; gap:16px; align-items:center; cursor:pointer;
}
.accordionBtn:hover{background:var(--surface)}
/* Service thumbnail + icon */
.accordionBtn .svcMedia{position:relative; width:96px; height:72px; flex:0 0 auto}
.accordionBtn .svcThumb{width:96px; height:72px; border-radius:14px; object-fit:cover; display:block; border:1px solid var(--line)}
.accordionBtn .svcIcon{position:absolute; right:-10px; bottom:-10px; width:32px; height:32px; padding:7px; border-radius:999px; background:#fff; border:1px solid var(--line); object-fit:contain}
@media (max-width:520px){
  .brand img{height:clamp(50px, 14vw, 78px); width:auto; max-width:220px}

  .accordionBtn .svcMedia{width:86px; height:64px}
  .accordionBtn .svcThumb{width:86px; height:64px}
  .accordionBtn .svcIcon{right:-8px; bottom:-8px; width:30px; height:30px; padding:6px}
}
.accordionBtn .t{font-weight:900}
.accordionBtn .m{margin-left:auto; color:var(--muted); font-weight:900; font-size:12px}
.accordionPanel{
  max-height:0; overflow:hidden; transition:max-height .22s ease;
  background:#fff;
}
.accordionPanel .inner{padding:0 18px 16px}
.list{margin:0; padding-left:18px; color:var(--muted); line-height:1.7}
.list li{margin:8px 0}
.tagRow{display:flex; gap:8px; flex-wrap:wrap; margin-top:12px}
.tag{
  padding:7px 10px; border-radius:999px; border:1px solid var(--line);
  background:var(--surface); color:var(--muted); font-weight:800; font-size:12px;
}

.mediaCard{
  position:relative; border-radius:var(--radius); overflow:hidden;
  border:1px solid var(--line); box-shadow:var(--shadow2);
  background:#000;
}
.mediaCard video{width:100%; height:240px; object-fit:cover; display:block; opacity:.9}
.mediaCard .cap{
  position:absolute; left:0; right:0; bottom:0;
  padding:14px 14px 12px;
  background:linear-gradient(180deg, transparent, rgba(0,0,0,.66));
  color:#fff;
}
.mediaCard .cap strong{display:block; font-size:14px}
.mediaCard .cap span{display:block; opacity:.9; font-size:12px; margin-top:3px}

.grid2{display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-top:22px}
.grid3{display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-top:22px}

/* Catálogo de medicamentos */
.searchRow{display:flex; gap:12px; align-items:center; flex-wrap:wrap; padding:8px 0 14px}
.searchRow input{
  flex:1; min-width:240px;
  padding:12px 14px;
  border:1px solid var(--line);
  border-radius:14px;
  background:#fff;
  font-weight:900;
  outline:none;
}
.searchRow input:focus{
  border-color:rgba(25,167,165,.65);
  box-shadow:0 0 0 4px rgba(25,167,165,.12);
}
.chip{
  display:inline-flex; align-items:center;
  padding:8px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--muted);
  font-weight:900;
  font-size:12px;
}
.medGrid{display:grid; grid-template-columns:repeat(4,1fr); gap:14px; margin-top:6px}
.medCard{
  border:1px solid var(--line);
  border-radius:18px;
  overflow:hidden;
  background:#fff;
  box-shadow:var(--shadow2);
  transition:transform .15s ease;
}
.medCard:hover{transform:translateY(-1px)}
.medCard img{width:100%; height:150px; object-fit:cover; display:block}
.medCard .body{padding:12px}
.medCard .name{font-weight:1000; font-size:13px; line-height:1.25}
.medCard .pres{color:var(--muted); font-size:12px; margin-top:6px; line-height:1.4}
.medCard .actions{display:flex; gap:10px; margin-top:10px}
.medCard .actions a{
  flex:1; text-align:center;
  padding:9px 10px;
  border-radius:12px;
  border:1px solid var(--line);
  font-weight:900;
  font-size:12px;
  background:var(--surface);
  color:var(--text);
}
.medCard .actions a.primary{background:var(--primary); color:#fff; border-color:transparent}

/* Vista rápida tipo carrusel (muestra 5 y permite deslizar) */
.medPreview{display:flex; flex-direction:column; gap:10px}
.medCarouselWrap{position:relative}
.medCarousel{
  display:flex;
  gap:14px;
  overflow-x:auto;
  padding:6px 44px 10px;
  scroll-snap-type:x mandatory;
  -webkit-overflow-scrolling:touch;
  scroll-behavior:smooth;
  scrollbar-width:none;
}
.medCarousel::-webkit-scrollbar{display:none}
.medCarousel .medCard{
  min-width:220px;
  max-width:220px;
  flex:0 0 auto;
  scroll-snap-align:start;
}
.carBtn{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:34px; height:34px;
  border-radius:999px;
  border:1px solid var(--line);
  background:#fff;
  box-shadow:var(--shadow2);
  font-weight:1000;
  font-size:22px;
  line-height:1;
  display:flex; align-items:center; justify-content:center;
  cursor:pointer;
}
.carBtn.prev{left:8px}
.carBtn.next{right:8px}
.carBtn:active{transform:translateY(-50%) scale(.98)}
.medMoreRow{display:flex; justify-content:center; padding-top:6px}

@media (max-width:640px){
  .medCarousel{padding:6px 10px 10px}
  .carBtn{display:none}
  .medCarousel .medCard{min-width:240px; max-width:240px}
}


.ctaBox{
  border:1px solid var(--line); border-radius:24px; overflow:hidden;
  background:linear-gradient(135deg, rgba(25,167,165,.10), rgba(11,75,122,.10));
  box-shadow:var(--shadow2);
  margin-top:26px;
}
.ctaBox .inner{
  padding:22px;
  display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap;
}
.ctaBox .inner strong{font-size:16px}
.ctaBox .inner p{margin:6px 0 0; color:var(--muted); line-height:1.6; max-width:62ch}

.footer{
  padding:26px 0; border-top:1px solid var(--line);
  color:var(--muted);
}
.footerRow{display:flex; justify-content:space-between; gap:12px; flex-wrap:wrap}
.small{font-size:13px}

.whats{
  position:fixed; right:18px; bottom:18px; z-index:60;
  display:flex; flex-direction:column; gap:10px; align-items:flex-end;
}
.whats .fab{
  display:flex; align-items:center; gap:10px;
  padding:12px 14px; border-radius:999px; background:#1bb954; color:#fff;
  font-weight:900; box-shadow:var(--shadow);
}
.whats .fab:hover{transform:translateY(-1px)}
.whats .hint{
  background:#fff; border:1px solid var(--line); border-radius:14px;
  padding:10px 12px; color:var(--muted); font-size:12px; box-shadow:var(--shadow2);
  max-width:240px;
}

.reveal{opacity:0; transform:translateY(16px); transition:opacity .6s ease, transform .6s ease}
.reveal.on{opacity:1; transform:translateY(0)}

@media (max-width: 1100px){
  .medGrid{grid-template-columns:repeat(3,1fr)}
}

@media (max-width: 980px){
  .medGrid{grid-template-columns:repeat(2,1fr)}

  .heroGrid{grid-template-columns:1fr; padding:34px 0 56px}
  .heroCard video{height:360px}
  .featureGrid{grid-template-columns:1fr}
  .split{grid-template-columns:1fr}
  .grid2{grid-template-columns:1fr}
  .grid3{grid-template-columns:1fr}
  .nav{display:none}
  .menuBtn{display:inline-flex; align-items:center; justify-content:center; width:42px; height:42px;
    border:1px solid var(--line); border-radius:12px; background:#fff; cursor:pointer}
  .mobileNav{
    display:none; border-top:1px solid var(--line);
    padding:10px 0 14px;
  }
  .mobileNav a{
    display:block; padding:12px 10px; border-radius:12px;
    color:var(--muted); font-weight:900;
  }
  .mobileNav a:hover{background:var(--surface); color:var(--text)}
}
@media (max-width: 560px){
  .medGrid{grid-template-columns:1fr}
}



/* Map embed */
.mapEmbed{width:100%;}
.mapEmbed iframe{
  width:100%;
  height:440px;
  border:0;
  border-radius:16px;
}
@media (max-width: 720px){
  .mapEmbed iframe{height:340px;}
}

/* Make the map CTA fill the card (no empty right column) */
.ctaBox.mapBox .inner{
  flex-direction:column;
  align-items:stretch;
}
.ctaBox.mapBox .inner p{max-width:none;}
.ctaBox.mapBox .btn{align-self:flex-end; margin-top:12px;}


/* ===== Hero (video grande) ===== */
.hero.heroVideo{
  background:#0f2a43;
}
.heroMedia{
  position:absolute;
  inset:0;
  z-index:0;
  overflow:hidden;
}
.heroMedia video{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  opacity:.62;
}
.heroMedia .overlay{
  position:absolute;
  inset:0;
  background:linear-gradient(180deg, rgba(15,42,67,.28), rgba(15,42,67,.86));
}
.heroMedia .heroSlides{
  position:absolute;
  inset:0;
  mix-blend-mode:screen;
  opacity:.55;
  pointer-events:none;
}
.heroMedia .heroSlides img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  opacity:0;
  transition:opacity 1.1s ease;
}
.heroMedia .heroSlides img.active{opacity:1}
.heroMedia .heroMini{
  position:absolute;
  left:18px;
  right:18px;
  bottom:18px;
  z-index:2;
}

.heroOverlay{
  position:relative;
  z-index:1;
  padding:52px 0 70px;
  max-width:820px;
}
.heroVideo .heroTitle{color:#fff}
.heroVideo .heroSubtitle{color:rgba(255,255,255,.82)}
.heroVideo .heroBadge{background:rgba(255,255,255,.94)}
.heroVideo .featureGrid .card{background:rgba(255,255,255,.92)}

@media (max-width: 980px){
  .heroOverlay{padding:34px 0 56px}
}

/* ===== Sobre nosotros ===== */
.aboutGrid{
  display:grid;
  grid-template-columns: .95fr 1.05fr;
  gap:22px;
  align-items:stretch;
  margin-top:18px;
}
.aboutPhotoWrap{
  border-radius:24px;
  overflow:hidden;
  border:1px solid var(--line);
  box-shadow:var(--shadow);
  background:#fff;
}
.aboutPhoto{
  width:100%;
  height:100%;
  min-height:440px;
  object-fit:cover;
  display:block;
}
.aboutCard{
  border:1px solid var(--line);
  border-radius:24px;
  background:#fff;
  box-shadow:var(--shadow2);
  padding:22px;
}
.aboutCard p{
  margin:0 0 12px;
  color:var(--muted);
  line-height:1.75;
}
.aboutCard p:last-child{margin-bottom:0}

@media (max-width: 980px){
  .aboutGrid{grid-template-columns:1fr}
  .aboutPhoto{min-height:340px}
}
