/* Nutridetalle · sistema visual "Pizarra y coral"
   Fondo gris niebla, texto pizarra, botones coral, detalles salvia. */

@layer reset, tokens, base, layout, components, utilities;

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/inter-latin-700-normal.woff2") format("woff2"); }

@layer tokens {
  :root {
    --fog: #f4f5f7;
    --fog-2: #e9ecf0;
    --paper: #ffffff;
    --ink: #1d2530;
    --ink-2: #3a4654;
    --mute: #5b6876;
    --slate: #26313c;
    --slate-2: #1c252e;
    --on-dark: #eef1f4;
    --on-dark-2: #b9c3cd;
    --coral: #f2785c;
    --coral-hi: #f69a82;
    --coral-ink: #b04428;
    --coral-soft: #fce6de;
    --sage: #8fb5a0;
    --sage-ink: #3f6a56;
    --sage-soft: #dfece5;
    --sky: #c9dceb;
    --line: #d6dbe2;
    --line-dark: rgba(238, 241, 244, 0.16);
    --radius: 14px;
    --radius-lg: 20px;
    --lift: 0 1px 2px rgba(29, 37, 48, 0.06), 0 14px 32px -18px rgba(29, 37, 48, 0.28);
    --pad-x: 16px;
    --sec-y: 56px;
    --sec-y-sm: 44px;
    --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --serif: Georgia, "Times New Roman", serif;
  }
  @media (min-width: 768px) { :root { --pad-x: 24px; --sec-y: 80px; --sec-y-sm: 52px; } }
  @media (min-width: 1024px) { :root { --pad-x: 32px; --sec-y: 96px; --sec-y-sm: 60px; } }
}

@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  html { -webkit-text-size-adjust: 100%; }
  body, h1, h2, h3, h4, p, figure, blockquote, dl, dd, ol, ul { margin: 0; }
  ol, ul { padding: 0; }
  img, svg { display: block; max-width: 100%; }
  img { height: auto; }
  button, input, textarea, select { font: inherit; color: inherit; }
  [hidden] { display: none !important; }
}

@layer base {
  html { scroll-behavior: smooth; scroll-padding-top: 96px; }
  body { background: var(--fog); color: var(--ink-2); font-family: var(--font); font-size: 16px; line-height: 1.65; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
  @media (min-width: 1024px) { body { font-size: 17px; } }
  h1, h2, h3, h4 { color: var(--ink); line-height: 1.18; font-weight: 700; letter-spacing: -0.015em; }
  h1 { font-size: clamp(30px, 2.3vw + 17px, 48px); line-height: 1.1; letter-spacing: -0.025em; }
  h2 { font-size: clamp(24px, 1.3vw + 16px, 36px); }
  h3 { font-size: clamp(18px, 0.4vw + 15.5px, 21px); }
  p + p { margin-top: 1em; }
  a { color: var(--coral-ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }
  a:hover { color: var(--ink); }
  :focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 3px; border-radius: 6px; }
  .on-dark :focus-visible, .on-dark:focus-visible { outline-color: var(--coral-hi); }
  ::selection { background: var(--coral-soft); color: var(--ink); }
}

@layer layout {
  .wrap { width: 100%; max-width: calc(1280px + 2 * var(--pad-x)); margin-inline: auto; padding-inline: var(--pad-x); }
  .sec { padding-block: var(--sec-y); position: relative; }
  .sec--sm { padding-block: var(--sec-y-sm); }
  .sec--fog2 { background: var(--fog-2); }
  .sec--paper { background: var(--paper); }
  .sec--ink { background: var(--slate); color: var(--on-dark-2); }
  .sec--ink h2, .sec--ink h3, .sec--ink h4 { color: var(--on-dark); }
  .sec--ink a { color: var(--coral-hi); }
  .sec--ink a:hover { color: var(--on-dark); }
  .lede { display: grid; gap: 14px; max-width: 780px; margin-bottom: 44px; }
  .lede--mid { margin-inline: auto; text-align: center; justify-items: center; }
  .lede p { color: var(--mute); }
  .sec--ink .lede p { color: var(--on-dark-2); }
  .cols { display: grid; gap: 22px; }
  @media (min-width: 720px) { .cols--2, .cols--3, .cols--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  @media (min-width: 1080px) { .cols--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .cols--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
  .split { display: grid; gap: 36px; align-items: center; }
  @media (min-width: 960px) { .split { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 64px; } }
  .bare { list-style: none; }
}

@layer components {
  /* Eyebrow */
  .eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--coral-ink); }
  .eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--coral); transform: rotate(45deg); }
  .sec--ink .eyebrow, .on-dark .eyebrow { color: var(--coral-hi); }

  /* Botones */
  .cta { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 12px 22px; border-radius: 10px; font-weight: 600; font-size: 15px; line-height: 1.2; text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: background-color .2s, border-color .2s, color .2s, transform .2s; }
  .cta svg { width: 18px; height: 18px; flex: none; }
  .cta--solid { background: var(--coral); color: var(--slate-2); }
  .cta--solid:hover { background: var(--coral-hi); color: var(--slate-2); transform: translateY(-1px); }
  .cta--line { background: transparent; color: var(--ink); border-color: var(--ink-2); }
  .cta--line:hover { background: var(--ink); color: var(--fog); }
  .on-dark .cta--line, .sec--ink .cta--line { color: var(--on-dark); border-color: rgba(238, 241, 244, 0.5); }
  .on-dark .cta--line:hover, .sec--ink .cta--line:hover { background: var(--on-dark); color: var(--slate-2); }
  .cta--edge { background: transparent; color: var(--coral-ink); border-color: var(--coral); }
  .cta--edge:hover { background: var(--coral-soft); color: var(--ink); }
  .cta--round { border-radius: 999px; padding-inline: 28px; }
  .cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

  /* Cabecera */
  .topbar { position: sticky; top: 0; z-index: 70; background: rgba(244, 245, 247, 0.97); border-bottom: 1px solid var(--line); }
  @supports (backdrop-filter: blur(8px)) { .topbar { background: rgba(244, 245, 247, 0.86); backdrop-filter: saturate(1.4) blur(12px); } }
  .topbar__row { height: 80px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
  .logo-link { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -0.02em; }
  .logo-link svg { width: 36px; height: 36px; color: var(--slate); }
  .logo-link:hover { color: var(--ink); }
  .on-dark .logo-link, .site-foot .logo-link { color: var(--on-dark); }
  .site-foot .logo-link svg { color: #ffffff; }
  .menu { display: none; }
  .menu ul { list-style: none; display: flex; gap: 4px; padding: 5px; border-radius: 999px; background: var(--fog-2); }
  .menu a { display: block; padding: 8px 16px; border-radius: 999px; color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: 15px; }
  .menu a:hover { background: var(--paper); color: var(--ink); }
  .menu a[aria-current="page"] { background: var(--slate); color: var(--on-dark); }
  .topbar__end { display: none; align-items: center; gap: 16px; }
  .tel { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; white-space: nowrap; }
  .tel svg { width: 18px; height: 18px; color: var(--coral-ink); }
  .tel:hover { color: var(--coral-ink); }
  .topbar .cta { min-height: 44px; padding: 10px 18px; font-size: 14.5px; }
  .menu-toggle { width: 46px; height: 46px; display: inline-grid; place-items: center; border-radius: 12px; background: var(--paper); border: 1px solid var(--line); color: var(--ink); cursor: pointer; }
  .menu-toggle svg { width: 22px; height: 22px; }
  .menu-toggle .is-x { display: none; }
  .menu-toggle[aria-expanded="true"] .is-bars { display: none; }
  .menu-toggle[aria-expanded="true"] .is-x { display: block; }
  .menu-sheet { background: var(--fog); border-top: 1px solid var(--line); padding: 8px 0 24px; box-shadow: 0 18px 30px -24px rgba(29, 37, 48, 0.5); }
  .menu-sheet ul { list-style: none; }
  .menu-sheet li a { display: flex; justify-content: space-between; align-items: center; padding: 15px 2px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 17px; }
  .menu-sheet li a[aria-current="page"] { color: var(--coral-ink); }
  .menu-sheet__foot { display: grid; gap: 14px; padding-top: 20px; }
  @media (min-width: 1024px) {
    .menu, .topbar__end { display: flex; }
    .menu-toggle, .menu-sheet { display: none !important; }
  }
  @media (min-width: 1024px) and (max-width: 1200px) {
    .menu a { padding: 8px 12px; }
    .topbar__end { gap: 12px; }
  }

  /* Tarjetas e iconos */
  .card { position: relative; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--lift); transition: transform .25s, box-shadow .25s; container-type: inline-size; }
  .card:hover { transform: translateY(-3px); box-shadow: 0 1px 2px rgba(29, 37, 48, 0.06), 0 24px 40px -22px rgba(29, 37, 48, 0.35); }
  .sec--ink .card { background: var(--slate-2); border-color: var(--line-dark); box-shadow: none; }
  .ico { width: 46px; height: 46px; flex: none; display: inline-grid; place-items: center; border-radius: 12px; background: var(--sage-soft); color: var(--sage-ink); }
  .ico svg { width: 23px; height: 23px; }
  .sec--ink .ico, .on-dark .ico { background: rgba(143, 181, 160, 0.16); color: var(--sage); }
  .ico--lg { width: 48px; height: 48px; }
  .num { display: inline-grid; place-items: center; align-self: flex-start; justify-self: start; min-width: 38px; height: 38px; padding: 0 10px; border-radius: 10px; background: var(--slate); color: var(--on-dark); font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
  .sec--ink .num { background: var(--coral); color: var(--slate-2); }
  .tags { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
  .tags li { font-size: 13px; font-weight: 500; padding: 4px 12px; border-radius: 6px; background: var(--coral-soft); color: #8a3420; }
  .checks { list-style: none; display: grid; gap: 10px; }
  .checks li { position: relative; padding-left: 30px; }
  .checks li::before { content: ""; position: absolute; left: 0; top: 4px; width: 20px; height: 20px; border-radius: 6px; background: var(--sage-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233f6a56' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.2 4.2L19 7'/%3E%3C/svg%3E") center / 13px no-repeat; }
  .pic { border-radius: var(--radius-lg); overflow: hidden; background: var(--fog-2); box-shadow: var(--lift); }
  .pic img { width: 100%; height: 100%; object-fit: cover; }
  .aside-note { margin-top: 30px; padding: 16px 18px; border-radius: 12px; background: var(--sage-soft); color: var(--ink-2); font-size: 14.5px; display: flex; gap: 12px; align-items: flex-start; }
  .aside-note svg { width: 20px; height: 20px; flex: none; color: var(--sage-ink); margin-top: 2px; }
  .sec--ink .aside-note { background: rgba(143, 181, 160, 0.14); color: var(--on-dark-2); }
  .sec--ink .aside-note svg { color: var(--sage); }
  .ring-deco { position: absolute; pointer-events: none; border-radius: 50%; border: 1.5px dashed rgba(176, 68, 40, 0.18); }
  .dot-deco { position: absolute; pointer-events: none; border-radius: 50%; background: radial-gradient(circle, rgba(242, 120, 92, 0.14), transparent 68%); }

  /* Cabecera de página interior */
  .page-head { position: relative; overflow: hidden; padding: calc(var(--sec-y) - 12px) 0 var(--sec-y-sm); background: linear-gradient(180deg, var(--paper), var(--fog)); border-bottom: 1px solid var(--line); }
  .page-head__grid { display: grid; gap: 18px; max-width: 900px; position: relative; }
  .page-head .intro-text { font-size: clamp(17px, 0.35vw + 15px, 19.5px); color: var(--mute); max-width: 760px; }
  .trail { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; font-size: 14px; color: var(--mute); }
  .trail li + li::before { content: "›"; margin-right: 6px; color: var(--coral-ink); }
  .trail a { color: var(--mute); }

  /* Pie */
  .site-foot { background: var(--slate-2); color: var(--on-dark-2); padding: 64px 0 26px; font-size: 15px; }
  .site-foot__grid { display: grid; gap: 34px; }
  @media (min-width: 768px) { .site-foot__grid { grid-template-columns: 1.4fr 1fr 1fr; } }
  @media (min-width: 1100px) { .site-foot__grid { grid-template-columns: 1.7fr 1fr 1fr 1.25fr; } }
  .site-foot h2 { font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--coral-hi); margin-bottom: 16px; }
  .site-foot ul { list-style: none; display: grid; gap: 10px; }
  .site-foot a { color: var(--on-dark); text-decoration: none; }
  .site-foot a:hover { color: var(--coral-hi); text-decoration: underline; }
  .site-foot address { font-style: normal; display: grid; gap: 10px; }
  .site-foot .logo-link { margin-bottom: 16px; }
  .site-foot__base { margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--line-dark); display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; justify-content: space-between; font-size: 14px; }
  .text-btn { background: none; border: 0; padding: 0; color: var(--on-dark); font-size: 14px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
  .text-btn:hover { color: var(--coral-hi); }

  /* Panel de cookies */
  .privacy-sheet { position: fixed; z-index: 120; right: 16px; bottom: 16px; width: min(430px, calc(100% - 32px)); max-height: calc(100vh - 32px); overflow: auto; background: var(--paper); color: var(--ink-2); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: 0 30px 70px -24px rgba(29, 37, 48, 0.55); padding: 24px; opacity: 0; transform: translateX(calc(100% + 40px)); visibility: hidden; transition: transform .45s cubic-bezier(.2, .8, .2, 1), opacity .3s, visibility 0s .45s; }
  .privacy-sheet.is-shown { opacity: 1; transform: none; visibility: visible; transition: transform .45s cubic-bezier(.2, .8, .2, 1), opacity .3s; }
  .privacy-sheet h2 { font-size: 20px; margin-bottom: 8px; }
  .privacy-sheet p { font-size: 14.5px; color: var(--mute); }
  .pref-list { list-style: none; display: grid; gap: 8px; margin: 16px 0 18px; }
  .pref { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; padding: 13px 14px; border-radius: 12px; background: var(--fog); }
  .pref b { display: block; color: var(--ink); font-size: 15px; }
  .pref small { display: block; color: var(--mute); font-size: 13.5px; line-height: 1.5; }
  .toggle { position: relative; flex: none; width: 46px; height: 26px; margin-top: 2px; }
  .toggle input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
  .toggle span { position: absolute; inset: 0; border-radius: 999px; background: #c5ccd5; transition: background .2s; }
  .toggle span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
  .toggle input:checked + span { background: var(--sage-ink); }
  .toggle input:checked + span::after { transform: translateX(20px); }
  .toggle input:disabled + span { opacity: .6; }
  .toggle input:focus-visible + span { outline: 3px solid var(--coral-ink); outline-offset: 2px; }
  .privacy-sheet__btns { display: flex; flex-wrap: wrap; gap: 8px; }
  .privacy-sheet__btns .cta { flex: 1 1 auto; min-height: 44px; font-size: 14.5px; padding-inline: 16px; }
  .privacy-sheet__links { margin-top: 14px; font-size: 13.5px; }
}

@layer utilities {
  .sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
  .jump { position: absolute; left: 12px; top: -64px; z-index: 200; padding: 10px 16px; border-radius: 10px; background: var(--slate); color: var(--on-dark); font-weight: 600; text-decoration: none; }
  .jump:focus { top: 12px; color: var(--on-dark); }
  .mt-0 { margin-top: 0 !important; }
  .js [data-animate] { opacity: 0; translate: 0 16px; transition: opacity .7s ease, translate .7s ease; }
  .js [data-animate].in-view { opacity: 1; translate: 0 0; }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
    .js [data-animate] { opacity: 1; translate: 0 0; }
    .card:hover, .cta:hover { transform: none; }
  }
}
