/*
Theme Name: Cerrajeros Baratos Child
Template: astra
Version: 1.0
Description: Child theme de Astra para cerrajeros-baratos.es
*/

/* ===== VARIABLES ===== */
:root {
  --cb-bg:         #1a1a1a;
  --cb-gold:       #c9a961;
  --cb-gold-hover: #b08950;
  --cb-text:       #e8e8e8;
  --cb-heading:    #ffffff;
  --cb-border:     rgba(201,169,97,0.2);
  --cb-section-bg: #222222;
  --font-heading:  'DM Serif Display', Georgia, serif;
  --font-body:     'Inter', system-ui, -apple-system, sans-serif;
  --container:     1240px;
  --section-pad:   80px;
  /* aliases for inline styles in HTML */
  --gold:          #c9a961;
  --gold-dark:     #b08950;
  --gray-500:      #6b7280;
  --gray-700:      #9ca3af;
}

/* ===== GOOGLE FONTS ===== */
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Inter:wght@300;400;500;600;700&display=swap');

/* ===== RESET / BASE ===== */
*, *::before, *::after { box-sizing: border-box; }

html, body {
  background-color: var(--cb-bg) !important;
}
body {
  color: var(--cb-text);
  font-family: var(--font-body);
  margin: 0;
  padding: 0;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--cb-heading);
  margin-top: 0;
}
p { margin-top: 0; }
a { color: var(--cb-gold); }
a:hover { color: var(--cb-gold-hover); }
img { max-width: 100%; height: auto; }
ul { margin: 0; padding: 0; }

/* ===== Suppress Astra page title, padding, sidebar ===== */
.entry-header,
.entry-header .page-title,
.ast-page-title-wrap {
  display: none !important;
}
.entry-content,
.ast-article-single,
.ast-entry-content-wrap,
.ast-container .entry-content {
  margin: 0 !important;
  padding: 0 !important;
  max-width: 100% !important;
}
.ast-article-single { padding: 0 !important; }
/* Remove Astra's default header and footer if still rendering */
#masthead { display: none !important; }
#colophon { display: none !important; }
/* Remove Astra's main content padding */
.ast-single-post-order .entry-content-wrap { padding: 0 !important; }
#primary { padding: 0 !important; }
.site-content { padding: 0 !important; }
.ast-container { max-width: var(--container) !important; }

/* ===== WRAP ===== */
.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== TOPBAR ===== */
.topbar {
  background: #111;
  border-bottom: 1px solid var(--cb-border);
  padding: 8px 0;
  font-size: 13px;
}
.topbar .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.topbar-msg { color: var(--cb-text); opacity: 0.8; }
.topbar-tel {
  color: var(--cb-gold);
  font-weight: 600;
  text-decoration: none;
}
.topbar-tel:hover { color: var(--cb-gold-hover); }

/* ===== HEADER ===== */
.header {
  background: var(--cb-bg);
  border-bottom: 1px solid var(--cb-border);
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.header .wrap {
  display: flex;
  align-items: center;
  gap: 40px;
}

/* ===== LOGO ===== */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.logo-mark {
  width: 36px;
  height: 36px;
  background: var(--cb-gold);
  color: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  font-family: var(--font-heading);
  border-radius: 4px;
  flex-shrink: 0;
}
.logo-text {
  font-size: 20px;
  color: #fff;
  font-family: var(--font-heading);
}
.logo-text span { color: var(--cb-gold); }

/* ===== NAV ===== */
.nav {
  display: flex;
  gap: 32px;
  margin-left: auto;
}
.nav a {
  color: var(--cb-text) !important;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}
.nav a:hover { color: var(--cb-gold) !important; }

.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--cb-gold);
  color: #1a1a1a !important;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: background 0.2s;
  white-space: nowrap;
}
.header-cta:hover { background: var(--cb-gold-hover); color: #1a1a1a !important; }
.header-cta .btn-icon { width: 15px; height: 15px; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}
.btn-icon { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary {
  background: var(--cb-gold);
  color: #1a1a1a !important;
}
.btn-primary:hover { background: var(--cb-gold-hover); color: #1a1a1a !important; }
.btn-ghost {
  background: transparent;
  color: var(--cb-gold) !important;
  border: 1.5px solid var(--cb-gold);
}
.btn-ghost:hover { background: rgba(201,169,97,0.1); }

/* ===== HERO ===== */
.hero {
  padding: 100px 0 80px;
  background: var(--cb-bg);
}
.hero-eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cb-gold);
  font-weight: 600;
  margin-bottom: 16px;
}
.hero h1 {
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.15;
  margin-bottom: 20px;
  max-width: 700px;
}
.hero h1 em {
  font-style: italic;
  color: var(--cb-gold);
}
.hero-lead {
  font-size: 18px;
  line-height: 1.7;
  color: var(--cb-text);
  max-width: 620px;
  margin-bottom: 36px;
}
.hero-ctas {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}
.hero-meta {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  padding-top: 32px;
  border-top: 1px solid var(--cb-border);
}
.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero-meta-icon {
  width: 22px;
  height: 22px;
  color: var(--cb-gold);
  flex-shrink: 0;
}
.hero-meta-text {
  font-size: 13px;
  line-height: 1.3;
  color: var(--cb-text);
}
.hero-meta-text strong {
  display: block;
  color: #fff;
  font-size: 14px;
  margin-bottom: 1px;
}

/* ===== TRUST BAR ===== */
.trust {
  background: #111;
  border-top: 1px solid var(--cb-border);
  border-bottom: 1px solid var(--cb-border);
  padding: 40px 0;
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  text-align: center;
}
.trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.trust-num {
  font-family: var(--font-heading);
  font-size: 44px;
  color: var(--cb-gold);
  line-height: 1;
}
.trust-label {
  font-size: 13px;
  color: var(--cb-text);
  line-height: 1.4;
}
.trust-label strong {
  display: block;
  color: #fff;
  font-size: 14px;
  margin-bottom: 2px;
}

/* ===== SECTIONS ===== */
.section {
  padding: var(--section-pad) 0;
  background: var(--cb-bg);
}
.section-dark { background: #111 !important; }
.section-light { background: var(--cb-section-bg) !important; }

/* ===== SECTION HEADER ===== */
.sh {
  max-width: 680px;
  margin-bottom: 56px;
}
.sh.center {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}
.sh-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cb-gold);
  font-weight: 600;
  margin-bottom: 12px;
}
.sh-eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--cb-gold);
  flex-shrink: 0;
}
.sh.center .sh-eyebrow { justify-content: center; }
.sh h2 {
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.2;
  margin-bottom: 16px;
}
.sh p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--cb-text);
  margin: 0;
}

/* ===== SERVICES GRID ===== */
.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service {
  background: #222;
  border: 1px solid var(--cb-border);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.25s;
}
.service:hover { border-color: var(--cb-gold); }
.service-img {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #2a2a2a;
}
.service-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.service:hover .service-img img { transform: scale(1.04); }
.service-body { padding: 24px; }
.service-body h3 {
  font-size: 18px;
  margin-bottom: 10px;
}
.service-body p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--cb-text);
  margin-bottom: 16px;
}
.service-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--cb-gold);
  text-decoration: none;
}
.service-link:hover { color: var(--cb-gold-hover); }

/* ===== STEPS ===== */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}
.step-num {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cb-gold);
  font-weight: 600;
  margin-bottom: 16px;
}
.step h3 {
  font-size: 22px;
  margin-bottom: 12px;
}
.step p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--cb-text);
  margin: 0;
}

/* ===== FEATURE (Por qué confiar) ===== */
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.feature-img {
  background: #222;
  border: 1px solid var(--cb-border);
  border-radius: 8px;
  min-height: 480px;
  background-image: url('https://images.unsplash.com/photo-1558618666-fcd25c85cd64?w=800&q=80&auto=format&fit=crop');
  background-size: cover;
  background-position: center;
}
.feature-content .sh-eyebrow { margin-bottom: 12px; }
.feature-content h2 { margin-bottom: 16px; }
.feature-list {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.feature-list li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.feature-list-num {
  width: 36px;
  height: 36px;
  min-width: 36px;
  background: rgba(201,169,97,0.12);
  color: var(--cb-gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
}
.feature-list-text {
  font-size: 15px;
  line-height: 1.5;
  color: var(--cb-text);
}
.feature-list-text strong {
  display: block;
  color: #fff;
  margin-bottom: 2px;
}

/* ===== ZONES ===== */
.zones {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.zones a {
  display: inline-block;
  padding: 8px 18px;
  background: rgba(201,169,97,0.06);
  border: 1px solid var(--cb-border);
  border-radius: 20px;
  font-size: 14px;
  color: var(--cb-text) !important;
  text-decoration: none;
  transition: all 0.2s;
}
.zones a:hover {
  background: rgba(201,169,97,0.15);
  border-color: var(--cb-gold);
  color: #fff !important;
}

/* ===== FAQ ===== */
.faq {
  max-width: 720px;
  margin: 0 auto;
}
.faq details {
  border-bottom: 1px solid var(--cb-border);
}
.faq details:first-child { border-top: 1px solid var(--cb-border); }
.faq summary {
  padding: 20px 0;
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-family: var(--font-body);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+';
  color: var(--cb-gold);
  font-size: 24px;
  font-weight: 300;
  flex-shrink: 0;
  line-height: 1;
}
.faq details[open] > summary::after { content: '−'; }
.faq details p {
  padding: 0 0 20px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--cb-text);
  margin: 0;
}

/* ===== FINAL CTA ===== */
.final-cta {
  background: linear-gradient(135deg, #1a1a1a 0%, #111 100%);
  border-top: 1px solid var(--cb-border);
  padding: 100px 0;
  text-align: center;
}
.final-cta h2 {
  font-size: clamp(28px, 4vw, 48px);
  margin-bottom: 16px;
}
.final-cta p {
  font-size: 17px;
  color: var(--cb-text);
  margin-bottom: 36px;
}

/* ===== FOOTER ===== */
.footer {
  background: #111;
  border-top: 1px solid var(--cb-border);
  padding: 60px 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand p {
  font-size: 14px;
  line-height: 1.7;
  color: var(--cb-text);
  margin-top: 16px;
}
.footer h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cb-gold);
  margin-bottom: 16px;
  font-family: var(--font-body);
}
.footer-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-list a {
  font-size: 14px;
  color: var(--cb-text) !important;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-list a:hover { color: var(--cb-gold) !important; }
.footer-bottom {
  border-top: 1px solid var(--cb-border);
  padding: 20px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--gray-500);
}

/* ===== STICKY MOBILE BAR ===== */
.sticky-mobile {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
}
.sticky-tel, .sticky-wa {
  flex: 1;
  padding: 16px;
  text-align: center;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sticky-tel {
  background: var(--cb-gold);
  color: #1a1a1a !important;
}
.sticky-wa {
  background: #25D366;
  color: #fff !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .services { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .feature { grid-template-columns: 1fr; gap: 48px; }
  .feature-img { min-height: 300px; }
}

@media (max-width: 768px) {
  :root { --section-pad: 56px; }
  .services { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 32px; }
  .nav { display: none; }
  .hero { padding: 60px 0 48px; }
  .hero-meta { gap: 20px; }
  .sticky-mobile { display: flex; }
  body { padding-bottom: 60px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 480px) {
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-ctas { flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
  .zones a { font-size: 13px; }
}

/* ===== PAGE HERO (subpáginas) ===== */
.pagehero {
  padding: 80px 0 60px;
  background: var(--cb-bg);
  border-bottom: 1px solid var(--cb-border);
}
.pagehero .eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cb-gold);
  font-weight: 600;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.pagehero .eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--cb-gold);
}
.pagehero h1 {
  font-size: clamp(32px, 4.5vw, 52px);
  line-height: 1.15;
  margin-bottom: 16px;
  max-width: 700px;
}
.pagehero h1 em {
  font-style: italic;
  color: var(--cb-gold);
}
.pagehero p {
  font-size: 18px;
  line-height: 1.7;
  color: var(--cb-text);
  max-width: 620px;
  margin: 0;
}

/* ===== PROSE (bloques de texto) ===== */
.prose {
  max-width: 720px;
  font-size: 16px;
  line-height: 1.8;
  color: var(--cb-text);
}
.prose p { margin-bottom: 20px; }
.prose strong { color: #fff; }

/* ===== STATS ===== */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-top: 48px;
  padding-top: 48px;
  border-top: 1px solid var(--cb-border);
}
.stat { text-align: center; }
.stat-num {
  font-family: var(--font-heading);
  font-size: 44px;
  color: var(--cb-gold);
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 14px;
  color: var(--cb-text);
}

/* ===== SECTION ALT (fondo alternativo) ===== */
.section.alt { background: #111 !important; }

@media (max-width: 768px) {
  .pagehero { padding: 56px 0 40px; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
