/* =========================================================
   Hongos del Sur — sistema de diseño
   Paleta: bosque templado + madera + hongos + laboratorio limpio
   Mobile-first. Ver DESIGN.md
   ========================================================= */

:root {
  /* Neutros cálidos */
  --paper: #faf7f0;       /* fondo general, blanco cálido */
  --sand: #ece4d5;        /* beige, secciones alternas */
  --cream: #fffdf8;       /* tarjetas */
  --ink: #20211c;         /* texto principal (verde-negro cálido) */
  --ink-soft: #565a4e;    /* texto secundario */
  --line: rgba(32, 33, 28, 0.12);

  /* Bosque + madera */
  --forest: #223a2e;      /* verde bosque profundo */
  --forest-2: #2f4f3c;    /* verde bosque medio */
  --moss: #7b8a58;        /* verde musgo (acento) */
  --bark: #443528;        /* marrón corteza */
  --earth: #8a6a45;       /* tierra */
  --amber: #c07a34;       /* ámbar / terracota (acento cálido) */

  /* Oscuro estratégico */
  --dark: #1c2a22;        /* fondo oscuro verdoso */

  --wa: #25d366;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 12px 32px rgba(28, 34, 26, 0.10);
  --shadow-lg: 0 20px 50px rgba(28, 34, 26, 0.16);
  --maxw: 1140px;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

/* ===== Reset / base ===== */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: "Inter", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: "Fraunces", Georgia, serif; line-height: 1.12; font-weight: 600; letter-spacing: -0.01em; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

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

/* ===== Tipografía de apoyo ===== */
.eyebrow {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--earth);
  margin-bottom: 14px;
  display: flex; align-items: center; gap: 8px;
}
.eyebrow--light { color: #cbb98f; }
.eyebrow__num { color: var(--amber); font-weight: 600; }
.eyebrow--light .eyebrow__num { color: var(--moss); }

.lead { font-size: 1.12rem; color: var(--ink-soft); margin-bottom: 14px; }
.lead--light { color: rgba(255, 253, 248, 0.78); }
.fineprint { font-size: 0.9rem; color: var(--ink-soft); margin-top: 16px; }
.section--forest .fineprint { color: rgba(255,253,248,0.6); }

/* ===== Botones ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 999px;
  font-weight: 600; font-size: 0.98rem; cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  border: 1.5px solid transparent;
}
.btn--primary { background: var(--forest); color: #fff; }
.btn--primary:hover { background: var(--forest-2); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn--glass { background: rgba(255,255,255,0.10); color: #fff; border-color: rgba(255,255,255,0.5); backdrop-filter: blur(4px); }
.btn--glass:hover { background: rgba(255,255,255,0.9); color: var(--ink); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--forest); border-color: var(--forest); }
.btn--ghost:hover { background: var(--forest); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(37,211,102,0.4); }

.link-cta { font-weight: 600; color: var(--forest-2); font-size: 0.95rem; transition: gap .18s ease, color .18s ease; display: inline-block; margin-top: 4px; }
.link-cta:hover { color: var(--amber); }

/* ===== Navegación ===== */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 247, 240, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.nav__logo { display: flex; align-items: center; gap: 10px; font-family: "Fraunces", serif; font-weight: 700; font-size: 1.15rem; }
.nav__logo-img { width: 40px; height: 40px; flex-shrink: 0; }
.nav__links { display: flex; align-items: center; gap: 4px; }
.nav__links a {
  padding: 8px 12px; border-radius: 999px; font-size: 0.92rem; font-weight: 500; color: var(--ink-soft);
  transition: color .15s ease, background .15s ease;
}
.nav__links a:hover { color: var(--forest); background: rgba(34,58,46,0.07); }
.nav__cta { background: var(--forest); color: #fff !important; }
.nav__cta:hover { background: var(--forest-2) !important; }
.nav__toggle {
  display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px;
}
.nav__toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s ease, opacity .2s ease; }
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Hero (sin foto, limpio) ===== */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(85% 120% at 100% 0%, rgba(34,58,46,0.10), transparent 55%),
    linear-gradient(180deg, var(--paper) 0%, var(--sand) 100%);
  border-bottom: 1px solid var(--line);
}
.hero__inner { display: grid; grid-template-columns: 1fr; gap: 28px; align-items: center; padding: 60px 20px 68px; }
.hero__eyebrow {
  font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.12em;
  font-size: 0.72rem; display: flex; align-items: center; gap: 9px; margin-bottom: 18px; color: var(--earth);
}
.hero__eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--moss); box-shadow: 0 0 0 4px rgba(123,138,88,0.25); }
.hero__title { font-size: clamp(2.4rem, 8vw, 4.2rem); font-weight: 700; letter-spacing: -0.02em; color: var(--ink); }
.hero__subtitle { font-size: 1.1rem; margin: 20px 0 30px; max-width: 540px; color: var(--ink-soft); }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero__mark { display: none; justify-self: center; }
.hero__mark img { width: min(340px, 78%); height: auto; }

/* ===== Secciones ===== */
.section { padding: 68px 0; }
.section--sand { background: var(--sand); }
.section--dark { background: var(--dark); color: #fff; }
.section--forest { background: var(--forest); color: #fff; }
.section--dark h2, .section--forest h2 { color: #fff; }

.section__head { max-width: 640px; margin-bottom: 40px; }
.section__head h2 { font-size: clamp(1.7rem, 5vw, 2.5rem); margin-bottom: 14px; }

h2 { font-size: clamp(1.7rem, 5vw, 2.5rem); margin-bottom: 16px; }

/* ===== Grid de 2 columnas ===== */
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 32px; align-items: center; }
.checklist { margin-top: 18px; display: flex; flex-direction: column; gap: 10px; }
.checklist li { position: relative; padding-left: 28px; color: var(--ink-soft); }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 7px; width: 16px; height: 16px;
  border-radius: 50%; background: var(--moss);
  -webkit-mask: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='black' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/></svg>") center / 12px no-repeat;
  mask: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='black' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/></svg>") center / 12px no-repeat;
}

/* ===== Marco de imagen ===== */
.media-frame {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  aspect-ratio: 4 / 3; background: linear-gradient(135deg, #d9cdb6, #c3b291); box-shadow: var(--shadow);
}
.media-frame img { width: 100%; height: 100%; object-fit: cover; }

/* ===== Quiénes somos ===== */
.about-intro { max-width: 760px; }

/* ===== Equipo / fundadores ===== */
.team { margin-top: 44px; }
.team__title { font-size: 1.4rem; margin-bottom: 20px; }
.team__grid { display: grid; grid-template-columns: 1fr; gap: 20px; align-items: start; }
.member { background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.member__photo { position: relative; overflow: hidden; background: linear-gradient(135deg, #d9cdb6, #c3b291); }
.member__photo--h { aspect-ratio: 3 / 2; }
.member__photo--v { aspect-ratio: 4 / 5; }
.member__photo img { width: 100%; height: 100%; object-fit: cover; }
.member figcaption { padding: 16px 18px 20px; }
.member h4 { font-family: "Fraunces", serif; font-weight: 600; font-size: 1.3rem; }
.member__role { font-family: var(--mono); font-size: 0.75rem; color: var(--moss); margin: 5px 0 9px; }
.member__bio { color: var(--ink-soft); font-size: 0.92rem; }

/* Placeholders */
.placeholder__label { display: none; }
.placeholder .placeholder__label {
  display: flex; position: absolute; inset: 0; align-items: center; justify-content: center;
  text-align: center; color: var(--bark); font-weight: 600; font-size: 0.85rem; padding: 12px;
  font-family: var(--mono);
}
.placeholder__label small { color: var(--ink-soft); font-weight: 400; }

/* ===== Especies ===== */
.species { display: grid; grid-template-columns: 1fr; gap: 18px; }
.scard {
  background: var(--cream); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); border: 1px solid var(--line);
  transition: transform .22s ease, box-shadow .22s ease;
}
.scard:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.scard__media { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: linear-gradient(135deg, #d9cdb6, #c3b291); }
.scard__media img { width: 100%; height: 100%; object-fit: cover; object-position: center; transition: transform .5s ease; }
/* Encuadres afinados por foto */
.scard__media img.pos-top { object-position: center top; }
.scard__media img.pos-bottom { object-position: center bottom; }
.scard__media img.pos-upper { object-position: center 30%; }
.scard:hover .scard__media img { transform: scale(1.06); }
.scard__body { padding: 18px 18px 20px; }
.scard__body h3 { font-size: 1.25rem; }
.latin { font-family: var(--mono); font-style: normal; font-size: 0.78rem; color: var(--moss); margin: 3px 0 10px; letter-spacing: 0.02em; }
.scard__desc { color: var(--ink-soft); font-size: 0.94rem; margin-bottom: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags span {
  font-size: 0.72rem; font-weight: 600; padding: 4px 10px; border-radius: 999px;
  background: rgba(138,106,69,0.12); color: var(--bark);
}
.tags .tag--fn { background: rgba(34,58,46,0.10); color: var(--forest-2); }

/* Nota funcional */
.fnote {
  margin-top: 34px; padding: 24px 26px; background: var(--cream);
  border: 1px solid var(--line); border-left: 4px solid var(--moss); border-radius: var(--radius);
}
.fnote p { color: var(--ink-soft); font-size: 0.95rem; }
.fnote details { margin-top: 12px; }
.fnote summary { cursor: pointer; font-weight: 600; color: var(--forest-2); font-size: 0.9rem; }
.fnote ol { margin: 12px 0 0 18px; list-style: decimal; display: flex; flex-direction: column; gap: 8px; }
.fnote li { font-size: 0.84rem; color: var(--ink-soft); }
.fnote a { color: var(--amber); font-weight: 600; }
.fnote__aviso { margin-top: 12px; font-size: 0.8rem; font-style: italic; }

/* ===== Proceso ===== */
.process { display: grid; grid-template-columns: 1fr; gap: 14px; counter-reset: none; }
.pstep {
  position: relative; padding: 22px 20px; border-radius: var(--radius);
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.10);
  transition: background .2s ease, transform .2s ease;
}
.pstep:hover { background: rgba(255,255,255,0.08); transform: translateY(-3px); }
.pstep__num { font-family: var(--mono); font-size: 0.75rem; color: var(--moss); font-weight: 600; }
.pstep__icon { display: block; color: #fff; margin: 10px 0 12px; }
.pstep__icon svg { width: 30px; height: 30px; }
.pstep h3 { font-size: 1.12rem; color: #fff; margin-bottom: 6px; }
.pstep p { color: rgba(255,255,255,0.72); font-size: 0.9rem; }

/* ===== Productos ===== */
.products { display: grid; grid-template-columns: 1fr; gap: 18px; }
.pcard {
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 24px; box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease;
}
.pcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.pcard h3 { font-size: 1.3rem; margin-bottom: 10px; }
.pcard p { color: var(--ink-soft); font-size: 0.95rem; margin-bottom: 14px; }

.b2b {
  margin-top: 26px; padding: 28px 26px; border-radius: var(--radius-lg);
  background: linear-gradient(120deg, var(--bark), var(--earth));
  color: #fff; display: flex; flex-direction: column; gap: 18px; align-items: flex-start;
}
.b2b h3 { color: #fff; font-size: 1.35rem; margin-bottom: 6px; }
.b2b p { color: rgba(255,255,255,0.85); font-size: 0.98rem; }

/* ===== Chips (I+D) ===== */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 4px; }
.chips li {
  font-family: var(--mono); font-size: 0.78rem; padding: 7px 13px; border-radius: 999px;
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.18); color: #fff;
}

/* ===== Galería ===== */
.gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; grid-auto-flow: dense; }
.gitem {
  position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 1 / 1;
  background: linear-gradient(135deg, #d9cdb6, #c3b291); box-shadow: var(--shadow);
}
.gitem img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.gitem:hover img { transform: scale(1.05); }

/* ===== Contacto ===== */
.contacto { display: grid; grid-template-columns: 1fr; gap: 34px; }
.contacto__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.contacto__meta { display: grid; gap: 16px; align-content: start; }
.contacto__meta > div { display: flex; flex-direction: column; gap: 2px; padding-bottom: 14px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.meta-k { font-family: var(--mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--moss); }
.meta-v { font-size: 1.02rem; color: #fff; }

/* ===== Footer ===== */
.footer { background: var(--dark); color: rgba(255,255,255,0.75); padding: 30px 0; border-top: 1px solid rgba(255,255,255,0.08); }
.footer__inner { display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }
.footer__brand { display: flex; align-items: center; gap: 10px; font-family: "Fraunces", serif; font-weight: 700; font-size: 1.05rem; color: #fff; }
.footer__logo-chip { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--cream); flex-shrink: 0; }
.footer__logo-chip img { width: 34px; height: 34px; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 16px; }
.footer__nav a { font-size: 0.9rem; transition: color .15s ease; }
.footer__nav a:hover { color: #fff; }
.footer__copy { font-size: 0.82rem; color: rgba(255,255,255,0.5); }

/* ===== Botón flotante WhatsApp ===== */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 90;
  width: 56px; height: 56px; border-radius: 50%; background: var(--wa); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(37,211,102,0.45); transition: transform .15s ease;
}
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }

/* ===== Reveal al hacer scroll ===== */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* =========================================================
   RESPONSIVE — de móvil hacia arriba
   ========================================================= */

/* Tablet */
@media (min-width: 620px) {
  .container { padding: 0 32px; }
  .species { grid-template-columns: repeat(2, 1fr); gap: 22px; }
  .products { grid-template-columns: repeat(3, 1fr); }
  .products--2 { grid-template-columns: repeat(2, 1fr); max-width: 760px; margin-inline: auto; }
  .process { grid-template-columns: repeat(2, 1fr); }
  .team__grid { grid-template-columns: repeat(2, 1fr); gap: 24px; max-width: 820px; }
  .gallery { grid-template-columns: repeat(3, 1fr); }
  .gitem--tall { grid-row: span 2; aspect-ratio: auto; }
  .gitem--wide { grid-column: span 2; aspect-ratio: 2 / 1; }
  .b2b { flex-direction: row; align-items: center; justify-content: space-between; }
  .b2b .btn { flex-shrink: 0; }
}

/* Desktop */
@media (min-width: 900px) {
  .section { padding: 96px 0; }
  .hero__inner { grid-template-columns: 1.05fr 0.95fr; padding: 88px 20px 92px; gap: 48px; }
  .hero__mark { display: block; }
  .grid-2 { grid-template-columns: 1fr 1fr; gap: 56px; }
  .grid-2--reverse .media-frame { order: -1; }
  .species { grid-template-columns: repeat(4, 1fr); }
  .process { grid-template-columns: repeat(3, 1fr); }
  .contacto { grid-template-columns: 1.3fr 1fr; gap: 56px; align-items: start; }
  .footer__inner { flex-direction: row; align-items: center; justify-content: space-between; }
}

@media (min-width: 1100px) {
  .process { grid-template-columns: repeat(5, 1fr); gap: 14px; }
}

/* Menú móvil */
@media (max-width: 860px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 12px 20px 20px; box-shadow: var(--shadow);
    clip-path: inset(0 0 100% 0); opacity: 0; pointer-events: none;
    transition: clip-path .3s ease, opacity .25s ease;
  }
  .nav__links.is-open { clip-path: inset(0 0 0 0); opacity: 1; pointer-events: auto; }
  .nav__links a { padding: 12px 14px; font-size: 1rem; }
  .nav__cta { text-align: center; margin-top: 6px; }
}

/* Accesibilidad: menos movimiento */
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__scroll { animation: none; }
  .scard:hover .scard__media img, .gitem:hover img { transform: none; }
}
