/* ==========================================================================
   Fullroom — marketing site
   Implements brand/FULLROOM-BRAND.md v1.0 (Floorplate).
   Do not invent values that are not in that document.

   Two rules that override convenience:
     1. One yellow object per viewport.  (see .accent audit note, §3.4)
     2. Never ship a fake dashboard.     (see .shot, §7)
   ========================================================================== */

@import url("../brand/tokens.css");
@import url("./visuals.css");

/* --------------------------------------------------------------------------
   1. Reset
   -------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--fr-bg-base);
  color: var(--fr-text);
  font-family: var(--fr-font-body);
  font-size: 16px;
  line-height: 26px;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-variant-numeric: tabular-nums;
  transition: background-color 120ms linear, color 120ms linear;
}

img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button { font: inherit; color: inherit; }

::selection { background: var(--fr-accent); color: var(--fr-accent-on); }

/* --------------------------------------------------------------------------
   2. Type scale — §4.1. Tighten as it grows; body takes no tracking.
   -------------------------------------------------------------------------- */

.display-xl, .display-l, .display-m, .stat-xl {
  font-family: var(--fr-font-display);
  font-weight: 400;           /* Archivo Black IS the weight */
  text-wrap: balance;
}

.display-xl { font-size: 76px; line-height: 70px; letter-spacing: -0.05em; }
.display-l  { font-size: 48px; line-height: 48px; letter-spacing: -0.045em; }
.display-m  { font-size: 38px; line-height: 41px; letter-spacing: -0.035em; }
.stat-xl    { font-size: 68px; line-height: 58px; letter-spacing: -0.05em; }

.heading {
  font-family: var(--fr-font-body);
  font-weight: 700;
  font-size: 27px;
  line-height: 32px;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.subhead {
  font-family: var(--fr-font-body);
  font-weight: 600;
  font-size: 20px;
  line-height: 26px;
  letter-spacing: -0.015em;
}

.body-l { font-size: 18px; line-height: 29px; }
.small  { font-size: 14px; line-height: 22px; }

/* Every label and eyebrow is uppercase Plex Mono. No sentence-case labels. */
.label {
  font-family: var(--fr-font-mono);
  font-weight: 500;
  font-size: 11px;
  line-height: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fr-text-dim);
}

.data {
  font-family: var(--fr-font-mono);
  font-weight: 400;
  font-size: 15px;
  line-height: 22px;
  font-variant-numeric: tabular-nums;
}

/* Never centre a paragraph. Left aligned, max 72 characters. */
p { max-width: 72ch; text-wrap: pretty; }

.dim { color: var(--fr-text-dim); }

/* The one keyword in a headline that is allowed to be the yellow object. */
.key { color: var(--fr-accent); }

/* Percentage and currency symbols drop to 50% of the figure, full opacity. §4.2 */
.unit { font-size: 50%; }

@media (max-width: 720px) {
  .display-xl { font-size: 44px; line-height: 44px; }
  .display-l  { font-size: 34px; line-height: 36px; }
  .display-m  { font-size: 28px; line-height: 32px; }
  .stat-xl    { font-size: 48px; line-height: 46px; }
  .heading    { font-size: 23px; line-height: 29px; }
  /* Body sizes do not shrink. */
}

/* --------------------------------------------------------------------------
   3. Layout
   -------------------------------------------------------------------------- */

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 104px 0; border-top: 1px solid var(--fr-line); }
.section:first-of-type { border-top: 0; }
.section-tight { padding: 72px 0; }

.stack-8  > * + * { margin-top: 8px; }
.stack-12 > * + * { margin-top: 12px; }
.stack-16 > * + * { margin-top: 16px; }
.stack-24 > * + * { margin-top: 24px; }
.stack-32 > * + * { margin-top: 32px; }
.stack-48 > * + * { margin-top: 48px; }

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

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.measure { max-width: 640px; }

/* Hero blocks: let the display line run wider than the reading measure, so a
   76px headline fills the page instead of stranding half of it. Paragraphs
   inside still cap at 72 characters via the rule on `p`. */
.measure-wide { max-width: 920px; }

@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: minmax(0, 1fr); gap: 40px; }
}

@media (max-width: 600px) {
  .section { padding: 72px 0; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); }
}

/* Rules, never shadows. */
.rule { height: 1px; background: var(--fr-line); border: 0; }

/* --------------------------------------------------------------------------
   4. Header / nav
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--fr-bg-base);
  border-bottom: 1px solid var(--fr-line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 68px;
}

/* Clearspace = one cell (1/3 of mark width) on all four sides. §2 */
.lockup {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--fr-text);
  padding: 10px;
  margin: -10px;
  border-radius: var(--fr-radius);
}

.lockup .mark { width: 22px; height: 22px; flex: none; }

.lockup .wordmark {
  font-family: var(--fr-font-display);
  font-size: 19px;
  line-height: 19px;
  letter-spacing: -0.035em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav a {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--fr-radius);
  color: var(--fr-text-dim);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
}

.nav a:hover { background: var(--fr-bg-hover); color: var(--fr-text); }

/* The active nav state is allowed to be the yellow object — but the header
   also carries the primary CTA, so on this site the active state is a rule,
   not a fill. Weight and a rule, never a second hue. §3.4 */
.nav a[aria-current="page"] {
  color: var(--fr-text);
  box-shadow: inset 0 -2px 0 var(--fr-line-strong);
  border-radius: var(--fr-radius) var(--fr-radius) 0 0;
}

.nav-actions { display: flex; align-items: center; gap: 8px; }

.nav-toggle { display: none; }

@media (max-width: 900px) {
  .site-header .wrap { gap: 12px; }
  .nav {
    display: none;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 16px 20px;
    background: var(--fr-bg-base);
    border-bottom: 1px solid var(--fr-line);
  }
  .nav.is-open { display: flex; }
  .nav a { height: 48px; padding: 0 8px; font-size: 16px; }
  .nav a[aria-current="page"] { box-shadow: none; color: var(--fr-accent); }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-left: auto;
    background: none;
    border: 1px solid var(--fr-line-strong);
    border-radius: var(--fr-radius);
    cursor: pointer;
  }
  .header-cta { display: none; }
}

/* --------------------------------------------------------------------------
   5. Buttons — §5.1. 44px minimum height on every touch target.
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 13px 22px;
  border-radius: var(--fr-radius);
  border: 1px solid transparent;
  font-family: var(--fr-font-body);
  font-weight: 600;
  font-size: 15px;
  line-height: 18px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 100ms linear, color 100ms linear, border-color 100ms linear;
}

/* Exactly one primary per screen — it is the yellow object. */
.btn-primary {
  background: var(--fr-accent);
  color: var(--fr-accent-on);
  border-color: var(--fr-accent);
}
.btn-primary:hover { background: var(--fr-accent-hover); border-color: var(--fr-accent-hover); }
.btn-primary:active { background: var(--fr-accent-active); border-color: var(--fr-accent-active); }

.btn-secondary {
  background: transparent;
  color: var(--fr-text);
  border-color: var(--fr-line-strong);
}
.btn-secondary:hover { background: var(--fr-bg-hover); }

.btn-ghost {
  background: none;
  border-color: transparent;
  color: var(--fr-text-dim);
  padding: 13px 8px;
}
.btn-ghost:hover { color: var(--fr-text); }

.btn:disabled, .btn[aria-disabled="true"] {
  background: var(--fr-line);
  border-color: var(--fr-line);
  color: #6A685E;
  cursor: not-allowed;
}

/* Never remove the focus state. */
:focus-visible {
  outline: 1px solid var(--fr-accent);
  outline-offset: 2px;
  background-color: var(--fr-bg-hover);
}
.btn-primary:focus-visible { background-color: var(--fr-accent-hover); }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* --------------------------------------------------------------------------
   6. Card — §5.2. Order: label → heading → body → 1px rule → source.
   -------------------------------------------------------------------------- */

.card {
  background: var(--fr-bg-raised);
  border: 1px solid var(--fr-line);
  border-radius: var(--fr-radius);
  padding: 24px;
  /* no shadow, ever */
}

.card > * + * { margin-top: 12px; }
.card .rule { margin: 20px 0 12px; }
.card p { max-width: none; }

/* A card only gets an accent top rule if it holds the hero number. */
.card-hero { border-top: 3px solid var(--fr-accent); padding-top: 21px; }

/* --------------------------------------------------------------------------
   7. Stat tile — §5.3
   -------------------------------------------------------------------------- */

.stat { display: flex; flex-direction: column; gap: 10px; }
.stat .figure { font-family: var(--fr-font-display); font-size: 68px; line-height: 58px; letter-spacing: -0.05em; }
.stat .foot {
  font-family: var(--fr-font-mono);
  font-size: 12px;
  line-height: 18px;
  color: var(--fr-text-dim);
}

/* Hero tile only: 3px accent top rule. Every other tile in the row has none. */
.stat-hero { border-top: 3px solid var(--fr-accent); padding-top: 20px; }
.stat-plain { border-top: 1px solid var(--fr-line); padding-top: 20px; }

@media (max-width: 720px) {
  .stat .figure { font-size: 48px; line-height: 46px; }
}

/* --------------------------------------------------------------------------
   8. Segment pills — §5.4. Always carry the count.
   -------------------------------------------------------------------------- */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--fr-radius-chip);
  border: 1px solid;
  font-family: var(--fr-font-mono);
  font-size: 11px;
  line-height: 14px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
}

.pill-critical { color: var(--fr-critical); border-color: color-mix(in srgb, var(--fr-critical) 25%, transparent); }
.pill-watch    { color: var(--fr-watch);    border-color: color-mix(in srgb, var(--fr-watch) 25%, transparent); }
.pill-strong   { color: var(--fr-strong);   border-color: color-mix(in srgb, var(--fr-strong) 25%, transparent); }
.pill-neutral  { color: var(--fr-neutral);  border-color: color-mix(in srgb, var(--fr-neutral) 25%, transparent); }

.pill-row { display: flex; flex-wrap: wrap; gap: 8px; }

/* Capability wall — deliberately NOT .pill. A segment pill carries a count
   (§5.4) and means a state a member is in; these are just names of things the
   platform does. Same visual family, different job, so they get their own
   class rather than a countless .pill that breaks that rule by example. */
.cap-wall {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cap {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: var(--fr-radius-chip);
  border: 1px solid var(--fr-line);
  color: var(--fr-text-dim);
  font-family: var(--fr-font-mono);
  font-size: 11px;
  line-height: 14px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   9. Screenshot frame — §7 do-not #1.
   Real screens only. Until a real screen exists, this frame states plainly
   that it is empty. It never renders invented product UI.
   -------------------------------------------------------------------------- */

.shot {
  border: 1px solid var(--fr-line);
  border-radius: var(--fr-radius);
  background: var(--fr-bg-raised);
  overflow: hidden;
}

.shot img { width: 100%; height: auto; border-radius: 0; }

.shot-pending {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  min-height: 320px;
  padding: 24px;
  background:
    repeating-linear-gradient(
      135deg,
      transparent 0 14px,
      var(--fr-line) 14px 15px
    ),
    var(--fr-bg-raised);
}

.shot-pending .label { color: var(--fr-text-dim); }
.shot-pending .note { font-family: var(--fr-font-mono); font-size: 12px; line-height: 18px; color: var(--fr-text-dim); }

.shot-caption {
  display: flex;
  gap: 8px;
  align-items: baseline;
  margin-top: 12px;
  font-family: var(--fr-font-mono);
  font-size: 12px;
  line-height: 18px;
  color: var(--fr-text-dim);
}

/* --------------------------------------------------------------------------
   10. Numbered feature blocks
   -------------------------------------------------------------------------- */

.numbered { counter-reset: fr-step; }

.step { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 20px; }

.step .idx {
  font-family: var(--fr-font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--fr-text-dim);
  padding-top: 6px;
  border-top: 1px solid var(--fr-line-strong);
}

@media (max-width: 600px) {
  .step { grid-template-columns: minmax(0, 1fr); gap: 12px; }
}

/* --------------------------------------------------------------------------
   11. Quote / calibration table
   -------------------------------------------------------------------------- */

.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left;
  font-family: var(--fr-font-mono);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fr-text-dim);
  padding: 0 16px 12px 0;
  border-bottom: 1px solid var(--fr-line);
}
.table td {
  padding: 16px 16px 16px 0;
  border-bottom: 1px solid var(--fr-line);
  vertical-align: top;
}
.table td.num { text-align: right; font-family: var(--fr-font-mono); font-variant-numeric: tabular-nums; padding-right: 0; }
.table tbody tr:hover { background: var(--fr-bg-hover); }

/* --------------------------------------------------------------------------
   12. Form — §5.1 sizing
   -------------------------------------------------------------------------- */

.field { display: flex; flex-direction: column; gap: 8px; }

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 46px;
  padding: 12px 14px;
  background: var(--fr-bg-raised);
  color: var(--fr-text);
  border: 1px solid var(--fr-line-strong);
  border-radius: var(--fr-radius);
  font-family: var(--fr-font-body);
  font-size: 16px;   /* never below 16px — iOS zoom, and §8 build constraints */
  line-height: 22px;
}

.field textarea { min-height: 112px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--fr-text-dim); }

/* --------------------------------------------------------------------------
   13. Footer
   -------------------------------------------------------------------------- */

.site-footer { border-top: 1px solid var(--fr-line); padding: 56px 0 40px; }
.site-footer a { color: var(--fr-text-dim); text-decoration: none; font-size: 15px; }
.site-footer a:hover { color: var(--fr-text); }
.site-footer .cols { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.site-footer li + li { margin-top: 10px; }

@media (max-width: 780px) {
  .site-footer .cols { grid-template-columns: 1fr 1fr; }
}

/* --------------------------------------------------------------------------
   14. Theme toggle
   -------------------------------------------------------------------------- */

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: none;
  border: 1px solid var(--fr-line-strong);
  border-radius: var(--fr-radius);
  color: var(--fr-text-dim);
  cursor: pointer;
}
.theme-toggle:hover { background: var(--fr-bg-hover); color: var(--fr-text); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-light { display: none; }
[data-theme="light"] .theme-toggle .icon-light { display: block; }
[data-theme="light"] .theme-toggle .icon-dark { display: none; }

/* --------------------------------------------------------------------------
   15. Utilities
   -------------------------------------------------------------------------- */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 12px 18px;
  background: var(--fr-accent);
  color: var(--fr-accent-on);
  border-radius: 0 0 var(--fr-radius) 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; }

.eyebrow { display: block; margin-bottom: 18px; }

.hr-accent { height: 3px; width: 64px; background: var(--fr-accent); border: 0; }

.nowrap { white-space: nowrap; }
