/* Agent-Town for Claude Code: the colors are the office's own (the path, the carpets, the tags). */
:root {
  --path: #f4eadb;        /* the cream brick path between blocks */
  --grout: #eaddc9;
  --exec: #9d9fdc;        /* the executive office's carpet */
  --exec-dark: #9294d4;
  --gray: #cdd0da;        /* the project blocks' carpets */
  --blue: #b9cde6;
  --green: #c5dcc0;
  --wood: #e3cda8;
  --tag: #333d4d;         /* name tags */
  --call: #f27326;        /* the phone line */
  --hat: #f6c844;
  --ink: #262b38;
  --ink-soft: #4a5263;
  --focus: #1f4fd1;
  --display: "Fredoka", "Avenir Next Rounded", ui-rounded, system-ui, sans-serif;
  --text: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--text);
  font-size: 1.0625rem;
  line-height: 1.6;
  /* The brick path, as in the app. */
  background-color: var(--path);
  background-image:
    linear-gradient(var(--grout) 1px, transparent 1px),
    linear-gradient(90deg, var(--grout) 1px, transparent 1px);
  background-size: 48px 24px, 48px 24px;
  background-position: 0 0, 24px 0;
}

a { color: var(--ink); text-decoration-color: var(--call); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; margin: 0 0 0.5em; text-wrap: balance; }
h1 { font-size: clamp(2.2rem, 5.2vw, 3.6rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; max-width: 68ch; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* Header */
.top { padding: 18px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 600; font-size: 1.15rem; text-decoration: none; }
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.top nav { display: flex; gap: 20px; flex-wrap: wrap; }
.top nav a { text-decoration: none; font-weight: 700; color: var(--ink-soft); }
.top nav a:hover { color: var(--ink); }

/* A block: a carpet of square tiles, like the office floor, with a darker front edge. */
.block {
  --c1: var(--gray);
  --c2: #c3c6d1;
  position: relative;
  background-color: var(--c1);
  background-image: conic-gradient(var(--c2) 25%, transparent 0 50%, var(--c2) 0 75%, transparent 0);
  background-size: 64px 64px;
  border-bottom: 6px solid color-mix(in srgb, var(--c2) 70%, var(--ink) 30%);
  border-radius: 6px;
  padding: clamp(28px, 5vw, 56px);
  margin: 0 0 56px;
}
.block.exec { --c1: var(--exec); --c2: var(--exec-dark); }
.block.blue { --c1: var(--blue); --c2: #afc4df; }
.block.green { --c1: var(--green); --c2: #bad3b4; }
.block.wood { --c1: var(--wood); --c2: #dbc39c; }

/* The block's sign, as in the app: a dark plate with the room's name. */
.sign {
  display: inline-block;
  background: var(--tag);
  color: #fff;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1rem;
  padding: 4px 12px;
  border-radius: 6px;
  margin-bottom: 18px;
}

/* Hero: the executive office */
.hero { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.hero h1 { color: var(--ink); }
.hero .lede { font-size: 1.2rem; color: var(--ink); max-width: 34ch; }
.hero .note { color: var(--ink); font-size: 0.95rem; margin-top: 14px; }
.office {
  margin: 0;
  background: var(--path);
  border-radius: 10px;
  padding: 10px;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.35);
}
.office img { display: block; width: 100%; height: auto; border-radius: 6px; }
.office figcaption { font-size: 0.85rem; color: var(--ink-soft); padding: 8px 4px 2px; }

.buttons { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.button {
  display: inline-block;
  background: var(--tag);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: 12px 20px;
  border-radius: 8px;
  border-bottom: 4px solid #1d232e;
}
.button:hover { background: #1d232e; }
.button.light { background: #fff; color: var(--ink); border-bottom-color: #c9cbe6; }
.button.light:hover { background: #eef0ff; }

/* The phone line: one orange dashed line from the CEO's desk down the page. */
main { position: relative; }
.line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 120px;
  width: 0;
  border-left: 4px dashed var(--call);
  transform: translateX(-2px);
  z-index: 0;
  pointer-events: none;
}
main > .wrap { position: relative; z-index: 1; }

/* Who's who: name tags, as the app draws them over each character. */
.cast { list-style: none; padding: 0; margin: 8px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 22px 28px; }
.cast li { display: grid; gap: 6px; align-content: start; }
.tag {
  justify-self: start;
  background: var(--tag);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 2px 9px;
  border-radius: 5px;
}
.tag.you { background: var(--call); }
.cast p { margin: 0; color: var(--ink); }

/* Two columns of short points */
.points { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 26px 40px; margin-top: 8px; }
.points h3 { margin-bottom: 0.25em; }
.points p { margin: 0; }

/* The story: the maintainer's own words */
.story { font-size: 1.15rem; }
.story p { max-width: 62ch; }
.story .by { font-weight: 700; color: var(--ink-soft); font-size: 1rem; }

/* Download */
.downloads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.downloads .plugin { grid-column: 1 / -1; }
.downloads > div { background: rgba(255, 255, 255, 0.55); border-radius: 8px; padding: 22px; }
.downloads h3 { margin-bottom: 0.4em; }
.small { font-size: 0.95rem; color: var(--ink-soft); }
pre {
  background: var(--tag);
  color: #f3f4f8;
  font-family: var(--mono);
  font-size: 0.86rem;
  padding: 12px 14px;
  border-radius: 6px;
  margin: 8px 0 12px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* FAQ */
details { border-top: 2px solid rgba(38, 43, 56, 0.12); padding: 12px 0; }
details:last-of-type { border-bottom: 2px solid rgba(38, 43, 56, 0.12); }
summary { cursor: pointer; font-family: var(--display); font-weight: 600; font-size: 1.15rem; }
details p { margin: 10px 0 0; }

/* Footer */
footer { padding: 8px 0 48px; color: var(--ink-soft); font-size: 0.95rem; }
footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 10px; }
footer a { font-weight: 700; }

/* Plain pages (privacy, code signing policy) */
.page { max-width: 760px; }
.page h1 { font-size: clamp(2rem, 4.5vw, 2.8rem); }
.page h2 { font-size: 1.5rem; margin-top: 1.6em; }
.page ul { padding-left: 1.2em; }
.page li { margin-bottom: 0.4em; }
.page table { border-collapse: collapse; width: 100%; margin: 8px 0 16px; background: rgba(255, 255, 255, 0.55); }
.page th, .page td { text-align: left; padding: 8px 10px; border-bottom: 1px solid rgba(38, 43, 56, 0.15); vertical-align: top; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; }
  .downloads { grid-template-columns: 1fr; }
  .hero .lede { max-width: none; }
  .line { display: none; }
}

/* Traditional Chinese pages: Noto Sans TC for the Chinese characters (the rounded display face has
   none), Latin letters keep their faces; a little more leading for CJK text. */
:lang(zh-Hant-TW) {
  --display: "Fredoka", "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  --text: "Atkinson Hyperlegible", "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
}
body:lang(zh-Hant-TW) { line-height: 1.8; }
:lang(zh-Hant-TW) h1, :lang(zh-Hant-TW) h2, :lang(zh-Hant-TW) h3, :lang(zh-Hant-TW) summary { font-weight: 700; letter-spacing: 0.02em; }
:lang(zh-Hant-TW) .hero .lede { max-width: 26em; }
:lang(zh-Hant-TW) p { max-width: 40em; }
