/* Hikkio site: the notebook's cover. Each section is one sheet of cover colour
   with a printed label plate; a cloth spine on the left carries the menu. */
:root {
  --ink: #241F4A;
  --ink-soft: #4A4570;
  --spine: #17141F;
  --on-spine: #D9D5E8;
  --plate: #FFFFFF;
  --butter: #FFD23F;
  --pink: #FF8FB8;
  --mint: #5BD6A0;
  --sky: #5EB8FF;
  --lilac: #B48CFF;
  --coral: #FF8A65;
  --rule: 2px;
  --spine-w: 76px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --cover: var(--butter);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-color: #5B5680 var(--spine); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100dvh;
  padding-left: var(--spine-w);
  background: var(--spine);
  color: var(--ink);
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  font-weight: 480;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--ink); color: var(--butter); }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 2px; }
p, h1, h2, h3, dl, dd, ol, ul, figure { margin: 0; }
ol, ul { padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; left: -200vw; top: 0; z-index: 30; background: var(--plate); padding: 12px 16px; font-weight: 700; }
.skip:focus { left: calc(var(--spine-w) + 8px); top: 8px; }

h1, h2 {
  font-stretch: 75%;
  font-weight: 850;
  line-height: 0.96;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.4rem, min(5.1vw, 8.6vh), 5rem); }
h2 { font-size: clamp(2.1rem, 3.7vw, 3.4rem); }
h3 { font-size: 1.5rem; font-stretch: 75%; font-weight: 850; line-height: 1.05; }
.lede { font-size: clamp(1.1rem, 1.25vw, 1.25rem); line-height: 1.45; text-wrap: pretty; max-width: 46ch; }

/* ---------- Spine ---------- */
.spine {
  position: fixed; inset: 0 auto 0 0; z-index: 20; width: var(--spine-w);
  display: flex; flex-direction: column; align-items: center; gap: 28px; padding: 16px 0;
  background-color: var(--spine);
  background-image:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0 1px, transparent 1px 3px);
  color: var(--on-spine);
}
/* The stitching where the tape meets the cover. */
.spine::after { content: ""; position: absolute; top: 0; bottom: 0; right: 7px; border-right: 2px dashed rgba(255, 255, 255, 0.22); pointer-events: none; }
.spine :focus-visible { outline-color: var(--butter); }
.spine-mark { display: block; flex: none; width: 44px; height: 44px; border-radius: 11px; overflow: hidden; }
.spine-mark svg { width: 100%; height: 100%; }
.spine-name { display: none; }
.spine-nav { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.spine-nav a, .spine-foot a.word {
  writing-mode: vertical-rl; transform: rotate(180deg);
  padding: 12px 8px; border-radius: 6px;
  font-size: 0.78rem; font-weight: 700; font-stretch: 112%; letter-spacing: 0.14em; text-transform: uppercase; text-decoration: none;
  transition: color 0.2s, background-color 0.2s;
}
.spine-nav a:hover, .spine-foot a.word:hover { color: #FFFFFF; background: rgba(255, 255, 255, 0.08); }
.spine-nav a[aria-current] { color: var(--current, var(--butter)); }
.spine-foot { margin-top: auto; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.spine-get {
  display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 11px;
  background: var(--butter); color: var(--ink); transition: transform 0.2s var(--ease), background-color 0.2s;
}
.spine-get:hover { background: #FFFFFF; }
.spine-get:active { transform: scale(0.94); }
.spine-get svg { width: 22px; height: 22px; }
.spine-get span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- Covers ---------- */
.cover { background: var(--cover); padding-block: clamp(3.5rem, 7vw, 6rem); overflow: clip; position: relative; }
.cover + .cover { border-top: var(--rule) solid var(--ink); }
.inner { width: min(1240px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.butter { --cover: var(--butter); } .pink { --cover: var(--pink); } .mint { --cover: var(--mint); }
.sky { --cover: var(--sky); } .lilac { --cover: var(--lilac); } .coral { --cover: var(--coral); }

/* A plate and the sheet that slides out from under it. */
.spread { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: center; }
.spread.flip { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.spread > .plate { position: relative; z-index: 2; }
.spread.flip > .plate { grid-column: 2; grid-row: 1; }
.spread.flip > .sheets { grid-column: 1; grid-row: 1; }

/* ---------- Label plates ---------- */
.plate { background: var(--plate); border: var(--rule) solid var(--ink); border-radius: 4px; }
.plate > * + * { border-top: var(--rule) solid var(--ink); }
.cell { padding: clamp(1.25rem, 2.2vw, 2rem); display: grid; gap: 1rem; }
.plate-name { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px clamp(1.25rem, 2.2vw, 2rem); }
.plate-name strong { display: flex; align-items: center; gap: 10px; font-size: 1.25rem; font-stretch: 75%; font-weight: 850; letter-spacing: 0; }
.plate-name strong svg { width: 28px; height: 28px; border-radius: 7px; }
.caps { font-size: 0.74rem; font-weight: 700; font-stretch: 112%; letter-spacing: 0.13em; text-transform: uppercase; }

.spec > div { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); }
.spec > div + div { border-top: var(--rule) solid var(--ink); }
.spec dt { padding: 0.95rem 0 0.85rem clamp(1.25rem, 2.2vw, 2rem); font-size: 0.74rem; font-weight: 700; font-stretch: 112%; letter-spacing: 0.13em; text-transform: uppercase; line-height: 1.5rem; }
.spec dd { padding: 0.85rem clamp(1.25rem, 2.2vw, 2rem) 0.85rem 1rem; border-left: var(--rule) solid var(--ink); font-weight: 520; text-wrap: pretty; }
.spec dd svg { width: 100%; height: 1.6rem; color: var(--ink); }

.action {
  display: flex; align-items: center; gap: 14px; padding: 1.15rem clamp(1.25rem, 2.2vw, 2rem);
  background: var(--ink); color: #FFFFFF; font-size: 1.2rem; font-weight: 750; text-decoration: none;
  border-radius: 0 0 1px 1px; transition: background-color 0.2s;
}
.action svg { width: 24px; height: 24px; flex: none; }
.action .arrow { margin-left: auto; transition: transform 0.35s var(--ease); }
.action:hover { background: var(--spine); }
.action:hover .arrow { transform: translateX(6px); }
.action:active { background: #000000; }
.action:focus-visible { outline-offset: 4px; }
.fine { font-size: 0.92rem; line-height: 1.45; color: var(--ink-soft); }

/* ---------- Screenshots: pages of the notebook ---------- */
.sheets { position: relative; z-index: 1; }
.shot { border: var(--rule) solid var(--ink); border-radius: 14px; overflow: hidden; background: var(--spine); box-shadow: 0 26px 44px -22px rgba(23, 20, 31, 0.55); }
.shot img { width: 100%; height: auto; }
.spread > .sheets { margin-left: -5%; margin-right: calc(-1 * var(--gutter) - 6%); }
.spread > .sheets .shot { transform: rotate(-2.2deg); transform-origin: 0 50%; }
.spread.flip > .sheets { margin-right: -5%; margin-left: calc(-1 * var(--gutter) - 6%); }
.spread.flip > .sheets .shot { transform: rotate(1.8deg); transform-origin: 100% 50%; }
/* A sheet whose far edge matters stays on the page. */
.spread > .sheets.whole { margin-right: 0; }
.pair { display: grid; }
.pair .shot { grid-area: 1 / 1; }
.pair .shot:first-child { width: 86%; }
.pair .shot:last-child { width: 62%; justify-self: end; align-self: end; margin-top: 34%; transform: rotate(2.4deg); }

.hero { padding-block: clamp(1.5rem, 4vh, 5rem); min-height: min(100dvh, 60rem); display: grid; align-items: center; }
.hero .cell { padding-block: clamp(1rem, 3vh, 2rem); }
.hero .spec dt { padding-block: clamp(0.55rem, 1.5vh, 0.95rem) clamp(0.45rem, 1.4vh, 0.85rem); }
.hero .spec dd { padding-block: clamp(0.45rem, 1.4vh, 0.85rem); }
.hero .action { padding-block: clamp(0.8rem, 2.2vh, 1.15rem); }
.hero .sheets .shot { animation: slide-out 1.1s var(--ease) 0.15s backwards; }
@keyframes slide-out { from { transform: translateX(-34%) rotate(0deg); } }

/* ---------- Record: the page you can try ---------- */
.try { margin-top: clamp(1.5rem, 3vw, 2.5rem); display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); background: var(--plate); border: var(--rule) solid var(--ink); border-radius: 4px; --i: 2; --p: 0.275; --row: 4.25rem; }
.try-page { border-right: var(--rule) solid var(--ink); min-width: 0; }
.try-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 1rem clamp(1rem, 2vw, 1.75rem); border-bottom: var(--rule) solid var(--ink); }
.try-head b { font-size: 1.15rem; font-stretch: 75%; font-weight: 850; }
.lines { position: relative; }
.lines::before { content: ""; position: absolute; left: clamp(1rem, 2vw, 1.75rem); right: clamp(1rem, 2vw, 1.75rem); margin-left: 4.25rem; top: 0.6rem; height: calc(var(--row) - 1.2rem); border-radius: 6px; background: var(--butter); transform: translateY(calc(var(--i) * var(--row))); transition: transform 0.5s var(--ease); }
.line {
  position: relative; display: grid; grid-template-columns: 3.5rem minmax(0, 1fr); align-items: center; gap: 0.75rem;
  width: 100%; height: var(--row); padding: 0 clamp(1rem, 2vw, 1.75rem); border: 0; border-bottom: 1.5px solid rgba(94, 184, 255, 0.55);
  background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer;
}
.lines li:last-child .line { border-bottom: 0; }
.line time { font-size: 0.82rem; font-weight: 700; color: var(--ink-soft); border-right: 2px solid rgba(255, 138, 101, 0.75); line-height: var(--row); }
.line svg { width: 100%; height: 2.6rem; overflow: visible; }
.line path { fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.line:hover time, .line[aria-pressed="true"] time { color: var(--ink); }
.line:focus-visible { outline-offset: -5px; }
.said { padding: clamp(1.25rem, 2.2vw, 2rem); display: grid; align-content: start; gap: 1rem; min-width: 0; }
.said-time { justify-self: start; display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 10px; border-radius: 999px; background: var(--ink); color: #FFFFFF; font-weight: 750; }
.said-time svg { width: 14px; height: 14px; color: var(--butter); }
.said blockquote { margin: 0; font-size: clamp(1.15rem, 1.6vw, 1.45rem); line-height: 1.35; font-weight: 520; min-height: 5.4em; text-wrap: pretty; }
.said blockquote p[hidden] { display: none; }
.tape { grid-column: 1 / -1; display: flex; align-items: center; gap: 14px; padding: 12px clamp(1rem, 2vw, 1.75rem); background: var(--spine); color: #FFFFFF; border-top: var(--rule) solid var(--ink); border-radius: 0 0 2px 2px; }
.tape-key { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--butter); color: var(--ink); }
.tape-key svg { width: 14px; height: 14px; }
.wave { position: relative; flex: 1; height: 36px; display: flex; align-items: center; gap: 3px; container-type: inline-size; overflow: hidden;
  background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.5) 0 3px, transparent 3px 8px) center / 100% 30% no-repeat; }
.wave.drawn { background: none; }
.wave i { flex: 1 1 0; min-width: 2px; border-radius: 2px; background: rgba(255, 255, 255, 0.78); }
.wave::after { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; border-radius: 2px; background: var(--butter); transform: translateX(calc(var(--p) * 100cqw)); transition: transform 0.5s var(--ease); }
.tape small { font-size: 0.82rem; font-weight: 700; }

/* ---------- Pro ---------- */
.head { display: grid; gap: 1.1rem; max-width: 52rem; }
.plans { margin-top: clamp(1.75rem, 3.5vw, 3rem); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1rem, 2.5vw, 2rem); align-items: stretch; }
.plan-name { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.plan .cell { gap: 0.6rem; }
.list li { padding: 0.8rem clamp(1.25rem, 2.2vw, 2rem); font-weight: 520; }
.list li + li { border-top: var(--rule) solid var(--ink); }

/* ---------- Back cover ---------- */
.back { background: var(--spine); color: var(--on-spine); padding-block: 2.5rem 3rem; border-top: var(--rule) solid var(--ink); }
.back .inner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; }
.back nav { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px 28px; }
.back a { text-decoration: none; font-weight: 600; }
.back a:hover { color: #FFFFFF; text-decoration: underline; }
.back :focus-visible { outline-color: var(--butter); }

/* ---------- Support, Privacy, 404: one long label ---------- */
.doc { min-height: calc(100dvh - 7rem); }
.doc .plate { max-width: 50rem; }
.doc .cell { gap: 0.9rem; }
.doc h2 { font-size: clamp(1.6rem, 2.4vw, 2rem); }
.doc p, .doc li { max-width: 68ch; text-wrap: pretty; }
.doc ul { display: grid; gap: 0.55rem; }
.doc ul li { padding-left: 1.4rem; position: relative; }
.doc ul li::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 0.7rem; height: 2px; background: var(--ink); }
.doc .cell a { font-weight: 650; }
.doc .cell a:hover { background: var(--butter); }
.updated { font-size: 0.92rem; color: var(--ink-soft); }
.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.97rem; }
th, td { text-align: left; vertical-align: top; padding: 0.7rem 0.9rem; border: var(--rule) solid var(--ink); }
th { font-size: 0.74rem; font-weight: 700; font-stretch: 112%; letter-spacing: 0.13em; text-transform: uppercase; }
.faq h3 { margin-top: 1.4rem; }
.faq h3:first-of-type { margin-top: 0.4rem; }
details { border-top: var(--rule) solid var(--ink); }
.faq details:last-child { border-bottom: var(--rule) solid var(--ink); }
summary { cursor: pointer; list-style: none; display: grid; grid-template-columns: minmax(0, 1fr) 1rem; align-items: center; gap: 1rem; padding: 0.85rem 0; font-weight: 700; overflow-wrap: anywhere; }
summary::-webkit-details-marker { display: none; }
summary::after { content: ""; width: 1rem; height: 1rem; background: linear-gradient(var(--ink) 0 0) center / 100% 2.5px no-repeat, linear-gradient(var(--ink) 0 0) center / 2.5px 100% no-repeat; transition: transform 0.3s var(--ease); }
details[open] summary::after { transform: rotate(45deg); }
summary:hover { background: color-mix(in srgb, var(--cover) 30%, transparent); }
details p { padding: 0 2rem 1rem 0; overflow-wrap: anywhere; }
.button { display: inline-flex; align-items: center; gap: 12px; padding: 0.9rem 1.3rem; background: var(--ink); color: #FFFFFF; font-weight: 750; text-decoration: none; border-radius: 3px; transition: background-color 0.2s; }
.button:hover { background: var(--spine); }
.doc .cell a.button:hover { background: var(--spine); }

/* A short window: the spine keeps the sections and drops Support, which the back cover also has. */
@media (max-height: 760px) and (min-width: 861px) {
  .spine { gap: 12px; }
  .spine-nav { gap: 0; }
  .spine-nav a { padding-block: 9px; }
  .spine-foot a.word { display: none; }
}

/* ---------- Narrower screens ---------- */
@media (max-width: 1100px) {
  .spread, .spread.flip { grid-template-columns: minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 2.5rem); }
  .spread.flip > .plate, .spread.flip > .sheets { grid-column: 1; grid-row: auto; }
  .spread > .plate { max-width: 40rem; }
  .spread > .sheets, .spread.flip > .sheets { margin-left: 0; margin-right: calc(-1 * var(--gutter) - 8%); }
  .spread > .sheets.whole { margin-right: 0; }
  .spread.flip > .sheets .shot { transform: rotate(-2.2deg); transform-origin: 0 50%; }
  .hero { min-height: 0; }
  @keyframes slide-out { from { transform: translateX(18%) rotate(0deg); } }
}
@media (max-width: 860px) {
  body { padding-left: 0; padding-top: 60px; }
  html { scroll-padding-top: 60px; }
  .spine { inset: 0 0 auto 0; width: auto; height: 60px; flex-direction: row; gap: 12px; padding: 0 var(--gutter); }
  .spine::after { top: auto; right: 0; left: 0; bottom: 6px; border-right: 0; border-bottom: 2px dashed rgba(255, 255, 255, 0.22); }
  .spine-mark { width: 36px; height: 36px; border-radius: 9px; }
  .spine-name { display: block; font-size: 1.2rem; font-stretch: 75%; font-weight: 850; color: #FFFFFF; text-decoration: none; }
  .spine-nav { display: none; }
  .spine-foot { margin: 0 0 0 auto; flex-direction: row; }
  .spine-foot a.word { writing-mode: horizontal-tb; transform: none; padding: 8px; }
  .spine-get { width: 36px; height: 36px; border-radius: 9px; }
  .skip:focus { left: 8px; top: 68px; }
  .try { grid-template-columns: minmax(0, 1fr); --row: 3.75rem; }
  .try-page { border-right: 0; border-bottom: var(--rule) solid var(--ink); }
  .said blockquote { min-height: 6.8em; }
  .plans { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  body { font-size: 1rem; }
  .spec > div { grid-template-columns: minmax(0, 1fr); }
  .spec dt { padding: 0.8rem 1.25rem 0; line-height: 1.2; }
  .spec dd { border-left: 0; padding: 0.3rem 1.25rem 0.85rem; }
  .try-head .caps { display: none; }
  /* The hero's four facts sit two by two, so the page inside shows without scrolling. */
  .hero .spec { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero .spec > div + div { border-top: 0; }
  .hero .spec > div:nth-child(odd) { border-right: var(--rule) solid var(--ink); }
  .hero .spec > div:nth-child(n + 3) { border-top: var(--rule) solid var(--ink); }
  .hero .spec dt { padding-top: 0.65rem; }
  .hero .spec dd { padding-bottom: 0.65rem; font-size: 0.94rem; line-height: 1.35; }
  .hero .cell { gap: 0.75rem; }
  .action { font-size: 1.05rem; gap: 10px; }
  .hero .spec dt { padding-bottom: 0; }
  .line { grid-template-columns: 2.9rem minmax(0, 1fr); }
  .lines::before { margin-left: 3.65rem; }
  .pair .shot:first-child { width: 94%; }
  .pair .shot:last-child { width: 70%; }
  .back nav { margin-left: 0; width: 100%; }
  .scroll { overflow: visible; }
  table, tbody, tr, td { display: block; }
  thead { display: none; }
  tr + tr { margin-top: 0.9rem; }
  td { border-top-width: 0; padding: 0.55rem 0.8rem; }
  td:first-child { border-top-width: var(--rule); font-weight: 750; }
  td:not(:first-child)::before { content: attr(data-label); display: block; font-size: 0.7rem; font-weight: 700; font-stretch: 112%; letter-spacing: 0.13em; text-transform: uppercase; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
