@font-face {
  font-family: Manrope;
  src: url('./assets/fonts/manrope.woff2') format('woff2');
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
}

/* Map Japanese text to Light/Regular without changing the Manrope weights. */
@font-face {
  font-family: irohamaru;
  src: url('./assets/fonts/irohamaru-Light.woff2') format('woff2');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: irohamaru;
  src: url('./assets/fonts/irohamaru-Regular.woff2') format('woff2');
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #ffffff;
  --ink: #1c2b43;
  --muted: #5e6677;
  --focus: #2a3d7f;
  --hairline: #d5dce7;
  --error: #9b3232;
  --text-size: 1.25rem;
  background: var(--paper);
  color: var(--ink);
  font-family: Manrope, irohamaru, 'Hiragino Maru Gothic ProN', 'Meiryo', sans-serif;
  font-synthesis: none;
  line-height: 1.75;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-size: var(--text-size); }
p, h1 { margin: 0; }

main {
  width: min(100% - 2 * clamp(1.25rem, 5vw, 3rem), 44rem);
  margin-inline: auto;
  padding-block: clamp(3rem, 8vh, 5rem) clamp(3rem, 8vh, 5rem);
}

.brand {
  display: flex;
  align-items: center;
  gap: .875rem;
}

.brand img, .brand svg { display: block; inline-size: auto; }
.brand-symbol { block-size: 2.375rem; aspect-ratio: 200 / 162.3; overflow: visible; }
.wordmark { block-size: 1.125rem; }

h1 {
  margin-block: clamp(2.5rem, 6vh, 3.5rem) 1.5rem;
  font-size: inherit;
  font-weight: 650;
  letter-spacing: -.01em;
  line-height: 1.3;
  line-break: strict;
  overflow-wrap: anywhere;
}

h1 span { display: inline-block; max-inline-size: 100%; }

.intro {
  max-inline-size: 37rem;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.intro p { text-wrap: pretty; word-break: auto-phrase; }
.intro p + p { margin-block-start: .875rem; }

.closing { margin-block-start: clamp(2rem, 5vh, 3rem); }

.showcase {
  line-height: 1.55;
  word-break: auto-phrase;
  overflow-wrap: anywhere;
}

.prefix { font-weight: 650; }

.request-list ul {
  margin: .5rem 0 0;
  padding: 0;
  list-style: none;
}

.request-list li + li { margin-block-start: .5rem; }

.visually-hidden {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.request-list[data-wheel] {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  column-gap: .125rem;
  border-radius: .375rem;
  touch-action: pan-x;
  user-select: none;
  -webkit-user-select: none;
}

.request-list[data-wheel]:focus-visible { outline: 2px solid var(--focus); outline-offset: .5rem; }

.request-list[data-wheel] ul {
  position: relative;
  margin: 0;
  block-size: var(--wheel-height, 4.75em);
  overflow: clip;
  perspective: 40rem;
  perspective-origin: 0 50%; /* left-aligned text: keep the drum from slanting it */
}

.request-list[data-wheel] li {
  position: absolute;
  inset-inline: 0;
  inset-block-start: 50%;
  margin: 0;
  opacity: var(--opacity, 0);
  transform: translateY(-50%) translateY(var(--y, 0px)) rotateX(var(--angle, 0deg));
  backface-visibility: hidden;
  will-change: transform, opacity;
}

.request-list[data-wheel] li[data-near] { cursor: pointer; }
/* Hidden rows stay in the accessibility tree; they only stop catching taps. */
.request-list[data-wheel] li:not([data-active], [data-near]) { pointer-events: none; }

.signup {
  max-inline-size: 26rem;
  margin-block-start: 1.75rem;
}

/* One slim capsule: the field and a smaller pill button share a pale hairline.
   Controls use 16px (not the page's 18-20px) so the form stays light; 16px is
   also the smallest size that stops iOS zooming into the field. */
.signup-fields {
  display: flex;
  align-items: center;
  gap: .5rem;
  min-block-size: 2.75rem;
  border: 1px solid var(--hairline);
  border-radius: 999px;
  padding: .25rem .25rem .25rem 1.125rem;
  background: var(--paper);
  font-size: 1rem;
  transition: border-color .15s;
}

.signup-fields:focus-within { border-color: var(--ink); }
.signup-fields:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 3px; }
.signup-fields:has(input:user-invalid) { border-color: var(--error); }

.signup input {
  flex: 1;
  min-inline-size: 0;
  min-block-size: 2.25rem;
  border: 0;
  padding: 0;
  background: none;
  color: var(--ink);
  font: inherit;
  outline: none;
}

.signup input::placeholder { color: var(--muted); }

.signup button {
  flex: none;
  min-block-size: 2.25rem;
  border: 0;
  border-radius: 999px;
  padding: 0 1rem;
  background: var(--ink);
  color: var(--paper);
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.signup button:disabled { opacity: .55; cursor: default; }
.signup button:not(:disabled):hover { background: var(--focus); }
.signup button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.signup-status, .signup-fallback {
  margin-block-start: .5rem;
  color: var(--muted);
}

@media (max-width: 31rem) {
  :root { --text-size: 1.125rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .companion { cursor: pointer; }
}
