/* ============================================================
   Vitral — Taller de Vidrieras · styles.css
   Identidad: cálido, artesanal, editorial.
   ============================================================ */

:root {
  --ink: #1b1713;
  --ink-soft: #57493d;
  --paper: #f7f3ec;
  --paper-2: #efe7d9;
  --amber: #d95f1e;
  --amber-deep: #b2440e;
  --gold: #b98a3e;
  --line: rgba(27, 23, 19, 0.14);
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;
  --shadow-soft: 0 10px 30px rgba(27, 23, 19, 0.10);
  --shadow-lift: 0 18px 44px rgba(27, 23, 19, 0.16);
}

/* ——— Base ——— */
html { scroll-behavior: smooth; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
}
h1 { font-size: clamp(2.6rem, 5vw, 4.2rem); line-height: 1.08; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.9rem); line-height: 1.15; }
h3 { font-size: 1.35rem; line-height: 1.25; }

p  { color: var(--ink-soft); }
a  { color: var(--amber-deep); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--amber); }

img { max-width: 100%; }

.container { max-width: 1180px; }

/* Kicker / etiqueta de sección */
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 1rem;
}
.kicker::before {
  content: "";
  width: 2.2rem;
  height: 1px;
  background: var(--amber);
  display: inline-block;
}

/* Línea de plomo entre secciones */
.lead-rule {
  border: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line) 18%, var(--line) 82%, transparent);
  margin: 0;
}

/* Secciones */
.section { padding: 5.5rem 0; }
.section-tight { padding: 4rem 0; }
.section-head { max-width: 640px; margin-bottom: 3rem; }
.section-head .lead { font-size: 1.08rem; }

/* ——— Header ——— */
.site-header {
  background: var(--ink);
  position: sticky;
  top: 0;
  z-index: 1030;
  transition: box-shadow .25s ease, background .25s ease;
}
.site-header.scrolled { box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35); }

.site-header .navbar { padding: 0.65rem 0; }
.site-header .navbar-brand { display: flex; align-items: center; }
.site-header .navbar-brand img {
  height: 44px;
  width: auto;
  display: block;
}

.site-header .nav-link {
  color: rgba(247, 243, 236, 0.82);
  font-size: 0.92rem;
  font-weight: 500;
  padding: .5rem 1rem;
  position: relative;
}
.site-header .nav-link::after {
  content: "";
  position: absolute;
  left: 1rem; right: 1rem; bottom: 0.2rem;
  height: 1px;
  background: var(--amber);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
.site-header .nav-link:hover,
.site-header .nav-link.active { color: #fff; }
.site-header .nav-link:hover::after,
.site-header .nav-link.active::after { transform: scaleX(1); }

.site-header .navbar-toggler {
  border: 0;
  color: var(--paper);
}
.site-header .navbar-toggler:focus { box-shadow: none; }

/* Botones */
.btn-amber {
  background: var(--amber);
  border: 1px solid var(--amber);
  color: #fff;
  font-weight: 600;
  padding: 0.6rem 1.35rem;
  border-radius: 2px;
  transition: background .2s ease, transform .2s ease;
}
.btn-amber:hover { background: var(--amber-deep); border-color: var(--amber-deep); color: #fff; transform: translateY(-1px); }

.btn-ghost-light {
  background: transparent;
  border: 1px solid rgba(247, 243, 236, 0.55);
  color: var(--paper);
  font-weight: 600;
  padding: 0.6rem 1.35rem;
  border-radius: 2px;
  transition: border-color .2s ease, background .2s ease, transform .2s ease;
}
.btn-ghost-light:hover { border-color: var(--paper); background: rgba(247, 243, 236, 0.08); color: #fff; transform: translateY(-1px); }

.btn-ghost-dark {
  background: transparent;
  border: 1px solid var(--ink);
  color: var(--ink);
  font-weight: 600;
  padding: 0.6rem 1.35rem;
  border-radius: 2px;
  transition: background .2s ease, transform .2s ease;
}
.btn-ghost-dark:hover { background: var(--ink); color: var(--paper); transform: translateY(-1px); }

/* ——— Hero ——— */
.hero {
  position: relative;
  min-height: min(88vh, 860px);
  display: flex;
  align-items: center;
  background: var(--ink) no-repeat center / cover;
  color: var(--paper);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(100deg, rgba(27,23,19,0.90) 0%, rgba(27,23,19,0.62) 45%, rgba(27,23,19,0.22) 100%),
    linear-gradient(0deg, rgba(27,23,19,0.85) 0%, transparent 40%);
}
.hero-inner { position: relative; z-index: 1; padding: 6rem 0; width: 100%; }
.hero .kicker { color: var(--gold); }
.hero .kicker::before { background: var(--gold); }
.hero h1 { color: #fff; max-width: 24ch; }
.hero .hero-sub {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: rgba(247, 243, 236, 0.88);
  max-width: 52ch;
  margin-top: 1.4rem;
}
.hero-cta { margin-top: 2.4rem; display: flex; gap: 1rem; flex-wrap: wrap; }

/* Cabecera compacta de interior */
.page-head { padding: 5rem 0 3.5rem; }
.page-head h1 { max-width: 22ch; }
.page-head .lead { max-width: 62ch; font-size: 1.1rem; }
.page-head--tint { background: var(--paper-2); border-bottom: 1px solid var(--line); }

/* ——— Stats ——— */
.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 3rem;
}
.stat {
  border-top: 1px solid var(--line);
  padding-top: 1.2rem;
}
.stat .stat-num {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 600;
  color: var(--amber);
  line-height: 1;
}
.stat .stat-label {
  margin-top: .5rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
@media (max-width: 575px) {
  .stats-row { grid-template-columns: 1fr; gap: 1.2rem; }
}

/* ——— Cards genéricas ——— */
.card-clean {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 1.9rem 1.6rem;
  height: 100%;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  display: flex;
  flex-direction: column;
}
.card-clean:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
  border-color: rgba(217, 95, 30, 0.4);
}
.card-clean h3 { margin-bottom: .7rem; font-size: 1.45rem; }
.card-clean p { flex: 1; font-size: 0.95rem; }
.card-clean .card-link {
  margin-top: 1.2rem;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
}
.card-clean .card-num {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--amber);
  letter-spacing: 0.18em;
}

/* Noticias */
.news-card { padding: 0; overflow: hidden; }
.news-card .news-body { padding: 1.6rem; }
.news-card h3 { font-size: 1.3rem; }
.news-card .news-date {
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
}

/* ——— Pasos del proceso ——— */
.steps-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1.2rem; }
.step {
  border-top: 1px solid var(--line);
  padding-top: 1.1rem;
}
.step .step-num {
  font-family: var(--serif);
  font-size: 2.1rem;
  color: var(--amber);
  line-height: 1;
}
.step h3 { font-size: 1.15rem; margin: .6rem 0 .4rem; }
.step p { font-size: 0.88rem; margin: 0; }
@media (max-width: 991px) { .steps-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575px) { .steps-grid { grid-template-columns: 1fr; } }

/* ——— Galería (compartida portada/trabajos) ——— */
.gallery-item {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: 3px;
  cursor: zoom-in;
  background: var(--ink);
}
.gallery-item .gallery-thumb {
  aspect-ratio: 4 / 3;
  overflow: hidden;
}
.gallery-item .gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .5s ease;
}
.gallery-item:hover .gallery-thumb img { transform: scale(1.045); }
.gallery-item figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 2.2rem 1.1rem 0.9rem;
  background: linear-gradient(0deg, rgba(27,23,19,0.85), transparent);
  color: #fff;
  font-family: var(--serif);
  font-size: 1.02rem;
  opacity: 0;
  transition: opacity .3s ease;
}
.gallery-item:hover figcaption,
.gallery-item:focus figcaption { opacity: 1; }
@media (hover: none) {
  .gallery-item figcaption { opacity: 1; padding-top: 1rem; }
}

/* Filtros */
.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.2rem;
}
.gallery-filter {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.42rem 1.1rem;
  border-radius: 999px;
  transition: all .2s ease;
}
.gallery-filter:hover { border-color: var(--amber); color: var(--amber-deep); }
.gallery-filter.active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

/* Lightbox */
.lightbox-modal .modal-content {
  background: #12100d;
  border: 0;
  border-radius: 4px;
}
.lightbox-modal .modal-body { padding: 0; display: flex; flex-direction: column; }
.lightbox-modal .lightbox-img {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  object-fit: contain;
  display: block;
}
.lightbox-modal .lightbox-caption {
  padding: 1rem 1.25rem;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 1.05rem;
  background: #12100d;
  margin: 0;
  border-top: 1px solid rgba(247,243,236,0.12);
}

/* ——— Banda CTA ——— */
.cta-band {
  background: var(--ink);
  color: var(--paper);
  padding: 4.5rem 0;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(247,243,236,0.8); }
.cta-band .kicker { color: var(--gold); }
.cta-band .kicker::before { background: var(--gold); }

/* ——— Footer ——— */
.site-footer {
  background: var(--ink);
  color: rgba(247, 243, 236, 0.78);
  font-size: 0.93rem;
}
.site-footer .footer-logo {
  height: 40px;
  display: inline-block;
}
.site-footer .footer-tag { margin-top: 1rem; color: rgba(247,243,236,0.6); }
.site-footer .footer-title {
  font-family: var(--serif);
  color: #fff;
  font-size: 1.15rem;
  margin-bottom: 0.9rem;
}
.site-footer .footer-list { list-style: none; padding: 0; margin: 0; }
.site-footer .footer-list li { margin-bottom: 0.45rem; }
.site-footer a { color: rgba(247,243,236,0.78); }
.site-footer a:hover { color: var(--gold); }
.site-footer .footer-bottom {
  border-top: 1px solid rgba(247, 243, 236, 0.14);
  padding: 1.2rem 0;
  font-size: 0.82rem;
  color: rgba(247, 243, 236, 0.5);
}

/* ——— Servicios ——— */
.service-section { padding: 4.5rem 0; border-top: 1px solid var(--line); }
.service-section:first-of-type { border-top: 0; }
.service-section h2 { margin-bottom: 1.2rem; }
.service-section .service-copy p { max-width: 68ch; }
.service-grid { margin-top: 2.4rem; }
.before-after {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
  margin-top: 2.4rem;
}
.before-after figure { margin: 0; border: 1px solid var(--line); border-radius: 3px; overflow: hidden; background: #fff; }
.before-after figure img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.before-after figcaption {
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
}
@media (max-width: 575px) { .before-after { grid-template-columns: 1fr; } }

.service-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.4rem;
  margin: 1.2rem 0 0;
  font-size: 0.88rem;
}
.service-nav a { color: var(--ink-soft); }
.service-nav a:hover { color: var(--amber-deep); }

.note-small {
  font-size: 0.82rem;
  color: var(--ink-soft);
  font-style: italic;
}

/* ——— Empresa ——— */
.values-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  list-style: none;
  padding: 0;
  margin-top: 2rem;
}
.values-list li {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 3px;
  padding: 1.1rem 1.2rem;
  font-weight: 500;
  display: flex;
  align-items: baseline;
  gap: 0.8rem;
}
.values-list .v-num {
  font-family: var(--serif);
  color: var(--amber);
  font-size: 1.05rem;
}
@media (max-width: 575px) { .values-list { grid-template-columns: 1fr; } }

.workshop-card {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 3px;
  padding: 1.8rem;
  height: 100%;
}
.workshop-card .ws-city {
  font-family: var(--serif);
  font-size: 1.5rem;
  color: var(--ink);
}
.workshop-card .ws-addr { font-size: 0.9rem; color: var(--ink-soft); margin: .4rem 0 .8rem; }

/* ——— Contacto (email) ——— */
.contact-email {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  font-weight: 600;
  color: var(--amber-deep);
  border-bottom: 2px solid var(--amber);
  display: inline-block;
  line-height: 1.25;
  transition: color .2s ease, border-color .2s ease;
}
.contact-email:hover { color: var(--amber); border-color: var(--gold); }


/* ——— Aviso legal ——— */
.legal-content { max-width: 760px; }
.legal-content h2 { font-size: 1.7rem; margin-top: 2.4rem; }
.legal-content p, .legal-content li { color: var(--ink-soft); }
.legal-content ul { padding-left: 1.2rem; }

/* ——— Revelado al scroll ——— */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ——— Trabajos: carruseles por técnica ——— */
.gallery-sliders { padding-top: 2.5rem; }
.gallery-slide { margin-bottom: 4.5rem; }
.gallery-slide:last-child { margin-bottom: 0; }
.gallery-slide .section-head { max-width: 760px; margin-bottom: 1.75rem; }

.work-carousel {
  border-radius: 3px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 18px 40px -18px rgba(27, 23, 19, 0.28);
}
.work-carousel .carousel-item {
  /* display:flex no se usa a propósito: rompería el display:none
     que Bootstrap aplica a los items inactivos (se apilarían). */
  line-height: 1;
}
.work-slide {
  position: relative;
  margin: 0;
  width: 100%;
  cursor: zoom-in;
  -webkit-tap-highlight-color: transparent;
}
.work-slide img {
  display: block;
  width: 100%;
  height: clamp(300px, 68vh, 620px);
  object-fit: contain;
  background: #211c17;
}
.work-slide:focus-visible { outline: 2px solid var(--amber); outline-offset: -2px; }
.work-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 2.4rem 1.25rem 1rem;
  background: linear-gradient(180deg, rgba(27, 23, 19, 0) 0%, rgba(27, 23, 19, 0.85) 100%);
  color: #fff;
  font-family: var(--serif);
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  font-weight: 500;
  pointer-events: none;
}
.work-carousel .carousel-control-prev,
.work-carousel .carousel-control-next {
  width: 4.5rem;
  z-index: 5;
}
.work-carousel .carousel-control-prev .carousel-control-prev-icon,
.work-carousel .carousel-control-next .carousel-control-next-icon {
  width: 3.2rem;
  height: 3.2rem;
  background-position: center;
  background-repeat: no-repeat;
  background-color: rgba(27, 23, 19, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  opacity: 0.95;
}
.work-carousel .carousel-control-prev:hover,
.work-carousel .carousel-control-next:hover { opacity: 1; }

/* ——— SEO: migas de pan y FAQ ——— */
.breadcrumbs {
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.breadcrumbs a { color: var(--gold); text-decoration: none; }
.breadcrumbs a:hover { color: var(--amber); }
.breadcrumbs [aria-current="page"] { color: var(--ink-soft); }

.faq-list div { border-bottom: 1px solid var(--line); padding: 1.1rem 0; }
.faq-list div:last-child { border-bottom: 0; }
.faq-list dt {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.35rem;
}
.faq-list dd { margin: 0; color: var(--ink-soft); line-height: 1.6; }

/* ——— Banner de consentimiento de cookies ——— */
.cookie-banner {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 1080;
  background: var(--ink);
  color: var(--paper);
  box-shadow: 0 -10px 34px rgba(27, 23, 19, 0.38);
}
.cookie-inner { position: relative; padding: 1.5rem 0 1.4rem; }
.cookie-close {
  position: absolute;
  top: 0.5rem; right: 0.5rem;
  width: 2.2rem; height: 2.2rem;
  background: transparent;
  border: 0;
  color: rgba(247, 243, 236, 0.75);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.cookie-close:hover { color: var(--paper); }
.cookie-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--paper);
  margin-bottom: 0.45rem;
}
.cookie-text {
  color: rgba(247, 243, 236, 0.85);
  font-size: 0.95rem;
  line-height: 1.55;
  margin-bottom: 0.9rem;
  max-width: 75ch;
}
.cookie-text a { color: var(--gold); }
.cookie-panel {
  border-top: 1px solid rgba(247, 243, 236, 0.18);
  padding-top: 0.85rem;
  margin-bottom: 0.9rem;
  display: grid;
  gap: 0.65rem;
}
.cookie-item {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-size: 0.9rem;
  line-height: 1.5;
  color: rgba(247, 243, 236, 0.85);
  cursor: default;
}
.cookie-item input { margin-top: 0.25rem; width: 1.05rem; height: 1.05rem; accent-color: var(--amber); flex: none; }
.cookie-item strong { color: var(--paper); }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.cookie-btn {
  background: transparent;
  border: 1px solid rgba(247, 243, 236, 0.45);
  color: var(--paper);
  padding: 0.5rem 1.1rem;
  font-size: 0.9rem;
  border-radius: 0.35rem;
  cursor: pointer;
}
.cookie-btn:hover { background: rgba(247, 243, 236, 0.1); color: #fff; }
.cookie-btn-primary {
  background: var(--amber);
  border-color: var(--amber);
  color: #fff;
}
.cookie-btn-primary:hover { background: var(--amber-deep); border-color: var(--amber-deep); color: #fff; }
.cookie-settings-link { color: var(--gold); text-decoration: none; }
.cookie-settings-link:hover { color: var(--amber); text-decoration: underline; }

@media (max-width: 575px) {
  .cookie-inner { padding: 1.2rem 0 1.1rem; }
  .cookie-text { font-size: 0.88rem; }
  .cookie-actions .cookie-btn { flex: 1 1 auto; text-align: center; }
}
