/* ============================================================
   work.css — featured projects, their mockups, and the
   long-form case studies
   Preston Thoman · Palm Springs portfolio

   Loaded on home.html and project.html after the other sheets.

   Each featured project has its own palette, set as local custom
   properties on its stage (never on :root, which would invalidate
   style for the whole document on this page):
     Weavoly   warm and intimate — apricot, coral, plum
     Evident  restrained and editorial — paper, graphite, cobalt
     Daybook  light beige and dark red, with a paper grain
     Proximity Pulse  medical green and teal, from its own deck
   --hi is each palette's accent re-tuned to read on the site's
   own dark purple, for numbers, rules and links around a stage.

   Mockups are sized with container-query units: a sized stage
   (.stage--sized) is a size container, and every device is an
   inline-size container, so a phone and all of its type scale
   together with whatever box they are dropped into.
   ============================================================ */

.feature--weavoly, .stage--weavoly, .study[data-theme="weavoly"]  { --hi: #ff9f7f; }
.feature--evident, .stage--evident, .study[data-theme="evident"] { --hi: #aebcff; }
.feature--daybook, .stage--daybook, .study[data-theme="daybook"] { --hi: #f0a59c; }
.feature--proximity, .stage--proximity, .study[data-theme="proximity"] { --hi: #7fd6b4; }
.study[data-theme="annenberg"] { --hi: #e8806b; }   /* brick, from the building itself */
.study[data-theme="disney"]    { --hi: #8fa2ff; }

/* ============================================================
   HOME — THE FEATURED ROWS
   ============================================================ */
.work__intro .lede { max-width: 58ch; }

.features {
  display: grid;
  gap: clamp(3.5rem, 9vw, 6.5rem);
  margin-top: clamp(2.2rem, 5vw, 3.5rem);
}
.feature {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(1.6rem, 4.5vw, 4rem);
  align-items: center;
}
.feature--flip { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); }
.feature--flip .stage { order: 2; }

.feature__index {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem .9rem;
  font-size: .68rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--muted); margin-bottom: .9rem;
}
.feature__index b {
  font-family: "Syne", sans-serif; font-weight: 700; letter-spacing: .06em;
  font-size: .9rem; color: var(--hi);
}
.feature__title {
  font-family: "Syne", sans-serif; font-weight: 700;
  font-size: clamp(2.2rem, 5.4vw, 3.6rem);
  line-height: 1; letter-spacing: -.035em;
  margin-bottom: 1rem;
}
.feature__title a { transition: color .3s; }
.feature__title a:hover { color: var(--hi); }
.feature__desc {
  color: rgba(255, 236, 205, .78);
  font-size: clamp(1rem, 1.6vw, 1.12rem); line-height: 1.6;
  max-width: 40ch; margin-bottom: 1.4rem;
  text-wrap: pretty;
}
.feature__meta {
  display: grid; grid-template-columns: auto 1fr; gap: .45rem 1.2rem;
  margin: 0 0 1.7rem;
  padding-top: 1.1rem; border-top: 1px solid var(--line);
  font-size: .88rem;
}
.feature__meta dt {
  font-size: .62rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--muted); padding-top: .2rem;
}
.feature__meta dd { color: var(--cream); }

/* the shelf below the featured rows */
.work__more {
  display: flex; align-items: center; gap: 1.25rem;
  margin: clamp(4rem, 10vw, 6.5rem) 0 1rem;
}
.work__more h3 {
  flex: none;
  font-family: "Syne", sans-serif; font-weight: 700;
  font-size: clamp(1.3rem, 2.6vw, 1.7rem); letter-spacing: -.015em;
}

@media (max-width: 860px) {
  .feature, .feature--flip { grid-template-columns: 1fr; }
  .feature--flip .stage { order: 0; }
}

/* ============================================================
   THE STAGE — a themed panel a mockup sits on
   ============================================================ */
.stage {
  position: relative;
  margin: 0;
  border-radius: var(--r);
  overflow: hidden;
  container-type: inline-size;
  isolation: isolate;
}
.stage--sized { container-type: size; aspect-ratio: 1.12; }
.stage--evident.stage--sized { aspect-ratio: 1.3; }
.stage--hero { aspect-ratio: 16 / 9; container-type: size; }
@media (max-width: 700px) {
  .stage--sized { aspect-ratio: .95; }
  .stage--evident.stage--sized { aspect-ratio: 1.1; }
}
.stage__box, .mock, .comp { position: absolute; inset: 0; }
.stage--plate .stage__box, .stage--plate .mock, .stage--plate .comp { position: static; }

/* Each stage is one project's own flat ink with a single hard horizon,
   printed rather than blended — the same rule as the sky. */
.stage--weavoly {
  background: linear-gradient(180deg, #f39a76 0 64%, #e0654f 64% 100%);
}
.stage--evident {
  background:
    linear-gradient(rgba(28, 27, 25, .045) 1px, transparent 1px) 0 0 / 100% 28px,
    linear-gradient(90deg, rgba(28, 27, 25, .045) 1px, transparent 1px) 0 0 / 28px 100%,
    #ece8df;
}
.stage--proximity {
  background: linear-gradient(180deg, #4fae8c 0 64%, #2c7a64 64% 100%);
}
/* paper grain: two offset dot fields, no image and no mask */
.stage--daybook {
  background:
    radial-gradient(rgba(124, 24, 32, .07) 1px, transparent 1.4px) 0 0 / 7px 7px,
    radial-gradient(rgba(60, 30, 10, .05) 1px, transparent 1.6px) 3px 4px / 11px 11px,
    #e8d9bf;
}

/* the composition settles in once its stage is revealed; only
   children move, so the observed element itself never clips */
.stage[data-reveal] .comp > * {
  transition: opacity .9s var(--ease), translate 1.1s var(--ease);
}
.stage[data-reveal]:not(.is-revealed) .comp > * { opacity: 0; translate: 0 1.6rem; }
.stage[data-reveal] .comp > :nth-child(2) { transition-delay: .12s; }
.stage[data-reveal] .comp > :nth-child(3) { transition-delay: .24s; }
.stage[data-reveal] .comp > :nth-child(4) { transition-delay: .36s; }

/* ============================================================
   DEVICES
   ============================================================ */
.dv { container-type: inline-size; }
.dv--phone {
  --ph: 80cqh;
  position: relative;
  width: calc(var(--ph) * .4615); height: var(--ph);
  /* sized from --ph, not cq units: on the device itself those would
     resolve against the stage rather than the phone */
  padding: calc(var(--ph) * .015);
  border-radius: calc(var(--ph) * .07);
  background: linear-gradient(160deg, #3b3236, #121012);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .14),
    0 calc(var(--ph) * .03) calc(var(--ph) * .08) rgba(30, 6, 16, .35),
    0 calc(var(--ph) * .01) calc(var(--ph) * .02) rgba(30, 6, 16, .22);
}
.dv__screen {
  position: relative; height: 100%;
  display: flex; flex-direction: column; gap: .55em;
  padding: 0 .9em .9em;
  border-radius: 12cqw;
  overflow: hidden;
  font-family: "Outfit", system-ui, sans-serif; font-weight: 400;
  font-size: 5.3cqw; line-height: 1.25;
}
/* the island */
.dv__screen::before {
  content: ""; position: absolute; top: 2.8cqw; left: 50%;
  width: 26cqw; height: 6.5cqw; border-radius: 99px;
  background: #0d0b0c; transform: translateX(-50%);
}
.dv__status {
  display: flex; justify-content: space-between; align-items: center;
  padding: .95em .5em .35em; font-size: .62em; font-weight: 600;
}
.dv__status i { width: 2em; height: .9em; border-radius: .25em; border: 1.5px solid currentColor; opacity: .7; }

.dv--browser {
  border-radius: 1.4cqw;
  overflow: hidden;
  background: #fbfaf7; color: #1c1b19;
  font-size: 1.9cqw; line-height: 1.3;
  box-shadow: 0 2cqw 6cqw rgba(28, 27, 25, .2), 0 0 0 1px rgba(28, 27, 25, .08);
}
.dv__bar {
  display: flex; align-items: center; gap: .4em;
  padding: .7em .9em; border-bottom: 1px solid rgba(28, 27, 25, .08);
  background: #f3f0ea; font-size: .78em; color: #77736b;
}
.dv__bar i { width: .75em; height: .75em; border-radius: 50%; background: #d8d3c9; }
.dv__bar span { margin-left: .8em; padding: .2em .9em; border-radius: .4em; background: #fbfaf7; }

/* shared avatar */
.av {
  flex: none; display: grid; place-items: center;
  width: 2.3em; height: 2.3em; border-radius: 50%;
  background: linear-gradient(140deg, hsl(var(--h) 85% 72%), hsl(calc(var(--h) + 35) 70% 52%));
  color: #fff; font-family: "Syne", sans-serif; font-weight: 700; font-size: .9em;
}
.av--sm { width: 1.8em; height: 1.8em; font-size: .75em; }

/* ============================================================
   WEAVOLY
   ============================================================ */
.dv--weavoly .dv__screen { background: #fff6ee; color: #2b1518; }
.dv--weavoly.dv--dark .dv__screen { background: #1c1014; color: #f7e6dc; }

.t-head { display: flex; justify-content: space-between; align-items: baseline; padding: .2em .1em .3em; }
.t-head b { font-family: "Syne", sans-serif; font-size: 1.4em; letter-spacing: -.03em; }
.t-head span { font-size: .66em; opacity: .6; }

.tc {
  position: relative;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .6em;
  padding: .7em .65em;
  border-radius: 1em;
  background: #fff;
  box-shadow: 0 .1em .3em rgba(80, 20, 20, .08), 0 .45em 0 -.18em #f3dfd2;
}
.tc--low { background: #fff0e8; box-shadow: 0 .1em .3em rgba(80, 20, 20, .08), 0 .45em 0 -.18em #f6cfc0; }
.tc__txt { display: grid; min-width: 0; gap: .1em; }
.tc__txt b { font-size: .8em; }
.tc__txt em { font-style: normal; font-size: .64em; opacity: .66; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tc__state {
  display: inline-flex; align-items: center; gap: .35em;
  font-size: .56em; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  color: #c9472e;
}
.dot { width: .6em; height: .6em; border-radius: 50%; background: currentColor; animation: tDot 2.4s ease-in-out infinite; }
@keyframes tDot { 50% { opacity: .3; } }

.ring { position: relative; display: grid; place-items: center; width: 2.9em; height: 2.9em; flex: none; }
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 3.6; }
.ring__t { stroke: rgba(201, 71, 46, .14); }
.ring__v { stroke: #e2603f; stroke-linecap: round; }
.ring b { position: relative; font-size: .48em; font-weight: 600; text-align: center; line-height: 1; }
.ring--low .ring__v { stroke: #b8202c; }
.ring--low b { color: #b8202c; }

.t-new {
  padding: .65em; border-radius: 1em; text-align: center;
  border: 1.5px dashed rgba(201, 71, 46, .35); color: #c9472e; font-size: .7em; font-weight: 500;
}
.t-tabs { margin-top: auto; display: flex; justify-content: center; gap: 2.6em; padding-top: .5em; }
.t-tabs i { width: 1.1em; height: 1.1em; border-radius: .35em; background: currentColor; opacity: .2; }
.t-tabs i.on { opacity: .85; background: #e2603f; }

.t-chathead { display: flex; align-items: center; gap: .5em; padding: .2em 0 .5em; border-bottom: 1px solid rgba(247, 230, 220, .1); }
.dv--weavoly:not(.dv--dark) .t-chathead { border-color: rgba(43, 21, 24, .08); }
.t-chathead b { font-size: .85em; }
.pill {
  margin-left: auto; padding: .3em .7em; border-radius: 99px;
  background: #e2603f; color: #fff; font-size: .56em; font-weight: 600; letter-spacing: .04em;
}
.bub { max-width: 80%; padding: .55em .8em; border-radius: 1.1em; font-size: .7em; line-height: 1.35; }
.bub--them { background: #352027; border-bottom-left-radius: .3em; }
.dv--weavoly:not(.dv--dark) .bub--them { background: #f3e2d7; }
.bub--me { align-self: flex-end; background: #e2603f; color: #fff; border-bottom-right-radius: .3em; }
.t-act {
  display: grid; gap: .45em; padding: .8em;
  border-radius: 1em;
  background: linear-gradient(150deg, #43222c, #2b161c);
  box-shadow: inset 0 0 0 1px rgba(255, 159, 127, .3);
}
.t-act__k { font-size: .52em; letter-spacing: .14em; text-transform: uppercase; color: #ff9f7f; }
.t-act b { font-family: "Syne", sans-serif; font-size: .9em; line-height: 1.15; }
.t-act__p { display: flex; gap: .3em; }
.t-act__p i { flex: 1; height: .32em; border-radius: 99px; background: rgba(247, 230, 220, .16); }
.t-act__p i.on { background: #ff9f7f; }
.t-act__btn { justify-self: start; padding: .45em .9em; border-radius: 99px; background: #f7e6dc; color: #2b1518; font-size: .62em; font-weight: 600; }
.t-compose {
  margin-top: auto; display: flex; align-items: center; justify-content: space-between;
  padding: .55em .55em .55em .9em; border-radius: 99px;
  background: rgba(247, 230, 220, .08); font-size: .66em; opacity: .9;
}
.t-compose i { width: 1.8em; height: 1.8em; border-radius: 50%; background: #e2603f; }

.sheet {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: grid; gap: .65em;
  padding: .6em 1em 1.3em;
  border-radius: 1.5em 1.5em 0 0;
  background: #fff;
  box-shadow: 0 -1em 2.5em rgba(80, 20, 20, .18), 0 -100cqh 0 100cqh rgba(43, 21, 24, .18);
}
.sheet__grab { justify-self: center; width: 3em; height: .3em; border-radius: 99px; background: #e6d3c7; }
.sheet__h { font-family: "Syne", sans-serif; font-size: 1em; }
.chips { display: flex; flex-wrap: wrap; gap: .35em; }
.chips i { font-style: normal; font-size: .6em; padding: .4em .8em; border-radius: 99px; background: #f6e7dc; }
.chips i.on { background: #2b1518; color: #fff6ee; }
.field { padding: .8em; border-radius: .8em; background: #fbf1e9; font-size: .68em; line-height: 1.4; min-height: 4.5em; }
.sheet__btn { padding: .8em; border-radius: 99px; background: #e2603f; color: #fff; text-align: center; font-size: .7em; font-weight: 600; }

.tag {
  position: absolute;
  padding: .55em 1em; border-radius: 99px;
  font-size: clamp(9px, min(1.9cqw, 2.3cqh), 13px); font-weight: 500;
  background: rgba(255, 246, 238, .94); color: #2b1518;
  box-shadow: 0 .6em 1.6em rgba(60, 10, 20, .25);
  white-space: nowrap;
}
.tag::before { content: ""; display: inline-block; width: .55em; height: .55em; margin-right: .5em; border-radius: 50%; background: #b8202c; }

/* weavoly compositions */
.comp--t-hero .dv { position: absolute; left: 50%; top: 50%; }
.comp--t-hero .dv:nth-child(1) { --ph: min(84cqh, 92cqw); transform: translate(-102%, -51%); }
.comp--t-hero .dv:nth-child(2) { --ph: min(74cqh, 81cqw); transform: translate(6%, -45%) rotate(3deg); }
.comp--t-hero .tag--a { left: 50%; bottom: 7cqh; transform: translateX(-12%); }
.stage--hero .comp--t-hero .dv:nth-child(1) { transform: translate(-108%, -51%); }
.stage--hero .comp--t-hero .dv:nth-child(2) { transform: translate(10%, -45%) rotate(3deg); }

.comp--t-time {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem;
  padding: clamp(1.1rem, 3cqw, 1.8rem);
}
.ts {
  display: grid; justify-items: start; align-content: start; gap: .7rem;
  padding: 1rem; border-radius: 14px;
  background: rgba(255, 246, 238, .94); color: #2b1518;
  box-shadow: 0 .6rem 1.4rem rgba(60, 10, 20, .16);
}
.ts .ring { font-size: 1.55rem; }
.ts__k { font-size: .62rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #c9472e; }
.ts__n { font-size: .8rem; line-height: 1.4; opacity: .72; }
.ts--end { background: #2b1518; color: #f7e6dc; }
.ts--end .ts__k { color: #ff9f7f; }
.ts--end b { font-family: "Syne", sans-serif; font-size: 1.05rem; line-height: 1.15; }
.ts__btns { display: flex; flex-wrap: wrap; gap: .35rem; }
.ts__btns i { font-style: normal; font-size: .72rem; padding: .4rem .75rem; border-radius: 99px; border: 1px solid rgba(247, 230, 220, .3); }
.ts__btns i.on { background: #e2603f; border-color: transparent; color: #fff; }
@media (max-width: 1000px) { .comp--t-time { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.comp--t-act {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(1rem, 4cqw, 2.4rem);
  align-items: center; padding: clamp(1.2rem, 4cqw, 2.4rem);
}
.comp--t-act .dv { --ph: min(30rem, 100cqw); }
.notes { display: grid; gap: .7rem; margin: 0; }
.notes li {
  display: grid; gap: .2rem;
  padding: .85rem 1rem; border-radius: 12px;
  background: rgba(255, 246, 238, .94); color: #4a2a2c;
  font-size: .84rem; line-height: 1.45;
}
.notes b { color: #2b1518; font-weight: 600; }
@media (max-width: 560px) {
  .comp--t-act { grid-template-columns: 1fr; justify-items: center; }
  .comp--t-act .dv { --ph: min(28rem, 120cqw); }
}

/* ============================================================
   EVIDENT
   ============================================================ */
.dv--evident .dv__screen { background: #fbfaf7; color: #1c1b19; }
.ev { display: grid; grid-template-columns: 22% 1fr; height: calc(100% - 2.3em); }
.ev__side {
  display: grid; align-content: start; gap: .25em;
  padding: 1em .9em; border-right: 1px solid rgba(28, 27, 25, .08);
  font-size: .8em;
}
.ev__side b { font-size: .7em; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #77736b; margin: .6em 0 .2em; }
.ev__side b:first-child { margin-top: 0; }
.ev__side span { padding: .3em .5em; border-radius: .35em; color: #4a4741; }
.ev__side span.on { background: #e9ecfb; color: #2f49c9; font-weight: 600; }
.ev__main { display: grid; grid-template-rows: auto 1fr auto auto; gap: .9em; padding: 1em 1.3em 1.2em; min-height: 0; }
.ev__top { display: flex; align-items: center; justify-content: space-between; gap: 1em; }
.ev__top b { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 1.3em; letter-spacing: -.01em; }
.frame {
  padding: .3em .8em; border-radius: 99px;
  border: 1px solid #2f49c9; color: #2f49c9;
  font-size: .72em; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
}
.ev__pair { display: grid; grid-template-columns: 1fr 1fr; gap: .9em; min-height: 0; }
.ev__pair figure {
  margin: 0; display: grid; grid-template-rows: 1fr auto; gap: .5em;
  min-height: 0;
}
.ev__pair figure > .vessel { justify-self: center; align-self: center; }
.ev__pair figure::before {
  content: ""; grid-area: 1 / 1; border-radius: .5em; background: #efebe3;
}
.ev__pair figure > .vessel { grid-area: 1 / 1; }
.ev__pair figcaption { font-size: .78em; display: flex; justify-content: space-between; gap: .5em; }
.ev__pair figcaption em { color: #77736b; }
.ev__crit { display: grid; gap: .35em; font-size: .78em; }
.ev__crit span { display: flex; justify-content: space-between; padding-bottom: .35em; border-bottom: 1px solid rgba(28, 27, 25, .08); }
.ev__crit b { font-weight: 500; }
.ev__crit i { font-style: normal; color: #77736b; }
.ev__crit i.up { color: #2f49c9; font-weight: 600; }
.ev__crit i.up::before { content: "↑ "; }
.ev__line { position: relative; display: flex; justify-content: space-between; padding: 0 .2em; }
.ev__line::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: rgba(28, 27, 25, .18); }
.ev__line i { position: relative; width: .55em; height: .55em; border-radius: 50%; background: #c8c2b6; }
.ev__line i.on { background: #2f49c9; box-shadow: 0 0 0 .25em #e9ecfb; }

.vessel { position: relative; display: block; width: 46%; aspect-ratio: 1 / .78; }
.vessel::before {
  content: ""; position: absolute; inset: 0;
  border-radius: 10% 14% 48% 46% / 10% 12% 62% 58%;
  background: linear-gradient(180deg, #c49373, #8a5a40 70%, #6d452f);
  transform: rotate(-3deg) skewX(-3deg);
}
.vessel i {
  position: absolute; left: -1%; right: 4%; top: -7%; height: 18%;
  border-radius: 50%;
  background: #6b4430; box-shadow: inset 0 -.25em 0 #d8ad8d;
  transform: rotate(-5deg);
}
.vessel--b::before {
  border-radius: 7% 7% 50% 50% / 8% 8% 62% 62%;
  background:
    linear-gradient(180deg, transparent 0 34%, rgba(255, 255, 255, .08) 34% 36%, transparent 36%),
    linear-gradient(180deg, #6f8e98, #3f5c67 60%, #2a3f47);
  transform: none;
}
.vessel--b i { left: 0; right: 0; transform: none; background: #2f4a53; box-shadow: inset 0 -.25em 0 #9bb5bd; }

.e-head { padding: .2em .1em .2em; }
.e-head b { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 1.3em; }
.es {
  display: grid; gap: .45em;
  padding: .85em; border-radius: .8em;
  background: #fff; border: 1px solid rgba(28, 27, 25, .1);
  color: #1c1b19;
}
.es__k { font-family: "Fraunces", Georgia, serif; font-style: italic; font-weight: 500; font-size: .95em; color: #2f49c9; }
.es__why { font-size: .7em; line-height: 1.45; color: #4a4741; }
.es__why u { text-decoration: none; border-bottom: 1px dotted currentColor; color: #1c1b19; }
.es__act { display: flex; gap: .4em; }
.es__act i { font-style: normal; font-size: .62em; padding: .45em .9em; border-radius: 99px; border: 1px solid rgba(28, 27, 25, .16); }
.es__act i:first-child { background: #1c1b19; color: #fbfaf7; border-color: transparent; }
.es--maybe .es__k { color: #6a6560; }
.es--quiet { background: transparent; border-style: dashed; }
.es--quiet .es__k { color: #77736b; }
.e-mini { display: flex; justify-content: center; align-items: center; gap: 8%; padding: .6em 0; border-radius: .8em; background: #efebe3; }
.e-mini .vessel { width: 32%; }

.comp--e-hero .dv--browser {
  position: absolute; width: min(78cqw, 108cqh); aspect-ratio: 16 / 10.5;
  left: 4cqw; top: 50%; transform: translateY(-54%);
}
.comp--e-hero .dv--phone {
  --ph: min(60cqh, 56cqw);
  position: absolute; right: 4cqw; bottom: 6cqh;
}
.stage--hero .comp--e-hero .dv--browser { left: calc(50% - min(78cqw, 108cqh) * .6); }
.stage--hero .comp--e-hero .dv--phone { right: auto; left: calc(50% + min(78cqw, 108cqh) * .4 - var(--ph) * .3); }

.comp--e-sug {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem;
  padding: clamp(1.1rem, 3cqw, 1.8rem);
  font-size: 1.15rem;
}
@media (max-width: 760px) { .comp--e-sug { grid-template-columns: 1fr; } }

.comp--e-fb {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 1rem;
  padding: clamp(1.1rem, 3cqw, 1.8rem); color: #1c1b19;
}
.fb {
  display: grid; gap: .8rem; align-content: start;
  padding: 1.2rem; border-radius: 12px; background: #fbfaf7;
  box-shadow: 0 .8rem 2rem rgba(28, 27, 25, .1);
}
.fb__crit { justify-self: start; font-size: .64rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #2f49c9; padding: .3rem .7rem; border-radius: 99px; background: #e9ecfb; }
.stage .fb p { margin: 0; max-width: none; color: #1c1b19; font-family: "Fraunces", Georgia, serif; font-size: 1.05rem; line-height: 1.5; }
.fb__by { display: flex; align-items: center; gap: .5rem; font-size: .8rem; color: #77736b; }
.fb__by i { display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; font-style: normal; font-size: .7rem; font-weight: 700; color: #fff; background: hsl(var(--h) 40% 45%); }
.nt { display: grid; gap: .5rem; align-content: start; }
.nt span {
  padding: .8rem 1rem; border-radius: 12px;
  background: rgba(251, 250, 247, .9); border: 1px solid rgba(28, 27, 25, .08);
  font-size: .84rem; line-height: 1.4; color: #4a4741;
}
.nt b { color: #1c1b19; font-weight: 600; }
@media (max-width: 760px) { .comp--e-fb { grid-template-columns: 1fr; } }

/* ============================================================
   DAYBOOK
   ============================================================ */
.dv--daybook .dv__screen {
  background:
    radial-gradient(rgba(124, 24, 32, .06) 1px, transparent 1.4px) 0 0 / 6px 6px,
    #f4ead8;
  color: #2a1a14;
}
.d-head { display: grid; padding: .2em .1em .3em; }
.d-head em { font-family: "Fraunces", Georgia, serif; font-style: italic; font-size: .8em; color: #7c1820; }
.d-head b { font-family: "Fraunces", Georgia, serif; font-weight: 700; font-size: 2em; line-height: .95; letter-spacing: -.02em; }
.d-head span { font-size: .62em; letter-spacing: .12em; text-transform: uppercase; opacity: .6; margin-top: .3em; }
.dh {
  display: flex; align-items: center; gap: .6em;
  padding: .65em .7em .65em .85em; border-radius: .9em;
  background: #fbf4e7; border: 1px solid rgba(124, 24, 32, .14);
}
.dh.is-done { background: #f7e3d6; }
.dh__txt { flex: 1; display: grid; gap: .05em; min-width: 0; }
.dh__txt b { font-size: .8em; font-weight: 600; }
.dh__txt em { font-style: normal; font-size: .62em; opacity: .65; }
.dh__btn {
  flex: none; display: grid; place-items: center;
  width: 2.1em; height: 2.1em; border-radius: 50%;
  border: 2px solid #7c1820; color: #fbf4e7; font-weight: 700; font-size: .85em;
  box-shadow: 0 .18em 0 rgba(90, 15, 21, .55);
}
.dh.is-done .dh__btn { background: #7c1820; }
.d-react {
  margin-top: auto; display: flex; align-items: center; gap: .5em;
  padding: .6em .7em; border-radius: .9em;
  background: #2a1a14; color: #f4ead8; font-size: .66em; line-height: 1.3;
}
.d-react i { flex: none; width: 2em; height: 2em; border-radius: 50%; background: hsl(10 45% 45%); display: grid; place-items: center; font-style: normal; font-weight: 700; color: #fff; }
.d-react b { font-weight: 600; }
.avs { display: flex; margin-top: .2em; }
.avs i {
  width: 1.4em; height: 1.4em; margin-right: -.35em; border-radius: 50%;
  display: grid; place-items: center; font-style: normal; font-size: .52em; font-weight: 700; color: #fff;
  background: hsl(var(--h) 45% 45%); box-shadow: 0 0 0 2px #f7e3d6;
}

.drc {
  position: absolute;
  display: grid; gap: .55em;
  width: 17em; padding: 1.1em 1.2em 1.2em;
  border-radius: 1em;
  background: #7c1820; color: #f6e7d2;
  font-size: clamp(8px, min(1.9cqw, 2.2cqh), 14px);
  box-shadow: 0 1.4em 3em rgba(80, 20, 20, .32);
}
.drc__k { font-size: .62em; letter-spacing: .16em; text-transform: uppercase; opacity: .75; }
.drc__h { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 1.35em; line-height: 1.1; }
.drc__days { display: flex; gap: 2px; }
.drc__days i { flex: 1; text-align: center; font-style: normal; font-size: .6em; opacity: .7; }
.drc__aw { justify-self: start; padding: .35em .8em; border-radius: 99px; background: #f6e7d2; color: #7c1820; font-size: .66em; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

/* single-series bars: one hue, the highlighted day stronger, rounded data
   ends anchored to the baseline, a 2px gap between neighbours */
.bars { display: flex; align-items: flex-end; gap: 2px; height: 4.2em; border-bottom: 1px solid rgba(246, 231, 210, .35); }
.bars i { flex: 1; border-radius: 4px 4px 0 0; background: rgba(246, 231, 210, .42); }
.bars i.is-hi { background: #f6e7d2; }

.stamp {
  position: absolute;
  display: grid; place-content: center; text-align: center; gap: .2em;
  width: 8.6em; aspect-ratio: 1; padding: 0 1em;
  color: #7c1820;
  font-size: clamp(7px, min(1.6cqw, 1.9cqh), 12px);
  border: 2px dashed currentColor; border-radius: 50%;
  outline: 2px solid currentColor; outline-offset: -.55em;
  background: rgba(244, 234, 216, .9);
  transform: rotate(-10deg);
}
.stamp b { font-family: "Fraunces", Georgia, serif; font-weight: 700; font-size: 1em; text-transform: uppercase; letter-spacing: .02em; line-height: 1.05; }
.stamp em { font-style: normal; font-size: .62em; letter-spacing: .06em; opacity: .85; }
.stamp--square { border-radius: .6em; outline-offset: -.5em; transform: rotate(5deg); }

.comp--d-hero .dv { --ph: min(86cqh, 82cqw); position: absolute; left: 50%; top: 50%; transform: translate(-92%, -50%); }
.comp--d-hero .drc { left: 50%; top: 50%; transform: translate(4%, -12%) rotate(2deg); }
.comp--d-hero .stamp { left: 50%; top: 9cqh; transform: translate(70%, 0) rotate(-12deg); }
.stage--hero .comp--d-hero .dv { transform: translate(-112%, -50%); }

.comp--d-recap {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem;
  padding: clamp(1.1rem, 3cqw, 1.8rem); color: #2a1a14;
}
.dcard {
  position: relative; overflow: hidden;
  display: grid; align-content: start; gap: .8rem;
  min-height: 17rem; padding: 1.2rem;
  border-radius: 16px;
  background: #fbf4e7; border: 1px solid rgba(124, 24, 32, .12);
  box-shadow: 0 .8rem 1.8rem rgba(80, 30, 10, .1);
}
.dcard--red { background: #7c1820; color: #f6e7d2; border-color: transparent; }
.dcard__k { font-size: .62rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.dcard b { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 1.3rem; line-height: 1.15; }
.dcard em { font-style: normal; font-size: .86rem; line-height: 1.45; opacity: .85; }
.dcard .stamp { position: absolute; right: -.6rem; bottom: -.6rem; font-size: 11px; color: #f6e7d2; background: transparent; }
.clock { display: flex; gap: 2px; height: 2.4rem; align-items: flex-end; margin-top: .4rem; }
.clock i { flex: 1; height: 30%; border-radius: 4px 4px 0 0; background: rgba(124, 24, 32, .16); }
.clock i.on { height: 100%; background: #7c1820; }
.dcard__axis { display: flex; justify-content: space-between; font-size: .64rem; opacity: .6; }
.dcard__axis i { font-style: normal; }
.cmp { display: grid; gap: .8rem; }
.cmp > span { display: grid; gap: .3rem; }
.cmp em { font-size: .64rem; letter-spacing: .1em; text-transform: uppercase; opacity: .6; }
.cmp .bars { height: 2.2rem; border-color: rgba(124, 24, 32, .25); }
.cmp .bars i { background: rgba(124, 24, 32, .3); }
.cmp > span:last-child .bars i { background: #7c1820; }
@media (max-width: 860px) { .comp--d-recap { grid-template-columns: 1fr; } .dcard { min-height: 0; } }

.comp--d-stamps { padding: clamp(1.4rem, 4cqw, 2.4rem); }
.coll {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 4cqw, 2rem); justify-items: center;
}
.coll .stamp { position: relative; font-size: clamp(10px, 2.3cqw, 14px); }
.coll .stamp:nth-child(2n) { transform: rotate(6deg); }
.coll .stamp:nth-child(3n) { transform: rotate(-4deg); }
@media (max-width: 520px) { .coll { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ============================================================
   THE LONG-FORM CASE STUDY
   ============================================================ */
.study .kicker { color: var(--hi); }
.study__title { font-size: clamp(2.6rem, 9vw, 5.6rem); letter-spacing: -.045em; }
.study__facts {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem 2rem;
  margin: 2rem 0 0; padding: 1.2rem 0;
  border-block: 1px solid var(--line);
}
.study__facts dt { font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: .3rem; }
.study__facts dd { margin: 0; color: var(--cream); font-size: .95rem; line-height: 1.45; }
@media (max-width: 700px) { .study__facts { grid-template-columns: 1fr; gap: .9rem; } }
@media (max-width: 700px) { .stage--hero { aspect-ratio: 4 / 5; container-type: size; } }

.study__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 15rem); }
@media (max-width: 860px) { .study__grid { grid-template-columns: minmax(0, 1fr); } }
.study__ch { margin-bottom: clamp(2.6rem, 5vw, 3.6rem); scroll-margin-top: 6.5rem; }
.study__h { display: flex; align-items: baseline; gap: .8rem; }
.study__n {
  font-family: "Outfit", sans-serif; font-weight: 500;
  font-size: .8rem; letter-spacing: .1em; color: var(--hi);
}
.study__h3 {
  font-family: "Syne", sans-serif; font-weight: 700;
  font-size: 1.05rem; color: var(--cream);
  margin: 1.6rem 0 .5rem;
}
.study__dec:first-of-type .study__h3 { margin-top: .4rem; }
.study .case__list li::before { background: var(--hi); }

.study__features {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.6rem;
  margin: 0; padding: 0;
}
.study__features li {
  display: grid; gap: .25rem; padding: .95rem 0;
  border-top: 1px solid var(--line);
}
.study__features b { color: var(--cream); font-weight: 500; }
.study__features span { color: rgba(255, 236, 205, .66); font-size: .92rem; line-height: 1.55; }
@media (max-width: 620px) { .study__features { grid-template-columns: 1fr; } }

.study__chips li { color: var(--hi); border-color: color-mix(in srgb, var(--hi) 35%, transparent); background: color-mix(in srgb, var(--hi) 7%, transparent); }

.study__body .study__quote {
  font-family: "Fraunces", Georgia, serif; font-style: italic; font-weight: 500;
  font-size: clamp(1.2rem, 2.4vw, 1.5rem); line-height: 1.5;
  color: var(--cream);
  padding-left: 1.2rem; border-left: 2px solid var(--hi);
  max-width: 56ch;
}

/* plates: close-ups placed between chapters */
.stage--plate { margin: 0 0 clamp(2.6rem, 5vw, 3.6rem); }
.stage__cap {
  padding: 0 clamp(1.1rem, 3cqw, 1.8rem) 1.1rem;
  font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
}
.stage--weavoly .stage__cap { color: #fff3ea; }
.stage--evident .stage__cap, .stage--daybook .stage__cap { color: #5d4a3c; }

/* the contents rail */
.study__toc ol { display: grid; gap: .15rem; margin: 0; padding: 0; }
.study__toc a {
  display: flex; gap: .7rem; align-items: baseline;
  padding: .35rem 0; font-size: .9rem; color: rgba(255, 236, 205, .72);
  transition: color .25s;
}
.study__toc a:hover { color: var(--cream); }
.study__tocn { font-size: .7rem; color: var(--hi); letter-spacing: .08em; }
@media (max-width: 860px) { .study__aside { display: none; } }

/* the flow diagram */
.flow { margin: 0 0 clamp(2.6rem, 5vw, 3.6rem); padding: 1.5rem; border: 1px solid var(--line); border-top: 3px solid var(--hi); border-radius: var(--r); }
.flow__title { font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: 1.2rem; }
.flow__steps {
  position: relative;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1rem;
  margin: 0; padding: 0;
}
.flow__steps::before {
  content: ""; position: absolute; left: 1rem; right: 1rem; top: 1rem; height: 1px;
  background: var(--rule);
}
.flow__steps li { position: relative; display: grid; gap: .3rem; align-content: start; }
.flow__n {
  display: grid; place-items: center; width: 2rem; height: 2rem; margin-bottom: .4rem;
  border-radius: 50%; border: 1px solid var(--hi); background: var(--ink-2);
  color: var(--hi); font-size: .78rem; font-weight: 500;
}
.flow__steps b { color: var(--cream); font-weight: 500; font-size: .95rem; }
.flow__note { color: rgba(255, 236, 205, .62); font-size: .82rem; line-height: 1.45; }
@media (max-width: 700px) {
  .flow__steps { grid-template-columns: 1fr; gap: 1.1rem; }
  .flow__steps::before { left: 1rem; right: auto; top: 1rem; bottom: 1rem; width: 1px; height: auto; background: var(--rule); }
  .flow__steps li { grid-template-columns: 2rem 1fr; column-gap: .9rem; }
  .flow__n { grid-row: span 2; margin: 0; }
}

/* ============================================================
   PROXIMITY PULSE — real captures through Spectacles
   ============================================================ */
.pshot {
  position: absolute; display: block;
  border-radius: 1.6cqw;
  box-shadow: 0 2cqw 6cqw rgba(4, 24, 18, .45), 0 0 0 1px rgba(255, 255, 255, .12);
  object-fit: cover;
}
.pshot--a { left: 7%; top: 9%; width: 66%; aspect-ratio: 1838 / 1346; }
.pshot--b { right: 6%; bottom: 10%; width: 46%; aspect-ratio: 1668 / 1186; transform: rotate(2.5deg); }
.comp--p-hero .tag--p { left: 9%; bottom: 7%; }
.comp--p-hero .tag--p::before { background: #e5484d; }
.stage--hero .pshot--a { left: 12%; width: 52%; }
.stage--hero .pshot--b { right: 12%; width: 38%; }

/* a credited photograph as the case-study hero */
.study__photo { margin: 0; }
.study__photo img {
  display: block; width: 100%; aspect-ratio: 21 / 9; object-fit: cover; object-position: 50% 42%;
  border-radius: var(--r); border: 1px solid var(--line);
}
/* the brief as a printed card: the client's mark on paper, the question beside it */
.study__brief { margin: 0; }
.study__brief-plate {
  display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  align-items: center; gap: clamp(1.5rem, 5vw, 4rem);
  padding: clamp(1.8rem, 5vw, 3.6rem);
  border-radius: var(--r);
  color: #1b1d26;
  background:
    var(--grain),
    repeating-linear-gradient(180deg, transparent 0 31px, rgba(59, 61, 107, .1) 31px 32px),
    #efe4cf;
  border-top: 4px solid var(--hi);
}
.study__brief-plate img { width: 100%; max-width: 320px; justify-self: center; }
.study__brief-text {
  font-family: "Fraunces", Georgia, serif; font-style: italic; font-weight: 500;
  font-size: clamp(1.2rem, 2.6vw, 1.75rem); line-height: 1.3;
  border-left: 2px solid #b2401b; padding-left: 1.1rem;
}
@media (max-width: 700px) {
  .study__photo img { aspect-ratio: 4 / 3; }
  .study__brief-plate { grid-template-columns: 1fr; }
}
.study__credit {
  margin-top: .7rem;
  font-size: .68rem; letter-spacing: .06em; line-height: 1.5;
  color: var(--muted);
}
.study__credit a { color: var(--cream); text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 2px; }
.study__credit a:hover { text-decoration-color: var(--orange); }

/* image and video plates in the long-form case study */
.study__media { margin: 0 0 clamp(2.6rem, 5vw, 3.6rem); }
.study__media img, .study__media video {
  display: block; width: 100%; height: auto;
  border-radius: var(--r); background: #0b1f1a;
  border: 1px solid var(--line);
}
.study__media--small img { width: min(11rem, 40%); border: 0; background: none; }
.study__cap {
  margin-top: .75rem;
  font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted);
}

/* ============================================================
   MOTION PREFERENCES
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .dot { animation: none; }
  .stage[data-reveal] .comp > * { transition: none; opacity: 1; translate: none; }
}
