/* fuad-daoud.com: one sheet for the home page and /status/.
   Recursive (OFL, fonts/OFL.txt) is self-hosted: latin subset, wght 300-1000 + MONO axis. */
@font-face {
  font-family: "Recursive";
  src: url("/fonts/recursive-latin.woff2") format("woff2");
  font-weight: 300 1000;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* planner blue and builder amber are relevo's two roles; they appear only in its loop and in focus/links */
:root {
  color-scheme: light dark;
  --paper: #EDF0F3;
  --pane: #E2E7ED;
  --ink: #1C2430;
  --muted: #5B6675;
  --rule: #C9D0D8;
  --planner: #2F4BD8;
  --on-planner: #FFFFFF;
  --builder: #D99A0E;
  --builder-line: #B37A00;
  --on-builder: #1C2430;
  --hover: #2F4BD8;
  --up: #2E7D4F;
  --dip: #E8A33D;
  --none: #D3D9E0;
  --down: #B3261E;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1A2230;
    --pane: #212B3B;
    --ink: #E4E8EE;
    --muted: #9AA5B4;
    --rule: #34405A;
    --planner: #7F95FF;
    --on-planner: #1A2230;
    --builder: #E8AE2E;
    --builder-line: #E8AE2E;
    --on-builder: #1A2230;
    --hover: #A9B8FF;
    --up: #4FBF7F;
    --none: #34405A;
    --down: #FF6B5E;
  }
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Recursive", ui-sans-serif, system-ui, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--ink);
  text-decoration-color: var(--planner);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.28em;
}

a:hover {
  color: var(--hover);
}

a:focus-visible {
  outline: 3px solid var(--planner);
  outline-offset: 4px;
  border-radius: 4px;
}

code {
  font-family: "Recursive", ui-monospace, monospace;
  font-variation-settings: "MONO" 1;
}

.dot {
  display: inline-block;
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--muted);
}

.dot.up {
  background: var(--up);
}

.dot.down {
  background: var(--down);
}

/* ---- home: two panes, you on the left, relevo on the right ---- */

.panes {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 2px minmax(0, 1fr);
  min-height: 100vh;
  min-height: 100dvh;
}

.divider {
  background: var(--ink);
}

.me {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 48px;
  padding: clamp(56px, 11vh, 104px) clamp(24px, 6.6vw, 96px) 48px clamp(24px, 7.8vw, 112px);
}

.me-top {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.name {
  margin: 0;
  font-size: clamp(88px, 12.8vw, 184px);
  line-height: 0.84;
  font-weight: 950;
  letter-spacing: -0.045em;
}

.role {
  margin: 0;
  font-size: clamp(22px, 2.1vw, 30px);
  line-height: 1.3;
  font-weight: 450;
}

.contact {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 36px;
  font-size: clamp(19px, 1.55vw, 22px);
  font-weight: 650;
}

.contact a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration-thickness: 3px;
}

.health {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 10px;
  min-height: 44px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
}

.project {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
  padding: clamp(40px, 11vh, 104px) clamp(24px, 6.1vw, 88px) 48px clamp(24px, 5.5vw, 80px);
  background: var(--pane);
}

.project h2 {
  margin: 0;
  font-size: clamp(40px, 3.9vw, 56px);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.project p {
  margin: 0;
  max-width: 28em;
  font-size: clamp(17px, 1.4vw, 20px);
  line-height: 1.55;
}

.project code {
  max-width: 100%;
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--paper);
  font-size: 15px;
  overflow-wrap: anywhere;
}

.project-head {
  display: flex;
  align-items: center;
  gap: 16px;
}

.version {
  padding: 3px 12px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  font-size: 14px;
  font-variation-settings: "MONO" 1;
}

.version[hidden] {
  display: none;
}

.project .caption {
  margin-top: -12px;
  color: var(--muted);
  font-size: 15px;
}

/* dated on purpose: "the first six weeks" stays true, so these numbers never need updating */
.firsts {
  align-self: stretch;
  max-width: 480px;
  padding-top: 20px;
  border-top: 1.5px solid var(--rule);
}

.project .firsts-label {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 14px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
}

.stats div {
  display: flex;
  flex-direction: column-reverse;
}

.stats dd {
  margin: 0;
  font-size: clamp(28px, 2.4vw, 34px);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.stats dt {
  color: var(--muted);
  font-size: 14px;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 28px;
  font-size: 18px;
  font-weight: 650;
}

.project-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

@media (max-width: 900px) {
  .panes {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto 2px auto;
  }

  .me {
    justify-content: flex-start;
    gap: 28px;
    padding-bottom: 40px;
  }

  .me-top {
    gap: 28px;
  }

  .project {
    padding-top: 40px;
  }

}

/* the handoff loop: one MasterMind, three builders; the middle round animates -- plan out on the
   upper line, report back on the lower one (SMIL, 7 s cycle); the outer curves stay still */
.loop {
  display: block;
  width: 100%;
  max-width: 480px;
  height: auto;
  overflow: visible;
}

.loop .line {
  fill: none;
  stroke: var(--ink);
  stroke-width: 2;
}

.loop .line.quiet {
  stroke: var(--muted);
  stroke-width: 1.5;
}

.loop .head,
.loop .label {
  fill: var(--ink);
}

.loop .tag {
  fill: var(--muted);
  font-size: 15px;
  text-anchor: middle;
}

.loop .harness {
  font-variation-settings: "MONO" 1;
}

.loop .label {
  font-size: 17px;
  font-weight: 600;
  text-anchor: middle;
}

.loop .who {
  font-size: 21px;
  font-weight: 700;
  text-anchor: middle;
}

.loop .box-planner { fill: var(--planner); }
.loop .box-builder { fill: var(--builder); }
.loop .who-planner, .loop .bar-planner { fill: var(--on-planner); }
.loop .who-builder, .loop .bar-builder { fill: var(--on-builder); }

.loop .trail {
  fill: none;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 100;
}

.loop .trail-plan { stroke: var(--planner); }
.loop .trail-report { stroke: var(--builder-line); }

.loop .ring {
  fill: none;
  stroke-width: 3;
}

.loop .ring-planner { stroke: var(--planner); }
.loop .ring-builder { stroke: var(--builder); }

.loop .packet {
  stroke: var(--pane);
  stroke-width: 2;
}

.loop .packet-plan { fill: var(--planner); }
.loop .packet-report { fill: var(--builder); }

/* SMIL ignores this query, so the moving parts are hidden instead; the still diagram stays */
@media (prefers-reduced-motion: reduce) {
  .loop .motion {
    display: none;
  }
}

/* the diagram scales with the pane, so its type needs a bump on phones */
@media (max-width: 900px) {
  .loop .label {
    font-size: 22px;
  }

  .loop .who {
    font-size: 26px;
  }

  .loop .who-planner {
    font-size: 23px;
  }

  .loop .tag {
    font-size: 19px;
  }
}

/* ---- /status/ ---- */

.status {
  display: flex;
  flex-direction: column;
  gap: 48px;
  max-width: 1440px;
  padding: clamp(48px, 9vh, 88px) clamp(20px, 7.8vw, 112px) 64px;
}

.status-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.status h1 {
  margin: 0;
  font-size: clamp(60px, 6.7vw, 96px);
  line-height: 0.9;
  font-weight: 950;
  letter-spacing: -0.045em;
}

#overall {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: clamp(19px, 1.7vw, 24px);
  font-weight: 600;
}

#overall.up { color: var(--up); }
#overall.down { color: var(--down); }

#overall .dot {
  width: 14px;
  height: 14px;
  background: currentColor;
}

.checked {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  color: var(--muted);
  font-size: 16px;
}

.svc-head,
.svc {
  display: grid;
  grid-template-columns: 260px 180px minmax(0, 1fr);
  align-items: center;
  gap: 24px;
}

.svc-head {
  padding-bottom: 12px;
  border-bottom: 2px solid var(--ink);
  color: var(--muted);
  font-size: 14px;
}

.svc {
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
}

.svc-name {
  font-size: 19px;
  font-weight: 650;
}

.svc-now {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
}

.days {
  display: flex;
  gap: 4px;
}

.day {
  flex: 1 1 0;
  max-width: 20px;
  height: 30px;
  border-radius: 3px;
  background: var(--none);
}

.day.up { background: var(--up); }
.day.dip { background: var(--dip); }

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
  margin: 0;
  padding: 16px 0 0 488px;
  list-style: none;
  color: var(--muted);
  font-size: 14px;
}

.legend li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.legend .day {
  flex: none;
  width: 12px;
  height: 12px;
  border-radius: 2px;
}

.status h2 {
  margin: 0 0 16px;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.events {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 17px;
}

.events li {
  display: grid;
  grid-template-columns: 200px 200px 80px minmax(0, 1fr);
  align-items: baseline;
  gap: 16px;
}

.events time,
.events .code {
  color: var(--muted);
}

.events .who {
  font-weight: 600;
}

.events .up,
.events .down {
  font-weight: 750;
}

.events .up { color: var(--up); }
.events .down { color: var(--down); }

.back {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  min-height: 44px;
  font-size: 17px;
  font-weight: 650;
}

.muted {
  color: var(--muted);
}

@media (max-width: 900px) {
  .checked {
    align-items: flex-start;
  }

  .svc-head {
    display: none;
  }

  .svc {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 16px;
  }

  .days {
    grid-column: 1 / -1;
  }

  .legend {
    padding-left: 0;
  }

  .events li {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0 12px;
  }

  .events time {
    grid-column: 1 / -1;
    font-size: 15px;
  }

  .events .code {
    display: none;
  }
}
