/* The Hustle Scorecard: one stylesheet for the whole site. Mobile-first. */

@font-face {
  font-family: "Archivo Black";
  src: url("/fonts/archivo-black-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --dark: #10161F;
  --dark-raised: #1A2230;
  --dark-line: #2A3444;
  --light: #F7F8FA;
  --white: #FFFFFF;
  --green: #2BD67B;        /* accent on dark backgrounds */
  --green-ink: #137A45;    /* green text on light backgrounds (5:1 on --light) */
  --amber: #FFB020;        /* scorecard "caution" only */
  --red: #E5484D;          /* scorecard "fail" only */
  --text-dark: #10161F;
  --text-muted: #4E5866;   /* on light */
  --text-on-dark: #F7F8FA;
  --text-on-dark-muted: #A9B4C2;
  --display: "Archivo Black", "Arial Black", "Helvetica Neue", Arial, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --wrap: 1100px;
}

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

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

body {
  margin: 0;
  background: var(--dark);
  color: var(--text-on-dark);
  font-family: var(--body);
  font-size: 1.0625rem; /* 17px */
  line-height: 1.6;
}

img { max-width: 100%; height: auto; }

h1, h2, h3 {
  margin: 0 0 0.5em;
  line-height: 1.1;
  text-wrap: balance;
}
h1, h2 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.5rem, 8vw, 4.75rem); text-transform: uppercase; }
h2 { font-size: clamp(1.9rem, 5vw, 2.75rem); }
h3 { font-size: 1.2rem; font-weight: 700; }

p { margin: 0 0 1em; }

.accent { color: var(--green); }
.section-light .accent { color: var(--green-ink); }

a { color: var(--green); text-underline-offset: 0.18em; }
a:hover { color: var(--white); }
.section-light a { color: var(--green-ink); }
.section-light a:hover { color: var(--text-dark); }

:focus-visible {
  outline: 3px solid var(--green);
  outline-offset: 3px;
  border-radius: 2px;
}
.section-light :focus-visible { outline-color: var(--green-ink); }

.visually-hidden {
  position: absolute !important;
  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;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  padding: 0.5rem 1rem;
  background: var(--green);
  color: var(--dark);
  font-weight: 700;
}
.skip-link:focus { top: 1rem; color: var(--dark); }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.narrow { max-width: 760px; }

/* Header */
.site-header { border-bottom: 1px solid var(--dark-line); }
.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-block: 0.9rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--white);
  text-decoration: none;
  font-family: var(--display);
  font-size: 1.2rem;
  line-height: 1.1;
}
.brand:hover { color: var(--white); }
.header-link { font-weight: 600; font-size: 0.98rem; }

/* Hero */
.hero {
  background:
    radial-gradient(ellipse 60% 60% at 85% 10%, rgba(43, 214, 123, 0.12), transparent 70%),
    var(--dark);
}
.hero-inner { padding-block: 3.5rem 4rem; }
.lede {
  max-width: 38rem;
  margin-bottom: 2rem;
  font-size: 1.2rem;
  color: var(--text-on-dark);
}

.actions { display: flex; flex-wrap: wrap; gap: 0.85rem; }
.button {
  display: inline-block;
  padding: 0.85rem 1.5rem;
  border-radius: 8px;
  border: 2px solid var(--green);
  font-weight: 700;
  font-size: 1.02rem;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.button-primary { background: var(--green); color: var(--dark); }
.button-primary:hover { background: var(--white); border-color: var(--white); color: var(--dark); }
.button-secondary { background: transparent; color: var(--white); }
.button-secondary:hover { background: var(--dark-raised); color: var(--green); }

/* Sections */
.section { padding-block: 3.5rem; }
.section-light { background: var(--light); color: var(--text-dark); }
.section-lede { color: var(--text-muted); font-size: 1.1rem; }
.section:not(.section-light) .section-lede { color: var(--text-on-dark-muted); }

/* The six parts, explained */
.split { display: grid; gap: 2.5rem; align-items: start; }
.parts { margin: 1.5rem 0 0; }
.parts div {
  padding: 0.85rem 0;
  border-top: 1px solid #DDE1E7;
}
.parts dt { font-weight: 700; }
.parts dd { margin: 0.15rem 0 0; color: var(--text-muted); }

/* ===== Scorecard component (see the comment in index.html) ===== */
.scorecard {
  margin: 0;
  padding: 1.25rem 1.25rem 1rem;
  background: var(--dark);
  color: var(--text-on-dark);
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(16, 22, 31, 0.18);
}
.scorecard-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--green);
}
.scorecard-kicker {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
}
.scorecard-name { margin: 0; font-family: var(--display); font-size: 1.35rem; }
.scorecard-table { width: 100%; border-collapse: collapse; }
.scorecard-table th,
.scorecard-table td {
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--dark-line);
  vertical-align: middle;
}
.scorecard-table th { text-align: left; font-weight: 600; padding-right: 0.75rem; }
.scorecard-table td { text-align: right; white-space: nowrap; }
.rating { display: inline-flex; gap: 4px; vertical-align: middle; }
.rating i {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid #56637A; /* empty dot, visible on the dark card */
}
.score {
  display: inline-block;
  min-width: 2.6em;
  margin-left: 0.6rem;
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* Fill the first N dots; color by band */
.rating[data-score="1"] i:nth-child(-n+1),
.rating[data-score="2"] i:nth-child(-n+2) { background: var(--red); border-color: var(--red); }
.rating[data-score="3"] i:nth-child(-n+3) { background: var(--amber); border-color: var(--amber); }
.rating[data-score="4"] i:nth-child(-n+4),
.rating[data-score="5"] i:nth-child(-n+5) { background: var(--green); border-color: var(--green); }
.scorecard figcaption {
  margin-top: 0.85rem;
  font-size: 0.88rem;
  color: var(--text-on-dark-muted);
}
/* ===== /Scorecard component ===== */

/* Who it's for */
.cards {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}
.card {
  padding: 1.4rem 1.4rem 1.2rem;
  background: var(--dark-raised);
  border: 1px solid var(--dark-line);
  border-top: 4px solid var(--green);
  border-radius: 10px;
}
.card p { margin: 0; color: var(--text-on-dark-muted); }

/* Coming up */
.upcoming { list-style: none; margin: 0; padding: 0; }
.upcoming li {
  position: relative;
  padding: 1rem 1rem 1rem 3rem;
  margin-bottom: 0.75rem;
  background: var(--white);
  border: 1px solid #DDE1E7;
  border-radius: 10px;
  font-weight: 700;
  font-size: 1.08rem;
  line-height: 1.4;
}
.upcoming li::before {
  content: "";
  position: absolute;
  left: 1.1rem;
  top: 1.25rem;
  width: 14px;
  height: 14px;
  border: 2px solid var(--green-ink);
  border-radius: 4px;
}

/* Our rules */
.rules { list-style: none; margin: 1.5rem 0 0; padding: 0; }
.rules li {
  position: relative;
  padding: 0.75rem 0 0.75rem 2.25rem;
  border-bottom: 1px solid var(--dark-line);
  color: var(--text-on-dark-muted);
}
.rules li:last-child { border-bottom: 0; }
.rules strong { color: var(--text-on-dark); }
.rules li::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 1.05rem;
  width: 14px;
  height: 8px;
  border-left: 3px solid var(--green);
  border-bottom: 3px solid var(--green);
  transform: rotate(-45deg);
}

.contact p { font-size: 1.1rem; }
.contact a { overflow-wrap: anywhere; font-weight: 600; }

/* Footer */
.site-footer {
  padding-block: 2rem;
  font-size: 0.95rem;
  color: var(--text-on-dark-muted);
}
.site-footer p { margin: 0 0 0.5rem; }
.disclaimer { max-width: 46rem; font-size: 0.88rem; }

/* 404 */
.not-found { min-height: 60vh; display: grid; align-items: center; }

@media (min-width: 640px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
  .hero-inner { padding-block: 5rem 5.5rem; }
  .scorecard { padding: 1.5rem 1.75rem 1.25rem; }
}

@media (min-width: 900px) {
  .split { grid-template-columns: 1.1fr 1fr; gap: 3.5rem; }
  .scorecard { position: sticky; top: 1.5rem; }
  .section { padding-block: 4.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
  }
}
