/*
 * The public landing page.
 *
 * Its palette is not chosen, it is inherited: every colour below is lifted from
 * packages/ui/src/theme/themes/ruoc.json, the app's own light theme. The page
 * exists to show the app, and a marketing site in its own colours would put a
 * screenshot of one product inside a page for a different one — the seam shows
 * most at the exact place the eye goes first.
 *
 * The type is Inter for the same reason: it is what the app sets, so the
 * headline above the screenshot and the text inside it are one voice. Both
 * weights are vendored rather than pulled from Google, because the people this
 * page is for are in Russia and a font that fails to load takes the page's
 * character with it.
 */

@font-face {
  font-family: "Inter Vendored";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/inter-latin-400.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: "Inter Vendored";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/inter-cyrillic-400.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Inter Vendored";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/inter-latin-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: "Inter Vendored";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/inter-cyrillic-600.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Inter Vendored";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/inter-latin-800.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: "Inter Vendored";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/inter-cyrillic-800.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

:root {
  /* The app's neutral is #f4f1e9; the page sits one step deeper on the same
     scale so that a card in the app's true surface colour reads as raised
     rather than dissolving into the background. */
  --ground: #ebe7dc;
  --paper: #fffefc;
  --ink: #141413;
  --ink-2: #5d5b54;
  --ink-3: #7f7d74;
  --rule: #d6d2c6;
  --rule-weak: #e3dfd3;
  --accent: #d97757;
  --accent-deep: #c2410c;

  --serif: "Playfair Vendored", "Playfair Display", Georgia, "Times New Roman", serif;

  --measure: 1140px;
  --step: clamp(1.5rem, 4vw, 3rem);
}

/*
 * The display face. Playfair Display carries a full Cyrillic set, so
 * the Cyrillic headline and wordmark are drawn, not synthesised. Vendored
 * for the same reason Inter is: the page must not depend on a font CDN.
 */
@font-face {
  font-family: "Playfair Vendored";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/playfair-latin-700.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: "Playfair Vendored";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/playfair-cyrillic-700.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: "Inter Vendored", Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 var(--step);
}

/* ---- header ---------------------------------------------------------- */

.top {
  display: flex;
  align-items: center;
  padding: 1.75rem 0 0;
}

.mark {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.6rem;
  letter-spacing: -0.01em;
}

.mark-logo {
  width: 3.1rem;
  height: 3.1rem;
  display: block;
}

/* ---- hero ------------------------------------------------------------ */

.hero {
  padding: clamp(1rem, 3vw, 2rem) 0 0;
}

/* The first screen is the hero alone: the split fills the viewport under
   the wordmark, so the app demo begins only once the visitor scrolls. */
.hero-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  align-content: start;
  min-height: calc(100svh - 7.5rem);
}

.hero-slot,
.demo-slot {
  display: none;
}

@media (min-width: 62rem) {
  .hero-split {
    grid-template-columns: 1.05fr 0.95fr;
  }

  /* The window's first resting place: a compact, chat-only column. */
  .hero-slot {
    display: block;
    height: min(calc(100svh - 9rem), 40rem);
  }

  /* Stretches to the story's height: that span is the window's pinned range. */
  .demo-slot {
    display: block;
    align-self: stretch;
    min-height: 1px;
  }
}

.eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0 0 1.25rem;
}

h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.7rem, 7.5vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  font-weight: 700;
  max-width: 14ch;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem;
  margin-top: 2.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  font-size: 0.97rem;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-icn {
  width: 1.1rem;
  height: 1.1rem;
  flex-shrink: 0;
}

/* The Mac button carries a second line once release.js knows the version. */
.btn-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.btn-meta {
  display: none;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  opacity: 0.72;
}

.btn-meta.is-ready {
  display: block;
}

.cta-note {
  display: none;
  font-size: 0.87rem;
  color: var(--ink-3);
}

.cta-note.is-ready {
  display: inline;
}

.btn--solid {
  background: var(--ink);
  color: var(--paper);
}

.btn--solid:hover {
  background: var(--accent-deep);
}

.btn--quiet {
  border-color: var(--rule);
  color: var(--ink);
}

.btn--quiet:hover {
  border-color: var(--ink-3);
  background: var(--paper);
}

/* No Windows build is published yet: the button stays so the platform is
   visibly on the roadmap, but it is a label, not a link. */
.btn.is-soon {
  color: var(--ink-3);
  border-style: dashed;
  cursor: default;
}

/* ---- the signature: the app narrating its own step -------------------- */

/*
 * This is the one thing on the page that moves, and it is the product's most
 * characteristic artifact rather than decoration: the app replaces the single
 * word "думаю" with the step it is actually on, timed over the turn. The strip
 * cycles four real phrases and then settles on the summary the app shows when a
 * turn ends, which is exactly the sequence a user watches.
 */
.ribbon {
  margin-top: 2rem;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 1.1rem 0.7rem 0.9rem;
  background: var(--paper);
  border: 1px solid var(--rule-weak);
  border-radius: 12px;
  font-size: 0.94rem;
  color: var(--ink-2);
  min-height: 2.9rem;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
  animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.8); }
}

.steps {
  position: relative;
  display: grid;
}

/* Every phrase occupies the same cell, so the strip's width is the widest of
   them and the box never jumps as the text changes. */
.steps span {
  grid-area: 1 / 1;
  opacity: 0;
  animation: cycle 12s linear infinite;
}

.steps span:nth-child(1) { animation-delay: 0s; }
.steps span:nth-child(2) { animation-delay: 3s; }
.steps span:nth-child(3) { animation-delay: 6s; }
.steps span:nth-child(4) { animation-delay: 9s; }

/*
 * Four phrases, four delays, one twelve-second cycle: each is visible for a
 * clean quarter of it. The visible window has to run right up to where the next
 * one opens — an earlier cut at 23% left the strip empty for a third of every
 * cycle, which read as the app having stalled rather than as it working.
 */
@keyframes cycle {
  0% { opacity: 0; transform: translateY(4px); }
  2% { opacity: 1; transform: translateY(0); }
  25% { opacity: 1; transform: translateY(0); }
  27% { opacity: 0; transform: translateY(-4px); }
  100% { opacity: 0; transform: translateY(-4px); }
}

.steps .done {
  color: var(--ink-3);
}

@media (prefers-reduced-motion: reduce) {
  .dot { animation: none; }
  .steps span { animation: none; opacity: 0; }
  /* One phrase, held still, rather than a stack of four overlapping. */
  .steps span:nth-child(1) { opacity: 1; }
}

/* ---- the screenshot --------------------------------------------------- */

/*
 * Held in the app's own surface colour with a hairline, not floated on a drop
 * shadow: the window in the picture already has its own chrome, and a second
 * frame around it reads as two windows.
 */
/*
 * Wider than the text it follows, and deliberately: the prose is set to a
 * readable measure, and a screenshot held to that same measure renders the
 * app's own interface too small to read — which is the one thing this element
 * exists to do. It breaks out to the viewport rather than to the text column,
 * and stays inside the page gutter at every width.
 */
.demo {
  margin: clamp(1.5rem, 4vw, 2.5rem) 0 0;
  width: min(1440px, calc(100vw - 2 * var(--step)));
  margin-left: 50%;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
}

/*
 * The window is pinned and the story scrolls past it, the way a demo reel
 * plays beside its captions: each block, on reaching the middle of the
 * viewport, takes over the window and plays its own session (demo.js).
 */
@media (min-width: 62rem) {
  .demo {
    grid-template-columns: minmax(0, 2fr) minmax(15rem, 1fr);
    gap: clamp(2rem, 4vw, 4rem);
    align-items: start;
  }
}

.demo-stage {
  position: sticky;
  top: 1rem;
  z-index: 1;
}

/* Under stage.js the stage is fixed and sized per frame; the window fills it
   and the panes clip while their columns slide open. */
.is-choreo .demo-stage {
  position: fixed;
  z-index: 2;
}

.is-choreo .demo .app-window,
.is-choreo .app-window {
  aspect-ratio: auto;
  height: 100%;
}

.is-choreo .aw-side,
.is-choreo .aw-files {
  overflow: hidden;
  min-width: 0;
}

/* Taller than the app's own window: the conversation is the point here, and
   the played reply must stay in view above the composer. */
.demo .app-window {
  aspect-ratio: 16 / 9;
}

@media (max-width: 62rem) {
  .demo .app-window {
    box-shadow: 0 10px 28px -14px rgba(20, 20, 19, 0.35);
  }
}

.demo-story {
  padding-bottom: 15vh;
}

.scene {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0.4;
  transition: opacity 0.3s ease;
}

.scene.is-active {
  opacity: 1;
}

.scene h3 {
  margin: 0 0 0.6rem;
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.scene p {
  margin: 0;
  color: var(--ink-2);
  max-width: 34ch;
}

@media (max-width: 62rem) {
  .demo-stage { top: 0.75rem; }
  .demo-story { padding-top: 1rem; }
  .scene { min-height: 50vh; align-items: center; text-align: center; }
}

/* The Агент heading introduces the app demo, so it sits close to it. */
.app-intro {
  margin-top: clamp(3rem, 8vw, 5.5rem);
  text-align: center;
}

.app-intro h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3.2vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.01em;
}

/*
 * The window is not a screenshot but the interface rebuilt in HTML: same font
 * (Inter), same surface scale and syntax palette as the desktop app's own
 * theme (packages/ui/src/theme/themes/ruoc.json). Light only; one hairline
 * frame, since the window carries its own chrome. Locked to the proportions of
 * the app window (the screenshot it replaces was 2200x1064).
 */
.app-window {
  width: 100%;
  aspect-ratio: 2200 / 1064;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 12px;
  overflow: hidden;
  /* App type scale (packages/ui/src/styles/theme.css): small 13, base 14,
     large 16; weights 400/500; Inter throughout. */
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  --aw-icon: #8f8f8f;
}

/* icons rebuilt from packages/ui/src/components/icon.tsx (20x20, square caps) */
.awi {
  width: 16px; height: 16px; flex: none; display: block;
  fill: none; stroke: currentColor; stroke-width: 1.25;
  stroke-linecap: square; stroke-linejoin: round;
}
.awi.awi-fill { fill: currentColor; stroke: none; }
.awi.awi-sm { width: 13px; height: 13px; }
.awi.awi-btn {
  box-sizing: border-box; width: 24px; height: 24px; padding: 4.5px;
  border-radius: 6px; color: var(--aw-icon);
}

.aw-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 14px;
  background: var(--ground);
  border-bottom: 1px solid var(--rule-weak);
}
.aw-traffic { display: inline-flex; gap: 8px; }
.aw-traffic i { width: 12px; height: 12px; border-radius: 50%; display: block; }
.aw-traffic i:nth-child(1) { background: #ff5f56; }
.aw-traffic i:nth-child(2) { background: #ffbd2e; }
.aw-traffic i:nth-child(3) { background: #27c93f; }
.aw-app { font-weight: 500; font-size: 13px; color: var(--ink); letter-spacing: -0.01em; }
.aw-bar-sp { flex: 1; }

.aw-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 216px minmax(0, 1fr) 260px;
}
.aw-side, .aw-chat, .aw-files { min-height: 0; }
.aw-side, .aw-files { overflow-y: auto; }
@media (max-width: 60rem) {
  .aw-body { grid-template-columns: 184px minmax(0, 1fr); }
  .aw-files { display: none; }
}
@media (max-width: 40rem) {
  .app-window { aspect-ratio: auto; }
  .aw-body { grid-template-columns: 1fr; }
  .aw-side { display: none; }
  .aw-chat-body { height: 36vh; }
  .demo .app-window { aspect-ratio: auto; }
}

.aw-side { padding: 10px 8px; background: var(--paper); border-right: 1px solid var(--rule-weak); }
.aw-files { padding: 0; background: var(--paper); border-left: 1px solid var(--rule-weak); }

.aw-side-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 4px 8px 10px; color: var(--ink-2); font-weight: 500; font-size: 13px;
}

.aw-proj { margin-bottom: 1px; }
.aw-proj-row {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 6px 6px 8px; border-radius: 6px;
  font-size: 14px; font-weight: 500; color: var(--ink);
}
.aw-proj-row > span:first-child { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aw-proj-row { cursor: pointer; }
.aw-proj-row:hover, .aw-proj-row.aw-on { background: var(--ground); }
.aw-proj-ctl { display: inline-flex; align-items: center; gap: 1px; color: var(--aw-icon); opacity: 0.6; }
.aw-proj-ctl .awi { width: 15px; height: 15px; }

.aw-sess {
  display: flex; align-items: center; gap: 7px;
  margin: 1px 0; padding: 5px 8px 5px 26px; border-radius: 6px;
  font-size: 14px; font-weight: 400; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none;
}
.aw-sess { cursor: pointer; position: relative; }
/* the app marks a session with a hollow circle */
.aw-sess::before {
  content: ""; position: absolute; left: 12px; top: 50%; width: 5px; height: 5px;
  margin-top: -3.5px; border: 1px solid var(--ink-3); border-radius: 50%;
}
.aw-sess:hover { background: var(--ground); }
.aw-sess.aw-sess-on { background: #e0dccf; }

.aw-side-sub {
  margin: 16px 8px 4px; font-size: 11px; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--ink-3);
}
.aw-recent, .aw-settings {
  display: flex; align-items: center; gap: 8px; padding: 6px 8px;
  font-size: 13px; color: var(--ink-2); text-decoration: none;
}
.aw-recent .awi, .aw-settings .awi { width: 15px; height: 15px; color: var(--aw-icon); }
.aw-settings { margin-top: 12px; }

.aw-chat { display: flex; flex-direction: column; overflow: hidden; }
.aw-chat-head {
  display: flex; align-items: center; justify-content: space-between;
  height: 44px; padding: 0 10px 0 20px; border-bottom: 1px solid var(--rule-weak);
  font-weight: 500; font-size: 13px; color: var(--ink-2);
}
.aw-chat-body {
  flex: 1; min-height: 0; overflow-y: auto;
  padding: 22px 24px; display: flex; flex-direction: column; gap: 18px;
}
.aw-user {
  align-self: flex-end; background: var(--ground); border-radius: 14px;
  padding: 8px 14px; max-width: 68%; font-size: 15px; color: var(--ink);
}
.aw-thought { display: flex; align-items: center; gap: 3px; font-size: 14px; color: var(--ink-3); }
.aw-thought .awi { width: 13px; height: 13px; color: var(--aw-icon); }
.aw-thought b { color: var(--ink-2); font-weight: 500; margin: 0 6px 0 3px; }
.aw-thought span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aw-reply { max-width: 54ch; font-size: 15px; line-height: 1.5; color: var(--ink); }
.aw-reply code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 0.85em; font-weight: 500;
  color: #874128;
  background: color-mix(in srgb, var(--ink) 5%, var(--paper));
  box-shadow: inset 0 0 0 0.5px color-mix(in srgb, var(--ink) 14%, transparent);
  border-radius: 4px; padding: 1px 5px;
}
.aw-composer { margin: 0 16px 16px; border: 1px solid var(--rule); border-radius: 14px; padding: 12px 14px; }
.aw-input {
  color: var(--ink); font-size: 15px; padding-bottom: 12px; min-height: 2.6em;
  outline: none; cursor: text; white-space: pre-wrap; word-break: break-word;
}
.aw-input:empty::before { content: attr(data-placeholder); color: var(--ink-3); pointer-events: none; }
.aw-composer:focus-within { border-color: var(--ink-3); }
.aw-input.is-typing::after {
  content: ""; display: inline-block; width: 1px; height: 1em; margin-left: 1px;
  vertical-align: -0.15em; background: var(--ink); animation: aw-caret 1s steps(1) infinite;
}
@keyframes aw-caret { 50% { opacity: 0; } }

.aw-steps { display: flex; flex-direction: column; gap: 6px; }
.aw-step { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--ink-3); }
.aw-step-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); flex: none; }
.aw-step.is-live .aw-step-dot { animation: aw-pulse 1s ease-in-out infinite; }
.aw-step.is-done { color: var(--ink-2); }
.aw-step.is-done .aw-step-dot { background: var(--rule); }
@keyframes aw-pulse { 50% { opacity: 0.35; transform: scale(0.75); } }

.aw-result { font-size: 14px; font-weight: 500; color: var(--accent-deep); text-decoration: none; }
.aw-result:hover { text-decoration: underline; }
.aw-composer-row { display: flex; align-items: center; gap: 8px; }
.aw-composer-row .aw-cc-sp { flex: 1; }
.aw-pill {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 13px; color: var(--ink-2); white-space: nowrap;
}
.aw-pill .aw-spark { color: var(--accent); margin-right: 3px; font-size: 12px; }
.aw-pill .awi { color: var(--aw-icon); }
.aw-send {
  width: 28px; height: 28px; border-radius: 8px; border: 0; padding: 0; margin-left: 4px;
  background: #b9b6ad; color: var(--paper); cursor: pointer; font: inherit;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background-color 0.15s ease, transform 0.12s ease;
}
.aw-send.is-live, .aw-send:hover { background: var(--ink); }
.aw-send.is-pressed, .aw-send:active { transform: scale(0.88); }
.aw-send .awi { width: 15px; height: 15px; }

.aw-files-head, .aw-code-head {
  display: flex; align-items: center; justify-content: space-between;
  height: 36px; padding: 0 6px 0 12px;
  font-weight: 500; font-size: 13px; color: var(--ink-2);
}
.aw-hd-btns { display: inline-flex; gap: 2px; }

.aw-file {
  display: flex; align-items: center; gap: 9px; margin: 0 6px;
  padding: 5px 6px; border-radius: 6px; font-size: 13px; color: var(--ink); text-decoration: none;
  cursor: pointer;
}
.aw-file:hover, .aw-file.is-on { background: var(--ground); }
.aw-ic {
  width: 16px; height: 16px; border-radius: 3px; flex: none; color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 7.5px; font-weight: 700; letter-spacing: -0.04em;
}
.aw-ic.html { background: #e44d26; }
.aw-ic.js { background: #f0db4f; color: #2b2a20; }
.aw-ic.css { background: #2965f1; font-size: 10px; }
.aw-ic.md { background: #5b8def; font-size: 9px; text-transform: lowercase; }
.aw-ic.doc { background: #2b579a; font-size: 9px; }
.aw-ic.xls { background: #217346; font-size: 9px; }
.aw-ic.ppt { background: #d24726; font-size: 9px; }
.aw-ic.aud { background: #6b7280; font-size: 10px; }
.aw-ic.txt { background: #8a8f98; font-size: 10px; }
.aw-ic.img { background: #7c3aed; font-size: 6.5px; }

.aw-code[hidden] { display: none; }
.aw-code { margin: 8px; border: 1px solid var(--rule-weak); border-radius: 8px; overflow: hidden; }
.aw-code .aw-code-head { background: var(--ground); border-bottom: 1px solid var(--rule-weak); font-size: 12px; }
.aw-code-body {
  padding: 12px 10px; overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 12px; line-height: 1.8;
}
.aw-code-body .cl { white-space: pre; }
.aw-code-body .ln {
  display: inline-block; width: 1.3em; margin-right: 14px;
  color: var(--ink-3); text-align: right; user-select: none;
}
/* syntax colours = ruoc.json syntax-* (property teal, selector magenta, etc.) */
.aw-code-body .c-sel { color: #c83d8b; }
.aw-code-body .c-fn { color: #5230c2; }
.aw-code-body .c-prop { color: #12736b; }
.aw-code-body .c-num, .aw-code-body .c-str { color: #c2410c; }
.aw-code-body .c-punc { color: var(--ink-3); }

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

.foot {
  margin: clamp(3.5rem, 8vw, 5rem) 0 0;
  padding: 1.75rem 0 3rem;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
  font-size: 0.87rem;
  color: var(--ink-3);
}

.foot a {
  color: var(--ink-3);
  text-decoration: none;
}

.foot a:hover {
  color: var(--accent-deep);
}

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

@media (prefers-reduced-motion: reduce) {
  .aw-input.is-typing::after,
  .aw-step.is-live .aw-step-dot { animation: none; }
  .scene { transition: none; }
}
