/* Rail Letters: components. Built only from tokens.css. */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--rl-paper);
  color: var(--rl-ink);
  font-family: var(--rl-font-sans);
  font-size: var(--rl-text-body);
  line-height: 1.55;
  overflow-x: clip;
}

img, svg { display: block; max-width: 100%; }

a { color: inherit; }

/* ---------- Page frame ---------- */

.rl-page {
  padding-inline: var(--rl-gutter);
}

.rl-container {
  max-width: var(--rl-container);
  margin-inline: auto;
}

.rl-section { padding-block: var(--rl-section); }
.rl-section--tight { padding-block: calc(var(--rl-section) * 0.55); }
.rl-section--bone {
  background: var(--rl-bone);
  margin-inline: calc(50% - 50vw);
  padding-inline: calc(50vw - 50%);
}

/* ---------- The rails: giant vertical wordmark on both edges ---------- */

.rl-rail {
  position: fixed;
  z-index: 1;
  margin: 0;
  font-family: var(--rl-font-rail);
  font-size: var(--rl-text-rail);
  line-height: 0.82;
  letter-spacing: -0.02em;
  color: var(--rl-ink);
  writing-mode: vertical-rl;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}

.rl-rail--left {
  left: -0.14em;
  top: 22vh;
  transform: rotate(180deg);
}

.rl-rail--right {
  right: -0.14em;
  bottom: -0.08em;
}

.rl-rail--red { color: var(--rl-red); }

/* On narrow screens the rails become one horizontal band under the nav */
.rl-band {
  display: none;
  overflow-x: clip;
  font-family: var(--rl-font-rail);
  font-size: clamp(40px, 15vw, 72px);
  line-height: 0.9;
  letter-spacing: -0.02em;
  white-space: nowrap;
  margin: 8px calc(var(--rl-gutter) * -1) 0;
  padding-inline: 8px;
}

@media (max-width: 900px) {
  .rl-rail { display: none; }
  .rl-band { display: block; }
}

/* ---------- Wordmark and nav ---------- */

.rl-mark {
  display: inline-grid;
  font-family: var(--rl-font-rail);
  font-size: 17px;
  line-height: 0.9;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--rl-ink);
}
.rl-mark span:last-child { padding-left: 1.6em; }

.rl-nav {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 28px;
}

.rl-nav__links {
  display: flex;
  gap: clamp(16px, 2.4vw, 36px);
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 17px;
  font-weight: 500;
}
.rl-nav__links a { text-decoration: none; }
.rl-nav__links a:hover,
.rl-nav__links a[aria-current] {
  text-decoration: underline;
  text-decoration-thickness: var(--rl-underline);
  text-underline-offset: 6px;
}

.rl-nav__actions { display: flex; align-items: center; gap: 12px; }

@media (max-width: 900px) {
  .rl-nav__links { display: none; }
  .rl-nav { padding-block: 18px; }
}

/* ---------- Type ---------- */

.rl-hero-title {
  font-family: var(--rl-font-sans);
  font-weight: 600;
  font-size: var(--rl-text-hero);
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 0;
}

.rl-h2 {
  font-weight: 500;
  font-size: var(--rl-text-h2);
  line-height: 1.04;
  letter-spacing: -0.025em;
  margin: 0;
}

.rl-h3 {
  font-weight: 600;
  font-size: var(--rl-text-h3);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0;
}

/* Big underlined title, the reference move for every listing */
.rl-title {
  font-weight: 500;
  font-size: var(--rl-text-title);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0;
}
.rl-title a,
.rl-title--plain {
  text-decoration: underline;
  text-decoration-thickness: var(--rl-underline);
  text-underline-offset: 0.12em;
}
.rl-title a:hover { color: var(--rl-red); }

.rl-lead {
  font-size: var(--rl-text-lead);
  line-height: 1.5;
  color: var(--rl-soft);
  max-width: 600px;
  margin: 0;
}

.rl-meta {
  font-family: var(--rl-font-serif);
  font-size: 16px;
  color: var(--rl-ink);
  margin: 0;
}
.rl-meta--soft { color: var(--rl-soft); }

.rl-label {
  display: inline-block;
  font-size: var(--rl-text-label);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.rl-red { color: var(--rl-red); }

/* Section header: h2 on the left, arrow link on the right */
.rl-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.rl-arrow {
  font-weight: 600;
  font-size: 18px;
  text-decoration: underline;
  text-decoration-thickness: var(--rl-underline);
  text-underline-offset: 5px;
  white-space: nowrap;
}
.rl-arrow::after { content: " \2192"; text-decoration: none; display: inline-block; margin-left: 4px; }

/* ---------- Buttons ---------- */

.rl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border: var(--rl-border);
  border-radius: var(--rl-radius-pill);
  background: var(--rl-ink);
  color: var(--rl-paper);
  font-family: var(--rl-font-sans);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.rl-btn:hover { background: var(--rl-red); border-color: var(--rl-red); }

.rl-btn--outline { background: transparent; color: var(--rl-ink); }
.rl-btn--outline:hover { background: var(--rl-ink); color: var(--rl-paper); border-color: var(--rl-ink); }

.rl-btn--red { background: var(--rl-red); border-color: var(--rl-red); }
.rl-btn--red:hover { background: var(--rl-ink); border-color: var(--rl-ink); }

.rl-btn--sm { padding: 8px 16px; font-size: 11px; }
.rl-btn--lg { padding: 16px 30px; font-size: 14px; }
.rl-btn--block { width: 100%; }

.rl-icon-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--rl-ink);
  color: var(--rl-paper);
  border: 0;
}

/* ---------- Badges ---------- */

.rl-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: var(--rl-border);
  border-radius: var(--rl-radius-pill);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  justify-self: start;
  width: fit-content;
}
.rl-badge--red { background: var(--rl-red); border-color: var(--rl-red); color: var(--rl-paper); }
.rl-badge--sun { background: var(--rl-sun); }
.rl-badge--ink { background: var(--rl-ink); color: var(--rl-paper); }

/* ---------- Hero ---------- */

.rl-hero {
  display: grid;
  gap: clamp(20px, 3vw, 32px);
  padding-block: clamp(24px, 5vw, 56px) clamp(40px, 6vw, 72px);
}
.rl-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Full-width feature frame, the big picture under the nav */
.rl-feature {
  position: relative;
  overflow: hidden;
  background: var(--rl-red);
  aspect-ratio: 16 / 8;
  min-height: 320px;
}

/* ---------- Drawn posters ---------- */

.rl-poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: var(--rl-bone);
  color: var(--rl-ink);
  box-shadow: var(--rl-shadow-poster);
  isolation: isolate;
}
.rl-poster--red { background: var(--rl-red); color: var(--rl-paper); }
.rl-poster--green { background: var(--rl-green); color: var(--rl-paper); }
.rl-poster--sun { background: var(--rl-sun); }
.rl-poster--sky { background: var(--rl-sky); }
.rl-poster--pink { background: var(--rl-pink); }
.rl-poster--ink { background: var(--rl-ink); color: var(--rl-paper); }

.rl-poster svg.rl-poster__art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.rl-poster__top {
  position: absolute;
  top: 6%;
  left: 7%;
  right: 7%;
  display: flex;
  justify-content: space-between;
  font-size: clamp(10px, 1.1vw, 13px);
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.rl-poster__type {
  position: absolute;
  left: 7%;
  right: 7%;
  bottom: 7%;
  margin: 0;
  font-family: var(--rl-font-rail);
  font-size: clamp(26px, 4.4vw, 60px);
  line-height: 0.88;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.rl-poster__foot {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 10px 7%;
  background: var(--rl-paper);
  color: var(--rl-ink);
  font-family: var(--rl-font-rail);
  font-size: clamp(20px, 3vw, 40px);
  line-height: 1;
  text-transform: uppercase;
}

/* ---------- Zigzag rows ---------- */

.rl-zig {
  display: grid;
  gap: clamp(64px, 9vw, 120px);
}

.rl-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: var(--rl-gap);
}
.rl-row > .rl-poster { max-width: 440px; width: 100%; }
.rl-row__text { display: grid; gap: 14px; align-content: center; }
.rl-row--flip > .rl-poster { order: 2; justify-self: end; }
.rl-row--flip > .rl-row__text { order: 1; }

@media (max-width: 760px) {
  .rl-row { grid-template-columns: 1fr; }
  .rl-row--flip > .rl-poster { order: 0; justify-self: start; }
  .rl-row--flip > .rl-row__text { order: 1; }
}

/* ---------- Cards ---------- */

.rl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(20px, 3vw, 36px);
}

.rl-card {
  display: grid;
  gap: 12px;
  align-content: start;
  padding-top: 18px;
  border-top: var(--rl-border);
}
.rl-card__num {
  font-family: var(--rl-font-rail);
  font-size: 28px;
  line-height: 1;
  color: var(--rl-red);
}
.rl-card__text { margin: 0; color: var(--rl-soft); }

/* Event list: date column, title, action */
.rl-list { list-style: none; margin: 0; padding: 0; border-top: var(--rl-border); }
.rl-list__item {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: 20px;
  align-items: center;
  padding-block: 22px;
  border-bottom: var(--rl-border-thin);
}
.rl-list__date { font-family: var(--rl-font-serif); font-size: 16px; }
.rl-list__title { font-size: 22px; font-weight: 500; letter-spacing: -0.01em; margin: 0; }
@media (max-width: 640px) {
  .rl-list__item { grid-template-columns: 1fr; gap: 6px; }
  .rl-list__item .rl-btn { justify-self: start; }
}

/* Big statement band in red */
.rl-statement {
  background: var(--rl-red);
  color: var(--rl-paper);
  margin-inline: calc(50% - 50vw);
  padding: var(--rl-section) calc(50vw - 50%);
}
.rl-statement .rl-hero-title { max-width: 14ch; }
.rl-statement .rl-lead { color: var(--rl-paper); opacity: 0.9; }

/* Stats */
.rl-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 24px; }
.rl-stat__num { font-family: var(--rl-font-rail); font-size: clamp(36px, 4.4vw, 60px); line-height: 1; margin: 0; }
.rl-stat__label { font-family: var(--rl-font-serif); color: var(--rl-soft); margin: 8px 0 0; }

/* ---------- Pricing ---------- */

.rl-toggle {
  display: inline-flex;
  border: var(--rl-border);
  border-radius: var(--rl-radius-pill);
  padding: 3px;
}
.rl-toggle button {
  border: 0;
  background: transparent;
  border-radius: var(--rl-radius-pill);
  padding: 8px 18px;
  font: 700 12px/1 var(--rl-font-sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  color: var(--rl-ink);
  white-space: nowrap;
}
.rl-toggle button[aria-pressed="true"] { background: var(--rl-ink); color: var(--rl-paper); }

.rl-plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  border-top: var(--rl-border);
  border-left: var(--rl-border);
}
.rl-plan {
  display: grid;
  gap: 16px;
  align-content: start;
  padding: clamp(24px, 3vw, 36px);
  border-right: var(--rl-border);
  border-bottom: var(--rl-border);
  background: var(--rl-paper);
}
.rl-plan--featured { background: var(--rl-sun); }
.rl-plan__name { font-family: var(--rl-font-rail); font-size: 22px; line-height: 1; margin: 0; text-transform: uppercase; }
.rl-plan__desc { margin: 0; font-family: var(--rl-font-serif); }
.rl-plan__price { font-size: 56px; font-weight: 600; letter-spacing: -0.04em; line-height: 1; margin: 0; }
.rl-plan__price small { font-size: 16px; font-weight: 500; letter-spacing: 0; }
.rl-plan__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rl-plan__list li { padding-left: 26px; position: relative; }
.rl-plan__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 12px;
  height: 12px;
  background: var(--rl-red);
  border-radius: 50%;
}
.rl-plan--featured .rl-plan__list li::before { background: var(--rl-ink); }

.rl-table-wrap { overflow-x: auto; border: var(--rl-border); }
.rl-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 16px; }
.rl-table th, .rl-table td { padding: 14px 18px; text-align: left; border-bottom: var(--rl-border-thin); }
.rl-table thead th { background: var(--rl-ink); color: var(--rl-paper); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; }
.rl-table td:not(:first-child), .rl-table th:not(:first-child) { text-align: center; }
.rl-table__yes::before { content: ""; display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: var(--rl-red); }
.rl-table__no { color: var(--rl-soft); }

.rl-faq { border-top: var(--rl-border); }
.rl-faq details { border-bottom: var(--rl-border-thin); }
.rl-faq summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-block: 22px;
  font-size: 21px;
  font-weight: 500;
  cursor: pointer;
}
.rl-faq summary::-webkit-details-marker { display: none; }
.rl-faq summary::after { content: "+"; font-family: var(--rl-font-rail); font-size: 22px; line-height: 1; transition: transform 0.2s; }
.rl-faq details[open] summary::after { transform: rotate(45deg); color: var(--rl-red); }
.rl-faq p { margin: 0 0 22px; max-width: 640px; font-family: var(--rl-font-serif); color: var(--rl-soft); }

/* ---------- Article ---------- */

.rl-article-head { display: grid; gap: 20px; max-width: 900px; padding-block: clamp(24px, 5vw, 56px) clamp(32px, 5vw, 56px); }

.rl-author { display: flex; align-items: center; gap: 12px; }
.rl-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--rl-sun);
  font-family: var(--rl-font-rail);
  font-size: 15px;
  flex-shrink: 0;
}
.rl-avatar--red { background: var(--rl-red); color: var(--rl-paper); }

.rl-prose {
  max-width: var(--rl-prose);
  font-family: var(--rl-font-serif);
  font-size: 19px;
  line-height: 1.7;
}
.rl-prose > * + * { margin-top: 1.1em; }
.rl-prose p { margin-bottom: 0; }
.rl-prose h2 {
  font-family: var(--rl-font-sans);
  font-size: 32px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 1.8em 0 0;
}
.rl-prose h3 { font-family: var(--rl-font-sans); font-size: 22px; font-weight: 600; margin: 1.5em 0 0; }
.rl-prose a { text-decoration-thickness: var(--rl-underline); text-underline-offset: 3px; }
.rl-prose ul { padding-left: 0; list-style: none; }
.rl-prose li { position: relative; padding-left: 28px; margin-top: 0.5em; }
.rl-prose li::before { content: ""; position: absolute; left: 4px; top: 0.7em; width: 10px; height: 10px; border-radius: 50%; background: var(--rl-red); }
.rl-prose blockquote {
  margin: 1.8em 0 0;
  padding: 0;
  font-family: var(--rl-font-sans);
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.rl-prose blockquote::before { content: ""; display: block; width: 56px; height: 8px; background: var(--rl-red); margin-bottom: 18px; }
.rl-prose figure { margin: 2em 0 0; }
.rl-prose figcaption { font-size: 15px; color: var(--rl-soft); margin-top: 10px; }
.rl-prose code { font-family: ui-monospace, Menlo, monospace; font-size: 0.85em; background: var(--rl-bone); padding: 2px 6px; }

.rl-callout {
  background: var(--rl-sun);
  padding: 22px 26px;
  font-family: var(--rl-font-sans);
  font-size: 17px;
  line-height: 1.55;
}
.rl-callout strong { display: block; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 6px; }

.rl-post { display: grid; gap: 14px; align-content: start; text-decoration: none; }
.rl-post .rl-poster { aspect-ratio: 4 / 3; box-shadow: none; }
.rl-post__title { font-size: 22px; font-weight: 500; line-height: 1.2; text-decoration: underline; text-decoration-thickness: var(--rl-underline); text-underline-offset: 4px; margin: 0; }

/* ---------- Forms ---------- */

.rl-form { display: grid; gap: 20px; }
.rl-field { display: grid; gap: 8px; }
.rl-label-text { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.rl-input, .rl-select {
  width: 100%;
  padding: 14px 16px;
  border: var(--rl-border);
  border-radius: var(--rl-radius-0);
  background: var(--rl-paper);
  font: 400 17px/1.3 var(--rl-font-sans);
  color: var(--rl-ink);
  appearance: none;
}
.rl-select {
  background-image: linear-gradient(45deg, transparent 50%, var(--rl-ink) 50%), linear-gradient(135deg, var(--rl-ink) 50%, transparent 50%);
  background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%;
  background-size: 6px 6px;
  background-repeat: no-repeat;
}
.rl-input:focus, .rl-select:focus { outline: 3px solid var(--rl-sun); outline-offset: 0; }
.rl-help { font-family: var(--rl-font-serif); font-size: 15px; color: var(--rl-soft); margin: 0; }
.rl-field--error .rl-input { border-color: var(--rl-red); }
.rl-error { font-size: 14px; font-weight: 600; color: var(--rl-red-deep); margin: 0; }

.rl-input-wrap { position: relative; }
.rl-input-wrap .rl-input { padding-right: 72px; }
.rl-input-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: none;
  font: 700 12px/1 var(--rl-font-sans);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: underline;
  cursor: pointer;
}

.rl-check { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; }
.rl-check input { appearance: none; flex-shrink: 0; width: 22px; height: 22px; margin: 1px 0 0; border: var(--rl-border); border-radius: 50%; background: var(--rl-paper); cursor: pointer; }
.rl-check input:checked { background: var(--rl-red); border-color: var(--rl-red); box-shadow: inset 0 0 0 4px var(--rl-paper); }

.rl-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.rl-choice label { display: block; cursor: pointer; }
.rl-choice input { position: absolute; opacity: 0; }
.rl-choice span {
  display: block;
  padding: 14px 16px;
  border: var(--rl-border);
  font-weight: 600;
}
.rl-choice span small { display: block; font-family: var(--rl-font-serif); font-weight: 400; color: var(--rl-soft); font-size: 14px; }
.rl-choice input:checked + span { background: var(--rl-ink); color: var(--rl-paper); }
.rl-choice input:checked + span small { color: var(--rl-bone-2); }

.rl-divider { display: flex; align-items: center; gap: 14px; font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.rl-divider::before, .rl-divider::after { content: ""; flex: 1; height: 2px; background: var(--rl-ink); }

/* ---------- Footer ---------- */

.rl-footer {
  border-top: var(--rl-border);
  padding-block: 48px 32px;
  display: grid;
  gap: 40px;
}
.rl-footer__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 28px; }
.rl-footer__cols h4 { margin: 0 0 12px; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; }
.rl-footer__cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rl-footer__cols a { text-decoration: none; }
.rl-footer__cols a:hover { text-decoration: underline; text-decoration-thickness: var(--rl-underline); }
.rl-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-family: var(--rl-font-serif); font-size: 14px; color: var(--rl-soft); }

/* ---------- Motion ---------- */

.rl-rise { animation: rl-rise 0.7s ease-out both; }
@keyframes rl-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .rl-rise { animation: none; } }

.rl-statement .rl-stat__label { color: var(--rl-paper); opacity: 0.88; }
figure.rl-feature { margin: 0; }
figure.rl-poster { margin: 0; }
.rl-fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.rl-fieldset legend { margin-bottom: 8px; padding: 0; }
