/* Chalkline's own look.

   Its own site, so its own stylesheet -- not shared with the delivery site.
   Sharing one would mean a change made for a contractor reading a sales page
   quietly altering the page a client collects her bespoke app from.

   Dark, because it is read on a phone in a van as often as at a desk, and a
   white page in bright sun is worse than a dark one at night. One accent
   colour, used only for the thing to press. */

:root {
  --bg:        #0e1116;
  --surface:   #161b22;
  --surface-2: #1d232c;
  --line:      #2a323d;
  --ink:       #e8edf4;
  --dim:       #96a1b0;
  --accent:    #35c46b;   /* money green, and it means "press this" */
  --accent-2:  #2aa85a;
  --warn:      #e0a03a;
  --bad:       #e05a5a;
  --radius:    14px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0 20px 70px;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* --- header ------------------------------------------------------------ */
.top {
  max-width: 860px;
  margin: 0 auto;
  padding: 22px 0 8px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  width: fit-content;       /* a flex <a> is a block -- without this the link
                               stretches the width of the page and a click
                               well clear of the logo navigates away */
}
.logo {
  font-weight: 800;
  letter-spacing: 1.5px;
  font-size: 19px;
  padding: 4px 9px;
  border: 2px solid var(--ink);
  border-radius: 8px;
}
.prod { font-weight: 600; color: var(--dim); }
.top-link {
  margin-left: auto;
  color: var(--dim);
  text-decoration: none;
  font-size: 14px;
}
.top-link:hover { color: var(--ink); }

/* --- hero -------------------------------------------------------------- */
.hero {
  max-width: 860px;
  margin: 34px auto 12px;
}
.hero h1 {
  margin: 0 0 14px;
  font-size: 40px;
  line-height: 1.12;
  letter-spacing: -0.5px;
}
.hero .sub {
  margin: 0;
  font-size: 18px;
  color: var(--dim);
  max-width: 62ch;
}
.hero.ready h1 { font-size: 34px; }

.hero-cta {
  margin-top: 28px;
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 22px;
}
.price { display: flex; align-items: baseline; gap: 8px; }
.amount { font-size: 40px; font-weight: 800; letter-spacing: -1px; }
.per { color: var(--dim); }
.hero-cta .lead { margin: 0; color: var(--dim); }
.go {
  margin-left: auto;
  background: var(--accent);
  color: #07220f;
  font-weight: 700;
  text-decoration: none;
  padding: 13px 22px;
  border-radius: 10px;
  white-space: nowrap;
}
.go:hover { background: var(--accent-2); }

/* --- the three hooks --------------------------------------------------- */
.hooks {
  max-width: 860px;
  margin: 34px auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}
.hook {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.hook h2 { margin: 0 0 8px; font-size: 17px; line-height: 1.3; }
.hook p { margin: 0; color: var(--dim); font-size: 15px; }

/* --- panels ------------------------------------------------------------ */
.panel {
  max-width: 860px;
  margin: 18px auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.panel h2 { margin: 0 0 12px; font-size: 20px; }
.lead { margin: 0 0 12px; color: var(--dim); }
.note { margin: 10px 0 0; color: var(--dim); font-size: 14px; }
.note.warn { color: var(--warn); }
.err {
  margin: 0 0 14px;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(224, 90, 90, .12);
  border: 1px solid rgba(224, 90, 90, .4);
  color: #ffbdbd;
}
.method { margin: 14px 0 0; color: var(--dim); font-size: 14px; }

.gets { margin: 0; padding: 0; list-style: none; }
.gets li {
  padding: 7px 0 7px 28px;
  position: relative;
  border-bottom: 1px solid var(--line);
}
.gets li:last-child { border-bottom: 0; }
.gets li::before {
  content: "✓";
  position: absolute;
  left: 4px;
  color: var(--accent);
  font-weight: 700;
}

.privacy { border-color: rgba(53, 196, 107, .35); }

.qa { padding: 12px 0; border-bottom: 1px solid var(--line); }
.qa:last-child { border-bottom: 0; }
.q { margin: 0 0 4px; font-weight: 650; }
.a { margin: 0; color: var(--dim); }

/* --- forms ------------------------------------------------------------- */
.signup { display: grid; gap: 14px; max-width: 460px; }
.signup label {
  display: grid;
  gap: 6px;
  font-size: 14px;
  color: var(--dim);
}
.opt { color: var(--line); }
input[type=text], input[type=email], input[type=password], select {
  width: 100%;
  padding: 12px 14px;
  font-size: 16px;            /* 16 or iOS zooms the page on focus */
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
}
input:focus, select:focus {
  outline: none;
  border-color: var(--accent);
}
button {
  padding: 13px 22px;
  font-size: 16px;
  font-weight: 700;
  background: var(--accent);
  color: #07220f;
  border: 0;
  border-radius: 10px;
  cursor: pointer;
}
button:hover { background: var(--accent-2); }
button:disabled {
  background: var(--surface-2);
  color: var(--dim);
  cursor: not-allowed;
}

.code-form { display: flex; gap: 10px; flex-wrap: wrap; }
.code-form input {
  flex: 1 1 200px;
  font-family: ui-monospace, Consolas, monospace;
  letter-spacing: 3px;
  text-transform: uppercase;
}

/* --- the download page ------------------------------------------------- */
.grab { text-align: center; }
.download {
  display: inline-block;
  background: var(--accent);
  color: #07220f;
  font-size: 22px;
  font-weight: 800;
  text-decoration: none;
  padding: 20px 46px;
  border-radius: 14px;
}
.download:hover { background: var(--accent-2); }

.steps { margin: 0; padding-left: 22px; }
.steps li { padding: 5px 0; }
.steps .orsplit {
  list-style: none;
  margin-left: -22px;
  color: var(--dim);
  padding: 14px 0 6px;
}

.code-big {
  margin: 4px 0;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 31px;
  font-weight: 700;
  letter-spacing: 4px;
  color: var(--accent);
}

/* --- admin ------------------------------------------------------------- */
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th, .tbl td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.tbl th { color: var(--dim); font-weight: 600; }
.dim { color: var(--dim); }
.inline { display: flex; gap: 6px; }
.inline button { padding: 6px 12px; font-size: 13px; }
.inline select { width: auto; padding: 6px 10px; font-size: 13px; }
.pill {
  padding: 2px 9px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 700;
}
.pill.trial   { background: rgba(224, 160, 58, .2);  color: var(--warn); }
.pill.paying  { background: rgba(53, 196, 107, .2);  color: var(--accent); }
.pill.lapsed  { background: rgba(224, 90, 90, .2);   color: #ff9a9a; }
.pill.stopped { background: var(--surface-2);        color: var(--dim); }

.foot {
  max-width: 860px;
  margin: 40px auto 0;
  color: var(--line);
  font-size: 13px;
}

@media (max-width: 620px) {
  .hero h1 { font-size: 30px; }
  .go { margin-left: 0; width: 100%; text-align: center; }
}

/* ---- the picker: what goes in your copy ------------------------------- */
.trade-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin-bottom: 18px;
}
.trade {
  display: block;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface-2);
  cursor: pointer;
  font-size: 14px;
}
.trade input { display: none; }
.trade:hover { border-color: var(--dim); }
.trade.on { border-color: var(--accent); color: var(--accent); }

.one-field { display: block; max-width: 440px; font-size: 14px; color: var(--dim); }
.one-field input { margin-top: 6px; }
.one-field .hint { display: block; margin-top: 5px; font-size: 12.5px; }
.opt { color: var(--line); }

.mod-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
}
.mod {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas: "icon name" "blurb blurb";
  gap: 2px 9px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-2);
  cursor: pointer;
}
.mod input { display: none; }
.mod:hover { border-color: var(--dim); }
.mod.on { border-color: var(--accent); background: rgba(53, 196, 107, .08); }
.mod.core { cursor: default; opacity: .7; }
.mod-icon { grid-area: icon; font-size: 17px; }
.mod-name { grid-area: name; font-weight: 700; font-size: 14px; }
.mod-blurb { grid-area: blurb; font-size: 12.5px; color: var(--dim);
  line-height: 1.45; }
.mod-always {
  grid-area: blurb;
  font-size: 11px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 700;
}

.go-panel { text-align: center; }
/* `button` is styled as a solid green block; these have to read as links */
.linky {
  background: none;
  border: 0;
  padding: 0;
  color: var(--dim);
  font-size: 14px;
  text-decoration: underline;
  cursor: pointer;
}
.linky:hover { color: var(--accent); background: none; }
.code-inline {
  font-family: ui-monospace, Consolas, monospace;
  letter-spacing: 2px;
  color: var(--accent);
}
