/* Type, colours and buttons match the sign-up survey, where every button here leads. */
:root {
  --canvas: #000;
  --on-canvas: #eeedf6;
  --muted: #b0aec2;
  --line: #ffffff24;
  --action: #ece8ff;
  --on-action: #15131d;
  --violet: #b4a0f8;
  --gutter: max(24px, calc((100% - 1320px) / 2));
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}
* { box-sizing: border-box; margin: 0; }
body {
  overflow-x: clip;
  background: var(--canvas);
  color: var(--on-canvas);
  font: 400 17px/1.75 "DM Sans", "Noto Sans KR", sans-serif;
  font-synthesis: none;
  word-break: keep-all;
}
html:lang(ja) body { font-family: "DM Sans", "Noto Sans JP", sans-serif; word-break: auto-phrase; }
::selection { background: var(--violet); color: var(--on-action); }
img { display: block; max-width: 100%; height: auto; }
button, select { color: inherit; font: inherit; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }

h1, h2 { font-weight: 700; letter-spacing: -0.035em; white-space: pre-line; text-wrap: balance; }
h1 { font-size: clamp(2.2rem, 3.7vw, 3.5rem); line-height: 1.28; }
h2 { font-size: clamp(1.8rem, 2.8vw, 2.6rem); line-height: 1.35; }

header {
  position: absolute;
  inset: 0 0 auto;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding-inline: var(--gutter);
}
.brand { display: flex; align-items: center; gap: 10px; color: inherit; font-weight: 700; text-decoration: none; }
.brand img { border-radius: 8px; }
.brand b { color: var(--violet); }
.language { min-height: 44px; border: 0; border-radius: 4px; background: transparent; font-size: 15px; cursor: pointer; }
.language option { background: #161520; }

.reserve {
  display: inline-flex;
  align-items: center;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 8px;
  background: var(--action);
  color: var(--on-action);
  font-weight: 700;
  text-decoration: none;
  transition: background-color 120ms;
}
.reserve:hover { background: #dad1f8; }

/* The page takes its colour from the playing cover, as the app's player does. */
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, clamp(290px, calc((100svh - 128px) * 0.475), 400px)) minmax(0, 1fr);
  align-items: center;
  gap: clamp(28px, 4.5vw, 72px);
  padding: 92px var(--gutter) 60px;
}
.glow { position: absolute; inset: 0; z-index: -1; mask-image: linear-gradient(#000 45%, transparent); }
.glow i { position: absolute; inset: 0; background-size: 100% 100%; opacity: 0; transition: opacity 700ms var(--ease); }
.glow .on { opacity: 0.5; }
.pitch p { max-width: 26em; margin: 20px 0 32px; color: #d3d0e2; }

.phone, .tablet { position: relative; }
.phone .frame, .tablet .frame { position: relative; width: 100%; }
.screen { position: absolute; overflow: hidden; background: #000; }
.screen img { position: absolute; inset: 0; width: 100%; height: 100%; }
.phone .screen { left: 4.1%; top: 1.95%; width: 90.95%; height: 96.4%; border-radius: 12% / 5.6%; }
.tablet .screen { left: 4.2%; top: 6.3%; width: 91.6%; height: 87.2%; border-radius: 1%; }

.works { display: grid; gap: 4px; }
.works button {
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 8px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  text-align: start;
  line-height: 1.4;
  cursor: pointer;
  transition: background-color 150ms;
}
.works img { border-radius: 9px; }
.works small { display: block; color: #c9c6da; font-size: 14px; }
.works button:hover { background: #ffffff14; }
.works [aria-pressed="true"] { background: #ffffff29; }
.note { margin: 12px 8px 0; color: #c9c6da; font-size: 13px; }

/* Text rows are shared, so the four phones start on the same line. */
.features {
  display: grid;
  grid-template: auto auto auto / repeat(4, minmax(0, 1fr));
  gap: 0 clamp(20px, 2.6vw, 40px);
  padding: 90px var(--gutter);
}
.features article { display: grid; grid-row: span 3; grid-template-rows: subgrid; }
.features h2 { font-size: 1.5rem; }
.features p { margin: 8px 0 28px; }
.features p, .shelf p { color: var(--muted); }

.shelf { padding: 80px var(--gutter) 100px; }
.shelf p { margin-top: 12px; }
/* Keep the whole tablet on screen, with the heading on its left edge. */
.shelf > * { width: min(100%, max(560px, (100svh - 250px) * 1.523)); margin-inline: auto; }
.shelf .tablet-scroll { margin-top: 32px; }
.join {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(36px, 5vw, 76px);
  padding: 80px var(--gutter) 120px;
}
.join .reserve { margin-top: 30px; }
dl div { display: grid; grid-template-columns: 8em minmax(0, 1fr); gap: 16px; padding: 15px 0; border-bottom: 1px solid var(--line); }
dt { color: var(--muted); }
dd { margin: 0; }

@media (max-width: 1080px) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 330px); row-gap: 40px; }
  .phone { grid-area: 1 / 2 / 3; }
  .picker { grid-area: 2 / 1; }
  .pitch { align-self: end; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; }
  .features article { margin-bottom: 56px; }
  .join { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 26px; padding-bottom: 40px; }
  .phone, .picker { grid-area: auto; }
  .pitch p { margin: 14px 0 22px; }
  .picker { order: 1; }
  .phone { order: 2; width: min(78%, 340px); margin-inline: auto; }
  .works { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
  .works button { display: block; padding: 3px; border-radius: 12px; }
  .works img { width: 100%; }
  .works span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .works [aria-pressed="true"] { background: var(--action); }
  .note { margin-inline: 3px; }
  .shelf { padding-block: 70px 30px; }
  .features {
    grid-template: auto auto auto / repeat(4, min(66vw, 270px));
    gap: 0 24px;
    padding-block: 56px 20px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 24px;
  }
  .features article { margin: 0; scroll-snap-align: start; }
  .features .phone { width: 100%; }
  .join { padding-block: 40px 80px; }
  .shelf > * { width: auto; }
  .tablet-scroll, .shelf .tablet-scroll { margin-inline: -24px; padding-inline: 24px; overflow-x: auto; }
  .tablet { width: 640px; }
  .tablet::after { content: ""; position: absolute; left: 100%; width: 24px; height: 1px; }
  dl div { grid-template-columns: 6em minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .glow i { transition: none; }
}
