:root {
  /* Brand */
  --color-primary:          #0066cc;
  --color-primary-focus:    #0071e3;
  --color-primary-on-dark:  #2997ff;

  /* Text */
  --color-ink:              #1d1d1f;
  --color-body:             #1d1d1f;
  --color-body-on-dark:     #ffffff;
  --color-ink-muted-80:     #333333;
  --color-ink-muted-48:     #7a7a7a;

  /* Surface */
  --color-canvas:           #ffffff;
  --color-canvas-parchment: #f5f5f7;
  --color-surface-pearl:    #fafafc;
  --color-surface-tile-1:   #272729;
  --color-surface-black:    #000000;

  /* Lines */
  --color-divider-soft:     #f0f0f0;
  --color-hairline:         #e0e0e0;
  --color-border-soft:      rgba(0, 0, 0, 0.08);
  --color-border-card:      rgba(0, 0, 0, 0.04);

  --color-on-primary:       #ffffff;
  --color-on-dark:          #ffffff;

  --shadow-product:         rgba(0, 0, 0, 0.22) 3px 5px 30px 0;

  --font-display: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Inter", system-ui, sans-serif;
  --font-text:    "SF Pro Text",    -apple-system, BlinkMacSystemFont, "Inter", system-ui, sans-serif;

  --radius-sm:    8px;
  --radius-md:    11px;
  --radius-lg:    18px;
  --radius-pill:  9999px;

  --space-section: 80px;
}

/* ============================================================
   RESET & BASE
============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-text);
  color: var(--color-ink);
  background: var(--color-canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.374px;
  overflow-x: hidden;
}
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
button, .pressable { transition: transform 120ms ease; }
button:active, .pressable:active { transform: scale(0.95); }

/* ============================================================
   LAYOUT — full-bleed tiles, edge-to-edge color sections
============================================================ */
.tile {
  width: 100%;
  padding: var(--space-section) 24px;
}
.tile--light     { background: var(--color-canvas); }
.tile--parchment { background: var(--color-canvas-parchment); }
.tile--dark      { background: var(--color-surface-tile-1); color: var(--color-on-dark); }

.container {
  max-width: 980px;
  margin: 0 auto;
}
.container-wide {
  max-width: 1080px;
  margin: 0 auto;
}

/* ============================================================
   SCROLL REVEAL — subtle fade + 30px slide-up
============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 700ms ease, transform 700ms ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.delay-1 { transition-delay: 80ms; }
.delay-2 { transition-delay: 160ms; }
.delay-3 { transition-delay: 240ms; }
.delay-4 { transition-delay: 320ms; }
.delay-5 { transition-delay: 400ms; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================================
   APPLE-STYLE ANIMATIONS
============================================================ */

/* Hero — word-by-word reveal with blur fade (iPhone hero intro) */
.hero-name .word {
  display: inline-block;
  opacity: 0;
  filter: blur(8px);
  transform: translateY(24px);
  transition: opacity 900ms cubic-bezier(0.22, 1, 0.36, 1),
              filter 900ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
}
.hero-name.is-in .word {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
}

/* Hero eyebrow — letter-spacing tighten on entry */
.hero-eyebrow {
  letter-spacing: 0.8em;
  opacity: 0;
  transition: letter-spacing 1200ms cubic-bezier(0.22, 1, 0.36, 1),
              opacity 800ms ease;
}
.hero-eyebrow.is-in {
  letter-spacing: 0.231px;
  opacity: 1;
}

/* Hero content scroll-linked fade & scale */
.hero-content-anim {
  will-change: transform, opacity, filter;
}

/* Photo — clip-path reveal from bottom (Apple product intro) */
.about-photo-wrap {
  overflow: visible;
  border-radius: var(--radius-lg);
  isolation: isolate;
}

/* Decorative ring — thin accent that breathes */
.about-photo-wrap::before {
  content: "";
  position: absolute;
  inset: -16px;
  border-radius: calc(var(--radius-lg) + 16px);
  border: 1px solid rgba(0, 102, 204, 0.18);
  opacity: 0;
  transform: scale(0.96);
  transition: opacity 1200ms ease 600ms, transform 1200ms cubic-bezier(0.22, 1, 0.36, 1) 600ms;
  pointer-events: none;
  z-index: 0;
}
.about-photo-wrap.is-in::before {
  opacity: 1;
  transform: scale(1);
  animation: ring-breathe 6s ease-in-out 2s infinite;
}
@keyframes ring-breathe {
  0%, 100% { transform: scale(1);    opacity: 0.9; }
  50%      { transform: scale(1.03); opacity: 0.5; }
}

/* Soft accent dot bottom-right */
.about-photo-wrap::after {
  content: "";
  position: absolute;
  bottom: -8px;
  right: -8px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-primary);
  opacity: 0;
  transform: scale(0);
  transition: opacity 600ms ease 1200ms, transform 800ms cubic-bezier(0.34, 1.56, 0.64, 1) 1200ms;
  pointer-events: none;
  z-index: 2;
}
.about-photo-wrap.is-in::after {
  opacity: 1;
  transform: scale(1);
}
.about-photo {
  position: relative;
  z-index: 1;
  clip-path: inset(100% 0 0 0);
  transform: scale(1.12);
  transition: clip-path 1400ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 700ms cubic-bezier(0.22, 1, 0.36, 1),
              filter 500ms ease,
              box-shadow 500ms ease;
  border-radius: var(--radius-lg);
  will-change: transform;
}
.about-photo-wrap.is-in .about-photo {
  clip-path: inset(0 0 0 0);
  transform: scale(1);
  animation: photo-float 7s ease-in-out 2.4s infinite;
}
@keyframes photo-float {
  0%, 100% { transform: translateY(0)    scale(1); }
  50%      { transform: translateY(-6px) scale(1); }
}
.about-photo-wrap.is-in:hover .about-photo {
  animation-play-state: paused;
  transform: translateY(-4px) scale(1.02);
  filter: brightness(1.04);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.28);
}

/* Section titles — accent underline draw-in */
.section-title {
  position: relative;
  display: block;
}
.section-title::after {
  content: "";
  display: block;
  width: 48px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
  margin: 24px auto 0;
  transform-origin: center;
  transform: scaleX(0);
  transition: transform 900ms cubic-bezier(0.22, 1, 0.36, 1) 200ms;
}
.section-title.visible::after {
  transform: scaleX(1);
}

/* Tech cards — stagger entry + continuous gentle bob + magnetic 3D hover */
.tech-card {
  transform-style: preserve-3d;
  transition: transform 400ms cubic-bezier(0.22, 1, 0.36, 1),
              border-color 200ms ease,
              box-shadow 400ms ease;
  will-change: transform;
  opacity: 0;
  animation: tech-enter 700ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes tech-enter {
  0%   { opacity: 0; transform: translateY(24px) scale(0.94); filter: blur(6px); }
  100% { opacity: 1; transform: translateY(0)    scale(1);    filter: blur(0); }
}
.tech-card:nth-child(1) { animation-delay: 0ms;   }
.tech-card:nth-child(2) { animation-delay: 80ms;  }
.tech-card:nth-child(3) { animation-delay: 160ms; }
.tech-card:nth-child(4) { animation-delay: 240ms; }
.tech-card:nth-child(5) { animation-delay: 320ms; }
.tech-card:nth-child(6) { animation-delay: 400ms; }
.tech-card:nth-child(7) { animation-delay: 480ms; }
.tech-card:nth-child(8) { animation-delay: 560ms; }

.tech-card .tech-card__icon {
  transition: transform 400ms cubic-bezier(0.22, 1, 0.36, 1);
  transform: translateZ(0);
  animation: icon-bob 5s ease-in-out infinite;
  animation-delay: var(--bob-delay, 0s);
}
@keyframes icon-bob {
  0%, 100% { transform: translate3d(0,  0,    0); }
  50%      { transform: translate3d(0, -4px, 0); }
}
.tech-card:nth-child(1) .tech-card__icon { --bob-delay: 0s;    }
.tech-card:nth-child(2) .tech-card__icon { --bob-delay: 0.4s;  }
.tech-card:nth-child(3) .tech-card__icon { --bob-delay: 0.8s;  }
.tech-card:nth-child(4) .tech-card__icon { --bob-delay: 1.2s;  }
.tech-card:nth-child(5) .tech-card__icon { --bob-delay: 1.6s;  }
.tech-card:nth-child(6) .tech-card__icon { --bob-delay: 2s;    }
.tech-card:nth-child(7) .tech-card__icon { --bob-delay: 2.4s;  }
.tech-card:nth-child(8) .tech-card__icon { --bob-delay: 2.8s;  }

.tech-card:hover {
  border-color: rgba(0, 0, 0, 0.18);
  box-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.18);
}
.tech-card:hover .tech-card__icon {
  animation-play-state: paused;
  transform: translateZ(20px) scale(1.12);
}
.tech-card:hover .tech-card__name {
  color: var(--color-primary);
}
.tech-card__name { transition: color 200ms ease; }

/* Project card — cursor spotlight */
.project-card {
  position: relative;
  isolation: isolate;
}
.project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(
    500px circle at var(--mx, 50%) var(--my, 50%),
    rgba(0, 102, 204, 0.10),
    transparent 40%
  );
  opacity: 0;
  transition: opacity 400ms ease;
  z-index: 0;
}
.project-card:hover::before {
  opacity: 1;
}
.project-card > * { position: relative; z-index: 1; }

/* Timeline — "Agora" dot pulse + line draw-in */
.timeline-item--now .timeline-year::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-primary);
  transform: translate(-50%, -50%);
  animation: dot-pulse 2.4s ease-out infinite;
  pointer-events: none;
}
@keyframes dot-pulse {
  0%   { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
  80%  { opacity: 0;   transform: translate(-50%, -50%) scale(3.2); }
  100% { opacity: 0;   transform: translate(-50%, -50%) scale(3.2); }
}
@media (max-width: 760px) {
  .timeline-item--now .timeline-year::before {
    left: 0;
    top: 8px;
    transform: none;
  }
  @keyframes dot-pulse {
    0%   { opacity: 0.5; transform: scale(1); }
    80%  { opacity: 0;   transform: scale(3.2); }
    100% { opacity: 0;   transform: scale(3.2); }
  }
}

/* Timeline year — count-up reveal */
.timeline-year[data-count] { font-variant-numeric: tabular-nums; }

/* Contact email — character cascade */
.contact-email .char {
  display: inline-block;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 600ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 600ms cubic-bezier(0.22, 1, 0.36, 1);
}
.contact-email.is-in .char { opacity: 1; transform: translateY(0); }

/* Hero scroll indicator gentle pulse */
.hero-scroll svg {
  animation: arrow-bob 1.6s ease-in-out infinite;
}
@keyframes arrow-bob {
  0%, 100% { transform: translateY(0); opacity: 0.6; }
  50%      { transform: translateY(4px); opacity: 1; }
}

/* Nav link active — subtle slide underline */
.global-nav__links a {
  position: relative;
  padding: 4px 0;
}
.global-nav__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: var(--color-primary-on-dark);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1);
}
.global-nav__links a:hover::after,
.global-nav__links a.active::after {
  transform: scaleX(1);
}

@media (prefers-reduced-motion: reduce) {
  .hero-name .word,
  .hero-eyebrow,
  .about-photo,
  .section-title::after,
  .contact-email .char {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    clip-path: none !important;
    letter-spacing: normal !important;
    transition: none !important;
  }
  .timeline-item--now .timeline-year::before { animation: none; }
  .hero-scroll svg { animation: none; }
}

/* ============================================================
   GLOBAL NAV — slim black bar (Apple signature)
============================================================ */
.global-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  color: var(--color-on-dark);
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.global-nav__inner {
  max-width: 1024px;
  width: 100%;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: -0.12px;
}
.global-nav__logo {
  color: var(--color-on-dark);
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.374px;
}
.global-nav__links {
  display: flex;
  gap: 32px;
  list-style: none;
}
.global-nav__links a {
  color: var(--color-on-dark);
  opacity: 0.8;
  transition: opacity 200ms ease;
}
.global-nav__links a:hover { opacity: 1; text-decoration: none; }

/* Hamburger toggle — only shown on small screens */
.global-nav__toggle {
  display: none;
  width: 28px;
  height: 28px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  position: relative;
  color: var(--color-on-dark);
}
.global-nav__toggle span {
  position: absolute;
  left: 4px;
  right: 4px;
  height: 1.5px;
  background: currentColor;
  border-radius: 1px;
  transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1),
              opacity 200ms ease,
              top 300ms cubic-bezier(0.22, 1, 0.36, 1);
}
.global-nav__toggle span:nth-child(1) { top: 10px; }
.global-nav__toggle span:nth-child(2) { top: 16px; }
.global-nav.is-open .global-nav__toggle span:nth-child(1) {
  top: 13px;
  transform: rotate(45deg);
}
.global-nav.is-open .global-nav__toggle span:nth-child(2) {
  top: 13px;
  transform: rotate(-45deg);
}

/* ============================================================
   BUTTONS
============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: -0.374px;
  border: none;
  border-radius: var(--radius-pill);
  padding: 11px 22px;
  cursor: pointer;
  transition: transform 200ms cubic-bezier(0.22, 1, 0.36, 1),
              background 200ms ease,
              box-shadow 200ms ease;
  min-height: 44px;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    110deg,
    transparent 40%,
    rgba(255, 255, 255, 0.22) 50%,
    transparent 60%
  );
  transform: translateX(-120%);
  transition: transform 600ms cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}
.btn-primary:hover {
  background: var(--color-primary-focus);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px -8px rgba(0, 102, 204, 0.5);
}
.btn-primary:hover::after { transform: translateX(120%); }
.btn-primary:active { transform: scale(0.96); }
.btn-primary:hover { text-decoration: none; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--color-primary);
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: -0.374px;
  border: 1px solid var(--color-primary);
  border-radius: var(--radius-pill);
  padding: 10px 21px;
  cursor: pointer;
  transition: transform 200ms cubic-bezier(0.22, 1, 0.36, 1),
              background 200ms ease,
              color 200ms ease,
              box-shadow 200ms ease;
  min-height: 44px;
  text-decoration: none;
}
.btn-secondary:hover {
  background: var(--color-primary);
  color: var(--color-on-primary);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px -8px rgba(0, 102, 204, 0.4);
}
.btn-secondary:active { transform: scale(0.96); }
.btn-secondary:hover { text-decoration: none; }

.text-link {
  color: var(--color-primary);
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: -0.374px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}
.text-link::after {
  content: "›";
  font-size: 17px;
  margin-left: 4px;
  transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1);
}
.text-link:hover { text-decoration: none; }
.text-link:hover::after { transform: translateX(6px); }

/* ============================================================
   HERO TILE
============================================================ */
#hero {
  position: relative;
  min-height: 100vh;
  padding-top: 140px;
  padding-bottom: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--color-canvas);
}

.hero-eyebrow {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 0.231px;
  color: var(--color-ink-muted-48);
  margin-bottom: 12px;
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(48px, 9vw, 96px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.005em;
  color: var(--color-ink);
  margin-bottom: 16px;
  text-wrap: balance;
}
.hero-name .accent { color: var(--color-primary); }

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.4vw, 28px);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.196px;
  color: var(--color-ink-muted-80);
  max-width: 640px;
  margin: 0 auto 40px;
}

.hero-cta-row {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.hero-socials {
  display: flex;
  gap: 24px;
  justify-content: center;
  align-items: center;
}
.hero-socials a {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-ink-muted-80);
  border-radius: var(--radius-pill);
  transition: color 200ms ease, background 200ms ease, transform 120ms ease;
}
.hero-socials a:hover {
  color: var(--color-primary);
  background: var(--color-canvas-parchment);
  text-decoration: none;
}
.hero-socials a:active { transform: scale(0.95); }
.hero-socials svg { width: 20px; height: 20px; }

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--color-ink-muted-48);
  font-family: var(--font-text);
  font-size: 12px;
  letter-spacing: -0.12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: bob 2s ease-in-out infinite;
}
.hero-scroll svg { width: 14px; height: 14px; }
@keyframes bob {
  0%, 100% { transform: translate(-50%, 0); }
  50%      { transform: translate(-50%, 6px); }
}

/* ============================================================
   SECTION HEADER (eyebrow + title, Apple tile style)
============================================================ */
.section-eyebrow {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 0.231px;
  color: var(--color-ink-muted-48);
  margin-bottom: 8px;
  text-align: center;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.005em;
  color: var(--color-ink);
  text-align: center;
  margin-bottom: 64px;
  text-wrap: balance;
}
.section-title .accent { color: var(--color-primary); }

/* ============================================================
   ABOUT
============================================================ */
#about { padding-top: var(--space-section); padding-bottom: var(--space-section); }

.about-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 72px;
  align-items: center;
  margin-bottom: 96px;
}

.about-photo-wrap {
  position: relative;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
}
.about-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top center;
  border-radius: var(--radius-lg);
  filter: drop-shadow(var(--shadow-product));
}

.about-text h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.005em;
  color: var(--color-ink);
  margin-bottom: 24px;
  text-wrap: balance;
}
.about-text p {
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: -0.374px;
  color: var(--color-ink-muted-80);
  margin-bottom: 16px;
}
.about-cta-row {
  display: flex;
  gap: 16px;
  margin-top: 32px;
  flex-wrap: wrap;
}

/* Profile */
.about-info-grid {
  display: grid;
  grid-template-columns: 1fr;
  max-width: 600px;
  margin: 0 auto;
  gap: 64px;
}
.info-block-title {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 0.231px;
  color: var(--color-ink);
  margin-bottom: 24px;
}

.info-item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-hairline);
  font-family: var(--font-text);
  font-size: 14px;
  letter-spacing: -0.224px;
}
.info-item:last-child { border-bottom: none; }
.info-label {
  color: var(--color-ink-muted-48);
  font-weight: 400;
}
.info-value {
  color: var(--color-ink);
  font-weight: 500;
}

/* Skills — tech chips (pearl capsules) */
.tech-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}
.tech-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-surface-pearl);
  color: var(--color-ink-muted-80);
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.224px;
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-pill);
  padding: 8px 14px;
  transition: border-color 200ms ease, color 200ms ease;
}
.tech-chip:hover {
  border-color: var(--color-primary-focus);
  color: var(--color-ink);
}
.tech-chip .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-primary);
}

/* Skills — thin pill bars */
.skill-bar-item { margin-bottom: 20px; }
.skill-bar-item:last-child { margin-bottom: 0; }
.skill-bar-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
  font-family: var(--font-text);
}
.skill-bar-header .label {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.374px;
  color: var(--color-ink);
}
.skill-bar-header .value {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: -0.12px;
  color: var(--color-ink-muted-48);
  font-variant-numeric: tabular-nums;
}
.skill-bar-track {
  height: 4px;
  background: var(--color-divider-soft);
  border-radius: var(--radius-pill);
  overflow: hidden;
}
.skill-bar-fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-pill);
  width: 0;
  transition: width 1200ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================================================
   TECH STACK GRID — Apple utility-card style
============================================================ */
.tech-stack {
  margin: 96px 0;
  padding-top: 64px;
  border-top: 1px solid var(--color-hairline);
}
.tech-stack-header {
  text-align: center;
  margin-bottom: 48px;
}
.tech-stack-header .section-eyebrow { margin-bottom: 8px; }
.tech-stack-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.005em;
  color: var(--color-ink);
  text-wrap: balance;
}
.tech-stack-title .accent { color: var(--color-primary); }

.tech-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  max-width: 880px;
  margin: 0 auto;
}
@media (max-width: 760px) {
  .tech-grid { grid-template-columns: repeat(2, 1fr); }
}

.tech-card {
  aspect-ratio: 1 / 1;
  background: var(--color-canvas);
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  transition: transform 200ms ease, border-color 200ms ease;
  text-decoration: none;
  cursor: pointer;
  color: inherit;
}
.tech-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 0, 0, 0.16);
}
.tech-card__icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tech-card__icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.tech-card__name {
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.224px;
  color: var(--color-ink);
  text-align: center;
}

/* ============================================================
   TIMELINE — Trajetória
============================================================ */
.timeline-wrap {
  margin-top: 96px;
  padding-top: 64px;
  border-top: 1px solid var(--color-hairline);
}
.timeline-wrap .info-block-title {
  text-align: center;
  margin-bottom: 8px;
}
.timeline-intro {
  text-align: center;
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.005em;
  color: var(--color-ink);
  margin-bottom: 64px;
  text-wrap: balance;
}
.timeline-intro .accent { color: var(--color-primary); }

.timeline-track {
  position: relative;
  max-width: 1024px;
  margin: 0 auto;
}
/* Vertical line — drawn through the year column */
.timeline-track::before {
  content: "";
  position: absolute;
  top: 16px;
  bottom: 16px;
  left: 50%;
  width: 1px;
  background: var(--color-hairline);
  transform: translateX(-0.5px);
}

.timeline-item {
  display: grid;
  grid-template-columns: 1fr 200px 1fr;
  align-items: center;
  gap: 32px;
  padding: 36px 0;
  position: relative;
}

.timeline-role {
  text-align: right;
  padding-right: 24px;
}
.timeline-role .timeline-title {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.231px;
  color: var(--color-ink);
  margin-bottom: 6px;
}
.timeline-role .timeline-sub {
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.224px;
  color: var(--color-primary);
}

.timeline-year {
  position: relative;
  text-align: center;
  font-family: var(--font-display);
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--color-ink-muted-48);
  line-height: 1;
}
/* Dot on the line, centered on the year baseline */
.timeline-year::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-canvas-parchment);
  border: 2px solid var(--color-ink-muted-48);
  transform: translate(-50%, -50%);
  transition: background 200ms ease, border-color 200ms ease, box-shadow 200ms ease;
}
.timeline-item--now .timeline-year { color: var(--color-ink); }
.timeline-item--now .timeline-year::after {
  background: var(--color-primary);
  border-color: var(--color-primary);
  box-shadow: 0 0 0 6px rgba(0, 102, 204, 0.12);
}

.timeline-desc {
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.374px;
  color: var(--color-ink-muted-80);
  padding-left: 24px;
}

@media (max-width: 760px) {
  .timeline-track::before {
    left: 20px;
  }
  .timeline-item {
    grid-template-columns: 40px 1fr;
    grid-template-areas:
      "year role"
      "year desc";
    gap: 8px 24px;
    padding: 24px 0;
    align-items: start;
  }
  .timeline-year {
    grid-area: year;
    font-size: 14px;
    text-align: left;
    color: var(--color-ink);
    font-weight: 600;
    padding-top: 2px;
  }
  .timeline-year::after {
    left: 0;
    top: 8px;
    transform: none;
  }
  .timeline-role {
    grid-area: role;
    text-align: left;
    padding-right: 0;
  }
  .timeline-desc {
    grid-area: desc;
    padding-left: 0;
    font-size: 15px;
  }
}

/* ============================================================
   PROJECTS
============================================================ */
#projects { padding-top: var(--space-section); padding-bottom: var(--space-section); }

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.project-card {
  background: var(--color-canvas);
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: grid;
  grid-template-columns: 6fr 5fr;
  transition: transform 300ms ease, border-color 300ms ease;
}
.project-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 0, 0, 0.16);
}

.project-image-wrap {
  background: var(--color-canvas-parchment);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
  min-height: 360px;
}
.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-sm);
  filter: drop-shadow(var(--shadow-product));
}
/* Capas ilustradas (SVG): cabem inteiras no quadro e usam sombra mais leve,
   porque não são screenshot e cortar a arte tira o sentido do desenho. */
.project-image--illustration {
  object-fit: contain;
  filter: drop-shadow(rgba(0, 0, 0, 0.12) 2px 4px 20px 0);
}
.project-image-placeholder {
  width: 100%;
  height: 100%;
  min-height: 260px;
  background: var(--color-canvas);
  border: 1px dashed var(--color-hairline);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--color-ink-muted-48);
  font-family: var(--font-text);
  font-size: 14px;
  letter-spacing: -0.224px;
  text-align: center;
  padding: 24px;
}
.project-image-placeholder svg {
  width: 40px;
  height: 40px;
  color: var(--color-ink-muted-48);
}

.project-info {
  padding: 40px 40px 40px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
}
@media (max-width: 900px) {
  .project-info { padding: 32px; }
}
.project-number {
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary);
}
.project-title {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.005em;
  color: var(--color-ink);
}
.project-desc {
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.374px;
  color: var(--color-ink-muted-80);
}
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.project-tag {
  display: inline-flex;
  align-items: center;
  background: transparent;
  color: var(--color-ink-muted-80);
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: -0.12px;
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-pill);
  padding: 4px 10px;
}
.project-link { margin-top: 8px; }
.project-github-link { gap: 6px; }
.project-github-link::after { content: none; }
.project-github-link svg { flex-shrink: 0; transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1); }
.project-github-link:hover svg { transform: translateY(-2px); }

.add-project-hint {
  margin-top: 32px;
  text-align: center;
  font-family: var(--font-text);
  font-size: 14px;
  letter-spacing: -0.224px;
  color: var(--color-ink-muted-48);
}

/* ============================================================
   CONTACT / FOOTER
============================================================ */
#contact {
  padding-top: var(--space-section);
  padding-bottom: var(--space-section);
  text-align: center;
}

.contact-lead {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 24px);
  font-weight: 300;
  line-height: 1.4;
  letter-spacing: 0;
  color: var(--color-ink-muted-80);
  max-width: 580px;
  margin: -32px auto 40px;
}

.contact-email {
  font-family: var(--font-display);
  font-size: clamp(28px, 4.5vw, 44px);
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--color-primary);
  display: inline-block;
  margin-bottom: 48px;
}
.contact-email:hover { text-decoration: underline; }

.contact-socials {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
.contact-socials a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-pill);
  color: var(--color-ink);
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.224px;
  transition: border-color 200ms ease, color 200ms ease, transform 120ms ease;
}
.contact-socials a:hover {
  border-color: var(--color-primary-focus);
  color: var(--color-primary);
  text-decoration: none;
}
.contact-socials a:active { transform: scale(0.96); }
.contact-socials svg { width: 16px; height: 16px; }

/* ── Contact Form ─────────────────────────────────────────── */
.contact-form {
  max-width: 560px;
  margin: 0 auto 48px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.contact-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.contact-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.contact-form__field label {
  font-family: var(--font-text);
  font-size: 13px;
  font-weight: 500;
  color: var(--color-ink-muted-80);
  letter-spacing: -0.1px;
}
.contact-form__field input,
.contact-form__field textarea {
  font-family: var(--font-text);
  font-size: 15px;
  color: var(--color-ink);
  background: var(--color-canvas);
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  outline: none;
  resize: none;
  transition: border-color 200ms ease, box-shadow 200ms ease;
  width: 100%;
  box-sizing: border-box;
}
.contact-form__field input::placeholder,
.contact-form__field textarea::placeholder {
  color: var(--color-ink-muted-48);
}
.contact-form__field input:focus,
.contact-form__field textarea:focus {
  border-color: var(--color-primary-focus);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.12);
}
.contact-form__btn {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.contact-form__btn .cf-btn-icon {
  width: 15px;
  height: 15px;
  transition: transform 200ms ease;
}
.contact-form__btn:hover .cf-btn-icon {
  transform: translate(2px, -2px);
}
.contact-form__feedback {
  font-family: var(--font-text);
  font-size: 14px;
  min-height: 20px;
  color: var(--color-ink-muted-48);
}
.contact-form__feedback.success { color: #1a8a3c; }
.contact-form__feedback.error   { color: #c0392b; }
@media (max-width: 560px) {
  .contact-form__row { grid-template-columns: 1fr; }
}

footer {
  background: var(--color-canvas-parchment);
  color: var(--color-ink-muted-48);
  padding: 24px 24px;
  font-family: var(--font-text);
  font-size: 12px;
  letter-spacing: -0.12px;
  border-top: 1px solid var(--color-hairline);
}
.footer-inner {
  max-width: 1024px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-inner a { color: var(--color-ink-muted-48); }
.footer-inner a:hover { color: var(--color-ink); text-decoration: underline; }

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 900px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .about-info-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .project-card { grid-template-columns: 1fr; }
  .project-image-wrap { min-height: 280px; padding: 32px; }
  .global-nav__links {
    position: fixed;
    top: 44px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    transition: max-height 400ms cubic-bezier(0.22, 1, 0.36, 1),
                padding 400ms cubic-bezier(0.22, 1, 0.36, 1),
                visibility 0s linear 400ms;
  }
  .global-nav.is-open .global-nav__links {
    max-height: calc(100vh - 44px);
    padding: 16px 0 32px;
    visibility: visible;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    transition: max-height 400ms cubic-bezier(0.22, 1, 0.36, 1),
                padding 400ms cubic-bezier(0.22, 1, 0.36, 1),
                visibility 0s linear 0s;
  }
  .global-nav__links li {
    width: 100%;
  }
  .global-nav__links a {
    display: block;
    font-size: 17px;
    font-weight: 400;
    letter-spacing: -0.374px;
    padding: 16px 24px;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 300ms ease, transform 300ms cubic-bezier(0.22, 1, 0.36, 1);
  }
  .global-nav.is-open .global-nav__links a {
    opacity: 0.9;
    transform: translateY(0);
  }
  .global-nav.is-open .global-nav__links li:nth-child(1) a { transition-delay: 80ms;  }
  .global-nav.is-open .global-nav__links li:nth-child(2) a { transition-delay: 140ms; }
  .global-nav.is-open .global-nav__links li:nth-child(3) a { transition-delay: 200ms; }
  .global-nav__links a::after { display: none; }
  .global-nav__toggle { display: inline-flex; align-items: center; justify-content: center; }
  .info-item { grid-template-columns: 120px 1fr; }
}
@media (max-width: 600px) {
  :root { --space-section: 60px; }
  #hero { padding-top: 100px; }
  .info-item { grid-template-columns: 1fr; gap: 4px; }
  .info-label { font-size: 12px; }
}

/* ============================================================
   PÁGINA DE DETALHE DO PROJETO
   Uma página por projeto, aberta pelo botão "Ver mais detalhes"
   do card. Reusa a paleta, os botões e as pills do portfólio,
   para o usuário sentir que continua no mesmo lugar.
============================================================ */
.project-detail { padding-top: 104px; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--color-primary);
  border-radius: var(--radius-pill);
  padding: 8px 18px;
  font-family: var(--font-text);
  font-size: 15px;
  letter-spacing: -0.2px;
  color: var(--color-primary);
  transition: background 200ms ease, color 200ms ease, transform 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.back-link:hover {
  background: var(--color-primary);
  color: var(--color-on-primary);
  text-decoration: none;
  transform: translateX(-3px);
}
.back-link svg { width: 14px; height: 14px; flex-shrink: 0; }

.detail-head { margin-top: 28px; }
.detail-title {
  font-family: var(--font-display);
  font-size: clamp(40px, 7vw, 76px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--color-ink);
  margin-top: 10px;
}

.detail-block { margin-top: 56px; }
.detail-label {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-ink);
  margin-bottom: 16px;
}
.detail-text {
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: -0.374px;
  color: var(--color-ink-muted-80);
  max-width: 78ch;
}
.detail-text + .detail-text { margin-top: 14px; }
.detail-rule {
  border: 0;
  border-top: 1px solid var(--color-divider-soft);
  margin-top: 40px;
}
.project-tag--accent {
  color: var(--color-primary);
  border-color: rgba(0, 102, 204, 0.35);
  background: rgba(0, 102, 204, 0.06);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}
.detail-tags { margin-top: 0; }

/* Galeria — imagem à esquerda, legenda à direita */
.gallery { display: flex; flex-direction: column; gap: 40px; }
.gallery-item {
  display: grid;
  grid-template-columns: 5fr 4fr;
  gap: 40px;
  align-items: center;
}
.gallery-item img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-hairline);
  background: var(--color-canvas-parchment);
}
.gallery-caption h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-ink);
  margin-bottom: 8px;
}
.gallery-caption p {
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: -0.3px;
  color: var(--color-ink-muted-80);
}

.detail-links { display: flex; flex-wrap: wrap; gap: 12px; }
.detail-links .btn-primary,
.detail-links .btn-secondary { gap: 8px; }
.detail-links svg { width: 17px; height: 17px; flex-shrink: 0; }

@media (max-width: 760px) {
  .project-detail { padding-top: 84px; }
  .gallery-item { grid-template-columns: 1fr; gap: 16px; }
  .detail-block { margin-top: 44px; }
}

/* ============================================================
   DESIGN & PROTÓTIPO — embed do Figma + notas de interação
============================================================ */
.figma-embed-wrap {
  margin-top: 40px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-hairline);
  background: var(--color-canvas);
}
.figma-embed-ratio {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
}
.figma-embed-ratio iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.proto-notes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 32px;
}
.proto-note {
  background: var(--color-canvas);
  border: 1px solid var(--color-hairline);
  border-radius: var(--radius-md);
  padding: 24px;
}
.proto-note__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.proto-note__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: 8px;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 600;
}
.proto-note__title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-ink);
}
.proto-note p {
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: -0.3px;
  color: var(--color-ink-muted-80);
}
@media (max-width: 900px) {
  .proto-notes { grid-template-columns: 1fr; }
}

/* Rodapé de ações do card do portfólio */
.project-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-top: 8px;
}
.project-actions .project-link { margin-top: 0; }
.project-actions .btn-secondary { font-size: 15px; padding: 8px 18px; }

.section-lead {
  max-width: 62ch;
  margin: 28px auto 0;
  text-align: center;
  font-family: var(--font-text);
  font-size: 19px;
  line-height: 1.55;
  letter-spacing: -0.4px;
  color: var(--color-ink-muted-80);
}

/* Crédito do Inteli nos projetos acadêmicos com empresa parceira.
   Fica logo abaixo do título porque o contexto (projeto real, com cliente real)
   é parte do valor do projeto, e esconder isso criaria impressão errada. */
.project-credit {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: -4px;
}
.project-credit img {
  width: 54px;
  height: auto;
  flex-shrink: 0;
}
.project-credit span {
  font-family: var(--font-text);
  font-size: 13px;
  letter-spacing: -0.1px;
  color: var(--color-ink-muted-48);
}
.detail-head .project-credit {
  margin-top: 16px;
}
.detail-head .project-credit img { width: 70px; }
.detail-head .project-credit span { font-size: 15px; }
