:root {
  --page: #111112;
  --page-soft: #171718;
  --card: #202020;
  --card-soft: #262626;
  --line: #2f2f31;
  --line-soft: #242426;
  --line-hover: #404044;
  --text: #f4f4f4;
  --text-soft: #d7d7d7;
  --muted: #a8a8a8;
  --muted-dark: #757575;
  --blue: #4078ff;
  --blue-hover: #3268ee;
  --green: #4fbd72;
  --shadow-soft: 0 24px 70px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--page);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
  scroll-behavior: auto;
  -webkit-font-smoothing: antialiased;
}

body {
  min-width: 320px;
  margin: 0;
}

body.dark-site {
  min-height: 100vh;
  background: var(--page);
}

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

button,
input {
  font: inherit;
}

p,
h1,
h2,
h3,
ul,
ol,
figure {
  margin: 0;
}

img {
  display: block;
}

.david-header,
.david-footer,
main {
  width: min(100% - 56px, 1860px);
  margin: 0 auto;
}

.david-header {
  min-height: 92px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 44px;
  align-items: center;
}

.brand-mark {
  display: inline-flex;
  width: fit-content;
  align-items: center;
}

.brand-mark img {
  border-radius: 8px;
}

.david-nav,
.david-actions,
.david-footer nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.david-nav {
  color: var(--text-soft);
  font-size: 17px;
  font-weight: 520;
}

.david-nav a,
.david-actions a:not(.button),
.david-footer a:not(.button) {
  color: var(--text-soft);
}

.david-nav a:hover,
.david-actions a:hover:not(.button),
.david-footer a:hover:not(.button) {
  color: var(--text);
}

.david-nav a,
.david-actions a:not(.button),
.david-footer a:not(.button) {
  transition: color 160ms ease;
}

.david-actions {
  justify-content: flex-end;
  gap: 14px;
  font-size: 16px;
  font-weight: 520;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 20px;
  color: var(--text);
  font-weight: 560;
  white-space: nowrap;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease,
    color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button:active {
  transform: translateY(0);
}

.button:focus-visible,
.david-nav a:focus-visible,
.david-actions a:focus-visible,
.david-footer a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

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

.button.blue:hover {
  background: var(--blue-hover);
  box-shadow: 0 14px 36px rgba(64, 120, 255, 0.28);
}

.button.ghost,
.button.dark {
  background: #1e1e1f;
}

.button.ghost:hover,
.button.dark:hover {
  border-color: var(--line-hover);
  background: var(--card-soft);
}

.button.dark {
  border-color: #323234;
  background: #2a2a2b;
  color: var(--text-soft);
}

.david-hero {
  min-height: 900px;
  display: grid;
  align-content: start;
  padding: 154px 0 0;
}

.hero-copy {
  max-width: 1040px;
  margin: 0 auto;
  text-align: center;
}

.hero-kicker,
.section-kicker {
  margin-bottom: 18px;
  color: var(--text-soft);
  font-size: 20px;
  line-height: 1.2;
  font-weight: 520;
}

h1 {
  color: var(--text);
  font-size: 60px;
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: 0;
}

h1 span {
  color: var(--blue);
}

.hero-subtitle {
  max-width: 760px;
  margin: 26px auto 0;
  color: var(--text-soft);
  font-size: 19px;
  line-height: 1.46;
  font-weight: 500;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 44px;
}

.hero-button {
  min-width: 154px;
  min-height: 50px;
  font-size: 17px;
}

.hero-cards {
  width: min(100%, 1220px);
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.9fr);
  gap: 22px;
  margin: 128px auto 0;
}

.hero-cards article,
.feature-cards article,
.trust-list article {
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: var(--card);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}

.hero-cards article:hover,
.feature-cards article:hover,
.trust-list article:hover,
.workflow-grid article:hover,
.prompt-list p:hover {
  transform: translateY(-4px);
  border-color: var(--line-hover);
  background: var(--card-soft);
  box-shadow: var(--shadow-soft);
}

.hero-cards article {
  min-height: 310px;
  display: grid;
  align-content: center;
  gap: 24px;
  padding: 54px;
}

.hero-cards h2,
.dark-section h2,
.pricing-cta h2 {
  color: var(--text);
  font-size: 38px;
  line-height: 1.15;
  font-weight: 650;
  letter-spacing: 0;
}

.hero-cards p {
  max-width: 610px;
  color: var(--text-soft);
  font-size: 18px;
  line-height: 1.45;
}

.hero-cards span {
  width: fit-content;
  border: 1px solid #171717;
  border-radius: 7px;
  background: #141414;
  padding: 10px 14px;
  color: var(--text-soft);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 14px;
}

.proof-strip {
  min-height: 88px;
  display: grid;
  grid-template-columns: 1.2fr repeat(5, 1fr);
  align-items: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.proof-strip span,
.proof-strip strong {
  min-height: 88px;
  display: grid;
  place-items: center;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-size: 17px;
}

.proof-strip strong {
  color: var(--text-soft);
  font-size: 18px;
  font-weight: 600;
}

.proof-strip strong:last-child {
  border-right: 0;
}

.dark-section {
  padding: 108px 0;
  border-bottom: 1px solid var(--line-soft);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.84fr) minmax(0, 1.16fr);
  gap: 72px;
  align-items: start;
}

.section-heading {
  max-width: 860px;
  margin-bottom: 42px;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.workflow-grid article {
  min-height: 270px;
  display: grid;
  align-content: start;
  gap: 16px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: var(--card);
  padding: 24px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}

.workflow-grid span,
.trust-list span {
  width: fit-content;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

.prompt-section {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 72px;
  align-items: start;
}

.prompt-list {
  display: grid;
  gap: 12px;
}

.prompt-list p {
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: var(--card);
  padding: 20px 22px;
  color: var(--text-soft);
  font-size: 18px;
  line-height: 1.45;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}

.trust-list {
  display: grid;
  gap: 16px;
}

.trust-list article {
  display: grid;
  gap: 10px;
  padding: 24px;
}

.trust-list h3,
.feature-cards h3,
.workflow-grid h3 {
  color: var(--text);
  font-size: 22px;
  line-height: 1.2;
}

.trust-list p,
.feature-cards p,
.workflow-grid p {
  color: var(--text-soft);
  font-size: 16px;
  line-height: 1.5;
}

.feature-section > h2,
.pricing-cta h2 {
  max-width: 970px;
}

.feature-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 42px;
}

.feature-cards article {
  min-height: 235px;
  display: grid;
  align-content: end;
  gap: 16px;
  padding: 24px;
}

.pricing-cta {
  display: grid;
  justify-items: center;
  text-align: center;
}

.pricing-cta .section-kicker {
  margin-bottom: 20px;
}

.david-footer {
  min-height: 120px;
  display: grid;
  grid-template-columns: auto 1fr auto auto auto;
  gap: 28px;
  align-items: center;
}

.david-footer nav {
  margin-left: 70px;
  color: var(--text-soft);
  font-size: 16px;
}

code {
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--card);
  padding: 2px 6px;
  color: var(--text);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
}

.simple-page {
  min-height: 100vh;
  display: grid;
  align-content: center;
  gap: 28px;
  width: min(100% - 40px, 760px);
  margin: 0 auto;
}

.simple-card {
  max-width: 680px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  padding: 34px;
}

.simple-card h1 {
  font-size: 56px;
}

.simple-card p:not(.eyebrow) {
  margin: 22px 0 28px;
  color: var(--text-soft);
  font-size: 18px;
  line-height: 1.6;
}

.auth-page {
  width: min(100% - 40px, 680px);
  min-height: 100vh;
  display: grid;
  align-content: center;
  gap: 22px;
  margin: 0 auto;
}

.auth-mark {
  width: 42px;
  height: 42px;
}

.auth-copy {
  color: var(--text-soft);
  font-size: 18px;
  line-height: 1.6;
}

.auth-copy a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  margin-top: 18px;
  padding: 0 16px;
  color: var(--text);
  font-weight: 700;
}

.code {
  width: fit-content;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  padding: 14px 18px;
  color: var(--text);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 24px;
  font-weight: 800;
}

.admin-login {
  display: grid;
  max-width: 420px;
  gap: 12px;
}

.admin-login label {
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
}

.admin-login input,
.admin-login button {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  color: var(--text);
  padding: 0 12px;
}

.admin-login button {
  border-color: var(--blue);
  border-radius: 999px;
  background: var(--blue);
  color: #ffffff;
  font-weight: 700;
}

.admin-panel {
  display: grid;
  gap: 18px;
  overflow-x: auto;
}

.admin-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-summary div,
.admin-card,
.admin-panel table {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
}

.admin-summary div {
  display: grid;
  gap: 8px;
  padding: 18px;
}

.admin-summary strong {
  font-size: 28px;
}

.admin-summary span,
.admin-panel small {
  color: var(--muted);
}

.admin-panel table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.admin-panel th,
.admin-panel td {
  border-bottom: 1px solid var(--line);
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

.admin-panel th {
  background: #181819;
}

.admin-workspaces {
  display: grid;
  gap: 16px;
}

.admin-card {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.admin-card h2 {
  font-size: 28px;
}

.admin-card h3 {
  margin-bottom: 10px;
  font-size: 15px;
}

.admin-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-checklist span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 10px;
  color: var(--muted);
  font-size: 13px;
}

.admin-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.admin-columns ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 18px;
}

.overview-hero {
  min-height: 540px;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 58px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.overview-copy,
.overview-grid p {
  color: var(--text-soft);
  font-size: 19px;
  line-height: 1.6;
}

.section {
  padding: 90px 0;
  border-bottom: 1px solid var(--line);
}

.flow-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.flow-strip div {
  min-height: 210px;
  display: grid;
  align-content: start;
  gap: 16px;
  border-right: 1px solid var(--line);
  background: var(--card);
  padding: 22px;
}

.flow-strip div:last-child {
  border-right: 0;
}

.flow-strip span,
.session-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.flow-strip strong,
.session-row strong {
  font-size: 18px;
}

.flow-strip p,
.session-steps {
  color: var(--text-soft);
  line-height: 1.5;
}

.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(340px, 1.1fr);
  gap: 54px;
  align-items: start;
}

.overview-grid p {
  margin-top: 22px;
}

.session-panel {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
}

.panel-top {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding: 0 18px;
  color: var(--muted);
  font-size: 13px;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--text);
}

.session-row {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  padding: 0 18px;
}

.session-row strong {
  overflow-wrap: anywhere;
  text-align: right;
}

.session-steps {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 22px 22px 22px 42px;
}

@media (max-width: 1280px) {
  .david-header,
  .david-footer,
  main {
    width: min(100% - 36px, 1860px);
  }

  .david-header {
    grid-template-columns: auto 1fr;
    row-gap: 18px;
  }

  .david-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }

  h1 {
    font-size: 52px;
  }

  .workflow-grid,
  .feature-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .prompt-section,
  .split-section {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .david-header,
  .david-footer,
  main {
    width: min(100% - 28px, 1860px);
  }

  .david-header {
    min-height: auto;
    grid-template-columns: 1fr;
    justify-items: center;
    padding: 22px 0;
  }

  .david-nav,
  .david-actions,
  .david-footer nav {
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 16px;
  }

  .david-actions {
    justify-content: center;
  }

  .david-hero {
    min-height: auto;
    padding-top: 78px;
  }

  h1 {
    font-size: 38px;
    line-height: 1.08;
  }

  .hero-kicker,
  .section-kicker {
    font-size: 20px;
  }

  .hero-subtitle {
    font-size: 18px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    margin-top: 34px;
  }

  .hero-actions .button {
    width: 100%;
  }

  .hero-cards,
  .split-section,
  .workflow-grid,
  .prompt-section,
  .feature-cards,
  .proof-strip,
  .overview-grid,
  .overview-hero,
  .flow-strip,
  .admin-summary,
  .admin-columns {
    grid-template-columns: 1fr;
  }

  .hero-cards {
    margin-top: 74px;
  }

  .hero-cards article {
    min-height: auto;
    padding: 28px;
  }

  .hero-cards h2,
  .dark-section h2,
  .pricing-cta h2 {
    font-size: 32px;
  }

  .proof-strip span,
  .proof-strip strong {
    min-height: 58px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .proof-strip strong:last-child {
    border-bottom: 0;
  }

  .dark-section,
  .pricing-cta {
    padding: 72px 0;
  }

  .feature-cards article {
    min-height: auto;
  }

  .workflow-grid article {
    min-height: auto;
  }

  .prompt-section,
  .split-section {
    gap: 34px;
  }

  .david-footer {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 18px;
    padding: 30px 0;
  }

  .david-footer nav {
    margin-left: 0;
  }

  .simple-card h1 {
    font-size: 42px;
  }

  .section {
    padding: 64px 0;
  }
}

@media (max-width: 520px) {
  .david-nav,
  .david-actions,
  .david-footer nav {
    gap: 10px;
    font-size: 15px;
  }

  .button {
    min-height: 42px;
    padding: 0 16px;
  }

  h1 {
    font-size: 34px;
  }

  .hero-cards h2,
  .dark-section h2,
  .pricing-cta h2 {
    font-size: 28px;
  }

  .prompt-list p {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
