:root {
  color-scheme: light;
  --bg: #f7f8fb;
  --surface: #ffffff;
  --surface-soft: #f1f4f8;
  --surface-tint: #edf9f6;
  --panel: #ffffff;
  --panel-2: #f7fafc;
  --text: #172033;
  --muted: #5d6878;
  --soft: #8792a2;
  --line: #e3e8ef;
  --line-strong: #ccd5e1;
  --red: #e84f4f;
  --gold: #f0b53f;
  --green: #16a36f;
  --teal: #14b8a6;
  --blue: #4f7cff;
  --ink: #111827;
  --shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
  --shadow-hover: 0 18px 44px rgba(15, 23, 42, 0.13);
  --body-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88) 0%, rgba(247, 248, 251, 0.94) 34%, #f7f8fb 100%),
    linear-gradient(135deg, rgba(20, 184, 166, 0.08), rgba(79, 124, 255, 0.06) 42%, rgba(240, 181, 63, 0.07));
  --topbar-bg: rgba(255, 255, 255, 0.84);
  --topbar-border: rgba(226, 232, 240, 0.9);
  --topbar-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
  --sidebar-bg: rgba(255, 255, 255, 0.88);
  --input-bg: #ffffff;
  --input-focus-bg: #ffffff;
  --toc-hover-bg: #f1f5fb;
  --band-bg: rgba(255, 255, 255, 0.62);
  --band-border: rgba(226, 232, 240, 0.7);
  --code-border: rgba(79, 124, 255, 0.16);
  --code-bg: rgba(79, 124, 255, 0.08);
  --code-text: #2851c7;
  --pre-bg: #111827;
  --pre-text: #eef6ff;
  --table-head-text: #334155;
  --table-cell-bg: rgba(255, 255, 255, 0.72);
  --table-hover-bg: #f7fbff;
  --card-bg: rgba(255, 255, 255, 0.92);
  --card-hover-bg: #ffffff;
  --command-bg: rgba(248, 250, 252, 0.88);
  --command-hover-bg: #ffffff;
  --notice-bg: #fff8e9;
  --notice-text: #7a4d08;
  --summary-text: #253047;
  --theme-track-bg: #f1f5fb;
  --theme-track-border: #dbe4ef;
  --theme-button-text: #5d6878;
  --theme-active-bg: #172033;
  --theme-active-text: #ffffff;
  --tag-bg: #eefaf6;
  --tag-hover-bg: #e2f8f1;
  --tag-text: #13795b;
  --hero-border: rgba(226, 232, 240, 0.78);
  --radius: 8px;
  --content: minmax(0, 1120px);
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f172a;
  --surface: #151f2e;
  --surface-soft: #202b3c;
  --surface-tint: #102c2d;
  --panel: #151f2e;
  --panel-2: #101827;
  --text: #eef4ff;
  --muted: #adbacd;
  --soft: #8190a8;
  --line: #2b394d;
  --line-strong: #3f5169;
  --ink: #f8fafc;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
  --shadow-hover: 0 20px 48px rgba(0, 0, 0, 0.36);
  --body-bg:
    linear-gradient(180deg, #0f172a 0%, #111827 48%, #0b1120 100%),
    linear-gradient(135deg, rgba(20, 184, 166, 0.12), rgba(79, 124, 255, 0.12) 42%, rgba(240, 181, 63, 0.06));
  --topbar-bg: rgba(15, 23, 42, 0.86);
  --topbar-border: rgba(51, 65, 85, 0.9);
  --topbar-shadow: 0 1px 0 rgba(255, 255, 255, 0.03);
  --sidebar-bg: rgba(17, 24, 39, 0.9);
  --input-bg: #0b1220;
  --input-focus-bg: #111827;
  --toc-hover-bg: #1d293b;
  --band-bg: rgba(15, 23, 42, 0.56);
  --band-border: rgba(51, 65, 85, 0.76);
  --code-border: rgba(96, 165, 250, 0.24);
  --code-bg: rgba(96, 165, 250, 0.13);
  --code-text: #93c5fd;
  --pre-bg: #080d16;
  --pre-text: #eaf3ff;
  --table-head-text: #d9e5ff;
  --table-cell-bg: rgba(17, 24, 39, 0.66);
  --table-hover-bg: #172236;
  --card-bg: rgba(22, 31, 46, 0.92);
  --card-hover-bg: #1d293b;
  --command-bg: rgba(12, 18, 31, 0.82);
  --command-hover-bg: #111c2e;
  --notice-bg: rgba(245, 185, 63, 0.12);
  --notice-text: #ffe7aa;
  --summary-text: #eef4ff;
  --theme-track-bg: #111827;
  --theme-track-border: #2b394d;
  --theme-button-text: #adbacd;
  --theme-active-bg: #eef4ff;
  --theme-active-text: #111827;
  --tag-bg: rgba(20, 184, 166, 0.12);
  --tag-hover-bg: rgba(20, 184, 166, 0.18);
  --tag-text: #5eead4;
  --hero-border: rgba(51, 65, 85, 0.78);
}

[data-theme="black"] {
  color-scheme: dark;
  --bg: #000000;
  --surface: #050505;
  --surface-soft: #0d0d0d;
  --surface-tint: #061211;
  --panel: #050505;
  --panel-2: #0a0a0a;
  --text: #f8fafc;
  --muted: #b5bdc9;
  --soft: #7f8792;
  --line: #222222;
  --line-strong: #363636;
  --ink: #ffffff;
  --shadow: 0 20px 58px rgba(0, 0, 0, 0.52);
  --shadow-hover: 0 24px 64px rgba(0, 0, 0, 0.64);
  --body-bg:
    linear-gradient(180deg, #000000 0%, #030303 44%, #000000 100%),
    linear-gradient(135deg, rgba(20, 184, 166, 0.08), rgba(79, 124, 255, 0.08) 46%, rgba(240, 181, 63, 0.04));
  --topbar-bg: rgba(0, 0, 0, 0.88);
  --topbar-border: rgba(38, 38, 38, 0.96);
  --topbar-shadow: 0 1px 0 rgba(255, 255, 255, 0.04);
  --sidebar-bg: rgba(5, 5, 5, 0.9);
  --input-bg: #000000;
  --input-focus-bg: #050505;
  --toc-hover-bg: #101010;
  --band-bg: rgba(255, 255, 255, 0.025);
  --band-border: rgba(38, 38, 38, 0.92);
  --code-border: rgba(45, 212, 191, 0.24);
  --code-bg: rgba(45, 212, 191, 0.1);
  --code-text: #5eead4;
  --pre-bg: #030303;
  --pre-text: #f8fafc;
  --table-head-text: #e5e7eb;
  --table-cell-bg: rgba(5, 5, 5, 0.72);
  --table-hover-bg: #0d0d0d;
  --card-bg: rgba(5, 5, 5, 0.92);
  --card-hover-bg: #0d0d0d;
  --command-bg: rgba(0, 0, 0, 0.78);
  --command-hover-bg: #0a0a0a;
  --notice-bg: rgba(245, 185, 63, 0.1);
  --notice-text: #ffe7aa;
  --summary-text: #f8fafc;
  --theme-track-bg: #050505;
  --theme-track-border: #2a2a2a;
  --theme-button-text: #b5bdc9;
  --theme-active-bg: #f8fafc;
  --theme-active-text: #000000;
  --tag-bg: rgba(45, 212, 191, 0.1);
  --tag-hover-bg: rgba(45, 212, 191, 0.16);
  --tag-text: #5eead4;
  --hero-border: rgba(38, 38, 38, 0.92);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--body-bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

img,
svg {
  max-width: 100%;
}

code,
pre {
  font-family: "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

code {
  padding: 0.12rem 0.32rem;
  border: 1px solid var(--code-border);
  border-radius: 6px;
  background: var(--code-bg);
  color: var(--code-text);
  font-size: 0.92em;
  overflow-wrap: anywhere;
}

pre {
  position: relative;
  margin: 1rem 0;
  padding: 1rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--pre-bg);
  color: var(--pre-text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), var(--shadow);
}

pre code {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 0.88rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

th,
td {
  padding: 0.85rem 0.9rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--table-head-text);
  font-size: 0.78rem;
  letter-spacing: 0;
  text-transform: uppercase;
  background: var(--surface-soft);
}

td {
  color: var(--muted);
  background: var(--table-cell-bg);
}

td:first-child {
  color: var(--text);
}

tbody tr {
  transition: background-color 160ms var(--ease);
}

tbody tr:hover td {
  background: var(--table-hover-bg);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  padding: 0.7rem 1rem;
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  font-weight: 800;
  transition: top 180ms var(--ease), transform 180ms var(--ease);
}

.skip-link:focus {
  top: 1rem;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 64px;
  padding: 0.65rem clamp(1rem, 4vw, 2rem);
  gap: 1rem;
  border-bottom: 1px solid var(--topbar-border);
  background: var(--topbar-bg);
  backdrop-filter: blur(18px) saturate(1.2);
  box-shadow: var(--topbar-shadow);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  text-decoration: none;
  transition: transform 180ms var(--ease), opacity 180ms var(--ease);
}

.brand:hover {
  transform: translateY(-1px);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(79, 124, 255, 0.18);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fff4c7 0%, #f7b955 46%, #14b8a6 100%);
  color: #152033;
  font-size: 0.78rem;
  font-weight: 900;
  box-shadow: 0 10px 24px rgba(240, 181, 63, 0.25);
}

.brand strong,
.brand small {
  display: block;
  line-height: 1.15;
}

.brand small {
  color: var(--muted);
  font-size: 0.78rem;
}

.top-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-left: auto;
}

.top-links a,
.button,
.icon-button,
.command-row button,
.copy-pre {
  min-height: 38px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  transition:
    background-color 180ms var(--ease),
    border-color 180ms var(--ease),
    box-shadow 180ms var(--ease),
    color 180ms var(--ease),
    transform 180ms var(--ease);
}

.top-links a {
  padding: 0.45rem 0.75rem;
  color: var(--muted);
}

.top-links a:hover {
  color: var(--text);
  background: var(--surface-soft);
  transform: translateY(-1px);
}

.icon-button {
  display: none;
  width: 42px;
  padding: 0;
  background: var(--surface);
  border-color: var(--line);
  color: var(--text);
  box-shadow: var(--shadow);
}

.theme-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.18rem;
  flex: 0 0 auto;
  margin-left: auto;
  padding: 0.22rem;
  border: 1px solid var(--theme-track-border);
  border-radius: var(--radius);
  background: var(--theme-track-bg);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
}

.theme-switcher button {
  min-height: 32px;
  padding: 0 0.62rem;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--theme-button-text);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 850;
  transition:
    background-color 180ms var(--ease),
    color 180ms var(--ease),
    box-shadow 180ms var(--ease),
    transform 180ms var(--ease);
}

.theme-switcher button:hover {
  color: var(--text);
  transform: translateY(-1px);
}

.theme-switcher button[aria-pressed="true"] {
  background: var(--theme-active-bg);
  color: var(--theme-active-text);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: currentColor;
}

.page-shell {
  display: grid;
  grid-template-columns: 292px var(--content);
  gap: clamp(1rem, 3vw, 2.25rem);
  align-items: start;
  width: min(1480px, calc(100% - 2rem));
  margin: 0 auto;
}

.sidebar {
  position: sticky;
  top: 84px;
  max-height: calc(100vh - 104px);
  padding: 0.9rem;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--sidebar-bg);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.search-box label {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--table-head-text);
  font-weight: 900;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0;
}

.search-box input {
  width: 100%;
  min-height: 42px;
  padding: 0 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--input-bg);
  color: var(--text);
  outline: none;
  transition: border-color 180ms var(--ease), box-shadow 180ms var(--ease), background-color 180ms var(--ease);
}

.search-box input:focus {
  border-color: var(--blue);
  background: var(--input-focus-bg);
  box-shadow: 0 0 0 4px rgba(79, 124, 255, 0.12);
}

#search-status {
  min-height: 1.2rem;
  margin: 0.45rem 0 0.7rem;
  color: var(--soft);
  font-size: 0.82rem;
}

.toc {
  display: grid;
  gap: 0.14rem;
}

.toc a {
  position: relative;
  padding: 0.48rem 0.6rem;
  border-radius: 6px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 750;
  transition: background-color 180ms var(--ease), color 180ms var(--ease), transform 180ms var(--ease);
}

.toc a::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  border-radius: 999px;
  background: var(--blue);
  opacity: 0;
  transform: scaleY(0.3);
  transition: opacity 180ms var(--ease), transform 180ms var(--ease);
}

.toc a:hover,
.toc a.active {
  color: var(--text);
  background: var(--toc-hover-bg);
  transform: translateX(2px);
}

.toc a:hover::before,
.toc a.active::before {
  opacity: 1;
  transform: scaleY(1);
}

.content {
  min-width: 0;
}

.doc-section {
  scroll-margin-top: 86px;
  padding: clamp(2.2rem, 5vw, 4.2rem) 0;
}

.band {
  position: relative;
}

.band::before {
  content: "";
  position: absolute;
  inset: 0 -100vw;
  z-index: -1;
  background: var(--band-bg);
  border-block: 1px solid var(--band-border);
}

.hero {
  position: relative;
  min-height: min(640px, calc(100vh - 84px));
  padding: clamp(4rem, 8vw, 7rem) clamp(1rem, 4vw, 3rem);
  overflow: hidden;
  border: 1px solid var(--hero-border);
  border-top: 0;
  border-radius: 0 0 var(--radius) var(--radius);
  background: #111827;
  color: #fff;
  box-shadow: var(--shadow);
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.01);
  transition: transform 700ms var(--ease), filter 700ms var(--ease);
}

.hero:hover .hero-image {
  transform: scale(1.035);
  filter: saturate(1.08);
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.72) 42%, rgba(15, 23, 42, 0.22)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.86), transparent 42%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
}

.hero h1 {
  color: #fff;
}

.hero .eyebrow {
  color: #f8c65d;
}

.eyebrow {
  margin: 0 0 0.55rem;
  color: #be7f12;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.08;
  letter-spacing: 0;
}

h1 {
  max-width: 12ch;
  font-size: 5.8rem;
}

h2 {
  font-size: 3.25rem;
}

h3 {
  margin-bottom: 0.75rem;
  color: var(--text);
  font-size: 1.14rem;
}

p {
  color: var(--muted);
}

.lead {
  max-width: 680px;
  margin: 1rem 0 0;
  color: #eef6ff;
  font-size: 1.22rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 0.92rem;
}

.button.primary {
  border-color: transparent;
  background: linear-gradient(135deg, #f8c65d 0%, #f2ad34 100%);
  color: #172033;
  box-shadow: 0 14px 28px rgba(240, 181, 63, 0.23);
}

.button.secondary {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  backdrop-filter: blur(10px);
}

.button:hover,
.command-row button:hover,
.copy-pre:hover {
  transform: translateY(-2px);
}

.button.primary:hover {
  box-shadow: 0 18px 36px rgba(240, 181, 63, 0.31);
}

.button.secondary:hover {
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.18);
}

.hero-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
  width: min(900px, 100%);
  margin: 2rem 0 0;
}

.hero-facts div,
.info-grid article,
.config-grid article,
.timeline article,
.placeholder-groups article,
.safe-grid article,
.setup-panel,
.notice,
.details,
.troubleshooting details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card-bg);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
  transition:
    border-color 180ms var(--ease),
    box-shadow 180ms var(--ease),
    transform 180ms var(--ease),
    background-color 180ms var(--ease);
}

.info-grid article:hover,
.config-grid article:hover,
.placeholder-groups article:hover,
.safe-grid article:hover,
.timeline article:hover,
.setup-panel:hover,
.details:hover,
.troubleshooting details:hover {
  border-color: rgba(79, 124, 255, 0.3);
  background: var(--card-hover-bg);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.hero-facts div {
  min-height: 92px;
  padding: 0.85rem;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(14px);
}

.hero-facts dt {
  color: #c7d2fe;
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.hero-facts dd {
  margin: 0.24rem 0 0;
  color: #fff;
  font-weight: 900;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 1.5rem;
}

.section-heading p:last-child {
  margin-bottom: 0;
  font-size: 1.03rem;
}

.info-grid,
.config-grid,
.placeholder-groups,
.safe-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.config-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.placeholder-groups {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.safe-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.info-grid article,
.config-grid article,
.placeholder-groups article,
.safe-grid article,
.timeline article {
  padding: 1rem;
}

.config-grid article p,
.info-grid article p,
.placeholder-groups article p,
.timeline article p {
  margin: 0;
}

.two-column {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
}

.setup-flow {
  display: grid;
  gap: 0.8rem;
  margin: 0;
  padding: 0;
  counter-reset: setup;
  list-style: none;
}

.setup-flow li {
  display: grid;
  gap: 0.45rem;
  padding: 1rem 1rem 1rem 4rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  background: var(--card-bg);
  position: relative;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
  transition: border-color 180ms var(--ease), box-shadow 180ms var(--ease), transform 180ms var(--ease);
}

.setup-flow li:hover {
  border-color: rgba(240, 181, 63, 0.45);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.setup-flow li::before {
  counter-increment: setup;
  content: counter(setup);
  position: absolute;
  left: 1rem;
  top: 1rem;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--gold);
  color: var(--ink);
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(240, 181, 63, 0.24);
}

.compact-list,
.check-list {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--muted);
}

.compact-list li + li,
.check-list li + li {
  margin-top: 0.45rem;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
}

.setup-panel {
  padding: 1rem;
  margin-top: 1rem;
}

.command-list,
.command-grid {
  display: grid;
  gap: 0.55rem;
}

.command-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.command-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(180px, 1fr) auto;
  gap: 0.65rem;
  align-items: center;
  min-height: 54px;
  padding: 0.55rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--command-bg);
  transition: border-color 180ms var(--ease), box-shadow 180ms var(--ease), transform 180ms var(--ease), background-color 180ms var(--ease);
}

.command-row:hover {
  border-color: rgba(20, 184, 166, 0.35);
  background: var(--command-hover-bg);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.command-grid .command-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.command-row span {
  color: var(--muted);
  font-size: 0.92rem;
}

.command-row button,
.copy-pre {
  padding: 0.45rem 0.65rem;
  border-color: rgba(20, 184, 166, 0.28);
  background: rgba(20, 184, 166, 0.1);
  color: #0f766e;
  cursor: pointer;
}

.command-row button:hover,
.copy-pre:hover {
  border-color: rgba(20, 184, 166, 0.45);
  background: rgba(20, 184, 166, 0.16);
}

.copy-pre {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  min-height: 32px;
  font-size: 0.78rem;
}

.notice {
  padding: 1rem;
  margin-top: 1rem;
  border-color: rgba(245, 185, 63, 0.35);
  background: var(--notice-bg);
  color: var(--notice-text);
}

.details,
.troubleshooting details {
  padding: 0.9rem 1rem;
  margin-top: 1rem;
}

.details summary,
.troubleshooting summary {
  cursor: pointer;
  color: var(--summary-text);
  font-weight: 900;
  transition: color 180ms var(--ease);
}

.details summary:hover,
.troubleshooting summary:hover {
  color: var(--blue);
}

.timeline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.timeline article span {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.75rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--teal));
  color: #fff;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(79, 124, 255, 0.24);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1rem;
}

.tag-cloud span {
  padding: 0.38rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--tag-bg);
  color: var(--tag-text);
  font-size: 0.86rem;
  font-weight: 800;
  transition: border-color 180ms var(--ease), transform 180ms var(--ease), background-color 180ms var(--ease);
}

.tag-cloud span:hover {
  border-color: rgba(20, 184, 166, 0.34);
  background: var(--tag-hover-bg);
  transform: translateY(-1px);
}

.troubleshooting {
  display: grid;
  gap: 0.65rem;
}

.footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--line);
  color: var(--soft);
}

.footer p {
  margin: 0.25rem 0;
}

.reveal-target {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 520ms var(--ease), transform 520ms var(--ease);
}

.reveal-target.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.is-hidden {
  display: none !important;
}

.mark {
  background: rgba(245, 185, 63, 0.18);
}

@media (max-width: 1180px) {
  .page-shell {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 4.3rem;
  }

  h2 {
    font-size: 2.75rem;
  }

  .sidebar {
    position: fixed;
    inset: 64px 1rem auto 1rem;
    z-index: 9;
    max-height: calc(100vh - 88px);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-120%);
    transition: opacity 180ms var(--ease), transform 180ms var(--ease);
  }

  .sidebar.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .icon-button {
    display: inline-block;
  }

  .top-links {
    display: none;
  }
}

@media (max-width: 900px) {
  .hero {
    min-height: 620px;
  }

  h1 {
    font-size: 3.25rem;
    line-height: 1;
  }

  h2 {
    font-size: 2.35rem;
  }

  .lead {
    font-size: 1.1rem;
  }

  .hero-shade {
    background:
      linear-gradient(180deg, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.96)),
      linear-gradient(90deg, rgba(15, 23, 42, 0.4), transparent);
  }

  .hero-facts,
  .info-grid,
  .config-grid,
  .placeholder-groups,
  .safe-grid,
  .two-column,
  .timeline,
  .command-grid {
    grid-template-columns: 1fr;
  }

  .command-row,
  .command-grid .command-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 540px) {
  body {
    font-size: 15px;
  }

  .topbar {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.55rem;
    padding-inline: 0.75rem;
    justify-content: normal;
    width: 100vw;
    max-width: 100vw;
    overflow: hidden;
  }

  .brand {
    grid-column: 1;
    gap: 0.55rem;
    padding-right: 3rem;
  }

  .brand strong {
    white-space: nowrap;
  }

  .brand small {
    display: none;
  }

  .theme-switcher button {
    width: auto;
    min-width: 0;
    padding: 0;
    font-size: 0.78rem;
  }

  .theme-switcher {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-column: 1 / -1;
    grid-row: 2;
    margin-left: 0;
    width: 300px;
    max-width: calc(100vw - 1.5rem);
    min-width: 0;
    justify-self: start;
  }

  .icon-button {
    position: absolute;
    top: 0.75rem;
    left: 10rem;
    right: auto;
    display: inline-grid !important;
    place-items: center;
    flex: 0 0 38px;
    width: 38px;
  }

  .sidebar {
    inset: 112px 0.75rem auto 0.75rem;
    max-height: calc(100vh - 128px);
  }

  .page-shell {
    width: min(1480px, calc(100% - 1rem));
    max-width: calc(100vw - 1rem);
    display: block;
  }

  .content,
  .doc-section,
  .section-heading {
    width: 100%;
    max-width: calc(100vw - 1rem);
    min-width: 0;
  }

  .hero {
    padding-inline: 0.75rem;
    min-height: 640px;
    max-width: calc(100vw - 1rem);
  }

  .hero-copy {
    width: 21rem;
    max-width: 100%;
    min-width: 0;
  }

  h1 {
    max-width: 100%;
    font-size: 2.45rem;
    line-height: 1;
    overflow-wrap: anywhere;
  }

  h2 {
    font-size: 2rem;
    line-height: 1.05;
  }

  .lead {
    width: 20.5rem;
    max-width: 100%;
    font-size: 1rem;
  }

  .section-heading p {
    width: 21rem;
    max-width: 100%;
  }

  p,
  li,
  dd {
    overflow-wrap: anywhere;
  }

  .hero-actions {
    display: grid;
    width: 100%;
    max-width: 100%;
  }

  .button {
    width: 100%;
  }

  .setup-flow li {
    padding-left: 1rem;
    padding-top: 3.4rem;
  }

  .setup-flow li::before {
    top: 0.9rem;
  }
}

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

  .reveal-target {
    opacity: 1;
    transform: none;
  }
}
