/* Two Dollar Tools — site styles */

/* fonts ------------------------------------------------------- */

/* Served from this site, not from a font service, so a visitor's browser
   talks to nobody but us. privacy.html says so; keep it true. Each family is
   under the SIL Open Font License, and the license texts sit beside the files
   in fonts/. The Sans and the Grotesk are variable fonts: one file covers
   every weight in the range. The -ext files hold accented Latin and load only
   when a page uses a character from them. */

@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(fonts/space-grotesk.woff2) format("woff2");
  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;
}
@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(fonts/space-grotesk-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url(fonts/plex-sans.woff2) format("woff2");
  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;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url(fonts/plex-sans-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/plex-mono-500.woff2) format("woff2");
  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;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/plex-mono-500-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/plex-mono-600.woff2) format("woff2");
  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;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/plex-mono-600-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #14161A;
  --panel: #1B1E23;
  --panel-2: #20242A;
  --well: #101216;
  --line: #2A2E35;
  --line-strong: #3A404A;
  --text: #E9EAEC;
  --muted: #A7ADB6;
  --dim: #868D97;
  --soft: #B6BCC5;
  --accent: #5B93B8;
  --accent-ink: #0B1219;
  --accent-link: #8FBCD8;

  --warn-bg: #1C1A16;
  --warn-line: #4A3A1E;
  --warn-title: #E9D9B4;
  --warn-text: #C6BCA3;

  --display: "Space Grotesk", "Segoe UI", sans-serif;
  --body: "IBM Plex Sans", "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --pad: clamp(20px, 5vw, 80px);
  --radius: 11px;
  --radius-lg: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--display);
  /* Never leave one word alone on the last line. Ignored where unsupported. */
  text-wrap: balance;
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.12;
}

h1 { font-size: clamp(34px, 5.4vw, 62px); letter-spacing: -0.03em; }
h2 { font-size: clamp(26px, 3.2vw, 40px); }
h3 { font-size: 17px; letter-spacing: -0.01em; line-height: 1.3; }

p { margin: 0; }

a { color: var(--accent-link); text-decoration: none; }
a:hover { color: #AFD2E6; }

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

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

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 10;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 10px 16px;
  border-radius: 8px;
}

/* layout ------------------------------------------------------ */

.wrap {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

section { padding-top: clamp(48px, 7vw, 80px); }

.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-lg { display: flex; flex-direction: column; gap: 24px; }

.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

/* Text beside media on a wide screen. Once it stacks, the media sits between
   the intro and the detail rather than after everything: on a phone the clip
   would otherwise land below the bullets AND below the link that leads away,
   so anyone following that link never saw it. Three children, in reading
   order: intro, media, detail. */
.media-split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  grid-template-areas:
    "intro media"
    "detail media";
  column-gap: clamp(28px, 4vw, 56px);
  row-gap: 16px;
  align-items: start;
}
.media-split > .media-intro { grid-area: intro; }
.media-split > .media-detail { grid-area: detail; }
.media-split > .shot { grid-area: media; align-self: center; }

.measure { max-width: 62ch; }

.rule { border-top: 1px solid var(--line); padding-top: 36px; }

/* type helpers ------------------------------------------------ */

.eyebrow {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-link);
}

.lede { font-size: clamp(17px, 1.6vw, 19px); color: var(--soft); }
.body-muted { color: var(--muted); font-size: 15px; }
.fineprint { font-size: 14px; color: var(--dim); }
.mono { font-family: var(--mono); font-size: 0.93em; color: #D6DAE0; }
.note { font-size: 15px; color: var(--dim); }

/* nav --------------------------------------------------------- */

.nav { border-bottom: 1px solid var(--line); }

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
  padding-top: 12px;
  padding-bottom: 12px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  font-family: var(--display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
}
.brand:hover { color: var(--text); }

.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--mono);
  font-weight: 600;
  font-size: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.4vw, 32px);
  font-size: 15px;
  flex-wrap: wrap;
}
.nav-links a { color: var(--muted); }
.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--text); }

/* buttons ----------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 9px;
  font-size: 15px;
  font-weight: 600;
  text-align: center;
  /* .btn sits on <a> and, in the library filter, on <button>. A button
     element arrives with the browser's own plate, border and font, which
     rendered the inactive filters as pale boxes. Reset to the blank slate an
     anchor already is; btn-primary and btn-ghost below paint it, and both
     come later, so they still win. Every .btn on the site carries one. */
  appearance: none;
  -webkit-appearance: none;
  background: none;
  border: 0;
  font-family: inherit;
  cursor: pointer;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: #74A9CC; color: var(--accent-ink); }
.btn-ghost { border: 1px solid var(--line-strong); color: var(--text); font-weight: 500; }
.btn-ghost:hover { border-color: var(--muted); color: var(--text); }
.btn-sm { min-height: 44px; padding: 0 18px; }
.btn-block { width: 100%; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* cards ------------------------------------------------------- */

.card {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.card-lg { padding: clamp(26px, 3vw, 44px); border-radius: var(--radius-lg); }
.card-plain { border-radius: 0; border-left: 0; border-right: 0; border-bottom: 0; padding-left: 0; padding-right: 0; }
.card-plain { background: transparent; }
.card-accent { border-color: var(--accent); background: var(--panel-2); }
.card p { color: var(--muted); font-size: 15px; }
.card .push { margin-top: auto; }

/* Two ways to buy an add-on: the tool alone, or with the tool box it docks
   into. They wrap to two rows when a card is too narrow for both, which is
   why the labels are short. $4 is $2 + $2 -- the same as buying them
   separately, so it is a shorter checkout and never a discount. */
.buy-pair {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}
.buy-pair .btn {
  flex: 1 1 104px;
  min-height: 42px;
  padding: 0 10px;
  font-size: 13px;
}


/* placeholder frames ------------------------------------------ */

/* captures ---------------------------------------------------- */

.shot {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--panel);
}

/* placeholders ------------------------------------------------ */

.ph {
  border-radius: var(--radius);
  border: 1px dashed var(--line-strong);
  background: var(--panel);
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
}
.ph-tall { min-height: 400px; }
.ph-tag { font-family: var(--mono); font-size: 13px; color: var(--dim); }
.ph-text { font-size: 15px; color: var(--soft); max-width: 34ch; }

/* tool + price ------------------------------------------------ */

.tool-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.price { font-family: var(--mono); font-size: 14px; color: var(--accent); }
.price-big {
  font-family: var(--display);
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
}

.bundle-list { font-size: 14px; line-height: 1.8; color: var(--muted); }

/* bullets ----------------------------------------------------- */

.bullets { display: flex; flex-direction: column; gap: 12px; margin: 0; padding: 0; list-style: none; }
/* The dot is positioned, not a flex item. With the li as a flex box, every
   inline tag inside it (a <strong>, an <em>, a link) became a flex item of
   its own and the sentence broke apart with gaps around it. */
.bullets li {
  position: relative;
  padding-left: 18px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--muted);
}
.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

/* themes ------------------------------------------------------ */

.swatch {
  border-radius: 9px;
  border: 1px solid #2B2F36;
  overflow: hidden;
}
.swatch-face { height: 64px; display: flex; align-items: flex-end; }
.swatch-accent { height: 14px; width: 100%; }
.swatch-name { padding: 10px 12px; background: var(--panel); font-size: 13px; color: var(--soft); }

/* library palette chips --------------------------------------- */

/* The four colors a shared theme is actually made of. A name alone says
   nothing about a theme, and a screenshot of one would be a 40KB image per
   card for information that fits in four rectangles. */
.chips {
  display: flex;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.chips span { flex: 1; height: 34px; }

/* what a shared widget's code calls. The page warns that widgets run
   Python; naming the Maya commands is the short version of that warning. */
.mono-note {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--dim);
  word-break: break-word;
}

/* facts ------------------------------------------------------- */

.fact { display: flex; flex-direction: column; gap: 6px; }
.fact-key { font-family: var(--mono); font-size: 15px; color: var(--accent); }
.fact-val { font-size: 14px; line-height: 1.55; color: var(--muted); }

/* notice ------------------------------------------------------ */

.notice {
  padding: 24px 28px;
  border-radius: var(--radius);
  background: var(--warn-bg);
  border: 1px solid var(--warn-line);
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.notice svg { flex-shrink: 0; margin-top: 2px; }
.notice h3 { color: var(--warn-title); font-family: var(--body); font-size: 16px; font-weight: 600; }
.notice p { color: var(--warn-text); font-size: 15px; }

/* filters ----------------------------------------------------- */

/* .card and .filters are both display:flex, which beats the hidden
   attribute on its own. The library filter hides cards with it. */
[hidden] { display: none !important; }

.filters { display: flex; flex-wrap: wrap; gap: 10px; }

/* code well --------------------------------------------------- */

.well {
  padding: 24px 26px;
  border-radius: 10px;
  background: var(--well);
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 14px;
  line-height: 2;
  color: var(--soft);
  white-space: pre-wrap;
  margin: 0;
  overflow-x: auto;
}

/* faq --------------------------------------------------------- */

.faq { display: flex; flex-direction: column; gap: 8px; }
.faq h3 { font-size: 17px; }
.faq p { font-size: 15px; color: var(--muted); }

/* cta band ---------------------------------------------------- */

.cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(20px, 4vw, 40px);
  flex-wrap: wrap;
}

/* footer ------------------------------------------------------ */

.footer {
  margin-top: clamp(48px, 7vw, 72px);
  border-top: 1px solid var(--line);
}
.footer-inner {
  padding-top: 32px;
  padding-bottom: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 14px;
}
.footer-inner a { color: var(--muted); }
.footer-links { display: flex; gap: 28px; flex-wrap: wrap; }
.footer-note { color: var(--dim); }
.footer-social {
  flex-basis: 100%;
  display: flex;
  align-items: center;
  gap: 12px 20px;
  flex-wrap: wrap;
  color: var(--dim);
}
.footer-social a { display: inline-flex; padding: 4px; }
.footer-social a:hover { color: var(--accent-link); }

/* pick your own (tools.html) ---------------------------------- */

.picks { gap: 12px 24px; }
.pick {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--panel-2);
  font-size: 15px;
  cursor: pointer;
}
.pick:hover { border-color: var(--line-strong); }
.pick input { width: 18px; height: 18px; accent-color: var(--accent); flex-shrink: 0; }
.pick:has(input:checked) { border-color: var(--accent); }
.pick-base { grid-column: 1 / -1; }
.pick-base .note { font-size: 14px; }
#tiers tr.is-on th, #tiers tr.is-on td { color: var(--text); }
#tiers td { font-family: var(--mono); }

/* releases (changes.html) ------------------------------------- */

.tool-log {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
}
.tool-log[open] > summary {
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
}
.release { padding: 14px 0 2px; }
.release + .release { border-top: 1px solid var(--line); }
.release-version { font-family: var(--mono); font-size: 15px; color: var(--accent-link); }
.tool-log summary,
.release summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 16px;
  cursor: pointer;
  list-style: none;
}
.tool-log summary::-webkit-details-marker,
.release summary::-webkit-details-marker { display: none; }
.release-name { font-family: var(--display); font-size: 18px; font-weight: 700; color: var(--text); }
.release-name a { color: inherit; }
.release summary:hover .release-name a { color: var(--accent-link); }
.release-when {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--dim);
  font-size: 14px;
  white-space: nowrap;
}
.release-mark {
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--dim);
  border-bottom: 2px solid var(--dim);
  transform: translateY(-2px) rotate(45deg);
  transition: transform 120ms ease;
}
.release[open] .release-mark { transform: translateY(2px) rotate(-135deg); }
.release[open] .bullets { margin-top: 16px; }

.lines { list-style: none; margin: 14px 0 4px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.lines li {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 14px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
}
.kind { font-size: 13px; font-weight: 600; letter-spacing: 0.01em; }
.kind-new { color: var(--accent-link); }
.kind-better { color: var(--soft); }
.kind-fixed { color: var(--warn-title); }
.kind-upkeep { color: var(--dim); }
.kind-ships { color: var(--dim); }

/* responsive -------------------------------------------------- */

@media (max-width: 1000px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .split { grid-template-columns: minmax(0, 1fr); }
  .media-split {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "intro" "media" "detail";
    row-gap: 24px;
  }
  .ph-tall { min-height: 300px; }
}

@media (max-width: 640px) {
  body { font-size: 15px; }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .grid-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav-inner { min-height: 64px; }
  .nav-links { gap: 14px; font-size: 14px; width: 100%; }
  .nav-links .btn { margin-left: auto; }
  .btn-row .btn { width: 100%; }
  .ph { min-height: 200px; }
  .well { font-size: 13px; line-height: 1.9; }
  .lines li { grid-template-columns: minmax(0, 1fr); gap: 2px; }
}

/* tool pages -------------------------------------------------- */

.crumb { font-size: 14px; color: var(--dim); }
.crumb a { color: var(--muted); }

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

.spec {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.spec th, .spec td {
  text-align: left;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.spec th { color: var(--dim); font-weight: 500; width: 40%; }
.spec td { color: var(--soft); }
.spec tr:last-child th, .spec tr:last-child td { border-bottom: 0; }

.feature { display: flex; flex-direction: column; gap: 8px; }
.feature h3 { font-size: 18px; }
.feature p { color: var(--muted); font-size: 15px; }

.pill {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-size: 13px;
  color: var(--muted);
}
