/* Layout refinements for the current voice-read homepage. */
:root {
  --landing-ink: #FAFAF7;
  --landing-muted: #B8B2A8;
  --landing-line: rgba(250, 250, 247, .14);
  --landing-section-gap: 96px;
}

html { scroll-padding-top: 0; }
body { background: #090A0A; }

#change {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  height: auto !important;
  min-height: 100vh !important;
  min-height: 100svh !important;
  justify-content: center;
  padding: 88px 0 var(--landing-section-gap);
  box-sizing: border-box;
}
#change > .hero-visual {
  margin-top: 0;
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  width: 100%;
  height: 280px;
  padding: 0 !important;
  flex: none;
}
.hero-visual #kc-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-visual #kc-pick {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 8px;
}
#change > .hero-copy {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px !important;
  padding: 0 24px !important;
  width: 100%;
  box-sizing: border-box;
}
#change .kairos-display {
  margin: 0;
  font-weight: 450;
  font-size: clamp(36px, 3.8vw, 56px) !important;
  line-height: 1.12 !important;
  letter-spacing: -.035em;
}
.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
}
#kc-pick button {
  min-width: 68px;
  height: 44px !important;
  border-radius: 22px !important;
}
#change a.kc-primary,
#change a.kc-secondary,
#app-cta,
#kr-card .kr-cta {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  height: auto !important;
  padding: 13px 22px !important;
  border-radius: 26px !important;
  font: 500 14px/1.5 'Manrope', system-ui, sans-serif;
  text-align: center;
  text-decoration: none;
}
#change a.kc-primary,
#app-cta,
#kr-card .kr-cta {
  color: #141615 !important;
  background: #FAFAF7 !important;
}
#change a.kc-primary:hover,
#app-cta:hover,
#kr-card .kr-cta:hover { background: #D2DAD3 !important; }
a:focus-visible,
button:focus-visible {
  outline: 2px solid #A4C2B9;
  outline-offset: 4px;
}

/* Natural flow keeps the live controls, read and next action together. */
#read[data-screen-label] {
  height: auto !important;
  min-height: 0 !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: var(--landing-section-gap) 24px;
  justify-content: flex-start;
  box-sizing: border-box;
  overflow: visible !important;
  scroll-margin-top: 0;
}
#read .kr-ask {
  position: relative !important;
  left: auto !important;
  top: auto !important;
  transform: none !important;
  width: min(560px, 100%) !important;
  gap: 22px !important;
}
#read .kr-ask :is(h1, h2),
#how h2 {
  font: 400 clamp(28px, 3vw, 36px)/1.25 'Kairos Fraunces', Georgia, serif !important;
  text-transform: none !important;
  letter-spacing: -.02em !important;
  text-wrap: balance;
  max-width: 620px;
}
#read .kr-ask > p {
  max-width: 360px !important;
  margin: -10px 0 0 !important;
  font-size: 13px !important;
  line-height: 1.6 !important;
  color: #B8B2A8 !important;
}
#read .kr-ask > button {
  min-height: 48px;
  padding: 0 22px !important;
  border-radius: 24px !important;
}
#read #kr-card {
  position: relative !important;
  left: auto !important;
  top: auto !important;
  transform: none !important;
  flex: none;
  width: min(400px, 100%);
  padding: 22px 24px 24px;
  border-radius: 22px;
  background: #111313;
  border: 1px solid var(--landing-line);
  box-shadow: none;
  scroll-margin: 24px;
}
#read #kr-card .kr-label { min-height: 36px; }
#read #kr-card .kr-i {
  position: relative;
  width: 44px !important;
  height: 44px !important;
  min-width: 44px !important;
  min-height: 44px !important;
  margin: -4px 0 -4px 0 !important;
  border: 0 !important;
  background: transparent !important;
  font: 500 13px/1 'Manrope', system-ui, sans-serif !important;
  font-style: normal !important;
  color: var(--landing-muted) !important;
}
#read #kr-card .kr-i::before {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border: 1px solid rgba(250, 250, 247, .3);
  border-radius: 50%;
}
#read #kr-card .kr-i:hover,
#read #kr-card .kr-i[aria-expanded=true] {
  background: transparent !important;
  color: var(--c) !important;
}
#kr-card .kr-ends { color: #B8B2A8; }
#kr-card .kr-cta { width: 100%; }

#how {
  scroll-margin-top: 0;
  min-height: 0;
  box-sizing: border-box;
  justify-content: flex-start;
  padding: var(--landing-section-gap) 24px !important;
  gap: 32px !important;
  background: #090A0A;
}
#how h2 { margin: 0 !important; }
#how .app-stages { gap: clamp(24px, 4vw, 56px) !important; }
#how figure { gap: 20px !important; }
#how figcaption {
  font-size: 12px !important;
  line-height: 1.5;
  color: #B8B2A8 !important;
}
#app-cta { margin-top: 12px; }

.landing-social-links a { min-width: 44px; min-height: 44px; }
.production-footer {
  padding: 24px !important;
  margin: 0 24px 24px !important;
  box-sizing: border-box;
}
.production-footer a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  color: #B8B2A8;
  font-size: 13px;
}
.production-footer .footer-links { gap: 0 24px; }

@media (max-width: 700px) {
  :root { --landing-section-gap: 72px; }
  #change { padding: 88px 0 var(--landing-section-gap); gap: 28px; }
  #change > .hero-visual { height: 230px; }
  #change > .hero-copy { gap: 20px !important; }
  .hero-actions { flex-direction: column; gap: 4px; }
  #change .kairos-display { font-size: clamp(32px, 8.8vw, 40px) !important; }
  #kc-pick { flex-wrap: nowrap !important; gap: 6px !important; }
  #kc-pick button { min-width: 0; padding: 0 14px !important; }
  #read[data-screen-label] { padding: var(--landing-section-gap) 24px; gap: 20px; }
  #read .kr-ask :is(h1, h2), #how h2 { font-size: 28px !important; }
  #read #kr-card { padding: 18px 20px 20px; }
  #how .app-stages {
    display: flex !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    width: calc(100% + 48px);
    overflow-x: auto;
    gap: 20px !important;
    padding: 8px 24px 24px;
    box-sizing: border-box;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 24px;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  #how figure { flex: 0 0 min(260px, 72vw); scroll-snap-align: start; }
  #how figure > div { box-sizing: border-box; width: 100% !important; }
  #app-cta { max-width: 100%; }
  .landing-social-links { left: 16px !important; right: 16px !important; gap: 4px !important; }
  .landing-social-links a { font-size: 12px !important; }
  .production-footer { margin: 0 16px 16px !important; padding: 20px 16px !important; }
  .production-footer .footer-links { justify-content: center; gap: 0 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  #kr-card .kr-fill { transition: none; }
}

/* The result button appears only for the visitor's own read; its space is always reserved so the card never jumps. */
#kr-card .kr-result, #kr-card .kr-result[hidden] { display: block !important; }
#kr-card:not(.mine) .kr-result { visibility: hidden; }
/* The example read is visibly an example: dimmed bars until the visitor's own read replaces them. */
#kr-card.example .kr-fill, #kr-card.insufficient .kr-fill { opacity: .85; }
/* In the example state the reserved result space carries a quiet prompt instead of sitting blank. */
#kr-card .kr-result { position: relative; }
#kr-card.example .kr-result::after, #kr-card.insufficient .kr-result::after { content: "Talk to see your own read."; visibility: visible; position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%); text-align: center; font-size: 14px; color: rgba(242,242,240,.62); }
#kr-card .kr-result[hidden] { display: block !important; }

#read #kr-slot { display: none; }
#how .how-heading { text-align: center; }
#how .how-description { margin: 16px auto 0; }

#read .kr-ask :is(h1, h2) { margin: 0; }
.app-price {
  margin: -16px 0 0;
  color: #B8B2A8;
  font: 400 14px/1.6 'Manrope', system-ui, sans-serif;
  text-align: center;
}
.mic-fallback {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  text-decoration: underline;
  text-underline-offset: 4px;
}


nav.landing-social-links a.landing-home-logo {
  height: 44px !important;
  min-height: 44px !important;
}

.landing-top-links .landing-contact-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
}
@media (min-width: 361px) and (max-width: 600px) {
  nav.landing-social-links { gap: 0 !important; }
  .landing-top-links { right: 16px !important; gap: 10px !important; }
}

#change .hero-actions .kc-secondary {
  min-height: 44px;
  padding: 0 4px !important;
  border: 0 !important;
  background: transparent;
  color: #D2DAD3 !important;
  border-radius: 0 !important;
  font-size: 14px;
}
#change .hero-actions .kc-secondary:hover { color: #FAFAF7 !important; }
#read #kr-card .kr-result { margin-top: 20px; padding-top: 0; border-top: 0; }

#how::before { display: none; }

/* The signal belongs to the page surface, with no enclosing visual panel. */
#change, #change .hero-visual, #kc-canvas {
  background: transparent !important;
  box-shadow: none;
}

@media (min-width: 901px) {
  #how {
    --stage-phone-width: clamp(140px, calc((100svh - 365px) * .462), 260px);
    gap: 24px !important;
  }
  #how figure { gap: 12px !important; }
  #how figure > div {
    width: var(--stage-phone-width) !important;
    border-radius: calc(var(--stage-phone-width) * .15) !important;
  }
  #how figure img { border-radius: calc(var(--stage-phone-width) * .125) !important; }
}

.hero-description {
  max-width: 520px;
  margin: -8px 0 0;
  color: #D2DAD3;
  font: 400 16px/1.5 'Manrope', system-ui, sans-serif;
  text-align: center;
  text-wrap: balance;
}
#read .kr-ask .read-intro {
  margin: -8px 0 0 !important;
  color: #D2DAD3 !important;
  font-size: 15px !important;
}
@media (max-width: 700px) {
  .hero-description { font-size: 14px; }
}
@media (max-width: 700px) and (max-height: 620px) {
  #change > .hero-visual { height: 190px; }
}

/* Read card notes: a missed read keeps the example card and says why inside it. */
#kr-card .kr-note {
  margin: 0 0 4px;
  color: #FAFAF7;
  font: 400 14px/1.45 'Manrope', system-ui, sans-serif;
}
#kr-card .kr-note[hidden] { display: none; }
#read .mic-status-error {
  color: #FAFAF7 !important;
  font-size: 14px !important;
}
#read .mic-fallback { font-size: 13px; color: #B8B2A8; }

#how .app-stages::-webkit-scrollbar { display: none; }

/* Type follows the Kairos app, not the old site: Manrope everywhere (the app's font). */
@font-face { font-family: 'Manrope'; src: url('/static/landing-v2/assets/fonts/manrope.ttf') format('truetype'); font-weight: 200 800; font-display: swap; }
body, body *:not(svg):not(path) { font-family: 'Manrope', system-ui, -apple-system, sans-serif !important; }
#change .kairos-display, #how h2, #read h1, #read h2 { font-weight: 600 !important; letter-spacing: -.015em !important; }
/* Trial note under the hero buttons (price or trial at the CTA). */
#change .hero-trial { margin: -12px 0 0; font-size: 13px; color: rgba(242,242,240,.62); }

/* Win over any id-scoped font rule: Manrope everywhere. */
body :not(#_k1):not(#_k2):not(svg):not(path) { font-family: 'Manrope', system-ui, -apple-system, sans-serif !important; }

/* Audit polish: one button height, visible focus on every pill. */
#change .hero-actions .kc-primary, #change .hero-actions .kc-secondary { min-height: 48px !important; height: 48px !important; display: inline-flex !important; align-items: center; justify-content: center; box-sizing: border-box; }
#kc-pick button:focus-visible, #kc-pick button.on:focus-visible { outline: 2px solid #FAFAF7 !important; outline-offset: 3px !important; }

/* Slimmer footer on wide screens: one compact row, centered, not full width. */
@media (min-width: 901px) {
  .production-footer { max-width: 880px; margin: 0 auto 20px !important; padding: 6px 24px !important; }
  .production-footer a { min-height: 32px; }
}
