/* Frame Labs Studio: the inner pages over the paper scene (/work, /services, /services/seo-geo, /process, /about, /contact,
   /company, /privacy, their /en/ mirrors and 404.html). Load after site.css and page.css; nothing here touches the home page.
   An inner page (tools/build_pages.py): <body data-scene="NAME">, the home page's frame, then <main class="inner side-SIDE">
   with the title block in the sky (.title-block) and one column of cut-card sheets (.sheets > .sheet). The parts and their
   markup: handoff/site/COMPONENTS.md. */

/* ---------- the instant still of each page's view (assets/proto/art-green/still-<scene>-desk.webp, -phone.webp:
   tools/green/stills.py; the autumn look's in art/;
   the head script preloads the same file). Without WebGL it is the page's background (#scene.nogl). ---------- */
body[data-scene="work"] #scene::after, body[data-scene="work"] #scene.nogl { background-image: url(../art-green/still-work-desk.webp); }
body[data-scene="services"] #scene::after, body[data-scene="services"] #scene.nogl { background-image: url(../art-green/still-services-desk.webp); }
body[data-scene="seo-geo"] #scene::after, body[data-scene="seo-geo"] #scene.nogl { background-image: url(../art-green/still-seo-geo-desk.webp); }
body[data-scene="process"] #scene::after, body[data-scene="process"] #scene.nogl { background-image: url(../art-green/still-process-desk.webp); }
body[data-scene="about"] #scene::after, body[data-scene="about"] #scene.nogl { background-image: url(../art-green/still-about-desk.webp); }
body[data-scene="contact"] #scene::after, body[data-scene="contact"] #scene.nogl { background-image: url(../art-green/still-contact-desk.webp); }
body[data-scene="quiet"] #scene::after, body[data-scene="quiet"] #scene.nogl { background-image: url(../art-green/still-quiet-desk.webp); }
body[data-scene="lot"] #scene::after, body[data-scene="lot"] #scene.nogl { background-image: url(../art-green/still-lot-desk.webp); }
@media (max-aspect-ratio: 3899/5000) {
  body[data-scene="work"] #scene::after, body[data-scene="work"] #scene.nogl { background-image: url(../art-green/still-work-phone.webp); }
  body[data-scene="services"] #scene::after, body[data-scene="services"] #scene.nogl { background-image: url(../art-green/still-services-phone.webp); }
  body[data-scene="seo-geo"] #scene::after, body[data-scene="seo-geo"] #scene.nogl { background-image: url(../art-green/still-seo-geo-phone.webp); }
  body[data-scene="process"] #scene::after, body[data-scene="process"] #scene.nogl { background-image: url(../art-green/still-process-phone.webp); }
  body[data-scene="about"] #scene::after, body[data-scene="about"] #scene.nogl { background-image: url(../art-green/still-about-phone.webp); }
  body[data-scene="contact"] #scene::after, body[data-scene="contact"] #scene.nogl { background-image: url(../art-green/still-contact-phone.webp); }
  body[data-scene="quiet"] #scene::after, body[data-scene="quiet"] #scene.nogl { background-image: url(../art-green/still-quiet-phone.webp); }
  body[data-scene="lot"] #scene::after, body[data-scene="lot"] #scene.nogl { background-image: url(../art-green/still-lot-phone.webp); }
  body[data-scene] #scene.nogl { background-position: 50% 55%; }
}
/* the autumn look (?look=autumn: site.css html.look-autumn): the head script sets --still-autumn to the still it
   preloads from art/ */
html.look-autumn body[data-scene] #scene::after, html.look-autumn body[data-scene] #scene.nogl { background-image: var(--still-autumn); }

/* ---------- the title block: the page's title and one line in the sky, as the home page's hero. It fills the first
   screen, so the scene's subject stands clear below it; the sheets come after. On the quiet pages (text first) it is
   shorter and the first sheet starts on the first screen. ---------- */
.title-block { position: relative; display: flex; justify-content: center; align-items: flex-start; min-height: 100vh; min-height: 100svh;
  padding: max(12vh, 112px) clamp(18px, 5vw, 88px) 0; text-align: center; }
body[data-scene="quiet"] .title-block { min-height: 52vh; min-height: 52svh; padding-bottom: 40px; }
.title-in { position: relative; max-width: 860px; }
/* a soft light with no edge behind the words keeps them clear of any cloud (the hero's) */
.title-in::before { content: ""; position: absolute; inset: -16% -12%; z-index: -1; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(247, 248, 242, .8), rgba(247, 248, 242, .45) 60%, rgba(247, 248, 242, 0)); }
html.look-autumn .title-in::before { background: radial-gradient(closest-side, rgba(250, 245, 236, .8), rgba(250, 245, 236, .45) 60%, rgba(250, 245, 236, 0)); }
.title-block h1 { margin: 0; font: 600 clamp(32px, min(3.8vw, 5.8vh), 54px)/1.26 var(--font); letter-spacing: -.02em; color: var(--ink); text-wrap: balance; }
.title-block .line { margin: 16px auto 0; max-width: 34em; font: 400 clamp(17px, 1.4vw, 20px)/1.6 var(--font); color: var(--text); text-wrap: balance; }
.title-block .cta { margin-top: 24px; }
/* a way back up (seo-geo: 서비스), above the title */
.crumb { margin: 0 0 6px; font: 600 16px/1.4 var(--font); }
.crumb a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; color: var(--accent-down); text-underline-offset: 5px; }
.crumb a:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 2px; }
/* a notice under the line (privacy: the policy is a draft): the chip's dark card */
.title-block .notice { display: inline-block; margin: 18px 0 0; padding: 6px 12px; border-radius: 2px; font: 600 16px/1.55 var(--font);
  color: var(--paper); background: rgba(35, 31, 28, .82); text-wrap: balance; }
/* the title on the right (tools/build_pages.py TITLE_SIDE: about, contact, seo-geo): the clinic and the page's piece take
   the left 55 % of the first screen (scenes.js), so the words sit over the open sky on the right, left-aligned, at most
   38 % of the window wide, with the same soft light. A phone keeps the centred title (below). */
.title-block.on-right { justify-content: flex-end; text-align: left; }
.title-block.on-right .title-in { width: min(38vw, 620px); }
.title-block.on-right .line { margin-left: 0; }
.title-block.on-right .cta { justify-content: flex-start; }
/* the dusk scenes (contact, seo-geo: scenes.js dusk 1 and .75; INT-GREEN): the title, its line and the way back up in
   paper cream on the deep sky, with no cream light behind them (it read as a pale patch). In its place a soft haze in
   the sky's own deep blue-green, blurred to no edge: on the sky it barely shows; where the desk's words cross the pale
   far town and mist it dims them, so the line keeps 4.5 to 1 and the title 3 to 1 (tools/green/contrast.py). The CSS
   sky under the canvas starts at the scene's own dusk, so the cream words never stand on the day sky before the scene
   draws. Daylight pages keep the ink title and its soft light. */
body[data-scene="contact"] #scene { --dusk: 1; }
body[data-scene="seo-geo"] #scene { --dusk: .75; }
body:is([data-scene="contact"], [data-scene="seo-geo"]) .title-in::before { inset: -56px -76px; border-radius: 76px;
  background: rgba(38, 80, 82, .76); filter: blur(38px); }
html.look-autumn body:is([data-scene="contact"], [data-scene="seo-geo"]) .title-in::before { background: rgba(58, 66, 92, .76); }
body:is([data-scene="contact"], [data-scene="seo-geo"]) .title-block :is(h1, .line),
body:is([data-scene="contact"], [data-scene="seo-geo"]) :is(.crumb, .crumb a) { color: var(--paper); }
body:is([data-scene="contact"], [data-scene="seo-geo"]) .crumb a:focus-visible { outline-color: var(--paper); }

/* ---------- the sheets: one column, about 760 px wide on the desk, on the side the scene's subject is not on ---------- */
.sheets { position: relative; display: flex; flex-direction: column; gap: 32px; width: min(760px, 100% - 2 * clamp(18px, 5vw, 88px));
  margin: 0 auto; padding-bottom: 48px; }
.side-left .sheets { margin-left: clamp(18px, 5vw, 88px); }
.side-right .sheets { margin-right: clamp(18px, 5vw, 88px); }
.sheets > .sheet { width: 100%; padding: 44px 48px 40px; scroll-margin-top: calc(var(--bar-h) + 16px); }
.sheets .sheet h2 { margin-bottom: 16px; }
.sheets .sheet h3 { margin: 30px 0 8px; font: 600 19px/1.45 var(--font); letter-spacing: -.005em; color: var(--ink); }
.sheets .sheet h2 + h3, .sheets .sheet .eyebrow + h3 { margin-top: 0; }
/* a working name's note after a brand (/company: 스피킹랩 가칭), as the parent page marks it: quieter than the name */
.sheets .sheet h3 .tag { margin-left: .35em; font-size: 15px; font-weight: 400; letter-spacing: .04em; color: var(--muted); }
/* line length: Korean about 45 characters, English about 68 */
.sheets .sheet p, .sheets .sheet li { max-width: 39em; }
html[lang="en"] .sheets .sheet p, html[lang="en"] .sheets .sheet li, .sheets [lang="en"] p { max-width: 68ch; }
.sheets .sheet a:not(.btn):not(.more) { color: var(--ink); text-decoration-color: var(--accent); text-underline-offset: 4px; }
.sheets .sheet a:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 2px; }
.sheets .sheet .cta { margin-top: 24px; }
.sheets .sheet .more { margin-top: 0; }
/* a small note: a caveat, the illustration note, a line under a table */
.sheets .sheet .note { font-size: 16px; line-height: 1.65; color: var(--muted); }
/* the closing call: the same sheet, its buttons on one row */
.sheets .next h2 { margin-bottom: 12px; }

/* ---------- lists: a plain list (paper squares) and a step list (numbered cut-card tabs; the numbers are CSS counters) ---------- */
.list { margin: 0 0 14px; padding: 0; list-style: none; }
.list > li { position: relative; margin: 0 0 8px; padding-left: 22px; }
.list > li::before { content: ""; position: absolute; left: 3px; top: .72em; width: 7px; height: 7px; border-radius: 1px; background: var(--accent); }
.steps { counter-reset: step; margin: 6px 0 14px; padding: 0; list-style: none; }
.steps > li { counter-increment: step; position: relative; min-height: 40px; margin: 0 0 22px; padding-left: 58px; }
.steps > li:last-child { margin-bottom: 0; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 40px; height: 40px;
  border-radius: 2px; font: 600 17px/1 var(--font); color: var(--ink); background: var(--grain), var(--face), var(--paper);
  box-shadow: var(--edge), 0 0 0 1px rgba(35, 31, 28, .12), var(--lift-small); }
.sheets .sheet .steps h3 { margin: 7px 0 4px; }
.steps p { margin: 0 0 6px; }
.steps > li > p:first-child { padding-top: 7px; }   /* a step with no heading: its first line level with the number */

/* ---------- a table: fees, hours, the company's details (two columns: what, and its value) ---------- */
.table { width: 100%; margin: 4px 0 16px; border-collapse: collapse; }
.table caption { padding: 0 0 10px; text-align: left; font-weight: 600; color: var(--ink); }
.table th, .table td { padding: 12px 0; text-align: left; vertical-align: top; border-top: 1px solid rgba(35, 31, 28, .13); }
.table tr:last-child > * { border-bottom: 1px solid rgba(35, 31, 28, .13); }
.table th { width: 42%; padding-right: 20px; font-weight: 600; color: var(--ink); }
.table td { overflow-wrap: anywhere; }
/* a link in a cell: a 44 px tall hit area without moving the row (padding taken back by the margin, as in the footer) */
.table td a { display: inline-block; padding: 10px 0; margin: -10px 0; }
.table .sub { display: block; margin-top: 2px; font-weight: 400; font-size: 16px; line-height: 1.6; color: var(--muted); }
/* a line left blank to be written on (the sample report's "next month") */
.table .blank { display: block; height: 1.75em; border-bottom: 1px solid rgba(35, 31, 28, .22); }

/* the privacy policy's clauses are numbered (CSS counters: the numbers are not page text) */
.sheets { counter-reset: clause; }
.sheet.clause { counter-increment: clause; }
.sheet.clause h2::before { content: counter(clause) ". "; color: var(--accent-down); }

/* ---------- a figure: a picture or a clip with its caption, in the sheet's text column ---------- */
.fig { margin: 22px 0; }
.fig:first-child { margin-top: 0; }
.fig picture, .fig img, .fig video { display: block; width: 100%; height: auto; }
.fig img, .fig video { border-radius: 2px; background: #EAE3D8; box-shadow: 0 0 0 1px rgba(35, 31, 28, .08), 0 1px 2px rgba(35, 31, 28, .12); }
.fig.narrow { max-width: 340px; }
.fig figcaption { margin-top: 10px; font-size: 16px; line-height: 1.6; color: var(--muted); }
.fig video:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

/* ---------- the contact form, its consent block and the notice that it does not send yet ---------- */
.form { display: grid; gap: 22px; margin: 4px 0 0; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; }
.field label, .choice legend { display: block; margin: 0 0 6px; padding: 0; font: 600 16px/1.5 var(--font); color: var(--ink); }
.req { margin-left: 6px; font-weight: 400; color: var(--muted); }
.field input, .field textarea { display: block; width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid rgba(35, 31, 28, .3); border-radius: 2px;
  font: 400 17px/1.5 var(--font); color: var(--ink); background: #fff; box-shadow: inset 1px 1px 2px rgba(35, 31, 28, .08); }
.field textarea { min-height: 128px; resize: vertical; }
/* form focus: the field's ring and edge in the accent (teal, 7.2:1 on white); the autumn look keeps its ink ring */
.field input:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
html.look-autumn .field input:focus-visible, html.look-autumn .field textarea:focus-visible { outline-color: var(--ink); border-color: rgba(35, 31, 28, .3); }
.field ::placeholder { color: #857C72; }
.choice { margin: 0; padding: 0; border: 0; min-width: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; padding: 0 14px 0 12px; border-radius: 2px; cursor: pointer;
  font-size: 16px; color: var(--ink); background: var(--grain), var(--face), var(--paper); box-shadow: var(--edge), 0 0 0 1px rgba(35, 31, 28, .16); }
.chip input { flex: none; width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.chip:has(input:checked) { box-shadow: var(--edge), 0 0 0 2px var(--accent); }
.chip:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
html.look-autumn .chip:has(input:focus-visible) { outline-color: var(--ink); }
.consent { padding: 18px 20px; border-radius: 2px; background: rgba(35, 31, 28, .04); box-shadow: inset 0 0 0 1px rgba(35, 31, 28, .08); }
.consent-row { display: flex; align-items: flex-start; gap: 10px; font-weight: 600; color: var(--ink); }
.consent-row input { flex: none; width: 22px; height: 22px; margin: 3px 0 0; accent-color: var(--accent); }
.consent-row label { cursor: pointer; }
.consent .list { margin: 12px 0 8px; font-size: 16px; line-height: 1.65; }
.consent .more { font-size: 16px; }
/* the form sends nothing yet: said in words before the button, in the accent's ink */
.form-note { margin: 0; padding: 12px 16px; border-radius: 2px; font-weight: 600; font-size: 16px; line-height: 1.6; color: var(--accent-down);
  background: rgba(45, 95, 93, .07); box-shadow: inset 0 0 0 1px rgba(45, 95, 93, .2); }   /* teal on it: 6.4:1 */
html.look-autumn .form-note { background: rgba(200, 54, 29, .07); box-shadow: inset 0 0 0 1px rgba(200, 54, 29, .18); }
.form .btn { justify-self: start; }
.form-msg { margin: 0; font-weight: 600; color: var(--ink); }
.form-msg:empty { display: none; }

/* ---------- phones: one column across the screen, 12 px from each side ---------- */
@media (max-width: 760px) {
  .title-block { padding: max(15svh, 124px) 18px 0; }
  .title-block h1 { font-size: clamp(28px, 7.6vw, 34px); }
  .title-block .line { font-size: 17px; }
  body[data-scene="quiet"] .title-block { min-height: 44svh; }
  .sheets, .side-left .sheets, .side-right .sheets { width: auto; margin: 0 12px; gap: 16px; padding-bottom: 28px; }
  .sheets > .sheet { padding: 26px 22px 24px; }
  .sheets .sheet h3 { margin-top: 24px; font-size: 18px; }
  .steps > li { padding-left: 52px; }
  .fields { grid-template-columns: 1fr; }
  .table th { width: 40%; padding-right: 14px; }
  .form .btn { justify-self: stretch; }
}
/* a phone, or any window the engine composes as a phone (width / height under .78: the scene centred), keeps the title
   centred */
@media (max-width: 760px), (max-aspect-ratio: 3899/5000) {
  .title-block.on-right { justify-content: center; text-align: center; }
  .title-block.on-right .title-in { width: auto; }
  .title-block.on-right .line { margin-left: auto; }
  .title-block.on-right .cta { justify-content: center; }
}
@media (min-width: 761px) and (max-height: 760px) {
  .title-block { padding-top: max(14vh, 96px); }   /* a centred title rises on a short window (work: clear of the frame) */
  .title-block.on-right { padding-top: max(11vh, 124px); }   /* the right title keeps clear of the motion button */
  .title-block .line { margin-top: 12px; }
}
/* upright phones: on a short phone the title starts higher (15 % of the height on 390 x 844, 96 px on 360 x 740: under
   the chip), as the scene's clinic stands at a share of the height and the title's lines are px tall (about, contact:
   their roofs under the line); a narrow phone sets the title a little smaller so contact's stays one line */
@media (max-width: 760px) and (max-aspect-ratio: 3899/5000) {
  .title-block { padding-top: max(calc(var(--bar-h) + 40px), min(max(15svh, 124px), 30.4svh - 130px)); }
}
@media (max-width: 374px) {
  .title-block h1 { font-size: clamp(26px, 7.5vw, 34px); }
}
/* a desk layout too short for the sky (a phone on its side, a window under 600 px): the title block on a cut card, as
   the home page's hero: on the right under the motion button where the scene's subject is on the left (side-right;
   40 % of the window wide, so the clinic of about, contact and seo-geo, in the left 55 %, stays clear), centred on the
   text-first pages; ink on paper on every scene */
@media (min-aspect-ratio: 3899/5000) and (max-height: 599.98px) {
  .title-block, .title-block.on-right { justify-content: flex-end; align-items: flex-start; text-align: left;
    padding: calc(var(--bar-h) + 64px) clamp(12px, 3vw, 30px) 12px; }
  .side-centre .title-block { justify-content: center; }
  .side-centre .title-block .title-in { width: min(440px, 100%); }
  .title-block .title-in, .title-block.on-right .title-in { width: min(clamp(300px, 40vw, 440px), 100%); max-width: none; padding: 18px 24px 20px;
    border-radius: 2px; background: var(--grain), var(--face), var(--paper); box-shadow: var(--edge), var(--lift); }
  body[data-scene] .title-block .title-in::before { display: none; }
  body[data-scene] .title-block .title-in h1 { font-size: clamp(24px, 3.4vw, 30px); line-height: 1.22; color: var(--ink); }
  body[data-scene] .title-block .title-in .line { margin: 8px 0 0; max-width: none; font-size: 17px; line-height: 1.5; color: var(--text); }
  body[data-scene] .title-block .crumb, body[data-scene] .title-block .crumb a { color: var(--accent-down); }
  .title-block .cta { justify-content: flex-start; margin-top: 16px; }
  .title-block .notice { margin-top: 12px; }
}

@media (forced-colors: active) {
  .chip, .consent, .form-note { border: 1px solid CanvasText; }
  .steps > li::before { border: 1px solid CanvasText; }
}
@media print {
  .title-block { min-height: 0; padding: 0 0 12pt; }
  .sheets { width: auto; margin: 0; gap: 12pt; }
  .sheets > .sheet { padding: 0; }
  .form, .fig video { display: none; }
}
