/* Amaze OS site: the loud layer. Borrowed from the feel of a music-software launch page:
   a geometric sans with a tight display serif, felt-tip scribbles, flat pastel cards split
   by hairlines, a tilted green note, square electric-blue buttons, a lime band.
   Loaded after base.css and pages.css; the Live-style panels inside figures stay as they are. */
:root {
  --display: "Newsreader", "Literata", Georgia, serif;
  --volt: #2b14ff;        /* buttons and live links */
  --volt-dark: #1a06c9;
  --band: #e4ff8f;        /* the strip under the nav */
  --note: #12c400;        /* the tilted note */
  --p-blue: #a3b1fa;
  --p-lime: #e8eca6;
  --p-pink: #eea8ea;
  --p-sand: #f3d6a8;
  --p-mint: #b5ecd0;
  --p-coral: #f6b3a6;
  --hot: #ff2b5e;
}

/* ---------- Nav and the band under it ---------- */
.nav { max-width: none; padding: 18px var(--gutter); }
.wordmark { font-weight: 500; letter-spacing: 0.02em; }
.nav ul { gap: clamp(16px, 2.4vw, 32px); font-size: 18px; }
.nav ul a:hover { color: var(--hot); }
.band {
  display: block; margin: 0; padding: 10px var(--gutter);
  background: var(--band); color: #000; text-align: center; text-decoration: none;
  font-size: 17px; font-weight: 500;
}
.band u { text-decoration-thickness: 1px; text-underline-offset: 3px; }
.band:hover u { text-decoration-thickness: 2px; }

/* ---------- Buttons: square and electric ---------- */
.pill, .btn { border-radius: 0; }
.pill { font-weight: 500; font-size: 17px; padding: 9px 18px; background: #fff; border: 1px solid #000; }
.pill:hover { background: #000; color: #fff; }
.pill.primary, .btn.primary { background: var(--volt); border-color: var(--volt); color: #fff; }
.pill.primary:hover, .btn.primary:hover { background: var(--volt-dark); border-color: var(--volt-dark); }

/* ---------- Scribbles ---------- */
[data-scribble] { position: absolute; pointer-events: none; color: #000; z-index: 2; }
[data-scribble] svg.scr { display: block; width: 100%; height: 100%; overflow: visible; }

/* ---------- Hero ---------- */
.hero.hero-obj { position: relative; max-width: 1240px; padding-top: clamp(28px, 5vw, 64px); }
.hero-tag {
  margin: 0 0 clamp(48px, 7vw, 88px) auto !important; max-width: none !important; text-align: right;
  font-family: var(--display); font-weight: 400; color: #000 !important;
  font-size: clamp(34px, 4.6vw, 64px) !important; line-height: 0.98 !important; letter-spacing: -0.035em;
}
.hero-tag span { display: inline-block; }
.hero-tag span + span { margin-left: 0.25em; transform: translateY(0.22em); }
.hero-obj .hero-links { justify-content: flex-start; margin-top: clamp(56px, 7vw, 88px); position: relative; z-index: 3; }
.hero-scrib-zig { left: 37%; bottom: 10px; width: clamp(150px, 16vw, 230px); height: clamp(190px, 21vw, 290px); z-index: 1; }
.note {
  position: relative; z-index: 3; width: min(100%, 470px); margin: -40px 0 0 auto;
  padding: 18px 26px 22px; background: var(--note); color: #000; text-align: left;
  transform: rotate(-4deg); transform-origin: 70% 50%;
}
.note ul { list-style: none; margin: 0; padding: 0; }
.note li { font-size: clamp(18px, 1.8vw, 23px); font-weight: 500; line-height: 1.25; padding: 7px 0 5px; border-bottom: 1.5px solid #000; }
.note li:last-child { border-bottom: 0; }

/* ---------- Story: told in the display serif ---------- */
.beat p { font-family: var(--display); letter-spacing: -0.025em; line-height: 1.12; }
.beat .when {
  font-size: 14px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em;
  padding: 5px 12px 4px; border: 0; border-radius: 0; background: var(--p-blue);
}
.beat:nth-of-type(6n+2) .when { background: var(--p-lime); }
.beat:nth-of-type(6n+3) .when { background: var(--p-pink); }
.beat:nth-of-type(6n+4) .when { background: var(--p-sand); }
.beat:nth-of-type(6n+5) .when { background: var(--p-mint); }
.beat:nth-of-type(6n+6) .when { background: var(--p-coral); }
.beat.turn .when { background: var(--note); }
.beat.last p { font-family: var(--display); font-weight: 400; letter-spacing: -0.045em; line-height: 0.96; }
.circled { position: relative; display: inline-block; white-space: nowrap; }
.circled [data-scribble] { left: -0.3em; right: -0.3em; top: -0.38em; bottom: -0.34em; }
.underlined { position: relative; display: inline-block; }
.underlined [data-scribble] { left: -2%; right: -2%; bottom: -0.22em; height: 0.36em; }

/* ---------- Section headings: big serif, a scribble beside ---------- */
.stage-head h2, .principle h2 {
  font-family: var(--display); font-weight: 400; letter-spacing: -0.045em; line-height: 0.95;
  font-size: clamp(52px, 7.4vw, 112px);
}
.stage-head h2, .kg h2 { position: relative; }
.h2-zig { right: -0.2em; top: -0.35em; width: 1.4em; height: 1.6em; }
.stage-head p { font-family: var(--sans); font-size: 19px; line-height: 1.55; }

/* ---------- Keep going: a list you point at, and the card for what you point at ---------- */
.kg { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 32px clamp(32px, 6vw, 96px); align-items: start; }
.kg h2 { margin: 0 0 clamp(24px, 3vw, 40px); display: inline-block; padding-right: 1.3em; }
.kg-n { font-family: var(--display); font-size: 15px; vertical-align: top; margin-right: 18px; letter-spacing: 0; }
.kg ul { list-style: none; margin: 0; padding: 0; }
.kg li a {
  position: relative; display: block; padding: 4px 0 6px 38px; color: #a1a1a6; text-decoration: none;
  font-family: var(--display); font-size: clamp(30px, 3.6vw, 52px); letter-spacing: -0.035em; line-height: 1.12;
  border-bottom: 1.5px solid transparent;
}
.kg li a span { display: none; }
.kg li a::before { content: ""; position: absolute; left: 6px; top: 50%; width: 12px; height: 12px; margin-top: -4px; border-radius: 50%; background: #000; opacity: 0; }
.kg li a.on, .kg li a:hover, .kg li a:focus-visible { color: #000; }
.kg li a.on { border-bottom-color: #000; }
.kg li a.on::before { opacity: 1; }
.kg-card {
  position: sticky; top: 32px; margin-top: clamp(90px, 10vw, 150px);
  background: var(--p-blue); color: #000; transform: rotate(1.5deg);
}
.kg-card > * { padding: 14px 18px; margin: 0; }
.kg-card .kg-tag { font-size: 15px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; padding-bottom: 36px; }
.kg-card .kg-say { font-size: 19px; line-height: 1.4; border-top: 1.5px solid #000; min-height: 7.5em; }
.kg-card .kg-go { border-top: 1.5px solid #000; font-size: 17px; font-weight: 500; }
.kg-card .kg-go a { color: #000; text-decoration: none; }
.kg-card .kg-go a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.foot { max-width: none; }

/* ---------- Small screens ---------- */
@media (max-width: 560px) { .story .beat-fig.panel { padding: 14px 14px 0; } }
@media (max-width: 860px) {
  .nav ul { font-size: 16px; }
  .note { width: 92%; margin: 40px auto 0; transform: rotate(-2.5deg); }
  .hero-scrib-zig { display: none; }
  .kg { grid-template-columns: minmax(0, 1fr); }
  .kg-card { display: none; }
  .kg li a { padding-left: 0; }
  .kg li a::before { display: none; }
  .kg li a span { display: block; font-family: var(--sans); font-size: 16px; letter-spacing: 0; color: #4a4a4a; padding-bottom: 8px; }
  .kg li a { color: #000; border-bottom: 1.5px solid #000; padding: 14px 0 6px; }
}
@media (max-width: 560px) {
  .hero-tag { text-align: left; margin-left: 0 !important; }
  .hero-tag span + span { margin-left: 0; transform: none; }
}

/* The book cover in the story uses the display serif too, so the page keeps to one serif */
.ng-bookart .cover .bs { font-family: var(--display); }

/* ---------- Calm: everything is simply there ---------- */
.beat, .beat .beat-fig { opacity: 1 !important; transform: none !important; transition: none !important; }
.beat { min-height: 0; padding: clamp(40px, 6vh, 72px) 0; }
.cipher.arrive { animation: none; }

/* ---------- Figures staged like app shots: the screen on a colour, a hand-lettered caption ---------- */
.story .beat { --bk: #c47b5f; }
.story .beat:nth-of-type(6n+2) { --bk: #8c9a5c; }
.story .beat:nth-of-type(6n+3) { --bk: #7584d6; }
.story .beat:nth-of-type(6n+4) { --bk: #c9a23e; }
.story .beat:nth-of-type(6n+5) { --bk: #b47aa3; }
.story .beat:nth-of-type(6n+6) { --bk: #4f978f; }
.story .beat-fig.panel {
  display: flex; flex-direction: column; overflow: visible;
  background: var(--bk); border: 0; border-radius: 0; color: #fff;
  padding: clamp(16px, 2.8vw, 36px) clamp(16px, 2.8vw, 36px) 0;
}
.story .beat-fig > .panel-head {
  order: 2; background: none; border: 0; min-height: 0; flex-wrap: nowrap;
  gap: 14px; padding: 14px 0 18px;
}
.story .beat-fig > .panel-head .chip { border: 0; border-radius: 0; font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; padding: 3px 8px; }
.story .beat-fig > .panel-head .meta { flex: 1; min-width: 0; color: #fff; }
.story .beat-fig > .panel-head .btn { background: #fff; border-color: #000; }
.hand-on { --hand-h: 21px; }
.hand-art { display: block; }
.story .beat-fig > svg { box-shadow: none; }
/* things that sat on a grey tray now sit straight on the colour */
.story .beat-today, .story .ng-desk, .story .am-worlds { background: transparent; border: 0; border-radius: 0; }
.story .beat-today { padding: 0; }
.story .am-worlds { padding: 0; }
.story .ng-desk { padding: 12px 0 8px; }
.stage-hand { margin: 14px 0 0; color: #000; }
.stage-hand { --hand-h: 22px; }

/* ---------- The mock screens, in the colours of a music app ---------- */
.am { background: #2f2f2f; border-color: #111; border-radius: 0; }
.am-bar { gap: 8px; }
.am-title { background: #ffa53c; color: #000; padding: 1px 7px; border-radius: 2px; letter-spacing: 0.06em; }
.am-btns span { background: #3d3d3d; border: 1px solid #141414; border-radius: 2px; opacity: 1; padding: 1px 8px; color: #d6d6d6; }
.am-right { opacity: 1; color: #b9b9b9; }
.am-frame { background: #62d6e8; color: #000; padding: 0 6px; border-radius: 2px; }
.stage > .panel { background: #2f2f2f; border-color: #111; border-radius: 0; }
.stage .info-bar { background: #3a3a3a; color: #e6e6e6; border-top-color: #111; }
.studio { background: #1b1b1b; }
.chatbox { background: #232323; border-right-color: #3c3c3c; }
.cl.you::before { color: #ffa53c; }
.cl.model { color: #e2e2e2; }
.cl.tool { color: #95db95; border-left-color: #3f5f3f; }
.cl.tool span { color: #8c8c8c; }
.chat-status { border-top-color: #3c3c3c; color: #8c8c8c; }
.chat-input { background: #353535; }
.studiobox { background: #1e1e1e; }
.studio-mark { color: #505050; }
@media (max-width: 860px) { .chatbox { border-bottom-color: #3c3c3c; } }
@media (max-width: 560px) { .story .beat-fig.panel { padding: 14px 14px 0; } }
.stage-head h2 .h2-zig { position: relative; display: inline-block; right: auto; top: auto; width: 0.85em; height: 0.95em; margin-left: 0.12em; vertical-align: -0.08em; }
.story .beat-fig .fit, .story .beat-fig .studio-extra { color: #000; }
@media (max-width: 560px) {
  .story .beat-fig > .panel-head { flex-wrap: wrap; gap: 10px; }
  .story .beat-fig > .panel-head .meta { flex-basis: 100%; }
  .hand-on { --hand-h: 18px; }
}
.chat-input { margin: 8px; }
.story .wt-bar { height: 22px; padding: 0 8px; }
@media (max-width: 560px) { .story .am-worlds { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* =====================================================================================
   Every other page: the same voice. One serif (Newsreader) for titles and reading text,
   square chips and windows, and figures staged like app shots on a flat colour.
   ===================================================================================== */
:root { --serif: "Newsreader", Georgia, serif; --lapis: var(--volt); }

/* Titles and section headings in the display serif */
.g-head h1, .pagehead h1, .principle h1, .head h1, .desk-page h1 {
  font-family: var(--display); font-weight: 400; letter-spacing: -0.045em; line-height: 0.95;
  font-size: clamp(56px, 8.4vw, 120px);
}
.g-sub { font-family: var(--display); font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -0.02em; line-height: 1.15; color: #000; }
.g-h {
  font-family: var(--display); font-weight: 400; letter-spacing: -0.04em; line-height: 0.98;
  font-size: clamp(40px, 5vw, 64px); max-width: 640px;
}
.nohead h2, .principle h2 {
  font-family: var(--display); font-weight: 400; letter-spacing: -0.045em; line-height: 0.96;
  font-size: clamp(44px, 6vw, 88px);
}
.pagehead p, .principle .lede p, .nohead p { color: #000; }
.h-zig { position: relative; display: inline-block; width: 0.8em; height: 0.9em; margin-left: 0.14em; vertical-align: -0.06em; color: #000; }

/* Contents list and the principle: flat pastel cards, no tint-on-tint */
.g-toc { background: var(--p-lime); border-radius: 0; padding: 16px 20px 18px; }
.g-toc h2 { color: #000; text-transform: uppercase; letter-spacing: 0.04em; font-size: 13px; }
.g-toc ol { font-family: var(--display); font-size: 19px; letter-spacing: -0.01em; line-height: 1.55; }
.g-toc a:hover { color: #000; }
.g-principle { background: var(--p-blue); border-left: 0; color: #000 !important; }
.g-principle b { color: #000; text-transform: uppercase; letter-spacing: 0.04em; }
.scrub { color: var(--volt); }
.scrub:hover, .scrub.on, .scrub:focus-visible { background: rgba(43, 20, 255, .1); }

/* Square, flat chips and windows everywhere */
.chip { border-radius: 0; }
.panel { border-radius: 0; }

/* ---------- Figures staged like app shots ---------- */
.stage-fig { --bk: #c47b5f; }
.g-row:nth-of-type(6n+2) .stage-fig, .nocase:nth-of-type(6n+2) .vnew, .principle:nth-of-type(6n+2) .stage-fig { --bk: #8c9a5c; }
.g-row:nth-of-type(6n+3) .stage-fig, .nocase:nth-of-type(6n+3) .vnew, .principle:nth-of-type(6n+3) .stage-fig { --bk: #7584d6; }
.g-row:nth-of-type(6n+4) .stage-fig, .nocase:nth-of-type(6n+4) .vnew, .principle:nth-of-type(6n+4) .stage-fig { --bk: #c9a23e; }
.g-row:nth-of-type(6n+5) .stage-fig, .nocase:nth-of-type(6n+5) .vnew, .principle:nth-of-type(6n+5) .stage-fig { --bk: #b47aa3; }
.g-row:nth-of-type(6n+6) .stage-fig, .nocase:nth-of-type(6n+6) .vnew, .principle:nth-of-type(6n+6) .stage-fig { --bk: #4f978f; }
.vold.stage-fig { --bk: #b9b4ab; }
.stage-fig {
  background: var(--bk); border-radius: 0;
  padding: clamp(16px, 2.6vw, 32px) clamp(16px, 2.6vw, 32px) 18px;
}
.stage-fig > figcaption, .vs2 .stage-fig > figcaption { color: #fff; font-size: 15px; line-height: 1.45; margin-top: 14px; }
.stage-fig > figcaption b, .vs2 .stage-fig figcaption b, .stage-fig > figcaption code { color: #fff; background: none; }
.stage-fig > figcaption::before { color: #fff !important; }
.vold.stage-fig > figcaption, .vold.stage-fig > figcaption b, .vold.stage-fig > figcaption::before { color: #000 !important; }
.stage-fig > .chip.side { background: #fff; color: #000; text-transform: uppercase; letter-spacing: 0.05em; font-size: 12px !important; }
/* A window on the colour: its frame dissolves, its name drops below as a hand-lettered caption */
.stage-fig > .panel { display: flex; flex-direction: column; background: none; border: 0; box-shadow: none; overflow: visible; }
.stage-fig.panel { display: flex; flex-direction: column; border: 0; box-shadow: none; overflow: visible; }
.stage-fig > .panel > .panel-head, .stage-fig.panel > .panel-head {
  order: 9; background: none; border: 0; min-height: 0; flex-wrap: nowrap; gap: 14px; padding: 14px 0 0; color: #fff;
}
.stage-fig .panel-head .chip { border: 0; font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; padding: 3px 8px; }
.stage-fig .panel-head .meta, .stage-fig .panel-head .ph-name { color: #fff; }
.stage-fig .panel-head .meta { flex: 1; min-width: 0; }
.stage-fig .panel-head .btn { background: #fff; border-color: #000; color: #000; }
.stage-fig > svg, .stage-fig > img { border: 0 !important; border-radius: 0 !important; }
.stage-fig > figcaption + figcaption { margin-top: 6px; }

/* Room: the photographs and the wall stay full bleed; only the windows are staged */
.stage-fig.panel > .info-bar { order: 10; }
.principle .stage-fig .info-bar { background: none; border: 0; color: #fff; padding: 14px 0 0; }

@media (max-width: 560px) {
  .stage-fig { padding: 14px 14px 14px; }
  .stage-fig > .panel > .panel-head, .stage-fig.panel > .panel-head { flex-wrap: wrap; gap: 10px; }
  .stage-fig .panel-head .meta { flex-basis: 100%; }
}
.g-fig svg.hand-art { width: auto; background: none; border: 0; border-radius: 0; }
.g-fig svg.scr { background: none; border: 0; }
.stage-fig .panel-head .spacer { display: none; }
.stage-fig .panel-head .ph-name { font-family: var(--sans); font-weight: 500; font-size: 14px; white-space: nowrap; }
.nw { white-space: nowrap; }
