/* Homepage composition. Shared navigation, pricing, care and invoice studio keep their own owners. */
.site--home .site-header__bar { height: 76px; }
.site--home :where(#clients, #invoice-styles, #pricing) { scroll-margin-top: 92px; }
.home-hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(40px, 7vw, 100px); align-items: end; padding-block: 70px 36px; }
.home-hero h1 { font-family: var(--font-display); font-weight: var(--font-display-weight); font-size: clamp(56px, 6vw, 84px); line-height: 1.02; letter-spacing: -.055em; }
.home-hero .kicker { margin-bottom: 23px; font-size: var(--fs-xs); letter-spacing: .075em; }
.home-hero__pitch { padding-bottom: 9px; }
.home-hero .lead { font-size: var(--fs-lead); line-height: 1.7; max-width: 29em; text-wrap: pretty; }
.home-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 24px; margin-top: 27px; }
.home-actions .btn { min-height: 50px; }
.home-watch { display: inline-flex; align-items: center; gap: var(--icon-gap-md); font-size: var(--fs-sm); font-weight: 600; text-decoration: none; }
.home-watch .bg-icon { color: var(--gold-deep); }
.home-hero__note { margin-top: 15px; font-size: var(--fs-xs); color: var(--caption); }

/* ---------- while you're away: a dark band like the footer's, the dashboard's window lit against it and the day's feed
   on paper ---------- */
.away { position: relative; overflow: hidden; margin-top: 0; padding-top: clamp(72px, 8vw, 112px); background: var(--sand-900); color: var(--inv-muted); }
.away__copy { position: relative; max-width: 760px; text-align: center; }
.away__copy h2 { font-family: var(--font-display); font-weight: var(--font-display-weight); margin-top: 12px; font-size: var(--fs-d2); line-height: 1.02; }
.away__copy .lead { max-width: 36em; margin: 16px auto 0; }
.away__stage { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 0; align-items: end; margin-top: clamp(40px, 5vw, 64px); padding-bottom: clamp(56px, 7vw, 96px); }
.away__window { position: relative; margin: 0; overflow: hidden; border-radius: var(--r-xl); background: var(--bg-panel); box-shadow: var(--shadow-card); }
.away__chrome { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border-bottom: 1px solid var(--line); background: var(--paper); }
.away__chrome i { width: 9px; height: 9px; border-radius: var(--r-pill); background: var(--sand-200); }
.away__chrome span { margin-inline: auto; padding: 2px 14px; border-radius: var(--r-sm); background: var(--bg-panel); box-shadow: var(--shadow-card); font-size: var(--fs-xs); color: var(--caption); }
/* the top of the dashboard: greeting, totals and the outstanding invoices */
.away__screen { position: relative; display: block; overflow: hidden; }
.away__screen img { display: block; width: 100%; height: auto; }

.away__feed { position: relative;  margin: 0 0 clamp(24px, 4vw, 56px) -48px; padding: 18px; border-radius: var(--r-xl); background: var(--bg-panel); box-shadow: var(--shadow-card); }
.away__feed-head { display: flex; justify-content: space-between; align-items: center; padding: 2px 4px 12px; border-bottom: 1px solid var(--line); }
.away__feed-head b { font-weight: 600; color: var(--ink); }
.away__live { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-xs); font-weight: 600; color: var(--paid-fg); }
.away__live::before { content: ""; width: 7px; height: 7px; border-radius: var(--r-pill); background: currentColor; box-shadow: var(--shadow-card);  }
.away__feed ol { display: grid; gap: 2px; margin: 8px 0 0; padding: 0; list-style: none; }
.away__feed li { display: grid; grid-template-columns: 32px 1fr; gap: 10px; align-items: center; padding: 8px 4px; border-radius: var(--r-lg);  }
.away__feed b { display: block; font-size: var(--fs-sm); font-weight: 600; line-height: 1.35; color: var(--ink); }
.away__feed small { display: block; font-size: var(--fs-xs); color: var(--caption); }
.away__feed time { font-family: var(--font-sans); }
.away__icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-lg); background: var(--sent-bg); color: var(--sent-fg); }
.away__feed [data-kind="paid"] .away__icon { background: var(--paid-bg); color: var(--paid-fg); }
.away__feed [data-kind="late"] .away__icon { background: var(--overdue-bg); color: var(--overdue-fg); }
.away .kicker { color: var(--inv-soft); }
.away h2 { color: var(--inv-strong); }
.away .accent { color: var(--site-accent-inv, var(--hl)); }
.away .lead { max-width: 30em; color: var(--inv-muted); }
.away__aside { margin-top: 14px; font-size: var(--fs-sm); color: var(--inv-soft); }
.away__aside strong { color: var(--inv-strong); }
.away__aside a { color: var(--inv-link); text-underline-offset: 3px; }
/* The window the whole width of the wrap, so the app reads (a 1440 x 900 capture at about 0.8x); the day's feed laid
   over its lower corner, its top just under the dashboard's tiles (54% down the 16:10 screen, under the 34px chrome),
   hanging below the window into the band's foot. */
@media (min-width: 981px) {
  .away .away__stage { display: block; container-type: inline-size; padding-bottom: clamp(96px, 14vw, 150px); }
  .away .away__feed { position: absolute; top: calc(100cqi * .625 * .54 + 34px); right: var(--site-gutter); width: 320px; margin: 0; }
}
.away .away__window { box-shadow: 0 40px 90px rgba(0, 0, 0, .42), 0 0 0 1px rgba(255, 255, 255, .07); }
.away .away__feed { box-shadow: 0 24px 60px rgba(0, 0, 0, .38); }
/* on a phone, the app on a phone, its top: the money card and what needs you */
@media (max-width: 600px) { .away .away__screen img { max-height: 480px; object-fit: cover; object-position: top; } }
@media (max-width: 980px) {
  .away__stage { grid-template-columns: minmax(0, 1fr); }
  .away__feed { margin: -40px 16px 0; }
}



.home-section { padding-block: 104px; }
.home-section__head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 80px; align-items: end; margin-bottom: 38px; }
.home-section__head h2, .home-details h2 { font-family: var(--font-display); font-weight: var(--font-display-weight); font-size: clamp(40px, 4.6vw, 62px); line-height: 1.06; }
.home-section__head .kicker { margin-bottom: 16px; }
.home-section__head .lead { font-size: var(--fs-md); line-height: 1.7; }
.home-text-link { display: inline-flex; align-items: center; gap: var(--icon-gap-md); font-size: var(--fs-sm); font-weight: 600; padding-bottom: 5px; margin-top: 19px; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--sand-300); }
.home-text-link:hover { color: var(--site-kicker, var(--gold-deep)); border-color: var(--site-accent, var(--gold)); }
/* three short notes under a section's picture (clients, time) */
.home-notes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px; margin-top: 32px; }
.home-notes > div { padding-top: 18px; border-top: 1px solid var(--line); }
.home-notes h3 { font-size: var(--fs-md); line-height: 1.4; letter-spacing: -.015em; }
.home-notes p { margin-top: 8px; font-size: var(--fs-sm); line-height: 1.65; color: var(--text-muted); }
.site--home .istyles { border-bottom: 0; }
.home-details { padding-block: 90px 82px; }
.home-details h2 { font-size: clamp(38px, 4vw, 54px); margin-top: 16px; }
/* six cards, each an icon, a line and a sentence, the whole card the link */
.home-details__head { display: flex; align-items: end; justify-content: space-between; gap: 32px; }
.home-details__head .home-text-link { margin: 0 0 6px; flex: none; }
.home-details__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 44px 0 0; padding: 0; list-style: none; }
.home-detail { position: relative; display: grid; align-content: start; gap: 8px; height: 100%; padding: 28px 28px 30px; border: 1px solid var(--line); border-radius: var(--r-xl); background: var(--bg-panel); color: inherit; text-decoration: none; transition: border-color .2s, box-shadow .2s, transform .2s; }
.home-detail:hover { border-color: color-mix(in srgb, var(--m) 35%, var(--line)); box-shadow: var(--shadow-card); transform: translateY(-2px); }
.home-detail:focus-visible { outline: 2px solid var(--m); outline-offset: 3px; }
.home-detail__icon { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 12px; border-radius: var(--r-lg); background: color-mix(in srgb, var(--m) 10%, transparent); color: var(--m); }
.home-detail h3 { font-size: var(--fs-md); font-weight: 600; line-height: 1.35; letter-spacing: -.015em; color: var(--ink); }
.home-detail p { font-size: var(--fs-sm); line-height: 1.6; color: var(--text-muted); }
.home-detail > .bg-icon:last-child { position: absolute; top: 30px; right: 26px; color: var(--m); opacity: 0; transform: translateX(-4px); transition: opacity .2s, transform .2s; }
.home-detail:is(:hover, :focus-visible) > .bg-icon:last-child { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .home-detail, .home-detail > .bg-icon:last-child { transition: none; } .home-detail:hover { transform: none; } }
@media (max-width: 980px) { .home-details__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .home-details__head { display: block; }
  .home-details__head .home-text-link { margin-top: 18px; }
  .home-details__grid { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 30px; }
  .home-detail { grid-template-columns: 44px minmax(0, 1fr); column-gap: 16px; row-gap: 4px; padding: 20px; }
  .home-detail__icon { grid-row: span 2; margin: 0; }
  .home-detail > .bg-icon:last-child { display: none; }
}
.home-pricing { padding-block: 92px; }
.home-pricing__head { margin-bottom: 42px; text-align: center; }
.home-pricing__head h2 { font-family: var(--font-display); font-weight: var(--font-display-weight); margin-top: 17px; font-size: clamp(38px, 4.2vw, 56px); line-height: 1.07; }
.home-pricing__head > p:last-child { margin-top: 22px; color: var(--text-muted); }
.home-pricing .plans { gap: 20px; }
.home-pricing .plan { padding: 32px; border-radius: var(--r-xl); }
.home-pricing .plan--featured { background: linear-gradient(var(--paper), var(--bg-panel) 72%); border-color: var(--site-accent, var(--gold)); }
.home-pricing__more { text-align: center; margin-top: 28px; font-size: var(--fs-sm); color: var(--caption); }
.home-pricing__more a { display: inline-flex; align-items: center; gap: var(--icon-gap-md); text-underline-offset: 4px; }
.site--home .closing { max-width: none; padding: 88px var(--site-gutter) 80px; background: var(--sand-50); border-top: 1px solid var(--line); }
.site--home .closing h2 { font-family: var(--font-display); font-weight: var(--font-display-weight); margin-top: 17px; font-size: clamp(46px, 5.4vw, 76px); line-height: 1.03; }
.site--home .closing .lead { margin-top: 24px; }
.site--home .closing > .btn { margin-top: 28px; }
.closing__assurances { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px 28px; list-style: none; padding: 0; margin: 26px 0 0; font-size: var(--fs-xs); color: var(--caption); }

@media (min-width:1440px) { .home-hero { padding-top:86px; } .home-hero h1 { font-size:88px; } }
@media (max-width:1000px) { .home-section__head { gap:44px; } }
@media (max-width:860px) { .home-hero, .home-section__head { grid-template-columns:minmax(0,1fr); gap:28px; } .home-hero { padding-top:52px; } .home-hero .lead { max-width:35em; } .home-hero h1 { font-size:70px; } }
@media (max-width:700px) {
  .site--home .site-header__bar { height:68px; }
  .home-hero { padding-block:39px 28px; gap:24px; }
  .home-hero h1 { font-size:60px; }
  .home-hero .kicker { margin-bottom:20px; }
  .home-hero__pitch { padding:0; }
  .home-hero .lead { font-size:16px; }
  .home-actions { gap:20px; margin-top:23px; }
  .home-section { padding-block:64px; }
  .home-section__head { gap:23px; margin-bottom:27px; }
  .home-section__head h2, .home-details h2 { font-size:42px; }
  .home-section__head .lead { font-size:16px; }
  .home-notes { grid-template-columns:minmax(0,1fr); gap:22px; margin-top:26px; }
  .home-details { padding-block:58px; }
  .home-pricing { padding-block:60px; }
  .home-pricing__head h2 { font-size:40px; }
  .home-pricing .plan { padding:28px; }
  .site--home .closing { padding-block:58px; }
  .site--home .closing h2 { font-size:58px; }
}
@media (max-width:370px) { .home-hero h1 { font-size:48px; } .home-actions { gap:13px; } .home-actions .btn { padding-inline:18px; } }

/* ---- the hero (docs/BRAND_REFRESH.md "Front page") ---- */

/* The ledger behind the hero: --hero-texture (outer/site.css) draws its grid. */
.home-hero { position: relative; isolation: isolate; }
.home-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--hero-texture);
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 30% 45%, #000 20%, transparent 78%);
  mask-image: radial-gradient(ellipse 70% 80% at 30% 45%, #000 20%, transparent 78%);
}

/* The staged hero: the job in a line, centered, the ways to sign up beneath it, then the app's own screens of the job in
   a window (.hs, fragments/home-stage.html) and its parts on the rail, in the job's three chapters. */
.home-hero.is-staged { display: block; padding-block: 44px 48px; text-align: center; }
.home-hero.is-staged .kicker { margin-bottom: 14px; text-wrap: balance; }
/* one line where it fits, so the product shows sooner; two on narrower screens */
.home-hero.is-staged :where(h1) { font-size: clamp(50px, 6.4vw, 92px); line-height: 1; letter-spacing: -.045em; text-wrap: balance; }
.home-hero__br { display: none; }
.home-hero.is-staged .home-hero__pitch { padding: 0; }
.home-hero.is-staged .lead { max-width: 40em; margin: 18px auto 0; text-wrap: balance; }
.home-hero.is-staged .home-actions { justify-content: center; gap: 28px; margin-top: 26px; }
/* The season's line ("to paid before the pie.", 8.44em) on one row, centered, and the character beside "From hello",
   flush with the line's end (seasonal-touches.css places it by these measures). */
.home-hero.is-staged [data-seasonal-stage] { --seasonal-line: 8.44; }
.home-hero.is-staged [data-seasonal-stage] .home-hero__br { display: inline; }
.home-hero.is-staged [data-seasonal-stage] > * { --seasonal-type: min(calc(100cqi / (var(--seasonal-line) + .14)), 96px); }
.home-hero.is-staged [data-seasonal-stage] .seasonal-trigger[data-seasonal-placement="hero"] {
  right: max(0px, calc(50% - var(--seasonal-type) * var(--seasonal-line) / 2));
}

/* The window: the screens are captures of the app at 1280 CSS pixels, shown at about 0.9x in the wrap, so the app's
   own type stays readable; on a phone, the app on a phone. */
.hs { position: relative; max-width: 1160px; margin: 32px auto 0; }
.hs-window {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg-panel);
  box-shadow: 0 1px 2px rgba(var(--shadow-rgb), .06), 0 30px 60px -30px rgba(var(--shadow-rgb), .35), 0 70px 120px -60px rgba(var(--shadow-rgb), .3);
}
.hs-chrome { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; height: 40px; padding-inline: 16px; border-bottom: 1px solid var(--line); background: var(--sand-50); }
.hs-chrome::before { content: ""; justify-self: start; width: 8px; height: 8px; border-radius: 50%; background: var(--sand-300); box-shadow: 14px 0 var(--sand-300), 28px 0 var(--sand-300); }
.hs-url { min-width: 0; padding: 3px 18px; border-radius: var(--r-pill); background: var(--bg-panel); box-shadow: inset 0 0 0 1px var(--line); font-size: 12px; color: var(--caption); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hs-pause { justify-self: end; display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--caption); cursor: pointer; }
.hs-pause:hover { background: var(--bg-panel); color: var(--ink); }
.hs-pause:focus-visible { outline: 2px solid var(--gold-deep); outline-offset: 1px; }
.hs-pause .hs-i-play, .hs-pause[aria-pressed="true"] .hs-i-pause { display: none; }
.hs-pause[aria-pressed="true"] .hs-i-play { display: block; }
/* Stacked in one cell: the screen coming in fades in over the one going (.is-leaving, js/outer/home.js). */
.hs-screens { display: grid; aspect-ratio: 1280 / 800; background: var(--bg-app); }
.hs-screens > picture { grid-area: 1 / 1; min-width: 0; }
.hs-screens > picture:not(.is-leaving) { z-index: 1; }
.hs-screens > picture:not([hidden]):not(.is-leaving) { animation: hs-in .55s var(--ease-out); }
.hs-screens img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top left; }
@keyframes hs-in { from { opacity: 0; } }

/* The rail: the job's three chapters over its parts on one thread; the part shown fills with its color, and while the
   tour runs a line under it measures how long it stays (its end moves the tour on, js/outer/home.js). */
.hs-rail { --cols: repeat(var(--n, 10), minmax(0, 1fr)); max-width: 1160px; margin: 48px auto 0; }
.hs-rail ol { margin: 0; padding: 0; list-style: none; }
/* The chapters: each title centered over its own steps, nothing drawn between them; the one thread through the steps
   is what connects them. */
.hs-rail .hs-chapters { display: grid; grid-template-columns: var(--cols); gap: var(--space-3); margin-bottom: 26px; }
.hs-chapters li { grid-column: span var(--win, 3); font-size: var(--fs-xs); font-weight: 600; letter-spacing: .12em; text-align: center; text-transform: uppercase; white-space: nowrap; color: var(--m); }
.hs-chapters li:nth-child(2) { grid-column: span var(--do, 4); }
.hs-chapters li:last-child { grid-column: span var(--paid, 3); }
.hs-rail [role="tablist"] { position: relative; display: grid; grid-template-columns: var(--cols); gap: var(--space-3); }
.hs-rail [role="tablist"]::before {
  content: "";
  position: absolute;
  top: 23px;
  left: calc(100% / (2 * var(--n, 10)));
  right: calc(100% / (2 * var(--n, 10)));
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--m-client), var(--m-proposal), var(--m-contract), var(--m-project), var(--m-time), var(--m-expense), var(--m-invoice), var(--m-paid), var(--m-portal));
  opacity: .5;
  transform-origin: left center;
  animation: hs-thread 1.1s var(--ease-out) .2s both;
}
.hs-rail [role="tablist"] li { animation: hs-knot .5s var(--ease-out) both; }
.hs-rail button { position: relative; display: grid; justify-items: center; gap: var(--space-1); width: 100%; padding: 0 0 14px; border: 0; background: none; font: inherit; color: var(--text-muted); cursor: pointer; }
.hs-rail button::after { content: ""; position: absolute; left: 32%; right: 32%; bottom: 2px; height: 2px; border-radius: 2px; background: var(--m); transform: scaleX(0); transform-origin: left center; }
.hs-rail [aria-selected="true"]::after { transform: scaleX(1); }
.hs-rail[data-touring] [aria-selected="true"]::after { animation: hs-dwell 6s linear both; }
.hs-rail[data-touring="paused"] [aria-selected="true"]::after { animation-play-state: paused; }
.hs-knot {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-2);
  border: 2px solid var(--m);
  border-radius: 50%;
  background: var(--bg-panel);
  box-shadow: 0 0 0 6px var(--bg-panel);
  color: var(--m);
  transition: background-color var(--duration-fast), color var(--duration-fast), translate var(--duration-fast) var(--ease-out), box-shadow var(--duration-fast);
}
.hs-rail button:hover .hs-knot { translate: 0 -2px; }
.hs-rail [aria-selected="true"] .hs-knot { background: var(--m); color: var(--on-accent); box-shadow: 0 0 0 6px var(--bg-panel), 0 0 0 7px color-mix(in srgb, var(--m) 40%, transparent); }
.hs-rail b { font-size: var(--fs-body); font-weight: 600; }
.hs-rail [aria-selected="true"] b, .hs-rail button:hover b { color: var(--ink); }
.hs-rail button:focus-visible { outline: none; }
.hs-rail button:focus-visible b { text-decoration: underline; text-underline-offset: 3px; }
.hs-says { margin-top: var(--space-4); }
.hs-says p { max-width: 46em; margin: 0 auto; font-size: var(--fs-body); line-height: 1.6; color: var(--text-muted); text-wrap: balance; }
.hs-says p:not([hidden]) { animation: hs-in .45s var(--ease-out); }
.hs-says b { font-weight: 600; color: var(--ink); }
.hs-says a { font-weight: 600; white-space: nowrap; color: var(--ink); text-underline-offset: 3px; }
@keyframes hs-thread { from { transform: scaleX(0); } }
@keyframes hs-knot { from { opacity: 0; translate: 0 6px; } }
@keyframes hs-dwell { from { transform: scaleX(0); } to { transform: scaleX(1); } }

@media (prefers-reduced-motion: reduce) {
  .hs-rail [role="tablist"]::before, .hs-rail [role="tablist"] li, .hs-screens > picture, .hs-says p { animation: none !important; }
}
@media (max-width: 980px) {
  .home-hero.is-staged { padding-top: 40px; }
  .home-hero__br { display: inline; }
  .hs-rail b { font-size: var(--fs-sm); }
  .hs-knot { width: 42px; height: 42px; }
  .hs-rail [role="tablist"]::before { top: 20px; }
}
/* A phone: the app on a phone, its top two thirds; the rail a row per chapter, its name beside its parts. */
@media (max-width: 600px) {
  .home-hero.is-staged { padding-block: 40px 32px; }
  .home-hero.is-staged :where(h1) { font-size: 56px; }
  .home-hero.is-staged .lead { font-size: 16px; }
  .home-hero.is-staged .home-actions { gap: 20px; }
  .hs { max-width: 400px; margin-top: 44px; }
  .hs-window { border-radius: 22px; }
  .hs-chrome { height: 34px; }
  .hs-screens { aspect-ratio: 390 / 620; }
  .hs-rail { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--space-3); margin-top: 36px; }
  .hs-rail .hs-chapters, .hs-rail [role="tablist"] { grid-auto-rows: 84px; gap: 0; margin: 0; }
  .hs-rail .hs-chapters { grid-template-columns: none; }
  .hs-chapters li, .hs-chapters li:nth-child(2), .hs-chapters li:last-child { grid-column: auto; padding: 13px 0 0; font-size: 11px; text-align: left; }

  .hs-rail [role="tablist"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hs-rail [role="tablist"] [data-ch="1"] { grid-row: 1; }
  .hs-rail [role="tablist"] [data-ch="2"] { grid-row: 2; }
  .hs-rail [role="tablist"] [data-ch="3"] { grid-row: 3; }
  .hs-rail [role="tablist"]::before { display: none; }
  .hs-knot { width: 38px; height: 38px; margin-bottom: var(--space-1); }
  .hs-rail b { font-size: var(--fs-xs); }
  .hs-says { grid-column: 1 / -1; }
  .hs-says p { font-size: var(--fs-sm); }
}
@media (max-width: 370px) { .home-hero.is-staged :where(h1) { font-size: 48px; } }

/* One client from both sides (fragments/home-sides.html): the studio's page for Fern & Field and Maya's own page with
   the studio, in one frame split by a seam that moves (js/outer/home.js). Both captures are the same 948 x 760 CSS
   pixels, shown a little wider than three quarters of the frame (the most a side can take), so neither runs out; at
   half each, each side ends at a natural edge of its page (the studio's after Client hub, Maya's after her main
   column). Below 900px the two are tabs; on a phone, the phone's captures. */
@property --split { syntax: "<percentage>"; inherits: true; initial-value: 50%; }
.sides { margin: 0; }
.sides__frame {
  --split: 50%;
  position: relative;
  container-type: inline-size;
  display: grid;
  grid-template-columns: minmax(0, var(--split)) minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-2xl);
  background: var(--bg-panel);
  box-shadow: 0 1px 2px rgba(var(--shadow-rgb), .06), 0 30px 60px -30px rgba(var(--shadow-rgb), .35), 0 70px 120px -60px rgba(var(--shadow-rgb), .3);
}
.sides__frame.is-dragging { cursor: ew-resize; user-select: none; }
.sides__pane { min-width: 0; overflow: hidden; }
.sides__label { display: flex; align-items: center; gap: var(--icon-gap-md); height: 56px; margin: 0; padding: 0 var(--space-5); border-bottom: 1px solid var(--line); background: var(--sand-50); font-size: var(--fs-sm); white-space: nowrap; color: var(--caption); }
.sides__label b { font-weight: 600; color: var(--ink); }
.sides__label > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.sides__label > span:last-child::before { content: "\00b7" / ""; margin-inline-end: var(--icon-gap-md); }
.sides__pane + .sides__pane .sides__label { padding-inline-start: calc(var(--space-5) + 6px); }
.sides__mark { display: grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: var(--r-md); background: color-mix(in srgb, var(--m) 12%, transparent); color: var(--m); }
/* the page runs on below the frame: its foot fades into it */
.sides__shot { display: block; -webkit-mask-image: linear-gradient(#000 78%, transparent); mask-image: linear-gradient(#000 78%, transparent); }
.sides__shot img { display: block; width: max(78.5cqi, 760px); max-width: none; height: auto; }

/* The seam: a line the full height of the frame and a grip at its middle; the line, the grip and the space either side
   of it take the pointer, and the keyboard moves it (a WAI-ARIA window splitter). */
.sides__seam { position: absolute; z-index: 1; inset-block: 0; left: var(--split); display: grid; place-items: center; width: 44px; margin-left: -22px; cursor: ew-resize; touch-action: none; }
.sides__seam[hidden] { display: none; }
.sides__seam::before { content: ""; position: absolute; inset-block: 0; left: 50%; width: 2px; margin-left: -1px; background: var(--ink); }
.sides__grip { position: relative; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--ink); color: var(--bg-panel); box-shadow: 0 0 0 4px var(--bg-panel), 0 12px 24px -8px rgba(var(--shadow-rgb), .55); transition: scale var(--duration-fast) var(--ease-out); }
.sides__grip .bg-icon + .bg-icon { margin-left: -2px; }
.sides__seam:hover .sides__grip, .is-dragging .sides__grip { scale: 1.08; }
.sides__seam:focus-visible { outline: none; }
.sides__seam:focus-visible .sides__grip { box-shadow: 0 0 0 4px var(--bg-panel), 0 0 0 7px var(--site-accent, var(--gold)); }
/* Once, the first time the frame comes into view, the seam leans each way to say it moves (js adds .is-hinting). */
.sides__frame.is-hinting { animation: sides-hint 1.4s var(--ease-out); }
@keyframes sides-hint { 0%, 100% { --split: 50%; } 38% { --split: 57%; } 72% { --split: 47%; } }

.sides figcaption { margin-top: var(--space-4); font-size: var(--fs-sm); line-height: 1.6; text-align: center; color: var(--caption); }

/* The tabs that take the seam's place below 900px. */
.sides__switch { display: flex; gap: var(--space-1); width: fit-content; max-width: 100%; margin: 0 auto var(--space-4); padding: var(--space-1); border: 1px solid var(--line); border-radius: var(--r-pill); background: var(--bg-panel); }
.sides__switch[hidden] { display: none; }
.sides__switch button { display: inline-flex; align-items: center; gap: var(--icon-gap-sm); min-height: var(--tap-min); padding: 0 var(--space-4); border: 0; border-radius: var(--r-pill); background: transparent; font: inherit; font-size: var(--fs-sm); font-weight: 600; white-space: nowrap; color: var(--text-muted); cursor: pointer; }
.sides__switch button:hover { color: var(--ink); }
.sides__switch [aria-selected="true"] { background: var(--ink); color: var(--bg-panel); }
.sides__switch button:focus-visible { outline: 2px solid var(--site-accent, var(--gold)); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
  .sides__frame.is-hinting { animation: none; }
  .sides__grip { transition: none; }
}
@media (max-width: 899px) {
  .sides__frame { grid-template-columns: minmax(0, 1fr); container-type: normal; }
  .sides__pane + .sides__pane { border-top: 1px solid var(--line); }
  .sides__shot img { width: 100%; }
  /* with script the tabs name each side, and the side picked fades in */
  .sides.is-live .sides__label { display: none; }
  .sides.is-live .sides__pane + .sides__pane { border-top: 0; }
  .sides.is-live .sides__pane:not([hidden]) { animation: hs-in .4s var(--ease-out); }
}
@media (max-width: 899px) and (prefers-reduced-motion: reduce) { .sides.is-live .sides__pane:not([hidden]) { animation: none; } }
@media (max-width: 600px) {
  .sides__switch { width: 100%; }
  .sides__switch button { flex: 1; justify-content: center; padding-inline: var(--space-2); }
}
