/*
  Workspace — Available Now
  Hand-built static replica of https://workspace.vip/available-now
  Breakpoints (same as the original): desktop >= 1440px, tablet 810–1439.98px, phone < 810px.
*/

/* ---------- Fonts: Geist Mono (variable file, one face per weight, as on the original) ---------- */
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 400; src: url(../fonts/geist-mono-cyrillic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 400; src: url(../fonts/geist-mono-latin-ext.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 400; src: url(../fonts/geist-mono-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 500; src: url(../fonts/geist-mono-cyrillic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 500; src: url(../fonts/geist-mono-latin-ext.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 500; src: url(../fonts/geist-mono-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 600; src: url(../fonts/geist-mono-cyrillic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 600; src: url(../fonts/geist-mono-latin-ext.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 600; src: url(../fonts/geist-mono-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 700; src: url(../fonts/geist-mono-cyrillic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 700; src: url(../fonts/geist-mono-latin-ext.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 700; src: url(../fonts/geist-mono-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---------- Tokens ---------- */
:root {
  --color-bg: #171717;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1); /* strong ease-out for UI that enters or responds */
  --color-text: #fff;
  --color-ink: #171717;            /* dark text on white hover fills */
  --color-black: #000;
  --color-muted: #8f8f8f;
  --color-nav-bg: rgba(23, 23, 23, 0.9);
  --color-nav-border: rgb(57, 57, 57);
  --color-accent: rgb(70, 255, 150);
  --color-accent-soft: rgba(70, 255, 150, 0.1);
  --color-alert: rgb(217, 61, 79);
  --color-alert-soft: rgba(255, 69, 69, 0.1);
  --color-image-placeholder: rgb(235, 235, 230);
  --color-hairline: #0000000f;
  --color-backdrop: rgba(0, 0, 0, 0.5);

  --font-mono: "Geist Mono", monospace;


  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- Base ---------- */
html, body { box-sizing: border-box; margin: 0; padding: 0; }
* { box-sizing: border-box; -webkit-font-smoothing: inherit; }
h1, h2, h3, h4, h5, h6, p, figure { margin: 0; }
body, input, textarea, select, button { font-family: sans-serif; font-size: 12px; }
body { background: var(--color-bg); }

/* Shared text styles (mirror the original's text presets) */
.t-label,   /* 13px uppercase UI label */
.t-heading, /* 16px uppercase card / panel heading */
.t-display, /* page title */
.t-footer {
  margin: 0;
  padding: 0;
  font-family: var(--font-mono);
  font-style: normal;
  font-feature-settings: normal;
  font-variation-settings: normal;
  text-decoration: none;
}
.t-label { font-size: 13px; font-weight: 500; letter-spacing: 0.02em; line-height: 1.2em; text-transform: uppercase; text-align: start; color: var(--label-color, var(--color-text)); }
.t-heading { font-size: 16px; font-weight: 400; letter-spacing: 0.02em; line-height: 120%; text-transform: uppercase; text-align: start; color: var(--color-text); }
.t-display { font-size: 32px; font-weight: 400; letter-spacing: 0.02em; line-height: 120%; text-transform: uppercase; text-align: center; color: var(--color-text); }
.t-footer { font-size: 13px; font-weight: 500; letter-spacing: 0.02em; line-height: 1.2em; text-transform: none; text-align: start; color: rgb(143, 143, 143); font-feature-settings: initial; }

@media (max-width: 1199px) and (min-width: 810px) { .t-display { font-size: 28px; } }
@media (max-width: 809px) and (min-width: 0) { .t-display { font-size: 24px; } }

/* Text wrappers behave like the original's rich-text containers */
.text-box { display: flex; flex-direction: column; justify-content: flex-start; flex-shrink: 0; outline: none; position: relative; flex: none; width: auto; height: auto; white-space: pre; }

/* Live "data" pieces (stock) fade in once the page is ready, as on the original */
.data-fade { opacity: 0; visibility: hidden; user-select: none; transition: opacity 0.2s ease-in-out; }
.data-fade.is-ready { opacity: 1; visibility: visible; user-select: auto; }

/* ---------- Page shell ---------- */
.page {
  position: relative;
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  justify-content: flex-start;
  align-content: center;
  align-items: center;
  gap: 0;
  width: auto;
  min-height: 100vh;
  height: min-content;
  padding: 0;
  overflow: clip;
  background-color: var(--color-bg);
}
.page__spacer { position: relative; flex-grow: 1; width: 0; height: 0; margin: 0; background: transparent; }

/* ---------- Navigation ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: 6;
  order: -1000;
  flex: none;
  width: 100%;
  height: auto;
  transform: translate(-50%);
}
.nav {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  justify-content: space-between;
  align-content: center;
  align-items: center;
  width: 100%;
  height: min-content;
  min-height: 64px; /* the height the EXPLORE / CART buttons used to give it */
  padding: 16px;
  overflow: visible;
  background-color: var(--color-nav-bg);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.nav::after { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; box-sizing: border-box; border: 0 solid var(--color-nav-border); border-bottom-width: 1px; border-radius: inherit; pointer-events: none; }

/* Logo */
.nav .logo { grid-column: 2; }
.logo { position: relative; display: block; flex: none; gap: 0; width: 52px; aspect-ratio: 2.15; height: auto; overflow: hidden; text-decoration: none; }
.logo__mark { position: absolute; top: 0; bottom: 0; left: -1px; flex: none; flex-shrink: 0; width: 52px; image-rendering: pixelated; fill: rgb(0, 0, 0); color: rgb(0, 0, 0); }
.svg-box { width: 100%; height: 100%; aspect-ratio: inherit; }
.svg-box svg { display: block; width: 100%; height: 100%; }

/* ---------- Listing ---------- */
.listing-root { display: contents; position: relative; width: auto; min-height: 100vh; overflow: clip; background-color: var(--color-bg); }
.listing {
  position: relative;
  display: flex;
  flex: none;
  flex-direction: column;
  flex-wrap: nowrap;
  justify-content: flex-start;
  align-content: flex-start;
  align-items: flex-start;
  gap: 0;
  width: 100%;
  height: min-content;
  padding: 0;
  overflow: hidden;
  background-color: var(--color-bg);
}
.listing::after { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; box-sizing: border-box; border-style: solid; border-color: var(--color-bg); border-width: 0 16px 16px 16px; border-radius: inherit; pointer-events: none; }
.listing__content { position: relative; display: flex; flex: none; flex-direction: column; flex-wrap: nowrap; justify-content: flex-start; align-content: center; align-items: center; gap: 80px; width: 100%; height: min-content; padding: 144px 16px 80px; overflow: visible; }

.grid {
  position: relative;
  display: grid;
  flex: none;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  justify-content: center;
  gap: 80px 16px;
  width: 100%;
  height: min-content;
  padding: 0;
}
.grid__cell { position: relative; display: flex; flex: none; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-content: center; align-items: center; align-self: start; justify-self: start; gap: 10px; width: 100%; height: min-content; padding: 0; }

/* ---------- Product card ---------- */
.card-slot { position: relative; flex: 1 0 0; width: 1px; height: auto; }
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-content: flex-start;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
  height: min-content;
  padding: 0;
  overflow: visible;
  cursor: pointer;
}
.card__media { position: relative; flex: none; width: 100%; aspect-ratio: 2 / 3; height: auto; overflow: hidden; }
.card__image-link { position: absolute; top: 0; bottom: 0; left: 0; display: block; flex: none; aspect-ratio: 2 / 3; width: auto; overflow: hidden; text-decoration: none; background-color: var(--color-image-placeholder); }
.card__layer { position: absolute; top: 0; left: 0; flex: none; width: 100%; height: 100%; overflow: hidden; will-change: var(--card-layer-will-change, auto); }
/* Older Safari needs a filter layer here (same rule as the original) */
@supports (background: -webkit-named-image(i)) and (not (position-area: top right)) {
  :root { --card-layer-will-change: filter; }
}
.card__layer--primary { z-index: 2; }
.card__image-frame { position: absolute; top: 0; right: 0; bottom: 0; left: 0; border-radius: inherit; }
.card__image-frame img { display: block; width: 100%; height: 100%; border-radius: inherit; object-position: center; object-fit: cover; transform: scale(1.02); /* trims baked-in edge lines */ }
.card__badges { position: absolute; top: 0; left: 0; z-index: 4; display: flex; flex: none; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-content: center; align-items: center; gap: 8px; width: min-content; height: min-content; padding: 12px; overflow: visible; }
.card__badge-slot { position: relative; flex: none; width: auto; height: auto; }
.card__badge-slot > div { display: none; }
.card__info { display: flex; flex-direction: column; flex-wrap: nowrap; align-items: flex-start; justify-content: flex-start; gap: 7px; width: 100%; } /* "Available now" under the name, 7px below it */

/* Stock status */
.stock-slot { position: relative; flex: none; width: auto; height: auto; }
.stock { position: relative; display: flex; flex-direction: row; flex-wrap: nowrap; justify-content: center; align-content: center; align-items: center; gap: 10px; width: min-content; height: min-content; padding: 0; overflow: hidden; }
.stock__slot { position: relative; flex: none; width: auto; height: auto; }
.stock__row { position: relative; display: flex; flex-direction: row; flex-wrap: nowrap; justify-content: center; align-content: center; align-items: center; gap: 8px; width: min-content; height: min-content; padding: 0; overflow: hidden; }
.stock__row--over { justify-content: flex-start; }
.stock__dot-box { position: relative; display: flex; flex: none; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-content: center; align-items: center; gap: 8px; width: min-content; height: 17px; padding: 0; overflow: hidden; }
.stock__dot { position: relative; display: flex; flex: none; flex-direction: row; flex-wrap: nowrap; justify-content: center; align-content: center; align-items: center; gap: 0; width: 12px; height: 12px; padding: 0; overflow: visible; border-radius: 100px; background-color: var(--color-alert-soft); }
.stock__dot-core { position: relative; flex: none; width: 3px; height: 3px; background-color: var(--color-alert); }
.stock__row--over .stock__dot { background-color: var(--color-accent-soft); }
.stock__row--over .stock__dot-core { background-color: var(--color-accent); }
/* "Available now" as a tag: bold dark type on the site's green, in
   place of the dot and green text. The words are whatever the Label column says. */
.stock__row--over { padding: 5px 9px 4px; border-radius: 6px; background-color: var(--color-accent); }
.stock__row--over .stock__dot-box { display: none; }
.stock__row--over .stock__text { font-size: 12px; font-weight: 700; letter-spacing: 0.9px; text-transform: uppercase; color: var(--color-ink); }
.stock__text-slot { position: relative; flex: none; width: auto; height: auto; }
.stock__text-box { display: inline-flex; flex-grow: 0; flex-shrink: 0; align-items: center; justify-content: center; width: auto; box-sizing: border-box; }
.stock__text { margin: 0; padding: 0; font-family: var(--font-mono); font-size: 13px; font-style: normal; font-weight: 500; letter-spacing: 0.6px; line-height: 1; white-space: nowrap; color: var(--color-muted); }

/* ---------- Footer ---------- */
.site-footer { position: relative; order: 1002; display: flex; flex: none; flex-direction: row; flex-wrap: nowrap; justify-content: space-between; align-content: center; align-items: center; width: 100%; height: min-content; padding: 16px; overflow: visible; }

/* ---------- Tablet ---------- */
@media (min-width: 810px) and (max-width: 1439.98px) {
  .grid { grid-template-columns: repeat(3, minmax(120px, 1fr)); }
}

/* ---------- Phone ---------- */
@media (max-width: 809.98px) {
  .listing__content { gap: 40px; padding: 104px 16px 40px; }
  .grid { grid-template-columns: repeat(2, minmax(120px, 1fr)); gap: 40px 16px; }

  .site-footer__copy { white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word; }
}

/* Hidden SVG sprite (same technique as the original) */
#svg-templates { position: absolute; bottom: 0; left: 0; z-index: 0; width: 0; height: 0; overflow: hidden; contain: strict; }

/* ---------- Card press (the card opens the photo pop-up) ---------- */
.card__image-link { transition: opacity 120ms var(--ease-out); }
.card__image-link:active { opacity: 0.86; }
.card__title-link { text-decoration: none; color: var(--color-text); }
/* Price under the name (only the VIP page sends one): the muted mono line, like the stock tag */
.card__price { margin: 5px 0 0; font-family: var(--font-mono); font-size: 13px; font-weight: 500; letter-spacing: 0.6px; line-height: 1; font-variant-numeric: tabular-nums; color: var(--color-muted); }
.card__image-link:focus-visible,
.card__title-link:focus-visible { outline: 2px solid var(--color-text); outline-offset: 2px; }

/* ---------- Photo pop-up ---------- */
/* The same place as the Vision VIP app's product page: near-black over the page, the
   current photo washed out behind, the photo floating with a deep shadow, stretching
   dots, centred mono type, swipe down (or tap outside) to leave. Native <dialog>: Esc
   closes it, focus stays inside, the page behind is inert. */
html:has(.viewer[open]) { overflow: hidden; }
.viewer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  color: var(--color-text);
  background: transparent;
  touch-action: pan-x pinch-zoom; /* vertical drags are ours (swipe down to close); pinch zoom still works */
  opacity: 0;
  transition: opacity 160ms var(--ease-out), overlay 160ms allow-discrete, display 160ms allow-discrete;
}
.viewer[open] { opacity: 1; transition-duration: 240ms; }
@starting-style { .viewer[open] { opacity: 0; } }
.viewer::backdrop {
  background-color: rgba(0, 0, 0, 0);
  transition: background-color 160ms var(--ease-out), overlay 160ms allow-discrete, display 160ms allow-discrete;
}
.viewer[open]::backdrop { background-color: rgba(0, 0, 0, 0.94); transition-duration: 240ms; }
@starting-style { .viewer[open]::backdrop { background-color: rgba(0, 0, 0, 0); } }

/* The wash: the photo on screen, blurred and dimmed behind everything, crossfading as you swipe. */
.viewer__wash { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.viewer__wash::after { content: ""; position: absolute; inset: 0; background-color: rgba(0, 0, 0, 0.45); }
.viewer__wash-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(60px);
  transform: scale(1.25);
  opacity: 0;
  transition: opacity 220ms var(--ease-out); /* crossfade between photos; the first one appears instantly */
}
.viewer__wash-img.is-on { opacity: 0.5; }
/* A tiny pre-blurred glow: the phone only scales it up, with a light blur to smooth it. */
.viewer__wash-img.is-glow { filter: blur(14px); transform: scale(1.12); }

.viewer__stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 20px 0 40px;
  box-sizing: border-box;
  transform: translateY(0);
  transition: transform 240ms var(--ease-out);
}
/* The photo opens where it stays: the pop-up fades in, nothing slides into place. */
.viewer.is-dragging .viewer__stage { transition: none; }

.viewer__reel { position: relative; width: 100%; }
.viewer__track {
  display: flex;
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  outline: none;
}
.viewer__track::-webkit-scrollbar { display: none; }
.viewer__slide { display: flex; align-items: center; justify-content: center; flex: 0 0 100%; height: 100%; scroll-snap-align: center; scroll-snap-stop: always; }
/* The frame carries the photo's corners, hairline and shadow, and trims 1% off each side: a few
   photos have a screenshot's light-and-dark edge lines baked in, and these hide them. */
.viewer__frame {
  overflow: hidden;
  border-radius: 3px;
  outline: 0.5px solid rgba(255, 255, 255, 0.13);
  outline-offset: -0.5px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.7);
  background-color: rgba(255, 255, 255, 0.045);
}
.viewer__slide img {
  display: block;
  width: 100%;
  height: 100%;
  transform: scale(1.02);
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
}

.viewer__dots { display: flex; justify-content: center; align-items: center; gap: 5px; height: 5px; margin-top: 16px; }
.viewer__dot { width: 5px; height: 5px; border-radius: 3px; background-color: #fff; opacity: 0.22; }

.viewer__name {
  margin: 18px 34px 0;
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 19px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0;
  text-align: center;
  text-transform: none;
  color: #fff;
}
.viewer__extra { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px; margin: 9px 34px 0; }
.viewer__extra:empty { display: none; }
.viewer__extra .card__price,
.viewer__extra .stock__text {
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 2.6px;
  line-height: 1.2;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}
.viewer__extra .stock__row--over { padding: 4px 8px 3px; border-radius: 5px; }
.viewer__extra .stock__row--over .stock__text { font-weight: 700; letter-spacing: 1.6px; color: var(--color-ink); }
/* Phones: the chair's card and the Apple Pay button already say it's available now, so the
   tag isn't repeated here; the photo gets the room instead. */
@media (max-width: 809.98px) {
  .viewer__extra .stock-slot { display: none; }
  .viewer__extra:not(:has(> :not(.stock-slot))) { display: none; }
}

/* Request availability. Phone: the Vision VIP app's white button, a size down. Computer: the
   app's quieter outlined button, tucked into the lower-right corner of the screen. */
.viewer__cta {
  display: block;
  box-sizing: border-box;
  width: min(280px, calc(100% - 96px));
  margin-top: 20px;
  padding: 13px 18px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  color: #000;
  background-color: #fff;
  transition: transform 120ms var(--ease-out), opacity 160ms ease, background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}
.viewer__cta[hidden] { display: none; }
.viewer__cta:active { transform: scale(0.97); }
.viewer__cta:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
@media (min-width: 810px) {
  .viewer__cta {
    position: absolute; /* the stage fills the screen, so this is the screen's corner */
    right: 28px;
    bottom: 28px;
    width: auto;
    margin: 0;
    padding: 10px 16px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 1.6px;
    color: rgba(255, 255, 255, 0.85);
    background-color: transparent;
    border-color: rgba(255, 255, 255, 0.22);
  }
}
@media (min-width: 810px) and (hover: hover) and (pointer: fine) {
  .viewer__cta:hover { color: #fff; background-color: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.38); }
}

/* Apple Pay for chairs that are Available now: Stripe's own button, under the name and tag. */
.viewer__pay { box-sizing: border-box; width: min(300px, calc(100% - 96px)); min-height: 48px; margin-top: 18px; }
.viewer__pay[hidden] { display: none; }
.viewer__pay.is-done .viewer__pay-button { display: none; }
/* Its room is already there, so the button only fades in; nothing around it moves. */
.viewer__pay-button { opacity: 0; transition: opacity 160ms var(--ease-out); }
.viewer__pay.is-ready .viewer__pay-button { opacity: 1; }
.viewer__pay-note {
  margin: 10px 0 0;
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
  color: rgba(255, 255, 255, 0.78);
}
.viewer__pay-note:empty { display: none; }
.viewer__pay.is-done .viewer__pay-note { margin-top: 0; color: var(--color-accent); }

/* Available in: the catalog this chair is in (Airtable: Available In -> Catalogs), with the
   catalog's hardcover turned to face the photo. Phones and iPads:
   under the name, before the button. Wide screens: the lower-right corner, above Request availability. */
.viewer__corner { display: contents; }
.avail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  align-self: center;
  box-sizing: border-box;
  width: min(calc(100% - 56px), 300px); /* phone: a card under the name, not a thin strip */
  margin-top: 22px;
  padding: 15px 17px 15px 19px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 13px;
  background-color: rgba(255, 255, 255, 0.04);
  transition: opacity 260ms var(--ease-out) 60ms, transform 260ms var(--ease-out) 60ms;
}
.avail[hidden] { display: none; }
@starting-style { .viewer[open] .avail { opacity: 0; transform: translateY(6px); } }
.avail__text { margin: 0; text-align: left; }
.avail__label {
  display: block;
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 2.3px;
  line-height: 1.2;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}
.avail__name {
  display: block;
  margin-top: 7px;
  font-family: ui-monospace, "SF Mono", var(--font-mono);
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  color: #fff;
}
/* The book: an 8.5 x 11 hardcover, its cover turned toward the photo, its page edges on the right */
.avail__book { --depth: 6px; flex: none; width: 52px; height: 67px; perspective: 380px; }
.avail__book-3d {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transform: rotateY(-30deg) rotateX(6deg);
  transition: transform 280ms var(--ease-out) 110ms;
}
@starting-style { .viewer[open] .avail__book-3d { transform: rotateY(-8deg) rotateX(6deg); } }
.avail__cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 1px 2px 2px 1px;
  background-color: #2b2b2b;
  /* the shadow sits on the cover itself: a filter on the book would flatten its 3D turn into a soft bitmap */
  box-shadow: -5px 7px 12px rgba(0, 0, 0, 0.5);
  transform: translateZ(calc(var(--depth) / 2));
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
}
.avail__pages {
  position: absolute;
  top: 1px;
  right: 0;
  width: var(--depth);
  height: calc(100% - 2px);
  transform-origin: right center;
  transform: translateZ(calc(var(--depth) / -2)) rotateY(90deg);
  background: repeating-linear-gradient(90deg, #f1ece1 0 0.7px, #d8d1c2 0.7px 1.2px);
}
.avail--no-book .avail__book { display: none; }
.avail--no-book { padding-right: 19px; }
@media (min-width: 810px) {
  .avail { justify-content: flex-start; gap: 19px; width: auto; margin-top: 24px; padding: 12px 14px 12px 19px; }
  .avail__label { font-size: 11px; letter-spacing: 2.5px; }
  .avail__name { margin-top: 7px; font-size: 16.5px; }
  .avail__book { --depth: 6px; width: 59px; height: 76px; perspective: 400px; }
}
/* The corner only where the screen is wide enough to keep well clear of the centred name and
   "Available now". Below that, iPads included, it stacks under them like on a phone. */
@media (min-width: 1200px) {
  .viewer__corner {
    position: absolute; /* the stage fills the screen, so this is the screen's corner */
    right: 28px;
    bottom: 28px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
  }
  .viewer__corner .viewer__cta { position: static; }
  .avail { margin: 0; align-self: auto; }
}

.viewer__arrow {
  position: absolute;
  top: calc(50% - 20px);
  display: none;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.85);
  background-color: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: transform 120ms var(--ease-out), background-color 160ms ease, opacity 160ms var(--ease-out);
}
.viewer__arrow--prev { left: 24px; }
.viewer__arrow--next { right: 24px; }
.viewer__arrow:active { transform: scale(0.94); }
.viewer__arrow:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.viewer__arrow:disabled { opacity: 0; pointer-events: none; }
@media (hover: hover) and (pointer: fine) {
  .viewer__arrow { display: grid; }
  .viewer__arrow:hover { background-color: rgba(255, 255, 255, 0.16); }
}

@media (prefers-reduced-motion: reduce) {
  .viewer__stage { transition: none; }
  .viewer__wash-img { transition: none; }
  .avail { transition: opacity 200ms ease; }
  .avail__book-3d { transition: none; }
  @starting-style { .viewer[open] .avail { transform: none; } .viewer[open] .avail__book-3d { transform: rotateY(-30deg) rotateX(6deg); } }
}

/* When the price shows (VIP and -available pages): the name on its own line, then the price with
   Available now as a small filled badge after it, at every width */
.card__info:has(.card__price) { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 5px 10px; }
.card__info:has(.card__price) .card__info-main { display: contents; }
.card__info:has(.card__price) .card__title-link { order: 0; flex-basis: 100%; }
.card__info:has(.card__price) .card__price { order: 1; flex-basis: auto; margin: 0; }
.card__info:has(.card__price) .stock-slot { order: 2; }
.card__info:has(.card__price) .stock__row--over { padding: 3px 6px 2px; border-radius: 4px; }
.card__info:has(.card__price) .stock__row--over .stock__text { font-size: 9px; letter-spacing: 1px; line-height: 1; }

/* Long names stay on one line and shrink just enough to fit the card (phones mostly).
   The heading font is monospaced: each letter is 0.62em wide with its spacing, and the
   page tells each name its letter count (--chars), so the fit needs no script. */
.card__info { container-type: inline-size; }
.card__title .t-heading[style*="--chars"] { font-size: min(16px, calc(100cqi / (var(--chars) * 0.625))); }
