/* Pages — the case studies, support pages and 404 in the studio system.

   studio.css supplies the tokens, type, buttons, window light, work plates
   and colophon; this file only lays out the pages that are read rather than
   travelled. Each page is a short day of its own: morning light over the
   cover, night from the contact section on (studio-page.js). */

/* ---------------------------------------------------------------- header */

.hd--page { gap: clamp(18px, 3vw, 44px); }
.hd-links { display: flex; gap: clamp(16px, 2.4vw, 36px); }
.hd-links a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: var(--f-small);
  font-weight: 500;
  color: var(--fg-2);
  transition: color .3s ease;
}
.hd-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 9px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .5s var(--ease-expo);
}
.hd-links a:hover,
.hd-links a[aria-current] { color: var(--fg); }
.hd-links a:hover::after,
.hd-links a[aria-current]::after { transform: scaleX(1); transform-origin: left; }
@media (max-width: 520px) {
  .hd--page .brand-name { display: none; }
}
@media (max-width: 400px) {
  .hd-links { gap: 12px; }
  .hd-links a { font-size: .8125rem; }
}

/* ---------------------------------------------------------------- reveals
   [data-reveal] blocks settle with the scroll (scroll-rise.js). */

.motion .cs-title .w__i {
  transform: translateY(112%);
  transition: transform 1.1s var(--ease-expo) calc(.04s + var(--i, 0) * .07s);
}
.is-ready .cs-title .w__i { transform: none; }

/* ---------------------------------------------------------------- case study */

.cs { padding-top: calc(var(--hd-h) + clamp(28px, 6vh, 72px)); }

.cs-cover {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  padding: 0 var(--margin);
}
.cs-meta { grid-column: 1 / -1; }
.cs-back {
  display: inline-flex;
  align-items: center;
  gap: .6em;
  min-height: 44px;
  color: var(--fg);
  transition: color .3s ease;
}
.cs-back span { transition: transform .5s var(--ease-expo); }
.cs-back:hover { color: var(--accent-ink); }
.cs-back:hover span { transform: translateX(-5px); }

.cs-title {
  grid-column: 1 / -1;
  margin: clamp(22px, 4vh, 48px) 0 clamp(28px, 5vh, 64px);
  font-family: var(--serif);
  /* As large as the grid allows, and never wider than it: --chars is the
     name's longest word, and Fraunces Light averages .47em a letter. */
  font-size: min(15rem, var(--cs-size, 14.2vw), calc((100vw - 2 * var(--margin)) / (var(--chars, 8) * .47)));
  font-weight: 290;
  line-height: .86;
  letter-spacing: -.05em;
  text-wrap: balance;
}
/* The one long name steps down so it keeps to two lines. */
.cs-title:has(.w:nth-child(3)) { --cs-size: 10.2vw; }
.cs-title .w { padding-bottom: .2em; margin-bottom: -.08em; }

/* The same plate the homepage shows, the case study's first page. It keeps
   the homepage's proportions so the page transition can carry it across. */
.cs-plate {
  grid-column: 1 / 8;
  grid-row: 3 / span 2;
  cursor: auto;
  view-transition-name: plate;
}
.cs-lead {
  grid-column: 9 / 13;
  grid-row: 3;
  align-self: start;
  display: grid;
  gap: 18px;
}
.cs-kind {
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.cs-deck {
  font-family: var(--serif);
  font-size: var(--f-lede);
  font-weight: 350;
  line-height: 1.3;
  letter-spacing: -.01em;
  text-wrap: pretty;
}
.cs-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }

.cs-facts {
  grid-column: 9 / 13;
  grid-row: 4;
  align-self: end;
  border-top: 1px solid var(--line);
}
.cs-facts div {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: var(--f-small);
}
.cs-facts dt {
  padding-top: .15em;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.cs-caption {
  grid-column: 1 / 8;
  grid-row: 5;
  max-width: 60ch;
  padding-top: 14px;
  font-size: var(--f-small);
  color: var(--fg-2);
}
.cs-caption span { display: block; margin-top: 2px; color: var(--accent-ink); font-size: var(--f-label); letter-spacing: .04em; }

/* Sections open like the homepage's chapters — rule, brass number, title —
   and their bodies sit on the same grid. */
.cs-section { padding: 0 0 clamp(24px, 4vh, 48px); }
.cs-section .chapter { padding-top: clamp(88px, 14vh, 170px); }
.cs-h2 {
  grid-column: 2 / 10;
  grid-row: 2;
  font-family: var(--serif);
  font-size: var(--f-display);
  font-weight: 320;
  line-height: .95;
  letter-spacing: -.035em;
}
.cs-section .chapter__no { padding-top: .9em; }

/* Overview is one statement that lights word by word as it is read. The
   unlit words stay at 52% so they are still 3:1 large text. */
.cs-statement {
  padding: 0 var(--margin);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
}
.cs-statement p {
  grid-column: 2 / 12;
  font-family: var(--serif);
  font-size: clamp(1.9rem, 4.1vw, 4.4rem);
  font-weight: 320;
  line-height: 1.08;
  letter-spacing: -.028em;
  text-wrap: pretty;
}
.cs-statement p + p { margin-top: .6em; }
.motion .cs-statement .lw { opacity: .52; transition: opacity .5s ease; }
.motion .cs-statement .lw.is-lit { opacity: 1; }

.cs-list,
.cs-ledger { padding: 0 var(--margin); }
.cs-list li,
.cs-ledger div {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  padding: clamp(22px, 3.4vh, 36px) 0;
  border-top: 1px solid var(--line);
}
.cs-list li:first-child,
.cs-ledger div:first-child { border-top: 0; }
.cs-list li:last-child,
.cs-ledger div:last-child { border-bottom: 1px solid var(--line); }
.cs-list em {
  grid-column: 1 / 3;
  padding-top: .5em;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  font-variant-numeric: tabular-nums;
  color: var(--accent-ink);
}
.cs-list p {
  grid-column: 2 / 10;
  font-family: var(--serif);
  font-size: var(--f-h3);
  font-weight: 340;
  line-height: 1.28;
  letter-spacing: -.012em;
  text-wrap: pretty;
}
.cs-ledger dt {
  grid-column: 2 / 5;
  font-family: var(--serif);
  font-size: var(--f-h3);
  font-weight: 360;
  line-height: 1.15;
  letter-spacing: -.015em;
}
.cs-ledger dd {
  grid-column: 5 / 11;
  max-width: 62ch;
  padding-top: .2em;
  color: var(--fg-2);
  text-wrap: pretty;
}

/* IBKR has no interface to show; its architecture is drawn from the
   repository instead, on a plate of its own. */
.cs-diagram { padding: 0 var(--margin) clamp(32px, 6vh, 64px); }
.cs-diagram .case-diagram {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: 16px;
  align-items: end;
}
.cs-diagram svg {
  grid-column: 1 / 9;
  width: 100%;
  height: auto;
  padding: clamp(18px, 3vw, 48px);
  border-radius: var(--radius);
  background:
    radial-gradient(ellipse 70% 55% at 50% 12%, rgba(200, 168, 99, .14), transparent 70%),
    #191B1E;
  color: rgba(233, 226, 212, .4);
}
.cs-diagram figcaption { grid-column: 9 / 13; font-size: var(--f-small); color: var(--fg-2); }
.case-diagram__box rect { fill: rgba(255, 255, 255, .03); stroke: rgba(233, 226, 212, .18); stroke-width: 1; }
.case-diagram__label text,
.case-diagram__title text { fill: #EDE6D8; font-family: var(--sans); font-size: 13px; font-weight: 600; }
.case-diagram__label text { font-size: 12px; }
.case-diagram__mono text,
.case-diagram__aside text { fill: rgba(233, 226, 212, .62); font-family: ui-monospace, "SFMono-Regular", Menlo, monospace; font-size: 11px; }
.case-diagram__mono .case-diagram__note { fill: #C8A863; font-weight: 600; }

.cs-section .cs-body--lede {
  padding: 0 var(--margin);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
}
.cs-body--lede p {
  grid-column: 2 / 10;
  font-family: var(--serif);
  font-size: var(--f-lede);
  font-weight: 350;
  line-height: 1.35;
  letter-spacing: -.01em;
  text-wrap: pretty;
}
.cs-body--lede p + p { margin-top: 1em; }
.cs-stack-label {
  margin: clamp(36px, 6vh, 64px) var(--margin) 14px;
  padding-left: calc((100% - 2 * var(--margin) + var(--gutter)) / 12);
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.cs-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 var(--margin);
  padding-left: calc((100% - 2 * var(--margin) + var(--gutter)) / 12);
}
.cs-stack li {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: var(--f-small);
}

/* Contact, then the next case study: the page's night. */
.cs-contact {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: 22px;
  margin-top: clamp(80px, 14vh, 160px);
  padding: clamp(80px, 14vh, 160px) var(--margin) clamp(60px, 10vh, 120px);
  border-top: 1px solid var(--line);
}
.cs-contact .chapter__tag { grid-column: 1 / -1; }
.cs-contact__title {
  grid-column: 1 / 10;
  font-family: var(--serif);
  font-size: var(--f-display);
  font-weight: 320;
  line-height: .96;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.cs-contact__body { grid-column: 1 / 7; color: var(--fg-2); max-width: 52ch; }
.cs-contact__links { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px 32px; }

.cs-next {
  position: relative;
  display: grid;
  gap: 10px;
  padding: clamp(56px, 10vh, 120px) var(--margin);
  border-top: 1px solid var(--line);
  overflow: hidden;
}
.cs-next::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--surface);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform .9s var(--ease-expo);
}
.cs-next:hover::before { transform: none; }
.cs-next__label,
.cs-next__kind {
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.cs-next__name {
  font-family: var(--serif);
  font-size: var(--f-chapter);
  font-weight: 300;
  line-height: .9;
  letter-spacing: -.045em;
  transition: color .4s ease;
}
.cs-next__name span { display: inline-block; transition: transform .7s var(--ease-expo); }
.cs-next:hover .cs-next__name { color: var(--accent-ink); }
.cs-next:hover .cs-next__name span { transform: translateX(.18em); }
.cs ~ .colophon { margin-top: 0; }

@media (max-width: 1099px) {
  .cs-plate { grid-column: 1 / -1; grid-row: auto; }
  .cs-lead { grid-column: 1 / 11; grid-row: auto; margin-bottom: clamp(28px, 5vh, 48px); }
  .cs-facts { grid-column: 1 / -1; grid-row: auto; margin-top: 28px; }
  .cs-caption { grid-column: 1 / -1; grid-row: auto; }
  .cs-statement p { grid-column: 1 / -1; }
  .cs-list p { grid-column: 2 / -1; }
  .cs-ledger dd { grid-column: 5 / -1; }
  .cs-body--lede p { grid-column: 2 / -1; }
  .cs-diagram svg, .cs-diagram figcaption { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .cs-title, .cs-title:has(.w:nth-child(3)) { --cs-size: 19vw; }
  .cs-lead { grid-column: 1 / -1; }
  .cs-facts div { grid-template-columns: 6.5rem 1fr; }
  .cs-list li, .cs-ledger div { row-gap: 10px; }
  .cs-list em { grid-column: 1 / -1; padding-top: 0; }
  .cs-list p, .cs-ledger dt, .cs-ledger dd { grid-column: 1 / -1; }
  .cs-contact__title, .cs-contact__body { grid-column: 1 / -1; }
  .cs-h2 { grid-column: 3 / -1; }
  .cs-body--lede p, .cs-ledger dt { grid-column: 1 / -1; }
  .cs-stack-label, .cs-stack { padding-left: 0; }
}

/* ---------------------------------------------------------------- support
   The four product records keep their own markup — every answer, card and
   form as written — and read in the studio system. Sections are numbered
   in brass like the homepage's chapters; answers open in place. */

:root { interpolate-size: allow-keywords; }

.support-page .hero .container {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  padding: calc(var(--hd-h) + clamp(28px, 6vh, 72px)) var(--margin) 0;
}
.sp-meta { grid-column: 1 / -1; }
.cs-meta,
.sp-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.sp-meta a:not(.cs-back) { color: var(--fg); background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat; }
.sp-meta a:not(.cs-back):hover { color: var(--accent-ink); }
.sp-icon {
  grid-column: 1 / -1;
  width: clamp(64px, 6vw, 88px);
  height: auto;
  margin-top: clamp(28px, 5vh, 56px);
  border-radius: 22.5%;
  box-shadow: 0 18px 40px -18px rgba(31, 32, 34, .45);
}
.support-page .hero .container > p:not(.sp-meta) {
  grid-column: 1 / 8;
  font-family: var(--serif);
  font-size: var(--f-lede);
  font-weight: 350;
  line-height: 1.3;
  letter-spacing: -.01em;
  text-wrap: pretty;
}
.search-box {
  position: relative;
  grid-column: 1 / 8;
  align-self: start;
  margin-top: clamp(24px, 4vh, 40px);
}
.search-box::before {
  content: "";
  position: absolute;
  left: 22px;
  top: 50%;
  width: 18px;
  height: 18px;
  translate: 0 -50%;
  background: var(--fg-2);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='m20 20-4.6-4.6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='m20 20-4.6-4.6'/%3E%3C/svg%3E") center / contain no-repeat;
  pointer-events: none;
}
.search-input {
  width: 100%;
  min-height: 60px;
  padding: 0 24px 0 54px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 55%, transparent);
  font-size: 1rem;
  transition: border-color .3s ease, background-color .3s ease;
}
.search-input::placeholder { color: var(--fg-2); }
.search-input:hover { border-color: color-mix(in srgb, var(--fg) 30%, transparent); }
.search-input:focus {
  outline: none;
  border-color: var(--accent-ink);
  background: var(--bg);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent);
}
.search-input::-webkit-search-cancel-button {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  background: var(--fg-2);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E") center / contain no-repeat;
  cursor: pointer;
}
.search-input::-webkit-search-cancel-button:hover { background: var(--fg); }
/* The script puts the status after the search box, inside the hero grid. */
.support-search-status { grid-column: 1 / 8; margin-top: 14px; padding-left: 24px; font-size: var(--f-small); color: var(--fg-2); }
.support-search-actions { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-top: 6px; }
.support-search-clear,
.support-search-contact {
  min-height: 44px;
  color: var(--fg);
  font-size: var(--f-small);
  font-weight: 500;
  background: linear-gradient(currentColor, currentColor) 0 calc(50% + .8em) / 100% 1px no-repeat;
}
.support-search-clear:hover,
.support-search-contact:hover { color: var(--accent-ink); }
.support-search-contact { display: inline-flex; align-items: center; }

.support-page > .container { padding: 0 var(--margin); }
.grid-layout {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  margin-top: clamp(64px, 11vh, 130px);
  counter-reset: sp;
}
.sidebar {
  grid-column: 1 / 4;
  position: sticky;
  top: calc(var(--hd-h) + 32px);
  align-self: start;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.sp-toc-title {
  margin-bottom: 12px;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.toc-list a {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 38px;
  padding-left: 18px;
  font-size: var(--f-small);
  color: var(--fg-2);
  transition: color .3s ease;
}
.toc-list a::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 8px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s var(--ease-expo);
}
.toc-list a:hover { color: var(--fg); }
.toc-list a.active { color: var(--fg); }
.toc-list a.active::before { transform: none; background: var(--accent-ink); }

#main-content { grid-column: 5 / 13; min-width: 0; }
.content-section {
  counter-increment: sp;
  padding-bottom: clamp(56px, 9vh, 110px);
  scroll-margin-top: calc(var(--hd-h) + 24px);
}
.section-header { padding-top: 18px; border-top: 1px solid var(--line); margin-bottom: clamp(18px, 3vh, 30px); }
.section-header::before {
  content: counter(sp, decimal-leading-zero);
  display: block;
  margin-bottom: 14px;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  font-variant-numeric: tabular-nums;
  color: var(--accent-ink);
}
.section-header h2,
#contact .card > h2 {
  font-family: var(--serif);
  font-size: clamp(2.1rem, 3.8vw, 3.8rem);
  font-weight: 320;
  line-height: 1;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.support-page .card { padding: 6px 0 0; }
.support-page .card + .card { margin-top: 28px; padding-top: 28px; border-top: 1px solid var(--line); }
.support-page .card h3,
.info-row h3 {
  margin-bottom: 14px;
  font-family: var(--serif);
  font-size: var(--f-h3);
  font-weight: 360;
  line-height: 1.15;
  letter-spacing: -.015em;
}
.support-page .card h4 {
  margin: 20px 0 8px;
  font-size: var(--f-label);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.sp-stack { display: grid; gap: 22px; }
.sp-stack h4 { margin-top: 0 !important; }
.support-page .card p,
.support-page .card li,
.info-row p,
.info-row li,
.answer { color: var(--fg-2); max-width: 66ch; text-wrap: pretty; }
.support-page .card p + p,
.answer p + p { margin-top: .8em; }
.support-page .card ul,
.support-page .card ol,
.answer ul,
.answer ol { margin: 10px 0 18px; padding-left: 1.2em; }
.support-page .card ul,
.answer ul { list-style: disc; }
.support-page .card ol,
.answer ol { list-style: decimal; }
.support-page li + li { margin-top: 6px; }
.support-page li::marker { color: var(--accent-ink); }
.support-page strong { font-weight: 600; color: var(--fg); }
.support-page main a:not(.cs-back):not(.support-search-contact) {
  color: var(--fg);
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: color .3s ease;
}
.support-page main a:hover { color: var(--accent-ink); }
.support-page code {
  padding: .1em .38em;
  border-radius: 4px;
  background: var(--surface);
  color: var(--fg);
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: .86em;
}
.spec-list { list-style: none !important; padding-left: 0 !important; border-top: 1px solid var(--line); }
.spec-list li { margin: 0 !important; padding: 12px 0; border-bottom: 1px solid var(--line); }
.info-row { padding: 22px 0; border-top: 1px solid var(--line); }
.info-row blockquote {
  margin-top: 12px;
  padding: 4px 0 4px 18px;
  border-left: 2px solid var(--accent);
  font-family: var(--serif);
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--fg);
}
.tag-dot { display: inline-block; width: 9px; height: 9px; margin-right: 8px; border-radius: 50%; vertical-align: .05em; }
.tag-dot--1 { background: #EB825F; }
.tag-dot--2 { background: #FFB44B; }
.tag-dot--3 { background: #78D2DC; }

/* Answers open in place: a hairline list, the question in the serif. */
.faq-group { border-top: 1px solid var(--line); }
.faq-group details { border-bottom: 1px solid var(--line); }
.faq-group summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  min-height: 64px;
  padding: 16px 0;
  font-family: var(--serif);
  font-size: clamp(1.1rem, 1.35vw, 1.3rem);
  font-weight: 380;
  line-height: 1.3;
  letter-spacing: -.01em;
  list-style: none;
  cursor: pointer;
  transition: color .3s ease;
}
.faq-group summary::-webkit-details-marker { display: none; }
.faq-group summary::after {
  content: "";
  flex: none;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background:
    linear-gradient(currentColor, currentColor) center / 12px 1.5px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.5px 12px no-repeat;
  transition: transform .6s var(--ease-expo), background-color .3s ease, border-color .3s ease;
}
.faq-group summary:hover { color: var(--accent-ink); }
.faq-group details[open] summary::after { transform: rotate(135deg); border-color: var(--accent); background-color: color-mix(in srgb, var(--accent) 22%, transparent); }
.faq-group .answer { padding: 0 58px 24px 0; }
.faq-group details::details-content {
  block-size: 0;
  overflow: clip;
  transition: block-size .55s var(--ease-expo), content-visibility .55s allow-discrete;
}
.faq-group details[open]::details-content { block-size: auto; }

/* Contact: the page's night, and one card to write from. */
#contact .card {
  padding: clamp(28px, 4vw, 56px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
#contact .card > h2 { margin-bottom: 14px; }
#contact .card > p { margin-bottom: 28px; }
.contact-form { display: grid; gap: 22px; }
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.contact-form label {
  display: block;
  margin-bottom: 8px;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  min-height: 52px;
  padding: 12px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  font-size: 1rem;
}
.contact-form select { appearance: none; background: linear-gradient(45deg, transparent 50%, currentColor 50%) right 6px center / 6px 6px no-repeat, linear-gradient(-45deg, transparent 50%, currentColor 50%) right 0 center / 6px 6px no-repeat; }
.contact-form select option { color: #1F2022; }
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form :is(input, select, textarea):focus { outline: none; border-bottom-color: var(--accent-ink); }
.contact-form :is(input, select, textarea):focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 4px; }
.contact-form ::placeholder { color: var(--fg-2); }
.submit-btn {
  justify-self: start;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  background: var(--fg);
  color: var(--bg);
  font-size: var(--f-small);
  font-weight: 500;
  transition: background-color .35s var(--ease-expo), color .35s var(--ease-expo);
}
.submit-btn:hover { background: var(--accent); color: var(--graphite); }
.sp-colophon { margin-top: 32px; font-size: var(--f-small); color: var(--fg-2); }
.sp-colophon div { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 8px; }

@media (max-width: 1099px) {
  .support-page .hero .container > p:not(.sp-meta),
  .search-box,
  .support-search-status { grid-column: 1 / -1; }
  .sidebar { grid-column: 1 / -1; position: static; margin-bottom: 40px; }
  .toc-list { display: flex; flex-wrap: nowrap; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
  .toc-list::-webkit-scrollbar { display: none; }
  .toc-list a { padding: 0 16px; min-height: 40px; white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; }
  .toc-list a::before { display: none; }
  .toc-list a.active { border-color: var(--fg); }
  #main-content { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .contact-grid { grid-template-columns: 1fr; }
  .faq-group .answer { padding-right: 0; }
}

/* ---------------------------------------------------------------- support hub */

.sp-hub-lede {
  grid-column: 1 / 7;
  font-family: var(--serif);
  font-size: var(--f-lede);
  font-weight: 350;
  line-height: 1.3;
  text-wrap: pretty;
}
.sp-products { margin-top: clamp(64px, 11vh, 130px); padding: 0 var(--margin); border-bottom: 1px solid var(--line); }
.sp-product {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  align-items: center;
  padding: clamp(22px, 3.6vh, 38px) 0;
  border-top: 1px solid var(--line);
  transition: color .3s ease;
}
.sp-product__no {
  grid-column: 1 / 2;
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  color: var(--accent-ink);
}
.sp-product img {
  grid-column: 2 / 3;
  width: clamp(52px, 5vw, 76px);
  height: auto;
  border-radius: 22.5%;
  transition: transform .8s var(--ease-expo);
}
.sp-product__text { grid-column: 3 / 12; display: grid; gap: 4px; }
.sp-product h2 {
  font-family: var(--serif);
  font-size: var(--f-display);
  font-weight: 320;
  line-height: .95;
  letter-spacing: -.035em;
  transition: translate .8s var(--ease-expo);
}
.sp-product__kind {
  font-size: var(--f-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.sp-product__what { color: var(--fg-2); font-size: var(--f-small); }
.sp-product b { grid-column: 12 / 13; justify-self: end; font-size: 1.5rem; font-weight: 300; transition: transform .6s var(--ease-expo); }
.sp-product:hover h2 { translate: .12em 0; color: var(--accent-ink); }
.sp-product:hover img { transform: rotate(-6deg) scale(1.06); }
.sp-product:hover b { transform: translate(4px, -4px); }

@media (max-width: 760px) {
  .sp-hub-lede { grid-column: 1 / -1; }
  .sp-product { row-gap: 12px; }
  .sp-product__no { grid-column: 1 / 3; }
  .sp-product img { grid-column: 3 / 6; }
  .sp-product b { grid-column: 11 / 13; }
  .sp-product__text { grid-column: 1 / -1; grid-row: 2; }
}
