/* PromptTrain site. Colours come from lib/theme.dart (Forest, Fern, Sage, Field). */
:root {
  --bg: #F6F1E9;
  --surface: #FFFFFF;
  --ink: #1E3D2A;
  --muted: #4F6B5A;
  --primary: #217A4E;
  --primary-soft: #EDF2DC;
  --accent: #82C99E;
  --chip: #EAE7D8;
  --line: rgba(30, 61, 42, 0.15);
  --amber: #E0A72E;
  --radius: 14px;
  --max: 760px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
}

a { color: var(--primary); text-underline-offset: 2px; }
a:hover { color: var(--ink); }
a:focus-visible, .btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 12px; padding-bottom: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; color: var(--ink); text-decoration: none; }
.brand img { width: 32px; height: 32px; border-radius: 8px; display: block; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.nav a { color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 600; padding: 6px 0; }
.nav a:hover { color: var(--primary); text-decoration: underline; }
.nav a[aria-current="page"] { color: var(--primary); text-decoration: underline; }

/* Hero */
.hero { padding: 48px 0 32px; }
.hero h1 { font-size: 36px; line-height: 1.15; margin: 0 0 16px; letter-spacing: -0.5px; }
.hero p.lead { font-size: 19px; margin: 0 0 20px; color: var(--muted); }
.status {
  display: inline-block;
  background: var(--primary-soft);
  border: 1px solid var(--accent);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 700;
  font-size: 15px;
}

/* Sections */
main { padding-bottom: 24px; }
section { padding: 28px 0; }
h1 { font-size: 30px; line-height: 1.2; margin: 32px 0 8px; }
h2 { font-size: 24px; line-height: 1.25; margin: 0 0 12px; }
h3 { font-size: 18px; margin: 20px 0 6px; }
p { margin: 0 0 14px; }
ul, ol { margin: 0 0 14px; padding-left: 22px; }
li { margin-bottom: 6px; }

.grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 640px) {
  .grid.two { grid-template-columns: 1fr 1fr; }
  .hero h1 { font-size: 44px; }
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}
.card h3 { margin-top: 0; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card.plan { border: 2px solid var(--primary); background: var(--primary-soft); }
.price { font-size: 30px; font-weight: 800; margin: 4px 0 8px; }
.price span { font-size: 16px; font-weight: 600; color: var(--muted); }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 46px; margin-bottom: 16px; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--primary); color: #fff; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

.notice {
  background: var(--chip);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 15px;
  margin: 0 0 20px;
}
.draft { border-left: 4px solid var(--amber); }

.legal h2 { margin-top: 28px; font-size: 21px; }
.meta { color: var(--muted); font-size: 15px; }

table { width: 100%; border-collapse: collapse; margin: 0 0 16px; font-size: 15px; background: var(--surface); }
th, td { text-align: left; vertical-align: top; padding: 10px; border: 1px solid var(--line); }
th { background: var(--chip); }
.table-scroll { overflow-x: auto; }

.btn {
  display: inline-block; background: var(--primary); color: #fff;
  text-decoration: none; font-weight: 700; padding: 12px 20px; border-radius: 12px;
}
.btn:hover { background: var(--ink); color: #fff; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 24px; padding: 24px 0 40px; font-size: 15px; color: var(--muted); }
.site-footer .nav a { font-size: 15px; color: var(--ink); }
.site-footer p { margin: 12px 0 0; }

.btn { display: inline-block; background: var(--primary); color: #fff; padding: 12px 22px; border-radius: 999px; font-weight: 700; text-decoration: none; }
.btn:hover { background: var(--ink); }
.shots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.shots figure { margin: 0; text-align: center; }
.shots img { width: 100%; height: auto; border-radius: var(--radius); border: 1px solid var(--line); }
.shots figcaption { margin-top: 8px; font-size: 15px; color: var(--muted); }
@media (min-width: 720px) { .shots { grid-template-columns: repeat(4, 1fr); } }

.hero-video { display: block; width: 100%; max-width: 280px; height: auto; margin: 24px 0 0; border-radius: 20px; border: 1px solid var(--line); }
@media (min-width: 860px) {
  .hero { display: grid; grid-template-columns: 1fr 280px; column-gap: 48px; align-items: start; }
  .hero > * { grid-column: 1; }
  .hero > .hero-video { grid-column: 2; grid-row: 1 / span 8; margin-top: 0; }
}

/* Features pages */
.lead-text { font-size: 19px; color: var(--muted); margin: 0 0 20px; }
.feature-shot { margin: 0 0 20px; text-align: center; }
.feature-shot img { max-width: 100%; height: auto; border-radius: var(--radius); border: 1px solid var(--line); }
.card-title { font-size: 18px; margin: 0 0 8px; }
.feature-list { list-style: none; padding: 0; }
.feature-list li { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin-bottom: 8px; }
caption { text-align: left; padding-bottom: 6px; }

h2[id]{scroll-margin-top:5rem}

/* Features search */
.feature-search[hidden], .feature-suggest[hidden], .feature-list li[hidden], main section[hidden], #feature-empty[hidden] { display: none; }
.feature-search { margin: 8px 0 28px; }
.feature-search-label { display: block; font-weight: 700; font-size: 20px; margin: 0 0 10px; }
.feature-search-box { position: relative; }
.feature-search-box input {
  width: 100%;
  box-sizing: border-box;
  min-height: 60px;
  font: inherit;
  font-size: 20px;
  color: var(--ink);
  background: var(--surface);
  border: 2px solid var(--line);
  border-radius: 14px;
  padding: 16px 20px;
}
.feature-search-box input:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.feature-suggest {
  position: absolute;
  left: 0; right: 0; top: calc(100% + 4px);
  z-index: 5;
  list-style: none;
  margin: 0; padding: 4px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 6px 18px rgba(30, 61, 42, 0.12);
}
.feature-suggest li { padding: 14px 16px; font-size: 18px; border-radius: 10px; cursor: pointer; }
.feature-suggest li:hover, .feature-suggest li[aria-selected="true"] { background: var(--primary-soft); }
