/* ==========================================================================
   Zuanaz Fogón, Andalusian recipes without vegetable oil
   Palette: whitewash cal, azulejo cobalt, albero ochre, olive, night navy
   Type: Fraunces (display) + Alegreya Sans (body)
   ========================================================================== */

:root {
  --cal: #fbfaf4;
  --cal-shade: #f2f0e6;
  --cal-deep: #e9e6d8;
  --azulejo: #1d4f8f;
  --azulejo-deep: #143a6d;
  --noche: #101f33;
  --albero: #d9a326;
  --albero-soft: #f0d488;
  --olivo: #55663a;
  --olivo-deep: #3c4a2a;
  --ink: #1b2838;
  --ink-soft: #47566a;
  --ink-faint: #718092;
  --line: rgba(20, 58, 109, 0.16);
  --line-soft: rgba(20, 58, 109, 0.08);
  --shadow-soft: 0 1px 2px rgba(16, 31, 51, 0.05), 0 12px 32px rgba(16, 31, 51, 0.09);
  --shadow-lift: 0 2px 6px rgba(16, 31, 51, 0.08), 0 26px 52px rgba(16, 31, 51, 0.16);
  --heading-font: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --body-font: 'Alegreya Sans', 'Avenir Next', 'Segoe UI', sans-serif;
  --radius-card: 14px;
  --azulejo-tile: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'%3E%3Crect width='28' height='28' fill='%23143a6d'/%3E%3Cg fill='%23fbfaf4'%3E%3Crect x='9' y='9' width='10' height='10'/%3E%3Crect x='9' y='9' width='10' height='10' transform='rotate(45 14 14)'/%3E%3C/g%3E%3Ccircle cx='14' cy='14' r='2.6' fill='%23d9a326'/%3E%3Cg fill='%23d9a326'%3E%3Crect x='-3' y='-3' width='6' height='6' transform='rotate(45 0 0)'/%3E%3Crect x='25' y='-3' width='6' height='6' transform='rotate(45 28 0)'/%3E%3Crect x='-3' y='25' width='6' height='6' transform='rotate(45 0 28)'/%3E%3Crect x='25' y='25' width='6' height='6' transform='rotate(45 28 28)'/%3E%3C/g%3E%3C/svg%3E");
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--body-font);
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--cal);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--heading-font);
  color: var(--noche);
  line-height: 1.18;
  font-weight: 600;
}

img { max-width: 100%; display: block; }

a { color: var(--azulejo); }

:focus-visible {
  outline: 3px solid var(--albero);
  outline-offset: 2px;
}

.kicker {
  display: inline-block;
  font-family: var(--body-font);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--olivo);
  margin-bottom: 14px;
}

/* Azulejo frieze, the signature band */
.azulejo-band {
  height: 14px;
  background-image: var(--azulejo-tile);
  background-size: 14px 14px;
  background-repeat: repeat-x;
}

/* Reveal on scroll (JS only; static without it) */
html.js [data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

html.js [data-reveal].revealed {
  opacity: 1;
  transform: none;
}

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

/* ==========================================================================
   Navbar
   ========================================================================== */

.navbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(251, 250, 244, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line-soft);
  transition: box-shadow 0.3s ease;
}

.navbar.scrolled {
  box-shadow: 0 6px 24px rgba(16, 31, 51, 0.08);
  border-bottom-color: var(--line);
}

.nav-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.nav-logo {
  font-family: var(--heading-font);
  font-size: 24px;
  font-weight: 600;
  color: var(--azulejo-deep);
  text-decoration: none;
  white-space: nowrap;
}

.logo-mark { margin-right: 6px; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 22px;
  color: var(--azulejo-deep);
  padding: 4px 12px;
  cursor: pointer;
}

.nav-links {
  display: flex;
  gap: 26px;
  list-style: none;
  align-items: center;
}

.nav-links a {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav-links a:hover {
  color: var(--azulejo);
  border-bottom-color: var(--albero);
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  background:
    radial-gradient(1100px 480px at 82% -10%, rgba(29, 79, 143, 0.07), transparent 60%),
    radial-gradient(800px 420px at -10% 110%, rgba(217, 163, 38, 0.09), transparent 55%),
    var(--cal);
  border-bottom: 1px solid var(--line-soft);
}

.hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 84px 28px 72px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 64px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(42px, 5.4vw, 64px);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 22px;
}

.hero h1 em {
  font-style: italic;
  font-weight: 500;
  color: var(--azulejo);
}

.hero-lede {
  font-size: 20px;
  color: var(--ink-soft);
  max-width: 54ch;
  margin-bottom: 32px;
}

.hero-actions { margin-bottom: 30px; }

.btn-primary {
  display: inline-block;
  background: var(--azulejo);
  color: #fff;
  font-family: var(--body-font);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-decoration: none;
  padding: 15px 34px;
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(29, 79, 143, 0.28);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary:hover {
  background: var(--azulejo-deep);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(29, 79, 143, 0.32);
}

.hero-fats {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--olivo);
}

.hero-fats .dot { color: var(--albero); font-size: 13px; }

.hero-figure { margin: 0; }

.hero-arch {
  border-radius: 260px 260px 18px 18px;
  overflow: hidden;
  border: 6px solid #fff;
  outline: 1px solid var(--line);
  box-shadow: var(--shadow-lift);
  background: var(--cal-deep);
}

.hero-arch img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

.hero-caption {
  margin-top: 16px;
  text-align: center;
  font-size: 15px;
  font-style: italic;
  color: var(--ink-soft);
}

.cap-mark { color: var(--albero); font-style: normal; margin-right: 6px; }

/* ==========================================================================
   Principles
   ========================================================================== */

.principles {
  background: var(--azulejo-deep);
  color: #fff;
}

.principles-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 44px;
}

.principle-word {
  display: inline-block;
  font-family: var(--heading-font);
  font-style: italic;
  font-size: 24px;
  color: var(--albero-soft);
  margin-bottom: 10px;
}

.principle h3 {
  color: #fff;
  font-size: 22px;
  margin-bottom: 12px;
}

.principle p {
  font-size: 17px;
  line-height: 1.65;
  color: rgba(251, 250, 244, 0.82);
}

/* ==========================================================================
   Recipes
   ========================================================================== */

.recipes-section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 92px 28px 40px;
}

.section-head {
  max-width: 700px;
  margin: 0 auto 56px;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(32px, 4vw, 44px);
  margin-bottom: 16px;
}

.section-lede {
  font-size: 19px;
  color: var(--ink-soft);
}

.recipe-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 34px;
}

.recipe-card {
  background: #fff;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
}

.recipe-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.card-media {
  position: relative;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 230px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.recipe-card:hover .card-media img { transform: scale(1.045); }

.card-region {
  position: absolute;
  left: 14px;
  bottom: 14px;
  background: rgba(16, 31, 51, 0.82);
  color: var(--albero-soft);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 999px;
}

.card-body {
  padding: 26px 26px 30px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-body h3 {
  font-size: 25px;
  margin-bottom: 10px;
}

.card-desc {
  font-size: 16.5px;
  color: var(--ink-soft);
  margin-bottom: 18px;
}

.card-meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.card-meta li {
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--olivo-deep);
  background: var(--cal-shade);
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 4px 13px;
}

.btn-recipe {
  align-self: flex-start;
  font-family: var(--body-font);
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--azulejo-deep);
  background: none;
  border: 2px solid var(--azulejo);
  border-radius: 999px;
  padding: 10px 24px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.btn-recipe:hover,
.btn-recipe[aria-expanded="true"] {
  background: var(--azulejo);
  color: #fff;
}

.recipe-details {
  margin-top: 24px;
  border-top: 1px dashed var(--line);
  padding-top: 20px;
}

.recipe-details h4 {
  font-size: 15px;
  font-family: var(--body-font);
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--olivo);
  margin: 18px 0 10px;
}

.recipe-details h4:first-child { margin-top: 0; }

.recipe-details ul,
.recipe-details ol {
  padding-left: 22px;
  font-size: 16px;
  color: var(--ink-soft);
}

.recipe-details li { margin-bottom: 7px; }

.recipe-details li::marker { color: var(--albero); font-weight: 700; }

/* ==========================================================================
   About
   ========================================================================== */

.about-section {
  margin-top: 60px;
  background:
    radial-gradient(900px 420px at 108% 0%, rgba(85, 102, 58, 0.08), transparent 60%),
    var(--cal-shade);
  border-top: 1px solid var(--line-soft);
}

.about-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 88px 28px;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
  align-items: center;
}

.about-figure {
  margin: 0;
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 6px solid #fff;
  outline: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}

.about-figure img {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

.about-copy h2 {
  font-size: clamp(30px, 3.6vw, 42px);
  margin-bottom: 20px;
}

.about-copy p {
  color: var(--ink-soft);
  margin-bottom: 16px;
  max-width: 60ch;
}

.about-sign {
  font-family: var(--heading-font);
  font-style: italic;
  font-size: 24px;
  color: var(--olivo-deep);
  margin-top: 8px;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  background: var(--noche);
  color: rgba(251, 250, 244, 0.85);
}

.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 68px 28px 44px;
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 0.7fr 1.2fr;
  gap: 44px;
}

.footer-logo {
  display: inline-block;
  font-family: var(--heading-font);
  font-size: 24px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 14px;
}

.footer-brand p {
  font-size: 16px;
  line-height: 1.65;
  color: rgba(251, 250, 244, 0.62);
  max-width: 34ch;
}

.footer h4 {
  color: var(--albero-soft);
  font-family: var(--body-font);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.footer-links ul { list-style: none; }

.footer-links li { margin-bottom: 10px; }

.footer-links a {
  color: rgba(251, 250, 244, 0.78);
  text-decoration: none;
  font-size: 16px;
  transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--albero-soft); }

.company-contact-box p {
  font-size: 15px;
  line-height: 1.6;
  color: rgba(251, 250, 244, 0.68);
  margin-bottom: 6px;
}

.footer-bottom {
  border-top: 1px solid rgba(251, 250, 244, 0.12);
  text-align: center;
  padding: 22px 28px;
  font-size: 14.5px;
  color: rgba(251, 250, 244, 0.5);
}

/* ==========================================================================
   Legal pages
   ========================================================================== */

.legal-hero {
  background: var(--azulejo-deep);
  color: #fff;
  text-align: center;
  padding: 72px 28px 58px;
}

.legal-hero h1 {
  color: #fff;
  font-size: clamp(32px, 4.2vw, 46px);
  margin-bottom: 10px;
}

.legal-hero .kicker { color: var(--albero-soft); margin-bottom: 10px; }

.legal-updated {
  font-size: 15px;
  color: rgba(251, 250, 244, 0.7);
}

.legal-main {
  max-width: 780px;
  margin: 0 auto;
  padding: 64px 28px 80px;
}

.legal-main h2 {
  font-size: 26px;
  margin: 38px 0 14px;
}

.legal-main h2:first-child { margin-top: 0; }

.legal-main p {
  color: var(--ink-soft);
  margin-bottom: 14px;
}

.legal-main ul {
  padding-left: 24px;
  color: var(--ink-soft);
  margin-bottom: 14px;
}

.legal-main li { margin-bottom: 8px; }

.legal-main li::marker { color: var(--albero); }

.legal-main a { color: var(--azulejo); font-weight: 700; }

.legal-main .company-contact-box {
  margin-top: 48px;
  background: var(--cal-shade);
  border: 1px solid var(--line-soft);
  border-left: 5px solid var(--azulejo);
  border-radius: 10px;
  padding: 26px 28px;
}

.legal-main .company-contact-box h4 {
  font-family: var(--body-font);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--olivo);
  margin-bottom: 12px;
}

.legal-main .company-contact-box p {
  color: var(--ink);
  margin-bottom: 6px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1024px) {
  .hero-inner { gap: 44px; padding: 64px 28px 56px; }
  .hero-arch img { height: 440px; }
  .principles-inner { gap: 32px; padding: 60px 28px; }
  .recipe-grid { grid-template-columns: repeat(2, 1fr); }
  .about-inner { gap: 44px; padding: 72px 28px; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--cal);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 32px rgba(16, 31, 51, 0.12);
    padding: 10px 0;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; text-align: center; }
  .nav-links a { display: block; padding: 13px 20px; border-bottom: none; }

  .hero-inner { grid-template-columns: 1fr; padding: 52px 24px 48px; }
  .hero-arch img { height: 380px; }
  .hero-lede { font-size: 19px; }
  .principles-inner { grid-template-columns: 1fr; gap: 36px; }
  .recipes-section { padding: 68px 24px 32px; }
  .recipe-grid { grid-template-columns: 1fr; }
  .about-inner { grid-template-columns: 1fr; padding: 60px 24px; }
  .about-figure img { height: 320px; }
  .footer-inner { grid-template-columns: 1fr; gap: 34px; padding: 52px 24px 36px; }
}

@media (max-width: 480px) {
  body { font-size: 17.5px; }
  .nav-container { padding: 14px 18px; }
  .nav-logo { font-size: 21px; }
  .hero-inner { padding: 42px 18px 40px; }
  .hero h1 { font-size: 36px; }
  .hero-fats { flex-wrap: wrap; row-gap: 6px; }
  .hero-arch { border-radius: 180px 180px 14px 14px; }
  .hero-arch img { height: 300px; }
  .btn-primary { width: 100%; text-align: center; }
  .recipes-section { padding: 56px 18px 24px; }
  .card-body { padding: 22px 20px 26px; }
  .about-inner { padding: 48px 18px; }
  .legal-main { padding: 48px 18px 60px; }
}
