@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&display=swap');

:root{
  --font-display: "Manrope", "Segoe UI", "Trebuchet MS", sans-serif;
  --font-body: "Manrope", "Segoe UI", "Trebuchet MS", sans-serif;
  --sky-50: #f6fdff;
  --sky-100: #e6f7ff;
  --sky-200: #c7ebff;
  --sky-300: #8fd7ff;
  --sea-500: #2cb9c7;
  --sea-600: #1f99ad;
  --sea-700: #13758c;
  --lime-500: #9adf6b;
  --sun-400: #f4d17d;
  --ember-400: #e78a47;
  --ember-500: #d46a2f;
  --ember-600: #b6531c;
  --ember-700: #8f3f14;
  --text-100:#0b2a33;
  --text-dim:#2d4f5b;
  --glass: rgba(255,255,255,.55);
  --glass-strong: rgba(255,255,255,.75);
  --glass-border: rgba(255,255,255,.85);
  --focus: #2cb9c7;
  --shadow: 0 28px 60px rgba(8,40,52,.18), 0 8px 18px rgba(8,40,52,.12);
  --radius-xl: 26px;
  --radius-lg: 18px;
  --space-5:1.25rem;
  --space-6:2.2rem;
  --space-7:3.2rem;
  --space-8:4.5rem;
  --project-row-h: clamp(460px, 62vh, 560px);
  --hero-h: clamp(720px, 110vh, 1120px);
  --bg-x: 0px;
  --bg-y: 0px;
  --bg-rot: 0deg;
  --bg-scale: 1;
  --sparkle-x: 50%;
  --sparkle-y: 50%;
  --sparkle2-x: 30%;
  --sparkle2-y: 70%;
  --bg-opacity:.22;
}

*{box-sizing:border-box}
html,body{height:100%}
html{scroll-behavior:smooth; scroll-padding-top:84px}
body{
  margin:0;
  font:16px/1.65 var(--font-body);
  color:var(--text-100);
  background: var(--sky-100);
  overflow-x:hidden;
}
body.home section{ padding-block: var(--space-7); }
body.projects section{ padding-block: var(--space-8); }
a,a:visited{color:inherit;text-decoration:none}
:focus-visible{
  outline:3px solid rgba(44,185,199,.55);
  outline-offset:2px;
}
h1,h2,h3,.brand{font-family:var(--font-display)}
.lead{font-size:1.1rem; color:var(--text-100)}
.muted{color:var(--text-dim)}
.max-65ch{max-width:65ch}

.global-bg{
  position:fixed; inset:-12%; z-index:-3; pointer-events:none;
  background:
    radial-gradient(1200px 700px at 20% 15%, rgba(143,215,255,.7), transparent 60%),
    radial-gradient(900px 620px at 85% 20%, rgba(154,223,107,.45), transparent 60%),
    radial-gradient(1000px 680px at 70% 80%, rgba(44,185,199,.45), transparent 60%),
    linear-gradient(180deg, var(--sky-50), var(--sky-100) 45%, var(--sky-200) 100%);
  background-size: 120% 120%, 130% 130%, 140% 140%, 100% 100%;
  animation: drift 140s linear infinite;
  transform: translate3d(var(--bg-x), var(--bg-y), 0) rotate(var(--bg-rot)) scale(var(--bg-scale));
  filter: saturate(112%);
}
.global-bg::before,
.global-bg::after{
  content:""; position:absolute; inset:-12%;
  background: radial-gradient(420px 260px at var(--sparkle-x) var(--sparkle-y), rgba(255,255,255,.6), transparent 70%);
  mix-blend-mode:screen; filter: blur(8px);
  animation: twinkle 30s ease-in-out infinite;
}
.global-bg::after{
  background: radial-gradient(620px 320px at var(--sparkle2-x) var(--sparkle2-y), rgba(44,185,199,.35), transparent 70%);
  animation: twinkle2 38s ease-in-out infinite;
}
.fluid-layer{
  position:fixed; inset:-12%; z-index:-2; pointer-events:none;
  display:block;
  width:124%; height:124%;
  filter: blur(1.1px) saturate(115%) contrast(1.02);
  mix-blend-mode: multiply;
  opacity:0.62;
  image-rendering: auto;
  transition: opacity .35s ease;
}
.fluid-frost{
  position:fixed; inset:-12%; z-index:-1; pointer-events:none;
  background: rgba(255,255,255,.16);
  backdrop-filter: blur(12px) saturate(110%);
  -webkit-backdrop-filter: blur(12px) saturate(110%);
}
@keyframes drift{
  0%{ background-position: 10% 10%, 85% 70%, 60% 50%, 50% 50% }
  50%{ background-position: 35% 55%, 55% 40%, 35% 60%, 50% 50% }
  100%{ background-position: 10% 10%, 85% 70%, 60% 50%, 50% 50% }
}
@keyframes twinkle{ 0%,100%{opacity:.55} 50%{opacity:.85} }
@keyframes twinkle2{ 0%,100%{opacity:.4} 50%{opacity:.7} }

.glass{
  background: linear-gradient(180deg, rgba(255,255,255,.82), rgba(255,255,255,.35));
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  position:relative;
}
.glass::after{
  content:""; position:absolute; inset:1px; border-radius:inherit;
  border:1px solid rgba(255,255,255,.5);
  pointer-events:none;
}
.liquid{ position:relative; overflow:hidden; border-radius:var(--radius-xl); isolation:isolate }
.liquid::before{
  content:""; position:absolute; inset:-35% -25% 45% -25%;
  background:
    radial-gradient(60% 40% at 15% 20%, rgba(255,255,255,.8), transparent 70%),
    linear-gradient(180deg, rgba(255,255,255,.65), rgba(255,255,255,0) 65%);
  opacity:.7; pointer-events:none; z-index:-1;
}
.liquid::after{
  content:""; position:absolute; inset:0; border-radius:inherit;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.7), inset 0 -1px 0 rgba(255,255,255,.35);
  pointer-events:none;
}

.container{ width:min(1180px,92vw); margin-inline:auto }
section{ padding-block: var(--space-7) }
h2.section-title{ font-size:clamp(2rem, 3.8vw, 2.9rem); margin:0 0 18px; letter-spacing:.2px }
#experience, #contact{ padding-block: var(--space-6) }
#experience .experience{ gap:22px }
.content{ padding: var(--space-6) }
.content p{ margin:0 0 .85rem }
.content p:last-child{ margin-bottom:0 }

header{
  position:fixed; inset-inline:0; top:0; z-index:30;
  background:linear-gradient(180deg, rgba(255,255,255,.9), rgba(255,255,255,.35));
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom:1px solid rgba(255,255,255,.7);
  box-shadow: 0 10px 24px rgba(8,40,52,.12);
}
.nav{ display:flex; align-items:center; justify-content:space-between; padding:.9rem 0 }
.brand{ display:flex; align-items:center; gap:.75rem; font-weight:800; letter-spacing:.3px; color:var(--ember-600) }
.brand-icon{
  width:50px;
  height:50px;
  display:block;
  object-fit:contain;
  filter: drop-shadow(0 4px 10px rgba(8,40,52,.18));
}
.brand span{
  display:block;
  line-height:1;
}
.nav-links{
  display:flex;
  align-items:center;
  margin-left:auto;
}
nav a{
  margin-left:1rem; padding:.45rem .7rem;
  border-radius:999px; font-weight:700; color:var(--text-100);
  transition: background .2s ease, transform .2s ease, box-shadow .25s ease;
}
nav a:hover{
  background:rgba(255,255,255,.55);
  box-shadow:0 8px 16px rgba(44,185,199,.22);
  transform:translateY(-1px);
}
nav a[aria-current="page"]{
  background: rgba(231,138,71,.22);
  box-shadow: inset 0 0 0 1px rgba(231,138,71,.35);
}
.cta{
  border:1px solid rgba(255,255,255,.95);
  padding:.55rem .95rem; border-radius:999px;
  background:linear-gradient(180deg, var(--ember-500), var(--ember-700));
  color:#fff;
  box-shadow:0 12px 22px rgba(143,63,20,.28);
}
nav a.cta,
nav a.cta:visited{ color:#fff; }
.cta:hover{
  background:linear-gradient(180deg, var(--ember-400), var(--ember-600));
  box-shadow:0 16px 28px rgba(143,63,20,.32);
}
.nav-toggle{
  display:none;
  border:0;
  background:rgba(255,255,255,.7);
  border-radius:999px;
  width:44px;
  height:44px;
  padding:10px;
  align-items:center;
  justify-content:center;
  gap:4px;
  box-shadow:0 10px 20px rgba(8,40,52,.12);
  cursor:pointer;
}
.nav-toggle span{
  display:block;
  width:18px;
  height:2px;
  background:var(--text-100);
  border-radius:999px;
}

.hero{ position:relative; padding-block:0; }
.hero .stage{
  position:sticky; top:0; display:grid; align-items:center;
  height: var(--hero-h);
  min-height: var(--hero-h);
  width:100vw;
}
.hero-canvas{
  position:absolute; inset:0; overflow:hidden;
  height: var(--hero-h);
  width:100vw;
  left:0;
  right:0;
  transform:none;
  z-index:0;
}
.hero-canvas spline-viewer{
  position:absolute; inset:0;
  display:block;
  width:100vw !important;
  min-width:100vw;
  max-width:none;
  height:100% !important;
  outline:none;
  filter: saturate(1.08) brightness(1.01);
}
spline-viewer #logo{ display:none !important; }
.hero-blur{
  position:absolute; left:0; right:0; bottom:0;
  height:10%;
  pointer-events:none;
  z-index:1;
  background: linear-gradient(180deg, rgba(246,253,255,0) 0%, rgba(246,253,255,.15) 35%, rgba(246,253,255,.55) 100%);
}
.hero-blur::before{
  content:"";
  position:absolute; inset:0;
  background: rgba(255,255,255,.03);
  backdrop-filter: blur(16px) saturate(110%);
  -webkit-backdrop-filter: blur(16px) saturate(110%);
  mask-image: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.35) 35%, rgba(0,0,0,1) 100%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.35) 35%, rgba(0,0,0,1) 100%);
}
.hero-content{ z-index:2; padding-block: var(--space-7); pointer-events:none }
.hero-card{
  border-radius:var(--radius-xl);
  padding: 2rem 2.3rem;
  border:1px solid rgba(255,255,255,.9);
  background:linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.45));
  backdrop-filter: blur(14px) saturate(140%);
  max-width: min(740px, 95vw);
  pointer-events:none;
}
.hero-card .btn{ pointer-events:auto }
.hero-title{ font-size:clamp(2.7rem,6.5vw,4.4rem); font-weight:800; line-height:1.1; margin:0 0 .3rem; text-shadow:0 12px 24px rgba(255,255,255,.6) }
.hero-sub{ font-size: clamp(1rem,2.2vw,1.25rem); color:var(--text-dim); margin:0; font-weight:600 }
.hero-actions{ margin-top:12px; display:flex; gap:10px; flex-wrap:wrap }
.chevron{
  position:absolute; bottom:22px; left:50%; translate:-50% 0;
  width:48px; height:48px; border-radius:999px; cursor:pointer;
  border:1px solid rgba(255,255,255,.9);
  background:linear-gradient(180deg, rgba(255,255,255,.9), rgba(255,255,255,.4));
  display:grid; place-items:center; color:var(--sea-700);
  box-shadow:0 10px 22px rgba(44,185,199,.25);
  z-index:3;
}
.chevron svg{ width:22px; height:22px }

#about .content{ padding: var(--space-6) }
#projects .projects{ margin-top: 18px }

.projects {
  display: flex;
  flex-direction: column;
  gap: 72px;
  margin-top: 0;
}
.project {
  display: grid;
  grid-template-columns: minmax(560px, 1.05fr) minmax(420px, 0.95fr);
  gap: 36px;
  align-items: stretch;
  justify-content: center;
  min-height: var(--project-row-h);
  transform: translateY(36px);
  opacity: 0;
  transition: transform .6s cubic-bezier(.21,.9,.24,1), opacity .6s;
}
.project.visible{ transform:translateY(0); opacity:1 }
.project.alt{ grid-template-columns: minmax(420px, 0.95fr) minmax(560px, 1.05fr) }
.media{
  background: linear-gradient(180deg, rgba(255,255,255,.45), rgba(255,255,255,.2));
  border:1px solid rgba(255,255,255,.75);
  border-radius: var(--radius-xl); overflow:hidden; position:relative;
  display:grid; place-items:center;
  height:100%;
  min-height: 340px;
  max-height: none;
  box-shadow: 0 20px 40px rgba(8,40,52,.18);
}
.media-inner{
  width: calc(100% - 20px);
  height: calc(100% - 20px);
  border-radius: calc(var(--radius-xl) - 12px);
  overflow:hidden;
  background: rgba(255,255,255,.2);
  border:1px solid rgba(255,255,255,.5);
  transform-style: preserve-3d;
  transition: transform .22s ease, filter .22s ease, box-shadow .25s ease;
}
.media:hover .media-inner{
  transform: rotateX(var(--tiltY,0deg)) rotateY(var(--tiltX,0deg)) scale(1.012);
  filter: saturate(115%);
  box-shadow: 0 16px 32px rgba(8,40,52,.25);
}
.media img{
  width:100%; height:100%; object-fit:cover; display:block;
  transition: opacity .25s ease, transform .25s ease;
}
.media img.fade{ opacity:0 }
.media img.pop{ transform: scale(1.018) }
.project .box{ padding: 22px; border-radius: var(--radius-xl); height:100% }
.project .text{
  display:flex;
  flex-direction:column;
  height:100%;
  min-height:0;
  overflow:hidden;
}
.project-body{
  display:flex;
  flex-direction:column;
  gap:16px;
  flex:1 1 auto;
  min-height:0;
  overflow:hidden;
}
.project-footer{
  margin-top:auto;
  display:flex;
  flex-direction:column;
  gap:12px;
}
.project h3{ margin:0 0 .5rem; font-size: clamp(1.5rem, 3vw, 2rem); line-height:1.32 }
.project .desc{
  font-size: 1.06rem;
  line-height: 1.72;
  color:var(--text-100);
  max-width: 62ch;
  min-height:0;
  overflow:visible;
  display:block;
  transition: opacity .28s ease, transform .28s ease;
}
.project .desc.fade-out{ opacity:0; transform: translateY(6px) }
.project .desc.fade-in{ opacity:1; transform: translateY(0) }
.thumbs{
  display:flex;
  gap:16px;
  align-items:center;
  padding-top: 6px;
  flex-wrap: wrap;
}
.thumb{
  flex: 0 0 148px; aspect-ratio: 1/1;
  width:148px; height:148px;
  border-radius: var(--radius-lg);
  border:1px solid rgba(255,255,255,.8);
  background: linear-gradient(180deg, rgba(255,255,255,.7), rgba(255,255,255,.25));
  padding:0; overflow:hidden; cursor:pointer; display:block; line-height:0;
  transition: transform .22s ease, box-shadow .25s ease, border-color .22s ease;
  box-shadow: 0 10px 20px rgba(8,40,52,.12);
}
.thumb img{ width:100%; height:100%; object-fit:cover; transition: transform .35s ease }
.thumb svg{ width:100%; height:100%; display:block }
.thumb:hover{ transform: translateY(-3px); box-shadow: 0 16px 26px rgba(8,40,52,.18); border-color: rgba(44,185,199,.45) }
.thumb:hover img{ transform: scale(1.06) }
.thumb[aria-pressed="true"]{
  border-color: rgba(44,185,199,.9);
  box-shadow: 0 0 0 2px rgba(44,185,199,.25), 0 12px 24px rgba(44,185,199,.25);
}
.swap-note{
  font-size:.92rem;
  color:var(--text-dim);
  margin-top:0;
  display:inline-block;
  padding:.35rem .7rem;
  border-radius:999px;
  background: rgba(255,255,255,.6);
  border:1px solid rgba(255,255,255,.75);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
  max-width: 40ch;
}
.all-projects-cta{
  margin-top: 28px;
  padding: 18px 22px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}
.all-projects-cta .lead{ margin:0 }
.inline-link{
  color: var(--sea-700);
  font-weight:700;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.inline-link:hover{ color: var(--sea-600) }

.page-hero{ padding-top: calc(var(--space-8) + 52px) }
body.projects .page-hero{ padding-top: calc(var(--space-8) + 84px) }
.page-hero .content{ padding: var(--space-7) }
.page-title{ font-size:clamp(2.4rem, 5vw, 3.6rem); margin:0 0 .4rem }
.page-sub{ font-size:1.1rem; color:var(--text-dim); margin:0 }

.projects-grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap:24px;
  margin-top:8px;
}
.project-tile{
  border:1px solid rgba(255,255,255,.85);
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(255,255,255,.78), rgba(255,255,255,.35));
  box-shadow: 0 16px 28px rgba(8,40,52,.12);
  overflow:hidden;
  transition: border-color .3s ease, box-shadow .3s ease;
  transform: translateZ(0);
  will-change: transform;
}
.project-tile.is-open{
  grid-column: 1 / -1;
  border-color: rgba(44,185,199,.7);
  box-shadow: 0 26px 40px rgba(8,40,52,.2);
}
.project-hit{
  width:100%;
  border:0;
  background:transparent;
  text-align:left;
  padding:16px;
  display:flex;
  flex-direction:column;
  gap:14px;
  cursor:pointer;
}
.project-tile.is-open .project-hit{
  display:grid;
  grid-template-columns: minmax(140px, 220px) 1fr;
  align-items:center;
  gap:18px;
}
.project-hit:focus-visible{
  outline:3px solid rgba(44,185,199,.45);
  outline-offset:2px;
  border-radius: calc(var(--radius-xl) - 4px);
}
.project-cover{
  border-radius:20px;
  overflow:hidden;
  aspect-ratio: 4 / 3;
  border:1px solid rgba(255,255,255,.9);
  background: rgba(255,255,255,.3);
}
.project-tile.is-open .project-cover{
  width:100%;
  max-width:220px;
}
.project-cover img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transition: transform .35s ease;
}
.project-tile:hover .project-cover img{ transform: scale(1.03) }
.project-meta{
  display:flex;
  flex-direction:column;
  gap:6px;
}
.project-kicker{
  font-size:.85rem;
  text-transform:uppercase;
  letter-spacing:.14rem;
  color:var(--sea-700);
  font-weight:800;
}
.project-title{
  margin:0;
  font-size:1.1rem;
  line-height:1.3;
  color:var(--text-100);
}
.project-detail{
  display:grid;
  grid-template-rows:0fr;
  transition: grid-template-rows .5s cubic-bezier(.21,.9,.24,1);
}
.project-detail-inner{
  overflow:hidden;
  padding:0 16px 18px;
  display:flex;
  flex-direction:column;
  gap:16px;
  opacity:0;
  transform: translateY(-6px);
  transition: opacity .3s ease, transform .45s ease;
}
.project-detail-inner::before{
  content:"";
  height:1px;
  background: rgba(255,255,255,.65);
  margin-top:2px;
}
.project-tile.is-open .project-detail{ grid-template-rows:1fr }
.project-tile.is-open .project-detail-inner{
  opacity:1;
  transform: translateY(0);
}
.project-desc{
  margin:0;
  font-size:1.05rem;
  line-height:1.75;
  color:var(--text-100);
}
.project-actions{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
}
.project-gallery{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap:12px;
}
.project-gallery .gallery-item{
  border:0;
  padding:0;
  background:transparent;
  text-align:inherit;
  cursor:pointer;
}
.project-gallery img{
  width:100%;
  aspect-ratio: 4 / 3;
  object-fit:cover;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.85);
  background: rgba(255,255,255,.35);
  box-shadow: 0 8px 16px rgba(8,40,52,.12);
  display:block;
}
.project-gallery .gallery-item:focus-visible{
  outline:3px solid rgba(44,185,199,.45);
  outline-offset:3px;
  border-radius:18px;
}

.experience{ display:flex; flex-direction:column; gap:28px }
.company-block{ display:flex; flex-direction:column; gap:14px }
.company-head{
  display:grid; grid-template-columns: 120px 1fr; gap:16px; align-items:center;
  padding:18px; border-radius: var(--radius-xl);
  background:linear-gradient(135deg, rgba(255,255,255,.82), rgba(255,255,255,.45));
  border:1px solid rgba(255,255,255,.75);
  box-shadow: 0 12px 24px rgba(8,40,52,.12);
}
.company-head .logo{
  display:grid; place-items:center; border-radius:14px; padding:14px;
  background: radial-gradient(circle at 30% 25%, #d7e8f5 0%, #a9c7df 55%, #86a9c8 100%);
  border:1px solid rgba(12,78,92,.4);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8), 0 12px 20px rgba(8,40,52,.2);
}
.company-logo{
  max-width:92px;
  opacity:.95;
}
.company-head .logo img{
  filter: drop-shadow(0 6px 10px rgba(8,40,52,.35));
}
.company-head .meta{ display:flex; flex-direction:column; gap:4px }
.company-head .name{ font-weight:800; letter-spacing:.4px }
.company-head .role{ color:var(--text-dim) }
.responsibilities{ display:grid; grid-template-columns: repeat(3, minmax(220px,1fr)); gap:18px }
.resp-card{
  position:relative;
  padding:18px 18px 16px;
  border-radius:16px;
  background:linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.6));
  border:1px solid rgba(255,255,255,.9);
  box-shadow: 0 14px 24px rgba(8,40,52,.14);
  overflow:hidden;
  opacity:0;
  transform: translateY(12px);
  animation: highlightIn .6s ease forwards;
}
.resp-card:nth-child(1){ animation-delay:.05s }
.resp-card:nth-child(2){ animation-delay:.12s }
.resp-card:nth-child(3){ animation-delay:.19s }
.resp-card::before{
  content:""; position:absolute; width:140px; height:140px; right:-60px; top:-60px;
  background: radial-gradient(circle, rgba(143,215,255,.6), transparent 70%);
  opacity:.8;
}
.resp-card h4{
  margin:.2rem 0 .6rem;
  color:var(--sea-600);
  text-transform:uppercase;
  letter-spacing:.12rem;
  font-size:.85rem;
}
.resp-card ul{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.resp-card li{
  position:relative;
  padding:.5rem .7rem .5rem 1.4rem;
  background:rgba(255,255,255,.78);
  border:1px solid rgba(255,255,255,.9);
  border-radius:14px;
  box-shadow: 0 6px 12px rgba(8,40,52,.08);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.resp-card li:hover{
  transform: translateY(-2px);
  background:rgba(255,255,255,.92);
  box-shadow: 0 10px 16px rgba(8,40,52,.12);
}
.resp-card li::before{
  content:"";
  position:absolute; left:.55rem; top:50%;
  width:8px; height:8px; border-radius:50%;
  transform:translateY(-50%);
  background: radial-gradient(circle at 30% 30%, #fff, var(--sea-500));
  box-shadow: 0 0 0 3px rgba(44,185,199,.18);
}
.resp-card:hover{
  transform: translateY(0) scale(1.01);
  box-shadow: 0 18px 30px rgba(8,40,52,.16);
}

.btn{
  display:inline-flex; align-items:center; gap:.5rem;
  padding:.75rem 1.2rem; border-radius:999px; text-decoration:none;
  border:1px solid rgba(255,255,255,.85);
  background:linear-gradient(180deg, #f3b37c, #e98c4c);
  color:#fff; font-weight:800; letter-spacing:.3px;
  box-shadow:0 10px 22px rgba(143,63,20,.22);
  transition: transform .2s ease, box-shadow .25s ease, filter .25s ease;
}
.btn:hover{ transform: translateY(-2px); box-shadow:0 16px 30px rgba(143,63,20,.26); filter:saturate(110%) }
.btn:visited,
.btn:active,
.btn:focus,
.btn:focus-visible{ color:#fff !important; }
.site-footer{
  padding:36px 0 42px;
  color:var(--text-dim);
}
.site-footer .footer-content{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
}
.site-footer .footer-copy{ font-size:.95rem }
.site-footer .footer-cta{ margin-left:auto }

.lightbox{
  position:fixed;
  inset:0;
  z-index:120;
  display:grid;
  place-items:center;
  background: rgba(6,18,24,.72);
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
  opacity:0;
  pointer-events:none;
  transition: opacity .2s ease;
}
.lightbox.is-open{
  opacity:1;
  pointer-events:auto;
}
.lightbox-content{
  position:relative;
  width:min(92vw, 1100px, calc(80vh * 4 / 3));
  display:flex;
  align-items:center;
  justify-content:center;
  aspect-ratio: 4 / 3;
}
.lightbox img{
  width:100%;
  height:100%;
  max-height:80vh;
  object-fit:cover;
  border-radius:22px;
  border:1px solid rgba(255,255,255,.8);
  background: rgba(255,255,255,.25);
  box-shadow: 0 28px 60px rgba(8,40,52,.28);
}
.lightbox-close{
  position:absolute;
  top:-12px;
  right:-12px;
  border:0;
  width:40px;
  height:40px;
  border-radius:999px;
  background: rgba(255,255,255,.9);
  color:#0b2a33;
  font-size:22px;
  font-weight:700;
  cursor:pointer;
  box-shadow: 0 10px 22px rgba(8,40,52,.2);
}
.lightbox-close:focus-visible{
  outline:3px solid rgba(44,185,199,.55);
  outline-offset:2px;
}

@keyframes highlightIn{ to{ opacity:1; transform: translateY(0) } }

.is-mobile .hero-canvas{ display:none; }
.is-mobile .hero .stage{
  position:relative;
  height:auto;
  min-height:0;
  padding-top: calc(var(--space-7) + 48px);
  padding-bottom: var(--space-6);
  overflow:hidden;
}
.is-mobile .hero .stage::before{
  content:"";
  position:absolute;
  inset:-20% -10% 0;
  background:
    radial-gradient(500px 320px at 20% 25%, rgba(143,215,255,.5), transparent 65%),
    radial-gradient(520px 340px at 80% 15%, rgba(154,223,107,.35), transparent 68%),
    linear-gradient(180deg, rgba(246,253,255,.95), rgba(230,247,255,.6) 55%, rgba(199,235,255,.35) 100%);
  z-index:0;
}
.is-mobile .hero-content{ position:relative; z-index:2; }
.is-mobile .hero-blur{ display:none; }
.is-mobile .chevron{ display:none; }
.is-mobile .fluid-layer,
.is-mobile .fluid-frost{ display:none; }
.is-mobile .global-bg{
  animation:none;
  filter: saturate(108%);
}
.is-mobile .brand span{ display:none; }

@media (prefers-reduced-motion: reduce){
  *, *::before, *::after{ animation-duration:0.001ms !important; animation-iteration-count:1 !important; transition-duration:0.001ms !important }
  .resp-card{ opacity:1; transform:none }
  .fluid-layer, .fluid-frost{ display:none }
}

@media (max-width: 820px){
  :root{
    --space-7:2.6rem;
    --space-8:3.4rem;
    --hero-h: clamp(420px, 75vh, 620px);
  }
  html{ scroll-padding-top: 120px }
  .page-hero{ padding-top: calc(var(--space-8) + 96px) }
  .nav{ flex-wrap:wrap; gap:.65rem }
  nav{ width:100%; display:flex; flex-wrap:wrap; justify-content:flex-start }
  nav a{ margin-left:0; margin-right:.4rem }
  .brand-icon{ width:44px; height:44px }
  .hero-card{ padding:1.5rem 1.6rem }
  .hero-title{ font-size: clamp(2.1rem, 8vw, 3.2rem) }
  .hero-actions{ width:100% }
  .hero-actions .btn{ width:100%; justify-content:center }
  .projects{ gap:48px }
  .project{ gap:24px; min-height:auto }
  .media{ min-height:240px }
  .thumb{ width:120px; height:120px; flex-basis:120px }
  .project-hit{ padding:14px }
  .project-tile.is-open .project-hit{ grid-template-columns: 1fr; align-items:flex-start }
  .project-cover{ max-width:none }
  .project-detail-inner{ padding:0 14px 16px }
  .project-gallery{ grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)) }
  .company-head{ grid-template-columns: 1fr }
  .company-head .logo{ width:120px }
}

@media (max-width: 1000px){
  .project, .project.alt{ grid-template-columns: 1fr; }
  .project, .project.alt{ height: auto; }
  .media{ max-height: none }
  .responsibilities{ grid-template-columns: 1fr 1fr }
  .projects-grid{ grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
}
body.nav-compact .nav{ flex-wrap:wrap; gap:.6rem }
body.nav-compact .nav-links{
  width:100%;
  order:3;
  flex-direction:column;
  align-items:flex-start;
  margin-top:0;
  padding:6px;
  border-radius:18px;
  background: rgba(255,255,255,.7);
  border:1px solid rgba(255,255,255,.8);
  max-height:0;
  opacity:0;
  overflow:hidden;
  transform: translateY(-8px) scale(0.98);
  transform-origin: top right;
  transition: max-height .45s cubic-bezier(.2,.9,.2,1), opacity .35s ease, transform .45s cubic-bezier(.2,.9,.2,1);
}
body.nav-compact .nav-links a{ margin-left:0; margin-right:0; width:100% }
body.nav-compact .nav-toggle{ display:flex; order:2; margin-left:auto }
body.nav-compact.nav-open .nav-links{
  max-height:240px;
  opacity:1;
  transform: translateY(0) scale(1);
  margin-top:.4rem;
}
body.nav-compact.nav-open header{ box-shadow: 0 16px 28px rgba(8,40,52,.16); }
body.nav-compact .nav-links a{ border-radius:12px; }
body.nav-compact .nav-links .cta{ box-shadow:none; }

@media (max-width: 640px){
  .nav{ gap:.6rem; padding:.55rem 0; min-height:56px }
  .brand-icon{ width:48px; height:48px }
  .nav-toggle{ width:48px; height:48px }
  nav a{ margin-left:0; margin-right:.4rem }
  .brand span{ display:none }
  .brand{ gap:.4rem }
  .all-projects-cta{ flex-direction:column; align-items:flex-start }
  .responsibilities{ grid-template-columns: 1fr }
  .site-footer .footer-content{ justify-content:flex-start }
  .site-footer .footer-cta{ margin-left:0 }
  .page-hero{ padding-top: calc(var(--space-8) + 112px) }
}

@media (hover: none){
  .media:hover .media-inner{
    transform:none;
    filter:none;
    box-shadow:none;
  }
  .thumb:hover{
    transform:none;
    box-shadow: 0 10px 20px rgba(8,40,52,.12);
    border-color: rgba(255,255,255,.8);
  }
  .project-tile:hover .project-cover img{ transform:none; }
}
