/*
  The Mason Company: parent site.
  Layout: one column page. Wide display type up top, a brick-bond band as the
  only ornament, then a ledger of brands (rows, not cards) grouped by kind.
  The brick bond is the one subject detail: a mason lays courses, each brand
  here is one course in the wall.
*/

:root {
  /* colour: navy ink on a cool paper, cobalt as the one accent (matches the logo), ochre and green only for signals */
  --paper: #f1f4fa;
  --paper-2: #e5eaf5;
  --ink: #0d1b3d;
  --ink-soft: #52607f;
  --line: #c7d0e4;
  --accent: #2f5bff;
  --accent-ink: #ffffff;
  --accent-tint: #dde5ff;
  --live: #1d7a52;
  --beta: #a8631a;
  --soon: #52607f;

  /* type */
  --font-display: "Archivo", "Arial Black", system-ui, sans-serif;
  --font-body: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --gutter: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  --wrap: 1120px;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #080f22;
    --paper-2: #0e1834;
    --ink: #e6ecfa;
    --ink-soft: #96a4c6;
    --line: #22305a;
    --accent: #6f93ff;
    --accent-ink: #080f22;
    --accent-tint: #14214a;
    --live: #6fcf9f;
    --beta: #e3a559;
    --soon: #96a4c6;
    color-scheme: dark;
  }
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + var(--gutter) + var(--gutter-r));
  margin-inline: auto;
  padding-inline: var(--gutter) var(--gutter-r);
}

.skip {
  position: absolute;
  left: 16px;
  top: -4rem;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.6rem 1rem;
  z-index: 20;
}
.skip:focus { top: 8px; }

/* header */
.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}
.brand svg { width: 34px; height: 34px; flex: none; }

.nav {
  display: flex;
  gap: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.nav a { text-decoration: none; padding-block: 0.25rem; border-bottom: 2px solid transparent; }
.nav a:hover { border-bottom-color: var(--accent); }

/* hero */
.hero .wrap { padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(2rem, 5vw, 3.5rem); }

.eyebrow {
  margin: 0 0 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-soft);
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.01em;
  text-wrap: balance;
  margin: 0;
}

h1 {
  font-stretch: 125%;
  font-size: clamp(2.2rem, 7.4vw, 5.4rem);
  max-width: 17ch;
}

.lede {
  max-width: 56ch;
  margin: 1.75rem 0 0;
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  color: var(--ink-soft);
}
.lede strong { color: var(--ink); font-weight: 600; }

/* the brick-bond band: a mask, so it follows the theme colour */
.course {
  height: 80px;
  background: var(--line);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40' viewBox='0 0 80 40'%3E%3Cpath d='M0 1H80M0 21H80M1 0V20M41 0V20M21 20V40M61 20V40' stroke='%23000' stroke-width='2' fill='none'/%3E%3C/svg%3E") 0 0 / 80px 40px repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40' viewBox='0 0 80 40'%3E%3Cpath d='M0 1H80M0 21H80M1 0V20M41 0V20M21 20V40M61 20V40' stroke='%23000' stroke-width='2' fill='none'/%3E%3C/svg%3E") 0 0 / 80px 40px repeat;
}

/* sections */
.section .wrap { padding-block: clamp(2.5rem, 6vw, 4.5rem); }

h2 {
  font-stretch: 112%;
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  margin-bottom: 0.75rem;
}

.section-intro { margin: 0 0 2.5rem; max-width: 52ch; color: var(--ink-soft); }

.group-label {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 2.5rem 0 0;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.group-label:first-of-type { margin-top: 0; }
.group-label span:last-child { color: var(--ink-soft); }

.ledger { list-style: none; margin: 0; padding: 0; }

.row {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.8fr) 8.5rem minmax(0, 13rem);
  align-items: center;
  gap: 0.5rem 1.5rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  transition: background-color 0.15s, box-shadow 0.15s;
}
/* the highlight bleeds past the rules on both sides without moving the text */
.row:hover {
  background: var(--accent-tint);
  box-shadow: -0.75rem 0 0 var(--accent-tint), 0.75rem 0 0 var(--accent-tint);
}

.row-name {
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 800;
  font-size: 1.45rem;
  line-height: 1.1;
}
.row-desc { margin: 0; color: var(--ink-soft); font-size: 1rem; line-height: 1.5; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.status::before {
  content: "";
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: currentColor;
}
.status.live { color: var(--live); }
.status.beta { color: var(--beta); }
.status.soon { color: var(--soon); }
.status.soon::before { background: none; border: 2px solid currentColor; }

.row-url {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}
.row-url .arrow {
  flex: none;
  transition: transform 0.15s;
}
.row:hover .arrow { transform: translateX(4px); }

/* about + contact */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
  gap: 1.5rem clamp(2rem, 6vw, 5rem);
}
.prose p { margin: 0 0 1.1rem; max-width: 60ch; }
.prose p:last-child { margin-bottom: 0; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.prose a:hover { text-decoration-thickness: 2px; }

.alt { background: var(--paper-2); }

.contact-links { margin: 1.25rem 0 0; padding: 0; list-style: none; display: grid; gap: 0.5rem; }
.contact-links a {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--accent);
  text-underline-offset: 3px;
}

/* footer */
.site-footer .course { height: 40px; }
.site-footer .wrap { padding-block: 1.75rem calc(2rem + env(safe-area-inset-bottom, 0px)); }
.legal {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.7;
  color: var(--ink-soft);
}

/* narrow */
@media (max-width: 860px) {
  .row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "name status"
      "desc desc"
      "url  url";
    padding-block: 1.1rem;
  }
  .row-name { grid-area: name; }
  .status { grid-area: status; }
  .row-desc { grid-area: desc; }
  .row-url { grid-area: url; margin-top: 0.25rem; }
  .split { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 480px) {
  .nav { gap: 1rem; }
  .course { height: 60px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .row, .row-url .arrow { transition: none; }
}
