/* Sebastian. Akzidenz-Grotesk on #F3EEE6.
   Structure taken from Experimental Jetset's site: one face, paper, separate pages.
   Not their Helvetica. */

:root {
  --paper: #f3eee6;
  --ink: #111111;
  --accent: #c1502e;
  --rule: rgba(17, 17, 17, 0.28);
  --pad: clamp(1.5rem, 4vw, 3.5rem);
  --measure: 36rem;
  --face: "Akzidenz-Grotesk", "AkzidenzGrotesk", "Neue Haas Grotesk Text Pro", Folio, "News Gothic", "Trade Gothic", sans-serif;
}

* { box-sizing: border-box; }

html {
  background: var(--paper);
  color: var(--ink);
}

html { overflow-x: hidden; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--face);
  font-weight: 500;
  font-size: 1.0625rem;
  line-height: 1.45;
  letter-spacing: 0;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
}

::selection {
  background: var(--ink);
  color: var(--paper);
}

:focus { outline: none; }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

a {
  color: inherit;
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--rule);
  text-underline-offset: 0.18em;
}

a:hover { text-decoration-color: var(--ink); }

p { margin: 0 0 1rem; }

h1, h2 { font-weight: 500; letter-spacing: -0.03em; }

.skip {
  position: absolute;
  left: var(--pad);
  top: 0;
  transform: translateY(-120%);
  background: var(--paper);
  padding: 0.4rem 0.2rem;
}

.skip:focus { transform: none; }

/* Home. Stark editorial. Wordmark, one line, index. No motion in the field. */

.home {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  min-height: 100dvh;
  padding:
    max(1.25rem, env(safe-area-inset-top))
    max(1.25rem, env(safe-area-inset-right))
    max(1.25rem, env(safe-area-inset-bottom))
    max(1.25rem, env(safe-area-inset-left));
}

.running {
  margin: 0;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.home main {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.home h1 {
  margin: 0;
  max-width: 100%;
  font-size: clamp(2.6rem, 13.2vw, 10.5rem);
  line-height: 0.88;
  letter-spacing: -0.04em;
  font-weight: 700;
  overflow-wrap: normal;
  word-break: keep-all;
}

.hero-line {
  margin: 0.9rem 0 0;
  max-width: 28em;
  font-size: clamp(1rem, 2.2vw, 1.25rem);
  font-weight: 500;
  color: var(--ink);
}

.index {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 2.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.index a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}

.index a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 10px;
  height: 2px;
  width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.index a:hover::after,
.index a[aria-current="page"]::after {
  transform: scaleX(1);
}

/* Inner pages */

.page {
  padding:
    max(1.25rem, env(safe-area-inset-top))
    max(1.25rem, env(safe-area-inset-right))
    max(1.5rem, env(safe-area-inset-bottom))
    max(1.25rem, env(safe-area-inset-left));
  max-width: calc(var(--measure) + (var(--pad) * 2));
}

.mast {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  margin-bottom: clamp(3rem, 8vw, 5.5rem);
}

.word {
  letter-spacing: -0.03em;
  text-decoration: none;
}

.mast nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 1.15rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mast nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}

.mast nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 10px;
  height: 2px;
  width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.mast nav a:hover::after,
.mast nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.mast .word {
  position: relative;
  transition: color 0.2s ease;
}

.mast .word:hover { color: var(--accent); }

.page h1 {
  margin: 0 0 1.5rem;
  font-size: clamp(2.5rem, 6vw, 4rem);
  line-height: 0.92;
}

.lede { max-width: 34em; }

.list {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.list li {
  display: grid;
  grid-template-columns: 2.5rem 1fr auto;
  gap: 1rem;
  align-items: baseline;
  padding: 0.85rem 0;
  border-top: 1px solid var(--rule);
}

.list li:last-child { border-bottom: 1px solid var(--rule); }

.num { font-variant-numeric: tabular-nums; }

.meta { color: var(--ink); }

.foot {
  margin-top: 4rem;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

button,
.button {
  font: inherit;
  color: var(--paper);
  background: var(--ink);
  border: 1px solid var(--ink);
  padding: 0.55rem 0.9rem;
  cursor: pointer;
  letter-spacing: -0.02em;
}

button:hover,
.button:hover { background: #000; }

button:disabled {
  background: transparent;
  color: var(--ink);
  cursor: not-allowed;
}

p button + button { margin-left: 0.75rem; }

form { margin-top: 1.5rem; }

label {
  display: block;
  margin: 1.1rem 0 0.35rem;
}

input,
textarea {
  width: 100%;
  max-width: 28rem;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--ink);
  border-radius: 0;
  padding: 0.7rem 0;
}

textarea { min-height: 7rem; resize: vertical; }

.trap {
  position: absolute;
  left: -9999px;
  height: 0;
  width: 0;
  overflow: hidden;
}

.note {
  margin-top: 1.5rem;
  max-width: 34em;
}

.basket-line {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  border-top: 1px solid var(--rule);
}

.empty { margin-top: 1rem; }

@media (max-width: 640px) {
  .list li { grid-template-columns: 2rem 1fr; }
  .list .meta { grid-column: 2; }
  .home h1 { letter-spacing: -0.035em; }
  .index { gap: 0 1.25rem; }
  .mast { margin-bottom: 2.25rem; }
  .page h1 { font-size: clamp(2.15rem, 11vw, 3rem); }
}
