:root {
  --hero-header-offset: 88px;
  --hero-panel-radius: 32px;
  --hero-side-visible-ratio: 1.097;
  --hero-copy-max: 555px;
  --hero-border-duration: 8s;
  --hero-cyan: #00f0ff;
  --hero-blue: #238bff;
  --hero-violet: #9d4dff;
  --hero-magenta: #f065ff;
}

@property --hero-angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }

.hero-editorial {
  display: block;
  min-height: clamp(760px, 100svh, 980px);
  height: auto;
  padding: 0;
  isolation: isolate;
  overflow: hidden;
  background: radial-gradient(circle at 72% 44%, rgba(0,229,240,.11), transparent 27%), linear-gradient(112deg, #050816 0%, #07101e 54%, #040815 100%);
}
.hero-editorial .hero-glow { z-index: 1; width: 58vw; height: 58vw; right: 3%; top: 9%; background: radial-gradient(ellipse, rgba(0,229,240,.2), rgba(124,58,237,.1) 40%, transparent 70%); filter: blur(34px); opacity: .85; transform-origin: 72% 46%; animation: heroAtmosphereBreath 11s ease-in-out infinite; }
.hero-atmosphere { position: absolute; z-index: 1; inset: 0; pointer-events: none; background: radial-gradient(circle at 73% 51%, rgba(0,229,240,.1), transparent 22%), radial-gradient(circle at 84% 22%, rgba(124,58,237,.1), transparent 18%); animation: heroAtmosphereBreath 13s ease-in-out infinite reverse; }
.hero-editorial-grid { position: relative; z-index: 3; display: grid; grid-template-columns: minmax(360px,.78fr) minmax(570px,1.22fr); gap: 22px; align-items: start; width: 100%; max-width: none; padding: calc(var(--hero-header-offset) + 2px) clamp(48px,4.5vw,86px) 54px; }
.hero-editorial-copy { position: relative; z-index: 4; max-width: var(--hero-copy-max); margin-top: 28px; }
.hero-editorial-copy .eyebrow { margin-bottom: 24px; }
.hero-editorial-copy .hero-kicker { margin-bottom: 18px; }
.hero-editorial-copy h1 { margin: 0 0 24px; font-size: clamp(56px,6.15vw,94px); font-weight: 800; letter-spacing: -.075em; line-height: .9; }
.hero-editorial-copy h1 em { display: inline-block; margin-top: 10px; color: var(--accent); font-family: var(--serif); font-size: clamp(50px,4.4vw,68px); font-style: italic; font-weight: 400; letter-spacing: -.06em; line-height: .9; white-space: nowrap; text-shadow: 0 0 22px rgba(0,229,240,.08); }
.hero-editorial-copy .hero-description { max-width: 410px; margin-bottom: 22px; font-size: 17px; line-height: 1.55; }
.hero-editorial-copy .hero-tech-strip { max-width: 510px; gap: 8px; margin-bottom: 27px; }
.hero-editorial-copy .hero-tech-strip span { padding: 7px 10px; border-color: rgba(0,229,240,.22); background: rgba(5,18,34,.45); font-size: 10px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.hero-editorial-copy .hero-actions { gap: 14px; }
.hero-editorial-copy .hero-actions .btn-primary { padding: 15px 25px; border-radius: 999px; }
.hero-editorial-copy .hero-connect { padding: 13px 20px; border: 1px solid rgba(0,229,240,.6); border-radius: 999px; background: rgba(5,18,34,.26); }
.hero-support-links { display: flex; align-items: center; gap: 25px; margin-top: 25px; }
.hero-support-links > a { color: var(--muted); font: 10px var(--mono); text-transform: uppercase; }
.hero-support-links > a i { margin-right: 6px; color: var(--accent); }
.hero-support-links .social-row { display: flex; gap: 16px; margin: 0; }
.hero-support-links .social-row a { font-size: 16px; }

/* One panel owns the clipping boundary; its two existing portrait wrappers are grid cells. */
.hero-editorial-visual { position: relative; isolation: isolate; width: 100%; height: clamp(540px,calc(100svh - 180px),700px); min-height: 540px; overflow: visible; }
.portrait-composition { position: relative; display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); align-items: stretch; width: 100%; height: 100%; min-width: 0; overflow: hidden; border: 2px solid transparent; border-radius: var(--hero-panel-radius); background: linear-gradient(108deg,rgba(0,240,255,.2) 0%,rgba(10,53,92,.66) 28%,rgba(8,25,54,.82) 51%,rgba(44,25,93,.82) 78%,rgba(157,77,255,.22) 100%) padding-box,linear-gradient(110deg,var(--hero-cyan) 0%,var(--hero-blue) 50%,var(--hero-violet) 100%) border-box; box-shadow: 0 24px 78px rgba(0,0,0,.48),-22px 0 58px rgba(0,229,240,.2),26px 0 64px rgba(157,77,255,.22),inset 0 1px rgba(255,255,255,.2),inset 0 0 42px rgba(35,139,255,.1); isolation: isolate; pointer-events: none; animation: heroGlassReveal .95s .08s both; }
.portrait-composition::before { position: absolute; z-index: 0; inset: 0; content: ""; pointer-events: none; background: linear-gradient(116deg,transparent 13%,rgba(191,250,255,.14) 30%,transparent 41%),linear-gradient(72deg,transparent 49%,rgba(240,101,255,.1) 69%,transparent 86%),radial-gradient(ellipse at 16% 48%,rgba(0,240,255,.19),transparent 34%),radial-gradient(ellipse at 53% 38%,rgba(35,139,255,.13),transparent 31%),radial-gradient(ellipse at 88% 50%,rgba(157,77,255,.2),transparent 36%); }
.portrait-composition::after { position: absolute; z-index: 4; inset: -2px; content: ""; border: 3px solid transparent; border-radius: calc(var(--hero-panel-radius) + 2px); background: conic-gradient(from var(--hero-angle),transparent 0deg 164deg,rgba(0,240,255,.08) 181deg,rgba(0,240,255,.22) 205deg,rgba(0,240,255,.58) 236deg,rgba(35,139,255,.78) 270deg,rgba(185,250,255,.9) 301deg,#bfffff 320deg,#fff 330deg,#fff 338deg,#f8d8ff 346deg,var(--hero-magenta) 356deg,transparent 360deg) border-box; filter: drop-shadow(0 0 8px rgba(0,240,255,.98)) drop-shadow(0 0 18px rgba(35,139,255,.82)) drop-shadow(0 0 28px rgba(157,77,255,.58)); pointer-events: none; mask: linear-gradient(#000 0 0) padding-box,linear-gradient(#000 0 0); mask-composite: exclude; -webkit-mask: linear-gradient(#000 0 0) padding-box,linear-gradient(#000 0 0); -webkit-mask-composite: xor; will-change: background; animation: heroBorderOrbit var(--hero-border-duration) linear infinite; }
.portrait-layer { position: relative; z-index: 2; min-width: 0; height: 100%; overflow: hidden; pointer-events: none; }
.portrait-layer--side { grid-column: 1; }
.portrait-layer--front { grid-column: 2; }
.portrait-layer .portrait-glass { display: none; }
.portrait-layer .hero-portrait { position: absolute; left: 50%; bottom: 0; z-index: 2; display: block; width: auto; height: 100%; max-width: none; object-fit: contain; object-position: center bottom; opacity: 1; filter: none; mix-blend-mode: normal; transform: translateX(-50%); transform-origin: center bottom; animation: heroPortraitReveal .95s .16s both; }
/* The side PNG has less visible subject height. This measured ratio equalizes the visible people while preserving source proportions. */
.portrait-layer--side .hero-portrait { height: calc(100% * var(--hero-side-visible-ratio)); }
.portrait-layer--front .hero-portrait { z-index: 3; height: 100%; }

.hero-editorial-note { position: absolute; z-index: 5; top: 50%; left: 50%; display: grid; width: clamp(88px,8.8vw,128px); max-width: none; gap: .02em; margin: 0; color: rgba(244,255,255,.96); font-family: var(--sans); font-size: clamp(13px,1.05vw,19px); font-style: normal; font-weight: 300; letter-spacing: .055em; line-height: .94; text-align: center; text-transform: none; text-shadow: 0 0 10px rgba(0,229,240,.2),0 0 26px rgba(0,229,240,.12); transform: translate(-50%,-50%); pointer-events: none; animation: heroMessageReveal .9s .35s both,heroMessageGlow 5.8s 1.3s ease-in-out infinite; }
.hero-editorial-note::before,.hero-editorial-note::after { position: absolute; left: 50%; width: 1px; height: 18px; content: ""; background: linear-gradient(180deg,rgba(95,250,255,.9),transparent); box-shadow: 0 0 10px rgba(0,229,240,.5); }
.hero-editorial-note::before { bottom: calc(100% + 13px); }
.hero-editorial-note::after { top: calc(100% + 13px); background: linear-gradient(180deg,transparent,rgba(177,113,255,.9)); box-shadow: 0 0 10px rgba(124,58,237,.5); }
.hero-editorial-note .note-light { display: block; color: rgba(231,250,255,.94); font-family: var(--sans); font-size: .78em; font-weight: 300; letter-spacing: .045em; }
.hero-editorial-note .note-accent { position: relative; display: block; font-family: var(--serif); font-size: 1.18em; font-style: italic; font-weight: 400; letter-spacing: -.045em; line-height: .88; text-shadow: none; }
.hero-editorial-note .note-accent--cyan { color: #b9faff; background: linear-gradient(105deg,#c8fdff 10%,#00f0ff 55%,#238bff 100%); background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-editorial-note .note-accent--violet { color: #eadbff; background: linear-gradient(105deg,#bba5ff 5%,#9d4dff 55%,#f065ff 100%); background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-editorial-note .note-accent--cyan::before { position: absolute; z-index: -1; top: 50%; left: 50%; width: 156%; height: 168%; content: ""; border: 1px solid rgba(0,240,255,.5); border-left-color: transparent; border-right-color: rgba(35,139,255,.65); border-radius: 50%; box-shadow: 0 0 9px rgba(0,240,255,.22); transform: translate(-50%,-50%) rotate(-9deg); animation: heroOrbitShimmer 5.5s ease-in-out infinite; }
.scroll-cue { z-index: 4; }

.assistant-shell { z-index: 90; right: max(14px,calc((100vw - 1440px)/2 + 10px)); bottom: clamp(96px,16vh,150px); }
.assistant-trigger { position: relative; min-width: 238px !important; padding: 13px 50px 13px 15px !important; border: 1px solid rgba(0,229,240,.62) !important; border-radius: 18px !important; background: linear-gradient(110deg,rgba(7,18,34,.9),rgba(11,26,45,.7) 60%,rgba(45,25,74,.5)) !important; box-shadow: 0 12px 40px rgba(0,0,0,.28),0 0 30px rgba(0,229,240,.1),inset 0 1px rgba(255,255,255,.1) !important; backdrop-filter: blur(16px) !important; -webkit-backdrop-filter: blur(16px) !important; animation: heroAssistantFloat 5s ease-in-out infinite; }
.assistant-trigger::after { position: absolute; top: 50%; right: 12px; width: 31px; height: 31px; content: ""; border: 1px solid rgba(0,229,240,.85); border-radius: 50%; background: linear-gradient(145deg,rgba(5,8,22,.05),rgba(5,8,22,.55)),url("../profileFront.png") center 7% / cover no-repeat; box-shadow: 0 0 15px rgba(0,229,240,.2); transform: translateY(-50%); }
.assistant-trigger .ai-trigger-orb { width: 23px; height: 23px; flex: 0 0 23px; background: rgba(0,229,240,.08); box-shadow: 0 0 18px rgba(0,229,240,.3); }
.assistant-trigger span:last-of-type { color: #effeff; font: 10px var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.assistant-trigger .bi-command { display: none; }

@media (max-width: 1439px) and (min-width: 1101px) {
  .hero-editorial-grid { grid-template-columns: minmax(330px,.8fr) minmax(520px,1.2fr); gap: 18px; padding-inline: clamp(32px,3.5vw,58px); }
  .hero-editorial-copy { margin-top: 24px; }
  .hero-editorial-copy h1 { font-size: clamp(54px,5.9vw,80px); }
  .hero-editorial-visual { height: clamp(520px,calc(100svh - 138px),660px); min-height: 520px; }
}

@media (max-width: 1100px) and (min-width: 768px) {
  :root { --hero-header-offset: 58px; }
  .hero-editorial { min-height: 0; padding-bottom: 72px; }
  .hero-editorial-grid { display: flex; flex-direction: column; gap: 28px; padding: calc(var(--hero-header-offset) + 12px) clamp(28px,6vw,64px) 0; }
  .hero-editorial-copy { order: 1; max-width: 620px; margin: 8px 0 0; }
  .hero-editorial-visual { order: 2; width: 100%; height: clamp(420px,58vw,580px); min-height: 420px; }
  .hero-editorial-note { top: 50%; right: 3%; width: 82px; font-size: 13px; }
  .assistant-shell { right: 18px; bottom: 10%; }
}

@media (max-width: 767px) {
  :root { --hero-header-offset: 67px; --hero-panel-radius: 24px; }
  .hero-editorial { min-height: 0; padding: 0 0 max(72px,env(safe-area-inset-bottom)); }
  .hero-editorial-grid { display: flex; flex-direction: column; gap: 24px; padding: calc(var(--hero-header-offset) + 9px) 0 0; }
  .hero-editorial-copy { order: 1; width: 100%; max-width: none; margin: 0; padding: 0 12px; }
  .hero-editorial-visual { order: 2; width: calc(100% - 24px); height: clamp(300px,82vw,410px); min-height: 300px; margin: 0 12px; }
  .hero-editorial-note { width: 58px; font-size: 10px; line-height: 1.02; }
  .hero-editorial-note em { font-size: 1.08em; }
  .hero-editorial-copy::before { position: absolute; z-index: -1; top: -20px; right: -12px; left: -12px; height: 225px; content: ""; background: linear-gradient(180deg,#050816 0%,rgba(5,8,22,.97) 56%,transparent 100%); }
  .hero-editorial-copy .eyebrow { margin-bottom: 18px; }
  .hero-editorial-copy h1 { margin-bottom: 19px; font-size: clamp(43px,12vw,59px); line-height: .94; }
  .hero-editorial-copy h1 em { margin-top: 8px; font-size: .78em; line-height: .96; white-space: normal; }
  .hero-editorial-copy .hero-description { margin-bottom: 22px; font-size: 14px; line-height: 1.58; }
  .hero-editorial-copy .hero-tech-strip { display: none; }
  .hero-editorial-copy .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .hero-editorial-copy .hero-actions .btn-primary { grid-column: 1 / -1; }
  .hero-editorial-copy .hero-actions .btn-primary,.hero-editorial-copy .hero-connect { display: flex; align-items: center; justify-content: center; min-height: 47px; padding: 12px 10px; font-size: 12px; text-align: center; }
  .hero-support-links { justify-content: space-between; margin-top: 22px; }
  .assistant-shell { top: auto !important; right: 16px !important; bottom: max(72px,calc(env(safe-area-inset-bottom) + 72px)) !important; }
  .assistant-trigger { display: flex; align-items: center; width: 72px; min-width: 72px !important; height: 48px; padding: 9px 7px !important; border-radius: 18px !important; }
  .assistant-trigger span:last-of-type { display: none; }
  .assistant-trigger::after { display: block; right: 7px; width: 24px; height: 24px; }
  .assistant-trigger .ai-trigger-orb { width: 26px; height: 26px; margin: 0; }
  .hero-editorial .scroll-cue { display: none; }
}
@media (max-width: 430px) { .hero-editorial-visual { height: clamp(286px,80vw,350px); } }
@media (max-width: 380px) { .hero-editorial-visual { height: 286px; } }

@keyframes heroBorderOrbit { from { --hero-angle: 0deg; } to { --hero-angle: 360deg; } }
@keyframes heroGlassReveal { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
@keyframes heroPortraitReveal { from { opacity: 0; } to { opacity: 1; } }
@keyframes heroOrbitShimmer { 0%,100% { opacity: .45; transform: translate(-50%,-50%) rotate(-9deg) scaleX(.96); } 50% { opacity: .8; transform: translate(-50%,-50%) rotate(-3deg) scaleX(1.02); } }
@keyframes heroAtmosphereBreath { 0%,100% { opacity: .78; transform: scale(1); } 50% { opacity: .94; transform: scale(1.035); } }
@keyframes heroAssistantFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes heroMessageReveal { from { opacity: 0; transform: translate(-50%,calc(-50% + 12px)); } to { opacity: 1; transform: translate(-50%,-50%); } }
@keyframes heroMessageGlow { 0%,100% { filter: brightness(1); text-shadow: 0 0 10px rgba(0,229,240,.2),0 0 26px rgba(0,229,240,.12); } 50% { filter: brightness(1.08); text-shadow: 0 0 12px rgba(0,229,240,.45),0 0 30px rgba(124,58,237,.25); } }
@media (prefers-reduced-motion: reduce) { .portrait-composition,.portrait-composition::after,.portrait-layer .hero-portrait,.hero-editorial .hero-glow,.hero-editorial .hero-atmosphere,.hero-editorial-note,.hero-editorial-note .note-accent--cyan::before,.assistant-trigger { animation: none; } }
[data-theme="light"] .hero-editorial { background: radial-gradient(circle at 72% 44%,rgba(8,127,145,.12),transparent 28%),linear-gradient(112deg,#edf3f7,#f6f7f4 62%,#e8eef2); }
[data-theme="light"] .hero-editorial-copy::before { background: linear-gradient(180deg,#edf3f7 0%,rgba(237,243,247,.96) 58%,transparent 100%); }
[data-theme="light"] .assistant-trigger { background: rgba(255,255,255,.68) !important; }

/* Cinematic system layer: the perimeter is a real SVG stroke, not a rotating box gradient. */
.hero-perimeter { position: absolute; z-index: 6; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.hero-perimeter rect { fill: none; vector-effect: non-scaling-stroke; }
.hero-perimeter-base { stroke: rgba(176,239,255,.62); stroke-width: 1.5; }
.hero-perimeter-glow { stroke: url(#heroPerimeterGradient); stroke-width: 3; stroke-linecap: round; opacity: .52; filter: blur(5px); stroke-dasharray: .22 .78; animation: heroPerimeterGlow 10s linear infinite; }
.hero-perimeter-travel { stroke: url(#heroPerimeterGradient); stroke-width: 2.2; stroke-linecap: round; opacity: .98; stroke-dasharray: .065 .935; filter: drop-shadow(0 0 5px rgba(0,240,255,.95)) drop-shadow(0 0 12px rgba(157,77,255,.72)); animation: heroPerimeterTravel 9s linear infinite; }
.portrait-composition::after { display: none; }
.portrait-composition::before { animation: heroGlassLight 12s ease-in-out infinite alternate; }
.portrait-layer--side::before,.portrait-layer--front::before { position: absolute; z-index: 1; inset: 14% 12% 3%; content: ""; border-radius: 50%; filter: blur(28px); opacity: .42; pointer-events: none; }
.portrait-layer--side::before { background: radial-gradient(ellipse,rgba(0,240,255,.5),transparent 70%); }
.portrait-layer--front::before { background: radial-gradient(ellipse,rgba(157,77,255,.5),transparent 70%); }
.hero-editorial-note::after { top: 50%; left: 50%; width: 185%; height: 138%; border: 1px solid rgba(112,224,255,.32); border-left-color: rgba(240,101,255,.45); border-right-color: transparent; border-radius: 50%; background: none; transform: translate(-50%,-50%) rotate(-13deg); animation: heroCaptionOrbit 9s linear infinite; }
.hero-editorial-note::before { display: none; }
.hero-editorial-note { width: clamp(108px,10vw,148px); }

@keyframes heroPerimeterTravel { to { stroke-dashoffset: -1; } }
@keyframes heroPerimeterGlow { to { stroke-dashoffset: -1; } }
@keyframes heroGlassLight { from { opacity: .78; background-position: 0 0,100% 0,0 0; } to { opacity: 1; background-position: 8% 4%,92% -4%,4% 0; } }
@keyframes heroCaptionOrbit { to { transform: translate(-50%,-50%) rotate(347deg); } }

@media (prefers-reduced-motion: reduce) {
  .hero-perimeter-glow,.hero-perimeter-travel,.portrait-composition::before,.hero-editorial-note::after { animation: none; }
}

/* Shared premium interaction language. */
html { scroll-behavior: smooth; }
body { background: #050816; }
body::before { position: fixed; z-index: -2; inset: 0; content: ""; pointer-events: none; opacity: .2; background-image: linear-gradient(rgba(0,240,255,.08) 1px,transparent 1px),linear-gradient(90deg,rgba(0,240,255,.08) 1px,transparent 1px); background-position: center; background-size: 72px 72px; mask-image: linear-gradient(180deg,#000,transparent 82%); }
body::after { position: fixed; z-index: -1; inset: 0; content: ""; pointer-events: none; background: radial-gradient(circle at var(--scroll-light-x,50%) 18%,rgba(0,240,255,.055),transparent 24%),radial-gradient(circle at 82% 72%,rgba(157,77,255,.055),transparent 25%); transition: background-position .4s ease; }
.site-header { background: rgba(5,8,22,.58); border-bottom-color: rgba(0,240,255,.1); backdrop-filter: blur(18px) saturate(130%); -webkit-backdrop-filter: blur(18px) saturate(130%); }
.site-header.scrolled { box-shadow: 0 14px 36px rgba(0,0,0,.22),0 1px rgba(0,240,255,.14); }
.desktop-nav a { position: relative; transition: color .25s ease,transform .25s ease; }
.desktop-nav a::after { position: absolute; right: 0; bottom: -8px; left: 0; height: 1px; content: ""; background: linear-gradient(90deg,var(--hero-cyan),var(--hero-magenta)); box-shadow: 0 0 10px rgba(0,240,255,.55); transform: scaleX(0); transform-origin: left; transition: transform .3s ease; }
.desktop-nav a:hover,.desktop-nav a.active { color: #dfffff; transform: translateY(-1px); }
.desktop-nav a:hover::after,.desktop-nav a.active::after { transform: scaleX(1); }
.section { position: relative; }
.section:nth-of-type(3n)::before { position: absolute; top: 0; left: 8%; width: 84%; height: 1px; content: ""; background: linear-gradient(90deg,transparent,rgba(0,240,255,.45),rgba(157,77,255,.35),transparent); box-shadow: 0 0 14px rgba(0,240,255,.16); opacity: .55; }
.project-card { position: relative; overflow: hidden; transition: transform .38s cubic-bezier(.22,1,.36,1),box-shadow .38s ease,border-color .38s ease; }
.project-card::before { position: absolute; z-index: 0; top: var(--pointer-y,50%); left: var(--pointer-x,50%); width: 260px; height: 220px; content: ""; pointer-events: none; background: radial-gradient(circle,rgba(0,240,255,.14),transparent 68%); opacity: 0; transform: translate(-50%,-50%); transition: opacity .35s ease; }
.project-card > * { position: relative; z-index: 1; }
.project-card:hover { border-color: rgba(0,240,255,.56); box-shadow: 0 24px 55px rgba(0,0,0,.3),0 0 28px rgba(0,240,255,.11); transform: translateY(-6px); }
.project-card:hover::before { opacity: 1; }
.project-card:hover .project-art img { transform: scale(1.035); }
.project-art img { transition: transform .65s cubic-bezier(.22,1,.36,1); }
.project-meta i,.btn-primary i,.btn-quiet i { transition: transform .25s ease; }
.project-card:hover .project-meta i,.btn-primary:hover i,.btn-quiet:hover i { transform: translate(3px,-3px); }
.tag-row span { transition: border-color .25s ease,color .25s ease,background .25s ease,transform .25s ease; }
.tag-row span:hover { color: #eaffff; border-color: rgba(0,240,255,.55); background: rgba(0,240,255,.1); transform: translateY(-2px); }
.btn-primary,.btn-quiet { transition: transform .25s ease,box-shadow .25s ease,background .25s ease,border-color .25s ease; }
.btn-primary:hover,.btn-quiet:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,240,255,.16); }
.btn-primary:active,.btn-quiet:active { transform: translateY(0) scale(.98); }
.btn-primary:focus-visible,.btn-quiet:focus-visible,.desktop-nav a:focus-visible { outline: 2px solid #00f0ff; outline-offset: 4px; }
html:not(.aos-enabled) [data-aos] { opacity: 1 !important; transform: none !important; }

@media (max-width: 767px) {
  body::before { opacity: .12; background-size: 56px 56px; }
  .project-card:hover { transform: translateY(-2px); }
  .project-card::before { display: none; }
}

/* Portfolio 3.0 depth layer: only the light field responds; portrait pixels stay still. */
.hero-editorial-visual::before { position: absolute; z-index: 1; inset: -18%; content: ""; pointer-events: none; opacity: .42; background: radial-gradient(circle at var(--hero-pointer-x,50%) var(--hero-pointer-y,50%),rgba(0,240,255,.16),transparent 18%),radial-gradient(ellipse at 78% 28%,rgba(157,77,255,.12),transparent 38%); filter: blur(18px); transform: translate3d(calc((var(--hero-pointer-x,50%) - 50%) / 18),calc((var(--hero-pointer-y,50%) - 50%) / 18),0); transition: transform .8s cubic-bezier(.22,1,.36,1),opacity .6s ease; }
.portrait-composition::before { background: radial-gradient(circle at var(--hero-pointer-x,50%) var(--hero-pointer-y,50%),rgba(191,250,255,.18),transparent 19%),linear-gradient(116deg,transparent 13%,rgba(191,250,255,.14) 30%,transparent 41%),linear-gradient(72deg,transparent 49%,rgba(240,101,255,.1) 69%,transparent 86%),radial-gradient(ellipse at 16% 48%,rgba(0,240,255,.19),transparent 34%),radial-gradient(ellipse at 53% 38%,rgba(35,139,255,.13),transparent 31%),radial-gradient(ellipse at 88% 50%,rgba(157,77,255,.2),transparent 36%); background-size: auto,auto,auto,auto,auto,auto; transition: background-position .7s cubic-bezier(.22,1,.36,1),opacity .8s ease; }
.hero-editorial-visual::after { position: absolute; z-index: 3; inset: 8% 12%; content: ""; pointer-events: none; opacity: .3; background: linear-gradient(112deg,transparent 28%,rgba(255,255,255,.2) 44%,transparent 52%); transform: translateX(calc((var(--hero-pointer-x,50%) - 50%) / 4)); transition: transform .7s cubic-bezier(.22,1,.36,1); mix-blend-mode: screen; }
.hero-editorial-visual.is-pointer-active::before,.hero-editorial-visual.is-pointer-active::after { opacity: .72; }

/* Expandable project explorer. */
.project-explorer-dialog { width: min(920px,calc(100vw - 32px)); max-height: min(820px,calc(100dvh - 32px)); padding: 0; color: var(--text); border: 1px solid rgba(0,240,255,.42); border-radius: 24px; background: linear-gradient(145deg,rgba(7,18,34,.98),rgba(16,15,42,.98)); box-shadow: 0 28px 100px rgba(0,0,0,.6),0 0 50px rgba(0,240,255,.12); overflow: hidden; }
.project-explorer-dialog::backdrop { background: rgba(2,5,15,.78); backdrop-filter: blur(10px); }
.project-explorer-dialog[open] { animation: explorerIn .36s cubic-bezier(.22,1,.36,1); }
.project-explorer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 24px 26px 18px; border-bottom: 1px solid rgba(0,240,255,.14); }
.project-explorer-kicker { color: var(--accent); font: 10px var(--mono); letter-spacing: .14em; text-transform: uppercase; }
.project-explorer-head h2 { margin: 8px 0 0; font-size: clamp(24px,4vw,42px); line-height: .98; }
.project-explorer-close { width: 38px; height: 38px; border: 1px solid rgba(0,240,255,.28); border-radius: 50%; background: rgba(0,240,255,.06); color: var(--text); font-size: 22px; cursor: pointer; }
.project-explorer-close:hover { border-color: var(--accent); color: var(--accent); }
.project-explorer-body { display: grid; grid-template-columns: minmax(0,1.3fr) minmax(230px,.7fr); gap: 24px; padding: 24px 26px 28px; overflow: auto; }
.project-explorer-summary { color: var(--muted); line-height: 1.7; }
.project-explorer-summary p { margin: 0 0 14px; }
.project-explorer-label { display: block; margin: 20px 0 9px; color: var(--accent); font: 10px var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.project-explorer-stack { display: flex; flex-wrap: wrap; gap: 7px; }
.project-explorer-stack span { padding: 7px 9px; border: 1px solid rgba(0,240,255,.18); border-radius: 999px; color: #d8fbff; background: rgba(0,240,255,.06); font: 10px var(--mono); }
.project-explorer-side { display: flex; flex-direction: column; gap: 14px; }
.project-explorer-media { min-height: 150px; border: 1px solid rgba(0,240,255,.2); border-radius: 16px; background: radial-gradient(circle at 20% 20%,rgba(0,240,255,.18),transparent 38%),rgba(6,13,28,.8); overflow: hidden; }
.project-explorer-media img { width: 100%; height: 100%; min-height: 150px; object-fit: cover; }
.project-explorer-architecture { padding: 14px; border: 1px solid rgba(157,77,255,.22); border-radius: 16px; color: #d9d5ff; font: 11px/1.7 var(--mono); background: rgba(157,77,255,.06); }
.project-explorer-links { display: flex; flex-wrap: wrap; gap: 9px; }
.project-explorer-links a { display: inline-flex; align-items: center; gap: 7px; }
.project-inspect-button { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; padding: 9px 12px; border: 1px solid rgba(0,240,255,.26); border-radius: 999px; color: #dffeff; background: rgba(0,240,255,.06); font: 10px var(--mono); cursor: pointer; }
.project-inspect-button:hover,.project-inspect-button:focus-visible { border-color: var(--accent); background: rgba(0,240,255,.13); outline: none; }

/* Technology constellation. */
.technology-constellation-section { overflow: hidden; }
.constellation-shell { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(250px,.8fr); gap: 24px; padding: 24px; border: 1px solid rgba(0,240,255,.18); border-radius: 24px; background: linear-gradient(135deg,rgba(5,18,34,.72),rgba(20,13,48,.62)); }
.constellation-stage { position: relative; min-height: 430px; border: 1px solid rgba(0,240,255,.12); border-radius: 18px; background: radial-gradient(circle at 50% 50%,rgba(0,240,255,.08),transparent 34%),rgba(3,9,22,.55); overflow: hidden; }
.constellation-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.constellation-edge { stroke: rgba(83,190,221,.2); stroke-width: 1; transition: stroke .3s ease,stroke-width .3s ease,opacity .3s ease; }
.constellation-edge.is-connected { stroke: rgba(0,240,255,.9); stroke-width: 2; filter: drop-shadow(0 0 4px rgba(0,240,255,.7)); }
.constellation-node { position: absolute; z-index: 1; min-width: 92px; padding: 8px 10px; border: 1px solid rgba(0,240,255,.22); border-radius: 999px; color: #ccecf1; background: rgba(4,14,30,.9); font: 10px var(--mono); cursor: pointer; transform: translate(-50%,-50%); transition: border-color .25s ease,background .25s ease,color .25s ease,box-shadow .25s ease,opacity .25s ease; }
.constellation-node[data-kind="project"] { border-color: rgba(157,77,255,.34); color: #e5d9ff; }
.constellation-node:hover,.constellation-node:focus-visible,.constellation-node.is-selected { border-color: var(--accent); color: #fff; background: rgba(0,240,255,.14); box-shadow: 0 0 22px rgba(0,240,255,.2); outline: none; }
.constellation-node.is-muted { opacity: .28; }
.constellation-legend { display: grid; align-content: start; gap: 13px; }
.constellation-legend h3 { margin: 0; font-size: 20px; }
.constellation-legend p { color: var(--muted); line-height: 1.65; }
.constellation-selection { min-height: 120px; padding: 16px; border: 1px solid rgba(157,77,255,.25); border-radius: 16px; background: rgba(157,77,255,.06); color: var(--muted); font-size: 13px; line-height: 1.6; }
.constellation-selection strong { display: block; margin-bottom: 5px; color: #f0eaff; }
.constellation-list { display: none; }

@keyframes explorerIn { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
@media (max-width: 800px) { .project-explorer-body,.constellation-shell { grid-template-columns: 1fr; } .constellation-stage { min-height: 460px; } }
@media (max-width: 600px) { .project-explorer-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); border-radius: 18px; } .project-explorer-head,.project-explorer-body { padding-inline: 17px; } .constellation-shell { padding: 12px; } .constellation-stage { display: none; } .constellation-list { display: grid; gap: 8px; } .constellation-list button { padding: 12px; border: 1px solid rgba(0,240,255,.2); border-radius: 12px; color: var(--text); background: rgba(5,18,34,.7); text-align: left; font: 11px var(--mono); } }

/* Keep the large recipe artwork lazy-loadable through the project card image. */
.art-findmyrecipe { background: radial-gradient(circle at 50% 40%, #123c56, #11152c 55%, #080b18) !important; }

/* Defer layout/paint work for long case-study sections until they approach the viewport. */
main > .section:not(#hero):not(#about):not(#digital-nizam) { content-visibility: auto; contain-intrinsic-size: 1px 900px; }

img[loading="lazy"] { content-visibility: auto; contain-intrinsic-size: 320px 240px; }

@media (max-width: 767px) {
  main > .section:not(#hero):not(#about):not(#digital-nizam) { contain-intrinsic-size: 1px 700px; }
}

@media (pointer: coarse) {
  .site-header.scrolled, .desktop-nav, .tech-badge, .code-float, .project-card, .skill-card { backdrop-filter: none; }
  .hero-glow { filter: none; }
}
