/* Build Big with Bayzyl (/bayzyl): the pitch page for the Minecraft building toolkit and the clubs built on it.
   Its own face, from Sage's approved mockup: obsidian and lava at night, parchment and ember by day, Baloo 2 for
   display and Atkinson Hyperlegible for reading. Fonts are self-hosted (SIL OFL) so the page makes no third-party
   request. The product shell above the hero is the site's shared navigation and keeps its own colours. */
@font-face { font-family: 'Baloo 2'; font-style: normal; font-weight: 600 800; font-display: swap; src: url(/bayzyl/fonts/Baloo2.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-style: normal; font-weight: 400; font-display: swap; src: url(/bayzyl/fonts/Atkinson-400.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-style: normal; font-weight: 700; font-display: swap; src: url(/bayzyl/fonts/Atkinson-700.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-style: italic; font-weight: 400; font-display: swap; src: url(/bayzyl/fonts/Atkinson-400-italic.woff2) format('woff2'); }

:root {
  --bg: #15110f; --bg2: #1f1815; --card: #261d18; --line: #3a2c24;
  --fg: #f6ecdf; --muted: #c9b7a6; --accent: #ff7a1a; --glow: #ffc46b; --ok: #8fd694;
  --display: 'Baloo 2', 'Trebuchet MS', sans-serif;
  --body: 'Atkinson Hyperlegible', 'Helvetica Neue', Arial, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) { --bg: #fbf4ea; --bg2: #f3e8d8; --card: #fff8ef; --line: #e3d3bf; --fg: #241a14; --muted: #6b574a; --accent: #d8540a; --glow: #b4420a; --ok: #2e7d3a; color-scheme: light; }
}
:root[data-theme="light"] { --bg: #fbf4ea; --bg2: #f3e8d8; --card: #fff8ef; --line: #e3d3bf; --fg: #241a14; --muted: #6b574a; --accent: #d8540a; --glow: #b4420a; --ok: #2e7d3a; color-scheme: light; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-gutter: stable; }
body { background: var(--bg); color: var(--fg); font-family: var(--body); font-size: 17px; line-height: 1.55; margin: 0; }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(2.4rem, 7vw, 4.6rem); font-weight: 800; letter-spacing: -.01em; }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0; }
a { color: var(--glow); }
code { font-family: var(--mono); font-size: .92em; background: var(--bg2); border: 1px solid var(--line); border-radius: 6px; padding: .08em .4em; white-space: nowrap; }
.eyebrow { font-family: var(--display); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; font-size: .78rem; color: var(--accent); }
.wrap { max-width: 1100px; margin: 0 auto; padding-inline: 20px; }
section { padding-block: clamp(52px, 6vw, 84px); scroll-margin-top: 24px; }
section .eyebrow + h2 { margin-top: 8px; }
section h2 + .lead { margin-top: 16px; }
.lead { max-width: 62ch; color: var(--muted); font-size: 1.12rem; }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip:focus { position: fixed; top: 8px; left: 8px; z-index: 2; padding: 8px 12px; background: var(--accent); color: #15110f; }

/* hero */
.hero { position: relative; min-height: min(760px, 84vh); display: grid; align-items: end; isolation: isolate; overflow: hidden; }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(21, 17, 15, .3) 0%, rgba(21, 17, 15, .72) 55%, #15110f 100%); }
.hero .wrap { width: 100%; padding-block: 92px 56px; display: grid; gap: 20px; }
.hero h1 { max-width: 14ch; }
.hero h1 { color: #f6ecdf; }
.hero p { max-width: 56ch; font-size: 1.15rem; color: #f6ecdf; }
.hero .eyebrow { color: var(--glow); }
.hero-link { display: inline-flex; align-items: center; gap: 24px; justify-self: start; padding: 10px 0; margin-top: 4px; color: #ffc46b; font-weight: 700; text-decoration-thickness: 1px; text-underline-offset: 6px; }
.hero-link span { font-size: 1.4rem; line-height: 1; }
.hero-link:hover { color: #fff; }
.pill { display: inline-flex; gap: 8px; flex-wrap: wrap; }
.pill span { background: rgba(0, 0, 0, .45); color: #f6ecdf; border: 1px solid rgba(255, 196, 107, .3); border-radius: 4px; padding: 4px 10px; font-size: .82rem; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hero .eyebrow { color: #ffc46b; } }
:root[data-theme="light"] .hero .eyebrow { color: #ffc46b; }

/* features */
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin-top: 28px; }
.feat { display: grid; gap: 8px; min-width: 0; padding: 18px 0; border-top: 2px solid var(--line); align-content: start; }
.feat h3 { color: var(--glow); }
.feat p { color: var(--muted); }
.feat code { display: inline-block; margin-top: 4px; justify-self: start; }
.feat > code { max-width: 100%; overflow-x: auto; }

/* steps */
.steps { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 24px; counter-reset: step; }
.step { background: var(--bg2); border-radius: 14px; padding: 18px; display: grid; gap: 8px; align-content: start; }
.step::before { counter-increment: step; content: "Step " counter(step); font-family: var(--display); font-weight: 700; color: var(--accent); font-size: .9rem; letter-spacing: .08em; text-transform: uppercase; }
.band { background: var(--bg2); }
.band .step { background: var(--card); }
.band code { background: var(--card); }

/* The screenshots are the gallery: complete frames, without labels or crops. */
#gallery > .wrap { max-width: 1280px; }
.gallery-heading { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: end; padding-bottom: 30px; border-bottom: 1px solid var(--line); }
.gallery-heading h2 { max-width: 12ch; font-size: clamp(2.5rem, 4.8vw, 4.1rem); line-height: 1.02; letter-spacing: -.025em; }
.gallery-intro { padding-bottom: 4px; }
.gallery-intro .lead { max-width: 42ch; }
.viewer-hint { margin-top: 18px; color: var(--muted); font-size: .9rem; }
.gallery { display: grid; gap: 24px; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; margin-top: 32px; }
.gallery figure, .renders figure { margin: 0; min-width: 0; }
.gallery figure.wide { grid-column: 1 / -1; }
.image-link { position: relative; display: block; color: #fff; background: var(--bg2); border-radius: 4px; box-shadow: 0 0 0 1px var(--line); }
.image-link img { display: block; width: 100%; height: auto; max-width: 100%; border-radius: inherit; }
.image-link:hover { box-shadow: 0 0 0 1px var(--accent); }
.image-link:active { opacity: .9; }
.image-expand { position: absolute; right: 12px; bottom: 12px; display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(255, 255, 255, .35); border-radius: 3px; background: rgba(15, 12, 10, .78); }
.image-link:hover .image-expand, .image-link:focus-visible .image-expand { background: #15110f; color: #ffc46b; border-color: #ffc46b; }
.renders { display: grid; gap: 20px; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; margin-top: 20px; }
.renders .guide-render { grid-column: 1 / -1; width: min(100%, 860px); justify-self: center; margin-top: 8px; }
@media (max-width: 759px) {
  .hero .wrap { padding-block: 76px 40px; }
  .hero { min-height: 0; }
  .hero p { font-size: 1.06rem; }
  .gallery-heading { grid-template-columns: 1fr; gap: 24px; }
  .gallery-heading h2 { max-width: 16ch; }
  .gallery-intro .lead { max-width: 48ch; }
  .gallery, .renders { grid-template-columns: 1fr; gap: 20px; }
  .gallery { margin-top: 24px; }
  .renders .guide-render { margin-top: 0; }
  .image-expand { right: 8px; bottom: 8px; }
}

/* Native dialog keeps focus inside the viewer; links work without enhancement. */
html.bayzyl-viewer-open { overflow: hidden; }
body.bayzyl-viewer-open { position: fixed; top: var(--viewer-scroll-top); inset-inline: 0; overflow: hidden; }
.build-viewer { width: 100%; height: 100%; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: #100e0d; color: #f6ecdf; }
.build-viewer::backdrop { background: #100e0d; }
.viewer-shell { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; height: 100%; padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); gap: 12px; }
.viewer-header, .viewer-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-width: 0; }
.viewer-header h2 { font-family: var(--body); font-size: 1rem; font-weight: 400; letter-spacing: .02em; }
.viewer-controls { display: flex; align-items: center; gap: 12px; }
.viewer-button { display: inline-grid; place-items: center; flex: none; width: 48px; height: 48px; padding: 0; border: 1px solid #625346; border-radius: 4px; background: #211b17; color: #f6ecdf; cursor: pointer; }
.viewer-button:hover:not(:disabled) { border-color: #ffc46b; color: #ffc46b; }
.viewer-button:active:not(:disabled) { background: #3a2c24; }
.viewer-button:disabled { opacity: .35; cursor: default; }
.viewer-button:focus-visible, .viewer-full:focus-visible { outline-color: #ffc46b; }
.viewer-stage { position: relative; min-height: 0; display: grid; place-items: center; }
.viewer-stage img { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.viewer-stage img[hidden] { display: none; }
.viewer-status { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: #c9b7a6; pointer-events: none; }
.viewer-status:empty { display: none; }
.viewer-counter { min-width: 5ch; text-align: center; font-variant-numeric: tabular-nums; font-size: .95rem; }
.viewer-full { display: inline-flex; align-items: center; min-height: 44px; color: #c9b7a6; font-size: .9rem; text-underline-offset: 4px; }
.viewer-full:hover { color: #fff; }
@media (max-width: 479px) {
  .viewer-shell { gap: 8px; padding-inline: 12px; }
  .viewer-header h2 { font-size: .9rem; }
  .viewer-controls { gap: 8px; }
  .viewer-button { width: 44px; height: 44px; }
}
@media (prefers-reduced-motion: no-preference) {
  .image-link { transition: box-shadow .18s ease; }
  .image-expand { transition: background-color .18s ease, color .18s ease, border-color .18s ease; }
}

/* two-column */
.split { display: grid; gap: 28px; grid-template-columns: 1fr 1fr; margin-top: 28px; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 22px; display: grid; gap: 12px; min-width: 0; align-content: start; }
.panel ul { margin: 0; padding-left: 20px; display: grid; gap: 8px; color: var(--muted); }
.panel li strong { color: var(--fg); }

.note { margin-top: 18px; color: var(--muted); font-size: .95rem; max-width: 70ch; }

/* about */
.about { display: grid; gap: 20px; grid-template-columns: 1.2fr .8fr; align-items: start; margin-top: 24px; }
@media (max-width: 760px) { .about { grid-template-columns: 1fr; } }
.links { display: grid; gap: 8px; justify-items: start; }
.links a { font-weight: 700; text-decoration: none; border-bottom: 2px solid var(--accent); }

footer { padding-block: 36px 48px; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
footer .wrap { display: grid; gap: 10px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
