:root {
  --bg: #f5efe5;
  --bg-soft: #fffaf3;
  --surface: #fffdf9;
  --surface-strong: #fff4df;
  --text: #25323b;
  --muted: #53636d;
  --line: rgba(37, 50, 59, 0.12);
  --primary: #a2471c;
  --primary-dark: #7d3411;
  --secondary: #0f5b63;
  --accent: #d9b26d;
  --shadow: 0 18px 48px rgba(31, 34, 37, 0.12);
  --radius-lg: 30px;
  --radius-md: 22px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(217, 178, 109, 0.28), transparent 24%),
    linear-gradient(180deg, #fffaf5 0%, var(--bg) 48%, #f8f2e9 100%);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  line-height: 1.68;
}
img { display: block; max-width: 100%; }
a { color: var(--secondary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
p, ul { margin: 0 0 1rem; }
h1, h2, h3 {
  margin: 0 0 1rem;
  line-height: 1.08;
  color: #182129;
  font-family: Georgia, "Times New Roman", serif;
}
h1 { font-size: clamp(2.5rem, 5vw, 4.8rem); }
h2 { font-size: clamp(1.9rem, 3.8vw, 3.1rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.55rem); }
.container { width: min(calc(100% - 2rem), var(--container)); margin: 0 auto; }

.site-topbar {
  background: #163940;
  color: #fff;
  padding: 0.9rem 0;
}
.topbar-content,
.header-shell,
.hero-layout,
.trust-grid,
.split,
.footer-grid,
.footer-bottom,
.page-hero-shell,
.section-heading,
.hero-actions,
.topbar-actions,
.inline-links { display: flex; gap: 1rem; }
.topbar-content,
.header-shell,
.footer-bottom { align-items: center; justify-content: space-between; }
.topbar-content p { margin: 0; max-width: 720px; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 250, 243, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-shell { min-height: 86px; }
.brand img { height: 60px; width: auto; }
.site-nav { display: flex; gap: 1.15rem; align-items: center; }
.site-nav a { color: var(--text); font-weight: 700; }
.site-nav a.is-active,
.site-nav a:hover { color: var(--primary); }
.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 50%;
  padding: 0.78rem;
  flex-direction: column;
  justify-content: space-between;
}
.nav-toggle span { display: block; height: 2px; width: 100%; background: var(--primary-dark); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0.85rem 1.35rem;
  border-radius: 999px;
  font-weight: 800;
  border: 1px solid transparent;
  transition: transform 180ms ease, background-color 180ms ease, color 180ms ease, border-color 180ms ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-secondary { border-color: var(--secondary); color: var(--secondary); background: transparent; }
.btn-secondary:hover { background: rgba(15, 91, 99, 0.08); }
.btn-ghost { border-color: rgba(255, 255, 255, 0.3); color: #fff; }
.btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.btn-whatsapp { background: #1c8c58; color: #fff; }
.btn-whatsapp:hover { color: #fff; background: #14613d; }

.hero,
.page-hero { padding: 4.2rem 0 3rem; }
.hero-layout,
.split,
.footer-grid,
.page-hero-shell { justify-content: space-between; align-items: stretch; }
.hero-layout > *,
.split > * { flex: 1 1 0; }
.hero-home {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.84), rgba(255, 244, 223, 0.88)),
    linear-gradient(180deg, rgba(162, 71, 28, 0.08), transparent 45%);
}
.hero-copy {
  padding: 2rem 2rem 2rem 0;
  max-width: 700px;
}
.hero-stack { display: grid; gap: 1rem; }
.hero-card,
.service-card,
.zone-card,
.info-card,
.content-card,
.text-shell,
.cta-panel,
.map-card,
.mini-panel,
.page-hero-copy,
.page-hero-side,
.trust-grid article,
.faq-grid article {
  background: var(--surface);
  border: 1px solid rgba(24, 33, 41, 0.08);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.hero-card { overflow: hidden; }
.hero-card img { aspect-ratio: 1 / 1.02; object-fit: cover; }
.hero-card-copy { padding: 1.35rem; }
.mini-panel { padding: 1.4rem; align-self: end; background: linear-gradient(180deg, #fff9ef, #fff2dc); }
.eyebrow {
  display: inline-flex;
  margin-bottom: 1rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(162, 71, 28, 0.1);
  color: var(--primary-dark);
  font-weight: 800;
  font-size: 0.9rem;
}
.hero-points,
.contact-list { padding-left: 1.15rem; }
.hero-points li,
.contact-list li,
.zone-list li { margin-bottom: 0.55rem; }
.section { padding: 4.8rem 0; }
.section-alt { background: linear-gradient(180deg, rgba(15, 91, 99, 0.03), rgba(217, 178, 109, 0.12)); }
.section-heading {
  flex-direction: column;
  max-width: 780px;
  margin-bottom: 2rem;
}
.trust-grid,
.cards-grid,
.zones-grid,
.info-grid,
.content-grid,
.faq-grid { display: grid; gap: 1.25rem; }
.trust-grid { grid-template-columns: 1.25fr 1fr 1fr; }
.trust-grid article { padding: 1.5rem; }
.cards-grid-services { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.zones-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.info-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.content-grid,
.faq-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.service-card,
.zone-card,
.info-card,
.content-card { overflow: hidden; }
.service-card img { aspect-ratio: 1 / 0.86; object-fit: cover; }
.service-card div,
.zone-card div,
.info-card div,
.content-card div { padding: 1.4rem; }
.text-shell,
.cta-panel,
.page-hero-copy,
.page-hero-side { padding: 2rem; }
.page-hero-shell { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 1.25rem; }
.page-hero-copy { background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 250, 243, 0.95)); }
.page-hero-side {
  background: linear-gradient(180deg, #163940, #0f5b63);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.page-hero-side h2,
.page-hero-side p,
.site-footer h3 { color: #fff; }
.page-hero-side .btn-secondary { color: #fff; border-color: rgba(255, 255, 255, 0.45); }
.split-map { align-items: center; }
.split-tight { align-items: start; }
.map-card { padding: 1rem; }
.map-card iframe {
  width: 100%;
  min-height: 420px;
  border: 0;
  border-radius: 22px;
}
.text-link { font-weight: 800; }
.inline-links,
.hero-actions,
.topbar-actions { flex-wrap: wrap; }
.contact-block { display: grid; grid-template-columns: 0.95fr 1.05fr; gap: 1.25rem; }

.site-footer {
  background: #182129;
  color: rgba(255, 255, 255, 0.84);
  padding: 3.2rem 0 1.4rem;
}
.footer-grid { align-items: start; gap: 1.5rem; }
.footer-grid > div { display: flex; flex-direction: column; gap: 0.65rem; }
.footer-grid a { color: rgba(255, 255, 255, 0.78); }
.footer-grid a:hover { color: #fff; }
.footer-logo { width: 220px; height: auto; }
.footer-bottom {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-bottom p { margin: 0; }

strong { color: #182129; }

@media (max-width: 1080px) {
  .cards-grid-services,
  .zones-grid,
  .info-grid,
  .trust-grid,
  .content-grid,
  .faq-grid,
  .page-hero-shell,
  .contact-block { grid-template-columns: 1fr 1fr; }
  .hero-layout,
  .split,
  .footer-grid { flex-direction: column; }
  .hero-copy { padding-right: 0; }
}

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    top: calc(100% + 0.6rem);
    left: 1rem;
    right: 1rem;
    padding: 1rem;
    background: var(--surface);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    flex-direction: column;
    align-items: flex-start;
  }
  .site-nav.is-open { display: flex; }
  .topbar-content { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 720px) {
  .cards-grid-services,
  .zones-grid,
  .info-grid,
  .trust-grid,
  .content-grid,
  .faq-grid,
  .page-hero-shell,
  .contact-block { grid-template-columns: 1fr; }
  .section,
  .hero,
  .page-hero { padding: 3.3rem 0; }
  .header-shell { min-height: 76px; }
  .brand img { height: 48px; }
  .page-hero-copy,
  .page-hero-side,
  .text-shell,
  .cta-panel { padding: 1.5rem; }
  .map-card iframe { min-height: 320px; }
}
/* codex-local-fixes */
img, svg, video, iframe { max-width: 100%; }
iframe { display: block; }
.button-row, .hero-actions, .inline-actions, .top-actions, .footer-links, .footer-actions, .header-actions { gap: 12px; flex-wrap: wrap; }
.container, .wrap, .hg-container { width: min(100% - 32px, 1200px); margin-inline: auto; }
details { margin-top: 14px; }
summary { cursor: pointer; }
.faq-answer p, p, li, a { overflow-wrap: anywhere; }
.hg-section { padding: 32px 0; }
.hg-cta-band { padding: 24px; border-radius: 18px; background: rgba(0,0,0,.04); }


/* codex-global-route-fixes */
.brand img,
.site-header .brand img,
.navbar-brand img,
.header-logo img,
.logo img {
  width: min(220px, 100%);
  max-width: 100%;
  max-height: 120px;
  height: auto;
  object-fit: contain;
}

.footer-logo,
.site-footer .brand img,
.site-footer .logo img,
footer .brand img,
footer img[alt*="logo" i],
footer img[alt*="cerrajero" i] {
  width: min(180px, 100%);
  max-width: 100%;
  max-height: 140px;
  height: auto;
  object-fit: contain;
}

#nuevas-rutas-locales details {
  margin-top: 1rem;
  padding: 1.2rem 1.25rem;
  border: 1px solid rgba(17, 36, 61, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 28px rgba(17, 36, 61, 0.08);
}

#nuevas-rutas-locales summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  cursor: pointer;
  font-weight: 800;
  font-size: 1.05rem;
  list-style: none;
}

#nuevas-rutas-locales summary::-webkit-details-marker {
  display: none;
}

#nuevas-rutas-locales .footer-links,
#nuevas-rutas-locales .quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

#nuevas-rutas-locales .footer-links a,
#nuevas-rutas-locales .quick-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.8rem 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(17, 36, 61, 0.12);
  box-shadow: 0 8px 20px rgba(17, 36, 61, 0.06);
  text-decoration: none;
  font-weight: 700;
  line-height: 1.35;
}

#nuevas-rutas-locales .footer-links a:hover,
#nuevas-rutas-locales .quick-links a:hover {
  transform: translateY(-1px);
}

.floating-actions .btn-whatsapp,
.floating-whatsapp,
a[href*="wa.me/34653373620"] {
  white-space: nowrap;
}

@media (max-width: 768px) {
  .brand img,
  .site-header .brand img,
  .navbar-brand img,
  .header-logo img,
  .logo img {
    width: min(180px, 100%);
    max-height: 96px;
  }

  .footer-logo,
  .site-footer .brand img,
  .site-footer .logo img,
  footer .brand img,
  footer img[alt*="logo" i],
  footer img[alt*="cerrajero" i] {
    width: min(150px, 100%);
    max-height: 112px;
  }

  #nuevas-rutas-locales .footer-links a,
  #nuevas-rutas-locales .quick-links a {
    width: 100%;
    justify-content: flex-start;
  }
}

#nuevas-rutas-locales summary::after {
  content: "+";
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1;
  color: #c9b000;
}

#nuevas-rutas-locales details[open] summary::after {
  content: "−";
}

/* SEO FOOTER UPGRADE START */
.hg-section {
  padding: 2.4rem 0;
}

.hg-container {
  width: min(calc(100% - 2rem), var(--container));
  margin: 0 auto;
}

.hg-cta-band {
  padding: 1.8rem 2rem;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(15, 76, 92, 0.1), rgba(191, 91, 44, 0.12)), var(--paper);
  border: 1px solid rgba(15, 76, 92, 0.16);
  box-shadow: var(--shadow);
}

.hg-cta-band h2 {
  margin-bottom: 0.75rem;
}

.hg-cta-band p:last-child {
  margin-bottom: 0;
}

.site-footer {
  background:
    radial-gradient(circle at top left, rgba(231, 159, 111, 0.16), transparent 26%),
    linear-gradient(180deg, #161b25 0%, #11161f 100%);
}

.footer-shell {
  padding: 3.4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
  align-items: start;
}

.footer-card {
  min-width: 0;
  padding: 1.3rem;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer .brand {
  display: inline-flex;
  flex-direction: column;
  gap: 0.2rem;
  text-decoration: none;
}

.site-footer .brand-name {
  color: #fff;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.site-footer .brand-copy {
  color: rgba(255, 248, 240, 0.78);
  font-size: 0.95rem;
}

.footer-brand .brand {
  margin-bottom: 0.9rem;
}

.footer-card h3 {
  margin-bottom: 0.9rem;
  color: #fff;
  font-size: 1.05rem;
}

.footer-note,
.footer-card p,
.footer-card a {
  color: rgba(255, 248, 240, 0.84);
}

.footer-note {
  margin-bottom: 1rem;
}

.footer-links {
  display: grid;
  gap: 0.65rem;
}

.footer-links a {
  line-height: 1.45;
}

.footer-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  justify-content: flex-start;
}

.site-footer .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 1.2rem;
  border-radius: 999px;
  border: 0;
  font-weight: 700;
  text-decoration: none;
}

.site-footer .button-primary {
  background: linear-gradient(135deg, #bf5b2c, #e79f6f);
  color: #fff;
}

.site-footer .button-secondary {
  background: linear-gradient(135deg, #0f4c5c, #2d7f94);
  color: #fff;
}

.footer-legal {
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  color: rgba(255, 248, 240, 0.62);
  font-size: 0.92rem;
}

@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .hg-cta-band,
  .footer-card {
    padding: 1.15rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}
/* SEO FOOTER UPGRADE END */
