/*
 * Axtli.ai — round 2 shared layer ("instrument").
 * Two themes as variable sets, so any section can flip between night and day.
 * Type is deliberately compact: 600-weight headings, short measures, 15–17px body.
 */

.t-dark {
  --bg: #111e1c;
  --bg-2: #162523;
  --fg: #f3f7f7;
  --fg-2: rgb(243 247 247 / 0.68);
  --fg-3: rgb(243 247 247 / 0.56);
  --line: rgb(243 247 247 / 0.09);
  --line-2: rgb(243 247 247 / 0.17);
  --accent: #31b8ad;
  --mark: #31b8ad;
  --btn-bg: #31b8ad;
  --btn-fg: #111e1c;
  --btn-hover: #4cc6bc;
  --ast-ink: rgb(243 247 247 / 0.5);
  --ast-minor: rgb(243 247 247 / 0.18);
  --ast-label: rgb(243 247 247 / 0.45);
  --ast-ring: rgb(243 247 247 / 0.13);
  --ast-accent: #31b8ad;
  --lp: #f3f7f7;
  color-scheme: dark;
}
.t-light {
  --bg: #f3f7f7;
  --bg-2: #dfe7e6;
  --fg: #111e1c;
  --fg-2: #5c6564;
  --fg-3: rgb(17 30 28 / 0.66);
  --line: rgb(17 30 28 / 0.09);
  --line-2: #b4bebc;
  --accent: #0b7a72;
  --mark: #0b7a72;
  --btn-bg: #111e1c;
  --btn-fg: #f3f7f7;
  --btn-hover: #00504a;
  --ast-ink: #111e1c;
  --ast-minor: #b4bebc;
  --ast-label: #5c6564;
  --ast-ring: #b4bebc;
  --ast-accent: #0b7a72;
  --lp: #ffffff;
  color-scheme: light;
}
.t-dark, .t-light { background: var(--bg); color: var(--fg); }
.t-dark ::selection { background: var(--accent); color: #111e1c; }
.t-light ::selection { background: var(--accent); color: #f3f7f7; }
.t-dark :focus-visible { outline-color: var(--accent); }

body { font-size: 15.5px; line-height: 1.6; font-weight: 420; }

/* --- type ----------------------------------------------------------------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent);
}
.eyebrow .dim { color: var(--fg-3); }
.h-display { font-weight: 550; font-size: clamp(34px, 4.1vw, 56px); line-height: 1.04; letter-spacing: -0.034em; }
.h-section { font-weight: 600; font-size: clamp(25px, 2.4vw, 34px); line-height: 1.14; letter-spacing: -0.026em; }
.h-item { font-weight: 600; font-size: 16.5px; line-height: 1.3; letter-spacing: -0.012em; }
.lede { font-size: 16.5px; line-height: 1.6; color: var(--fg-2); max-width: 42ch; }
.small { font-size: 14.5px; line-height: 1.55; color: var(--fg-2); }
.mono-s { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--fg-3); }
.em { color: var(--accent); }

/* --- header ----------------------------------------------------------------- */
.ihdr { position: fixed; inset: 0 0 auto; z-index: 50; border-bottom: 1px solid transparent;
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease); }
.ihdr.solid { background: color-mix(in srgb, var(--bg) 84%, transparent); border-color: var(--line);
  -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2); }
.ihdr .wrap { height: 64px; display: flex; align-items: center; gap: 28px; }
.ibrand { display: flex; align-items: center; gap: 11px; color: var(--mark); }
.ibrand .mark { width: 26px; height: 26px; }
.ibrand .wordmark { font-size: 14.5px; color: var(--fg); }
.inav { display: flex; gap: 26px; margin-left: auto; }
.inav a { font-size: 14px; color: var(--fg-2); transition: color 0.2s var(--ease); }
.inav a:hover { color: var(--fg); }

/* --- buttons ------------------------------------------------------------- */
.ibtn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--btn-bg); color: var(--btn-fg); font-weight: 600; font-size: 14px; letter-spacing: -0.005em; white-space: nowrap;
  transition: background 0.2s var(--ease), transform 0.15s var(--ease), box-shadow 0.3s var(--ease); }
.ibtn:hover { background: var(--btn-hover); }
.ibtn:active { transform: translateY(1px); }
.ibtn .arr { transition: transform 0.3s var(--ease-out); }
.ibtn:hover .arr { transform: translateX(2px); }
.ibtn.ghost { background: transparent; color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-2); }
.ibtn.ghost:hover { box-shadow: inset 0 0 0 1px var(--fg-3); background: transparent; }
.ibtn.sm { height: 34px; padding: 0 14px; font-size: 13.5px; }
.ilink { font-weight: 600; font-size: 14px; color: var(--fg-2); transition: color 0.2s var(--ease); }
.ilink:hover { color: var(--fg); }

/* --- sections ----------------------------------------------------------- */
.isec { padding: clamp(72px, 8vw, 112px) 0; border-top: 1px solid var(--line); position: relative; }
.ihead { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: end; margin-bottom: 44px; }
.ihead .h-section { margin-top: 12px; max-width: 18ch; }
.ihead .small { max-width: 46ch; justify-self: end; }

/* principles: four compact columns */
.marks4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line-2); }
.marks4 > div { padding: 22px 22px 4px 0; }
.marks4 > div + div { padding-left: 22px; border-left: 1px solid var(--line); }
.marks4 .sg { display: block; width: 30px; height: 30px; color: var(--mark); margin-bottom: 18px; }
.marks4 .sg .mark { width: 100%; height: 100%; }
.marks4 .sg .mark > g > * { opacity: 0.16; }
.marks4 .k { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-3); }
.marks4 .h-item { margin-top: 4px; }
.marks4 p.small { margin-top: 6px; }

/* product readout */
.readout { border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; background: var(--bg-2); }
.readout .bar { display: flex; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--line);
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-3); }
.readout .bar b { font-weight: 500; color: #b8761c; }
.t-dark .readout .bar b { color: var(--amber); }
.readout pre { margin: 0; padding: 16px 16px 18px; font-family: var(--font-mono); font-size: 12.5px; line-height: 1.85; color: var(--fg-2); white-space: pre-wrap; min-height: 13.2em; }
.readout .p { color: var(--accent); } .readout .k { color: var(--fg-3); } .readout .w { color: var(--fg); }
.readout .sg { color: var(--fg); border-bottom: 1px dashed var(--fg-3); }
.readout .ok { color: var(--fg); } .readout .am { color: #b8761c; }
.t-dark .readout .am { color: var(--amber); }
.caret { display: inline-block; width: 0.55em; height: 1.05em; vertical-align: -0.18em; background: var(--accent); animation: ins-blink 1.1s steps(1) infinite; }
@keyframes ins-blink { 50% { opacity: 0; } }

.feats { display: grid; gap: 0; border-top: 1px solid var(--line-2); }
.feats li { display: grid; grid-template-columns: 112px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.feats .mono-s { padding-top: 3px; color: var(--accent); }

/* roadmap */
.road { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: relative; }
.road::before { content: ""; position: absolute; left: 0; right: 0; top: 4px; height: 1px;
  background: linear-gradient(90deg, var(--accent) 0 12%, var(--line-2) 12% 70%, transparent); }
.road li { position: relative; padding: 26px 24px 0 0; }
.road li::before { content: ""; position: absolute; left: 0; top: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 1px var(--line-2); }
.road li:first-child::before { background: var(--accent); box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 18%, transparent); }
.road .mono-s { display: block; }
.road li:first-child .mono-s { color: var(--accent); }
.road .h-item { margin-top: 6px; }
.road p.small { margin-top: 4px; max-width: 26ch; }
.road-note { margin-top: 32px; }

/* contact */
.iclose .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: 48px; align-items: end; }
form.req { display: grid; gap: 10px; }
.ifield { display: flex; gap: 6px; padding: 5px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line-2); background: color-mix(in srgb, var(--bg-2) 60%, transparent);
  transition: box-shadow 0.25s var(--ease); }
.ifield:focus-within { box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent); }
.ifield input { flex: 1; min-width: 0; height: 38px; padding: 0 14px; border: 0; outline: 0; background: transparent; font-size: 15px; }
.ifield input::placeholder { color: var(--fg-3); }
.req .note { font-family: var(--font-mono); font-size: 11px; color: var(--fg-3); padding-left: 16px; min-height: 1.4em; }
.req .note.ok { color: var(--accent); }

.ifoot { border-top: 1px solid var(--line); }
.ifoot .wrap { height: 72px; display: flex; align-items: center; justify-content: space-between; font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-3); }

/* --- astrolabe ---------------------------------------------------------- */
.astro { position: relative; aspect-ratio: 1; }
.astro > svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.ast-c { fill: none; stroke: var(--ast-ink); stroke-width: 1; vector-effect: non-scaling-stroke; }
.ast-c2 { fill: none; stroke: var(--ast-ring); stroke-width: 1; vector-effect: non-scaling-stroke; }
.ast-tk { stroke: var(--ast-ink); stroke-width: 1; vector-effect: non-scaling-stroke; }
.ast-tk.mn { stroke: var(--ast-minor); }
.ast-deg { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.08em; fill: var(--ast-label); text-anchor: middle; }
.ast-ins { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.3em; fill: var(--ast-accent); text-transform: uppercase; }
.ast-card { fill: var(--ast-accent); }
.astro .core { position: absolute; inset: 31%; color: var(--mark); }
.astro .core .mark { width: 100%; height: 100%; }

/* the light that walks the ring, finds the gap, climbs to the datum */
.mark .lp { fill: none; stroke: var(--lp); stroke-linecap: round; filter: drop-shadow(0 0 3px var(--accent)) drop-shadow(0 0 7px var(--accent)); }
.mark .lp-ring { stroke-width: 8; stroke-dasharray: 0.06 1.2; stroke-dashoffset: 0.06; animation: lp-walk 9s var(--ease-in-out) 1.2s infinite; }
.mark .lp-plumb { stroke-width: 5; stroke-dasharray: 0.3 1.4; stroke-dashoffset: 0.3; opacity: 0; animation: lp-climb 9s var(--ease-in-out) 1.2s infinite; }
.mark .lp-flare { fill: var(--lp); opacity: 0; transform-box: fill-box; transform-origin: center; animation: lp-flare 9s var(--ease-out) 1.2s infinite; }
.mark .lp-halo { fill: none; stroke: var(--accent); stroke-width: 0.8; opacity: 0; animation: lp-halo 9s var(--ease-out) 1.2s infinite; }
@keyframes lp-walk { 0% { stroke-dashoffset: 0.06; opacity: 0; } 4% { opacity: 1; } 52% { stroke-dashoffset: -1; opacity: 1; } 56%, 100% { stroke-dashoffset: -1; opacity: 0; } }
@keyframes lp-climb { 0%, 52% { stroke-dashoffset: 0.3; opacity: 0; } 54% { opacity: 1; } 66% { stroke-dashoffset: -1; opacity: 1; } 68%, 100% { stroke-dashoffset: -1; opacity: 0; } }
@keyframes lp-flare { 0%, 64% { opacity: 0; transform: scale(1); } 67% { opacity: 1; transform: scale(1.35); } 85%, 100% { opacity: 0; transform: scale(1); } }
@keyframes lp-halo { 0%, 65% { opacity: 0; r: 5; } 67% { opacity: 0.9; } 95%, 100% { opacity: 0; r: 38; } }

/* reveal */
.js .rv { opacity: 0; transform: translateY(12px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }
.js .rv.in { opacity: 1; transform: none; }

@media (max-width: 980px) {
  .inav { display: none; }
  .ihdr .ibtn { margin-left: auto; }
  .ihead, .iclose .wrap { grid-template-columns: 1fr; }
  .ihead .small { justify-self: start; }
  .marks4 { grid-template-columns: 1fr 1fr; }
  .marks4 > div:nth-child(3) { border-left: 0; padding-left: 0; }
  .marks4 > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .road { grid-template-columns: 1fr 1fr; row-gap: 32px; }
  .road::before { display: none; }
}
@media (max-width: 560px) {
  .marks4, .road { grid-template-columns: 1fr; }
  .marks4 > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); }
  .feats li { grid-template-columns: 1fr; gap: 2px; }
  .ibtn, .ibtn.sm, .ilink { min-height: 44px; }
  .ilink { display: inline-flex; align-items: center; }
  .eyebrow { flex-wrap: wrap; }
  .ifoot .wrap { height: auto; min-height: 84px; padding-block: 18px 62px; gap: 12px; flex-wrap: wrap; }
  .readout pre { font-size: 11px; }
}
