/* ============================================================
   Klaud — Marketing Site
   Anthropic-style system: ivory paper, near-black ink, serif
   prose, bold sans headlines, hairline rules, kraft panels,
   black pill buttons, dark footer.
   ============================================================ */

/* ---------- Fonts ---------- */
@font-face {
  font-family: 'Anthropic Serif';
  src: url('fonts/AnthropicSerif-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Anthropic Serif';
  src: url('fonts/AnthropicSerif-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Anthropic Serif';
  src: url('fonts/AnthropicSerif-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Anthropic Serif';
  src: url('fonts/AnthropicSerif-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ---------- Custom Properties ---------- */
:root {
  /* Paper */
  --bg: #faf9f5;
  --bg-soft: #f3f1ea;
  --kraft: #eae2d5;
  --kraft-deep: #e0d5c3;
  --card: #ffffff;

  /* Ink */
  --ink: #141413;
  --ink-soft: #4d4b45;
  --ink-faint: #86837b;
  --line: #e4e1d8;
  --line-strong: #d1cdc1;

  /* Claude terracotta */
  --accent: #d97757;
  --accent-hover: #c9653f;
  --accent-deep: #a94f2c;
  --accent-soft: #f7e7de;
  --accent-glow: rgba(217, 119, 87, 0.2);

  /* Dark surface */
  --dark: #141413;
  --dark-2: #1f1f1c;
  --dark-3: #2b2b26;
  --dark-line: rgba(250, 249, 245, 0.14);
  --dark-line-strong: rgba(250, 249, 245, 0.26);
  --cream: #faf9f5;
  --cream-soft: rgba(250, 249, 245, 0.72);

  /* Type stacks */
  --font-serif: 'Anthropic Serif', 'Newsreader', 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
  --font-sans: 'Anthropic Sans', 'Helvetica Neue', Helvetica, Arial, ui-sans-serif, sans-serif;
  --font-mono: ui-monospace, 'Cascadia Code', 'SF Mono', 'JetBrains Mono', Menlo, Consolas, monospace;

  /* Layout & Geometry */
  --wrap: 1240px;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-full: 9999px;

  /* Elevation — restrained; the system is flat by design */
  --shadow-card: 0 1px 2px rgba(20, 20, 19, 0.03);
  --shadow-window: 0 1px 2px rgba(20, 20, 19, 0.05), 0 30px 60px -34px rgba(20, 20, 19, 0.35);
}

/* ---------- Global Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 19px;
  line-height: 1.62;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

::selection {
  background: var(--accent);
  color: #fff;
}

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

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 56px);
}

/* Keyboard skip link */
.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 200;
  background: var(--ink);
  color: var(--cream);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-full);
  transition: top 0.18s ease;
}

.skip-link:focus-visible {
  top: 12px;
}

/* ---------- Typography ---------- */
h1, h2, h3 {
  margin: 0;
  text-wrap: balance;
}

/* Anthropic's headline voice: bold grotesque, tight leading */
h1 {
  font-family: var(--font-sans);
  font-size: clamp(2.75rem, 5.6vw, 4.35rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.033em;
}

/* Section statements are set in the serif, light weight */
h2 {
  font-family: var(--font-serif);
  font-size: clamp(2.3rem, 4.4vw, 3.5rem);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.021em;
}

/* Card titles are UI, so they take the sans */
h3 {
  font-family: var(--font-sans);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: -0.012em;
}

h1 em {
  font-style: normal;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 0.075em;
  text-underline-offset: 0.16em;
}

p {
  margin: 0 0 1em;
  text-wrap: pretty;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.735rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0 0 20px;
}

/* Short rule in front of every section eyebrow */
.eyebrow::before {
  content: '';
  flex: 0 0 auto;
  width: 24px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.8;
}

.eyebrow-light {
  color: #e8a382;
}

.lede {
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 1.5vw, 1.45rem);
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 46ch;
}

.standfirst {
  font-family: var(--font-serif);
  font-size: clamp(1.075rem, 1.3vw, 1.2rem);
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: 64ch;
  margin-top: 20px;
}

code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: rgba(217, 119, 87, 0.09);
  border: 1px solid rgba(217, 119, 87, 0.2);
  border-radius: 5px;
  padding: 0.08em 0.36em;
  white-space: nowrap;
}

.section-dark code {
  background: rgba(232, 163, 130, 0.13);
  border-color: rgba(232, 163, 130, 0.26);
  color: #f2c2a8;
}

/* ---------- Header & Navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 249, 245, 0.88);
  backdrop-filter: blur(14px) saturate(1.15);
  -webkit-backdrop-filter: blur(14px) saturate(1.15);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.site-header.is-scrolled {
  background: rgba(250, 249, 245, 0.96);
  border-bottom-color: var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 40px);
  height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  margin-right: auto;
}

.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-sans);
  font-size: 1.18rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.4vw, 34px);
}

.site-nav a {
  position: relative;
  font-family: var(--font-sans);
  font-size: 0.925rem;
  font-weight: 500;
  color: var(--ink-soft);
  padding: 6px 2px;
  transition: color 0.18s ease;
}

.site-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s cubic-bezier(0.2, 0, 0, 1);
}

.site-nav a:hover {
  color: var(--ink);
}

.site-nav a.is-active {
  color: var(--ink);
  font-weight: 600;
}

.site-nav a:hover::after,
.site-nav a.is-active::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  padding: 6px 13px;
  cursor: default;
}

.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(217, 119, 87, 0.7);
  animation: pulse-ring 2.4s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

@keyframes pulse-ring {
  0%, 100% { box-shadow: 0 0 0 0 rgba(217, 119, 87, 0.55); }
  50% { box-shadow: 0 0 0 5px rgba(217, 119, 87, 0); }
}

/* Mobile navigation toggle */
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  color: var(--ink);
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.nav-toggle:hover {
  background: #fff;
  border-color: var(--ink-faint);
}

.nav-toggle-bars {
  position: relative;
  display: block;
  width: 17px;
  height: 12px;
}

.nav-toggle-bars span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.75px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.24s ease, opacity 0.18s ease, top 0.24s ease;
}

.nav-toggle-bars span:nth-child(1) { top: 0; }
.nav-toggle-bars span:nth-child(2) { top: 5px; }
.nav-toggle-bars span:nth-child(3) { top: 10px; }

.nav-toggle[aria-expanded='true'] .nav-toggle-bars span:nth-child(1) {
  top: 5px;
  transform: rotate(45deg);
}
.nav-toggle[aria-expanded='true'] .nav-toggle-bars span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded='true'] .nav-toggle-bars span:nth-child(3) {
  top: 5px;
  transform: rotate(-45deg);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  text-decoration: none;
  border-radius: var(--radius-full);
  padding: 14px 27px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.btn-small {
  padding: 10px 20px;
  font-size: 0.875rem;
}

/* Primary: the black pill. Turns terracotta on hover. */
.btn-accent {
  background: var(--ink);
  color: var(--cream);
}

.btn-accent:hover {
  background: var(--accent);
  color: #fff;
}

.btn-accent .i-arrow {
  transition: transform 0.2s ease;
}

.btn-accent:hover .i-arrow {
  transform: translateX(3px);
}

.btn-ink {
  background: var(--ink);
  color: var(--cream);
}

.btn-ink:hover {
  background: var(--accent);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--ink);
  background: #fff;
}

.i-gh {
  flex-shrink: 0;
}

.i-ext {
  width: 11px;
  height: 11px;
  opacity: 0.7;
}

/* ---------- Copy Elements ---------- */
.copy-chip, .copy-line {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  padding: 13px 21px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.copy-chip:hover {
  border-color: var(--ink);
  background: #fff;
}

.copy-chip .prompt {
  color: var(--accent-deep);
  font-weight: 600;
}

.copy-chip code, .copy-line code {
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
  color: inherit;
}

.copy-feedback {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
}

.copy-feedback .i-copy,
.copy-feedback .i-check {
  position: absolute;
  inset: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.copy-feedback .i-copy {
  opacity: 0.6;
  transform: scale(1);
}

.copy-feedback .i-check {
  opacity: 0;
  transform: scale(0.6);
  color: var(--accent-deep);
}

.copy-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  transition: color 0.2s ease;
}

.copy-chip.is-copied,
.copy-line.is-copied {
  border-color: var(--accent);
}

.copy-chip.is-copied .copy-feedback .i-copy,
.copy-line.is-copied .copy-feedback .i-copy {
  opacity: 0;
  transform: scale(0.6);
}

.copy-chip.is-copied .copy-feedback .i-check,
.copy-line.is-copied .copy-feedback .i-check {
  opacity: 1;
  transform: scale(1);
}

.copy-chip.is-copied .copy-label,
.copy-line.is-copied .copy-label {
  color: var(--accent-deep);
}

.copy-line {
  width: 100%;
  border-radius: var(--radius-sm);
  justify-content: space-between;
  padding: 14px 18px;
  background: var(--bg);
}

.copy-line:hover {
  border-color: var(--ink);
  background: #fff;
}

/* ---------- Hero Section ---------- */
.hero {
  position: relative;
  padding: clamp(52px, 6.5vw, 96px) 0 0;
  overflow: hidden;
}

.hero-inner {
  position: relative;
}

/* Headline left, standfirst right — the anthropic.com split */
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: end;
}

.hero-main {
  min-width: 0;
}

.hero-side {
  min-width: 0;
  padding-bottom: 8px;
}

.hero-badge {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 26px;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.badge-tag {
  color: var(--accent-deep);
  font-weight: 600;
}

.badge-sep {
  color: var(--line-strong);
}

.hero h1 {
  margin-bottom: 30px;
}

.hero .lede {
  margin: 0;
}

.cta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-start;
}

/* Keep the button and the copy chip on one optical line */
.cta-row .btn,
.cta-row .copy-chip {
  min-height: 52px;
}

.cta-center {
  justify-content: center;
  margin-top: 48px;
}

/* ---------- Window Frame Preview ---------- */
.window {
  margin: clamp(48px, 6vw, 80px) 0 0;
  width: 100%;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-window);
}

.window-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 44px;
  padding: 0 18px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
}

.window-dots {
  display: flex;
  align-items: center;
  gap: 7px;
}

.window-bar .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid rgba(20, 20, 19, 0.1);
}

.dot-close { background: #eb6f65; }
.dot-min   { background: #e5a93c; }
.dot-max   { background: #54b76e; }

.window-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--ink-faint);
}

.window img {
  width: 100%;
  display: block;
}

.window-dark {
  background: var(--dark);
  border-color: #2b2b26;
  box-shadow: 0 1px 2px rgba(20, 20, 19, 0.2), 0 30px 60px -34px rgba(20, 20, 19, 0.6);
}

.window-dark .window-bar {
  background: #1f1f1c;
  border-bottom-color: #2b2b26;
}

.window-dark .window-title {
  color: rgba(250, 249, 245, 0.55);
}

.window-dark .dot-close { background: #d95e55; }
.window-dark .dot-min   { background: #cca036; }
.window-dark .dot-max   { background: #4ca562; }

/* ---------- Stats Section ---------- */
.stats {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-top: clamp(64px, 7vw, 104px);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.stat {
  padding: 38px 30px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-left: 1px solid var(--line);
}

.stat:first-child {
  border-left: none;
  padding-left: 0;
}

.stat:last-child {
  padding-right: 0;
}

.stat-num {
  font-family: var(--font-sans);
  font-size: clamp(2rem, 2.8vw, 2.5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.035em;
  color: var(--ink);
}

.stat-label {
  font-family: var(--font-serif);
  font-size: 0.97rem;
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 26ch;
  text-wrap: pretty;
}

/* ---------- Sections Common ---------- */
.section {
  padding: clamp(84px, 9vw, 136px) 0;
}

.section-tint {
  background: var(--kraft);
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.section-dark {
  background: var(--dark);
  color: var(--cream);
}

.section-dark h2 {
  color: var(--cream);
}

.section-dark .standfirst {
  color: var(--cream-soft);
}

.section-dark :focus-visible {
  outline-color: #e8a382;
}

.section-head {
  margin-bottom: clamp(44px, 5.5vw, 72px);
}

.section-head h2 {
  max-width: 22ch;
}

.section-head .standfirst {
  margin-top: 22px;
}

/* ---------- Feature Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 30px 32px;
  box-shadow: var(--shadow-card);
  transition: border-color 0.22s ease, background 0.22s ease;
}

.card:hover {
  border-color: var(--line-strong);
}

.card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 22px;
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent-soft);
  border: 1px solid rgba(217, 119, 87, 0.3);
}

.card-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--accent-deep);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.card-tag {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  padding: 4px 11px;
}

.card h3 {
  margin-bottom: 10px;
}

.card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.01rem;
  line-height: 1.6;
}

/* ---------- Tools Block ---------- */
.tools-block {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(36px, 6vw, 88px);
  align-items: start;
  margin-top: clamp(64px, 7.5vw, 104px);
  padding-top: clamp(56px, 6.5vw, 88px);
  border-top: 1px solid var(--line-strong);
}

.tools-title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 2.9vw, 2.5rem);
  font-weight: 400;
  line-height: 1.14;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}

.tools-copy p:last-child {
  color: var(--ink-soft);
  margin-bottom: 0;
}

.tools-list {
  margin: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.tool-item {
  display: grid;
  grid-template-columns: 172px 1fr;
  gap: 20px;
  align-items: baseline;
  padding: 14px 8px;
  border-bottom: 1px solid var(--line);
  transition: background 0.18s ease;
}

.tool-item:hover {
  background: rgba(255, 255, 255, 0.7);
}

.tool-item dt {
  margin: 0;
}

.tool-item dt code {
  color: var(--accent-deep);
  font-weight: 600;
  font-size: 0.87rem;
  padding: 3px 7px;
}

.tool-item dd {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.99rem;
}

/* ---------- Free Providers Grid ---------- */
.provider-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.provider {
  background: var(--card);
}

.provider .provider-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.provider h3 {
  font-size: 1.16rem;
}

.provider .basis {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.provider p:last-child {
  margin-bottom: 0;
}

.provider.featured {
  background: var(--accent-soft);
  border-color: rgba(217, 119, 87, 0.45);
}

.provider.featured .basis {
  border-bottom-color: rgba(217, 119, 87, 0.3);
}

.chip {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  padding: 4px 11px;
  white-space: nowrap;
}

.chip-accent {
  color: var(--accent-deep);
  background: #fff;
  border-color: rgba(217, 119, 87, 0.45);
}

.note-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 30px;
}

.note {
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 26px 28px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 1rem;
}

.note:last-child {
  margin-bottom: 0;
}

.note strong {
  color: var(--ink);
  font-weight: 600;
}

/* ---------- Safety Architecture (Dark) ---------- */
.dark-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.dark-item {
  background: var(--dark-2);
  border: 1px solid var(--dark-line);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: border-color 0.22s ease, background 0.22s ease;
}

.dark-item:hover {
  border-color: var(--dark-line-strong);
  background: var(--dark-3);
}

.dark-item-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
}

.safety-index {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.dark-item h3 {
  font-size: 1.1rem;
  color: var(--cream);
  margin: 0;
}

.dark-item p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(250, 249, 245, 0.66);
}

.dark-item strong {
  color: #f2c2a8;
  font-weight: 600;
}

/* ---------- Klaud CLI ---------- */
.cli-steps {
  display: grid;
  gap: 10px;
  margin: 20px 0 16px;
}

.cli-hint {
  font-size: 0.93rem;
  line-height: 1.6;
  color: var(--ink-faint);
  margin-bottom: 22px;
}

.cli-hint code {
  font-size: 0.85em;
  white-space: normal;
}

.cli-showcase .window {
  margin: 0;
}

/* A terminal, not a screenshot: the session is type, so it stays selectable
   and copyable the way a real transcript would be. */
.terminal {
  margin: 0;
  padding: 26px 28px 28px;
  background: var(--dark);
  color: var(--cream);
  font-family: var(--font-mono);
  font-size: 0.84rem;
  line-height: 1.72;
  overflow-x: auto;
}

.terminal .t-prompt {
  color: var(--accent);
  font-weight: 600;
}

.terminal .t-cmd {
  color: var(--cream);
  font-weight: 600;
}

.terminal .t-dim {
  color: rgba(250, 249, 245, 0.48);
}

.terminal .t-tool {
  color: #e8a382;
}

.terminal .t-ok {
  color: #7fbd8f;
}

.terminal .t-fail {
  color: #eb8b80;
}

.terminal .t-answer {
  color: rgba(250, 249, 245, 0.9);
}

/* ---------- Gallery ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.gallery-item {
  margin: 0;
}

.gallery-item .window {
  margin: 0;
}

.gallery-item figcaption {
  margin-top: 14px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--ink-faint);
  text-align: left;
}

.gallery .window img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: top center;
}

/* ---------- Install & Quick Start ---------- */
.install-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.install-card {
  padding: 30px 28px;
}

.install-card-head {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 18px;
}

.os-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-deep);
}

.install-card h3 {
  font-size: 1.1rem;
  margin: 0;
}

.install-card .hint {
  margin: 14px 4px 0;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  color: var(--ink-faint);
}

/* ---------- Site Footer (dark, like anthropic.com) ---------- */
.site-footer {
  background: var(--dark);
  color: var(--cream);
  padding: clamp(56px, 7vw, 88px) 0 44px;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

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

.footer-brand .brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 8px;
}

.footer-name {
  font-family: var(--font-sans);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--cream);
  margin: 0;
  line-height: 1.2;
}

.footer-tag {
  margin: 3px 0 0;
  font-family: var(--font-serif);
  font-size: 0.95rem;
  color: var(--cream-soft);
}

.footer-col {
  display: flex;
  flex-direction: column;
}

.footer-col-title {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(250, 249, 245, 0.5);
  margin: 0 0 14px;
}

.footer-col a,
.footer-col span {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: rgba(250, 249, 245, 0.78);
  padding: 7px 0;
  transition: color 0.16s ease;
}

.footer-col a:hover {
  color: var(--accent);
}

.footer-col .footer-pill {
  align-self: flex-start;
  color: var(--accent);
  font-weight: 600;
  border: 1px solid rgba(217, 119, 87, 0.5);
  border-radius: var(--radius-full);
  padding: 3px 11px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: clamp(44px, 5vw, 72px);
  padding-top: 24px;
  border-top: 1px solid var(--dark-line);
}

.footer-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.73rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(250, 249, 245, 0.5);
}

.footer-sep {
  color: rgba(250, 249, 245, 0.3);
}

.footer-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-nav a {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(250, 249, 245, 0.7);
  transition: color 0.16s ease;
}

.footer-nav a:hover {
  color: var(--accent);
}

.back-to-top {
  color: var(--cream) !important;
  font-weight: 600 !important;
}

/* ---------- Scroll Reveal Progressive Enhancement ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1), transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* ---------- Responsive Breakpoints ---------- */
@media (max-width: 1040px) {
  .card-grid, .provider-grid, .dark-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gallery {
    grid-template-columns: 1fr 1fr;
  }
  .gallery-item:last-child {
    grid-column: 1 / -1;
    max-width: 620px;
    margin: 0;
  }
  .tools-block {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
    row-gap: 40px;
  }
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  /* Stack as headline → standfirst → actions, the way it reads on desktop */
  .hero-main {
    display: contents;
  }
  .hero-badge { order: 1; }
  .hero-main h1 { order: 2; margin-bottom: 0; }
  .hero-side { order: 3; padding-bottom: 0; }
  .hero-main .cta-row { order: 4; }
  .lede {
    max-width: 56ch;
  }
}

@media (max-width: 860px) {
  .nav-toggle {
    display: inline-flex;
  }
  .header-pill {
    display: none;
  }

  /* Nav collapses into a panel under the header bar */
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px clamp(20px, 4vw, 56px) 16px;
    background: var(--bg);
    border-bottom: 1px solid var(--line-strong);
    box-shadow: 0 18px 32px -24px rgba(20, 20, 19, 0.5);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    font-size: 1rem;
    padding: 14px 4px;
    border-bottom: 1px solid var(--line);
  }

  .site-nav a:last-child {
    border-bottom: none;
  }

  .site-nav a::after {
    display: none;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }
  .stat {
    border-left: none;
    padding: 26px 0;
    border-top: 1px solid var(--line);
  }
  .stat:first-child, .stat:nth-child(2) {
    border-top: none;
  }
  .stat:nth-child(odd) {
    padding-right: 20px;
  }
  .stat:last-child {
    padding-right: 0;
  }
  .note-row {
    grid-template-columns: 1fr;
  }
  .install-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 18px;
  }
  .terminal {
    font-size: 0.74rem;
    padding: 20px 18px 22px;
  }
  .badge-optional {
    display: none;
  }
  .header-inner {
    height: 66px;
  }
  .card-grid, .provider-grid, .dark-grid, .gallery {
    grid-template-columns: 1fr;
  }
  .gallery-item:last-child {
    max-width: none;
  }
  .cta-row {
    flex-direction: column;
    align-items: stretch;
  }
  .cta-row .btn, .cta-row .copy-chip {
    justify-content: center;
  }
  .tool-item {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .window-title {
    display: none;
  }
  .footer-top {
    grid-template-columns: 1fr;
    row-gap: 34px;
  }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}