/* Divyanshi Verma portfolio. Direction: a designer's contact sheet.
   Paper and graphite, with haldi yellow used only as a marker fill. */
:root {
  --ground: #f3f3ef;
  --surface: #ffffff;
  --ink: #16171a;
  --ink-2: #4a4d55;
  --rule: #d6d6cf;
  --marker: #f4c430;
  --marker-ink: #16171a;
  --link: #1d4ed8;
  --frame: #16171a;
  --shadow: 0 1px 0 rgba(0,0,0,.04), 0 18px 40px -24px rgba(20,22,26,.35);
  --display: "Young Serif", Georgia, serif;
  --body: "Schibsted Grotesk", system-ui, sans-serif;
  --gut: clamp(16px, 4vw, 56px);
  --max: 1360px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #141518;
    --surface: #1d1f24;
    --ink: #ecebe6;
    --ink-2: #a9abb3;
    --rule: #33363d;
    --marker: #e9b824;
    --marker-ink: #141518;
    --link: #8fb0ff;
    --frame: #3a3d45;
    --shadow: 0 1px 0 rgba(255,255,255,.03), 0 20px 50px -24px rgba(0,0,0,.8);
  }
}
:root[data-theme="dark"] {
  --ground: #141518; --surface: #1d1f24; --ink: #ecebe6; --ink-2: #a9abb3;
  --rule: #33363d; --marker: #e9b824; --marker-ink: #141518; --link: #8fb0ff;
  --frame: #3a3d45; --shadow: 0 1px 0 rgba(255,255,255,.03), 0 20px 50px -24px rgba(0,0,0,.8);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font: 400 17px/1.55 var(--body); overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--marker); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--marker); color: var(--marker-ink); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gut); }

/* header */
.top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.top .name { font: 400 22px/1 var(--display); text-decoration: none; }
.top nav { display: flex; gap: clamp(14px, 3vw, 28px); font-size: 15px; flex-wrap: wrap; }
.top nav a { text-decoration: none; color: var(--ink-2); }
.top nav a:hover, .top nav a[aria-current] { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }

.mark { -webkit-box-decoration-break: clone; box-decoration-break: clone; background: linear-gradient(transparent 58%, var(--marker) 58%, var(--marker) 92%, transparent 92%); padding: 0 .08em; }

@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .mark { background: none; color: var(--marker); } }
:root[data-theme="dark"] .mark { background: none; color: var(--marker); }

/* hero: name, index of live sites, and a stage that cycles through them */
.hx { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); grid-template-areas: "head head" "copy stage" "index stage"; column-gap: clamp(28px, 5vw, 80px); row-gap: clamp(24px, 3vw, 40px); padding: clamp(40px, 6vw, 88px) 0 clamp(64px, 9vw, 120px); align-items: start; }
.hx-head { grid-area: head; }
.hx-copy { grid-area: copy; }
.hx-eyebrow { margin: 0 0 18px; font-size: 15px; color: var(--ink-2); letter-spacing: .02em; }
.hx-name { font: 400 clamp(56px, 9.4vw, 136px)/.92 var(--display); margin: 0; letter-spacing: -.025em; }
.hx-lede { margin: 6px 0 0; font-size: clamp(18px, 1.5vw, 21px); line-height: 1.45; color: var(--ink-2); max-width: 30ch; }
.hx-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.btn { display: inline-block; padding: 12px 20px; border-radius: 999px; background: var(--ink); color: var(--ground); font-weight: 600; text-decoration: none; border: 1.5px solid var(--ink); }
.btn:hover { background: var(--marker); border-color: var(--marker); color: var(--marker-ink); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: var(--ink); color: var(--ground); border-color: var(--ink); }

.hx-index { grid-area: index; }
.hx-label { margin: 0 0 10px; font-size: 13px; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-2); }
.hx-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 28px; border-top: 1px solid var(--rule); }
.hx-list li { break-inside: avoid; border-bottom: 1px solid var(--rule); }
.hx-list a { display: flex; align-items: baseline; gap: 10px; padding: 8px 0; text-decoration: none; color: var(--ink-2); font-size: 15px; transition: color .2s, padding-left .25s; }
.hx-list .n { font-size: 12px; font-variant-numeric: tabular-nums; opacity: .7; }
.hx-list a.on, .hx-list a:hover, .hx-list a:focus-visible { color: var(--ink); padding-left: 8px; }
.hx-list a.on .n { color: var(--ink); opacity: 1; }
.hx-list a.on::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--marker); margin-left: auto; align-self: center; }

.hx-stage { grid-area: stage; position: relative; margin: 8px 0 0 7%; }
.hx-laptop .lt-screen img, .hx-phone .ip-screen img { position: absolute; inset: 0; opacity: 0;
}
.hx-laptop .lt-screen img, .hx-phone .ip-screen img { transition: opacity .7s ease, transform 6s ease; }
.hx-laptop .lt-screen img.on, .hx-phone .ip-screen img.on { opacity: 1; }
.hx-laptop .lt-screen img.on { transform: scale(1.02); }
.hx-phone { position: absolute; left: -8%; bottom: 4%; width: 23%; }
.hx-url { margin: 18px 0 0; text-align: center; font-size: 14px; color: var(--ink-2); letter-spacing: .02em; }
.hx-url::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--marker); margin-right: 8px; vertical-align: 1px; }

/* section heads */
.sec { padding: clamp(40px, 6vw, 80px) 0; border-top: 1px solid var(--rule); }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: clamp(24px, 4vw, 44px); }
.sec-head h2 { font: 400 clamp(30px, 3.6vw, 48px)/1.05 var(--display); margin: 0; }
.sec-head p { margin: 0; color: var(--ink-2); max-width: 46ch; }

/* lead work: alternating wide rows */
.lead { display: grid; gap: clamp(48px, 7vw, 96px); }
.lead-item { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: clamp(20px, 3vw, 44px); align-items: center; text-decoration: none; }
.lead-item:nth-child(even) { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
.lead-item:nth-child(even) .lead-media { order: 2; }
.lead-media { position: relative; }
.lead-media { padding-bottom: 4%; }
.lead-phone { position: absolute; right: -3%; bottom: 0; width: 22%; }
.lead-item:nth-child(even) .lead-phone { right: auto; left: -3%; }
.lead-media .laptop { transition: transform .5s ease; }
.lead-item:hover .lead-media .laptop { transform: translateY(-4px); }
.lead-text h3 { font: 400 clamp(28px, 3vw, 42px)/1.05 var(--display); margin: 0 0 10px; }
.lead-text p { margin: 0 0 14px; color: var(--ink-2); }
.lead-text .go { font-weight: 600; text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--marker); text-decoration-thickness: 3px; }
.rank { font: 400 15px/1 var(--body); color: var(--ink-2); display: block; margin-bottom: 12px; }

/* more work grid: 4 columns at wide, cards of mixed height */
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px) clamp(12px, 1.6vw, 22px); }
.card { text-decoration: none; display: block; }
.card .thumb { border-radius: 6px; overflow: hidden; aspect-ratio: 4/3; background: var(--surface); box-shadow: var(--shadow); }
.thumb-device { transition: transform .4s ease; }
.thumb-device .lt-base { width: 106%; margin-left: -3%; }
.card:hover .thumb-device { transform: translateY(-3px); }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .6s ease; }
.card:hover .thumb img { transform: scale(1.04); }
.card h3 { font: 600 18px/1.25 var(--body); margin: 12px 0 2px; }
.card p { margin: 0; font-size: 15px; color: var(--ink-2); }

/* index table */
.index { width: 100%; border-collapse: collapse; font-size: 16px; }
.index th { text-align: left; font-weight: 500; color: var(--ink-2); padding: 0 12px 10px 0; border-bottom: 1px solid var(--ink); font-size: 14px; }
.index td { padding: 14px 12px 14px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.index td:first-child { font-weight: 600; white-space: nowrap; }
.index a { text-underline-offset: 4px; }
.index tr:hover td { background: color-mix(in srgb, var(--marker) 14%, transparent); }

/* behance */
.be-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.be-grid .card .thumb { aspect-ratio: 4/3 !important; }

/* about */
.about { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 5vw, 80px); }
.about h2 { font: 400 clamp(30px, 3.6vw, 48px)/1.05 var(--display); margin: 0; }
.about p { margin: 0 0 16px; max-width: 58ch; }
.mail { font: 400 clamp(22px, 3vw, 40px)/1.2 var(--display); word-break: break-all; }

footer { padding: 28px 0 48px; color: var(--ink-2); font-size: 14px; border-top: 1px solid var(--rule); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* project page */
.p-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(20px, 4vw, 64px); padding: clamp(36px, 6vw, 80px) 0 clamp(28px, 4vw, 48px); align-items: end; }
.p-head h1 { font: 400 clamp(40px, 6vw, 84px)/1 var(--display); margin: 0 0 12px; }
.p-head .tag { font-size: clamp(18px, 1.6vw, 22px); margin: 0; }
.p-head .what { color: var(--ink-2); margin: 0 0 14px; }
.p-head .live { font-weight: 600; text-decoration-color: var(--marker); text-decoration-thickness: 3px; text-underline-offset: 5px; }
.p-hero { position: relative; padding: 0 0 4% 0; }
.p-hero-phone { position: absolute; left: -1%; bottom: 0; width: 17%; }
.block { padding: clamp(40px, 6vw, 72px) 0 0; }
.block h2 { font: 600 15px/1.2 var(--body); color: var(--ink-2); margin: 0 0 18px; padding-top: 12px; border-top: 1px solid var(--ink); }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(12px, 2vw, 24px); }
.pair figure, .phones figure, .flow figure, .long figure { margin: 0; }
.long img { border-radius: 6px; box-shadow: var(--shadow); width: 100%; }
figcaption { font-size: 14px; color: var(--ink-2); margin-top: 8px; }
.phones { display: flex; gap: clamp(16px, 4vw, 48px); justify-content: flex-start; flex-wrap: wrap; }
.phones figure { width: min(300px, 42vw); }
.phones figcaption, .pair figcaption { margin-top: 12px; font-size: 14px; color: var(--ink-2); }
.long { max-height: 1100px; overflow: hidden; border-radius: 6px; }
.flow { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(280px, 1fr); gap: 16px; overflow-x: auto; padding-bottom: 12px; scroll-snap-type: x mandatory; }
.flow figure { scroll-snap-align: start; }
.flow img { border-radius: 6px; box-shadow: var(--shadow); width: 100%; }
.flow .step { font: 400 26px/1 var(--display); display: block; margin-bottom: 8px; }
.points { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(20px, 4vw, 56px); }
.points li { padding: 16px 0; border-bottom: 1px solid var(--rule); }
.note { color: var(--ink-2); font-size: 15px; }
.pager { display: flex; justify-content: space-between; gap: 16px; padding: 56px 0; font: 400 clamp(20px, 2.4vw, 30px)/1.2 var(--display); }
.pager a { text-decoration: none; }
.pager a:hover { text-decoration: underline; text-decoration-color: var(--marker); text-decoration-thickness: 3px; }
.pager small { display: block; font: 400 14px/1.4 var(--body); color: var(--ink-2); }

/* reveal: images wipe in once, only if motion is allowed */
@media (prefers-reduced-motion: no-preference) {
  .js .rv { clip-path: inset(0 0 100% 0); transition: clip-path .9s cubic-bezier(.2,.7,.2,1); }
  .js .rv.in { clip-path: inset(-15% -15% -15% -15%); }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

@media (max-width: 1024px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .be-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .p-head, .about { grid-template-columns: 1fr; }
  .hx { grid-template-columns: 1fr; grid-template-areas: "head" "copy" "stage" "index"; row-gap: 28px; }
  .hx-stage { margin: 8px 0 13% 10%; }
  .hx-phone { left: -9%; width: 24%; bottom: 10%; }
  .lead-item, .lead-item:nth-child(even) { grid-template-columns: 1fr; }
  .lead-item:nth-child(even) .lead-media { order: 0; }
  .lead-media { margin-right: 8%; }
  .lead-item:nth-child(even) .lead-media { margin: 0 0 0 8%; }
  .lead-phone { right: -8%; width: 24%; }
  .lead-item:nth-child(even) .lead-phone { left: -8%; }
  .lead-text { padding-top: 18px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .points { grid-template-columns: 1fr; }
  .index .hide-s { display: none; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .top { flex-direction: column; gap: 10px; }
  .top nav { gap: 18px; font-size: 15px; }
  .pair { grid-template-columns: 1fr; }
  .be-grid { grid-template-columns: 1fr; }
  .index td:first-child { white-space: normal; }
  .flow { grid-auto-columns: 82%; }
  .hx-name span { display: block; padding-left: .35em; }
  .hx-list { column-gap: 18px; }
  .hx-list a { font-size: 14px; }
  .hx-url { font-size: 13px; }
}

/* ---------- device frames ----------
   Sizes are in container units, so a frame looks the same at any width.
   The screen box carries the screenshot's own ratio, so nothing is cropped. */
:root { --metal-edge: #c4c7cd; --metal-1: #e6e8eb; --metal-2: #cdd0d5; --metal-3: #a2a6ad; --bezel: #0e0f11; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --metal-edge: #5a5e66; --metal-1: #50535a; --metal-2: #393b41; --metal-3: #26282c; } }
:root[data-theme="dark"] { --metal-edge: #5a5e66; --metal-1: #50535a; --metal-2: #393b41; --metal-3: #26282c; }

.laptop { container-type: inline-size; filter: drop-shadow(0 14px 22px rgba(15, 17, 20, .22)); }
.lt-lid { position: relative; width: 100%; margin: 0 auto; padding: 1.9cqw 1.9cqw 2.3cqw; background: var(--bezel); border-radius: 2.6cqw 2.6cqw .4cqw .4cqw; box-shadow: inset 0 0 0 .2cqw #2c2f35, 0 0 0 .26cqw var(--metal-edge); }
.lt-lid::before { content: ""; position: absolute; top: .9cqw; left: 50%; width: .6cqw; height: .6cqw; margin-left: -.3cqw; border-radius: 50%; background: #23262c; box-shadow: inset 0 0 0 .14cqw #121316; }
.lt-screen { position: relative; aspect-ratio: 1440 / 900; overflow: hidden; border-radius: .3cqw; background: #000; }
.lt-base { position: relative; width: 110%; margin-left: -5%; height: 2.6cqw; background: linear-gradient(var(--metal-1), var(--metal-2) 50%, var(--metal-3)); border-radius: .2cqw .2cqw 2cqw 2cqw / .2cqw .2cqw 2.4cqw 2.4cqw; box-shadow: inset 0 .15cqw 0 rgba(255, 255, 255, .35); }
.lt-base::before { content: ""; position: absolute; top: 0; left: 50%; width: 14cqw; height: .85cqw; margin-left: -7cqw; border-radius: 0 0 1cqw 1cqw; background: var(--metal-3); opacity: .55; }

.iphone { container-type: inline-size; filter: drop-shadow(0 16px 24px rgba(15, 17, 20, .26)); }
.ip-body { position: relative; padding: 2.9cqw; background: #000; border-radius: 15.5cqw; box-shadow: inset 0 0 0 .55cqw #4a4d53, 0 0 0 .45cqw var(--metal-edge); }
.ip-screen { position: relative; aspect-ratio: 390 / 844; overflow: hidden; border-radius: 12.8cqw; background: #000; }
.ip-island { position: absolute; top: 5.3cqw; left: 50%; width: 25cqw; height: 7.2cqw; margin-left: -12.5cqw; border-radius: 4cqw; background: #000; z-index: 2; }
.ip-btn { position: absolute; right: -.95cqw; top: 29cqw; width: .7cqw; height: 16cqw; border-radius: 0 .4cqw .4cqw 0; background: var(--metal-edge); }
.ip-btn::before { content: ""; position: absolute; left: calc(-100cqw - 1.2cqw); top: -5cqw; width: .7cqw; height: 10cqw; border-radius: .4cqw 0 0 .4cqw; background: var(--metal-edge); box-shadow: 0 13cqw 0 var(--metal-edge); }

.lt-screen img, .ip-screen img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }

/* phones: keep the laptop base inside the page gutter */
@media (max-width: 520px) {
  .lt-base { width: 104%; margin-left: -2%; }
  .p-hero-phone { left: 0; }
}
