/* Lookout: the landing page (What is Lookout?) and How it works. Loaded after lookout.css. */

/* ============================================================ landing */
.hero { background: radial-gradient(120% 90% at 78% 40%, #134a40 0%, #0b3832 55%, #082d28 100%); color: #e6efe9; }
.hero .in { max-width: 1240px; margin: 0 auto; padding: 46px 20px 40px; display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.25fr); gap: 36px; align-items: center; }
@media (max-width: 1000px) { .hero .in { grid-template-columns: 1fr; padding-top: 30px; } }
.hero h1 { color: #ffffff; font-size: clamp(2.4rem, 4.4vw, 3.6rem); font-weight: 600; letter-spacing: -0.02em; margin: 0 0 18px; line-height: 1.05; }
.hero h1 .stroke { position: relative; display: inline-block; }
.hero h1 .stroke svg { position: absolute; left: 0; right: 0; bottom: -0.16em; width: 100%; height: 0.3em; overflow: visible; }
.hero .answer { font-family: var(--serif); font-size: 1.28rem; line-height: 1.6; color: #e6efe9; max-width: 34em; margin: 0 0 18px; }
.hero .tally { font-size: 1.02rem; line-height: 1.7; color: #b9cfc3; max-width: 36em; margin: 0 0 26px; }
.hero .tally b { color: #ffffff; font-weight: 600; font-variant-numeric: tabular-nums; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn-light { background: var(--chartreuse); color: var(--pine); border: 0; border-radius: 7px; padding: 10px 18px; font-weight: 700; text-decoration: none; }
.btn-light:hover { background: #c9d96c; color: var(--pine); }
.btn-ghost { color: #e6efe9; border: 1px solid rgba(230, 239, 233, 0.35); border-radius: 7px; padding: 9px 16px; text-decoration: none; }
.btn-ghost:hover { border-color: #e6efe9; color: #fff; }
.mapbox { position: relative; }
.mapbox .legend { font-size: 0.8rem; color: #9fb8ac; text-align: center; margin: 4px auto 0; max-width: 46em; line-height: 1.5; }
.mapbox .replay { position: absolute; top: 4px; right: 4px; background: transparent; border: 1px solid rgba(230, 239, 233, .3); color: #b9cfc3; font-size: 0.78rem; padding: 3px 10px; border-radius: 12px; }
.mapbox .replay:hover { color: #fff; border-color: #fff; background: transparent; }
.km-tip { position: absolute; pointer-events: none; background: #ffffff; color: var(--ink); border-radius: 8px; padding: 9px 12px; font-size: 0.84rem; line-height: 1.4; box-shadow: 0 6px 24px rgba(4, 30, 26, 0.35); max-width: 240px; opacity: 0; transition: opacity .12s; z-index: 3; }
.km-tip b { font-family: var(--serif); font-size: 1rem; color: var(--pine-deep); display: block; }
.km-tip.on { opacity: 1; }

/* the map */
.km { width: 100%; height: auto; display: block; overflow: visible; }
.km text { font-family: var(--sans); }
.km-ring { fill: none; stroke: rgba(162, 205, 156, 0.12); stroke-width: 1; }
.km-arc { fill: none; stroke-width: 5; stroke-linecap: round; opacity: 0.95; }
.km-catname { font-size: 11px; fill: #9fb8ac; letter-spacing: 0.02em; }
.km-link { fill: none; opacity: 0.42; transition: opacity .2s; }
.km-link.us { opacity: 0.95; }
.km-dim circle { fill: #0b3832; stroke: var(--sage); stroke-width: 2; }
.km-dim text { font-size: 12px; fill: #d4e5da; font-weight: 600; }
.km-dim { cursor: default; outline: none; }
.km-firm text { font-size: 10px; fill: #b9cfc3; }
.km-firm.us text { font-size: 14px; fill: var(--chartreuse); font-weight: 700; font-family: var(--serif); }
.km-firm circle { transition: transform .2s; transform-box: fill-box; transform-origin: center; }
.km-firm:focus { outline: none; }
.km-firm:focus circle, .km-firm:hover circle { transform: scale(1.35); }
.km-us-halo { fill: none; stroke: var(--chartreuse); stroke-width: 1.5; opacity: 0.6; }
.km-count { font-family: var(--serif); font-size: 36px; font-weight: 600; fill: #ffffff; font-variant-numeric: tabular-nums; }
.km-unit { font-size: 13px; fill: #9fb8ac; }
/* focus: one firm or one dimension at a time */
.km.focus .km-link { opacity: 0.05; }
.km.focus .km-link.hl { opacity: 0.95; }
.km.focus .km-firm { opacity: 0.28; }
.km.focus .km-firm.hl { opacity: 1; }
.km.focus .km-firm.hl text { fill: #ffffff; }
.km.focus .km-dim { opacity: 0.35; }
.km.focus .km-dim.hl { opacity: 1; }
.km.focus .km-dim.hl circle { fill: var(--sage); }
/* the build: hidden until the script reveals each part */
.km.building .km-dim, .km.building .km-firm, .km.building .km-catname, .km.building .km-centre { opacity: 0; }
.km.building .km-arc, .km.building .km-link { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); }
.km .km-dim, .km .km-firm, .km .km-catname, .km .km-centre { transition: opacity .45s ease-out; }
.km .km-arc, .km .km-link { transition: stroke-dashoffset 1s cubic-bezier(.4, 0, .2, 1), opacity .2s; }
.km.building .shown { opacity: 1; }
.km.building .drawn { stroke-dashoffset: 0; }
.km .km-firm.pop circle { animation: km-pop .5s ease-out; }
@keyframes km-pop { 0% { transform: scale(0); } 70% { transform: scale(1.4); } 100% { transform: scale(1); } }
.km .km-firm.us.pop .km-us-halo { animation: km-halo 1.6s ease-out 2; transform-box: fill-box; transform-origin: center; }
@keyframes km-halo { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(2.6); opacity: 0; } }

/* below the hero */
.questions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 10px 0 8px; border-top: 1px solid var(--line); }
@media (max-width: 900px) { .questions { grid-template-columns: 1fr; } }
.questions > div { padding: 20px 26px 22px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 901px) { .questions > div + div { padding-left: 26px; border-left: 1px solid var(--line); } }
.questions h3 { font-size: 1.22rem; margin: 0 0 8px; }
.questions p { color: var(--ink-soft); margin: 0 0 10px; }
.questions .finding { font-family: var(--serif); font-size: 1.05rem; color: var(--ink); border-left: 3px solid var(--sage); padding-left: 12px; margin: 12px 0; }
.wayfind { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 44px; margin-top: 6px; }
@media (max-width: 760px) { .wayfind { grid-template-columns: 1fr; } }
.wayfind a { display: grid; grid-template-columns: 150px 1fr; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink-soft); align-items: baseline; }
.wayfind a b { font-family: var(--serif); font-size: 1.08rem; color: var(--pine-deep); font-weight: 600; }
.wayfind a:hover b { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.section-lede { color: var(--ink-soft); max-width: 70ch; margin-top: 0; }

/* ======================================================== how it works */
.flow { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 18px 18px 8px; margin: 18px 0 8px; }
.flow svg { width: 100%; height: auto; display: block; }
.steps { list-style: none; padding: 0; margin: 10px 0 0; counter-reset: step; position: relative; }
.steps::before { content: ""; position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px; background: var(--sage); opacity: .6; }
.steps > li { counter-increment: step; position: relative; padding: 0 0 26px 62px; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 40px; height: 40px; border-radius: 50%; background: var(--pine-deep); color: #fff; font-family: var(--serif); font-weight: 600; font-size: 1.1rem; display: grid; place-items: center; }
.steps h3 { margin: 6px 0 6px; font-size: 1.2rem; }
.steps .detail { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 26px; }
@media (max-width: 860px) { .steps .detail { grid-template-columns: 1fr; gap: 6px; } }
.steps .detail p { margin: 0 0 6px; max-width: 64ch; }
.steps .made { font-size: 0.86rem; color: var(--muted); border-left: 2px solid var(--line); padding-left: 12px; }
.steps .made b { color: var(--ink-soft); font-weight: 600; }
.arch { background: var(--pine); border-radius: 12px; padding: 22px; margin: 14px 0; }
.arch svg { width: 100%; height: auto; display: block; }
.facts-two { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; }
@media (max-width: 860px) { .facts-two { grid-template-columns: 1fr; } }
ul.ticks { list-style: none; padding: 0; margin: 8px 0; }
ul.ticks li { padding: 7px 0 7px 26px; position: relative; border-bottom: 1px solid var(--line); }
ul.ticks li::before { content: ""; position: absolute; left: 2px; top: 14px; width: 12px; height: 7px; border-left: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent); transform: rotate(-45deg); }
table.costs { border-collapse: collapse; width: 100%; font-size: 0.93rem; }
table.costs td { padding: 8px 4px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.costs td.n { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; font-weight: 600; color: var(--pine-deep); }
table.why { border-collapse: collapse; width: 100%; font-size: 0.93rem; }
table.why th, table.why td { text-align: left; padding: 10px 10px 10px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
table.why th { color: var(--muted); font-size: 0.84rem; font-weight: 600; }
table.why td:first-child { font-family: var(--serif); font-weight: 600; color: var(--pine-deep); width: 26%; }
@media (prefers-reduced-motion: reduce) { .km .km-firm.pop circle, .km .km-firm.us.pop .km-us-halo { animation: none; } }
