@font-face {
  font-family: Manrope;
  src: url("./assets/manrope.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
}

@font-face {
  font-family: "Space Grotesk";
  src: url("./assets/space-grotesk.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --ink: #11120f;
  --canvas: #11120f;
  --surface: #181a15;
  --surface-elevated: #20231c;
  --projects-bg: #181a15;
  --project-card-bg: #11120f;
  --project-card-hover: #141612;
  --rule: rgba(245, 245, 237, 0.1);
  --paper: #f5f5ed;
  --muted: #aeb1a5;
  --accent: #d7ff52;
  --accent-text: #d7ff52;
  --warm: #ff9f56;
  --warm-deep: #f48636;
  --about-bg: linear-gradient(180deg, #121410 0%, #151712 100%);
  --about-grid: rgba(245, 245, 237, 0.022);
  --about-ring: rgba(215, 255, 82, 0.14);
  --about-ring-warm: rgba(255, 159, 86, 0.14);
  --about-block-bg: rgba(245, 245, 237, 0.018);
  --about-block-border: rgba(245, 245, 237, 0.07);
  --glass-bg: rgba(23, 25, 20, 0.58);
  --glass-border: rgba(255, 255, 255, 0.13);
  --glass-highlight: rgba(255, 255, 255, 0.22);
  --glass-shadow: 0 12px 32px rgba(0, 0, 0, 0.32), inset 0 1px 0 var(--glass-highlight);
  --nav-active-bg: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06));
  --nav-active-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.26), 0 4px 12px rgba(0, 0, 0, 0.22);
  --hero-fade-rgb: 17, 18, 15;
  --topic-icon-even: #232b13;
  --topic-border: rgba(255, 255, 255, 0.12);
  --education-bg: #f2f3ec;
  --ease-apple: cubic-bezier(0.22, 1, 0.36, 1);
  --display: "Space Grotesk", Arial, sans-serif;
  --body: Manrope, Arial, sans-serif;
  font-family: var(--body);
  color: var(--paper);
  background: var(--canvas);
  scroll-behavior: smooth;
}

/* Apple-inspired crisp Light Mode */
html[data-theme="light"] {
  color-scheme: light;
  --canvas: #f6f6f1;
  --surface: #ffffff;
  --surface-elevated: #eceee6;
  --projects-bg: #eef0e8;
  --project-card-bg: #ffffff;
  --project-card-hover: #fbfbf8;
  --rule: rgba(17, 18, 15, 0.1);
  --paper: #141512;
  --muted: #565a4e;
  --accent-text: #4a5c08;
  --about-bg: linear-gradient(180deg, #ffffff 0%, #f5f6ef 100%);
  --about-grid: rgba(17, 18, 15, 0.028);
  --about-ring: rgba(74, 92, 8, 0.14);
  --about-ring-warm: rgba(244, 134, 54, 0.18);
  --about-block-bg: rgba(17, 18, 15, 0.02);
  --about-block-border: rgba(17, 18, 15, 0.08);
  --glass-bg: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(17, 18, 15, 0.11);
  --glass-highlight: rgba(255, 255, 255, 0.9);
  --glass-shadow: 0 10px 28px rgba(17, 18, 15, 0.09), inset 0 1px 0 var(--glass-highlight);
  --nav-active-bg: rgba(17, 18, 15, 0.08);
  --nav-active-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  --hero-fade-rgb: 246, 246, 241;
  --topic-icon-even: #eef4d6;
  --topic-border: rgba(17, 18, 15, 0.1);
  --education-bg: #eceee6;
}

*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  transition: background 0.3s ease, color 0.3s ease;
}
a { color: inherit; text-decoration: none; }
figure, dl, dd { margin: 0; }
img { display: block; max-width: 100%; }
p, h1, h2, h3, h4 { margin: 0; }
h1, h2, h3 { font-family: var(--display); }
h2 {
  font-size: clamp(2.55rem, 5.1vw, 4.9rem);
  line-height: 1.01;
  letter-spacing: -0.045em;
  font-weight: 600;
  text-wrap: balance;
}
h3 {
  font-size: clamp(1.42rem, 2.4vw, 2.25rem);
  line-height: 1.1;
  letter-spacing: -0.042em;
}
[hidden] { display: none !important; }
::selection { color: var(--ink); background: var(--accent); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 4px; }
main, section { scroll-margin-top: 96px; }

.shell { width: min(1280px, calc(100% - 104px)); margin-inline: auto; }
.section-pad { padding-block: clamp(76px, 9vw, 140px); }

.eyebrow {
  font-size: 0.72rem;
  line-height: 1.4;
  letter-spacing: 0.14em;
  font-weight: 700;
  text-transform: uppercase;
}
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--accent-text);
  margin-bottom: 18px;
}
.section-kicker::before { content: ""; width: 20px; height: 1px; background: currentColor; }
.centered-kicker { justify-content: center; }
.centered-kicker::after { content: ""; width: 20px; height: 1px; background: currentColor; }

/* Material Symbols icons (inline SVG sprite at the top of <body>) */
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.arrow {
  width: 1.2em;
  height: 1.2em;
  flex: none;
  fill: currentColor;
  transition: transform 0.28s var(--ease-apple);
}
/* ↘ arrows point down into the page, so they nudge down-right on hover */
.button:hover .arrow.arrow-down { transform: translate(2px, 2px); }
.skip-link {
  position: fixed;
  z-index: 30;
  top: 12px;
  left: 12px;
  background: var(--accent);
  color: var(--ink);
  font-weight: 700;
  padding: 12px 18px;
  border-radius: 999px;
  transform: translateY(-160%);
}
.skip-link:focus { transform: none; }

/* Scroll progress hairline */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 25;
  pointer-events: none;
  opacity: 0.75;
}
.scroll-progress-bar {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  background: var(--accent-text);
  will-change: transform;
}

/* Liquid glass reserved specifically for nav pill, theme icon & secondary action */
.glass-pill {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.095), rgba(255, 255, 255, 0.025)), var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  box-shadow: var(--glass-shadow);
  transition:
    background 0.3s var(--ease-apple),
    border-color 0.3s var(--ease-apple),
    box-shadow 0.3s var(--ease-apple),
    transform 0.26s var(--ease-apple),
    color 0.24s ease;
}

/* Header */
.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  padding-top: 16px;
  padding-bottom: 14px;
  pointer-events: none;
}
.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 -28px 0;
  z-index: -1;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(17, 18, 15, 0.92) 0%,
    rgba(17, 18, 15, 0.62) 56%,
    transparent 100%
  );
  transition: opacity 0.32s var(--ease-apple), background 0.3s ease;
}
.site-header[data-scrolled="true"]::before { opacity: 1; }

html[data-theme="light"] .site-header::before {
  background: linear-gradient(
    180deg,
    rgba(246, 246, 241, 0.9) 0%,
    rgba(246, 246, 241, 0.42) 55%,
    transparent 100%
  );
}
html[data-theme="dark"] .site-header[data-header-theme="light"]::before {
  background: linear-gradient(
    180deg,
    rgba(242, 243, 236, 0.92) 0%,
    rgba(242, 243, 236, 0.56) 58%,
    transparent 100%
  );
}
html[data-theme="dark"] .site-header[data-header-theme="lime"]::before,
html[data-theme="light"] .site-header[data-header-theme="lime"]::before {
  background: linear-gradient(
    180deg,
    rgba(215, 255, 82, 0.94) 0%,
    rgba(215, 255, 82, 0.62) 58%,
    transparent 100%
  );
}
.header-layout {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  position: relative;
}
.header-layout > * { pointer-events: auto; }

.signature {
  width: max-content;
  font: 700 1.85rem/1 var(--display);
  letter-spacing: -0.075em;
  color: var(--paper);
  display: inline-flex;
  align-items: center;
  transition: color 0.25s ease, opacity 0.2s ease;
}
.signature span { color: var(--accent-text); margin-left: 0.03em; }
.signature:hover { opacity: 0.85; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
}
.site-nav a {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--muted);
  padding: 8px 15px;
  border-radius: 999px;
  transition: color 0.24s ease, background 0.26s var(--ease-apple), box-shadow 0.26s var(--ease-apple);
}
.site-nav a:hover {
  color: var(--paper);
  background: rgba(128, 132, 118, 0.14);
}
.site-nav a.is-active {
  color: var(--paper);
  background: var(--nav-active-bg);
  box-shadow: var(--nav-active-shadow);
}

.header-actions {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

/* Circular Theme Toggle Button (Sun / Moon) */
.theme-toggle {
  width: 42px;
  height: 42px;
  padding: 0;
  display: grid;
  place-items: center;
  cursor: pointer;
  color: var(--paper);
}
.theme-toggle:hover {
  border-color: var(--accent-text);
  color: var(--accent-text);
  transform: translateY(-1px);
}
.theme-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: block; }

.header-contact {
  background: var(--accent);
  color: var(--ink);
  font-family: var(--display);
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 24px;
  border-radius: 999px;
  box-shadow: none;
  transition: background 0.24s ease, color 0.24s ease, transform 0.26s var(--ease-apple), box-shadow 0.26s ease;
}
.header-contact:hover {
  background: #e6ff84;
  transform: translateY(-1px);
}
html[data-theme="light"] .header-contact {
  box-shadow: 0 0 0 1px rgba(17, 18, 15, 0.1);
}

/* Adaptive contrast in dark mode when header floats over light/lime sections */
html[data-theme="dark"] .site-header[data-header-theme="light"] .signature,
html[data-theme="dark"] .site-header[data-header-theme="lime"] .signature { color: var(--ink); }
html[data-theme="dark"] .site-header[data-header-theme="light"] .signature span,
html[data-theme="dark"] .site-header[data-header-theme="lime"] .signature span { color: #4a570e; }
html[data-theme="dark"] .site-header[data-header-theme="light"] .glass-pill,
html[data-theme="dark"] .site-header[data-header-theme="lime"] .glass-pill {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02)), rgba(18, 20, 16, 0.86);
  border-color: rgba(17, 18, 15, 0.2);
  box-shadow: 0 14px 34px rgba(17, 18, 15, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
html[data-theme="dark"] .site-header[data-header-theme="light"] .header-contact,
html[data-theme="dark"] .site-header[data-header-theme="lime"] .header-contact {
  box-shadow: 0 10px 24px rgba(17, 18, 15, 0.16), 0 0 0 1px rgba(17, 18, 15, 0.15);
}
/* Over the lime contact section the lime CTA would vanish: invert it (both themes) */
.site-header[data-header-theme="lime"] .header-contact,
html[data-theme="dark"] .site-header[data-header-theme="lime"] .header-contact,
html[data-theme="light"] .site-header[data-header-theme="lime"] .header-contact {
  background: var(--ink);
  color: var(--accent);
  box-shadow: 0 10px 24px rgba(17, 18, 15, 0.22);
}
.site-header[data-header-theme="lime"] .header-contact:hover {
  background: #23261f;
  color: #f5f5ed;
}

.menu-toggle {
  display: none;
  font: 700 0.82rem var(--body);
  color: var(--paper);
  padding: 10px 15px;
  cursor: pointer;
}
.menu-bars {
  width: 12px;
  height: 7px;
  border-block: 1.5px solid currentColor;
  display: inline-block;
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  min-height: 48px;
  width: fit-content;
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 0.85rem;
  line-height: 1.35;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    background 0.26s var(--ease-apple),
    color 0.22s ease,
    border-color 0.26s var(--ease-apple),
    box-shadow 0.28s var(--ease-apple),
    transform 0.26s var(--ease-apple);
}
.button:hover { transform: translateY(-2px); }
.button:hover .arrow { transform: translate(2px, -2px); }
.button-lg { min-height: 54px; padding: 14px 30px; font-size: 0.92rem; }

.button-accent {
  background: var(--accent);
  color: var(--ink);
  box-shadow: none;
}
.button-accent:hover {
  background: #e7ff87;
  box-shadow: 0 10px 24px rgba(215, 255, 82, 0.16);
}
html[data-theme="light"] .button-accent {
  box-shadow: 0 0 0 1px rgba(17, 18, 15, 0.1);
}

.button-glass {
  color: var(--paper);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03)), var(--glass-bg);
  border-color: var(--glass-border);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  box-shadow: var(--glass-shadow);
}
.button-glass:hover {
  border-color: var(--accent-text);
  color: var(--accent-text);
}

.button-dark {
  background: var(--ink);
  color: #f5f5ed;
  box-shadow: 0 8px 20px rgba(17, 18, 15, 0.16);
}
.button-dark:hover {
  background: #23261f;
  box-shadow: 0 12px 26px rgba(17, 18, 15, 0.24);
}

.button-outline {
  background: transparent;
  color: #f5f5ed;
  border-color: rgba(255, 255, 255, 0.22);
}
.button-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Hero — Full-bleed right-side portrait touching top/right/bottom, fading ONLY left-to-right */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: clamp(640px, 100vh, 900px);
  display: flex;
  align-items: center;
  padding-block: clamp(88px, min(8.5vw, 13vh), 118px) clamp(40px, min(6vw, 7vh), 84px);
}
.hero-layout {
  position: static;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  width: min(1280px, calc(100% - 104px));
}
.hero-copy {
  position: relative;
  z-index: 3;
  max-width: 580px;
  padding-block: 18px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Ambient lime glow drifting behind the name */
.hero-glow {
  position: absolute;
  z-index: 2; /* above the portrait's fade so no seam appears at the photo edge */
  top: 8%;
  left: -12%;
  width: min(62vw, 820px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(215, 255, 82, 0.13) 0%, rgba(215, 255, 82, 0.04) 38%, transparent 68%);
  filter: blur(10px);
  pointer-events: none;
  animation: hero-glow-drift 16s ease-in-out infinite alternate;
}
/* Light mode stays clean: no green tint behind the text */
html[data-theme="light"] .hero-glow { display: none; }
@keyframes hero-glow-drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(8%, 6%, 0) scale(1.08); }
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  margin-bottom: 22px;
}

.hero h1 {
  font-size: clamp(4.7rem, 8.8vw, 8.8rem);
  font-weight: 700;
  line-height: 0.93;
  letter-spacing: -0.048em;
  margin-left: -0.055em;
}
/* Each name line rises from behind a mask */
.hero-line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.1em;
  margin-bottom: -0.1em;
}
.hero-line > span { display: inline-block; }
.hero-name-dot { color: var(--accent-text); margin-left: 0.03em; }
.has-reveal .hero-line > span {
  transform: translateY(108%);
  transition: transform 1.15s var(--ease-apple);
}
.has-reveal .hero-line:nth-child(2) > span { transition-delay: 0.12s; }
.has-reveal .hero-name.is-visible .hero-line > span { transform: none; }
.has-reveal .hero-name-dot {
  display: inline-block;
  transform: scale(0);
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.95s;
}
.has-reveal .hero-name.is-visible .hero-name-dot { transform: none; }

.hero-role {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 0.32em;
  font-family: var(--display);
  font-size: clamp(1.4rem, 2.2vw, 2rem);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.035em;
}
.hero-role-lead { color: var(--muted); }
/* Rotating role word */
.hero-rotator {
  position: relative;
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  padding-bottom: 0.08em;
  color: var(--accent-text);
  font-weight: 600;
}
.hero-rotator::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.35;
}
.hero-rotator-word {
  display: inline-block;
  transition: transform 0.55s var(--ease-apple), opacity 0.4s ease;
}
.hero-rotator-word.is-out { transform: translateY(-105%); opacity: 0; }
.hero-rotator-word.is-in { transform: translateY(105%); opacity: 0; transition: none; }

.hero-description {
  color: var(--muted);
  max-width: 40ch;
  margin-top: 16px;
  font-size: 1.02rem;
  line-height: 1.68;
}
.hero-description strong { color: var(--paper); font-weight: 600; }
.action-group { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; }
.hero .action-group { margin-top: 32px; }

/* Proof strip: three quick facts under the actions */
.hero-proof {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, auto));
  justify-content: start;
  gap: 18px clamp(22px, 3vw, 40px);
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
  max-width: 560px;
}
.hero-proof dt {
  font: 600 clamp(1.35rem, 2vw, 1.7rem)/1 var(--display);
  letter-spacing: -0.04em;
  white-space: nowrap;
}
.hero-proof dd {
  margin-top: 7px;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--muted);
  max-width: 17ch;
}

.hero-photo {
  position: absolute;
  z-index: 1;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(60vw, 880px);
  overflow: hidden;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 54% 18%;
  filter: saturate(0.86) contrast(1.04);
}
@media (min-width: 1101px) {
  /* Trim the antialiased first pixels so no light hairline shows at the photo's left edge */
  .hero-photo img { clip-path: inset(0 0 0 3px); }
}
.hero-photo::before {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 0;
  background: linear-gradient(
    90deg,
    #11120f 0%,
    #11120f 8%,
    rgba(17, 18, 15, 0.86) 22%,
    rgba(17, 18, 15, 0.42) 38%,
    transparent 56%
  );
  pointer-events: none;
}
@media (min-width: 1101px) {
  html[data-theme="light"] .hero-photo {
    width: min(50vw, 760px);
  }
}
html[data-theme="light"] .hero-photo::before {
  background: linear-gradient(
    90deg,
    rgba(17, 18, 15, 0.62) 0%,
    rgba(17, 18, 15, 0.26) 26%,
    transparent 52%
  );
}
.hero-photo::after {
  content: "";
  position: absolute;
  z-index: 2;
  inset: auto 0 0 0;
  height: 30%;
  background: linear-gradient(180deg, transparent 0%, rgba(17, 18, 15, 0.86) 100%);
  pointer-events: none;
}
.hero-photo figcaption {
  position: absolute;
  z-index: 3;
  right: clamp(28px, 4.2vw, 64px);
  bottom: clamp(24px, 3.2vw, 44px);
  text-align: right;
  font-family: var(--display);
  font-size: clamp(1.45rem, 2.3vw, 2.1rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: rgba(245, 245, 237, 0.92);
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.72);
}
/* The caption always sits on the photo's dark fade, so the bright lime reads in both themes */
.hero-photo figcaption strong { color: var(--accent); font-weight: 700; white-space: nowrap; }

/* About — Centered editorial with geometric background */
.about {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-top: 1px solid var(--rule);
  background: var(--about-bg);
}
.about-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(var(--about-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--about-grid) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 78% 72% at 50% 50%, #000 24%, transparent 82%);
}
.geo-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--about-ring);
}
.geo-ring-1 { width: 540px; height: 540px; top: -180px; left: -140px; }
.geo-ring-2 {
  width: 460px;
  height: 460px;
  bottom: -200px;
  right: -120px;
  border-color: var(--about-ring-warm);
}

.about-inner {
  max-width: 840px;
  text-align: center;
  display: grid;
  justify-items: center;
}
.about h2 {
  max-width: 16ch;
  font-size: clamp(2.55rem, 5vw, 4.7rem);
}
.about-copy {
  margin-top: 32px;
  display: grid;
  gap: 20px;
  max-width: 64ch;
  color: var(--muted);
  line-height: 1.85;
  font-size: clamp(1.04rem, 1.45vw, 1.24rem);
}
.about-copy strong { color: var(--paper); font-weight: 700; }

/* Projects — Square editorial blocks + real CRIAÊ laptop + minimal rounded pills */
.projects {
  background: var(--projects-bg);
  border-block: 1px solid var(--rule);
}

.featured {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: clamp(28px, 3.6vw, 48px);
  align-items: center;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% 18%, rgba(255, 224, 184, 0.45), transparent 52%),
    linear-gradient(135deg, #ffb475 0%, var(--warm) 52%, var(--warm-deep) 100%);
  margin-top: 38px;
  border-radius: 0;
  padding: clamp(30px, 4.5vw, 60px);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.14);
  overflow: hidden;
}
.featured-copy h3 {
  font-size: clamp(2.7rem, 4.8vw, 4.85rem);
  line-height: 0.98;
  letter-spacing: -0.055em;
}
.featured-copy p { max-width: 43ch; line-height: 1.68; }
.featured-lead { font-size: 1.1rem; font-weight: 700; margin-block: 16px 10px; }
.featured-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-top: 28px;
}
.featured-copy a:focus-visible,
.contact a:focus-visible { outline-color: var(--ink); }

/* Laptop Mockup displaying REAL CRIAÊ Creator website scroll */
.featured-stage { display: grid; place-items: center; min-width: 0; }
.laptop-mockup {
  width: 100%;
  max-width: 590px;
  filter: drop-shadow(0 28px 44px rgba(34, 17, 5, 0.36));
}
.laptop-lid {
  position: relative;
  background: linear-gradient(180deg, #2b2c29 0%, #151614 14%, #0f100e 100%);
  border-radius: 18px 18px 6px 6px;
  padding: 11px 11px 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.laptop-camera {
  position: absolute;
  top: 5px;
  left: 50%;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  transform: translateX(-50%);
  background: #2f332c;
}
.laptop-screen {
  border-radius: 10px;
  overflow: hidden;
  background: #0e0e0e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
}
.laptop-chrome {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 7px 11px;
  background: #171816;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.chrome-dots { display: flex; gap: 5px; }
.chrome-dots span { width: 7px; height: 7px; border-radius: 50%; }
.chrome-dots span:nth-child(1) { background: #ff5f57; }
.chrome-dots span:nth-child(2) { background: #febc2e; }
.chrome-dots span:nth-child(3) { background: #28c840; }
.chrome-url {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 0.64rem;
  font-weight: 700;
  color: rgba(245, 245, 237, 0.8);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.09);
}
.chrome-lock { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

.laptop-viewport {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0e0e0e;
}
.laptop-track {
  width: 100%;
  will-change: transform;
  animation: criae-real-scroll 14s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite;
}
.laptop-track img { width: 100%; height: auto; display: block; }
.laptop-mockup:hover .laptop-track,
.laptop-mockup[data-preview-motion="paused"] .laptop-track {
  animation-play-state: paused;
}

@keyframes criae-real-scroll {
  0%, 14% { transform: translateY(0%); }
  46%, 62% { transform: translateY(-52%); }
  90%, 100% { transform: translateY(0%); }
}

.glass-icon-btn {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 4;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  color: #f5f5ed;
  background: rgba(17, 18, 15, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
  transition: transform 0.24s var(--ease-apple), background 0.24s ease, border-color 0.24s ease;
}
.glass-icon-btn:hover {
  transform: scale(1.08);
  background: rgba(17, 18, 15, 0.9);
  border-color: var(--accent);
  color: var(--accent);
}
.glass-icon-btn svg { width: 13px; height: 13px; fill: currentColor; }
.preview-toggle .icon-play { display: none; }
.laptop-mockup[data-preview-motion="paused"] .preview-toggle .icon-pause { display: none; }
.laptop-mockup[data-preview-motion="paused"] .preview-toggle .icon-play { display: grid; }

.laptop-base {
  position: relative;
  height: 14px;
  width: 104%;
  margin-left: -2%;
  border-radius: 2px 2px 14px 14px;
  background: linear-gradient(180deg, #565852 0%, #2d2f2b 45%, #171815 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 10px 22px rgba(24, 12, 4, 0.35);
}
.laptop-notch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 16%;
  height: 5px;
  border-radius: 0 0 6px 6px;
  background: #1d1f1b;
}

/* Secondary Project Blocks — Square, tight, borderless minimalism */
.project-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}
.project-card {
  display: flex;
  flex-direction: column;
  background: var(--project-card-bg);
  border: 0;
  border-radius: 0;
  overflow: hidden;
  transition: background 0.3s ease;
}
.project-card:hover { background: var(--project-card-hover); }
.project-photo {
  position: relative;
  height: clamp(210px, 21.5vw, 310px);
  overflow: hidden;
}
.project-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 18, 15, 0.62) 0%, transparent 42%, rgba(17, 18, 15, 0.45) 100%);
  pointer-events: none;
}
.project-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease-apple);
}
.project-card:hover .project-photo img { transform: scale(1.04); }
.community-photo img { object-position: 50% 28%; }
.museum-photo img { object-position: center 52%; }

.project-floating-label {
  position: absolute;
  z-index: 2;
  top: 20px;
  left: 24px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.75);
}

.project-copy {
  padding: clamp(26px, 3vw, 40px);
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: start;
}
.project-copy > p {
  color: var(--muted);
  line-height: 1.72;
  max-width: 46ch;
  margin-block: 12px 26px;
}
.project-copy > .project-pill-btn { margin-top: auto; }
.project-stats {
  width: 100%;
  display: grid;
  grid-template-columns: auto auto;
  justify-content: start;
  gap: 16px 36px;
  margin-bottom: 28px;
}
.project-stats > div { padding: 0; border: 0; background: transparent; }
.project-stats dt {
  font: 700 clamp(1.65rem, 2.9vw, 2.35rem)/1 var(--display);
  letter-spacing: -0.055em;
  color: var(--accent-text);
}
.project-stats dd {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.42;
  max-width: 22ch;
}

.project-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--rule);
  border-color: color-mix(in srgb, var(--paper) 24%, transparent);
  background: transparent;
  color: var(--paper);
  font-size: 0.82rem;
  font-weight: 700;
  transition:
    background 0.24s ease,
    color 0.22s ease,
    border-color 0.24s ease,
    transform 0.24s var(--ease-apple);
}
.project-pill-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink);
  transform: translateY(-2px);
}
.project-pill-btn:hover .arrow { transform: translate(2px, -2px); }

/* Career — Centered heading + Photo background on 7-year card + Apple Photo Gallery */
.career-head {
  text-align: center;
  max-width: 760px;
  margin-inline: auto;
}
.career-bento {
  display: grid;
  grid-template-columns: 0.96fr 1.04fr;
  gap: 20px;
  margin-top: 44px;
  align-items: stretch;
}
.bento-card {
  border-radius: 26px;
  padding: clamp(28px, 3.5vw, 46px);
  background: var(--surface);
  border: 1px solid var(--rule);
}
html[data-theme="light"] .bento-card {
  box-shadow: 0 16px 38px rgba(17, 18, 15, 0.05);
}

/* 7-year card with Rio de Janeiro twilight photo background + crisp legible text */
.career-hero-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: #f5f5ed;
  border-color: rgba(255, 255, 255, 0.12);
  background: #141612;
}
.career-hero-bg {
  position: absolute;
  top: -14%;
  left: 0;
  z-index: -2;
  width: 100%;
  height: 128%; /* overscan so the parallax shift never exposes an edge */
  object-fit: cover;
  object-position: center 42%;
  filter: saturate(0.85) contrast(1.04);
  transition: transform 0.9s var(--ease-apple);
}
.career-hero-card:hover .career-hero-bg { transform: scale(1.04); }
.career-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    155deg,
    rgba(14, 15, 12, 0.82) 0%,
    rgba(14, 15, 12, 0.6) 46%,
    rgba(14, 15, 12, 0.9) 100%
  );
  pointer-events: none;
}
.career-hero-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 34px;
}
.career-metric-label,
.career-sublabel {
  color: rgba(245, 245, 237, 0.72);
  display: block;
}
.career-metric-line {
  display: flex;
  align-items: flex-end;
  gap: 18px;
  margin-top: 14px;
}
.career-metric-line strong {
  font: 700 clamp(5.8rem, 11vw, 9.2rem)/0.82 var(--display);
  letter-spacing: -0.09em;
  color: var(--accent);
  text-shadow: 0 8px 26px rgba(0, 0, 0, 0.45);
}
.career-metric-line span {
  font-family: var(--display);
  font-size: clamp(1.18rem, 1.8vw, 1.55rem);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.03em;
  padding-bottom: 6px;
  color: #f5f5ed;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.55);
}

.career-organs {
  border-top: 1px solid rgba(245, 245, 237, 0.18);
  padding-top: 22px;
}
.organ-list {
  list-style: none;
  padding: 0;
  margin: 14px 0 0;
  display: grid;
  gap: 10px;
}
.organ-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.94rem;
  font-weight: 700;
  color: #f5f5ed;
}
.organ-list li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.career-detail-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
}
.career-detail-block p {
  margin-top: 14px;
  color: var(--muted);
  line-height: 1.78;
  font-size: 1rem;
  max-width: 58ch;
}
.career-detail-block strong { color: var(--paper); font-weight: 700; }
.career-event {
  border-top: 1px solid var(--rule);
  padding-top: 26px;
}

/* Apple-style Interactive Photo Gallery for "Projetos dos quais participei" */
.career-gallery-section {
  margin-top: 56px;
}
.career-gallery-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: 26px;
}
.career-gallery-head .section-kicker { margin-bottom: 10px; }
.career-gallery-head h3 { font-size: clamp(1.55rem, 2.5vw, 2.15rem); }

.gallery-controls {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.gallery-nav-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--rule);
  background: var(--surface);
  color: var(--paper);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.22s ease, border-color 0.22s ease, color 0.22s ease, opacity 0.22s ease, transform 0.22s var(--ease-apple);
}
.gallery-nav-btn svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}
.gallery-nav-btn:hover:not(:disabled) {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink);
  transform: scale(1.05);
}
.gallery-nav-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.gallery-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 40px) / 3);
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-bottom: 6px;
}
.gallery-track::-webkit-scrollbar { display: none; }

.gallery-card {
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.gallery-media {
  aspect-ratio: 4 / 3.35;
  border-radius: 22px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--rule);
}
.gallery-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s var(--ease-apple);
}
.gallery-card:hover .gallery-media img { transform: scale(1.045); }
.gallery-caption {
  font-size: 0.93rem;
  line-height: 1.6;
  color: var(--muted);
  padding-inline: 2px;
}
.gallery-caption strong {
  color: var(--paper);
  font-weight: 700;
}

/* Education — Centered light section with equal-height white cards */
.education {
  color-scheme: light;
  background: var(--education-bg);
  color: var(--ink);
}
.education-head {
  text-align: center;
  max-width: 720px;
  margin-inline: auto;
}
.education .section-kicker { color: #4a570e; }
.education-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 48px;
  align-items: stretch;
}
.education-card {
  background: #ffffff;
  border-radius: 26px;
  padding: clamp(28px, 3.4vw, 44px);
  box-shadow: 0 18px 42px rgba(17, 18, 15, 0.055);
  display: flex;
  flex-direction: column;
}
.education-card-head { margin-bottom: 24px; }
.education-card-label { display: block; color: #5b6819; margin-bottom: 8px; }
.education-grid h3 { font-size: clamp(1.5rem, 2.2vw, 1.9rem); }

.degree-list { list-style: none; padding: 0; margin: 0; display: grid; flex: 1; align-content: start; }
.degree-list li {
  border-top: 1px solid rgba(17, 18, 15, 0.1);
  padding-block: 20px;
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: center;
  gap: 14px;
}
.degree-list li:last-child { border-bottom: 1px solid rgba(17, 18, 15, 0.1); }
.degree-num { font-family: var(--display); font-size: 0.84rem; font-weight: 700; color: #5b6819; }
.degree-type { display: block; color: #5d6153; font-size: 0.8rem; font-weight: 700; margin-bottom: 3px; }
.degree-list strong { font-family: var(--display); font-size: 1.18rem; color: var(--ink); }

.certifications details { border-top: 1px solid rgba(17, 18, 15, 0.1); }
.certifications details:last-child { border-bottom: 1px solid rgba(17, 18, 15, 0.1); }
.certifications summary {
  list-style: none;
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding-block: 14px;
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  transition: color 0.2s ease;
}
.certifications summary:hover { color: #4a570e; }
.certifications summary:focus-visible { outline-color: #4a570e; }
.certifications summary::-webkit-details-marker { display: none; }
.certifications summary::after {
  content: "+";
  font: 700 1.4rem/1 var(--display);
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}
.certifications details[open] summary::after { content: "−"; }
.certifications summary small { font-size: 0.82em; }
.count {
  margin-left: auto;
  background: #f2f3ec;
  border-radius: 50%;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  font-size: 0.78rem;
  font-weight: 700;
}
.certifications ul { color: #353a2e; padding: 0 0 18px 20px; margin: 0; line-height: 1.62; }
.certifications li + li { margin-top: 7px; }

/* Speaking & Vertical Flowchart */
.speaking-grid {
  display: grid;
  grid-template-columns: 0.94fr 1.06fr;
  gap: clamp(36px, 5.5vw, 84px);
  align-items: stretch;
}
.speaking-grid > * { min-width: 0; }
.speaking-intro { display: flex; flex-direction: column; }
.speaking h2 { text-wrap: initial; }
.speaking-intro > p:not(.eyebrow) {
  margin-top: 18px;
  color: var(--muted);
  line-height: 1.72;
  max-width: 48ch;
  font-size: 1.02rem;
}
.speaking-photo {
  margin-top: 30px;
  flex: 1;
  min-height: 340px;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--rule);
  background: var(--surface);
}
.speaking-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: grayscale(1) contrast(1.06);
}

.speaking-topics {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.speaking-topics h3 {
  font-size: clamp(1.7rem, 2.5vw, 2.2rem);
  margin-bottom: 26px;
}

/* Talk topics: a curved ribbon with round nodes, text alternating sides */
.speaking-topics { position: relative; container-type: inline-size; }
.speaking-topics h3 { text-align: center; }
.topic-ribbon {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
  z-index: 0;
}
.topic-ribbon .ribbon-band {
  fill: none;
  stroke: url(#ribbon-fill);
  stroke-width: var(--band, 22px);
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.6s var(--ease-apple);
}
.topic-ribbon .ribbon-ring {
  fill: url(#ribbon-fill);
  transform-box: fill-box;
  transform-origin: center;
  scale: 0.6;
  opacity: 0;
  transition: scale 0.7s var(--ease-apple), opacity 0.5s ease;
}
.speaking-topics.ribbon-in .ribbon-band { stroke-dashoffset: 0; }
.speaking-topics.ribbon-in .ribbon-ring { scale: 1; opacity: 1; }
.ribbon-stop-a { stop-color: #d7ff52; }
.ribbon-stop-b { stop-color: #7d9e17; }
html[data-theme="light"] .ribbon-stop-a { stop-color: #c4ec3c; }
html[data-theme="light"] .ribbon-stop-b { stop-color: #5f7a0c; }

.speaking-flow {
  --node: 66px;
  --shift: 10px;
  position: relative;
  z-index: 1;
  list-style: none;
  display: grid;
  gap: 30px;
  padding: 6px 0;
  margin: 0;
}
.speaking-flow li {
  display: grid;
  grid-template-columns: calc(var(--node) + 46px) minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: calc(var(--node) + 20px);
}
.speaking-flow li:nth-child(even) { --dir: -1; }
.topic-icon {
  position: relative;
  left: calc(var(--shift) * var(--dir, 1) * -1);
  grid-column: 1;
  grid-row: 1;
  justify-self: center;
  display: grid;
  place-items: center;
  width: var(--node);
  height: var(--node);
  border-radius: 50%;
  color: #1b1e16;
  background: radial-gradient(circle at 35% 28%, #ffffff 0%, #f4f5ef 70%, #e8eae1 100%);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.28), inset 0 -3px 8px rgba(17, 18, 15, 0.06);
  transition: transform 0.35s var(--ease-apple);
}
html[data-theme="light"] .topic-icon {
  color: #3d4a0a;
  box-shadow: 0 10px 22px rgba(46, 60, 8, 0.22), inset 0 -3px 8px rgba(17, 18, 15, 0.05);
}
.speaking-flow li:hover .topic-icon { transform: scale(1.06); }
.topic-icon svg {
  width: 44%;
  height: 44%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.topic-title {
  appearance: none;
  grid-column: 2;
  grid-row: 1;
  display: grid;
  gap: 4px;
  justify-self: start;
  max-width: 30ch;
  padding: 6px 4px;
  border: 0;
  background: none;
  border-radius: 10px;
  font-family: var(--display);
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--paper);
  text-align: left;
  cursor: pointer;
  transition: color 0.22s ease, transform 0.3s var(--ease-apple);
}
.topic-kicker {
  font-family: var(--body);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.topic-title:hover { color: var(--accent-text); transform: translateX(3px); }
.topic-title:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 4px; }

/* Wide column: centred ribbon, text alternates left / right like a winding path */
@container (min-width: 520px) {
  .speaking-flow { --node: 88px; --shift: 34px; gap: 22px; }
  .speaking-flow li {
    grid-template-columns: minmax(0, 1fr) calc(var(--node) + 2 * var(--shift) + 44px) minmax(0, 1fr);
    gap: 0;
  }
  .topic-icon { grid-column: 2; }
  .topic-title { grid-column: 3; }
  .speaking-flow li:nth-child(even) .topic-title {
    grid-column: 1;
    justify-self: end;
    text-align: right;
  }
  .speaking-flow li:nth-child(even) .topic-title:hover { transform: translateX(-3px); }
}

/* Invite CTA closes the ribbon: centred under the path, bigger and haloed */
.speaking-cta {
  position: relative;
  z-index: 1;
  margin-top: 64px;
  display: grid;
  justify-items: center;
  gap: 14px;
  text-align: center;
}
.speaking-cta .button-lg {
  min-height: 62px;
  padding: 16px 38px;
  font-size: 1.02rem;
  box-shadow:
    0 0 0 8px color-mix(in srgb, var(--accent) 22%, transparent),
    0 18px 38px color-mix(in srgb, var(--accent) 30%, transparent);
  transition: transform 0.3s var(--ease-apple), box-shadow 0.3s ease;
}
.speaking-cta .button-lg:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow:
    0 0 0 12px color-mix(in srgb, var(--accent) 26%, transparent),
    0 22px 44px color-mix(in srgb, var(--accent) 36%, transparent);
}
html[data-theme="light"] .speaking-cta .button-lg {
  box-shadow:
    0 0 0 8px rgba(125, 158, 23, 0.16),
    0 18px 36px rgba(95, 122, 12, 0.22);
}
.speaking-cta-note { font-size: 0.86rem; color: var(--muted); max-width: 32ch; }

/* Contact */
.contact {
  color-scheme: light;
  background: var(--accent);
  color: var(--ink);
}
.contact-layout {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: clamp(32px, 6vw, 92px);
  align-items: center;
  padding-block: clamp(56px, 6.8vw, 98px);
}
.contact h2 { font-size: clamp(2.9rem, 6vw, 5.8rem); }
.contact .section-kicker { color: var(--ink); margin-bottom: 12px; }
.contact p { line-height: 1.62; }
.contact-description { margin-top: 18px; max-width: 41ch; }
.contact-links { display: flex; flex-wrap: wrap; gap: 10px 12px; margin-top: 24px; }
.contact-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  background: var(--ink);
  color: var(--accent);
  box-shadow: none;
  transition: background 0.24s ease, color 0.24s ease, transform 0.24s var(--ease-apple), box-shadow 0.24s ease;
}
.contact-pill:hover {
  background: #23261f;
  color: #f5f5ed;
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(17, 18, 15, 0.18);
}
.contact-pill:hover .arrow { transform: translate(2px, -2px); }
.contact-note { margin-top: 12px; font-size: 0.74rem; font-weight: 700; color: #364116; }

.invite-form {
  color-scheme: dark;
  background: var(--ink);
  color: #f5f5ed;
  padding: clamp(24px, 3.2vw, 38px);
  border-radius: 26px;
  box-shadow: 0 20px 44px rgba(17, 18, 15, 0.2);
  display: grid;
  gap: 8px;
}
.invite-form h3 { margin-bottom: 8px; font-size: clamp(1.5rem, 2.3vw, 2rem); }
.invite-form label { font-size: 0.82rem; font-weight: 700; color: #f5f5ed; }
.invite-form :is(input, select, textarea) {
  width: 100%;
  min-height: 45px;
  padding: 10px 14px;
  color: #f5f5ed;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.15);
  font: 600 0.9rem/1.45 var(--body);
  border-radius: 14px;
  margin-bottom: 6px;
  transition: border-color 0.22s ease, background 0.22s ease;
}
.invite-form :is(input, select, textarea):focus {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.085);
}
.invite-form select option { background: #181a15; color: #f5f5ed; }
.invite-form textarea { resize: vertical; min-height: 78px; }
.invite-form textarea::placeholder { color: #9ea295; }

.form-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.form-status {
  margin-top: 6px;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(215, 255, 82, 0.1);
  border: 1px solid rgba(215, 255, 82, 0.28);
}
.invite-form { scroll-margin-top: 86px; }
.invite-form .copy-fallback {
  min-height: 0;
  margin: 2px 0 0;
  font-size: 0.8rem;
  resize: none;
}
.invite-form .form-note { font-size: 0.73rem; color: #b9bcb0; margin-top: 4px; }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); }
.footer-layout { display: flex; min-height: 88px; gap: 18px; align-items: center; }
.footer-layout > p { color: var(--muted); font-size: 0.82rem; }
.footer-top {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.83rem;
  font-weight: 700;
  color: var(--muted);
  transition: color 0.22s ease;
}
.footer-top:hover { color: var(--accent-text); }
.footer-top:hover .arrow { transform: translateY(-2px); }

/* Motion — entrance on load, scroll reveals (with variants + stagger) and soft parallax */
@keyframes header-in {
  from { opacity: 0; transform: translateY(-14px); }
  to { opacity: 1; transform: none; }
}
@keyframes nav-drop {
  from { opacity: 0; transform: translateY(-8px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.has-reveal .site-header { animation: header-in 0.9s var(--ease-apple) 0.05s both; }

.has-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.8s var(--ease-apple) var(--reveal-delay, 0ms),
    transform 0.95s var(--ease-apple) var(--reveal-delay, 0ms),
    clip-path 1.1s var(--ease-apple) var(--reveal-delay, 0ms);
}
.has-reveal [data-reveal="fade"] { transform: none; }
.has-reveal [data-reveal="left"] { transform: translateX(-32px); }
.has-reveal [data-reveal="right"] { transform: translateX(32px); }
.has-reveal [data-reveal="scale"] { transform: translateY(18px) scale(0.965); }
.has-reveal [data-reveal="clip"] {
  transform: none;
  clip-path: inset(22% 0 0 0 round 24px);
}
.has-reveal [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}
.has-reveal [data-reveal="clip"].is-visible { clip-path: inset(0 0 0 0 round 24px); }

/* Photos settle from a gentle zoom as they appear */
.has-reveal .hero-photo img,
.has-reveal .speaking-photo img {
  transform: scale(1.08);
  transition: transform 1.9s var(--ease-apple) var(--reveal-delay, 0ms);
}
.has-reveal .hero-photo.is-visible img,
.has-reveal .speaking-photo.is-visible img { transform: none; }

/* Parallax layers move with the CSS `translate` property (set in site.js) */
[data-parallax] { will-change: translate; }

@media (min-width: 1101px) {
  .hero h1 { font-size: clamp(4rem, min(8.8vw, 11.5vh), 8.8rem); }
  /* Light Mode: the photo is a hard 50% split, so text must never cross it */
  html[data-theme="light"] .hero-copy { max-width: min(580px, calc(50vw - 96px)); }
  html[data-theme="light"] .hero h1 {
    font-size: clamp(3.6rem, min(8.8vw, 11.5vh, calc((50vw - 96px) / 6.7)), 8.8rem);
  }
}

/* Responsive */
@media (max-width: 1080px) {
  .shell { width: calc(100% - 64px); }
  .featured { grid-template-columns: 1fr; }
  .laptop-mockup { max-width: 580px; }
  .gallery-track { grid-auto-columns: calc((100% - 20px) / 2); }
}

/* Hero stacks (text, then portrait) on tablets and small laptops so nothing runs under the photo */
@media (max-width: 1100px) {
  .hero {
    min-height: 0;
    display: block;
    padding-block: 92px 0;
  }
  .hero-layout {
    width: calc(100% - 64px);
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .hero-copy { padding-block: 8px 0; max-width: none; }
  .hero h1 { font-size: clamp(3.9rem, 18vw, 6.8rem); }
  .hero-glow { width: 130vw; top: -6%; left: -45%; }
  .hero-role { font-size: clamp(1.35rem, 6vw, 1.7rem); margin-top: 22px; }
  .hero-proof { margin-top: 34px; gap: 14px 22px; }
  .hero-photo {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    width: calc(100% + 64px);
    margin: 0 -32px;
    height: auto;
    aspect-ratio: 4 / 4.4;
    max-height: 600px;
  }
  .hero-photo img { object-position: 56% 18%; }
  .hero-photo::before {
    background: linear-gradient(90deg, rgba(17, 18, 15, 0.45) 0%, transparent 32%);
  }
  .hero-photo::after {
    height: 36%;
    background: linear-gradient(180deg, transparent 0%, rgba(17, 18, 15, 0.88) 100%);
  }
  .hero-photo figcaption {
    left: 20px;
    right: 20px;
    bottom: 22px;
    text-align: left;
    font-size: 1.45rem;
  }

}

@media (max-width: 860px) {
  .hero-layout { width: calc(100% - 40px); }
  .hero-photo { width: calc(100% + 40px); margin: 0 -20px; max-height: 520px; }
  .shell { width: calc(100% - 40px); }
  main, section { scroll-margin-top: 86px; }
  .header-layout { grid-template-columns: 1fr auto auto; gap: 8px; }
  .signature { font-size: 1.55rem; }
  .header-actions { grid-column: 3; grid-row: 1; gap: 8px; }
  .theme-toggle { width: 38px; height: 38px; }
  .header-contact { padding: 9px 16px; font-size: 0.88rem; }
  .menu-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    grid-column: 2;
    grid-row: 1;
    padding: 9px 13px;
  }
  /* Mobile menu: one link per row (column) instead of wrapped pills */
  .site-nav {
    grid-column: 1 / -1;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px;
    border-radius: 22px;
  }
  .menu-toggle:not([hidden]) ~ .site-nav { display: none; }
  .menu-toggle[aria-expanded="true"] ~ .site-nav {
    animation: nav-drop 0.32s var(--ease-apple) both;
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    display: flex;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    box-shadow: 0 24px 52px rgba(0, 0, 0, 0.35);
  }
  /* Opened panel is solid (no see-through), in every header contrast state */
  html[data-theme="dark"] .site-header .menu-toggle[aria-expanded="true"] ~ .site-nav {
    background: #151712;
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 24px 52px rgba(0, 0, 0, 0.55);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  html[data-theme="light"] .site-header .menu-toggle[aria-expanded="true"] ~ .site-nav {
    background: #ffffff;
    border-color: rgba(17, 18, 15, 0.1);
    box-shadow: 0 24px 52px rgba(17, 18, 15, 0.14);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .site-nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 48px;
    padding: 12px 16px;
    border-radius: 14px;
    font-size: 1rem;
  }
  .site-nav a.is-active { color: var(--paper); }
  .site-nav a.is-active::after {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-text);
  }
  .menu-toggle[aria-expanded="true"] ~ .site-nav a {
    animation: nav-drop 0.34s var(--ease-apple) both;
  }
  .menu-toggle[aria-expanded="true"] ~ .site-nav a:nth-child(2) { animation-delay: 30ms; }
  .menu-toggle[aria-expanded="true"] ~ .site-nav a:nth-child(3) { animation-delay: 60ms; }
  .menu-toggle[aria-expanded="true"] ~ .site-nav a:nth-child(4) { animation-delay: 90ms; }
  .menu-toggle[aria-expanded="true"] ~ .site-nav a:nth-child(5) { animation-delay: 120ms; }

  .about-inner { text-align: left; justify-items: start; }
  .about .centered-kicker::after,
  .education .centered-kicker::after { display: none; }
  .education-head { text-align: left; }
  .education .centered-kicker { justify-content: flex-start; }

  .career-bento,
  .education-grid,
  .speaking-grid,
  .contact-layout,
  .project-grid { grid-template-columns: 1fr; }

  .gallery-track { grid-auto-columns: 82%; gap: 14px; }
  .speaking-photo { min-height: 240px; aspect-ratio: 16 / 10; }
  .speaking-topics h3 { margin-top: 8px; }
  .speaking-cta { margin-top: 52px; }
}

@media (max-width: 420px) {
  .shell, .hero-layout { width: calc(100% - 32px); }
  .hero-photo { width: calc(100% + 32px); margin: 0 -16px; }
  .hero h1 { font-size: 3.55rem; }
  .hero-proof { gap: 12px 16px; }
  .hero-proof dt { font-size: 1.18rem; }
  .hero-proof dd { font-size: 0.72rem; }
  .header-contact { padding: 9px 13px; font-size: 0.84rem; }
  .menu-toggle { padding: 9px 11px; }
  .featured { padding: 24px 18px; border-radius: 0; }
  .laptop-lid { padding: 7px 7px 8px; border-radius: 13px 13px 4px 4px; }
  .laptop-base { height: 11px; width: 100%; margin-left: 0; }
  .glass-icon-btn { width: 34px; height: 34px; right: 7px; bottom: 7px; }
  .project-stats { grid-template-columns: 1fr; }
  .gallery-track { grid-auto-columns: 88%; }
  .form-actions { flex-direction: column; }
  .form-actions .button { width: 100%; }
  .footer-layout { flex-wrap: wrap; padding-block: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
  .has-reveal [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    clip-path: none !important;
  }
  /* The CRIAÊ preview does not animate here, so its pause control is pointless */
  .preview-toggle { display: none; }
}

/* ---------------------------------------------------------------------------
   Acabamento suave — meio-termo entre o visual Apple e o Material (Google):
   sem contornos em botões, cards, campos e seções; cantos arredondados nos blocos.
   (Divisores internos de listas continuam, para manter a leitura.)
   --------------------------------------------------------------------------- */
.glass-pill,
.button-glass,
html[data-theme] .site-header[data-header-theme] .glass-pill,
.theme-toggle:hover,
.button-glass:hover,
.glass-icon-btn,
.glass-icon-btn:hover { border-color: transparent; }
html[data-theme] .site-header .menu-toggle[aria-expanded="true"] ~ .site-nav { border-color: transparent; }

.about { border-top: 0; }
.projects { border-block: 0; }
.site-footer { border-top: 0; }
.hero-proof { border-top: 0; }

.featured { border-radius: 28px; }
.project-grid { gap: 16px; margin-top: 16px; }
.project-card { border-radius: 28px; }
.project-pill-btn {
  border-color: transparent;
  background: color-mix(in srgb, var(--paper) 8%, transparent);
}
.project-pill-btn:hover { border-color: transparent; }

.bento-card { border: 0; border-radius: 28px; }
.gallery-nav-btn { border-color: transparent; }
.gallery-nav-btn:hover:not(:disabled) { border-color: transparent; }
.gallery-media { border: 0; border-radius: 24px; }
.speaking-photo { border: 0; border-radius: 28px; }


.button-outline { border-color: transparent; background: rgba(255, 255, 255, 0.08); }
.button-outline:hover { border-color: transparent; background: rgba(255, 255, 255, 0.12); }
.invite-form :is(input, select, textarea) { border-color: transparent; background: rgba(255, 255, 255, 0.075); }
.invite-form :is(input, select, textarea):focus { border-color: var(--accent); }
.form-status { border-color: transparent; }

@media (max-width: 420px) {
  .featured { border-radius: 24px; }
}

/* Reconhecimentos (moções e honrarias), dentro da seção Formação */
.honors {
  margin-top: 24px;
  display: grid;
  gap: 24px;
  background: #ffffff;
  border-radius: 28px;
  padding: clamp(28px, 3.4vw, 44px);
  box-shadow: 0 18px 42px rgba(17, 18, 15, 0.055);
}
.honors:has(.honors-photo) {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
}
.honors-photo {
  border-radius: 22px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #f2f3ec;
}
.honors-photo img { width: 100%; height: 100%; object-fit: cover; }
.honors-head h3 { font-size: clamp(1.5rem, 2.2vw, 1.9rem); }
.honors-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.honors:has(.honors-photo) .honors-list { grid-template-columns: 1fr; }
.honors-list li {
  display: grid;
  gap: 4px;
  padding: 18px 20px;
  border-radius: 20px;
  background: #f2f3ec;
}
.honors-list strong { font-family: var(--display); font-size: 1.1rem; color: var(--ink); }
.honors-list span { font-size: 0.85rem; color: #5d6153; }

@media (max-width: 860px) {
  .honors,
  .honors:has(.honors-photo) { grid-template-columns: 1fr; }
  .honors-list { grid-template-columns: 1fr; }
}

/* Honors with photo */
.honors-body { display: grid; gap: 20px; align-content: center; }
.honors-photo { margin: 0; }
.honors-photo img { object-position: 46% 40%; }

/* Light Mode hero: same photo fade as Dark Mode, but into the light canvas */
html[data-theme="light"] .hero-photo::before {
  background: linear-gradient(
    90deg,
    rgb(var(--hero-fade-rgb)) 0%,
    rgba(var(--hero-fade-rgb), 0.86) 12%,
    rgba(var(--hero-fade-rgb), 0.42) 28%,
    transparent 46%
  );
}
html[data-theme="light"] .hero-photo::after {
  height: 34%;
  background: linear-gradient(180deg, transparent 0%, rgba(var(--hero-fade-rgb), 0.94) 100%);
}
html[data-theme="light"] .hero-photo figcaption {
  color: var(--paper);
  text-shadow: 0 2px 20px rgba(var(--hero-fade-rgb), 0.95);
}
html[data-theme="light"] .hero-photo figcaption strong { color: var(--accent-text); }
@media (max-width: 1100px) {
  html[data-theme="light"] .hero-photo::before {
    background: linear-gradient(180deg, rgb(var(--hero-fade-rgb)) 0%, transparent 24%);
  }
  html[data-theme="light"] .hero-photo::after {
    height: 38%;
    background: linear-gradient(180deg, transparent 0%, rgba(var(--hero-fade-rgb), 0.96) 100%);
  }
}
.speaking-topics h3 { position: relative; z-index: 1; margin-bottom: 58px; }
