/* Definiciones para Material Design 3  */
@import url(../material-tokens/css/baseline.css);
/* Fonts utilizados */
@import url(../lib/css/roboto.css);
@import url(../lib/css/material-symbols-outlined.css);

html {
  /* Indica los temas del sistema operativo que son soportados. */
  color-scheme: light dark;
  --tabWidth: 3.75rem;
  --anchoNav: 22.5rem;
}

main {
  margin-left: auto;
  margin-right: auto;
}

/* Quita un borde rojo que coloca Firefox. */
:-moz-ui-invalid {
  box-shadow: none;
}

body {
  margin: 0;
  font-family: var(--md-sys-typescale-body-large-font);
  /* font-family: "Anton", sans-serif; */
  font-weight: var(--md-sys-typescale-body-large-weight);
  font-size: var(--md-sys-typescale-body-large-size);
  font-style: var(--md-sys-typescale-body-large-font-style);
  letter-spacing: var(--md-sys-typescale-body-large-tracking);
  line-height: var(--md-sys-typescale-body-large-line-height);
  text-transform: var(--md-sys-typescale-body-large-text-transform);
  text-decoration: var(--md-sys-typescale-body-large-text-decoration);
  color: var(--md-sys-color-on-background);
  background-color: var(--md-sys-color-background);
  /* Las siguientes líneas Evita los cambios de apariencia al cargar estilos y
 + custom elements, que son conocidos como Flash Of Unstyled Content (fouc). */
  opacity: 0;
  animation-name: fouc;
  animation-fill-mode: forwards;
  animation-duration: 1.5s;
}

@keyframes fouc {
  to {
    opacity: 1;
  }
}

html {
  --Font: -apple-system, BlinkMacSystemFont, roboto, sans-serif;
  --colIntIos: white;
  --colIntIosOnBk: #2acc2a;
  --colIntIosOnBkFc: #1bbb1b;
  --colIntIosOffBk: #dbdbdb;
  --colIntIosOffBkFc: #bdbdbd;
  /* Plain typeface */
  --md-ref-typeface-plain: var(--Font);
  /* Brand typeface */
  --md-ref-typeface-brand: var(--Font-Brand);
  --md-sys-typescale-label-large-weight-prominent: var(
    --md-ref-typeface-weight-bold
  );
  --md-box_shadow_level4: 0 var(--md-sys-elevation-level4)
    var(--md-sys-elevation-level4) var(--md-sys-color-shadow);
  --md-box_shadow_level3: 0 var(--md-sys-elevation-level3)
    var(--md-sys-elevation-level3) var(--md-sys-color-shadow);
  --md-box_shadow_level2: 0 var(--md-sys-elevation-level2)
    var(--md-sys-elevation-level2) var(--md-sys-color-shadow);
  --md-box_shadow_level1: 0 var(--md-sys-elevation-level1)
    var(--md-sys-elevation-level1) var(--md-sys-color-shadow);
  --md-box_shadow_level0: none;
  --iconSize: 1.5rem;
  --avatarSize: 2.5rem;
  --imageSize: 3.5rem;
  --videoWidth: 7.125rem;
  --videoHeight: 4rem;
  --scroll-headline-duracion: 2s;
  --md-sys-state-focus-indicator-outer-offset: 0.125rem;
  --md-sys-state-focus-indicator-thickness: 0.1875rem;
  /* Pressed state layer opacity */
  --state-pressed-transparency-percentage: 84%;
  /* Focus state layer opacity */
  --state-focus-transparency-percentage: 88%;
  /* Hover state layer opacity */
  --state-hover-transparency-percentage: 92%;
}

p {
  margin-top: 1rem;
  margin-bottom: 1rem;
}

a {
  color: var(--md-sys-color-on-background);
}

@media (prefers-color-scheme: light) {
  html {
    --md-riple-color: #00000020;
  }
}

@media (prefers-color-scheme: dark) {
  html {
    --md-riple-color: #ffffff40;
  }
}

@keyframes salePorLaIzquierda {
  to {
    translate: -100vw 0;
  }
}

@keyframes entraPorLaDerecha {
  from {
    translate: 100vw 0;
  }
}

@keyframes aparece {
  from {
    opacity: 0;
  }
}

@keyframes desvanece {
  to {
    opacity: 0;
  }
}

:root {
  --blue-main: #3000ff;
  --dark: #353230;
  --yellow: #fff100;
}

.hero {
  background: var(--yellow);
  padding: 64px 24px;
  color: var(--dark);
}

.hero h1 {
  font-size: 55px;
  max-width: 1100px;
  margin: 0 auto;
  line-height: 1.1;
  text-align: center;
}

.hero p {
  font-size: 16px;
  max-width: 600px;
  margin: 20px auto 0;
  opacity: 0.9;
}

/* ---------- CATÁLOGO ---------- */
.section {
  max-width: 1200px;
  margin: auto;
  padding: 56px 20px;
}

.section h2 {
  font-size: 32px;
  margin-bottom: 32px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}

.branch-card {
  background: var(--dark);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
  transition: 0.25s ease;
}

.branch-card:hover {
  transform: translateY(-6px);
}

.branch-card-inner {
  transition: transform 0.25s ease;
  will-change: transform;
}

.branch-card:hover .branch-card-inner {
  transform: translateY(-6px);
}

.branch-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.branch-body {
  padding: 20px;
}

.branch-body h3 {
  margin: 0;
  font-size: 22px;
  color: var(--yellow);
  letter-spacing: 0.6px;
}

.branch-body p {
  font-size: 14px;
  margin: 10px 0 18px;
  color: var(--yellow);
  font-weight: 600;
}

.btn {
  display: block;
  text-align: center;
  background: var(--yellow);
  color: #000;
  padding: 14px;
  border-radius: 10px;
  font-weight: 700;
  text-decoration: none;
}

/* Layout principal detalle */
.detail {
  max-width: 1200px;
  margin: auto;
  padding: 56px 20px 80px;
}

.detail-header {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
  align-items: flex-start;
}

/* ---------- SWIPER ---------- */
.swiper {
  width: 100%;
  height: 420px; /* desktop protagonista */
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.15);
}

.swiper-slide {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}

.swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* vuelve al look limpio */
}

/* ---------- INFO DERECHA ---------- */

.location-block {
  margin-bottom: 32px;
}

.map-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  border-radius: 14px;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  transition: 0.25s ease;
  color: var(--blue-main);
}

.map-link:hover {
  background: rgba(48, 0, 255, 0.15);
  transform: translateY(-2px);
}

.map-link:hover {
  text-decoration: none;
}

.detail-visual h1 {
  font-size: 42px;
  margin: 0 0 8px;
}

.detail .meta {
  font-size: 18px;
  color: #666;
  margin-bottom: 28px;
}

.info-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.info-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 16px;
  padding: 22px 16px;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.08);
  transition:
    box-shadow 0.25s ease,
    background 0.25s ease;
  color: #666;
  background-color: #fff;
}

.info-card:hover {
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  background: var(--yellow);
}

/* ---------- MODAL ---------- */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
}

body.modal-open {
  overflow: hidden;
}

.modal-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content img {
  max-width: 100%;
  max-height: 80vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 900px) {
  .detail-header {
    grid-template-columns: 1fr;
  }
  .swiper {
    height: 350px;
  }
  .info-actions {
    grid-template-columns: 1fr;
  }
  .detail-visual h1 {
    font-size: 27px;
    margin: 0 0 8px;
  }
  .hero {
    background: var(--yellow);
    padding: 24px 24px;
    color: var(--dark);
  }
  .hero h1 {
    font-size: 18px;
    max-width: 900px;
    margin: 0 auto;
    line-height: 1.1;
    text-align: center;
  }
}
