/* === GLOBAL BASE STYLES (FORCED) === */

/* Contact hero: subtle grain without external image (avoids 404 from CSS-relative URLs) */
.contact-hero-noise {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  mix-blend-mode: overlay;
  background-image:
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 8px 8px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

main {
  max-width: 1600px;
  margin-inline: auto;
  width: 100%;
}

.container {
  margin-inline: auto;
}

body {
  overflow-x: hidden;
}

section {
  width: 100%;
}

.utility-shell {
  width: min(980px, calc(100% - 24px));
  margin: 0 auto;
  padding: 28px 0 56px;
}

.utility-page--with-header .utility-shell {
  padding-top: calc(
    28px +
    var(
      --utility-chrome-offset,
      calc(var(--spacing-6, 48px) + var(--spacing-4, 32px))
    )
  );
}

@media (max-width: 720px) {
  .utility-shell {
    width: min(100% - 16px, 980px);
    padding-top: 16px;
    padding-bottom: 36px;
  }

  .utility-page--with-header .utility-shell {
    padding-top: calc(
      16px +
      var(
        --utility-chrome-offset-mobile,
        calc(var(--spacing-4, 32px) + var(--spacing-3, 24px))
      )
    );
  }
}

/* --- SVG icons (local sprite) --- */
.icon {
  width: 1.25rem;
  height: 1.25rem;
  display: inline-block;
  vertical-align: middle;
  flex: 0 0 auto;
}

/* g2 palette ssot start */
:root {
  --g2-palette-dark: #0f172a;
  --g2-palette-light: #f5efe5;
  --g2-palette-accent: #1d6b62;
  --g2-palette-text: #172033;
  --g2-color-primary: var(--g2-palette-accent);
  --g2-color-accent: var(--g2-palette-accent);
  --g2-color-text: var(--g2-palette-text);
}
/* g2 palette ssot end */

/* --- Nav: current page (class activ_link set manually in HTML) --- */
.site-header__link.activ_link {
  color: #1d6b62;
  box-shadow: 0 2px 0 0 #1d6b62;
}

.site-header__link.activ_link:hover {
  color: #155e4e;
}

/* Header brand: fit ~360px (logo + long name + burger) */
@media (max-width: 520px) {
  .site-header__container {
    padding-left: max(12px, env(safe-area-inset-left, 0px));
    padding-right: max(12px, env(safe-area-inset-right, 0px));
  }

  .site-header__asymmetric {
    gap: 10px;
  }

  .site-header__brand {
    flex: 1 1 0;
    min-width: 0;
    flex-shrink: 1;
    font-size: clamp(0.75rem, 3.6vw, 1rem);
    gap: 6px;
    line-height: 1.15;
  }

  .site-header__brand svg {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
  }

  .site-header__brand-text {
    min-width: 0;
    flex: 1 1 auto;
  }

  .site-header__right {
    flex-shrink: 0;
    gap: 8px;
  }

  .site-header__burger {
    padding: 6px;
  }
}

/* Franja legal superior: solo escritorio (en móvil/tablet el aviso sigue en hero y pie) */
@media (max-width: 1023px) {
  .site-header__disclaimer {
    display: none;
  }
}

/* Footer: fila legal con varios enlaces — salto de línea en móvil/tablet */
.site-footer__legal-inner {
  min-width: 0;
}

.site-footer__legal-links {
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
  max-width: 100%;
}

.site-footer__legal-links .site-footer__link {
  white-space: nowrap;
}

@media (min-width: 768px) {
  .site-footer__legal-links {
    flex: 1 1 0;
    min-width: 0;
    justify-content: flex-end;
  }
}

.site-mobile-nav__link.activ_link {
  color: #34d399;
  padding-left: 8px;
  border-left-width: 2px;
  border-left-style: solid;
  border-left-color: #34d399;
}

.site-mobile-nav__link.activ_link:hover {
  color: #6ee7b7;
  border-left-color: #6ee7b7;
}

/* --- Cookie consent banner (site.js) --- */
.cookie-consent {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 10050;
  box-sizing: border-box;
  width: 100%;
  max-height: min(55vh, 100%);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 14px clamp(12px, 4vw, 20px) max(16px, env(safe-area-inset-bottom, 0px));
  padding-top: 14px;
  background: rgba(15, 23, 42, 0.97);
  color: #e2e8f0;
  border-top: 3px solid #10b981;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.28);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: clamp(0.8125rem, 2.8vw, 0.9375rem);
  line-height: 1.55;
  transform: translateY(110%);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.cookie-consent.cookie-consent--visible {
  transform: translateY(0);
  opacity: 1;
}

.cookie-consent__inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: clamp(12px, 3vw, 20px);
}

.cookie-consent__text {
  flex: 1 1 240px;
  min-width: 0;
}

.cookie-consent__title {
  font-weight: 700;
  font-size: clamp(0.9375rem, 3vw, 1.0625rem);
  color: #fff;
  margin-bottom: 6px;
}

.cookie-consent__desc {
  color: #cbd5e1;
  margin: 0;
  hyphens: auto;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.cookie-consent__inline-link {
  color: #6ee7b7;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-consent__inline-link:hover {
  color: #a7f3d0;
}

.cookie-consent__actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: flex-end;
  gap: 10px;
  flex: 0 1 auto;
  min-width: 0;
}

.cookie-consent__link {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid rgba(148, 163, 184, 0.55);
  color: #e2e8f0;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  text-align: center;
  line-height: 1.25;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.cookie-consent__link:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #94a3b8;
  color: #fff;
}

.cookie-consent__accept {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.875rem;
  line-height: 1.25;
  text-align: center;
  background: #059669;
  color: #fff;
  transition: background 0.2s ease, transform 0.15s ease;
}

.cookie-consent__accept:hover {
  background: #10b981;
}

.cookie-consent__accept:active {
  transform: scale(0.98);
}

/* Narrow screens: stack text + full-width actions */
@media (max-width: 640px) {
  .cookie-consent__inner {
    flex-direction: column;
    align-items: stretch;
  }

  .cookie-consent__text {
    flex: 1 1 auto;
  }

  .cookie-consent__actions {
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    justify-content: stretch;
  }

  .cookie-consent__link,
  .cookie-consent__accept {
    width: 100%;
    flex: 0 0 auto;
  }
}

/* Medium: stack + full-width controls */
@media (min-width: 641px) and (max-width: 900px) {
  .cookie-consent__inner {
    flex-direction: column;
    align-items: stretch;
  }

  .cookie-consent__actions {
    flex-direction: column;
    width: 100%;
    justify-content: stretch;
  }

  .cookie-consent__link,
  .cookie-consent__accept {
    width: 100%;
  }
}

/* Wide: one row, vertically centered */
@media (min-width: 901px) {
  .cookie-consent__inner {
    align-items: center;
  }

  .cookie-consent__actions {
    flex-wrap: nowrap;
    justify-content: flex-end;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-consent {
    transition: none;
  }
}

/* --- Age gate modal (site.js, main pages only) --- */
html.age-gate-open,
html.age-gate-open body {
  overflow: hidden;
}

.age-gate {
  position: fixed;
  inset: 0;
  z-index: 10100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top, 0px)) max(14px, env(safe-area-inset-right, 0px))
    max(16px, env(safe-area-inset-bottom, 0px)) max(14px, env(safe-area-inset-left, 0px));
  box-sizing: border-box;
  opacity: 0;
  transition: opacity 0.28s ease;
  pointer-events: none;
}

.age-gate.age-gate--visible {
  opacity: 1;
  pointer-events: auto;
}

.age-gate__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(4px);
}

.age-gate__panel {
  position: relative;
  width: min(100%, 520px);
  max-height: min(88vh, 100%);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
  padding: clamp(20px, 4vw, 28px);
  border-radius: 10px;
  background: #0f172a;
  color: #e2e8f0;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.age-gate__title {
  font-size: clamp(1.1rem, 4vw, 1.35rem);
  font-weight: 800;
  color: #fff;
  margin: 0 0 14px;
  line-height: 1.25;
}

.age-gate__text {
  margin: 0 0 22px;
  font-size: clamp(0.9rem, 3.2vw, 1rem);
  line-height: 1.6;
  color: #cbd5e1;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.age-gate__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.age-gate__btn {
  box-sizing: border-box;
  width: 100%;
  min-height: 48px;
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  border: none;
  text-align: center;
  transition: background 0.2s ease, transform 0.12s ease, border-color 0.2s ease;
}

.age-gate__btn:active {
  transform: scale(0.99);
}

.age-gate__btn--yes {
  background: #059669;
  color: #fff;
}

.age-gate__btn--yes:hover {
  background: #10b981;
}

.age-gate__btn--no {
  background: transparent;
  color: #e2e8f0;
  border: 2px solid rgba(148, 163, 184, 0.55);
}

.age-gate__btn--no:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: #94a3b8;
}

@media (min-width: 480px) {
  .age-gate__actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .age-gate__btn {
    flex: 1 1 calc(50% - 6px);
    min-width: 140px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .age-gate {
    transition: none;
  }
}
