/* Selvin Chinnaiah, professional page. Same system as Karuvi (Archivo, red #BB081A), calmer volume: white-led, facts first, one signature moment (the ₹0 to ₹2.5 crore line). */
@font-face { font-family: "Archivo"; src: url("/assets/fonts/archivo-var.woff2") format("woff2"); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/assets/fonts/jetbrains-mono-var.woff2") format("woff2"); font-weight: 100 800; font-display: swap; }
:root {
  --ink: #0e0e0e; --ink-2: #2a2a2a; --mute: #5f5f5f; --line: rgba(0,0,0,.1); --paper: #fff; --tint: #f5f3f0;
  --red: #bb081a; --red-hover: #d10a1e; --gold: #b8860b;
  --f-text: "Archivo", system-ui, sans-serif; --f-mono: "JetBrains Mono", ui-monospace, monospace;
  --gut: clamp(20px, 4vw, 56px); --max: 1200px; --sec: clamp(72px, 10vh, 128px);
  --ease: cubic-bezier(.23, 1, .32, 1);
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink-2); font-family: var(--f-text); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, svg { display: block; max-width: 100%; }
figure { margin: 0; }
a { color: inherit; text-underline-offset: .2em; }
h1, h2, h3, h4, p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
dialog { display: none; } dialog[open] { display: block; }

.p-wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gut); }
.p-sec { padding: var(--sec) 0; }
.p-tint { background: var(--tint); }
.p-ink { background: #0b0b0b; color: #d9d9d9; }
.p-ink .p-h2, .p-ink .p-h3, .p-ink .p-h4, .p-ink b { color: #fff; }
.p-kicker { font-family: var(--f-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--red); display: flex; gap: 10px; align-items: center; margin-bottom: 14px; }
.p-kicker::before { content: ""; width: 18px; height: 1px; background: currentColor; }
.p-ink .p-kicker { color: #ff5466; }
.p-h1 { font-stretch: 125%; font-weight: 900; font-size: clamp(34px, 4.4vw, 60px); line-height: 1.02; letter-spacing: -.01em; color: var(--ink); text-wrap: balance; }
.p-h1 em { font-style: normal; color: var(--red); }
.p-h2 { font-stretch: 112%; font-weight: 800; font-size: clamp(28px, 3vw, 42px); line-height: 1.1; letter-spacing: -.015em; color: var(--ink); margin-bottom: clamp(28px, 4vw, 48px); text-wrap: balance; }
.p-h3 { font-stretch: 108%; font-weight: 800; font-size: clamp(19px, 1.6vw, 22px); line-height: 1.25; color: var(--ink); }
.p-h4 { font-weight: 800; font-size: 18px; color: var(--ink); }
.p-lead { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.6; color: var(--ink-2); max-width: 62ch; }
.p-small { font-size: 13px; color: var(--mute); margin-top: 18px; }
.p-ink .p-small { color: #8e8e8e; }
.p-mute { color: var(--mute); font-size: 15px; }
.p-split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.p-split-top { align-items: start; }
.p-three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 4vw, 56px); }
@media (max-width: 900px) { .p-split, .p-three { grid-template-columns: 1fr; } }

/* buttons */
.p-btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; align-items: flex-start; }
.p-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 46px; padding: 11px 20px; border-radius: 999px; border: 1px solid rgba(0,0,0,.28); background: #fff; color: var(--ink); font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; white-space: nowrap; transition: background-color 160ms var(--ease), color 160ms var(--ease), border-color 160ms var(--ease), transform 160ms var(--ease); }
.p-btn:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.p-btn:active { transform: scale(.97); }
.p-btn svg { width: 17px; height: 17px; }
.p-btn-red { background: var(--red); border-color: var(--red); color: #fff; }
.p-btn-red:hover { background: var(--red-hover); border-color: var(--red-hover); }
.p-btn-ink { background: var(--ink); color: #fff; border-color: var(--ink); min-height: 40px; padding: 8px 18px; }
.p-btn-ink:hover { background: var(--red); border-color: var(--red); }
.p-ink .p-btn:not(.p-btn-red) { background: none; color: #fff; border-color: rgba(255,255,255,.4); }
.p-dl { position: relative; }
.p-dl summary { list-style: none; }
.p-dl summary::-webkit-details-marker { display: none; }
.p-dl-menu { position: absolute; z-index: 20; top: calc(100% + 8px); left: 0; min-width: 260px; padding: 8px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 24px 50px -20px rgba(0,0,0,.35); display: grid; }
.p-dl-menu a { display: flex; justify-content: space-between; gap: 16px; padding: 12px 14px; border-radius: 10px; text-decoration: none; font-weight: 600; color: var(--ink); }
.p-dl-menu a span { font-family: var(--f-mono); font-size: 11px; color: var(--mute); }
.p-dl-menu a:hover { background: var(--tint); color: var(--red); }

/* top bar */
.p-top { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 64px; padding: 0 var(--gut); background: rgba(255,255,255,.86); backdrop-filter: blur(14px) saturate(160%); -webkit-backdrop-filter: blur(14px) saturate(160%); border-bottom: 1px solid var(--line); }
.p-name { font-stretch: 125%; font-weight: 900; text-transform: uppercase; font-size: 15px; text-decoration: none; color: var(--ink); letter-spacing: .02em; }
.p-nav { display: flex; align-items: center; gap: 4px; }
.p-nav a:not(.p-btn) { padding: 8px 12px; border-radius: 999px; text-decoration: none; font-size: 14px; font-weight: 500; color: var(--ink-2); }
.p-nav a:not(.p-btn):hover { background: var(--tint); color: var(--red); }
@media (max-width: 860px) { .p-nav a:not(.p-btn) { display: none; } }

/* hero */
.p-hero { padding: clamp(40px, 7vh, 80px) 0 var(--sec); position: relative; overflow: hidden; }
.p-hero::before { content: ""; position: absolute; right: -10%; top: -20%; width: 60vw; height: 60vw; background: radial-gradient(closest-side, rgba(187,8,26,.10), transparent 70%); pointer-events: none; }
.p-hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 72px); align-items: center; position: relative; }
.p-eyebrow { font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mute); margin-bottom: 20px; }
.p-hero .p-lead { margin-top: 22px; }
.p-portrait { position: relative; border-radius: 24px; overflow: hidden; aspect-ratio: 4 / 5; background: #e9e9e9; box-shadow: 0 50px 90px -50px rgba(0,0,0,.55); }
.p-portrait img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; }
.p-portrait::after { content: ""; position: absolute; inset: auto 0 0 0; height: 6px; background: var(--red); }
.p-info { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; margin: clamp(40px, 6vw, 72px) 0 0; background: var(--line); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.p-info div { background: #fff; padding: 18px 18px 20px; }
.p-info dt { font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--red); margin-bottom: 6px; }
.p-info dd { margin: 0; font-size: 14.5px; line-height: 1.45; color: var(--ink); font-weight: 600; }
@media (max-width: 1080px) { .p-info { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) { .p-hero-grid { grid-template-columns: 1fr; } .p-portrait { max-width: 420px; } }
@media (max-width: 560px) { .p-info { grid-template-columns: 1fr 1fr; } }

/* the number */
.p-number { background: #0a0a0a; color: #ddd; padding: var(--sec) 0; position: relative; overflow: hidden; }
.p-number .p-h2 { color: #fff; font-size: clamp(32px, 4vw, 56px); }
.p-number .p-kicker { color: #ff5466; }
.p-chart { position: relative; }
.p-chart svg { width: 100%; height: auto; overflow: visible; }
.p-chart .grid line { stroke: rgba(255,255,255,.08); stroke-width: 1; }
.p-chart .area { fill: rgba(187,8,26,.12); }
.p-chart .ln { fill: none; stroke: #ff3b4e; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 10px rgba(255,59,78,.6)); }
.p-chart .ln.proj { stroke-dasharray: 10 10; opacity: .7; }
.p-chart .pt circle { fill: #ff3b4e; } .p-chart .pt .hollow { fill: #0a0a0a; stroke: #ff3b4e; stroke-width: 3; }
.p-chart-labels { list-style: none; position: absolute; inset: 0; pointer-events: none; }
.p-chart-labels li { position: absolute; display: grid; gap: 2px; max-width: 220px; }
.p-chart-labels b { font-stretch: 125%; font-weight: 900; color: #fff; font-size: clamp(18px, 2.2vw, 30px); line-height: 1; }
.p-chart-labels span { font-size: 13px; color: #9a9a9a; }
.p-chart-labels .l1 { left: 6%; top: 70%; } .p-chart-labels .l2 { left: 33%; top: 46%; } .p-chart-labels .l3 { left: 58%; top: 22%; } .p-chart-labels .l4 { right: 0; top: 0; text-align: right; }
.p-chart-labels .l3 b { color: #ff5466; font-size: clamp(24px, 3.2vw, 44px); }
@media (max-width: 640px) { .p-chart-labels span { display: none; } .p-chart-labels .l1 { left: 4%; top: 64%; } }

/* titles */
.p-titles-img { border-radius: 20px; overflow: hidden; box-shadow: 0 40px 80px -50px rgba(0,0,0,.5); }
.p-steps { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 24px; }
.p-steps li { padding: 22px; border-radius: 16px; border: 1px solid var(--line); display: grid; gap: 6px; align-content: start; transition: border-color 200ms var(--ease), transform 300ms var(--ease); }
.p-steps li:hover { border-color: var(--red); transform: translateY(-3px); }
.p-steps b { color: var(--ink); font-size: 18px; }
.p-steps p { color: var(--mute); font-size: 15px; }
.p-yr { font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; color: var(--red); text-transform: uppercase; }
.p-quote { margin: clamp(40px, 6vw, 64px) 0; padding: 0 0 0 28px; border-left: 4px solid var(--red); max-width: 880px; }
.p-quote p { font-stretch: 108%; font-weight: 700; font-size: clamp(21px, 2.2vw, 30px); line-height: 1.3; color: var(--ink); }
.p-earlier { border-top: 1px solid var(--line); padding-top: 32px; }
.p-earlier .p-h4 { margin-bottom: 18px; }
.p-earlier-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 40px; }
.p-earlier-grid b { display: block; color: var(--ink); margin: 4px 0 2px; }
.p-earlier-grid .p-ticks { margin-top: 14px; }
@media (max-width: 800px) { .p-steps, .p-earlier-grid { grid-template-columns: 1fr; } }

/* lists */
.p-ticks { list-style: none; display: grid; gap: 10px; }
.p-ticks li { position: relative; padding-left: 26px; font-size: 15.5px; line-height: 1.55; }
.p-ticks li::before { content: ""; position: absolute; left: 2px; top: .5em; width: 12px; height: 7px; border-left: 2px solid var(--red); border-bottom: 2px solid var(--red); transform: rotate(-45deg); }
.p-ink .p-ticks li::before { border-color: #ff5466; }
.p-ic { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: rgba(187,8,26,.08); color: var(--red); flex: none; }
.p-ic svg { width: 22px; height: 22px; }

/* desk */
.p-desk { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.p-desk li { background: #fff; border-radius: 18px; padding: 24px; display: grid; gap: 4px; align-content: start; border: 1px solid var(--line); transition: transform 300ms var(--ease), box-shadow 300ms var(--ease); }
.p-desk li:hover { transform: translateY(-4px); box-shadow: 0 30px 50px -30px rgba(0,0,0,.3); }
.p-desk b { font-stretch: 125%; font-weight: 900; font-size: clamp(30px, 3vw, 42px); line-height: 1; color: var(--red); }
.p-desk span { font-weight: 700; color: var(--ink); }
.p-desk p { font-size: 14px; color: var(--mute); margin-top: 8px; }
@media (max-width: 1000px) { .p-desk { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .p-desk { grid-template-columns: 1fr; } }

/* skills */
.p-skills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.p-skill { padding: clamp(22px, 2.6vw, 34px); border: 1px solid var(--line); border-radius: 20px; display: grid; gap: 14px; align-content: start; transition: border-color 200ms var(--ease); }
.p-skill:hover { border-color: rgba(187,8,26,.5); }
.p-skill > p { color: var(--ink-2); }
.p-skill-photo figure { border-radius: 14px; overflow: hidden; margin-bottom: 4px; aspect-ratio: 16 / 8; }
.p-skill-photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 860px) { .p-skills { grid-template-columns: 1fr; } }

/* linkedin */
.p-stats { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: rgba(255,255,255,.1); border-radius: 18px; overflow: hidden; }
.p-stats li { background: #0b0b0b; padding: 28px; display: grid; gap: 8px; align-content: start; }
.p-stats b { font-stretch: 125%; font-weight: 900; font-size: clamp(32px, 3.4vw, 48px); line-height: 1; color: #fff; }
.p-stats li:first-child b { color: #ff5466; }
.p-stats span { font-size: 15px; color: #b5b5b5; }
@media (max-width: 800px) { .p-stats { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .p-stats { grid-template-columns: 1fr; } }

/* creatives spiral */
.p-creatives { overflow: hidden; }
.p-creatives .p-lead { margin-top: -20px; }
.p-spiral { position: relative; height: clamp(520px, 72vh, 700px); margin-top: 24px; perspective: 1400px; }
.p-spiral-ring { list-style: none; position: absolute; left: 50%; top: 44%; width: 0; height: 0; transform-style: preserve-3d; }
.p-spiral-ring li { position: absolute; left: 0; top: 0; transform-style: preserve-3d; }
.p-spiral-ring button { display: block; width: 230px; margin: -170px 0 0 -115px; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 12px; overflow: hidden; box-shadow: 0 30px 60px -30px rgba(0,0,0,.6); transition: box-shadow 300ms var(--ease); }
.p-spiral-ring button img { width: 100%; height: 320px; object-fit: cover; object-position: 50% 0; background: #eee; }
.p-spiral-ring li.is-front button { box-shadow: 0 0 0 3px var(--red), 0 40px 80px -30px rgba(187,8,26,.6); }
.p-spiral-cap { position: absolute; left: 50%; bottom: 64px; transform: translateX(-50%); width: min(640px, calc(100% - 40px)); text-align: center; display: grid; gap: 4px; }
.p-spiral-cap b { color: var(--ink); font-size: 18px; }
.p-spiral-cap span { color: var(--mute); }
.p-spiral-nav { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); display: flex; gap: 10px; }
.p-spiral-nav .p-btn { width: 46px; justify-content: center; padding: 0; }
/* phones and no-JS: a swipeable row */
.p-spiral:not(.is-3d) { height: auto; perspective: none; }
.p-spiral:not(.is-3d) .p-spiral-ring { position: static; width: auto; height: auto; display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 10px var(--gut) 20px; scrollbar-width: none; }
.p-spiral:not(.is-3d) .p-spiral-ring li { position: static; flex: 0 0 auto; scroll-snap-align: center; transform: none !important; opacity: 1 !important; }
.p-spiral:not(.is-3d) .p-spiral-ring button { margin: 0; width: 220px; }
.p-spiral:not(.is-3d) .p-spiral-cap { position: static; transform: none; margin: 16px auto 0; }
.p-spiral:not(.is-3d) .p-spiral-nav { display: none; }

/* AI */
.p-ai { align-items: start; }
.p-ai .p-split { align-items: start; }
.p-ai-side { display: grid; gap: 16px; }
.p-card-dark { padding: 26px; border-radius: 18px; background: #151515; border: 1px solid rgba(255,255,255,.1); display: grid; gap: 12px; }
.p-karuvi { background: linear-gradient(150deg, rgba(187,8,26,.35), #151515 60%); border-color: rgba(187,8,26,.5); }
.p-karuvi .p-btn { justify-self: start; }

/* lead */
.p-lead-grid { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.p-lead-grid li { padding: 24px; border-radius: 18px; border: 1px solid var(--line); display: grid; gap: 16px; align-content: start; font-size: 15.5px; color: var(--ink-2); }
@media (max-width: 1000px) { .p-lead-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .p-lead-grid { grid-template-columns: 1fr; } }

/* cases */
.p-cases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.p-case { position: relative; background: #fff; border-radius: 20px; padding: 28px; border: 1px solid var(--line); display: grid; gap: 16px; align-content: start; overflow: hidden; }
.p-case-n { position: absolute; right: 18px; top: 8px; font-stretch: 125%; font-weight: 900; font-size: 64px; line-height: 1; color: rgba(187,8,26,.08); }
.p-case dl { margin: 0; display: grid; gap: 6px; }
.p-case dt { font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--mute); margin-top: 8px; }
.p-case dd { margin: 0; font-size: 15px; }
.p-case .p-res { font-weight: 700; color: var(--ink); padding: 12px 14px; background: rgba(187,8,26,.06); border-left: 3px solid var(--red); border-radius: 6px; }
.p-mini-cases { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
.p-mini-cases article { padding: 22px 26px; border-radius: 16px; border: 1px dashed rgba(0,0,0,.2); display: grid; gap: 4px; }
.p-mini-cases b { color: var(--ink); }
@media (max-width: 960px) { .p-cases, .p-mini-cases { grid-template-columns: 1fr; } }

/* awards + certs */
.p-awards { list-style: none; display: grid; gap: 10px; }
.p-awards li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); }
.p-awards b { display: block; color: var(--ink); }
.p-awards span { font-size: 14px; color: var(--mute); }
.p-gold { color: var(--gold); } .p-gold svg { width: 36px; height: 36px; }
.p-certs { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.p-certs a, .p-cert-plain { display: grid; gap: 6px; padding: 12px; border-radius: 14px; border: 1px solid var(--line); text-decoration: none; height: 100%; align-content: start; transition: border-color 200ms var(--ease), transform 300ms var(--ease); }
.p-certs a:hover { border-color: var(--red); transform: translateY(-3px); }
.p-certs img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 30%; border-radius: 8px; background: #eee; margin-bottom: 6px; }
.p-certs b { color: var(--ink); font-size: 15px; line-height: 1.3; }
.p-certs span:not(.p-ic) { color: var(--mute); font-size: 13px; }
.p-cert-plain .p-ic { margin: 18px 0 30px; }
.p-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.p-tags span { padding: 6px 12px; border-radius: 999px; background: var(--tint); font-size: 13px; color: var(--ink-2); }
.p-tint .p-tags span { background: #fff; }
.p-plain { list-style: none; display: grid; gap: 14px; margin-top: 14px; }
.p-plain b { display: block; color: var(--ink); }
.p-plain span { color: var(--mute); font-size: 15px; }
.p-three .p-h3 { margin-bottom: 4px; }
@media (max-width: 520px) { .p-certs { grid-template-columns: 1fr; } }

/* contact */
.p-contact { padding: var(--sec) 0 32px; background: #0a0a0a; color: #ddd; position: relative; overflow: hidden; }
.p-contact::before { content: ""; position: absolute; left: -10%; bottom: -30%; width: 70vw; height: 70vw; background: radial-gradient(closest-side, rgba(187,8,26,.35), transparent 70%); pointer-events: none; }
.p-contact .p-h1 { color: #fff; margin-bottom: 28px; }
.p-contact .p-kicker { color: #ff5466; }
.p-contact-list { list-style: none; display: grid; gap: 10px; }
.p-contact-list a, .p-contact-list span { display: inline-flex; gap: 12px; align-items: center; font-size: clamp(17px, 1.5vw, 21px); color: #fff; text-decoration: none; }
.p-contact-list a:hover { color: #ff5466; }
.p-contact-list svg { width: 20px; height: 20px; color: #ff5466; }
.p-contact .p-btn:not(.p-btn-red) { background: none; color: #fff; border-color: rgba(255,255,255,.4); }
.p-contact .p-btn:not(.p-btn-red):hover { background: #fff; color: var(--ink); }
.p-contact-img { justify-self: center; width: min(360px, 80%); border-radius: 24px; overflow: hidden; position: relative; }
.p-foot { margin-top: 64px; font-size: 13px; color: #8a8a8a; position: relative; }
.p-foot a { color: #bbb; }

/* reveal */
.js-motion .rv { opacity: 0; transform: translateY(16px); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition-duration: 1ms !important; } html { scroll-behavior: auto; } }
.p-chart { padding-bottom: 56px; }
.p-chart-labels .l1 { left: 6%; top: auto; bottom: 0; }
.p-skills { display: block; columns: 2; column-gap: 20px; }
.p-skill { break-inside: avoid; margin-bottom: 20px; }
@media (max-width: 860px) { .p-skills { columns: 1; } }
.p-contact-img { width: min(320px, 80%); aspect-ratio: 4 / 5; }
.p-contact-img img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 8%; }
@media (max-width: 640px) {
  .p-chart { padding-bottom: 0; }
  .p-chart-labels { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 20px; }
  .p-chart-labels li, .p-chart-labels .l1, .p-chart-labels .l4 { position: static; text-align: left; max-width: none; }
  .p-chart-labels span { display: block; }
  .p-desk { grid-template-columns: 1fr 1fr; gap: 10px; }
  .p-desk li { padding: 16px; }
  .p-desk p { display: none; }
}
.p-number .p-h2 { max-width: 20ch; } img { height: auto; }
.p-portrait { aspect-ratio: 3 / 4; }
.p-portrait img { object-position: 50% 20%; }
.p-contact-img { width: min(300px, 70%); aspect-ratio: 720 / 1282; }
.p-contact-img img { object-position: 50% 50%; }

/* round 4: layered reading (nothing removed, details open on demand) */
.p-top { position: sticky; }
.p-progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: transparent; pointer-events: none; }
.p-progress i { display: block; height: 100%; background: var(--red); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); }
.p-nav a.is-active:not(.p-btn) { color: var(--red); background: rgba(187,8,26,.08); }
@media (max-width: 860px) {
  .p-top { height: auto; flex-wrap: wrap; row-gap: 6px; padding-top: 10px; padding-bottom: 8px; }
  .p-nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; gap: 2px; }
  .p-nav::-webkit-scrollbar { display: none; }
  .p-nav a:not(.p-btn) { display: inline-flex; white-space: nowrap; font-size: 13px; padding: 6px 10px; }
  .p-nav .p-btn-ink { display: none; }
}
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
details .m-c { display: none; } details[open] > summary .m-o { display: none; } details[open] > summary .m-c { display: inline; }

.p-skills { display: grid; columns: auto; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: start; }
.p-skill { margin: 0; gap: 12px; }
.p-skill-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.p-skill-num { text-align: right; display: grid; }
.p-skill-num b { font-stretch: 125%; font-weight: 900; font-size: clamp(28px, 2.6vw, 38px); line-height: 1; color: var(--red); }
.p-skill-num span { font-size: 12px; color: var(--mute); margin-top: 4px; }
.p-skill > p { font-size: 15.5px; color: var(--ink-2); }
.p-skill-photo { border-radius: 14px; overflow: hidden; aspect-ratio: 16 / 9; margin: 0 0 4px; }
.p-skill-photo img { width: 100%; height: 100%; object-fit: cover; }
.p-more > summary { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 14px; color: var(--red); }
.p-more > summary::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform 200ms var(--ease); }
.p-more[open] > summary::after { transform: rotate(-135deg) translateY(-2px); }
.p-more .p-ticks { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
@media (max-width: 1000px) { .p-skills { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .p-skills { grid-template-columns: 1fr; } }

.p-fold > summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 0; }
.p-fold-hint { font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--red); }
.p-fold .p-earlier-grid { padding: 8px 0 12px; }
.p-earlier { padding-top: 0; border-bottom: 1px solid var(--line); }

.p-cases-nav { display: flex; justify-content: flex-end; gap: 8px; margin: -24px 0 16px; }
.p-cases-nav .p-btn { width: 46px; justify-content: center; padding: 0; }
.p-cases { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gut); padding-bottom: 12px; scrollbar-width: thin; scrollbar-color: var(--red) transparent; }
.p-case { flex: 0 0 min(420px, 86%); scroll-snap-align: start; }
.p-case-mini { flex-basis: min(320px, 76%); }
.p-cases:focus-visible { outline: 2px solid var(--red); outline-offset: 6px; }

/* AI Content page (/selvinchinnaiahs/): swipeable story cards */
.p-row-nav { display: flex; justify-content: flex-end; gap: 8px; margin: 8px 0 16px; }
.p-row-nav .p-btn { width: 46px; justify-content: center; padding: 0; }
.p-films { list-style: none; display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding-inline: var(--gut); padding-bottom: 12px; scrollbar-width: thin; scrollbar-color: var(--red) transparent; }
.p-films:focus-visible { outline: 2px solid var(--red); outline-offset: 6px; }
.p-film { flex: 0 0 min(372px, 84%); scroll-snap-align: start; display: grid; gap: 16px; align-content: start; padding: clamp(16px, 1.8vw, 22px); border: 1px solid var(--line); border-radius: 20px; transition: border-color 200ms var(--ease); }
.p-film:hover { border-color: rgba(187,8,26,.5); }
.p-film-img { display: block; border-radius: 14px; overflow: hidden; aspect-ratio: 16 / 10; background: #e9e9e9; }
.p-film-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease); }
.p-film:hover .p-film-img img { transform: scale(1.03); }
.p-film > div { display: grid; gap: 10px; justify-items: start; }
.p-film > div > p:not(.p-yr) { color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.p-film-award { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--ink) !important; }
.p-film-award .p-gold svg { width: 30px; height: 30px; flex: none; }

/* AI Content page: Karuvi button sits at the foot of its column, level with the card's own button */
.p-ai .p-split.p-split-foot, .p-split-foot { align-items: stretch; }   /* beats .p-ai .p-split { align-items: start } above */
.p-split-foot > div:first-child { display: flex; flex-direction: column; gap: 14px; }
.p-btn-end { align-self: start; margin-top: auto; }
@media (min-width: 901px) { .p-split-foot > div:first-child { padding-bottom: 26px; } }   /* matches the card's own bottom padding, so both buttons sit on one line */
@media (max-width: 900px) { .p-btn-end { margin-top: 4px; } }
.p-teach-img { border-radius: 16px; overflow: hidden; aspect-ratio: 16 / 9; margin: 4px 0 6px; }
.p-teach-img img { width: 100%; height: 100%; object-fit: cover; }

/* fold affordance: a chevron that turns, so the summary reads as something you open */
.p-fold-hint { display: inline-flex; align-items: center; gap: 8px; }
.p-fold-hint svg { width: 18px; height: 18px; transition: transform 220ms var(--ease); }
.p-fold[open] .p-fold-hint svg { transform: rotate(180deg); }
.p-fold > summary { cursor: pointer; }
.p-fold > summary:hover .p-fold-hint { color: var(--ink); }

/* AI Content page: the earlier films inside the fold */
.p-earlier-films { gap: 18px; }
.p-earlier-films li { display: grid; gap: 4px; justify-items: start; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.p-earlier-films li:last-child { border-bottom: 0; padding-bottom: 0; }
.p-earlier-films span { color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.p-earlier-films a { font-weight: 700; font-size: 14px; color: var(--red); text-decoration: none; }
.p-earlier-films a:hover { text-decoration: underline; }

/* AI Content page: Karuvi block */
.p-karuvi-logo { width: clamp(150px, 15vw, 196px); height: auto; display: block; margin-bottom: 20px; }
.p-ink .p-lead-bright { color: #e8e8e8; }
