/* ============================================================
   Team Azizi — Base: reset, typography, layout primitives,
   buttons, forms. Component-specific rules live in site.css.
   ============================================================ */

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

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-ink);
  font-family: var(--f-body);
  font-size: var(--t-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
picture,
video,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ---- Headings ---------------------------------------------- */

/* Reem Kufi Fun is a COLRv1 colour font: the tittles on i/j are small red
   hearts, which is the "Fun" in the family name and what the old site shipped
   (unremarked in research/design.md). Red is nowhere else in this brand and
   fights the gold accent, so we remap the colour layer to #8D7120 rather than
   flattening it — the detail survives, in the brand's own accent.
   Delete this block to restore the stock red. */
@font-palette-values --ta-gold {
  font-family: "Reem Kufi Fun";
  override-colors: 0 #8d7120, 1 #8d7120;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0 0 0.5em;
  font-family: var(--f-display);
  font-palette: --ta-gold;
  font-weight: 400;
  line-height: var(--lh-display);
  letter-spacing: var(--ls-display);
  text-wrap: balance;
}

h1 { font-size: var(--t-h1); }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); }
h4 { font-size: var(--t-h4); }
h5 { font-size: var(--t-h5); }
h6 { font-size: var(--t-h6); }

p {
  margin: 0 0 1.25em;
  max-width: 68ch;
  text-wrap: pretty;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

/* ---- Accessibility ------------------------------------------ */

:where(a, button, input, select, textarea, summary):focus-visible {
  outline: 2px solid var(--c-gold);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: var(--gutter);
  z-index: var(--z-modal);
  padding: 0.75rem 1.25rem;
  background: var(--c-ink);
  color: var(--c-on-dark);
  font: 700 var(--t-ui) / 1 var(--f-body);
  letter-spacing: var(--ls-ui);
  text-transform: uppercase;
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

/* ---- Layout ------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--wide {
  max-width: var(--container-wide);
}

.container--narrow {
  max-width: 74ch;
}

.section {
  padding-block: var(--section-y);
}

.section--tight {
  padding-block: var(--section-y-tight);
}

/* The alternating white/black rhythm is core to the brand. */
.section--dark {
  background: var(--c-ink);
  color: var(--c-on-dark);
}

.section--panel {
  background: var(--c-panel);
}

.grid {
  display: grid;
  gap: clamp(1.5rem, 1rem + 2vw, 2.5rem);
}

.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
/* Four short columns — the "why join" band. Narrower minimum than --3 so
   four sit on one row on a desktop and fold to two, then one. */
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 13.5rem), 1fr)); }

/* ---- Eyebrow / meta ----------------------------------------- */

.eyebrow {
  margin: 0 0 1rem;
  font-family: var(--f-body);
  font-size: var(--t-ui);
  font-weight: 700;
  letter-spacing: var(--ls-ui);
  text-transform: uppercase;
  color: var(--c-neutral);
}

.section--dark .eyebrow {
  color: var(--c-rule-strong);
}

/* A 110×1px centred hairline under display headings — lifted
   from the original "Work With Us" band. */
.rule-center::after {
  content: "";
  display: block;
  width: 110px;
  height: 1px;
  margin: 1.25rem auto 0;
  background: currentColor;
  opacity: 0.6;
}

.rule-gold::after {
  content: "";
  display: block;
  width: 64px;
  height: 2px;
  margin-top: 0.875rem;
  background: var(--c-gold);
}

/* ---- Buttons ------------------------------------------------ */
/* Square, 2px border, ghost by default, inverts on hover. */

.btn {
  display: inline-block;
  padding: 1.25rem 2.875rem;
  border: var(--border-w) solid currentColor;
  border-radius: var(--radius);
  background: transparent;
  color: inherit;
  font-family: var(--f-body);
  font-size: var(--t-small);
  font-weight: 700;
  letter-spacing: var(--ls-ui);
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur) var(--ease),
              color var(--dur) var(--ease);
}

/* On light backgrounds */
.btn--dark {
  color: var(--c-ink);
}

.btn--dark:hover,
.btn--dark:focus-visible {
  background: var(--c-ink);
  color: var(--c-on-dark);
}

/* On dark backgrounds and over photography */
.btn--light {
  color: var(--c-on-dark);
}

.btn--light:hover,
.btn--light:focus-visible {
  background: var(--c-on-dark);
  color: var(--c-ink);
}

/* Form submits are filled, not ghost */
.btn--filled {
  background: var(--c-ink);
  border-color: var(--c-ink);
  color: var(--c-on-dark);
}

.btn--filled:hover,
.btn--filled:focus-visible {
  background: transparent;
  color: var(--c-ink);
}

.btn--sm {
  padding: 0.875rem 1.75rem;
  font-size: var(--t-ui);
}

/* Property/status tag — gold block, white type */
.tag {
  display: inline-block;
  padding: 0.5rem 2.125rem;
  background: var(--c-gold);
  color: var(--c-on-dark);
  font-size: var(--t-small);
  font-weight: 700;
  letter-spacing: var(--ls-ui);
  text-transform: uppercase;
}

/* ---- Forms -------------------------------------------------- */

label {
  display: block;
  margin-bottom: 0.375rem;
  font-size: var(--t-ui);
  font-weight: 700;
  letter-spacing: var(--ls-ui);
  text-transform: uppercase;
}

input,
select,
textarea {
  width: 100%;
  padding: 0.9375rem 1rem;
  border: 1px solid var(--c-silver);
  border-radius: var(--radius);
  background: var(--c-bg);
  color: var(--c-ink);
  font-family: var(--f-body);
  font-size: var(--t-body);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--c-ink);
}

textarea {
  min-height: 8rem;
  resize: vertical;
}

.field {
  margin-bottom: 1.25rem;
}

/* TCPA consent block — required on every lead form. */
.consent {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: start;
  margin-bottom: 1.5rem;
}

.consent input {
  width: 1.125rem;
  height: 1.125rem;
  margin-top: 0.25rem;
}

.consent p {
  margin: 0;
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--c-neutral);
}

/* ---- Media band --------------------------------------------- */
/* Full-bleed image or video with a legibility overlay. */

.band {
  position: relative;
  display: grid;
  place-items: center;
  padding-block: clamp(5rem, 3rem + 9vw, 9rem);
  overflow: hidden;
  color: var(--c-on-dark);
  text-align: center;
}

.band__media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.band::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--o-media);
  z-index: 1;
}

.band--hero::after { background: var(--o-hero); }
.band--heavy::after { background: var(--o-media-heavy); }

/* Plate: the hero for a community with no photograph. The background is an
   abstract texture that depicts nothing, so unlike the photo bands it is
   light — which means the type has to flip to ink and the dark scrim has to
   go. See build/textures.py for why these are not pictures of places. */
.band--plate {
  color: var(--c-ink);
  border-block: 1px solid var(--c-rule);
}

.band--plate::after { background: none; }

.band > .container {
  position: relative;
  z-index: 2;
}
