/* Clearfront Studio page CSS: the brand tokens (start.mjs brand, keep as printed) and what sits inside visuals. */
:root {
  --p-bg: #f7f8fa; --p-surface: #eaf0f4; --p-ink: #0f2747; --p-muted: #4a5b70;
  --p-accent: #0e7c80; --p-accent-ink: #f7f8fa; --p-action: #0e7c80; --p-action-ink: #f7f8fa;
  --p-inv-bg: #0f2747; --p-inv-surface: #1d3453; --p-inv-ink: #f7f8fa; --p-inv-muted: #97a3b3;
  --p-inv-accent: #0e7c80; --p-inv-accent-ink: #f7f8fa; --p-inv-action: #0e7c80; --p-inv-action-ink: #f7f8fa;
  --font-display: "Host Grotesk", system-ui, sans-serif;
  --font-text: "Host Grotesk", system-ui, sans-serif;
  --display-weight: 400;
  --display-tracking: -0.035em;
  --display-tracking-xl: -0.04em;
}

/* the logo is the studio's own SVG (brand/logo/final), never retyped */
.nav__logo--brand img { display: block; height: 38px; width: auto; }
.closing .nav__logo--brand img { height: 44px; }
@media (max-width: 639px) { .nav__logo--brand img { height: 32px; } }

/* hero visual: a phone with a concept site and a 9:16 ad frame on the surface ground */
.hero__media--devices { background: var(--p-surface); border-radius: var(--r-lg); overflow: hidden; position: relative; }
.devices { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 5%; padding: 5%; }
.device { margin: 0; border-radius: 22px; overflow: hidden; background: #0b1a30; box-shadow: 0 0 0 6px #0b1a30; }
.device img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.devices .device--phone { height: 86%; aspect-ratio: 390 / 844; flex: none; }
.devices .device--ad { height: 86%; aspect-ratio: 9 / 16; flex: none; }
.hero__media--devices .ly-float { display: none; }

/* concept work tiles on the inverse ground */
.work__tile { display: grid; gap: var(--s-4); color: inherit; text-decoration: none; }
.work__panel { margin: 0; display: flex; align-items: center; justify-content: center; height: 400px; border-radius: var(--r-lg); background: var(--p-inv-surface); overflow: hidden; }
.work__tile .device { height: 340px; width: auto; box-shadow: 0 0 0 6px #08142a; }
.work__tile .device--phone { aspect-ratio: 390 / 844; }
.work__tile .device--ad { aspect-ratio: 9 / 16; }
.work__tile img { transition: transform 300ms cubic-bezier(.22,1,.36,1); }
.work__tile:hover img { transform: scale(1.025); }
@media (max-width: 1023px) { .work__panel { height: 400px; } .work__tile .device { height: 330px; } .hero__media--devices { min-height: 340px; } }
@media (max-width: 639px) {
  .work__panel { height: 340px; } .work__tile .device { height: 300px; }
  .hero__media--devices { min-height: 360px; }
  .hero__media--devices .ly-float { display: none; }
  .devices { padding: 6% 8%; }
  .devices { padding: 6% 8% 22%; }
}

.offers .plan { height: auto; }
#process .mo-pc__visual img, #process .mo-pc__visuals img { object-fit: contain; background: var(--p-surface); }

/* legal and text pages */
.prose { max-width: 62ch; }
.prose h2 { font: var(--display-weight) var(--t-h3)/1.2 var(--font-display); letter-spacing: -0.02em; margin: var(--s-7) 0 var(--s-3); }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { font-size: 16px; line-height: 1.7; }
.prose ul { padding-left: 1.2em; }
.prose a { color: var(--p-action); }

/* inner pages */
.devices .device--solo { height: 100%; align-self: center; margin: 0; }
.hero__media--devices:has(.device--solo) .ly-float { left: 24px; right: auto; }
.steps { list-style: none; padding: 0; margin: 0; }
.steps .card h3 { font: 500 var(--t-card)/1.3 var(--font-text); margin: 0 0 var(--s-3); }
.page-text { height: auto; min-height: 100svh; }
.page-text__h1 { font: var(--display-weight) var(--t-h2)/1.1 var(--font-display); letter-spacing: var(--display-tracking); margin: 0; }

.plan__media { height: 132px; margin-bottom: var(--s-5); border-radius: var(--r-md); overflow: hidden; background: var(--p-surface); }
.plan__media img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.plan__media--strip img { object-position: 50% 30%; }
.plan .btn { margin-top: var(--s-5); align-self: start; }
@media (max-width: 639px) { .plan__media { height: 120px; } .plan .btn { align-self: stretch; } }
.chat-mock { display: grid; gap: var(--s-3); margin-top: var(--s-7); max-width: 420px; padding: var(--s-5); border-radius: var(--r-lg); background: var(--p-surface); }
.chat-mock__msg { margin: 0; padding: 10px 14px; border-radius: 14px; font-size: 16px; line-height: 1.45; max-width: 85%; }
.chat-mock__msg--them { background: #fff; justify-self: start; }
.chat-mock__msg--us { background: #d4efe9; justify-self: end; }

.footer__legal .legal__links { display: inline-flex; gap: var(--s-5); }
@media (max-width: 639px) { .footer__legal > span { display: flex; flex-direction: column; gap: var(--s-2); } }
/* the pinned moment rests (not live) on a phone; hold it to its two screens there */
@media (max-width: 359px) { .work__panel { height: 280px; } .work__tile .device { height: 240px; } }
.label-mock { margin-top: var(--s-7); max-width: 380px; padding: var(--s-5); border-radius: var(--r-lg); background: #0b1a30; color: #f7f8fa; display: grid; gap: var(--s-3); }
.label-mock__head { display: flex; gap: var(--s-3); align-items: center; font-size: 15px; }
.label-mock__head b { font-weight: 500; display: block; }
.label-mock__av { width: 36px; height: 36px; border-radius: 50%; background: #3cc6cb; flex: none; }
.label-mock__tag { display: inline-block; margin-top: 2px; font-size: 13px; color: #c9d2de; border: 1px solid #ffffff40; border-radius: 6px; padding: 1px 6px; }
.label-mock__cap { margin: 0; font-size: 18px; line-height: 1.35; font-weight: 500; }
.label-mock__meta { margin: 0; font-size: 13px; color: #b6c1cf; }

/* browser surfaces from the palette (impeccable craft floor) */
::selection { background: #14a3a833; color: var(--p-ink); }
.ground-inverse ::selection, .footer--dark ::selection { background: #3cc6cb55; color: #fff; }
html { caret-color: var(--p-accent); accent-color: var(--p-accent); }
a { text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
.plan__price, .rows__value { font-variant-numeric: tabular-nums; }

/* web interface guidelines: taps, anchors */
a, button { touch-action: manipulation; -webkit-tap-highlight-color: #14a3a826; }
main [id], footer[id] { scroll-margin-top: var(--nav, 72px); }
.rows .rows__name small { display: block; margin-top: 2px; font-weight: 400; font-size: var(--t-small); line-height: 1.5; color: var(--p-muted); }
.label-mock .label-mock__cap { color: #f7f8fa; }
.label-mock .label-mock__meta { color: #b6c1cf; }
.footer__legal .legal__links { margin-left: var(--s-5); }
@media (max-width: 639px) { .footer__legal .legal__links { margin-left: 0; } }

/* plain inline mail link (no arrow) on the dark close */
a.mail { color: inherit; text-decoration: underline; text-decoration-color: #3cc6cb; text-underline-offset: 0.2em; }
a.mail:hover { text-decoration-thickness: 2px; }
/* legal pages: text grows the section; the footer never covers it */
main > section.section.page-text { height: auto; min-height: 100svh; padding-bottom: var(--s-9); }
#process .mo-pc__visual img, #process .mo-pc__visuals img { object-fit: cover; }

@media (max-width: 639px) { .plan__price { flex-wrap: wrap; row-gap: 4px; } .plan__price small { flex-basis: 100%; } }
/* the terms statement fills its screen */
#promise .mo-wh__text { font-size: clamp(34px, 4.6vw, 72px); line-height: 1.12; max-width: 20ch; }
.offers { align-items: start; }
.steps .step__img { aspect-ratio: 16 / 10; height: auto; margin-bottom: var(--s-5); border-radius: var(--r-md); overflow: hidden; }
.steps .step__img img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* process on a phone: the pinned moment rests as a list; bigger pictures fill its two screens */
@media (max-width: 639px) {
  #process .mo-pc__visual > img { max-height: none; aspect-ratio: 4 / 3; }
  main > #process[data-moment]:not(.is-live) { height: auto; min-height: calc(2 * 100lvh); }
}
@media (max-width: 639px) { .steps .step__img { aspect-ratio: 2 / 1; } }
.steps .step__img { background: #eaf0f4; } .steps .step__img img { object-fit: contain; }

/* desktop screens of any height: a section is at least its screens and grows with its content, so nothing is
   ever cut or laid under the next section (the kit does this below 1280; this extends it to wide, short screens) */
@media (min-width: 1280px) {
  main > :is(section, .section), footer.closing {
    height: auto; min-height: calc(var(--h, 1) * 100vh); min-height: calc(var(--h, 1) * 100svh);
  }
  :where(main > :is(section, .section):not(.hero), footer.closing) { display: flex; flex-direction: column; }
  main > :is(section, .section):not(.hero) > .wrap, footer.closing > .wrap { flex: 1 0 auto; height: auto; min-height: 0; }
}

/* never let a fill grid shrink under its content (the kit lets .fill flex to 0 with min-height 0, which on short
   screens laid cards over the next section); it still grows to fill when there is room */
main > :is(section, .section) > .wrap > .fill.fill, main .group > .fill.fill { flex: 1 0 auto; min-height: auto; }
/* the three step cards stay one row from 1024 up */
@media (min-width: 1024px) { .steps > li.span-4 { grid-column: span 4; } }

/* the hero picture fills the hero's content height, so the devices are large */
@media (min-width: 1024px) { .hero--split .hero__media.hero__media--devices { min-height: min(716px, calc(100svh - 184px)); align-self: stretch; } }
@media (max-width: 1023px) { .hero__media--devices { min-height: 420px; } }
@media (max-width: 639px) { .hero__media--devices { min-height: 360px; } .devices { padding: 4%; gap: 4%; } }

/* concept ad video */
.device--video { position: relative; }
.device--video video { display: block; width: 100%; height: 100%; object-fit: cover; background: #0b1a30; }
.ad-ctrl { position: absolute; left: 8px; right: 8px; bottom: 8px; display: flex; gap: 6px; justify-content: space-between; }
.ad-btn { width: 36px; height: 36px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(11, 26, 48, .78); color: #fff; font: 500 13px/1 var(--font-text); cursor: pointer; transition: background-color 200ms ease; }
.ad-btn:hover { background: rgba(11, 26, 48, .95); }
.ad-btn:focus-visible { outline: 2px solid #3cc6cb; outline-offset: 2px; }
.ad-btn svg { width: 18px; height: 18px; fill: currentColor; }
@media (pointer: coarse) { .ad-btn { width: 44px; height: 44px; } }

.device--video video { cursor: pointer; }
.ad-tap { position: absolute; left: 50%; bottom: 56px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 6px; min-height: 32px; max-width: calc(100% - 12px); padding: 0 10px; border: 0; border-radius: 999px; background: #fff; color: #0f2747; font: 500 12px/1 var(--font-text); white-space: nowrap; cursor: pointer; box-shadow: 0 6px 18px rgba(0,0,0,.25); transition: transform 200ms cubic-bezier(.22,1,.36,1); }
.ad-tap::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #14a3a8; }
.ad-tap:hover { transform: translateX(-50%) translateY(-1px); }
.ad-tap:focus-visible { outline: 2px solid #3cc6cb; outline-offset: 2px; }
.ad-tap[hidden] { display: none; }
@media (pointer: coarse) { .ad-tap { min-height: 44px; } }
