/* =========================================================
   Táxi Alves — Design System
   Douro palette. Fraunces (headings) + Inter (body).
   Mobile-first. 8px scale. Pure CSS. No frameworks.
   ========================================================= */

/* ---------- Fonts (self-hosted; falls back gracefully) ---------- */
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ---------- Design tokens ---------- */
:root {
  /* Colour — Douro palette */
  --c-primary: #1B4332;
  --c-primary-dark: #143326;
  --c-accent: #B08948;
  --c-accent-soft: #EFE3CC;
  --c-bg: #FAF7F2;
  --c-bg-alt: #F0EAE0;
  --c-ink: #1F1F1D;
  --c-ink-soft: #5C5850;
  --c-line: #E5DFD3;
  --c-wine: #5E2129;
  --c-white: #ffffff;

  /* Type stacks — Fraunces + system fallback / Inter + system fallback */
  --font-display: "Fraunces", Georgia, "Times New Roman", "Playfair Display", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  /* Spacing (8px scale) */
  --s-1: 8px;
  --s-2: 16px;
  --s-3: 24px;
  --s-4: 32px;
  --s-5: 48px;
  --s-6: 64px;
  --s-7: 96px;

  /* Radius / shadow */
  --r-sm: 6px;
  --r: 10px;
  --r-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(20, 20, 15, .05);
  --shadow: 0 2px 8px rgba(20, 20, 15, .06);
  --shadow-lg: 0 12px 32px rgba(20, 20, 15, .12);

  /* Layout */
  --container: 1100px;
  --header-h: 64px;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--c-primary); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--c-primary-dark); }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; color: var(--c-ink); letter-spacing: -0.01em; line-height: 1.15; margin: 0 0 var(--s-2); }
h1 { font-size: clamp(2rem, 5.2vw, 3.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.25rem); }
h3 { font-size: 1.25rem; line-height: 1.25; }
p { margin: 0 0 var(--s-2); }
ul { margin: 0; padding: 0; }

/* Focus */
:focus-visible {
  outline: 3px solid var(--c-accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Skip link */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--c-primary); color: var(--c-white);
  padding: 12px 16px; font-weight: 600; border-radius: 0 0 var(--r) 0; z-index: 100;
}
.skip-link:focus { left: 0; color: var(--c-white); }

/* Container */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--s-3);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(250, 247, 242, .92);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--c-line);
}
.header-inner {
  min-height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s-2);
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 700; font-size: 1.15rem;
  color: var(--c-ink); text-decoration: none;
}
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 8px;
  background: var(--c-primary); color: var(--c-white);
}
.site-nav { display: none; }
.site-nav ul { list-style: none; display: flex; gap: var(--s-3); }
.site-nav a { color: var(--c-ink-soft); text-decoration: none; font-weight: 500; font-size: 0.95rem; }
.site-nav a:hover { color: var(--c-primary); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.lang-switch {
  font-weight: 600; font-size: 0.85rem; letter-spacing: 0.08em;
  padding: 8px 10px; border-radius: var(--r-sm);
  color: var(--c-ink-soft); text-decoration: none;
  border: 1px solid var(--c-line); background: var(--c-white);
}
.lang-switch:hover { color: var(--c-primary); border-color: var(--c-primary); }

@media (min-width: 768px) {
  .site-nav { display: block; }
}

/* ---------- Buttons ---------- */
.btn {
  --btn-h: 48px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: var(--btn-h);
  padding: 0 20px;
  font: inherit; font-weight: 600; font-size: 1rem;
  border-radius: var(--r); border: 1px solid transparent; cursor: pointer;
  text-decoration: none; white-space: nowrap;
  transition: background 150ms ease, color 150ms ease, transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}
.btn svg { flex-shrink: 0; }
.btn-primary { background: var(--c-primary); color: var(--c-white); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--c-primary-dark); color: var(--c-white); box-shadow: var(--shadow); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--c-primary); border-color: currentColor; }
.btn-ghost:hover { background: var(--c-primary); color: var(--c-white); border-color: var(--c-primary); }
.btn-light { background: var(--c-white); color: var(--c-wine); }
.btn-light:hover { background: var(--c-accent-soft); color: var(--c-wine); }
.btn-outline-light { background: transparent; color: var(--c-white); border-color: rgba(255,255,255,.7); }
.btn-outline-light:hover { background: rgba(255,255,255,.12); color: var(--c-white); }
.btn-whatsapp { background: #25D366; color: var(--c-white); box-shadow: var(--shadow-sm); border-color: #25D366; }
.btn-whatsapp:hover, .btn-whatsapp:focus-visible { background: #1EBE5D; color: var(--c-white); border-color: #1EBE5D; box-shadow: var(--shadow); transform: translateY(-1px); }
.btn-lg { --btn-h: 56px; padding: 0 26px; font-size: 1.05rem; }
.btn-compact { --btn-h: 40px; padding: 0 14px; font-size: 0.95rem; border-radius: 8px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate;
  color: var(--c-white);
  padding: clamp(var(--s-6), 12vw, 120px) 0 clamp(var(--s-6), 10vw, 96px);
  overflow: hidden;
  /* CSS gradient carries the Douro palette even if the image is missing/slow */
  background:
    radial-gradient(120% 80% at 80% -10%, rgba(176, 137, 72, .35), transparent 55%),
    linear-gradient(160deg, #143326 0%, #1B4332 45%, #2A1A1D 85%, #5E2129 100%);
}
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  overflow: hidden;
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(20, 51, 38, .55) 0%, rgba(20, 51, 38, .70) 60%, rgba(20, 20, 20, .82) 100%);
}
.hero-bg img {
  width: 100%; height: 100%; object-fit: cover; object-position: center;
  opacity: .85;
}
.hero-inner {
  position: relative;
  max-width: 780px;
  text-align: left;
}
.hero .eyebrow { color: var(--c-accent); }
.hero h1 { color: var(--c-white); margin-bottom: var(--s-3); }
.hero .lede {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  color: rgba(255, 255, 255, .88);
  max-width: 58ch;
  margin-bottom: var(--s-4);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-2); }
.hero-note { color: rgba(255, 255, 255, .72); font-size: 0.9rem; margin: 0; }
.hero-english-note {
  color: rgba(255, 255, 255, .92);
  font-size: 0.92rem;
  margin: 10px 0 0;
  max-width: 46ch;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .45);
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(var(--s-6), 9vw, var(--s-7)) 0;
}
.section-alt { background: var(--c-bg-alt); }
.section-head {
  max-width: 640px;
  margin: 0 auto var(--s-5);
  text-align: center;
}
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--c-accent);
  margin: 0 0 12px;
}
.section-sub { color: var(--c-ink-soft); font-size: 1.05rem; margin: 0; }

/* ---------- Cards ---------- */
.cards {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-3);
}
@media (min-width: 640px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .cards { grid-template-columns: repeat(3, 1fr); } }

.card {
  position: relative;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-lg);
  padding: var(--s-4) var(--s-3);
  box-shadow: var(--shadow);
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: #d9d0bd; }
.card-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px;
  border-radius: 10px;
  background: var(--c-bg-alt);
  color: var(--c-primary);
  margin-bottom: var(--s-3);
}
.card-icon svg { width: 22px; height: 22px; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--c-ink-soft); margin-bottom: var(--s-2); }

.card-featured {
  background: linear-gradient(180deg, #FBF4E6 0%, #FFFFFF 55%);
  border-color: var(--c-accent);
  box-shadow: 0 8px 24px rgba(176, 137, 72, .18);
}
.card-featured .card-icon { background: var(--c-accent); color: var(--c-white); }
.card-badge {
  position: absolute; top: -12px; left: var(--s-3);
  background: var(--c-accent); color: var(--c-white);
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 999px;
  box-shadow: var(--shadow-sm);
}
@media (min-width: 1024px) {
  .card-featured { grid-column: span 1; }
}

.booking-note {
  max-width: 680px;
  margin: var(--s-5) auto 0;
  text-align: center;
  color: var(--c-ink-soft);
  font-size: 1rem;
  padding: var(--s-3);
  background: var(--c-bg);
  border: 1px solid var(--c-line);
  border-radius: var(--r);
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-5);
  align-items: center;
}
.about-media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  background: var(--c-bg);
}
.about-text h2 { margin-bottom: var(--s-3); }
.about-text p { color: var(--c-ink-soft); font-size: 1.05rem; }
.pill-list {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: var(--s-3);
}
.pill-list li {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--c-primary);
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: 999px;
  padding: 6px 12px;
}
@media (min-width: 768px) {
  .about-grid { grid-template-columns: 5fr 6fr; gap: var(--s-6); }
}

/* ---------- Reviews ---------- */
.reviews {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-3);
}
@media (min-width: 768px) { .reviews { grid-template-columns: repeat(3, 1fr); } }
.review {
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-lg);
  padding: var(--s-4) var(--s-3);
  box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column;
}
.stars {
  color: var(--c-accent);
  letter-spacing: 3px;
  font-size: 1.05rem;
  margin-bottom: var(--s-2);
}
.review blockquote {
  margin: 0 0 var(--s-3);
  font-family: var(--font-display);
  font-size: 1.1rem;
  line-height: 1.5;
  color: var(--c-ink);
}
.review cite {
  font-style: normal;
  font-size: 0.9rem;
  color: var(--c-ink-soft);
  margin-top: auto;
}
.review-note { font-size: 0.8em; opacity: 0.7; }
.reviews-cta { text-align: center; margin: var(--s-5) 0 0; }
.reviews-cta a { font-weight: 600; }

/* ---------- Zona / Area ---------- */
.zona-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-4);
  align-items: center;
}
.zona-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--r-lg);
  background: var(--c-bg);
  box-shadow: var(--shadow);
}
@media (min-width: 768px) {
  .zona-grid { grid-template-columns: 5fr 6fr; gap: var(--s-6); }
}

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(135deg, #5E2129 0%, #431419 100%);
  color: var(--c-white);
  padding: clamp(var(--s-5), 8vw, var(--s-6)) 0;
}
.cta-inner {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--s-3);
}
.cta-band h2 { color: var(--c-white); margin: 0; }
.cta-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); justify-content: center; }
@media (min-width: 768px) {
  .cta-inner { flex-direction: row; justify-content: space-between; text-align: left; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: #1a1a18;
  color: #cfc9bd;
  padding: var(--s-6) 0 var(--s-3);
}
.site-footer a { color: #efe6d3; }
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-4);
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.2fr 1fr 1.4fr; gap: var(--s-5); }
}
.footer-brand {
  font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; color: var(--c-white);
  margin: 0 0 8px;
}
.footer-heading {
  font-family: var(--font-body); font-weight: 700; font-size: 0.82rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: #efe6d3;
  margin: 0 0 12px;
}
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.fine { font-size: 0.88rem; color: #a8a294; line-height: 1.6; }
.credits { font-size: 0.7rem; opacity: 0.6; color: #a8a294; line-height: 1.5; margin-top: var(--s-2); }
.credits a { color: #cfc9bd; }
.footer-bottom {
  margin-top: var(--s-5);
  padding-top: var(--s-3);
  border-top: 1px solid rgba(255,255,255,.08);
  font-size: 0.85rem;
  color: #857f72;
}
.footer-bottom p { margin: 0; }

/* ---------- Floating call (mobile only) ---------- */
.floating-call {
  position: fixed;
  left: 12px; right: 12px; bottom: 12px;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px;
  padding: 0 20px;
  background: var(--c-primary); color: var(--c-white);
  font-weight: 700; font-size: 1.05rem;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(20, 51, 38, .35);
  text-decoration: none;
  z-index: 50;
}
.floating-call:hover { background: var(--c-primary-dark); color: var(--c-white); }
@media (min-width: 768px) {
  .floating-call { display: none; }
}
/* Give room to the fixed button on mobile so the footer isn't obscured */
@media (max-width: 767.98px) {
  body { padding-bottom: 84px; }
}

/* ---------- Services note (single price line under grid) ---------- */
.services-note {
  max-width: 620px;
  margin: var(--s-4) auto 0;
  text-align: center;
  color: var(--c-ink-soft);
  font-size: 0.98rem;
  font-style: italic;
}

/* ---------- Review author + avatar ---------- */
.review-author {
  display: flex; align-items: center; gap: 12px;
  margin-top: auto;
  padding-top: var(--s-2);
}
.avatar {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--c-primary);
  color: var(--c-accent-soft);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}
.review-author cite {
  font-style: normal;
  font-size: 0.92rem;
  color: var(--c-ink-soft);
  margin: 0;
}

/* ---------- Reviews carousel ---------- */
.reviews-carousel { position: relative; }
/* No-JS fallback: show reviews as a static 3-col grid (first 3 visible) */
.reviews-carousel .reviews > .review { display: flex; }
.reviews-carousel .carousel-controls { display: none; }

/* JS-enhanced state: only one slide visible, controls appear */
.reviews-carousel.is-enhanced .reviews {
  display: block;
  position: relative;
  min-height: 240px;
}
.reviews-carousel.is-enhanced .reviews > .review {
  display: none;
  opacity: 0;
  transition: opacity 400ms ease;
  max-width: 720px;
  margin: 0 auto;
}
.reviews-carousel.is-enhanced .reviews > .review.is-active {
  display: flex;
  opacity: 1;
}
.reviews-carousel.is-enhanced .carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  margin-top: var(--s-3);
}
.carousel-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--c-white);
  color: var(--c-primary);
  border: 1px solid var(--c-line);
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}
.carousel-btn:hover { background: var(--c-primary); color: var(--c-white); border-color: var(--c-primary); }
.carousel-dots {
  display: inline-flex; gap: 8px;
  padding: 0 var(--s-2);
}
.carousel-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--c-line);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 150ms ease, transform 150ms ease;
}
.carousel-dot.is-active { background: var(--c-accent); transform: scale(1.25); }
.carousel-dot:hover { background: var(--c-primary); }

@media (prefers-reduced-motion: reduce) {
  .reviews-carousel.is-enhanced .reviews > .review { transition: none; }
}

/* ---------- Zona / Area — tag lists ---------- */
.zona-subtitle {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-ink-soft);
  margin: var(--s-3) 0 12px;
}
.tag-list {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 0 0 var(--s-2);
  padding: 0;
}
.tag-list li {
  font-size: 0.88rem;
  color: var(--c-ink);
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-sm);
  padding: 6px 10px;
  line-height: 1.3;
}
.tag-list-accent li {
  color: var(--c-primary);
  border-color: var(--c-accent);
  background: var(--c-accent-soft);
  font-weight: 600;
}
.zona-note {
  font-size: 0.92rem;
  color: var(--c-ink-soft);
  font-style: italic;
  margin: 0 0 var(--s-3);
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
          