/* ─── Base ─────────────────────────────────────────── */
:root {
  --green-deep: #2f605c;
  --green-ink: #1d2a28;
  --green-mid: #4d8f6a;
  --green-bright: #7ed957;
  --sage-1: #eef5ee;
  --sage-2: #d8e8dc;
  --text: #353334;
  --text-soft: #5c6b64;
  --white: #ffffff;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(29, 42, 40, 0.10);
  --header-h: 64px;
  --leaf: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 20A7 7 0 0 1 9.8 6.1C15.5 5 17 4.48 19 2c1 2 2 4.18 2 8 0 5.5-4.78 10-10 10Z'/%3E%3Cpath d='M2 21c0-3 1.85-5.36 5.08-6C9.5 14.52 12 13 13 12'/%3E%3C/svg%3E");
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  font-family: 'Poppins', system-ui, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  font-weight: 300;
}

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

h1, h2, h3, h4 { font-weight: 500; color: var(--green-ink); }

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

.section { padding: 96px 0; }

.section-title {
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
  font-weight: 400;
  text-align: center;
  margin-bottom: 12px;
  position: relative;
  padding-bottom: 18px;
}
.section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 120px;
  height: 2px;
  background: linear-gradient(90deg, var(--green-deep), var(--green-bright));
}

.display {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 400;
  letter-spacing: -0.5px;
}

/* ─── Header ───────────────────────────────────────── */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 rgba(29, 42, 40, 0.08);
  z-index: 100;
}

.header-left { display: flex; align-items: center; gap: 18px; }

.brand {
  font-weight: 600;
  letter-spacing: 2px;
  font-size: 0.95rem;
  color: var(--green-ink);
  text-decoration: none;
}

.lang-switch {
  display: flex;
  gap: 2px;
  padding: 2px;
  border: 1px solid rgba(29, 42, 40, 0.16);
  border-radius: 999px;
}

.lang-btn {
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.6px;
  color: var(--text-soft);
  background: none;
  border: none;
  border-radius: 999px;
  padding: 4px 9px;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.lang-btn:hover { color: var(--green-deep); }
.lang-btn.is-active { background: var(--green-deep); color: var(--white); }

.nav { display: flex; gap: 28px; align-items: center; }

.nav a {
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 400;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color .2s, border-color .2s;
}
.nav a:hover { color: var(--green-deep); }
.nav a.active { color: var(--green-ink); font-weight: 500; border-color: var(--green-bright); }

.nav .nav-cta {
  border: 1.5px solid var(--green-deep);
  border-radius: 999px;
  padding: 6px 18px;
  color: var(--green-deep);
}
.nav .nav-cta:hover, .nav .nav-cta.active { background: var(--green-deep); color: var(--white); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--green-ink); transition: .2s; }

/* ─── Hero ─────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

/* el desenfoque viene aplicado en el archivo: pesa menos que blur() y evita
   los bordes lavados que deja filtrar un elemento a pantalla completa */
.hero-bg {
  position: absolute;
  inset: 0;
  background: url('assets/hero.jpg') center 45% / cover no-repeat;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 88% 62% at 50% 46%, rgba(29, 42, 40, 0.32), rgba(9, 17, 15, 0.9) 76%),
    linear-gradient(174deg, rgba(9, 17, 15, 0.55), rgba(47, 96, 92, 0.42) 48%, rgba(9, 17, 15, 0.78));
}

.hero-content { position: relative; z-index: 1; color: var(--white); padding: 0 24px; }

.hero-kicker {
  letter-spacing: 4px;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 24px;
  opacity: 0.9;
}

.hero h1 {
  color: var(--white);
  font-size: clamp(2.4rem, 6.5vw, 4.6rem);
  font-weight: 500;
  line-height: 1.15;
}

.hero .grad {
  background: linear-gradient(90deg, #2e9e63, #7ed957);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-cue {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 56px;
  color: var(--white);
  text-decoration: none;
  font-size: 1rem;
  opacity: 0.9;
}
.hero-cue svg { animation: bob 2s infinite ease-in-out; }
@keyframes bob { 50% { transform: translateY(6px); } }

/* ─── Sobre mí ─────────────────────────────────────── */
.about { background: linear-gradient(135deg, var(--sage-1), var(--sage-2)); }

.about-grid {
  display: grid;
  grid-template-columns: minmax(260px, 420px) 1fr;
  gap: 64px;
  align-items: center;
}

.about-photo img { border-radius: var(--radius); box-shadow: var(--shadow); }

.about-role { margin-top: 18px; color: var(--green-deep); letter-spacing: 0.5px; }

.about-bio { margin-top: 22px; font-size: 1.08rem; }

.about-question { margin-top: 36px; font-style: italic; color: var(--text-soft); }

.chip-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; }

.chip {
  display: inline-block;
  padding: 8px 20px;
  border: 1.5px solid var(--green-ink);
  border-radius: 999px;
  color: var(--green-ink);
  text-decoration: none;
  font-size: 0.92rem;
  transition: background .2s, color .2s;
}
a.chip:hover { background: var(--green-ink); color: var(--white); }
.chip-static { cursor: default; }

.about-contact-label { margin-top: 36px; font-style: italic; color: var(--text-soft); }

.social-row { display: flex; gap: 22px; margin-top: 12px; }
.social-row a { color: var(--green-ink); transition: color .2s, transform .2s; }
.social-row a:hover { color: var(--green-deep); transform: translateY(-2px); }

/* ─── Formación ────────────────────────────────────── */
.formacion { background: var(--white); }

.course-list {
  max-width: 640px;
  margin: 40px auto 90px;
  display: grid;
  gap: 18px;
}

.course-card {
  display: block;
  width: 100%;
  font-family: inherit;
  border: none;
  cursor: default;
  text-align: center;
  background: linear-gradient(135deg, var(--sage-1), #e4efe6);
  border-radius: var(--radius);
  padding: 26px 32px;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 2px 10px rgba(29, 42, 40, 0.06);
  transition: transform .2s, box-shadow .2s;
}
button.course-card { cursor: zoom-in; }
.course-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.course-card h3 { font-size: 1rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.3px; }
.course-card p { margin-top: 4px; color: var(--text-soft); font-size: 0.95rem; }
.course-card .year { display: inline-block; margin-top: 6px; color: var(--green-deep); font-weight: 500; }

.pub-grid {
  margin-top: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 24px;
}

.pub-card {
  background: var(--white);
  border: 1px solid rgba(29, 42, 40, 0.08);
  border-radius: var(--radius);
  padding: 18px;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 2px 10px rgba(29, 42, 40, 0.05);
  transition: transform .2s, box-shadow .2s;
}
.pub-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.pub-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(29, 42, 40, 0.08);
  background: #f4f7f4;
}
.pub-card h3 { font-size: 0.98rem; font-weight: 600; margin-top: 14px; line-height: 1.4; }
.pub-card p { font-size: 0.88rem; font-style: italic; color: var(--text-soft); margin-top: 6px; }

.btn-row { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; margin: 44px 0 104px; }

.btn {
  display: inline-block;
  padding: 11px 30px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background .2s, color .2s, transform .2s;
}
.btn-outline {
  border: 1.5px solid var(--green-deep);
  color: var(--green-deep);
  background: transparent;
}
.btn-outline:hover { background: var(--green-deep); color: var(--white); }
.btn-solid {
  border: 1.5px solid var(--green-deep);
  background: var(--green-deep);
  color: var(--white);
}
.btn-solid:hover { background: var(--green-ink); border-color: var(--green-ink); }
.btn-light {
  border: 1.5px solid var(--white);
  background: var(--white);
  color: var(--green-deep);
}
.btn-light:hover { transform: translateY(-2px); }

/* ─── Trayectoria (tabs) ───────────────────────────── */
.tab-hint { text-align: center; color: var(--text-soft); font-size: 0.9rem; margin: 18px 0 26px; }

.cert-mark {
  display: inline-block;
  width: 1.05em;
  height: 1.05em;
  vertical-align: -0.2em;
  margin: 0 1px;
  background-color: var(--green-mid);
  opacity: 0.55;
  -webkit-mask: var(--leaf) center / contain no-repeat;
  mask: var(--leaf) center / contain no-repeat;
}
.cv-link:hover .cert-mark { opacity: 0.9; }

.tabs {
  background: linear-gradient(150deg, var(--sage-1), #e9f2ea);
  border-radius: 18px;
  padding: 10px 10px 26px;
  box-shadow: 0 2px 12px rgba(29, 42, 40, 0.05);
}

.tab-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid rgba(29, 42, 40, 0.1);
}

.tab-btn {
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-soft);
  background: transparent;
  border: 1.5px solid transparent;
  border-radius: 999px;
  padding: 8px 20px;
  cursor: pointer;
  transition: color .2s, background .2s, border-color .2s;
}
.tab-btn:hover { color: var(--green-deep); }
.tab-btn.active { background: var(--green-deep); color: var(--white); }

.tab-panel { display: none; padding: 26px 30px 4px; }
.tab-panel.active { display: block; animation: fadein .3s ease; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px); } }

.cv-list { list-style: none; max-width: 780px; margin: 0 auto; }
.cv-list > li {
  padding: 12px 4px 12px 24px;
  position: relative;
  font-size: 0.95rem;
  border-bottom: 1px dashed rgba(29, 42, 40, 0.12);
}
.cv-list > li:last-child { border-bottom: none; }
.cv-list > li::before { content: '•'; position: absolute; left: 6px; color: var(--green-mid); }
.cv-awards > li::before { content: ''; }

.cv-meta { display: block; font-size: 0.82rem; color: var(--text-soft); margin-top: 2px; }

.cv-link {
  font-family: inherit;
  font-size: inherit;
  font-weight: 400;
  color: var(--green-ink);
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  cursor: zoom-in;
  border-bottom: 1px solid transparent;
  transition: color .2s, border-color .2s;
}
.cv-link:hover { color: var(--green-deep); border-color: var(--green-deep); }

.cv-list-cols { max-width: none; columns: 2; column-gap: 48px; }
.cv-list-cols > li { break-inside: avoid; }

.tabs-foot { text-align: center; padding: 4px 20px 0; }
.tabs-foot-link {
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 300;
  color: var(--text-soft);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  border-bottom: 1px solid rgba(92, 107, 100, 0.35);
  transition: color .2s, border-color .2s;
}
.tabs-foot-link:hover { color: var(--green-deep); border-color: var(--green-deep); }

/* ─── Eficiencia energética ────────────────────────── */
.eficiencia { background: linear-gradient(160deg, var(--sage-2), var(--sage-1) 55%, #dcebe0); }

.ee-grid {
  margin-top: 44px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 26px;
}

.ee-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
  box-shadow: 0 2px 10px rgba(29, 42, 40, 0.06);
  transition: transform .2s, box-shadow .2s;
}
.ee-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.ee-card img {
  width: 100%;
  height: 170px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(29, 42, 40, 0.08);
  background: #f4f7f4;
}
.ee-card h3 { margin-top: 16px; font-size: 1.1rem; font-weight: 600; }
.ee-card p { margin-top: 6px; font-size: 0.92rem; color: var(--text-soft); }

.campo { margin-top: 90px; }

.campo-grid {
  margin-top: 44px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
}

.campo-item img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: var(--shadow);
}
.campo-item figcaption { margin-top: 12px; font-weight: 500; color: var(--green-ink); text-align: center; }

/* ─── Obras ────────────────────────────────────────── */
.obras { background: var(--white); }

.obras-intro { text-align: center; font-style: italic; color: var(--text-soft); margin-top: 30px; }
.obras-intro a { color: var(--green-deep); }

.chips-skills { justify-content: center; margin: 22px 0 10px; }

.obra-card {
  margin-top: 44px;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 36px;
  align-items: center;
  background: linear-gradient(140deg, var(--sage-1), #eaf3ec);
  border-radius: 18px;
  padding: 34px;
  box-shadow: 0 2px 12px rgba(29, 42, 40, 0.05);
}
.obra-card:nth-child(even) { grid-template-columns: 280px 1fr; }
.obra-card:nth-child(even) .obra-info { order: -1; }

.obra-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.obra-gallery img {
  width: 100%;
  aspect-ratio: 3 / 3.4;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(29, 42, 40, 0.14);
}
.obra-gallery figcaption {
  text-align: center;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--text-soft);
  margin-top: 8px;
}

.obra-info h3 { font-size: 1.5rem; font-weight: 600; font-style: italic; }
.obra-info .obra-tipo { font-style: italic; font-size: 1.05rem; color: var(--green-deep); margin-bottom: 14px; }
.obra-info p { font-size: 0.95rem; }

/* ─── Contacto ─────────────────────────────────────── */
.contacto {
  background: radial-gradient(circle at 20% 0%, var(--green-deep), var(--green-ink) 75%);
  color: var(--white);
  text-align: center;
}
.contacto .display { color: var(--white); }
.contacto p { margin: 18px auto 32px; max-width: 480px; opacity: 0.85; }

.social-light { justify-content: center; margin-top: 36px; }
.social-light a { color: var(--white); opacity: 0.85; }
.social-light a:hover { opacity: 1; color: var(--green-bright); }

/* ─── Footer ───────────────────────────────────────── */
.footer {
  background: var(--green-ink);
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
  font-size: 0.82rem;
  padding: 22px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* ─── Parallax band: recorrido solar ───────────────── */
.parallax {
  position: relative;
  height: 78vh;
  min-height: 540px;
  overflow: hidden;
  background: linear-gradient(160deg, #1d332f, var(--green-deep) 60%, #3d7a60);
}

.px-layer { position: absolute; inset: -20% 0; will-change: transform; pointer-events: none; }

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.35;
}
.b1 { width: 380px; height: 380px; left: 8%; top: 10%; background: #7ed957; }
.b2 { width: 300px; height: 300px; right: 10%; top: 40%; background: #2e9e63; }
.b3 { width: 220px; height: 220px; left: 45%; bottom: -5%; background: #a8e6a1; }

/* line art de la vivienda + trayectoria solar */
.px-scene { inset: 0; }
#sunScene { width: 100%; height: 100%; }

.sc-arc {
  fill: none;
  stroke: rgba(255, 255, 255, 0.24);
  stroke-width: 1.6;
  stroke-dasharray: 2 13;
  stroke-linecap: round;
}
.sc-ground { stroke: rgba(255, 255, 255, 0.3); stroke-width: 1.6; }
.sc-house path {
  fill: none;
  stroke: rgba(255, 255, 255, 0.45);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.sc-shadow {
  fill: rgba(255, 255, 255, 0.11);
  stroke: rgba(255, 255, 255, 0.26);
  stroke-width: 1.2;
  stroke-linejoin: round;
}
.sc-rays line {
  stroke: rgba(255, 255, 255, 0.22);
  stroke-width: 1.2;
  stroke-dasharray: 2 11;
  stroke-linecap: round;
}
.sc-sun {
  fill: rgba(255, 255, 255, 0.16);
  stroke: rgba(255, 255, 255, 0.8);
  stroke-width: 2.2;
}

.px-quote {
  position: absolute;
  top: 30%;
  left: 0;
  right: 0;
  z-index: 1;
  color: var(--white);
  text-align: center;
  padding: 0 24px;
  will-change: transform;
}
.px-quote p {
  font-size: clamp(1.4rem, 3.4vw, 2.5rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.35;
  text-shadow: 0 2px 26px rgba(20, 40, 34, 0.75);
}

/* ─── Certs modal ──────────────────────────────────── */
.certs-modal[hidden], .lightbox[hidden] { display: none; }

.certs-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(20, 30, 28, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4vh 3vw;
}

.certs-dialog {
  background: var(--white);
  border-radius: 16px;
  width: min(1080px, 100%);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.certs-head {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 18px 24px;
  border-bottom: 1px solid rgba(29, 42, 40, 0.1);
}
.certs-head h3 { font-size: 1.2rem; font-weight: 600; flex: 1; }
.certs-drive { font-size: 0.88rem; color: var(--green-deep); text-decoration: none; }
.certs-drive:hover { text-decoration: underline; }
.certs-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  color: var(--text-soft);
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 8px;
}
.certs-close:hover { background: var(--sage-1); color: var(--green-ink); }

.certs-grid {
  overflow-y: auto;
  padding: 22px 24px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 18px;
}

.cert-thumb {
  background: none;
  border: 1px solid rgba(29, 42, 40, 0.1);
  border-radius: 10px;
  padding: 10px;
  font-family: inherit;
  cursor: zoom-in;
  text-align: center;
  transition: transform .15s, box-shadow .15s;
}
.cert-thumb:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.cert-thumb img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  object-position: top;
  border-radius: 6px;
  background: #f4f7f4;
}
.cert-thumb span {
  display: block;
  margin-top: 8px;
  font-size: 0.76rem;
  color: var(--text-soft);
  line-height: 1.35;
}

/* ─── Lightbox ─────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(15, 22, 20, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
}

.lb-figure {
  max-width: 92vw;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.lb-figure img {
  max-width: 92vw;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 12px 60px rgba(0, 0, 0, 0.5);
}
.lb-figure figcaption { color: rgba(255, 255, 255, 0.85); font-size: 0.95rem; text-align: center; }

.lb-close, .lb-prev, .lb-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--white);
  cursor: pointer;
  border-radius: 50%;
  width: 46px;
  height: 46px;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
}
.lb-close:hover, .lb-prev:hover, .lb-next:hover { background: rgba(255, 255, 255, 0.22); }
.lb-close { top: 20px; right: 20px; }
.lb-prev { left: 18px; top: 50%; transform: translateY(-50%); font-size: 2rem; }
.lb-next { right: 18px; top: 50%; transform: translateY(-50%); font-size: 2rem; }
.lb-prev[disabled], .lb-next[disabled] { opacity: 0.25; cursor: default; }

/* every content image is zoomable */
.zoomable { cursor: zoom-in; }

/* ─── Easter egg: dona verde ───────────────────────── */
.donut-drop {
  position: fixed;
  top: -80px;
  z-index: 500;
  font-size: 46px;
  filter: hue-rotate(90deg) saturate(1.5) brightness(1.05);
  pointer-events: none;
  animation: donut-fall linear forwards;
}
@keyframes donut-fall {
  to { transform: translateY(115vh) rotate(720deg); }
}

.donut-toast {
  position: fixed;
  left: 50%;
  bottom: 34px;
  transform: translateX(-50%) translateY(20px);
  z-index: 501;
  background: var(--green-deep);
  color: var(--white);
  padding: 12px 26px;
  border-radius: 999px;
  font-size: 0.95rem;
  box-shadow: var(--shadow);
  opacity: 0;
  transition: opacity .3s, transform .3s;
  pointer-events: none;
}
.donut-toast.show { opacity: 1; transform: translateX(-50%); }

/* ─── Reveal animation ─────────────────────────────── */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-cue svg { animation: none; }
}

/* ─── Responsive ───────────────────────────────────── */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-photo { max-width: 380px; margin: 0 auto; }
  .obra-card, .obra-card:nth-child(even) { grid-template-columns: 1fr; }
  .obra-card:nth-child(even) .obra-info { order: 0; }
  .cv-list-cols { columns: 1; }
  .parallax { height: 50vh; min-height: 360px; }
  .px-quote { top: 11%; }
  .px-quote br { display: none; }
  .px-quote p { max-width: 24ch; margin: 0 auto; text-wrap: balance; }
}

@media (max-width: 760px) {
  .nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    background: var(--white);
    padding: 18px 32px 24px;
    border-radius: 0 0 0 var(--radius);
    box-shadow: var(--shadow);
    transform: translateX(110%);
    transition: transform .25s ease;
  }
  .nav.open { transform: none; }
  .nav a { font-size: 1.05rem; padding: 10px 0; }
  .nav-toggle { display: flex; }
  .section { padding: 72px 0; }
}
