/* ══════════════════════════════════════════
   ElCaminoSinGluten · hoja de estilos global
   ══════════════════════════════════════════ */

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

:root {
  /* Paleta */
  --ink:        #0F1512;
  --ink-2:      #1A231E;
  --ink-3:      #2A3630;
  --paper:      #FBFAF7;
  --surface:    #FFFFFF;
  --line:       #E7E3DC;
  --line-soft:  #F1EEE8;

  --text:       #131A16;
  --text-2:     #5A635E;
  --text-3:     #8B938E;

  --accent:     #16A34A;   /* verde principal */
  --accent-dk:  #12813C;
  --accent-lt:  #ECFDF3;
  --accent-br:  #A7E8C0;

  --lime:       #BEF264;   /* acento vivo */
  --amber:      #F59E0B;
  --amber-lt:   #FFFBEB;
  --violet:     #7C3AED;
  --violet-lt:  #F5F3FF;

  --r-sm: 10px;
  --r:    16px;
  --r-lg: 24px;
  --r-xl: 32px;

  --sh-sm: 0 1px 2px rgba(15,21,18,.05);
  --sh:    0 4px 16px -4px rgba(15,21,18,.10);
  --sh-lg: 0 24px 48px -16px rgba(15,21,18,.22);

  --nav-h: 64px;
  --max:   1180px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font, 'Plus Jakarta Sans', -apple-system, system-ui, sans-serif);
  background: var(--paper);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img, svg { display: block; max-width: 100%; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ═══ NAVEGACIÓN ═══ */
.nav {
  position: sticky; top: 0; z-index: 500;
  background: rgba(251,250,247,.82);
  backdrop-filter: blur(14px) saturate(1.6);
  -webkit-backdrop-filter: blur(14px) saturate(1.6);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  height: var(--nav-h); display: flex; align-items: center;
  justify-content: space-between; gap: 20px;
}
.brand { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.brand-mark {
  width: 36px; height: 36px; border-radius: 11px; flex-shrink: 0;
  background: linear-gradient(150deg, var(--accent) 0%, var(--accent-dk) 100%);
  display: grid; place-items: center;
  box-shadow: 0 4px 12px -3px color-mix(in srgb, var(--accent) 50%, transparent);
}
.brand-mark svg { width: 20px; height: 20px; }
/* Logo subido desde Ajustes del sitio */
.brand-mark.has-logo { width: auto; min-width: 36px; max-width: 150px; background: none; box-shadow: none; border-radius: 0; }
.brand-mark.has-logo img { height: 36px; width: auto; max-width: 150px; object-fit: contain; }
.brand.logo-solo .brand-txt { display: none; }
.brand.logo-solo .brand-mark.has-logo, .brand.logo-solo .brand-mark.has-logo img { height: 44px; max-width: 220px; }
@media (max-width: 600px) {
  .nav .brand.with-logo .brand-mark.has-logo, .nav .brand.with-logo .brand-mark.has-logo img { height: 30px; min-width: 0; max-width: 64px; }
  .nav .brand.with-logo { gap: 8px; min-width: 0; flex-shrink: 1; }
  .nav .brand.with-logo .brand-txt { font-size: 13px; }
  .nav .brand.with-logo .brand-txt span { display: none; }
}
.foot .brand-mark.has-logo { background: #fff; padding: 6px 10px; border-radius: 10px; height: auto; }
.brand-txt { font-weight: 800; font-size: 16px; letter-spacing: -.35px; line-height: 1.15; }
.brand-txt span { display: block; font-size: 10.5px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }

.nav-links { display: flex; align-items: center; gap: 2px; }
.nav-links a {
  padding: 8px 13px; border-radius: 9px; font-size: 13.5px; font-weight: 600;
  color: var(--text-2); transition: .15s;
}
.nav-links a:hover { background: var(--line-soft); color: var(--text); }
.nav-links a.on { background: var(--ink); color: #fff; }

.nav-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.lang {
  display: flex; background: var(--line-soft); border-radius: 8px; padding: 3px;
  border: 1px solid var(--line);
}
.lang button {
  padding: 4px 9px; border-radius: 6px; font-size: 11.5px; font-weight: 700;
  color: var(--text-3); transition: .15s;
}
.lang button.on { background: var(--surface); color: var(--text); box-shadow: var(--sh-sm); }

.burger { display: none; width: 38px; height: 38px; border-radius: 9px; border: 1px solid var(--line); }
.burger svg { width: 18px; height: 18px; margin: auto; stroke: var(--text); }

@media (max-width: 900px) {
  .nav-links {
    display: none; position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--line);
    padding: 8px; box-shadow: var(--sh);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 14px; font-size: 15px; }
  .burger { display: block; }
}

/* ═══ HERO ═══ */
.hero {
  background: var(--ink);
  background-image:
    radial-gradient(1000px 380px at 12% -18%, color-mix(in srgb, var(--accent) 34%, transparent), transparent 62%),
    radial-gradient(760px 320px at 92% 0%, rgba(190,242,100,.14), transparent 60%);
  color: #fff; padding: 52px 0 44px; position: relative; overflow: hidden;
}
.hero::after {
  content:''; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 22px 22px;
}
.hero > * { position: relative; z-index: 1; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14);
  padding: 5px 13px; border-radius: 100px; font-size: 11.5px; font-weight: 700;
  letter-spacing: .3px; color: rgba(255,255,255,.82); margin-bottom: 18px;
}
.eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); }

h1.hero-t {
  font-size: clamp(30px, 5.2vw, 50px); font-weight: 800;
  letter-spacing: -1.6px; line-height: 1.05; margin-bottom: 14px; max-width: 16ch;
}
h1.hero-t em { font-style: normal; color: var(--lime); }
.hero-sub {
  font-size: clamp(14.5px, 1.7vw, 17px); color: rgba(255,255,255,.66);
  max-width: 54ch; line-height: 1.6;
}

/* ═══ PÁGINAS INTERNAS ═══ */
.page-head { background: var(--ink); color: #fff; padding: 44px 0 40px;
  background-image: radial-gradient(760px 300px at 10% -30%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 62%); }
.page-head h1 { font-size: clamp(26px, 4vw, 38px); font-weight: 800; letter-spacing: -1.1px; margin-bottom: 10px; }
.page-head p { color: rgba(255,255,255,.62); font-size: 15px; max-width: 62ch; }

main { flex: 1; }
.section { padding: 44px 0; }

.prose { max-width: 76ch; }
.prose h2 { font-size: 21px; font-weight: 800; letter-spacing: -.5px; margin: 32px 0 10px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 16px; font-weight: 700; margin: 22px 0 7px; }
.prose p { color: var(--text-2); margin-bottom: 13px; font-size: 14.7px; }
.prose ul { color: var(--text-2); margin: 0 0 15px 20px; font-size: 14.7px; }
.prose li { margin-bottom: 6px; }
.prose strong { color: var(--text); font-weight: 700; }
.prose a { color: var(--accent-dk); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

.callout {
  background: var(--amber-lt); border: 1px solid #FDE68A; border-radius: var(--r);
  padding: 15px 17px; font-size: 13.5px; color: #78350F; margin-bottom: 26px;
  display: flex; gap: 11px; align-items: flex-start;
}
.callout svg { width: 17px; height: 17px; flex-shrink: 0; margin-top: 2px; stroke: #B45309; }

/* ═══ TARJETAS GENÉRICAS ═══ */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 22px; transition: .18s;
}
.card:hover { border-color: var(--accent-br); box-shadow: var(--sh); }
.card h3 { font-size: 16px; font-weight: 700; letter-spacing: -.3px; margin-bottom: 6px; }
.card p { font-size: 13.5px; color: var(--text-2); line-height: 1.55; }

.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
/* Catálogos (Guías físicas, Planifica): columnas fijas, una tarjeta sola no se estira */
.grid-cat { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.cat-img { aspect-ratio: 16 / 9; border-radius: 12px; margin-bottom: 16px; position: relative; overflow: hidden;
  display: grid; place-items: center; background: linear-gradient(140deg, var(--ink-2), var(--ink-3)); }
.cat-img .bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: blur(18px) brightness(.7); transform: scale(1.2); }
.cat-img .fg { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; object-fit: contain; }
.cat-img .tag { position: absolute; top: 10px; right: 10px; z-index: 2; background: var(--lime); color: var(--ink);
  font-size: 10px; font-weight: 800; padding: 3px 9px; border-radius: 100px; letter-spacing: .3px; }

.card-ico {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: var(--accent-lt); margin-bottom: 14px;
}
.card-ico { color: var(--accent-dk); }
.card-ico svg { width: 20px; height: 20px; stroke: currentColor; }

/* ═══ BOTONES ═══ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px; border-radius: 11px; font-size: 14px; font-weight: 700;
  transition: .16s; white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 4px 14px -4px color-mix(in srgb, var(--accent) 55%, transparent); }
.btn-primary:hover { background: var(--accent-dk); transform: translateY(-1px); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--ink-2); transform: translateY(-1px); }
.btn-ghost { background: var(--surface); color: var(--text); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--text-3); }
.btn-lime { background: var(--lime); color: var(--ink); }
.btn-lime:hover { filter: brightness(.95); }
.btn-full { width: 100%; }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

/* ═══ SELLOS ═══ */
.sello {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px 3px 7px; border-radius: 100px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .1px; white-space: nowrap;
  border: 1px solid;
}
.sello svg { width: 11px; height: 11px; flex-shrink: 0; }
.sello-cert     { background: var(--violet-lt); color: #5B21B6; border-color: #DDD6FE; }
.sello-full     { background: var(--accent-lt); color: var(--accent-dk); border-color: var(--accent-br); }
.sello-opciones { background: var(--amber-lt); color: #B45309; border-color: #FDE68A; }

/* ═══ FORMULARIOS ═══ */
.field { margin-bottom: 15px; }
.field label {
  display: block; font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .7px; color: var(--text-3); margin-bottom: 6px;
}
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line);
  border-radius: 11px; font-family: inherit; font-size: 14.5px; color: var(--text);
  background: var(--surface); transition: .15s;
}
.field textarea { min-height: 118px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-lt);
}
select {
  appearance: none; cursor: pointer; padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%238B938E' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}

/* ═══ FOOTER ═══ */
.foot { background: var(--ink); color: rgba(255,255,255,.55); padding: 46px 0 26px; margin-top: 60px; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: 34px; margin-bottom: 34px; }
@media (max-width: 800px) { .foot-grid { grid-template-columns: 1fr 1fr; gap: 28px; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }

.foot h4 { color: #fff; font-size: 12px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .9px; margin-bottom: 13px; }
.foot ul { list-style: none; }
.foot li { margin-bottom: 8px; }
.foot a { font-size: 13.5px; transition: .15s; }
.foot a:hover { color: #fff; }
.foot-about p { font-size: 13.5px; line-height: 1.65; margin: 12px 0 16px; max-width: 34ch; }

.socials { display: flex; gap: 8px; }
.socials a {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.11); transition: .15s;
}
.socials a:hover { background: var(--accent); border-color: var(--accent); }
.socials svg { width: 16px; height: 16px; fill: rgba(255,255,255,.8); }
.socials a:hover svg { fill: #fff; }

.news-box {
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.11);
  border-radius: var(--r); padding: 17px;
}
.news-box p { font-size: 12.5px; margin-bottom: 12px; line-height: 1.5; }
.news-form { display: flex; gap: 7px; }
.news-form input {
  flex: 1; min-width: 0; padding: 10px 12px; border-radius: 9px;
  border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.06);
  color: #fff; font-family: inherit; font-size: 13px;
}
.news-form input::placeholder { color: rgba(255,255,255,.38); }
.news-form input:focus { outline: none; border-color: var(--lime); }
.news-form button {
  padding: 10px 15px; border-radius: 9px; background: var(--lime); color: var(--ink);
  font-weight: 700; font-size: 13px; flex-shrink: 0;
}

.foot-base {
  border-top: 1px solid rgba(255,255,255,.09); padding-top: 22px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 12px;
}
.foot-base a { text-decoration: underline; text-underline-offset: 3px; }

/* ═══ COOKIES ═══ */
.cookie-bar {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 900;
  max-width: 620px; margin: 0 auto; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 20px;
  box-shadow: var(--sh-lg); display: none; gap: 14px; align-items: center; flex-wrap: wrap;
}
.cookie-bar.show { display: flex; }
.cookie-bar p { font-size: 13px; color: var(--text-2); flex: 1; min-width: 200px; line-height: 1.5; }
.cookie-bar a { color: var(--accent-dk); font-weight: 600; text-decoration: underline; }

/* ═══ UTILIDADES ═══ */
.center { text-align: center; }
.mt-s { margin-top: 10px; } .mt-m { margin-top: 22px; } .mt-l { margin-top: 38px; }
.mb-m { margin-bottom: 22px; }
.muted { color: var(--text-3); font-size: 12.5px; }
.sec-title { font-size: clamp(21px,3vw,27px); font-weight: 800; letter-spacing: -.8px; margin-bottom: 8px; }
.sec-sub { color: var(--text-2); font-size: 14.5px; margin-bottom: 26px; max-width: 60ch; }
[hidden] { display: none !important; }
.is-hidden { display: none !important; }
