/* Manual de Normas de Identidad Visual UCCuyo 1.0 (2017)
   Dominante verde #064A31 · Subordinado bordeaux #7D1B1C · Acento oro #E38A00
   Tipografías: Droid Serif + Montserrat */
:root {
  --verde: #064A31;
  --verde-oscuro: #042F23;
  --verde-banda: #043824;
  --bordeaux: #7D1B1C;
  --bordeaux-hi: #9a2a2c;
  --bordeaux-lo: #5a1213;
  --bordeaux-edge: #3e0c0d;
  --oro: #E38A00;
  --oro-suave: #f4c56a;
  --crema: #f7f1e8;
  --papel: #fffdf8;
  --tinta: #1c2b26;
  --muted: #5c564f;
  --linea: #e4d9c8;
  --sidebar: 280px;
  --header: 72px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  color: var(--tinta);
  background: var(--crema);
  font-family: Montserrat, "Segoe UI", sans-serif;
  line-height: 1.5;
}
main.wrap { overflow-x: hidden; }
button, a.btn-3d, .burger, .filter, .rank-more {
  touch-action: manipulation;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font-family: inherit; }

.skip {
  position: absolute;
  left: -999px;
  top: 0;
}
.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 80;
  background: #fff;
  padding: 8px 12px;
}

/* ——— Header 2026: 5 pilares + CTAs ——— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--verde-oscuro);
  color: #fff;
  border-bottom: 3px solid var(--oro);
}
.header-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 20px;
  max-width: 1280px;
  margin: 0 auto;
}
.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
  flex-shrink: 0;
}
.brand-link img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  background: #fff;
  border-radius: 8px;
  padding: 3px;
}
.brand-link small {
  display: block;
  font-size: 9px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--oro-suave);
  font-weight: 700;
}
.brand-link strong {
  display: block;
  font-size: 15px;
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  line-height: 1.1;
}
.nav-panel { flex: 1; min-width: 0; }
.nav-panel-head { display: none; }
.menu-root {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.menu-root > li { position: relative; }
.menu-root > li > a,
.menu-root > li > button {
  display: block;
  background: none;
  border: 0;
  color: #e8efe9;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}
.menu-root > li > button::after {
  content: " ▾";
  font-size: 10px;
  color: var(--oro-suave);
}
.menu-root > li > a:hover,
.menu-root > li > button:hover,
.menu-root > li.active > a,
.menu-root > li.active > button,
.menu-root > li.open > button {
  background: rgba(227, 138, 0, .18);
  color: #fff;
}
.has-sub > ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  margin: 0;
  padding: 8px;
  list-style: none;
  background: #04271d;
  border: 1px solid rgba(227, 138, 0, .35);
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(0,0,0,.28);
  z-index: 60;
}
.has-sub:hover > ul,
.has-sub:focus-within > ul,
.has-sub.open > ul { display: block; }
.has-sub > ul a {
  display: block;
  color: #e8efe9;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 7px;
}
.has-sub > ul a:hover,
.has-sub > ul a.active { background: rgba(227, 138, 0, .18); color: #fff; }
.header-cta {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
  margin-left: auto;
}
.header-cta .btn-3d {
  font-size: 12px;
  padding: 0.5rem 0.9rem;
}
.drawer-cta { display: none; }
.app-actions { display: none; }
.lang-switcher.top {
  display: flex;
  flex-direction: row;
  gap: 6px;
  padding: 0;
  flex-shrink: 0;
}
.lang-switcher.top .btn-3d.lang {
  min-width: 74px;
  font-size: 12px;
  font-weight: 800;
  padding: 0.48rem 0.7rem;
  gap: 7px;
}
.flag {
  display: inline-block;
  width: 22px;
  height: 15px;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(0,0,0,.22);
  flex-shrink: 0;
}
.flag-ar {
  background: linear-gradient(to bottom, #74acdf 0 33%, #fff 33% 67%, #74acdf 67% 100%);
  position: relative;
}
.flag-ar::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 5px;
  height: 5px;
  margin: -2.5px 0 0 -2.5px;
  background: #f6b40e;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(246, 180, 14, .35);
}
.flag-gb {
  background: #012169 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 30'%3E%3Cpath fill='%23012169' d='M0 0h60v30H0z'/%3E%3Cpath stroke='%23fff' stroke-width='6' d='M0 0l60 30M60 0L0 30'/%3E%3Cpath stroke='%23C8102E' stroke-width='4' d='M0 0l60 30M60 0L0 30'/%3E%3Cpath stroke='%23fff' stroke-width='10' d='M30 0v30M0 15h60'/%3E%3Cpath stroke='%23C8102E' stroke-width='6' d='M30 0v30M0 15h60'/%3E%3C/svg%3E") center / cover no-repeat;
}
.burger { display: none; }
.nav-overlay { display: none; }
.wrap { min-height: 100vh; }
.hero-logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  background: #fff;
  border-radius: 12px;
  padding: 6px;
  margin-bottom: 16px;
}
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.team-card {
  background: var(--papel);
  border: 1px solid var(--linea);
  border-top: 4px solid var(--bordeaux);
  border-radius: 12px;
  padding: 16px;
}
.team-card strong {
  display: block;
  color: var(--verde);
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  font-size: 16px;
  margin-bottom: 4px;
}
.team-card span { display: block; color: var(--muted); font-size: 13px; }
.team-card:first-child {
  border-top-color: var(--oro);
}
.team-card:last-child {
  border-top-color: var(--verde);
}
.burger {
  display: none;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  background: var(--bordeaux);
  color: #fff;
  border: 0;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 13px;
  cursor: pointer;
}
.burger-ico { font-size: 18px; line-height: 1; }
.nav-close {
  display: none;
  margin-left: auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: var(--bordeaux);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}
.btn-3d.lang {
  opacity: 1;
}
.btn-3d.lang.is-active {
  outline: 2px solid var(--oro);
  outline-offset: 2px;
}

/* ——— 3D Bordeaux buttons (manual) ——— */
.btn-3d {
  --face: var(--bordeaux);
  --hi: var(--bordeaux-hi);
  --lo: var(--bordeaux-lo);
  --edge: var(--bordeaux-edge);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(180deg, var(--hi) 0%, var(--face) 46%, var(--lo) 100%);
  color: #fff !important;
  text-decoration: none;
  border: 0;
  border-radius: 10px;
  padding: 0.82rem 1.35rem;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .02em;
  cursor: pointer;
  box-shadow:
    0 1px 0 rgba(255,255,255,.28) inset,
    0 -3px 0 rgba(0,0,0,.28) inset,
    0 6px 0 var(--edge),
    0 12px 18px rgba(45, 10, 12, .28);
  transform: translateY(0);
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.btn-3d:hover {
  filter: brightness(1.07);
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,.3) inset,
    0 -3px 0 rgba(0,0,0,.28) inset,
    0 8px 0 var(--edge),
    0 16px 22px rgba(45, 10, 12, .32);
}
.btn-3d:active {
  transform: translateY(5px);
  filter: brightness(.96);
  box-shadow:
    0 1px 0 rgba(255,255,255,.2) inset,
    0 2px 0 var(--edge),
    0 6px 10px rgba(0,0,0,.22);
}
.btn-3d.gold {
  --face: #c77800;
  --hi: #f0a01a;
  --lo: #b36a00;
  --edge: #7a4700;
  color: #1c1408 !important;
}
.btn-3d.cream {
  --face: #f4ead8;
  --hi: #fffdf8;
  --lo: #e2d2b4;
  --edge: #7a6240;
  color: #064A31 !important;
}
.btn-3d.ghost {
  background: transparent;
  color: var(--verde) !important;
  box-shadow: 0 4px 0 var(--verde);
  border: 2px solid var(--verde);
}
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* ——— Layout ——— */
section.panel {
  padding: 48px 40px 64px;
  max-width: 1180px;
  margin: 0 auto;
}
.kicker {
  margin: 0 0 6px;
  color: var(--oro);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
h2.titulo {
  margin: 0 0 10px;
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  font-size: clamp(28px, 3vw, 38px);
  color: var(--verde);
  line-height: 1.15;
}
.lead { margin: 0 0 28px; color: var(--muted); max-width: 720px; font-size: 16px; }

.hero {
  position: relative;
  min-height: 92vh;
  color: #fff;
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  overflow: hidden;
  background: var(--verde-oscuro);
}
.hero-copy { padding: 64px 48px 72px; display: flex; flex-direction: column; justify-content: center; }
.hero-copy .uni { color: var(--oro-suave); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 16px; }
.hero-copy h2 {
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  font-size: clamp(36px, 4.4vw, 56px);
  line-height: 1.05;
  margin: 0 0 8px;
}
.hero-copy .sia { color: var(--oro); font-size: 22px; font-weight: 700; margin: 0 0 18px; }
.hero-copy p { color: #d5e6de; max-width: 540px; font-size: 17px; }
.hero-photo {
  position: relative;
  min-height: 420px;
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.hero-photo::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 10px;
  background: var(--oro);
  z-index: 2;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 28px; }
.chip {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(227,138,0,.45);
  color: #fff;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }

.card {
  background: var(--papel);
  border: 1px solid var(--linea);
  border-radius: 14px;
  padding: 18px 18px 16px;
  box-shadow: 0 1px 0 #fff inset;
}
.card h3 {
  margin: 0 0 8px;
  color: var(--verde);
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  font-size: 20px;
}
.card h3.book-title {
  margin-top: 48px;
  font-size: 18px;
}
.card p, .card li { color: var(--muted); font-size: 14px; }
.card ul { margin: 8px 0 0; padding-left: 18px; }
.goldbar { border-top: 4px solid var(--oro); }

.stat {
  background: var(--verde);
  color: #fff;
  border-radius: 14px;
  padding: 22px 16px;
  text-align: center;
}
.stat b {
  display: block;
  font-size: 38px;
  color: var(--oro);
  font-family: "Droid Serif", "Libre Baskerville", Georgia, serif;
  line-height: 1;
}
.stat span { display: block; margin-top: 8px; font-size: 13px; font-weight: 600; }
.visit-stats { margin-bottom: 18px; }
.stat.counter b { font-size: 48px; letter-spacing: .04em; }

.scope-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 22px 0 14px;
}
.scope-tab {
  border: 1px solid var(--linea);
  background: #fff;
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 800;
  font-size: 13px;
  cursor: pointer;
  color: var(--verde);
}
.scope-tab.on {
  background: var(--verde);
  color: var(--oro);
  border-color: var(--verde);
}
.scope-board { display: none; }
.scope-board.on { display: block; }
.scope-board .lead { margin-top: 4px; }

.level {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: start;
}
.badge {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--verde);
  color: var(--oro);
  display: grid; place-items: center;
  font-weight: 800;
  font-size: 18px;
}

.gallery {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  grid-template-rows: 180px 180px;
  gap: 10px;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; }
.gallery img:first-child { grid-row: 1 / span 2; }

#map {
  height: 420px;
  border-radius: 14px;
  border: 1px solid var(--linea);
  overflow: hidden;
}
.rank-panels { display: grid; gap: 16px; }
.rank-block {
  background: var(--papel);
  border: 1px solid var(--linea);
  border-radius: 14px;
  overflow: hidden;
}
.rank-block > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0;
  padding: 12px 14px;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-weight: 800;
  color: var(--verde);
  background: #fff8ee;
  border-bottom: 1px solid var(--linea);
}
.rank-block > summary::-webkit-details-marker { display: none; }
.rank-block > summary::after {
  content: "▾";
  color: var(--oro);
  font-size: 14px;
  transition: transform .15s ease;
}
.rank-block:not([open]) > summary::after { transform: rotate(-90deg); }
.rank-block:not([open]) > summary { border-bottom: 0; }
.rank-count {
  margin-left: auto;
  margin-right: 8px;
  letter-spacing: 0;
  text-transform: none;
  font-size: 12px;
  color: var(--muted);
}
.origin-list { list-style: none; margin: 0; padding: 0; }
.origin-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid var(--linea);
  cursor: pointer;
  background: var(--papel);
}
.origin-list li:last-child { border-bottom: 0; }
.origin-list li:hover, .origin-list li.on { background: #fff4e0; }
.origin-list li.origin-group {
  background: #eef4f0;
  padding-top: 10px;
  padding-bottom: 10px;
}
.origin-list li.origin-group strong {
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--verde);
}
.origin-list li.origin-group:hover,
.origin-list li.origin-group.on { background: #e4eee8; }
.origin-list li.origin-child { padding-left: 26px; }
.origin-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
}
.origin-copy strong {
  display: block;
  line-height: 1.25;
}
.origin-list .sub {
  display: block;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}
.origin-list li.empty:hover { background: var(--papel); }
.origin-list .empty {
  cursor: default;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}
.rank-more {
  display: block;
  width: calc(100% - 16px);
  margin: 8px 8px 10px;
  border: 1px solid var(--linea);
  background: #fff;
  color: var(--verde);
  border-radius: 999px;
  padding: 7px 12px;
  font-weight: 800;
  font-size: 12px;
  cursor: pointer;
}
.rank-more:hover { background: #fff4e0; border-color: var(--oro); }
.rank-more[hidden] { display: none !important; }
.book-title {
  margin: 48px 0 8px;
  font-size: 16px;
  clear: both;
}

form.visit {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr 1fr;
  padding-bottom: 12px;
}
form.visit .full { grid-column: 1 / -1; }
form.visit .btn-row {
  padding-bottom: 36px;
  margin-bottom: 8px;
  align-items: flex-start;
}
label { font-size: 12px; font-weight: 700; color: var(--verde); display: grid; gap: 4px; }
input, select, textarea {
  border: 1px solid #d9cbb6;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: var(--tinta);
  font-size: 14px;
}
.book {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}
.note {
  background: #fff;
  border-left: 4px solid var(--bordeaux);
  padding: 12px 14px;
  border-radius: 0 10px 10px 0;
}
.note strong { color: var(--verde); }
.note small { color: var(--muted); }

.banner-you {
  background: var(--verde);
  color: #fff;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 16px;
  display: none;
}
.banner-you.show { display: block; }
.geo-note {
  margin: 12px 0 0;
  font-size: 13px;
}
.note.empty {
  border-left-color: var(--oro);
  color: var(--muted);
  font-weight: 600;
}

footer.site {
  background: var(--verde-oscuro);
  color: #d5e6de;
  padding: 36px 40px 28px;
  border-top: 4px solid var(--oro);
}
footer.site strong { color: #fff; }
footer.site a { color: var(--oro-suave); text-decoration: none; }
footer.site a:hover { color: #fff; }
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
  max-width: 1180px;
}
.foot-grid .kicker { color: var(--oro); margin-bottom: 10px; }
.foot-grid a, .foot-grid p { display: block; font-size: 13px; font-weight: 600; margin: 0 0 8px; }
.foot-note {
  max-width: 1180px;
  margin: 28px 0 0;
  font-size: 12px;
  color: #9bb0a6;
}

.filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 14px; }
.filter {
  border: 1px solid var(--linea);
  background: #fff;
  border-radius: 999px;
  padding: 6px 12px;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  color: var(--verde);
}
.filter.on { background: var(--bordeaux); color: #fff; border-color: var(--bordeaux); }

@media (max-width: 1100px) {
  .header-cta { display: none; }
  .lang-switcher.top { margin-left: auto; }
  .drawer-cta { display: grid; gap: 8px; padding: 12px; }
  .burger { display: inline-flex; }
  .nav-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 14px 10px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    font-size: 12px;
    color: var(--oro-suave);
  }
  .nav-close { display: grid; place-items: center; }
  .nav-panel {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(320px, 88vw);
    height: 100dvh;
    max-height: 100dvh;
    background: var(--verde-oscuro);
    border-right: 4px solid var(--oro);
    transform: translateX(-110%);
    transition: transform .2s ease, visibility .2s ease;
    z-index: 90;
    overflow: auto;
    display: flex;
    flex-direction: column;
    box-shadow: 8px 0 24px rgba(0,0,0,.28);
    flex: none;
    visibility: hidden;
    pointer-events: none;
    padding-bottom: env(safe-area-inset-bottom, 12px);
    -webkit-overflow-scrolling: touch;
  }
  body.nav-open .site-header { z-index: 80; }
  .site-header.nav-open .nav-panel,
  body.nav-open .nav-panel,
  body > .nav-panel.nav-panel {
    z-index: 90;
  }
  .site-header.nav-open .nav-panel,
  body.nav-open .nav-panel {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
  }
  .menu-root {
    flex-direction: column;
    align-items: stretch;
    padding: 8px 10px 16px;
  }
  .menu-root > li > a,
  .menu-root > li > button {
    width: 100%;
    text-align: left;
  }
  .has-sub > ul {
    position: static;
    display: none;
    min-width: 0;
    margin: 4px 0 8px 10px;
    border: 0;
    box-shadow: none;
    background: rgba(0,0,0,.18);
  }
  .has-sub:hover > ul,
  .has-sub:focus-within > ul { display: none; }
  .has-sub.open > ul { display: block !important; }
  .app-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    margin-top: auto;
  }
  .app-actions .btn-3d { width: 100%; font-size: 12px; padding: 0.62rem 0.7rem; }
  .app-hint { margin: 0; font-size: 11px; line-height: 1.35; color: #b7c9c0; font-weight: 600; }
  .nav-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(4, 23, 17, .55);
    z-index: 40;
  }
  .nav-overlay[hidden] { display: none; }
  body.nav-open { overflow: hidden; }
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-photo { min-height: 240px; }
  .hero-copy { padding: 32px 22px 40px; }
  section.panel { padding: 32px 18px 48px; }
  .grid-2, .grid-3, .grid-4, form.visit { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 18px; }
  footer.site { padding: 28px 18px; }
  .gallery { grid-template-columns: 1fr 1fr; grid-template-rows: 160px 160px 160px; }
  .gallery img:first-child { grid-row: auto; grid-column: 1 / -1; height: 200px; }
  .site-header { padding-top: env(safe-area-inset-top, 0px); }
  .header-bar { gap: 8px; padding: 8px 12px; }
  .brand-link small { display: none; }
  .lang-switcher.top .btn-3d.lang {
    min-width: 0;
    padding: 0.4rem 0.5rem;
    font-size: 11px;
  }
  .drawer-cta .btn-3d,
  .app-actions .btn-3d { width: 100%; }
  .menu-root > li > a,
  .menu-root > li > button { min-height: 44px; }
  .hero .btn-row {
    flex-direction: column;
    align-items: stretch;
  }
  .hero .btn-3d { width: 100%; justify-content: center; }
  form.visit .btn-row {
    flex-direction: column;
    align-items: stretch;
  }
  form.visit .btn-row .btn-3d { width: 100%; justify-content: center; }
  #map { height: 260px; }
  input, select, textarea { font-size: 16px; }
  section.panel, .hero {
    scroll-margin-top: calc(var(--header) + env(safe-area-inset-top, 0px));
  }
}

@media (max-width: 640px) {
  .burger-label { display: none; }
  .burger { min-width: 44px; padding: 0 10px; justify-content: center; }
  .brand-link img { width: 36px; height: 36px; }
  .brand-link strong { font-size: 14px; }
  .hero-copy { padding: 24px 16px 32px; }
  .hero-copy p { font-size: 16px; }
  section.panel { padding: 28px 14px 40px; }
  .foot-grid { grid-template-columns: 1fr; }
  footer.site {
    padding: 24px 14px calc(20px + env(safe-area-inset-bottom, 0px));
  }
  .gallery { grid-template-columns: 1fr; grid-template-rows: none; }
  .gallery img, .gallery img:first-child {
    grid-column: auto;
    height: 180px;
  }
  .team-grid { grid-template-columns: 1fr; }
  .stat b { font-size: 28px; }
}

@media (display-mode: standalone) {
  .app-hint { display: none; }
}
