:root {
  --ink: #101827;
  --text: #223047;
  --muted: #5a677d;
  --paper: #f5f7fb;
  --panel: #ffffff;
  --line: #d9e0ea;
  --teal: #119c89;
  --coral: #e85a3f;
  --violet: #5b63c7;
  --gold: #d79a25;
  --green: #6b963f;
  --shadow: 0 14px 34px rgba(16, 24, 39, 0.11);
  --max: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 58px;
  padding: 0 32px;
  border-bottom: 1px solid rgba(217, 224, 234, 0.9);
  background: rgba(245, 247, 251, 0.9);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 800;
}

.brand-mark {
  width: 18px;
  height: 18px;
  border: 3px solid var(--ink);
  border-right-color: var(--coral);
  border-bottom-color: var(--teal);
  border-radius: 50%;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.site-nav a {
  padding: 8px 10px;
  border-radius: 6px;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  background: #e9eef7;
  color: var(--ink);
  outline: none;
}

.hero,
.section,
.site-footer {
  width: min(var(--max), calc(100% - 48px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(330px, 0.68fr) minmax(560px, 1.32fr);
  gap: 22px;
  align-items: start;
  padding: 28px 0 24px;
  scroll-margin-top: 80px;
}

.hero-copy {
  max-width: 980px;
  min-width: 0;
}

.intro-gallery .hero-copy {
  position: sticky;
  top: 78px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  line-height: 1.06;
}

h1 {
  max-width: 980px;
  font-size: 40px;
  font-weight: 900;
}

h2 {
  font-size: 28px;
  font-weight: 900;
}

h3 {
  font-size: 18px;
  font-weight: 850;
}

.hero-lede {
  max-width: 860px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.authors {
  margin: 14px 0 0;
  color: var(--ink);
  font-weight: 800;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.claim-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin: 18px 0 0;
  list-style: none;
}

.claim-list li {
  padding: 6px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.15;
}

.citation-card {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid #253044;
  border-radius: 8px;
  background: #0e1726;
  box-shadow: 0 9px 20px rgba(16, 24, 39, 0.08);
  scroll-margin-top: 80px;
}

.citation-card .eyebrow {
  margin-bottom: 8px;
  color: #91f0de;
}

.citation-card pre {
  overflow: auto;
  margin: 0;
}

.citation-card code {
  color: #e8f3ff;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 11px;
  line-height: 1.45;
  white-space: pre;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 850;
  box-shadow: 0 8px 22px rgba(16, 24, 39, 0.07);
}

.button.primary {
  border-color: var(--ink);
  background: var(--ink);
  color: #ffffff;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

.section {
  padding: 42px 0 0;
  scroll-margin-top: 80px;
}

.section-heading {
  max-width: 700px;
  margin-bottom: 20px;
}

.section-heading p:not(.eyebrow) {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.gallery-panel {
  min-width: 0;
}

.gallery-panel .section-heading {
  max-width: none;
  margin-bottom: 12px;
}

.gallery-panel .section-heading h2 {
  font-size: 24px;
}

.gallery-panel .section-heading p:not(.eyebrow) {
  font-size: 14px;
}

.edit-grid {
  display: grid;
  gap: 12px;
}

.edit-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.intro-gallery .edit-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.edit-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 9px 20px rgba(16, 24, 39, 0.06);
}

.edit-media {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
}

.edit-media img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.media-arrow {
  position: absolute;
  top: 50%;
  left: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 34px;
  border-radius: 6px;
  background: var(--ink);
  color: #ffffff;
  font-size: 15px;
  font-weight: 900;
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 18px rgba(16, 24, 39, 0.25);
}

.edit-card h3 {
  padding: 10px 11px 6px;
  font-size: 14px;
  line-height: 1.2;
}

.prompt-pair {
  display: grid;
  gap: 5px;
  padding: 0 11px 12px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.34;
}

.prompt-pair p {
  margin: 0;
}

.prompt-pair b {
  display: inline-block;
  min-width: 44px;
  color: var(--ink);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

mark {
  padding: 0 3px;
  border-radius: 4px;
  background: #fff0a8;
  color: #101827;
}

.section-ink {
  width: 100%;
  max-width: none;
  margin-top: 46px;
  padding: 42px max(24px, calc((100% - var(--max)) / 2)) 46px;
  background: var(--ink);
}

.section-ink .section-heading {
  width: min(var(--max), 100%);
}

.section-ink h2,
.section-ink h3 {
  color: #ffffff;
}

.section-ink .section-heading p:not(.eyebrow),
.section-ink .method-flow p {
  color: #c9d3e3;
}

.method-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: min(var(--max), 100%);
}

.method-flow article {
  min-height: 150px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
    #172236;
}

.method-flow span {
  display: inline-flex;
  margin-bottom: 22px;
  color: #91f0de;
  font-size: 13px;
  font-weight: 900;
}

.method-flow p {
  margin: 9px 0 0;
  font-size: 14px;
}

.demo-section {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(320px, 1fr);
  gap: 18px;
  align-items: end;
}

.demo-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 96px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 12px 28px rgba(16, 24, 39, 0.08);
}

.demo-card strong,
.demo-card span {
  display: block;
}

.demo-card strong {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.2;
}

.demo-card span {
  margin-top: 5px;
  color: var(--muted);
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 28px 0 40px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.site-footer span:first-child {
  color: var(--ink);
  font-weight: 900;
}

@media (max-width: 1040px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .intro-gallery .hero-copy {
    position: static;
  }

  h1 {
    font-size: 38px;
  }

  .edit-grid,
  .method-flow {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-section {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 20px;
  }

  .site-nav {
    flex-wrap: wrap;
  }

  .hero,
  .section,
  .site-footer {
    width: min(100% - 32px, var(--max));
  }

  .hero {
    padding: 26px 0 8px;
  }

  h1 {
    font-size: 38px;
  }

  h2 {
    font-size: 30px;
  }

  .hero-lede,
  .section-heading p:not(.eyebrow) {
    font-size: 16px;
  }

  .edit-grid,
  .intro-gallery .edit-grid,
  .method-flow,
  .demo-section {
    grid-template-columns: 1fr;
  }

  .section {
    padding-top: 48px;
  }

  .section-ink {
    margin-top: 52px;
    padding-top: 48px;
    padding-bottom: 52px;
  }

  .method-flow article {
    min-height: auto;
  }

  .method-flow span {
    margin-bottom: 24px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .demo-card {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 460px) {
  .button {
    width: 100%;
  }

  h1 {
    font-size: 32px;
  }

  h2 {
    font-size: 26px;
  }

}
