/* ============================================
   Marine Royet — Portfolio
   Design tokens & shared styles
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

:root{
  --bg: #000000;
  --fg: #ffffff;
  --muted: rgba(255,255,255,0.62);
  --muted-2: rgba(255,255,255,0.42);
  --line: rgba(255,255,255,0.14);
  --card-bg: rgba(255,255,255,0.05);
  --card-border: rgba(255,255,255,0.10);
  --pill-bg: rgba(255,255,255,0.08);
  --pill-bg-hover: rgba(255,255,255,0.14);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-pill: 999px;
  --container: 1160px;
  --gap: 24px;
}

*, *::before, *::after{ box-sizing: border-box; }

html{
  background: var(--bg);
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
}

body{
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
}

/* ---------- Ambient background glow ---------- */
.bg-glow{
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 900px 700px at 18% 8%, rgba(216,150,92,0.20), transparent 60%),
    radial-gradient(ellipse 900px 800px at 78% 4%, rgba(107,79,196,0.24), transparent 55%),
    radial-gradient(ellipse 700px 650px at 50% 20%, rgba(178,58,90,0.16), transparent 60%),
    linear-gradient(180deg, #0a0a0a 0%, #000000 45%);
}

body > :where(*:not(.bg-glow)){
  position: relative;
  z-index: 1;
}

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

a{ color: inherit; text-decoration: none; }

.container{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------- Nav ---------- */
.site-nav{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 40px;
}
.site-nav .pill{ background: rgba(0,0,0,0.1); }
.site-nav .pill:hover{ background: rgba(0,0,0,0.16); }

.brand{
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.pill{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 20px;
  border-radius: var(--radius-pill);
  background: var(--pill-bg);
  border: 1px solid var(--card-border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  font-size: 13px;
  font-weight: 500;
  color: var(--fg);
  transition: background 0.2s ease, transform 0.2s ease;
  white-space: nowrap;
}
.pill:hover{ background: var(--pill-bg-hover); }
.pill:active{ transform: scale(0.97); }

.pill--block{ display: flex; width: 100%; justify-content: center; }

.pill-avatar{
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}
.pill:has(.pill-avatar){ padding-top: 4px; padding-bottom: 4px; padding-left: 4px; }
.pill--tall{ height: 52px; }

/* ---------- Typography ---------- */
h1, h2, h3, h4{
  margin: 0;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

.hero-title{
  font-size: clamp(48px, 9vw, 128px);
  text-align: center;
  margin: 0 auto;
  max-width: 20ch;
}

.section-title{
  font-size: clamp(28px, 4vw, 44px);
  text-align: center;
}

.section-lede{
  max-width: 640px;
  margin: 16px auto 0;
  text-align: center;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.eyebrow{
  font-family: 'Roboto Mono', ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted-2);
}

p{ line-height: 1.6; color: var(--muted); }

.divider{
  border: none;
  border-top: 1px solid var(--line);
  margin: 0;
}

/* ---------- Buttons ---------- */
.btn{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  background: var(--pill-bg);
  border: 1px solid var(--card-border);
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s ease, transform 0.2s ease;
}
.btn:hover{ background: var(--pill-bg-hover); }
.btn:active{ transform: scale(0.97); }
.btn--sm{ padding: 10px 18px; font-size: 13px; }

/* ---------- Section spacing ---------- */
.section{ padding: 96px 0; }
.section--tight{ padding: 24px 0 56px; }

.stack-head{
  position: sticky;
  top: 24px;
  z-index: 20;
  padding: 20px 32px 24px;
}

/* ---------- Footer / Connect ---------- */
.connect{
  text-align: center;
  padding: 100px 0 120px;
}
.connect .section-title{ margin-bottom: 32px; }
.connect-links{
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 420px;
  margin: 0 auto;
}

.project-footer{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0 60px;
  border-top: 1px solid var(--line);
  margin-top: 40px;
}
.project-footer .title{ font-size: 20px; }
.project-footer .icon{
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--pill-bg);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700;
}

/* ============================================
   HOME PAGE
   ============================================ */
.hero{
  padding: 200px 32px 56px;
  text-align: center;
}
.hero-sub{
  max-width: 620px;
  margin: 24px auto 0;
  color: var(--muted);
  font-size: 17px;
}
.hero-sub p{ margin: 0 0 14px; color: inherit; font-size: inherit; line-height: 1.6; }
.hero-sub p:last-child{ margin-bottom: 0; }
.hero-sub a{
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.hero-sub a:hover{ opacity: 0.8; }
.hero-sub a.btn{
  text-decoration: none;
  color: var(--fg);
}
.hero-sub a.btn-primary{
  color: #0a0a0a;
}
.hero-cta-row{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}
.btn-primary{
  background: #ffffff;
  color: #0a0a0a;
  border-color: #ffffff;
  font-weight: 600;
}
.btn-primary:hover{ background: rgba(255,255,255,0.88); }

/* ---------- Scroll-driven parallax bento ---------- */
.parallax-hero{
  position: relative;
  height: 145vh;
}
.parallax-stage{
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pcard-grid{
  --p: 1;
  width: min(1180px, 94vw);
  display: flex;
  gap: 12px;
}
.pcard-col{
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.pcard-col.wide{ flex: 1; }
.pcard-col.narrow{ flex: 0.82; }

.pcard{
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 24px 56px -22px rgba(0,0,0,0.6);
  transform:
    translate3d(calc(var(--dx) * var(--p)), calc(var(--dy) * var(--p)), 0)
    rotate(calc(var(--rot) * var(--p)))
    scale(calc(1 + (var(--sc)) * var(--p)));
  will-change: transform;
}
.pcard img{
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
}

/* Bring the body-composition and scale cards down to meet the other
   columns' bottom edge without touching the rest of the bento. */
.pcard-3, .pcard-5{ aspect-ratio: 0.648; background: rgba(255,255,255,0.08); }
.pcard-3 img, .pcard-5 img{ width: 100%; height: 100%; object-fit: cover; }

/* per-card scatter targets (start = fully scattered at --p:1) */
.pcard-1{ --dx:-16vw; --dy:-9vh;  --rot:-9deg;  --sc:0.22; }
.pcard-2{ --dx:11vw;  --dy:-13vh; --rot:11deg;  --sc:0.3;  }
.pcard-3{ --dx:-9vw;  --dy:11vh;  --rot:7deg;   --sc:0.16; }
.pcard-4{ --dx:13vw;  --dy:-10vh; --rot:-10deg; --sc:0.24; }
.pcard-5{ --dx:-13vw; --dy:12vh;  --rot:8deg;   --sc:0.18; }
.pcard-6{ --dx:17vw;  --dy:-6vh;  --rot:-7deg;  --sc:0.2;  }
.pcard-7{ --dx:15vw;  --dy:13vh;  --rot:10deg;  --sc:0.26; }

@media (prefers-reduced-motion: reduce){
  .pcard{ transition: none; }
}
.parallax-hero.no-motion{ height: auto; }
.parallax-hero.no-motion .parallax-stage{
  position: static;
  height: auto;
  padding: 40px 0 80px;
}
.parallax-hero.no-motion .pcard{ transform: none; }

@media (max-width: 860px){
  .parallax-hero{ height: 130vh; }
  .pcard-grid{ flex-wrap: wrap; }
  .pcard-col{ flex: 1 1 calc(50% - 6px); }
  .pcard-1{ --dx:-10vw; --dy:-8vh; }
  .pcard-2{ --dx:10vw;  --dy:-10vh; }
  .pcard-3{ --dx:-9vw;  --dy:6vh; }
  .pcard-4{ --dx:9vw;   --dy:8vh; }
  .pcard-5{ --dx:-11vw; --dy:2vh; }
  .pcard-6{ --dx:11vw;  --dy:-2vh; }
  .pcard-7{ --dx:8vw;   --dy:9vh; }
}

.role-section{ padding: 48px 0 40px; text-align: center; }

.role-card{
  position: relative;
  max-width: var(--container);
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 420px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 40px;
  background: #120c10;
  isolation: isolate;
}
.role-card video{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
.role-card::after{
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.7) 100%);
  z-index: -1;
}
.role-card h3{ font-size: 32px; margin-bottom: 6px; }
.role-card .meta{
  font-family: 'Roboto Mono', ui-monospace, monospace;
  font-size: 12px;
  color: rgba(255,255,255,0.75);
  margin-bottom: 18px;
}

/* ---------- Stacking project cards ---------- */
.stack{
  --card-top-base: 212px;
  max-width: var(--container);
  margin: 40px auto 0;
  padding: 0 32px 0;
}

.stack-card{
  position: sticky;
  z-index: 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 480px;
  display: flex;
  align-items: flex-end;
  isolation: isolate;
  border: 0.5px solid rgba(255,255,255,0.10);
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.6);
  margin-bottom: 32px;
  transition: box-shadow 0.2s ease;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}
.stack-card:hover{
  box-shadow: 0 0 60px 0 rgba(0,0,0,0.05), 0 30px 60px -20px rgba(0,0,0,0.6);
}
.stack-card img, .stack-card video{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
.stack-card::before{
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.05);
  z-index: -1;
  transition: opacity 0.2s ease;
}
.stack-card:hover::before{
  opacity: 0;
}
.stack-card::after{
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.75) 100%);
  z-index: -1;
}
.stack-card .card-body{
  position: relative;
  padding: 40px;
  width: 100%;
}
.stack-card h3{
  font-size: clamp(24px, 3vw, 38px);
  margin-bottom: 8px;
  max-width: 20ch;
}
.stack-card .meta{
  font-family: 'Roboto Mono', ui-monospace, monospace;
  font-size: 12px;
  color: rgba(255,255,255,0.75);
  margin-bottom: 18px;
}

.stack-card:nth-child(1){ top: var(--card-top-base); scroll-margin-top: var(--card-top-base); }
.stack-card:nth-child(2){ top: calc(var(--card-top-base) + 16px); scroll-margin-top: calc(var(--card-top-base) + 16px); }
.stack-card:nth-child(3){ top: calc(var(--card-top-base) + 32px); scroll-margin-top: calc(var(--card-top-base) + 32px); }
.stack-card:nth-child(4){ top: calc(var(--card-top-base) + 48px); scroll-margin-top: calc(var(--card-top-base) + 48px); }
.stack-card:nth-child(5){ top: calc(var(--card-top-base) + 64px); scroll-margin-top: calc(var(--card-top-base) + 64px); }
.stack-card:nth-child(6){ top: calc(var(--card-top-base) + 80px); scroll-margin-top: calc(var(--card-top-base) + 80px); }

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-hero{ padding: 180px 0 40px; }
.about-hero h1{ font-size: clamp(56px, 9vw, 110px); }

.intro-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  margin-top: 40px;
}
.intro-grid img{
  border-radius: var(--radius-md);
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.intro-grid h2{ font-size: 34px; margin-bottom: 16px; }
.intro-grid p{ margin: 0 0 12px; }

.healthtech-title{ font-size: 34px; margin-bottom: 28px; }
.healthtech-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.healthtech-grid img{
  border-radius: var(--radius-md);
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
}

.timeline{ margin-top: 56px; }
.timeline-row{
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.timeline-row-head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.timeline-row .role{ font-size: 22px; }
.timeline-row .role span{ color: var(--muted); }
.timeline-row .date{
  font-family: 'Roboto Mono', ui-monospace, monospace;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}
.timeline-desc{
  margin: 12px 0 0;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 640px;
}

/* ============================================
   PROJECT DETAIL PAGES
   ============================================ */
.project-hero{
  padding: 180px 32px 64px;
  text-align: center;
}

/* ---- Full-width image hero with title overlay ---- */
.hero-banner{
  position: relative;
  width: 100%;
  margin-bottom: 32px;
  min-height: 88vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
}
.hero-banner img, .hero-banner video{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
.hero-banner::after{
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.25) 45%, rgba(0,0,0,0.75) 100%);
  z-index: -1;
}
.hero-banner-content{
  position: relative;
  padding: 140px 32px 0;
  max-width: 820px;
  text-align: center;
}
.hero-banner-content h1{ font-size: clamp(48px, 9vw, 108px); }
.hero-banner-content .sub{
  max-width: 620px;
  margin: 20px auto 0;
  color: rgba(255,255,255,0.85);
  font-size: 17px;
}
.project-hero h1{ font-size: clamp(48px, 9vw, 108px); }
.project-hero .sub{
  max-width: 620px;
  margin: 20px auto 0;
  color: var(--muted);
  font-size: 17px;
}

.project-flow{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px 40px;
  display: flex;
  flex-direction: column;
  gap: 56px;
}
.project-flow img{
  width: 100%;
  border-radius: var(--radius-md);
}
.project-flow > video{
  width: 100%;
  border-radius: var(--radius-md);
  display: block;
}
.motion-video{
  display: block;
  width: 100%;
  max-width: 340px;
  margin: 0 auto;
  border-radius: var(--radius-md);
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.6);
}
.project-flow .text-block{
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
}
.project-flow .text-block h2{ font-size: clamp(24px, 3.4vw, 36px); margin-bottom: 12px; }
.project-flow .text-block p{ font-size: 15px; }

.text-block--left{
  text-align: left;
  max-width: 720px;
  margin: 0;
}
.text-block--left h2{ font-size: clamp(24px, 3.4vw, 36px); margin-bottom: 12px; }
.text-block--left p{ font-size: 15px; margin: 0 0 10px; }

/* ============================================
   PROJECT PAGE — reusable content components
   ============================================ */

/* ---- Two-column photo + text split ---- */
.split{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  text-align: left;
}
.split.reverse .split-media{ order: 2; }
.split.reverse .split-text{ order: 1; }
.split-media img{
  width: 100%;
  border-radius: var(--radius-md);
  aspect-ratio: 4/3;
  object-fit: cover;
}
.split-text h2{ font-size: clamp(22px, 2.6vw, 30px); margin-bottom: 14px; }

.split-text p{ font-size: 14.5px; margin: 0 0 10px; }

/* ---- Numbered feature steps ---- */
.feature-steps{
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
  text-align: center;
}
.feature-step-num{
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #fff;
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  margin: 0 auto 14px;
}
.feature-step-title{
  font-weight: 700;
  color: var(--fg);
  font-size: 17px;
  margin-bottom: 6px;
}
.feature-step p{ font-size: 15px; margin: 0; }
.split-text p a{ text-decoration: underline; text-underline-offset: 2px; color: var(--fg); }

/* ---- Photo with floating glass note (Cardio hero) ---- */
.photo-note-wrap{ position: relative; }
.photo-note-wrap img{ width: 100%; border-radius: var(--radius-md); }
.glass-note{
  position: absolute;
  right: 24px; bottom: 24px;
  max-width: 340px;
  background: rgba(20,20,20,0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 16px;
  padding: 18px 20px;
  text-align: left;
}
.glass-note .tag{ font-size: 11px; color: var(--muted); margin-bottom: 6px; }
.glass-note h4{ font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.glass-note p{ font-size: 12.5px; margin: 0; line-height: 1.5; }

/* ---- Device diagram (BeamO sensors) ---- */
.device-diagram{
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 56px 40px;
  text-align: center;
}
.device-diagram h2{ font-size: clamp(22px,2.8vw,32px); margin-bottom: 40px; }
.diagram-row{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}
.diagram-label{ font-size: 12.5px; max-width: 140px; }
.diagram-label .dot{
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--fg); margin-right: 6px;
}
.device-illustration{
  width: 340px; max-width: 100%;
}
.device-illustration img{ width: 100%; }

/* ---- Handheld device mockup (BeamO screen states) ---- */
.device-mock-row{
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
}
.device-mock{
  width: 210px;
  background: #f2f2f2;
  border-radius: 40px;
  padding: 6px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.35);
}
.device-mock .screen{
  background: #0b0b0c;
  color: #fff;
  border-radius: 34px;
  padding: 22px 14px;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  font-size: 11px;
}
.device-mock .screen .instr{ font-size: 11px; line-height: 1.4; max-width: 130px; }
.device-mock .knob{
  width: 34px; height: 34px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #2b2b2b, #050505);
  margin: 10px auto 0;
}
.device-mock .brand{ font-size: 8px; letter-spacing: 0.08em; color: var(--muted-2); margin-top: 8px; }

/* ---- Phone mockup ---- */
.phone-row{
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  justify-content: center;
}
.phone{
  width: 220px;
  flex-shrink: 0;
  background: #111214;
  border-radius: 34px;
  padding: 8px;
  box-shadow: 0 24px 48px rgba(0,0,0,0.45);
}
.phone-screen{
  position: relative;
  background: #fff;
  color: #111;
  border-radius: 27px;
  overflow: hidden;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  font-size: 11px;
  text-align: left;
}
.phone-screen.is-dark{ background: #121212; color: #fff; }
.phone-screen video{ width: 100%; height: 100%; object-fit: cover; }
.phone--lg{ width: 320px; }
.phone--lg .phone-screen{ min-height: 640px; }
.phone-notch{
  position: absolute; top: 8px; left: 50%; transform: translateX(-50%);
  width: 64px; height: 16px; background: #111214; border-radius: 10px;
}
.phone-status{
  display: flex; justify-content: space-between;
  padding: 16px 16px 2px; font-size: 10px; font-weight: 600;
}
.phone-body{ padding: 6px 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 8px; overflow-wrap: anywhere; }
.phone-body h5{ font-size: 13px; font-weight: 700; margin: 4px 0; letter-spacing: -0.01em; }
.phone-body p{ color:#555; font-size: 10.5px; margin:0; }
.phone-screen.is-dark .phone-body p{ color:#aaa; }
.phone-body .tabs{ display:flex; gap:14px; font-size:10px; color:#8a8a8a; margin-bottom:2px; }
.phone-body .tabs .on{ color:#111; font-weight:700; }
.phone-screen.is-dark .phone-body .tabs .on{ color:#fff; }

.app-card{
  background: #f4f4f5;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 10.5px;
}
.phone-screen.is-dark .app-card{ background: #1e1e1f; color:#eee; }
.app-card + .app-card{ margin-top: 6px; }
.app-card .title{ font-weight: 700; font-size: 11.5px; margin-bottom: 3px; }
.app-card p{ font-size: 10px; color: #666; margin: 0; line-height: 1.4; }
.phone-screen.is-dark .app-card p{ color:#aaa; }

.app-badge{
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 9px; font-weight: 700; padding: 3px 8px;
  border-radius: 999px; margin-bottom: 4px;
}
.app-badge.green{ background: #e6f3e6; color: #1e4b1f; }
.app-badge.red{ background: #fbe4e4; color: #9c2b2b; }
.app-badge.amber{ background: #fbf0d9; color: #8a5a12; }

.app-btn{
  background: #111; color: #fff; text-align: center;
  padding: 9px; border-radius: 10px; font-size: 10.5px; font-weight: 700;
  margin-top: auto;
}
.app-btn.light{ background: #eef0ff; color: #3a4bcf; }
.app-btn.outline{ background: transparent; border: 1px solid #d8d8d8; color: #111; }
.phone-screen.is-dark .app-btn.outline{ border-color:#333; color:#fff; }

.app-list-item{
  display: flex; align-items: center; gap: 8px;
  padding: 6px 0; font-size: 10.5px; border-bottom: 1px solid #ececec;
}
.phone-screen.is-dark .app-list-item{ border-color:#262626; }
.app-list-item .name{ font-weight: 600; flex: 1; }
.app-list-item .sub{ color: #888; font-size: 9.5px; }

.avatar-dot{
  width: 26px; height: 26px; border-radius: 50%;
  background: #d8d8de; flex-shrink: 0;
  display:flex; align-items:center; justify-content:center;
  font-size: 10px; font-weight:700; color:#555;
}

.waveform{ display: flex; align-items: center; gap: 2px; height: 40px; margin: 6px 0; }
.waveform span{ width: 2px; background: #3355ee; border-radius: 1px; }
.phone-screen.is-dark .waveform span{ background: #6f8bff; }

.metric-row{ display:flex; gap:8px; }
.metric-row .app-card{ flex:1; }
.metric-value{ font-size:16px; font-weight:700; }

/* ---- Image carousel ---- */
.carousel-wrap{ position: relative; }
.carousel{
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 10px 4px 14px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  justify-content: flex-start;
}
.carousel::-webkit-scrollbar{ display: none; }
.carousel video{
  scroll-snap-align: center;
  flex: 0 0 auto;
  height: 520px;
  width: auto;
  border-radius: var(--radius-md);
  object-fit: cover;
}
.carousel img{
  scroll-snap-align: center;
  flex: 0 0 auto;
  height: 520px;
  width: auto;
  border-radius: 0;
}
.carousel-btn{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--pill-bg);
  border: 1px solid var(--card-border);
  backdrop-filter: blur(10px);
  color: var(--fg);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  z-index: 2;
  font-size: 16px;
}
.carousel-btn:hover{ background: var(--pill-bg-hover); }
.carousel-btn.prev{ left: 0; }
.carousel-btn.next{ right: 0; }

/* ---- Stat grid (Omnia dashboard) ---- */
.stat-grid{
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  background: #0a0a0a;
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.stat-tile{
  background: rgba(255,255,255,0.04);
  border-radius: 14px;
  padding: 16px;
  min-height: 108px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.stat-tile .label{ font-size: 11px; color: var(--muted); }
.stat-tile .value{
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 32px;
  font-weight: 500;
  color: var(--fg);
}
.stat-tile .value small{
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}
.stat-tile.wide{ grid-column: span 2; }
.stat-tile .bars{ display:flex; align-items:flex-end; gap:3px; height:34px; }
.stat-tile .bars span{ width:5px; background: linear-gradient(180deg, #f2c14e, #b98a2f); border-radius:2px; }

/* ---- Live prototype embed ---- */
.prototype-embed{
  position: relative;
  width: 402px;
  height: 874px;
  max-width: 100%;
  margin: 0 auto;
  background: #000;
  border-radius: 52px;
  overflow: hidden;
  box-shadow: 0 30px 60px -12px rgba(0,0,0,0.55);
}
.prototype-embed iframe{
  display: block;
  position: absolute;
  top: -40px;
  left: -40px;
  width: 482px;
  height: 954px;
  border: 0;
}

/* ---- Two-image row (side by side, smaller) ---- */
.img-row{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.img-row img{ width: 100%; border-radius: var(--radius-md); }

/* ---- Contact chip cluster (decorative) ---- */
.chip-cluster{
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  padding: 32px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
}
.chip{
  display: flex; align-items: center; gap: 8px;
  background: #fff; color: #111;
  padding: 8px 14px 8px 8px;
  border-radius: 999px;
  font-size: 12.5px; font-weight: 600;
}

/* ---- Laptop / tablet mockups ---- */
.laptop-mock{ max-width: 640px; margin: 0 auto; }
.laptop-mock .lid{
  background: #d9d9d9;
  border-radius: 14px 14px 0 0;
  padding: 14px 14px 0;
}
.laptop-mock .screen{
  background: #f4f4f4;
  color: #111;
  border-radius: 8px 8px 0 0;
  padding: 16px;
  min-height: 220px;
  text-align: left;
  font-size: 12px;
}
.laptop-mock .base{
  height: 14px;
  background: linear-gradient(180deg, #bdbdbd, #a5a5a5);
  border-radius: 0 0 10px 10px;
}
.tablet-mock{
  max-width: 560px; margin: 0 auto;
  background: #e9e9ea; border-radius: 22px; padding: 14px;
}
.tablet-mock .screen{
  background: #fff; color: #111; border-radius: 12px; padding: 18px;
  text-align: left; font-size: 12px;
}
.laptop-mock .screen p, .tablet-mock .screen p{ color:#666; font-size:11.5px; margin:0; }

.alert-row{
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px solid #ececec; font-size: 12px;
}
.alert-row:last-child{ border-bottom: none; }
.alert-row .dot{ width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.alert-row .dot.red{ background:#e5484d; }
.alert-row .dot.amber{ background:#f2b705; }
.alert-row .dot.green{ background:#3fb950; }
.alert-row .name{ font-weight:600; flex:1; }
.alert-row .sub{ color:#888; font-size:11px; }

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 860px){
  .site-nav{ padding: 20px 20px; }
  .hero{ padding: 140px 20px 40px; }
  .about-hero{ padding: 140px 0 30px; }
  .container{ padding-left: 20px; padding-right: 20px; }
  .stack{ padding: 0 20px; }
  .project-flow{ padding: 0 20px 30px; gap: 40px; }
  .intro-grid{ grid-template-columns: 1fr; }
  .healthtech-grid{ grid-template-columns: 1fr 1fr; }
  .role-card{ padding: 28px; min-height: 360px; }
  .timeline-row-head{ flex-direction: column; align-items: flex-start; gap: 4px; }
  .connect-links{ padding: 0 20px; }

  .split{ grid-template-columns: 1fr; gap: 24px; }
  .split.reverse .split-media{ order: 1; }
  .split.reverse .split-text{ order: 2; }
  .img-row{ grid-template-columns: 1fr; gap: 16px; }
  .glass-note{ position: static; margin-top: 16px; max-width: none; }
  .device-diagram{ padding: 32px 20px; }
  .diagram-row{ gap: 24px; }
  .device-illustration{ width: 100%; max-width: 300px; order: -1; flex: 0 0 100%; }
  .stat-grid{ grid-template-columns: repeat(2, 1fr); }
  .stat-tile.wide{ grid-column: span 2; }
  .phone{ width: 180px; }
  .phone-screen{ min-height: 330px; }
  .phone--lg{ width: 240px; }
  .phone--lg .phone-screen{ min-height: 460px; }
  .device-mock{ width: 160px; }
  .carousel img{ height: 380px; }
  .carousel video{ height: 380px; }
  .carousel-btn{ display: none; }
}

@media (max-width: 480px){
  .stat-grid{ grid-template-columns: 1fr 1fr; padding: 16px; gap: 10px; }
  .phone-row, .device-mock-row{ gap: 14px; }
  .phone{ width: 150px; border-radius: 26px; }
  .phone-screen{ min-height: 280px; border-radius: 20px; font-size: 9.5px; }
  .device-mock{ width: 130px; }
}
