/* ==========================================================
   Figuro Design / wuzotek.site
   Bauhaus tile board: every page is a grid of square tiles.
   ========================================================== */

:root {
  --red: #E63946;
  --blue: #1D3557;
  --yellow: #F4D35E;
  --cream: #F1FAEE;
  --black: #101010;
  --head: "League Spartan", "Century Gothic", "Trebuchet MS", Arial, sans-serif;
  --copy: "Kumbh Sans", "Segoe UI", Verdana, Arial, sans-serif;
  --board: 1200px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--black);
  font-family: var(--copy);
  font-size: 1.0625rem;
  line-height: 1.6;
}
h1, h2, h3 {
  font-family: var(--head);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 0.98;
  margin: 0;
  overflow-wrap: anywhere;
}
p, ul, ol { margin: 0; }
a { color: inherit; }
svg { max-width: 100%; display: block; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 4px solid var(--black);
  outline-offset: 2px;
  box-shadow: 0 0 0 8px var(--yellow);
}

/* ---------- masthead ---------- */
.masthead {
  max-width: var(--board);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  border-bottom: 6px solid var(--black);
  position: relative;
}
.mark {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  min-height: 72px;
  text-decoration: none;
  font-family: var(--head);
  font-weight: 800;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
  line-height: 1;
}
.mark__glyph { display: grid; grid-template-columns: 18px 18px; grid-template-rows: 18px 18px; flex: none; }
.mark__glyph i { display: block; }
.mark__glyph i:nth-child(1) { background: var(--red); border-radius: 50%; }
.mark__glyph i:nth-child(2) { background: var(--blue); }
.mark__glyph i:nth-child(3) { background: var(--yellow); border-radius: 0 0 0 100%; }
.mark__glyph i:nth-child(4) { background: var(--black); clip-path: polygon(0 0, 100% 100%, 0 100%); }
.mark span span { font-weight: 500; }
.mark:hover .mark__glyph { transform: rotate(90deg); }
.mark__glyph { transition: transform .3s; }

.menu-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 72px;
  min-height: 72px;
  padding: 0 16px;
  border: 0;
  background: var(--black);
  color: var(--cream);
  font: 700 0.95rem/1 var(--head);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.menu-btn__icon { position: relative; width: 22px; height: 22px; flex: none; }
.menu-btn__icon::before, .menu-btn__icon::after { content: ""; position: absolute; transition: transform .25s, border-radius .25s; }
.menu-btn__icon::before { left: 0; top: 0; width: 13px; height: 13px; border-radius: 50%; background: var(--red); }
.menu-btn__icon::after { right: 0; bottom: 0; width: 13px; height: 13px; background: var(--yellow); }
.menu-btn[aria-expanded="true"] { background: var(--red); color: var(--black); }
.menu-btn[aria-expanded="true"] .menu-btn__icon::before { background: var(--black); border-radius: 0; transform: translate(4px, 4px) rotate(45deg) scale(1.5, .35); }
.menu-btn[aria-expanded="true"] .menu-btn__icon::after { background: var(--black); transform: translate(-5px, -5px) rotate(-45deg) scale(1.5, .35); }

.shapes-nav { flex: 1 0 100%; }
.shapes-nav ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 6px solid var(--black); }
.shapes-nav li { min-width: 0; }
.shapes-nav li:last-child { grid-column: 1 / -1; }
.shapes-nav a {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  min-height: 112px;
  padding: 14px 16px;
  text-decoration: none;
  font: 700 1.05rem/1.05 var(--head);
  border-bottom: 2px solid var(--black);
}
.shapes-nav li:nth-child(odd):not(:last-child) a { border-right: 2px solid var(--black); }
.shapes-nav li:last-child a { border-bottom: 0; flex-direction: row; align-items: center; justify-content: flex-start; min-height: 76px; }
.shapes-nav a[aria-current="page"] { background: var(--yellow); }
.glyph { display: block; width: 38px; height: 38px; flex: none; transition: transform .3s; }
.glyph--disc { background: var(--red); border-radius: 50%; }
.glyph--block { background: var(--blue); }
.glyph--peak { background: var(--black); clip-path: polygon(50% 4%, 100% 100%, 0 100%); }
.glyph--quarter { background: var(--red); border-radius: 100% 0 0 0; }
.glyph--arch { background: var(--blue); border-radius: 999px 999px 0 0; height: 19px; margin: 9px 0 10px; }
.shapes-nav li:last-child .glyph--arch { margin: 0; }
.shapes-nav a:hover .glyph { transform: rotate(90deg); }
.shapes-nav a:hover { background: var(--black); color: var(--cream); }
.shapes-nav a:hover .glyph--peak, .shapes-nav a:hover .glyph--block, .shapes-nav a:hover .glyph--arch { background: var(--yellow); }
.shapes-nav a:focus-visible { outline-offset: -6px; box-shadow: none; }
.js .shapes-nav:not(.is-open) { display: none; }

/* ---------- the board ---------- */
.board {
  max-width: var(--board);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-flow: dense;
}
.tile {
  --bg: var(--cream);
  --ink: var(--black);
  --shape: var(--black);
  position: relative;
  min-width: 0;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
}
.tile::before { content: ""; position: absolute; background: var(--shape); transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.tile:not(.says):hover::before { transform: rotate(90deg); }

.bg-red { --bg: var(--red); }
.bg-blue { --bg: var(--blue); --ink: var(--cream); }
.bg-yellow { --bg: var(--yellow); }
.bg-cream { --bg: var(--cream); }
.bg-black { --bg: var(--black); --ink: var(--cream); }
.of-red { --shape: var(--red); }
.of-blue { --shape: var(--blue); }
.of-yellow { --shape: var(--yellow); }
.of-cream { --shape: var(--cream); }
.of-black { --shape: var(--black); }

.disc::before { inset: 13%; border-radius: 50%; }
.dot::before { inset: 32%; border-radius: 50%; }
.ring::before { inset: 13%; border-radius: 50%; background: transparent; border: clamp(10px, 2.6vw, 30px) solid var(--shape); }
.q-nw::before { inset: 0; border-radius: 100% 0 0 0; }
.q-ne::before { inset: 0; border-radius: 0 100% 0 0; }
.q-se::before { inset: 0; border-radius: 0 0 100% 0; }
.q-sw::before { inset: 0; border-radius: 0 0 0 100%; }
.leaf::before { inset: 0; border-radius: 100% 0 100% 0; }
.wedge-a::before { inset: 0; clip-path: polygon(0 0, 100% 0, 0 100%); }
.wedge-b::before { inset: 0; clip-path: polygon(100% 0, 100% 100%, 0 100%); }
.peak::before { inset: 0; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.arch::before { left: 0; right: 0; bottom: 0; height: 50%; border-radius: 999px 999px 0 0; }
.bowl::before { left: 0; right: 0; top: 0; height: 50%; border-radius: 0 0 999px 999px; }
.dee::before { top: 0; bottom: 0; left: 0; width: 50%; border-radius: 0 999px 999px 0; }
.block::before { inset: 26%; }
.bars::before { inset: 0; background: repeating-linear-gradient(90deg, var(--shape) 0 12.5%, transparent 12.5% 25%); }
.steps-shape::before { inset: 0; clip-path: polygon(0 100%, 0 66.6%, 33.3% 66.6%, 33.3% 33.3%, 66.6% 33.3%, 66.6% 0, 100% 0, 100% 100%); }
.tile.arch:hover::before, .tile.bowl:hover::before, .tile.dee:hover::before, .tile.bars:hover::before { transform: scale(.82); }

.big { grid-column: span 2; grid-row: span 2; }
.lg-only { display: none; }

/* text tiles */
.says {
  aspect-ratio: auto;
  grid-column: 1 / -1;
  padding: 34px 20px 38px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: visible;
}
.says::before { content: none; }
.says > * { max-width: 62ch; position: relative; }
.says p + p, .says p + ul, .says p + ol { margin-top: 0.9em; }
.label {
  font: 700 0.86rem/1 var(--head);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.label::before { content: ""; width: 14px; height: 14px; border-radius: 50%; background: currentColor; flex: none; }
.label--sq::before { border-radius: 0; }
.label--tri::before { border-radius: 0; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
h1 { font-size: clamp(2.5rem, 9.4vw, 4.7rem); margin-bottom: 20px; }
.inner-h1 { font-size: clamp(2.3rem, 8.4vw, 3.6rem); }
h2 { font-size: clamp(1.8rem, 6vw, 2.6rem); margin-bottom: 16px; }
h3 { font-size: 1.5rem; margin-bottom: 10px; }
.lede { font-size: 1.16rem; line-height: 1.5; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 22px 0 8px;
  border: 0;
  border-radius: 999px;
  background: var(--black);
  color: var(--cream);
  font: 700 1.05rem/1 var(--head);
  text-decoration: none;
  cursor: pointer;
}
.pill::before { content: ""; width: 38px; height: 38px; border-radius: 50%; background: var(--red); flex: none; transition: border-radius .25s, background-color .25s; }
.pill:hover::before { border-radius: 0; background: var(--yellow); }
.pill--plain { background: transparent; color: inherit; box-shadow: inset 0 0 0 3px currentColor; }
.pill--plain::before { background: var(--blue); }
.bg-black .pill, .bg-blue .pill { background: var(--cream); color: var(--black); }
.bg-red .pill::before { background: var(--yellow); }
.bg-red .pill:hover::before { background: var(--cream); }

/* linked discipline tiles */
.door {
  aspect-ratio: auto;
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 260px;
  padding: 26px 20px;
  text-decoration: none;
}
.door::before { width: 150px; height: 150px; top: -30px; right: -30px; }
.door--disc::before { border-radius: 50%; }
.door--peak::before { clip-path: polygon(50% 0, 100% 100%, 0 100%); top: 14px; right: 14px; width: 130px; height: 130px; }
.door:hover::before { transform: scale(1.25) rotate(90deg); }
.door__n { font: 800 1rem/1 var(--head); letter-spacing: 0.1em; margin-bottom: auto; position: relative; }
.door__t { font: 800 clamp(1.9rem, 7vw, 2.4rem)/0.98 var(--head); letter-spacing: -0.025em; margin: 70px 0 10px; position: relative; }
.door__d { position: relative; max-width: 34ch; }
.door__go { position: relative; margin-top: 14px; font: 700 1rem/1 var(--head); text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 5px; }

/* numbered tiles */
.num { display: grid; place-items: center; }
.num::before { inset: auto; left: 13%; top: 50%; width: 74%; aspect-ratio: 1; border-radius: 50%; translate: 0 -50%; }
.num--sq::before { border-radius: 0; }
.num--tri::before { border-radius: 0; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.num--tri b { padding-top: 0.5em; font-size: clamp(1.3rem, 5vw, 2.6rem); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.num b { position: relative; font: 800 clamp(1.6rem, 7vw, 3.4rem)/1 var(--head); color: var(--numink, var(--black)); padding-top: 0.12em; }
.step { grid-column: span 3; padding: 20px 16px 22px; justify-content: flex-start; }
.step h3 { font-size: 1.3rem; }

/* lists */
.marks { list-style: none; padding: 0; }
.marks li { position: relative; padding-left: 30px; }
.marks li + li { margin-top: 10px; }
.marks li::before { content: ""; position: absolute; left: 0; top: 0.42em; width: 14px; height: 14px; background: currentColor; }
.marks--round li::before { border-radius: 50%; }
.marks--tri li::before { clip-path: polygon(50% 0, 100% 100%, 0 100%); }

/* composer */
.composer-stage { aspect-ratio: 1; grid-column: 1 / -1; background: var(--black); padding: 0; }
.composer-stage::before { content: none; }
.composer-stage svg { width: 100%; height: 100%; }
.composer-stage g[role="button"] { cursor: pointer; outline: none; }
.composer-stage g[role="button"]:focus-visible .focus-box { stroke: var(--black); stroke-width: 8; stroke-dasharray: 10 6; }
.composer-stage .focus-box { fill: none; stroke: none; }
.seg { display: inline-flex; align-self: flex-start; margin-top: 22px; border: 3px solid currentColor; border-radius: 999px; overflow: hidden; }
.seg button { min-width: 62px; min-height: 48px; border: 0; background: transparent; color: inherit; font: 700 1rem/1 var(--head); cursor: pointer; }
.seg button + button { border-left: 3px solid currentColor; }
.seg button[aria-pressed="true"] { background: var(--yellow); color: var(--black); }
.seg button:focus-visible { outline-offset: -5px; box-shadow: none; }
.seg-label { display: block; margin-top: 22px; font: 700 0.86rem/1 var(--head); letter-spacing: 0.14em; text-transform: uppercase; }
.seg-label + .seg { margin-top: 10px; }
.quiet { font-size: 0.98rem; margin-top: 16px; }

/* contact */
.form-row { margin-bottom: 18px; max-width: 34rem; }
.form-row label { display: block; font: 700 1.05rem/1.2 var(--head); margin-bottom: 7px; }
.form-row input, .form-row select, .form-row textarea {
  width: 100%;
  min-height: 54px;
  padding: 12px 14px;
  border: 3px solid var(--black);
  border-radius: 0;
  background: #fff;
  color: var(--black);
  font: 400 1.0625rem/1.4 var(--copy);
}
.form-row textarea { min-height: 170px; resize: vertical; }
.form-row .is-wrong { border-color: var(--red); box-shadow: inset 8px 0 0 var(--red); }
.form-row .oops { margin-top: 6px; font-weight: 700; color: #a3141f; }
.form-note { max-width: 34rem; margin-top: 14px; font-size: 0.98rem; }
.form-result { max-width: 34rem; margin-top: 16px; padding: 14px 16px; background: var(--yellow); font-weight: 700; }
.card-list { margin: 0; }
.card-list > div + div { margin-top: 18px; }
.card-list dt { font: 700 0.86rem/1 var(--head); letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 6px; color: var(--yellow); }
.card-list dd { margin: 0; font-size: 1.1rem; overflow-wrap: anywhere; }
.card-list a { text-decoration-thickness: 2px; text-underline-offset: 4px; }
.card-list a:hover { color: var(--yellow); }

/* ---------- base ---------- */
.base { background: var(--blue); color: var(--cream); margin-top: 0; }
.base__in { max-width: var(--board); margin: 0 auto; padding: 44px 20px 30px; display: grid; gap: 34px; }
.base__in > * { min-width: 0; }
.base h2 { font-size: 0.86rem; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 700; color: var(--yellow); margin-bottom: 16px; }
.base__brand { font: 800 2.2rem/0.95 var(--head); letter-spacing: -0.025em; }
.base__brand + p { margin-top: 12px; max-width: 30ch; }
.base ul { list-style: none; padding: 0; }
.base li a { display: inline-flex; align-items: center; gap: 10px; min-height: 40px; text-decoration: none; font-weight: 500; }
.base li a::before { content: ""; width: 10px; height: 10px; background: var(--red); border-radius: 50%; transition: border-radius .2s, background-color .2s; }
.base li a:hover::before, .base li a[aria-current="page"]::before { border-radius: 0; background: var(--yellow); }
.base li a:hover { text-decoration: underline; text-underline-offset: 4px; }
.base dl { margin: 0; }
.base dl > div { padding: 8px 0; border-top: 2px solid rgba(241, 250, 238, 0.25); }
.base dt { font-weight: 700; font-size: 0.95rem; }
.base dd { margin: 0; overflow-wrap: anywhere; }
.base dd a:hover { color: var(--yellow); }
.base__strip { max-width: var(--board); margin: 0 auto; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); }
.base__strip .tile:nth-child(n+9) { display: none; }
.base :focus-visible { outline-color: var(--cream); box-shadow: 0 0 0 8px var(--red); }

/* ---------- tablet ---------- */
@media (min-width: 620px) {
  .says { padding: 48px 40px 52px; }
  .door { grid-column: span 2; min-height: 0; aspect-ratio: 1; }
  .door:last-of-type { grid-column: 1 / -1; aspect-ratio: auto; min-height: 240px; }
  .step { padding: 28px 30px; }
  .base__in { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 56px 40px 36px; }
  .base__in > :first-child { grid-column: 1 / -1; }
}

/* ---------- desktop: six columns, links always visible ---------- */
@media (min-width: 1040px) {
  body { font-size: 1.125rem; }
  .masthead { flex-wrap: nowrap; }
  .mark { padding: 0 20px 0 24px; font-size: 1.7rem; }
  .menu-btn { display: none; }
  .shapes-nav, .js .shapes-nav:not(.is-open) { display: block; flex: 0 1 auto; }
  .shapes-nav ul { display: flex; border-top: 0; }
  .shapes-nav li:last-child { grid-column: auto; }
  .shapes-nav a, .shapes-nav li:last-child a {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 132px;
    min-height: 112px;
    padding: 12px 6px;
    border: 0;
    border-left: 2px solid var(--black);
    text-align: center;
    font-size: 0.98rem;
  }
  .shapes-nav li:last-child .glyph--arch { margin: 9px 0 10px; }
  .shapes-nav li:nth-child(odd):not(:last-child) a { border-right: 0; }

  .board { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .lg-only { display: block; }
  .sm-only { display: none; }
  .says { grid-column: span 4; padding: 40px 48px; }
  .says.w6 { grid-column: 1 / -1; }
  .says.w3 { grid-column: span 3; }
  .says.w2 { grid-column: span 2; }
  .says.h2 { grid-row: span 2; }
  .says.h3 { grid-row: span 3; }
  .says.right { grid-column: 3 / span 4; }
  .says.right3 { grid-column: 4 / span 3; }
  .top { justify-content: flex-start; }
  .door, .door:last-of-type { grid-column: span 2; aspect-ratio: 1; min-height: 0; padding: 34px; }
  .door::before { width: 210px; height: 210px; top: -40px; right: -40px; }
  .door--peak::before { width: 170px; height: 170px; top: 24px; right: 24px; }
  .step { grid-column: span 2; padding: 30px 30px 34px; }
  .composer-stage { grid-column: span 3; grid-row: span 3; }
  .base__in { grid-template-columns: 1.1fr 0.8fr 1.6fr; padding: 70px 48px 40px; gap: 48px; }
  .base__in > :first-child { grid-column: auto; }
  .base__strip { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .base__strip .tile:nth-child(n+9) { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
