/* Bureau Brand System — Brand Overview v2.0 (2025) */

@font-face {
  font-family: "Acid Grotesk";
  src: url("/fonts/FFF-AcidGrotesk-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Acid Grotesk";
  src: url("/fonts/FFF-AcidGrotesk-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Acid Grotesk";
  src: url("/fonts/FFF-AcidGrotesk-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "National 2 Condensed";
  src: url("/fonts/national-2-condensed-bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Quadrant Text";
  src: url("/fonts/QuadrantText-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Primary palette */
  --color-canary-yellow: #fffd6d;
  --color-warm-grey: #c4c3c1;
  --color-mid-grey: #647170;
  --color-steel-blue: #213741;

  /* Secondary palette */
  --color-off-white: #f7f4e7;
  --color-bright-blue: #3171f1;
  --color-lilac: #c4c0f9;
  --color-red-orange: #ff603b;

  /* Semantic */
  --color-bg: var(--color-off-white);
  --color-surface: #ffffff;
  --color-text: var(--color-steel-blue);
  --color-accent: var(--color-canary-yellow);
  --color-muted: var(--color-mid-grey);
  --color-border: rgba(33, 55, 65, 0.18);
  --color-error: var(--color-red-orange);
  --color-focus: var(--color-bright-blue);

  /* Typography */
  --font-display: "National 2 Condensed", "Arial Narrow", Arial, sans-serif;
  --font-body: "Acid Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Quadrant Text", "JetBrains Mono", "Courier New", monospace;

  /* Display rules — per brand spec */
  --display-leading: 0.9;
  --display-tracking: -0.05em;

  /* Body rules */
  --body-leading: 1.4;
  --body-tracking: 0.02em;

  /* Mono rules */
  --mono-leading: 1.3;
  --mono-tracking: 0.1em;

  /* Geometric radii */
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: var(--body-leading);
  letter-spacing: var(--body-tracking);
  background: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  max-width: 680px;
  margin: 0 auto;
  padding: 56px 24px 96px;
}

/* Brand bar — small mono signature at top */
.brand-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: var(--mono-tracking);
  text-transform: uppercase;
  color: var(--color-steel-blue);
  margin-bottom: 32px;
}

.brand-bar .dot {
  width: 8px;
  height: 8px;
  background: var(--color-canary-yellow);
  border-radius: 50%;
  display: inline-block;
}

/* Display headlines — National 2 Condensed Bold, tight */
h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.75rem, 7vw, 4.5rem);
  line-height: var(--display-leading);
  letter-spacing: var(--display-tracking);
  margin: 0 0 16px;
  color: var(--color-steel-blue);
}

h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.875rem, 4vw, 2.5rem);
  line-height: var(--display-leading);
  letter-spacing: var(--display-tracking);
  margin: 0 0 14px;
  color: var(--color-steel-blue);
}

#form-title {
  white-space: pre-line;
}

.form-kicker {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.875rem;
  letter-spacing: 0.04em;
  color: var(--color-mid-grey);
  margin: 0 0 8px;
  max-width: 56ch;
}

header { margin-bottom: 36px; }

.sub {
  font-family: var(--font-body);
  color: var(--color-mid-grey);
  font-size: 1.0625rem;
  margin: 0 0 20px;
  max-width: 52ch;
}

/* Cards */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 16px;
}

.hidden { display: none; }

/* Form labels — Acid Grotesk Medium, slight track, uppercase */
label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-steel-blue);
  margin-bottom: 8px;
  font-weight: 500;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
textarea,
select {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-family: var(--font-body);
  letter-spacing: var(--body-tracking);
  background: #fff;
  color: var(--color-text);
  transition: border-color 0.15s, box-shadow 0.15s;
}

input::placeholder,
textarea::placeholder {
  color: var(--color-warm-grey);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--color-focus);
  box-shadow: 0 0 0 3px rgba(49, 113, 241, 0.18);
}

textarea {
  resize: vertical;
  min-height: 84px;
  font-family: var(--font-body);
}

select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%23213741' d='M6 8 0 0h12z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}

/* Buttons — primary CTA: yellow + steel blue text in mono */
button {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: var(--mono-tracking);
  line-height: var(--mono-leading);
  text-transform: uppercase;
  padding: 14px 22px;
  border-radius: var(--radius-md);
  border: none;
  background: var(--color-canary-yellow);
  color: var(--color-steel-blue);
  cursor: pointer;
  transition: transform 0.1s ease, background 0.15s, color 0.15s;
  margin-top: 16px;
}

button:hover:not(:disabled) {
  background: var(--color-steel-blue);
  color: var(--color-canary-yellow);
}

button:active:not(:disabled) {
  transform: translateY(1px);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

button.link {
  background: transparent;
  color: var(--color-mid-grey);
  padding: 8px 0;
  margin-top: 12px;
  text-transform: none;
  letter-spacing: var(--body-tracking);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.875rem;
}

button.link:hover:not(:disabled) {
  background: transparent;
  color: var(--color-steel-blue);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.hint {
  font-family: var(--font-body);
  color: var(--color-mid-grey);
  font-size: 0.875rem;
  margin: 12px 0 0;
}

/* Field stacking + pre-filled annotation */
.field {
  margin-bottom: 22px;
}

/* POC sub-section — shown when user says they aren't the main contact */
.poc-section {
  border-left: 3px solid var(--color-steel-blue);
  padding: 4px 0 4px 16px;
  margin: -8px 0 22px;
  background: rgba(33, 55, 65, 0.03);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.poc-section .field:last-child {
  margin-bottom: 12px;
}

/* Generic conditional agreement section — e.g. elevator booking */
.agreement-section {
  border-left: 3px solid var(--color-canary-yellow);
  padding: 14px 16px 16px;
  margin: -10px 0 22px;
  background: rgba(255, 253, 109, 0.18);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.agreement-section .helper-text {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 0.875rem;
  color: var(--color-steel-blue);
  max-width: none;
}

/* Override default label styling for checkbox rows — these are body copy, not labels */
.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0;
  padding: 4px 0;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: var(--body-tracking);
  line-height: 1.4;
  text-transform: none;
  color: var(--color-steel-blue);
  cursor: pointer;
}

.checkbox-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin-top: 2px;
  accent-color: var(--color-canary-yellow);
  cursor: pointer;
}

.field.prefilled {
  position: relative;
  padding-left: 14px;
  border-left: 3px solid var(--color-canary-yellow);
}

.prefilled-note {
  margin: 6px 0 0;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  letter-spacing: var(--body-tracking);
  color: var(--color-mid-grey);
  font-style: italic;
}

.helper-text {
  margin: -2px 0 8px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  letter-spacing: var(--body-tracking);
  color: var(--color-mid-grey);
  line-height: 1.45;
  max-width: 56ch;
}

.helper-warn {
  color: var(--color-red-orange);
  font-weight: 500;
}

/* Section break — used before the "additional charges" group */
.section-heading {
  margin: 32px 0 18px;
  padding-top: 28px;
  border-top: 1px solid var(--color-border);
}

.section-heading h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.625rem;
  line-height: var(--display-leading);
  letter-spacing: var(--display-tracking);
  margin: 0 0 10px;
  color: var(--color-steel-blue);
}

.section-note {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: var(--body-tracking);
  margin: 0;
  color: var(--color-red-orange);
}

/* Ticket cards — clickable list items */
.ticket {
  display: block;
  width: 100%;
  text-align: left;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  margin: 0 0 12px;
  cursor: pointer;
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 1rem;
  letter-spacing: var(--body-tracking);
  text-transform: none;
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
}

.ticket:hover {
  border-color: var(--color-steel-blue);
  background: var(--color-canary-yellow);
}

.ticket:hover .ticket-meta {
  color: var(--color-steel-blue);
}

.ticket-subject {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1.0625rem;
  margin-bottom: 6px;
  letter-spacing: 0;
  white-space: pre-line;
}

.ticket-meta {
  display: flex;
  gap: 14px;
  color: var(--color-mid-grey);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.8125rem;
  letter-spacing: var(--body-tracking);
}

/* Error block */
.error {
  background: var(--color-red-orange);
  color: #fff;
  border-radius: var(--radius-md);
  padding: 14px 18px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.9375rem;
  letter-spacing: var(--body-tracking);
  margin-top: 16px;
}

/* Hero email + verify steps — white card with a steel blue outline */
#step-email,
#step-verify {
  background: #fff;
  border: 2px solid var(--color-steel-blue);
  border-radius: 18px;
  padding: 36px;
  color: var(--color-steel-blue);
}

.step-badge {
  display: inline-block;
  background: var(--color-red-orange);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

#step-email label,
#step-verify label {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.875rem;
  letter-spacing: 0.02em;
  text-transform: none;
  color: var(--color-steel-blue);
}

#step-email input[type="email"],
#step-verify input[type="text"] {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  padding: 14px 18px;
  border: 1.5px solid var(--color-steel-blue);
  border-radius: 999px;
  background: var(--color-off-white);
  color: var(--color-steel-blue);
}

#step-email input[type="email"]::placeholder,
#step-verify input[type="text"]::placeholder {
  color: var(--color-mid-grey);
  font-weight: 400;
}

#step-email input[type="email"]:focus,
#step-verify input[type="text"]:focus {
  border-color: var(--color-steel-blue);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(33, 55, 65, 0.12);
}

/* Code input — large monospace digits, centered */
#step-verify input[type="text"]#code {
  text-align: center;
  font-family: "Courier New", "JetBrains Mono", Courier, monospace;
  font-size: 1.5rem;
  letter-spacing: 0.4em;
  font-weight: 700;
  padding: 16px 18px;
}

#step-email button,
#step-verify button[type="submit"],
#details-form button[type="submit"] {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 0.02em;
  text-transform: none;
  border-radius: 999px;
  padding: 14px 26px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

#details-form button[type="submit"] {
  margin-top: 24px;
}

#step-email .hint,
#step-verify .hint {
  font-family: var(--font-body);
  color: var(--color-steel-blue);
  opacity: 0.65;
}

#step-verify .link {
  display: inline-block;
  margin-right: 16px;
}
