/* =================================================================
   Real Estate Lawyer Barcelona — Design System
   Paleta: Azul marino #0A192F · Dorado #C5A880 · Gris claro #F8F9FA
   Hand-written CSS · Mobile-first · Sin dependencias externas
   ================================================================= */

:root {
  /* Colores corporativos */
  --navy: #0A192F;
  --navy-700: #112240;
  --navy-600: #1B2D4A;
  --navy-500: #24385c;
  --gold: #C5A880;
  --gold-dark: #B0915F;
  --gold-soft: #e7dac5;
  --light: #F8F9FA;
  --white: #ffffff;
  --gray-100: #f1f3f6;
  --gray-200: #e3e7ec;
  --gray-300: #cbd2dc;
  --gray-500: #6b7785;
  --gray-700: #3a4655;
  --text: #1f2733;
  --text-muted: #5b6774;
  --success: #1f9d63;
  --error: #d64545;

  /* Tipografía */
  --font-head: "Georgia", "Times New Roman", serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  /* Layout */
  --container: 1200px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(10, 25, 47, 0.08);
  --shadow: 0 8px 30px rgba(10, 25, 47, 0.10);
  --shadow-lg: 0 20px 50px rgba(10, 25, 47, 0.18);
  --transition: 0.25s ease;
  --header-h: 76px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.65;
  font-size: 1.0625rem; /* 17px — en rem para permitir el escalado de accesibilidad */
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--gold-dark); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--navy); }
ul { list-style: none; }

/* ---------- Tipografía ---------- */
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--navy); line-height: 1.2; font-weight: 700; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); letter-spacing: -0.5px; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.5rem); }
h4 { font-size: 1.15rem; }
p { margin-bottom: 1rem; color: var(--text-muted); }
.lead { font-size: 1.2rem; color: var(--text-muted); }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section-sm { padding: 48px 0; }
.section--light { background: var(--light); }
.section--navy { background: var(--navy); }
.section--navy h1, .section--navy h2, .section--navy h3, .section--navy h4 { color: var(--white); }
.section--navy p { color: rgba(255,255,255,0.78); }
.text-center { text-align: center; }
.eyebrow {
  display: inline-block; font-family: var(--font-body); font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase; font-size: 0.78rem;
  color: var(--gold-dark); margin-bottom: 12px;
}
.section--navy .eyebrow { color: var(--gold); }
.section-head { max-width: 760px; margin: 0 auto 48px; }
.section-head.text-left { margin-left: 0; }
.divider { width: 64px; height: 3px; background: var(--gold); border: 0; margin: 18px 0; }
.text-center .divider { margin-left: auto; margin-right: auto; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-body); font-weight: 700; font-size: 1rem;
  padding: 14px 28px; border-radius: var(--radius-sm); cursor: pointer;
  border: 2px solid transparent; transition: all var(--transition); text-align: center;
  line-height: 1.2;
}
.btn-gold { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-dark); border-color: var(--gold-dark); color: var(--navy); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-navy { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-navy:hover { background: var(--navy-700); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.section--navy .btn-outline { color: var(--white); border-color: rgba(255,255,255,0.5); }
.section--navy .btn-outline:hover { background: var(--white); color: var(--navy); border-color: var(--white); }
.btn-ghost { background: transparent; color: var(--gold-dark); padding: 10px 0; }
.btn-block { width: 100%; }
.btn-lg { padding: 16px 36px; font-size: 1.05rem; }

/* ---------- Header / Navbar ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100; background: var(--navy);
  box-shadow: var(--shadow-sm); height: var(--header-h);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand__mark {
  width: 42px; height: 42px; border-radius: 9px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  display: grid; place-items: center; color: var(--navy);
  font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; flex-shrink: 0;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__name { color: var(--white); font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; }
.brand__tag { color: var(--gold); font-size: 0.68rem; letter-spacing: 1.5px; text-transform: uppercase; }

.nav__links { display: none; align-items: center; gap: 4px; }
.nav__item { position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: 5px; color: rgba(255,255,255,0.85);
  font-weight: 600; font-size: 0.95rem; padding: 10px 14px; border-radius: 6px;
  background: transparent; border: 0; cursor: pointer; font-family: var(--font-body);
}
.nav__link:hover, .nav__link[aria-expanded="true"] { color: var(--white); background: rgba(255,255,255,0.06); }
.nav__link .caret { width: 9px; height: 9px; transition: transform var(--transition); }
.nav__link[aria-expanded="true"] .caret { transform: rotate(180deg); }

.dropdown {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 320px;
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-lg);
  padding: 10px; opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: all var(--transition); border-top: 3px solid var(--gold);
}
.nav__item:hover .dropdown,
.dropdown.open { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown a {
  display: block; padding: 10px 14px; border-radius: 7px; color: var(--text);
  font-size: 0.92rem; font-weight: 600;
}
.dropdown a:hover { background: var(--light); color: var(--navy); }
.dropdown a span { display: block; font-weight: 400; font-size: 0.8rem; color: var(--gray-500); }

.nav__cta { display: none; }

/* Hamburguesa */
.nav__toggle {
  display: inline-flex; flex-direction: column; gap: 5px; background: transparent;
  border: 0; cursor: pointer; padding: 8px;
}
.nav__toggle span { width: 26px; height: 2px; background: var(--white); transition: var(--transition); border-radius: 2px; }
.nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle.open span:nth-child(2) { opacity: 0; }
.nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Menú móvil */
.mobile-menu {
  position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0;
  background: var(--navy); z-index: 99; transform: translateX(100%);
  transition: transform var(--transition); overflow-y: auto; padding: 20px;
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu a, .mobile-menu .m-group-title {
  display: block; color: rgba(255,255,255,0.9); padding: 13px 8px; font-weight: 600;
  border-bottom: 1px solid rgba(255,255,255,0.08); font-size: 1.05rem;
}
.mobile-menu .m-group-title { color: var(--gold); font-size: 0.8rem; letter-spacing: 1.5px; text-transform: uppercase; border: 0; padding-bottom: 4px; margin-top: 10px; }
.mobile-menu .m-sub a { padding-left: 18px; font-size: 0.98rem; font-weight: 500; color: rgba(255,255,255,0.78); }
.mobile-menu .btn { margin-top: 22px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; background-color: var(--navy);
  background-image:
    radial-gradient(900px 500px at 82% -10%, rgba(197,168,128,0.22), transparent 60%),
    linear-gradient(180deg, rgba(10,25,47,0.86) 0%, rgba(13,32,56,0.93) 100%),
    url("../img/hero-barcelona.jpg");
  background-size: cover, cover, cover;
  background-position: center, center, center 35%;
  background-repeat: no-repeat;
  color: var(--white); padding: 84px 0; overflow: hidden;
}
.page-hero {
  background-image:
    linear-gradient(180deg, rgba(10,25,47,0.88) 0%, rgba(13,32,56,0.94) 100%),
    url("../img/hero-barcelona.jpg");
  background-size: cover, cover;
  background-position: center, center 40%;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 56px 56px; mask-image: radial-gradient(circle at 75% 20%, black, transparent 70%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero h1 { color: var(--white); max-width: 16ch; }
.hero h1 .accent { color: var(--gold); }
.hero p { color: rgba(255,255,255,0.82); font-size: 1.2rem; max-width: 56ch; margin: 20px 0 32px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__trust { display: flex; flex-wrap: wrap; gap: 26px; margin-top: 40px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,0.12); }
.hero__trust-item { display: flex; flex-direction: column; }
.hero__trust-item strong { font-family: var(--font-head); font-size: 1.8rem; color: var(--gold); }
.hero__trust-item span { font-size: 0.85rem; color: rgba(255,255,255,0.7); }

.page-hero { padding: 64px 0 56px; }
.page-hero p { margin-bottom: 28px; }
.breadcrumb { font-size: 0.85rem; color: rgba(255,255,255,0.6); margin-bottom: 18px; }
.breadcrumb a { color: var(--gold); }
.breadcrumb span { margin: 0 8px; }

/* ---------- Grid utilidades ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }

/* ---------- Cards ---------- */
.card {
  background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 28px; transition: all var(--transition); height: 100%;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--gold-soft); }
.card__icon {
  width: 52px; height: 52px; border-radius: 12px; background: var(--navy);
  display: grid; place-items: center; margin-bottom: 18px; color: var(--gold);
}
.card__icon svg { width: 26px; height: 26px; }
.card h3 { font-size: 1.2rem; margin-bottom: 10px; }
.card p { font-size: 0.96rem; margin-bottom: 16px; }
.card__link { font-weight: 700; font-size: 0.92rem; display: inline-flex; align-items: center; gap: 6px; }
.card__link svg { width: 15px; height: 15px; transition: transform var(--transition); }
.card:hover .card__link svg { transform: translateX(4px); }

/* Feature item (por qué elegirnos) */
.feature { display: flex; gap: 18px; align-items: flex-start; }
.feature__icon {
  flex-shrink: 0; width: 48px; height: 48px; border-radius: 12px;
  background: var(--gold-soft); display: grid; place-items: center; color: var(--gold-dark);
}
.feature__icon svg { width: 24px; height: 24px; }
.feature h3 { font-size: 1.2rem; margin-bottom: 6px; }
.feature p { margin-bottom: 0; }

/* Lista con check */
.check-list li { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; color: var(--text-muted); }
.check-list li svg { flex-shrink: 0; width: 22px; height: 22px; color: var(--gold-dark); margin-top: 2px; }
.check-list li strong { color: var(--navy); }

/* Pasos / proceso */
.steps { counter-reset: step; display: grid; gap: 20px; }
.step { position: relative; padding: 26px 26px 26px 84px; background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius); }
.step::before {
  counter-increment: step; content: counter(step); position: absolute; left: 22px; top: 24px;
  width: 44px; height: 44px; border-radius: 50%; background: var(--navy); color: var(--gold);
  font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; display: grid; place-items: center;
}
.step h4 { margin-bottom: 6px; }
.step p { margin-bottom: 0; font-size: 0.96rem; }

/* Tabla comparativa */
.table-wrap { overflow-x: auto; border-radius: var(--radius); box-shadow: var(--shadow-sm); }
table.compare { width: 100%; border-collapse: collapse; background: var(--white); min-width: 560px; }
table.compare th, table.compare td { padding: 16px 18px; text-align: left; border-bottom: 1px solid var(--gray-200); }
table.compare thead th { background: var(--navy); color: var(--white); font-family: var(--font-body); font-size: 0.9rem; letter-spacing: 0.5px; }
table.compare tbody tr:nth-child(even) { background: var(--light); }
table.compare td:first-child { font-weight: 700; color: var(--navy); }
.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 700; background: var(--gold-soft); color: var(--gold-dark); }

/* Prose (texto largo) */
.prose p { font-size: 1.05rem; }
.prose h2 { margin: 36px 0 14px; }
.prose h3 { margin: 28px 0 10px; }
.prose ul { margin: 0 0 18px; }
.prose ul li { position: relative; padding-left: 26px; margin-bottom: 10px; color: var(--text-muted); }
.prose ul li::before { content: ""; position: absolute; left: 4px; top: 11px; width: 8px; height: 8px; background: var(--gold); border-radius: 50%; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(135deg, var(--navy) 0%, var(--navy-600) 100%); border-radius: var(--radius); padding: 44px; text-align: center; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; right: -40px; top: -40px; width: 200px; height: 200px; background: radial-gradient(circle, rgba(197,168,128,0.25), transparent 70%); }
.cta-band h2, .cta-band h3 { color: var(--white); position: relative; }
.cta-band p { color: rgba(255,255,255,0.8); position: relative; max-width: 60ch; margin: 12px auto 26px; }
.cta-band .btn { position: relative; }
.cta-band__actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Formularios ---------- */
.form-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 32px; border: 1px solid var(--gray-200); }
.form-grid { display: grid; gap: 18px; grid-template-columns: 1fr; }
.form-grid.cols-2 > .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 600; font-size: 0.9rem; color: var(--navy); }
.field label .req { color: var(--error); }
.field input, .field select, .field textarea {
  font-family: var(--font-body); font-size: 1rem; padding: 12px 14px; border: 1px solid var(--gray-300);
  border-radius: var(--radius-sm); background: var(--white); color: var(--text); transition: border var(--transition), box-shadow var(--transition); width: 100%;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(197,168,128,0.2); }
.field input.invalid, .field select.invalid, .field textarea.invalid { border-color: var(--error); box-shadow: 0 0 0 3px rgba(214,69,69,0.12); }
.field .error-msg { color: var(--error); font-size: 0.82rem; display: none; }
.field.has-error .error-msg { display: block; }
.checkbox { display: flex; gap: 10px; align-items: flex-start; font-size: 0.88rem; color: var(--text-muted); }
.checkbox input { width: auto; margin-top: 3px; flex-shrink: 0; }
.checkbox a { font-weight: 600; }
.form-note { font-size: 0.82rem; color: var(--gray-500); margin-top: 4px; }

.form-alert { display: none; padding: 16px 18px; border-radius: var(--radius-sm); margin-bottom: 20px; font-weight: 600; }
.form-alert.success { display: block; background: rgba(31,157,99,0.1); color: var(--success); border: 1px solid rgba(31,157,99,0.3); }
.form-alert.error { display: block; background: rgba(214,69,69,0.08); color: var(--error); border: 1px solid rgba(214,69,69,0.3); }

/* Calculadora resultado */
.calc-result { margin-top: 18px; padding: 20px; border-radius: var(--radius-sm); background: var(--light); border: 1px dashed var(--gold); display: none; }
.calc-result.show { display: block; }
.calc-result .big { font-family: var(--font-head); font-size: 1.8rem; color: var(--navy); font-weight: 700; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin: 0 auto; }
.faq__item { border: 1px solid var(--gray-200); border-radius: var(--radius-sm); margin-bottom: 12px; background: var(--white); overflow: hidden; }
.faq__q { width: 100%; text-align: left; background: transparent; border: 0; padding: 18px 22px; font-family: var(--font-head); font-weight: 700; font-size: 1.08rem; color: var(--navy); cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq__q .plus { flex-shrink: 0; width: 22px; height: 22px; position: relative; transition: transform var(--transition); }
.faq__q .plus::before, .faq__q .plus::after { content: ""; position: absolute; background: var(--gold-dark); border-radius: 2px; }
.faq__q .plus::before { width: 100%; height: 2px; top: 10px; }
.faq__q .plus::after { height: 100%; width: 2px; left: 10px; transition: transform var(--transition); }
.faq__item.open .plus::after { transform: rotate(90deg); opacity: 0; }
.faq__a { max-height: 0; overflow: hidden; transition: max-height var(--transition); }
.faq__a p { padding: 0 22px 20px; margin: 0; }

/* ---------- Sobre nosotros / equipo ---------- */
.team-card { text-align: center; }
.team-card .avatar {
  width: 110px; height: 110px; border-radius: 50%; margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--navy), var(--navy-600)); color: var(--gold);
  display: grid; place-items: center; font-family: var(--font-head); font-size: 2.2rem; font-weight: 700;
}
.team-card h3 { font-size: 1.2rem; margin-bottom: 2px; }
.team-card .role { color: var(--gold-dark); font-weight: 700; font-size: 0.9rem; margin-bottom: 10px; }
.stat-grid { display: grid; gap: 24px; grid-template-columns: repeat(2, 1fr); text-align: center; }
.stat .num { font-family: var(--font-head); font-size: clamp(2rem,5vw,2.8rem); color: var(--gold); font-weight: 700; }
.stat .label { font-size: 0.9rem; color: rgba(255,255,255,0.75); }

/* ---------- Contacto info ---------- */
.contact-info li { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 20px; }
.contact-info .ci-icon { flex-shrink: 0; width: 44px; height: 44px; border-radius: 10px; background: var(--gold-soft); color: var(--gold-dark); display: grid; place-items: center; }
.contact-info .ci-icon svg { width: 22px; height: 22px; }
.contact-info strong { display: block; color: var(--navy); }
.contact-info a, .contact-info span { color: var(--text-muted); }
.map-embed { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); border: 1px solid var(--gray-200); }
.map-embed iframe { width: 100%; height: 320px; border: 0; display: block; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,0.7); padding: 56px 0 0; }
.footer-grid { display: grid; gap: 36px; grid-template-columns: 1fr; }
.footer-col h4 { color: var(--white); font-size: 1.05rem; margin-bottom: 16px; font-family: var(--font-body); letter-spacing: 0.3px; }
.footer-col p { color: rgba(255,255,255,0.65); font-size: 0.92rem; }
.footer-col ul li { margin-bottom: 9px; }
.footer-col ul a { color: rgba(255,255,255,0.7); font-size: 0.92rem; }
.footer-col ul a:hover { color: var(--gold); }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; font-size: 0.92rem; color: rgba(255,255,255,0.7); }
.footer-contact svg { width: 18px; height: 18px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }
.footer-brand .brand__name { font-size: 1.15rem; }
.footer-map iframe { width: 100%; height: 180px; border: 0; border-radius: var(--radius-sm); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); margin-top: 44px; padding: 22px 0; display: flex; flex-direction: column; gap: 10px; align-items: center; text-align: center; font-size: 0.85rem; }
.footer-bottom a { color: rgba(255,255,255,0.7); }
.footer-legal { display: flex; gap: 18px; flex-wrap: wrap; justify-content: center; }

/* ---------- WhatsApp flotante ---------- */
.wa-float {
  position: fixed; bottom: 22px; right: 22px; z-index: 90; width: 58px; height: 58px;
  border-radius: 50%; background: #25D366; display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25); transition: transform var(--transition);
}
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 32px; height: 32px; fill: #fff; }

/* ---------- Animación on-scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (min-width: 600px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .form-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
  .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1.4fr; }
  .split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
  .split.form-side { grid-template-columns: 1fr 1.05fr; align-items: start; }
}
@media (min-width: 1000px) {
  .nav__links { display: flex; }
  .nav__cta { display: inline-flex; }
  .nav__toggle { display: none; }
  .grid-3.cols-5 { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1100px) {
  .grid-3.feat-5 { grid-template-columns: repeat(2, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* =================================================================
   ACCESIBILIDAD (widget flotante) + BANNER DE COOKIES
   ================================================================= */

/* ---- Escalado de fuente ---- */
html.a11y-fs-1 { font-size: 112.5%; }
html.a11y-fs-2 { font-size: 125%; }
html.a11y-fs-3 { font-size: 140%; }

/* ---- Alto contraste ---- */
html.a11y-contrast, html.a11y-contrast body { background: #000 !important; }
html.a11y-contrast .hero, html.a11y-contrast .section--navy,
html.a11y-contrast .site-header, html.a11y-contrast .site-footer,
html.a11y-contrast .cta-band, html.a11y-contrast .mobile-menu { background: #000 !important; }
html.a11y-contrast .hero::after, html.a11y-contrast .hero::before,
html.a11y-contrast .cta-band::before { display: none !important; }
html.a11y-contrast *, html.a11y-contrast h1, html.a11y-contrast h2,
html.a11y-contrast h3, html.a11y-contrast h4, html.a11y-contrast p,
html.a11y-contrast span, html.a11y-contrast li, html.a11y-contrast strong,
html.a11y-contrast label, html.a11y-contrast .eyebrow { color: #fff !important; border-color: #fff !important; }
html.a11y-contrast .card, html.a11y-contrast .form-card, html.a11y-contrast .step,
html.a11y-contrast .faq__item, html.a11y-contrast table.compare,
html.a11y-contrast .field input, html.a11y-contrast .field select,
html.a11y-contrast .field textarea { background: #000 !important; border-color: #fff !important; }
html.a11y-contrast a, html.a11y-contrast .card__link { color: #ffff00 !important; }
html.a11y-contrast .btn { background: #ffff00 !important; color: #000 !important; border-color: #ffff00 !important; }
html.a11y-contrast .card__icon, html.a11y-contrast .feature__icon,
html.a11y-contrast .ci-icon { background: #ffff00 !important; color: #000 !important; }

/* ---- Resaltar enlaces ---- */
html.a11y-links a { text-decoration: underline !important; text-underline-offset: 3px; outline: 2px dashed currentColor; outline-offset: 2px; }

/* ---- Fuente legible ---- */
html.a11y-readable, html.a11y-readable body, html.a11y-readable h1, html.a11y-readable h2,
html.a11y-readable h3, html.a11y-readable h4, html.a11y-readable p, html.a11y-readable a,
html.a11y-readable span, html.a11y-readable li, html.a11y-readable button, html.a11y-readable input,
html.a11y-readable select, html.a11y-readable textarea, html.a11y-readable label {
  font-family: Arial, Helvetica, "Segoe UI", sans-serif !important; letter-spacing: 0.4px !important;
}
html.a11y-readable p, html.a11y-readable li { line-height: 1.9 !important; }

/* ---- Escala de grises ---- */
html.a11y-grayscale body { filter: grayscale(100%); }

/* ---- Botón flotante de accesibilidad ---- */
.a11y-fab {
  position: fixed; left: 22px; bottom: 22px; z-index: 98; width: 56px; height: 56px;
  border-radius: 50%; background: var(--navy); color: var(--gold); border: 2px solid var(--gold);
  display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow);
  transition: transform var(--transition);
}
.a11y-fab:hover { transform: scale(1.08); }
.a11y-fab svg { width: 30px; height: 30px; }

.a11y-panel {
  position: fixed; left: 22px; bottom: 88px; z-index: 98; width: 300px; max-width: calc(100vw - 44px);
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-lg);
  border-top: 4px solid var(--gold); padding: 18px; display: none;
}
.a11y-panel.open { display: block; }
.a11y-panel h3 { font-size: 1.1rem; margin-bottom: 4px; }
.a11y-panel .a11y-sub { font-size: 0.8rem; color: var(--gray-500); margin-bottom: 14px; }
.a11y-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.a11y-row span { font-size: 0.9rem; font-weight: 600; color: var(--navy); }
.a11y-steppers { display: flex; gap: 6px; }
.a11y-btn {
  font-family: var(--font-body); font-weight: 700; font-size: 0.85rem; cursor: pointer;
  border: 1px solid var(--gray-300); background: var(--light); color: var(--navy);
  border-radius: 7px; padding: 8px 10px; min-width: 36px; transition: all var(--transition);
}
.a11y-btn:hover { border-color: var(--gold); }
.a11y-toggle { width: 100%; text-align: left; display: flex; align-items: center; gap: 10px; }
.a11y-toggle[aria-pressed="true"] { background: var(--navy); color: var(--white); border-color: var(--navy); }
.a11y-toggle[aria-pressed="true"] .a11y-dot { background: var(--gold); }
.a11y-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid currentColor; flex-shrink: 0; }
.a11y-panel .a11y-reset { width: 100%; margin-top: 10px; background: transparent; color: var(--error); border-color: var(--error); }
.a11y-fs-ind { min-width: 28px; text-align: center; font-weight: 700; font-size: 0.85rem; color: var(--navy); }

/* ---- Banner de cookies ---- */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 97; background: var(--navy);
  color: rgba(255,255,255,0.9); box-shadow: 0 -6px 24px rgba(10,25,47,0.25);
  padding: 18px 20px; display: none;
}
.cookie-banner.show { display: block; }
.cookie-banner__inner { max-width: var(--container); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 16px; justify-content: space-between; }
.cookie-banner p { margin: 0; font-size: 0.9rem; color: rgba(255,255,255,0.85); flex: 1 1 320px; }
.cookie-banner a { color: var(--gold); text-decoration: underline; }
.cookie-banner__actions { display: flex; gap: 10px; flex-wrap: wrap; }
.cookie-banner .btn { padding: 10px 20px; font-size: 0.92rem; }
.cookie-banner .btn-reject { background: transparent; color: #fff; border-color: rgba(255,255,255,0.5); }
.cookie-banner .btn-reject:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ---- Mapa bloqueado hasta consentimiento ---- */
.map-blocked {
  position: absolute; inset: 0; background: var(--navy); color: #fff; display: flex;
  flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; padding: 18px;
}
.map-blocked p { margin: 0; font-size: 0.88rem; color: rgba(255,255,255,0.85); max-width: 36ch; }

@media (max-width: 560px) {
  .cookie-banner__actions { width: 100%; }
  .cookie-banner__actions .btn { flex: 1; }
  .a11y-fab { width: 50px; height: 50px; left: 16px; bottom: 16px; }
  .a11y-panel { left: 16px; bottom: 76px; }
}

/* ---- Selector de idioma (navbar) ---- */
.lang-switch { display: inline-flex; align-items: center; flex-shrink: 0; margin-left: 10px; border: 1px solid rgba(255,255,255,0.25); border-radius: 6px; overflow: hidden; line-height: 1; }
.lang-switch span, .lang-switch a { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; font-size: 0.78rem; font-weight: 700; font-family: var(--font-body); line-height: 1; letter-spacing: 0.4px; white-space: nowrap; }
.lang-switch .flag { width: 15px; height: 10px; border-radius: 2px; flex-shrink: 0; display: block; }
.lang-switch a:not(:first-child), .lang-switch span:not(:first-child) { border-left: 1px solid rgba(255,255,255,0.18); }
.lang-switch .lang-active { background: var(--gold); color: var(--navy); }
.lang-switch a { color: rgba(255,255,255,0.85); }
.lang-switch a:hover { background: rgba(255,255,255,0.12); color: #fff; }
.lang-switch--mobile { margin: 18px 0 0; width: max-content; }
html.a11y-contrast .lang-switch .lang-active { background: #ffff00 !important; color: #000 !important; }
