/* The public site.
 *
 * Its own stylesheet rather than the workspace's: the two have different jobs
 * and one of them is read by strangers on phones. Sharing would mean every
 * change to a dashboard table risking the front page, and every widening here
 * reaching pages behind a login.
 *
 * No font *host*. The policy is `default-src 'self'` and a marketing page is
 * exactly where one gets added without anyone deciding to widen it -- so the
 * two faces below are served from our own origin, byte for byte the files
 * Google would have sent. The policy is untouched, and a blocked webfont fails
 * silently (the page renders in the fallback and nothing reports it), which is
 * the other half of why these are not loaded from a CDN.
 *
 * Declared here as well as in `home.css` rather than shared. Every page loads
 * exactly one stylesheet -- that is this sheet's own rule, a few lines down --
 * so there is nowhere to share them from. Same filenames, so a reader crossing
 * from the front page to `/register` re-uses the cached files. */

/* The public palette: sage page, teal accent, ember rule. Taken with the
 * typography from the reference design, and shared with `home.css` so the
 * front page, pricing, register and login are one surface.
 *
 * **It is not the workspace's.** This sheet went navy once, precisely to close
 * the seam between marketing and product, and that seam is now open again by
 * decision rather than by accident: `workspace.css` and `app.css` are still
 * navy with a gold rule. Somebody signing up changes scheme once, at `/login`.
 * That is one change rather than the two the navy re-map was fixing, and it is
 * a real cost -- nothing in this product should be described as "one identity,
 * front to back" until the workspace follows.
 *
 * **The token names lie and are kept anyway.** `--navy` holds a teal; `--gold`
 * holds a readable bronze. Renaming them means touching every rule in the
 * sheet and every sheet that copied them, for no change a reader can see -- so
 * the names stay and this paragraph is the correction.
 *
 * `--gold` and `--ember` are two colours with two jobs, the same split
 * `home.css` documents at length: `--gold` is for text (#A15C07 reaches 5.1:1
 * on white, where the old #E9A825 managed 2.1:1 and made the brand line under
 * the wordmark effectively unreadable), `--ember` is for the 3px rule, which
 * carries no text and wants the warm gold. */

:root {
  --navy: #0f766e;
  --navy-deep: #0b5b55;
  --gold: #a15c07;
  --ember: #e8a33d;
  --ink: #102b29;
  --grey-text: #52625f;
  --grey-line: #dce6e2;
  --grey-line-2: #c6dad4;
  --page: #f5f7f6;
  --soft: #eaf2ef;
  --radius: 14px;

  --display: 'Space Grotesk', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --sans: 'Open Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

/* Variable faces: `400 800` and `500 700` are weight ranges, so every weight
   this sheet asks for comes out of these four files. Relative URLs, because
   `asset()` cannot be called from inside a stylesheet. */
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(open-sans-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(open-sans-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(space-grotesk-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(space-grotesk-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

* { box-sizing: border-box; }

/* Sage page, white paper on top of it -- the reference's own arrangement, and
   the reason the cards read as cards without needing a shadow. This inverts
   what was here: the body was white and `.band.alt` was the tint. The
   alternation is the same alternation, turned over, so no band lost its
   neighbour. */
body.public {
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
  -webkit-font-smoothing: antialiased;
}

/* Space Grotesk on anything that is a heading or a number somebody reads as
   one. The face stops at 700, so nothing below may ask for 800 -- the three
   rules that did were lowered to 700 rather than left to synthesise a fake
   bold, which at 32px on a price is plainly visible. */
.brand-name,
.hero h1,
.band > h2,
.steps h3,
.grid h3,
.tier h2,
.tier-amount,
.notice h2 { font-family: var(--display); }

a { color: inherit; }

/* --- The bar ------------------------------------------------------------- */

.top {
  align-items: center;
  border-bottom: 1px solid var(--grey-line);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  padding: 18px 24px;
}
.brand { display: flex; flex-direction: column; text-decoration: none; }
.brand-name { font-size: 20px; font-weight: 700; letter-spacing: .14em; }
.brand-line { color: var(--gold); font-size: 11.5px; font-weight: 600; }

.top-nav { align-items: center; display: flex; flex-wrap: wrap; gap: 22px; }
.top-nav a { color: var(--grey-text); font-size: 14px; text-decoration: none; }
.top-nav a:hover { color: var(--ink); }

.button {
  background: #fff;
  border: 1px solid var(--grey-line);
  border-radius: 8px;
  color: var(--ink) !important;
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  padding: 9px 18px;
  text-decoration: none;
}
.button:hover { background: var(--soft); border-color: var(--grey-line-2); }
.button.primary {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff !important;
}
.button.primary:hover { background: var(--navy-deep); border-color: var(--navy-deep); }

/* --- The first screen ---------------------------------------------------- */

.hero { margin: 0 auto; max-width: 46rem; padding: 72px 24px 56px; text-align: center; }
.hero h1 {
  font-size: clamp(30px, 5vw, 46px);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.15;
  margin: 0 0 18px;
}
.lede { color: var(--grey-text); font-size: 17px; margin: 0 auto; max-width: 42rem; }
.cta { align-items: center; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin: 30px 0 0; }
.cta-note { color: var(--grey-text); font-size: 13.5px; }

/* --- The bands ----------------------------------------------------------- */

.band { padding: 60px 24px; }
.band.alt { background: #fff; border-block: 1px solid var(--grey-line); }
.band > h2 {
  font-size: clamp(22px, 3vw, 28px);
  letter-spacing: -.01em;
  margin: 0 auto 34px;
  max-width: 62rem;
  text-align: center;
}

/* Numbered, because they happen in this order and the order is the product. */
.steps { counter-reset: step; list-style: none; margin: 0 auto; max-width: 54rem; padding: 0; }
.steps li {
  border-top: 1px solid var(--grey-line);
  counter-increment: step;
  display: grid;
  gap: 4px 20px;
  grid-template-columns: 40px 1fr;
  padding: 24px 0;
}
.steps li::before {
  align-self: start;
  background: var(--navy);
  border-radius: 999px;
  color: #fff;
  content: counter(step);
  font-size: 13px;
  font-weight: 700;
  height: 30px;
  line-height: 30px;
  text-align: center;
  width: 30px;
}
.steps h3 { font-size: 17px; margin: 2px 0 0; }
.steps p { color: var(--grey-text); grid-column: 2; margin: 6px 0 0; }

.grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  margin: 0 auto;
  max-width: 66rem;
}
.grid article {
  background: #fff;
  border: 1px solid var(--grey-line);
  border-radius: var(--radius);
  padding: 22px 22px 24px;
}
.grid h3 { font-size: 16px; margin: 0 0 8px; }
.grid p { color: var(--grey-text); font-size: 14.5px; margin: 0; }

.close { text-align: center; }
.close .lede { margin-bottom: 6px; }

.hero.narrow { padding-bottom: 24px; }

/* --- The plans -----------------------------------------------------------
   Rendered from the catalogue the allowance enforces, so the number on the
   card and the number an agency hits are the same number. */
.tiers {
  align-items: start;
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  list-style: none;
  margin: 0 auto;
  max-width: 62rem;
  padding: 0;
}
.tier {
  background: #fff;
  border: 1px solid var(--grey-line);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 26px 24px 24px;
}
/* One card carries the eye. Not "most popular", which nothing here can
   measure and which is the first claim on a pricing page people stop
   believing. */
/* The same 3px ember rule `home.css` puts on its recommended plan, so the one
   card carrying the eye is marked the same way on both pricing surfaces. */
.tier-lead {
  border-color: var(--grey-line);
  border-top: 3px solid var(--ember);
  box-shadow: 0 8px 24px rgba(8, 47, 43, .07);
  /* 26px less the two extra pixels the 3px rule adds, so this card's heading
     and price line up with the two beside it rather than sitting under them. */
  padding-top: 24px;
}
.tier h2 { font-size: 17px; margin: 0; }
.tier-price { margin: 8px 0 0; }
.tier-amount { font-size: 32px; font-weight: 700; letter-spacing: -.02em; }
.tier-per { color: var(--grey-text); font-size: 13px; }
.tier-allow { color: var(--ink); font-size: 14px; font-weight: 600; margin: 2px 0 0; }
.tier-blurb { color: var(--grey-text); font-size: 14px; margin: 10px 0 0; }
.tier-features { color: var(--grey-text); font-size: 14px; margin: 14px 0 0; padding-left: 18px; }
.tier-features li { margin-bottom: 6px; }
.tier-cta { margin: auto 0 0; padding-top: 18px; }
.tier-cta .button { display: block; text-align: center; }

/* --- The foot ------------------------------------------------------------ */

.foot {
  align-items: center;
  border-top: 1px solid var(--grey-line);
  color: var(--grey-text);
  display: flex;
  flex-wrap: wrap;
  font-size: 13.5px;
  gap: 12px;
  justify-content: space-between;
  padding: 26px 24px;
}
.foot p { margin: 0; }
.foot-links a { color: var(--ink); }

/* Read on a phone more often than not, and the first screen is the whole
   impression: the hero must not arrive as a wall. */
@media (max-width: 40rem) {
  .hero { padding: 48px 20px 40px; }
  .band { padding: 44px 20px; }
  .steps li { grid-template-columns: 30px 1fr; gap: 4px 14px; }
  .cta { justify-content: flex-start; }
  .hero, .close { text-align: left; }
  .lede { margin-left: 0; }
}

/* --- Registration -------------------------------------------------------
 *
 * A single column at a readable width. A signup form laid out in two columns
 * reads as shorter and is not: the eye has to decide where to go next at every
 * row, and the fields here are not pairs that belong side by side. */

.signup {
  margin: 0 auto;
  max-width: 30rem;
  text-align: left;
}

.signup label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.signup input[type="text"],
.signup input[type="email"],
.signup input[type="password"] {
  background: #fff;
  border: 1px solid var(--grey-line-2);
  border-radius: 8px;
  color: var(--ink);
  font-family: inherit;
  font-size: 1rem;
  padding: 11px 12px;
  width: 100%;
}

.signup input:focus-visible {
  border-color: var(--navy);
  outline: 2px solid rgba(15, 118, 110, 0.22);
  outline-offset: 1px;
}

/* The address field and its fixed domain read as one control, because that is
   what they are: nobody is choosing the part after the dot. */
.field-suffixed {
  align-items: stretch;
  display: flex;
}

.field-suffixed input {
  border-bottom-right-radius: 0 !important;
  border-right: 0 !important;
  border-top-right-radius: 0 !important;
  min-width: 0;
}

.suffix {
  align-items: center;
  background: var(--soft);
  border: 1px solid var(--grey-line-2);
  border-left: 0;
  border-radius: 0 8px 8px 0;
  color: var(--grey-text);
  display: flex;
  font-size: 0.95rem;
  padding: 0 12px;
  white-space: nowrap;
}

/* Under the field it explains, not above: it is read after somebody has looked
   at the input and wondered, which is the moment it is useful. */
.hint {
  color: var(--grey-text);
  font-size: 0.85rem;
  line-height: 1.5;
  margin: 6px 0 20px;
}

.signup .button { margin-top: 4px; width: 100%; }

/* Above the fields. The reason is read before anything is retyped. */
.form-error {
  background: #fdf1ef;
  border: 1px solid #f3ccc6;
  border-radius: 8px;
  color: #8c1d13;
  font-size: 0.9rem;
  margin: 0 0 1.5rem;
  padding: 0.75rem 0.9rem;
}

/* Registration closed, which is a statement rather than a failure -- so it is
   not styled as an error. */
.notice {
  background: #fff;
  border: 1px solid var(--grey-line);
  border-radius: var(--radius);
  margin: 0 auto;
  max-width: 34rem;
  padding: 28px 30px;
}

.notice h2 { font-size: 1.15rem; margin: 0 0 10px; }
.notice p { color: var(--grey-text); line-height: 1.65; margin: 0; }

@media (max-width: 600px) {
  .suffix { font-size: 0.85rem; padding: 0 8px; }
}

/* The palette is light; somebody reading at night gets the same page rather
   than a half-inverted one. Stated explicitly so the browser does not guess. */
@media (prefers-color-scheme: dark) {
  body.public { background: var(--page); color: var(--ink); }
}
