/* Clotho landing page.
 *
 * A self-contained visual language, separate from the Phase-0 studies system in
 * style.css: Sora over IBM Plex Mono, a warm paper ground, a single electric
 * blue accent, hard offset shadows instead of elevation, and full-bleed ink and
 * blue bands to break the page into movements. Only the landing loads this
 * file, so class names here are prefixed `clo-` purely to keep the two
 * vocabularies legible side by side. */

:root {
  --clo-paper: #f3f0e9;
  --clo-ink: #1a2233;
  --clo-blue: #2b49d4;
  --clo-blue-dark: #1e37ab;
  --clo-body: #3d3b32;
  --clo-body-strong: #2d2b23;
  --clo-muted: #6d6a5f;
  --clo-faint: #9a9484;
  --clo-rule: #d7d2c6;
  --clo-sand: #e6ddca;
  --clo-dashed: #b0aa9a;

  /* Text and rules that sit on the ink bands. */
  --clo-on-ink: #f3f0e9;
  --clo-on-ink-body: #c3c9d8;
  --clo-on-ink-muted: #a3abc0;
  --clo-on-ink-dim: #7f889d;
  --clo-on-ink-off: #8b93a8;
  --clo-on-ink-rule: rgba(243, 240, 233, 0.24);
  --clo-blue-light: #93a6ff;
  --clo-string: #c9b98a;

  --clo-sans: "Sora", system-ui, sans-serif;
  --clo-mono: "IBM Plex Mono", ui-monospace, monospace;

  --clo-measure: 1080px;
  --clo-gutter: 30px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--clo-paper);
}

body {
  font-family: var(--clo-sans);
  -webkit-font-smoothing: antialiased;
  color: var(--clo-ink);
  overflow-x: hidden;
}

a {
  color: var(--clo-blue);
  text-decoration: none;
}

a:hover {
  color: var(--clo-blue-dark);
}

::selection {
  background: rgba(43, 73, 212, 0.16);
}

.clo-skip {
  position: absolute;
  left: -9999px;
}

.clo-skip:focus {
  left: 12px;
  top: 12px;
  z-index: 100;
  background: var(--clo-ink);
  color: var(--clo-paper);
  font-family: var(--clo-mono);
  font-size: 13px;
  padding: 8px 14px;
  border-radius: 4px;
}

/* ---------------------------------------------------------------- shell -- */

.clo-wrap {
  max-width: var(--clo-measure);
  margin: 0 auto;
  padding: 0 var(--clo-gutter);
}

/* Every band on paper shares one top rhythm; the bottom is left to the band
 * itself so the full-bleed ink and blue bands can close against each other. */
.clo-section {
  padding-top: 52px;
}

/* Full-bleed colour bands. The wrap inside keeps the measure. */
.clo-band--ink {
  background: var(--clo-ink);
  color: var(--clo-on-ink);
  margin-top: 58px;
  padding: 52px 0;
}

.clo-band--blue {
  background: var(--clo-blue);
  color: var(--clo-on-ink);
  margin-top: 64px;
  padding: 52px 0 54px;
}

/* The three-weight rule that opens the page, echoing the brand's blue / ink /
 * sand split. */
.clo-rail {
  display: flex;
  height: 6px;
}

.clo-rail span:nth-child(1) {
  flex: 3;
  background: var(--clo-blue);
}

.clo-rail span:nth-child(2) {
  flex: 1;
  background: var(--clo-ink);
}

.clo-rail span:nth-child(3) {
  flex: 5;
  background: var(--clo-sand);
}

.clo-eyebrow {
  font-family: var(--clo-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--clo-blue);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.clo-eyebrow svg {
  flex: none;
}

.clo-band--ink .clo-eyebrow {
  color: var(--clo-blue-light);
}

/* The recurring editorial split: heading left, running text right. */
.clo-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.clo-h2 {
  font-size: 34px;
  line-height: 1.08;
  letter-spacing: -0.026em;
  font-weight: 600;
  margin: 0;
}

.clo-prose {
  font-size: 16px;
  line-height: 1.62;
  color: var(--clo-body);
  margin: 0;
}

.clo-band--ink .clo-prose {
  color: var(--clo-on-ink-body);
}

.clo-prose--lead {
  font-size: 16.5px;
  line-height: 1.68;
}

.clo-prose--lead p {
  margin: 0 0 16px;
}

.clo-prose--lead p:last-child {
  margin: 0;
}

.clo-brace {
  font-family: var(--clo-mono);
  color: var(--clo-blue);
  font-weight: 500;
}

.clo-accent {
  color: var(--clo-blue);
  font-weight: 600;
}

.clo-pill {
  font-family: var(--clo-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--clo-blue);
  background: rgba(43, 73, 212, 0.1);
  border: 1px solid rgba(43, 73, 212, 0.3);
  border-radius: 20px;
  padding: 1px 8px;
  margin-left: 8px;
  vertical-align: 2px;
  white-space: nowrap;
}

/* On ink there is no tinted plate to sit on, so the pill is an outline only. */
.clo-pill--on-ink {
  color: var(--clo-blue-light);
  background: none;
  border-color: rgba(147, 166, 255, 0.45);
}

/* --------------------------------------------------------------- header -- */

.clo-masthead {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(243, 240, 233, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--clo-ink);
  /* A hard blue underline rather than a soft drop shadow, so the sticky bar
   * reads as another rule in the same family as .clo-rail. */
  box-shadow: 0 3px 0 rgba(43, 73, 212, 0.85);
}

.clo-masthead .clo-wrap {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.clo-brand {
  display: flex;
  align-items: center;
  min-width: 0;
}

/* The wordmark is an inked chip; the version tab butts straight against it with
 * no seam, so the two read as one printed stamp. */
.clo-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--clo-ink);
  color: var(--clo-paper);
  padding: 6px 11px 6px 9px;
  flex: none;
}

.clo-chip span {
  font-family: var(--clo-mono);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.1em;
}

.clo-version {
  font-family: var(--clo-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--clo-paper);
  background: var(--clo-blue);
  padding: 6px 8px;
  align-self: stretch;
  display: inline-flex;
  align-items: center;
  flex: none;
}

.clo-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-family: var(--clo-mono);
  font-size: 13px;
}

.clo-nav-link {
  color: #4a473e;
}

.clo-nav-link:hover {
  color: var(--clo-blue);
}

/* -------------------------------------------------------------- buttons -- */

/* Hard offset shadow that collapses under the press, rather than a hover lift. */
.clo-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--clo-mono);
  font-weight: 600;
  font-size: 13.5px;
  letter-spacing: 0.01em;
  padding: 13px 20px;
  border-radius: 4px;
  border: 1.5px solid var(--clo-ink);
  box-shadow: 4px 4px 0 var(--clo-ink);
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease;
}

.clo-btn:hover,
.clo-btn:focus-visible {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--clo-ink);
}

.clo-btn--primary {
  background: var(--clo-blue);
  color: #fff;
}

.clo-btn--primary:hover {
  color: #fff;
}

.clo-btn--small {
  background: var(--clo-ink);
  color: var(--clo-paper);
  gap: 8px;
  font-size: 13px;
  padding: 7px 15px;
  box-shadow: 3px 3px 0 var(--clo-blue);
}

.clo-btn--small:hover,
.clo-btn--small:focus-visible {
  color: var(--clo-paper);
  box-shadow: 1px 1px 0 var(--clo-blue);
}

/* Sits on the blue CTA band, so it inverts: paper face, ink shadow. */
.clo-btn--large {
  background: var(--clo-paper);
  color: var(--clo-ink);
  font-size: 14px;
  padding: 15px 26px;
  box-shadow: 5px 5px 0 var(--clo-ink);
  white-space: nowrap;
}

.clo-btn--large:hover,
.clo-btn--large:focus-visible {
  color: var(--clo-ink);
  box-shadow: 3px 3px 0 var(--clo-ink);
}

.clo-btn svg {
  flex: none;
}

/* ----------------------------------------------------------------- hero -- */

/* The lilac wash is the only gradient on the page; it fades to paper before the
 * hero rule so the band edge is the rule, not the colour change. */
.clo-hero {
  background: linear-gradient(180deg, #eae7f4 0%, var(--clo-paper) 92%);
}

.clo-hero .clo-wrap {
  padding-top: 46px;
  padding-bottom: 30px;
  animation: clo-rise 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.clo-hero-grid {
  display: grid;
  grid-template-columns: 1.42fr 0.58fr;
  gap: 34px;
  align-items: end;
  padding-bottom: 30px;
  border-bottom: 2px solid var(--clo-ink);
}

/* Rotating headline. The four lines are stacked on top of each other, so the
 * box needs a reserved height; the clip keeps the outgoing line from widening
 * the page as it swipes, while leaving descenders and the focus ring room. */
.clo-headlines {
  position: relative;
  /* The floor only has to clear the first headline, which is all a no-JS render
   * ever shows; the rotator measures the other three and raises it if one of
   * them is taller. */
  min-height: var(--clo-headline-h, 178px);
  clip-path: inset(-400px 0px);
  margin: 0;
  font-size: 50px;
  line-height: 1.06;
  letter-spacing: -0.038em;
  font-weight: 600;
}

.clo-headline {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  transition:
    opacity 0.42s ease,
    transform 0.52s cubic-bezier(0.3, 0.8, 0.25, 1);
  /* Default resting place is off to the right; the line leaving swaps to the
   * left (.is-leaving) so a rotation reads as one continuous travel. */
  opacity: 0;
  transform: translateX(46px);
  pointer-events: none;
}

.clo-headline.is-leaving {
  transform: translateX(-46px);
}

.clo-headline.is-active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.clo-qualifier {
  color: var(--clo-muted);
  font-weight: 500;
}

/* Without scripting the dots cannot do anything, and only the first headline is
 * ever shown — so they are hidden until the rotator is live. */
.clo-dots {
  display: none;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  line-height: 0;
}

.js .clo-dots {
  display: flex;
}

.clo-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  margin: 0;
  border: none;
  appearance: none;
  flex: none;
  border-radius: 20px;
  cursor: pointer;
  background: rgba(26, 34, 51, 0.22);
  transition:
    width 0.35s cubic-bezier(0.2, 0.7, 0.2, 1),
    background 0.3s ease;
}

.clo-dot[aria-pressed="true"] {
  width: 26px;
  background: var(--clo-blue);
}

.clo-hero-copy {
  font-size: 19px;
  line-height: 1.55;
  color: var(--clo-body);
  margin: 22px 0 16px;
  max-width: 520px;
}

.clo-hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}

/* Not a button — the command is shown as a terminal chip you read, with the
 * same offset-shadow construction as the buttons beside it. */
.clo-command {
  font-family: var(--clo-mono);
  font-size: 15.5px;
  color: var(--clo-on-ink);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--clo-ink);
  border: 1.5px solid var(--clo-ink);
  border-radius: 4px;
  box-shadow: 4px 4px 0 var(--clo-blue);
  padding: 12px 18px;
  margin: 0;
}

.clo-dollar {
  color: var(--clo-blue-light);
}

/* -------------------------------------------------------- supports card -- */

.clo-supports {
  background: var(--clo-ink);
  color: var(--clo-on-ink);
  border: 1.5px solid var(--clo-ink);
  border-radius: 4px;
  box-shadow: 6px 6px 0 var(--clo-blue);
  padding: 20px 22px 18px;
}

.clo-supports-label {
  font-family: var(--clo-mono);
  font-size: 12px;
  color: var(--clo-on-ink-muted);
  letter-spacing: 0.05em;
  margin: 0;
}

.clo-supports-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.15;
}

.clo-supports-list li.is-pending {
  color: var(--clo-on-ink-off);
}

.clo-coverage {
  border-top: 1px solid var(--clo-on-ink-rule);
  margin-top: 18px;
  padding-top: 16px;
}

.clo-coverage-value {
  font-family: var(--clo-mono);
  font-size: 44px;
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.04em;
  margin: 0;
}

/* Tabular figures keep the count-up from jittering the % sign sideways. */
.clo-coverage-value [data-coverage] {
  font-variant-numeric: tabular-nums;
}

.clo-star {
  color: var(--clo-blue-light);
}

.clo-coverage-value .clo-star {
  font-size: 22px;
  font-weight: 500;
  vertical-align: super;
  line-height: 1;
}

.clo-coverage-note {
  font-size: 13.5px;
  color: var(--clo-on-ink-muted);
  margin: 8px 0 0;
  line-height: 1.45;
}

.clo-coverage-source {
  font-size: 12px;
  color: var(--clo-on-ink-dim);
  margin: 10px 0 0;
  line-height: 1.4;
}

.clo-coverage-source a {
  color: var(--clo-blue-light);
  border-bottom: 1px solid rgba(147, 166, 255, 0.4);
}

@keyframes clo-rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* -------------------------------------------------------------- toolbox -- */

.clo-toolbox-intro {
  margin-bottom: 30px;
}

.clo-tools {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-bottom: 26px;
  padding: 0;
  list-style: none;
}

.clo-tool {
  border: 1.5px solid var(--clo-ink);
  border-radius: 4px;
  padding: 16px 17px 18px;
  background: rgba(43, 73, 212, 0.045);
}

/* Not shipped yet: dashed edge, drained fill, muted type. */
.clo-tool--soon {
  border-style: dashed;
  border-color: var(--clo-dashed);
  background: rgba(43, 73, 212, 0.02);
}

.clo-tool-name {
  font-family: var(--clo-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--clo-ink);
  margin: 0 0 9px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.clo-tool-name b {
  color: var(--clo-blue);
  font-weight: inherit;
}

.clo-tool--soon .clo-tool-name {
  color: var(--clo-muted);
}

.clo-tool--soon .clo-tool-name b {
  color: #8a9bd8;
}

.clo-tool-body {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--clo-body);
  margin: 0;
}

.clo-tool--soon .clo-tool-body {
  color: var(--clo-muted);
}

/* ------------------------------------------------------------ terminals -- */

.clo-terminals {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  align-items: stretch;
}

.clo-term {
  background: var(--clo-ink);
  border: 1.5px solid var(--clo-ink);
  border-radius: 4px;
  box-shadow: 6px 6px 0 var(--clo-blue);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.clo-term-bar {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px;
  border-bottom: 1px solid rgba(243, 240, 233, 0.18);
  font-family: var(--clo-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--clo-on-ink-muted);
}

.clo-term-bar::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--clo-blue);
  flex: none;
}

.clo-term pre {
  padding: 20px 22px 24px;
  margin: 0;
  font-family: var(--clo-mono);
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--clo-on-ink);
  overflow-x: auto;
  flex: 1;
}

.clo-kw {
  color: var(--clo-blue-light);
}

.clo-str {
  color: var(--clo-string);
}

.clo-term-note {
  color: var(--clo-on-ink-dim);
}

/* --------------------------------------------------------------- why/wins -- */

.clo-fast-intro {
  margin-bottom: 26px;
}

.clo-featured {
  border-top: 2px solid rgba(243, 240, 233, 0.5);
  padding-top: 28px;
}

.clo-featured-num {
  font-family: var(--clo-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--clo-blue-light);
  margin: 0 0 10px;
}

.clo-h3 {
  font-size: 26px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 600;
  margin: 0;
}

.clo-wins {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 48px;
  border-top: 1px solid var(--clo-on-ink-rule);
  margin-top: 38px;
}

.clo-win {
  padding: 26px 0;
  border-bottom: 1px solid var(--clo-on-ink-rule);
}

.clo-win-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 7px;
}

.clo-win-num {
  font-family: var(--clo-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--clo-blue-light);
}

.clo-win-title {
  font-size: 18px;
  font-weight: 600;
}

.clo-win-body {
  font-size: 15px;
  line-height: 1.6;
  color: var(--clo-on-ink-body);
  margin: 0;
  padding-left: 25px;
}

/* ---------------------------------------------------------- correctness -- */

.clo-checks {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 22px 24px 8px;
  list-style: none;
  background: rgba(43, 73, 212, 0.055);
  border: 1.5px solid var(--clo-ink);
  border-radius: 4px;
  box-shadow: 5px 5px 0 rgba(43, 73, 212, 0.16);
}

.clo-check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  border-bottom: 1px solid var(--clo-rule);
  padding-bottom: 16px;
}

.clo-check:last-child {
  border-bottom: none;
}

.clo-check-mark {
  color: var(--clo-blue);
  font-weight: 600;
  font-family: var(--clo-mono);
}

.clo-check-text {
  font-size: 15.5px;
  color: var(--clo-body-strong);
  line-height: 1.5;
}

.clo-check--todo .clo-check-mark {
  color: var(--clo-dashed);
}

.clo-check--todo .clo-check-text {
  color: var(--clo-muted);
}

/* ------------------------------------------------------------ cta/footer -- */

.clo-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.clo-cta-copy {
  flex: 1 1 420px;
}

.clo-cta h2 {
  font-size: 40px;
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin: 0 0 16px;
  max-width: 560px;
}

.clo-cta p {
  font-size: 16px;
  color: #dfe3fb;
  margin: 0;
  max-width: 460px;
  line-height: 1.55;
}

.clo-cta p + p {
  font-size: 15px;
  margin-top: 14px;
}

.clo-cta a:not(.clo-btn) {
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
}

.clo-footer {
  background: var(--clo-ink);
}

.clo-footer .clo-wrap {
  padding-top: 26px;
  padding-bottom: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-family: var(--clo-mono);
  font-size: 12px;
  color: var(--clo-on-ink-muted);
}

.clo-footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* The footer inverts the masthead stamp: blue plate instead of ink. */
.clo-footer .clo-chip {
  background: var(--clo-blue);
  gap: 7px;
  padding: 4px 9px 4px 7px;
}

.clo-footer .clo-chip span {
  font-size: 11px;
}

.clo-footer-links {
  display: flex;
  gap: 22px;
}

.clo-footer-links a {
  color: var(--clo-blue-light);
}

.clo-footer-links a:hover {
  color: var(--clo-paper);
}

/* ----------------------------------------------------------- responsive -- */

@media (max-width: 860px) {
  .clo-hero-grid,
  .clo-split,
  .clo-wins,
  .clo-terminals {
    grid-template-columns: 1fr;
    gap: 22px;
    column-gap: 0;
  }

  .clo-headlines {
    min-height: 170px;
  }

  .clo-tools {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  .clo-nav-link {
    display: none;
  }

  .clo-headlines {
    font-size: 42px;
    min-height: 150px;
  }
}

@media (max-width: 440px) {
  .clo-headlines {
    font-size: 34px;
    min-height: 145px;
  }

  .clo-tools {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .clo-hero .clo-wrap {
    animation: none;
  }

  .clo-btn,
  .clo-dot,
  .clo-headline {
    transition: none;
  }

  /* With motion off the rotator holds one headline, so the offsets that would
   * park the others off-screen are dropped. */
  .clo-headline {
    transform: none;
  }
}
