/* How it works (redesigned 2026-10-20 to the founder's mockup): a hero with the lifecycle diagram (bring data,
   your LakehouseBox, connect tools; you choose where compute runs) and the structure strip; the admins' four steps;
   the tools grid; the capabilities as vertical tabs (how-it-works.js; without script every panel shows); where it
   fits (the comparison, folded); the closing call. Icons carry their size and colour in the markup. */

body.hiw .eyebrow { color: var(--accent); font-size: 11.5px; letter-spacing: .18em; margin: 0 0 14px; }
body.hiw h2 { max-width: none; }

/* hero */
.x-hero { padding: 44px 0 0; }
.x-hero-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 48px; align-items: center; }
.x-hero h1 { font-size: clamp(46px, 5vw, 72px); line-height: 1; margin: 0 0 24px; }
.x-sub { font-size: 17px; line-height: 1.6; color: var(--ink-soft); max-width: 46ch; margin: 0 0 28px; }
.x-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 18px; }
.x-ctas .btn { font-family: var(--sans); font-size: 15px; font-weight: 500; padding: 12px 20px; }
.x-hero .fine { font-size: 13.5px; margin: 0; }

.x-flow { margin: 0; }
.x-flow-grid { display: grid; grid-template-columns: minmax(0, 1fr) 34px minmax(0, 1.15fr) 34px minmax(0, 1fr); align-items: stretch; }
.x-lane { background: #eaf4f8; border-radius: 12px; padding: 14px 12px; display: grid; gap: 10px; align-content: center; }
.x-lane-h { margin: 0 0 2px 4px; font-size: 13px; font-weight: 500; color: var(--ink); }
.x-node { display: flex; gap: 10px; align-items: flex-start; background: #fff; border-radius: 8px; padding: 11px 12px; box-shadow: 0 1px 2px rgba(24, 60, 78, .06); }
.x-node svg { flex: none; margin-top: 1px; }
.x-node b { display: block; font-size: 14px; font-weight: 500; color: var(--ink); }
.x-node span { display: block; font-size: 12px; line-height: 1.35; color: var(--muted); }
.x-core { background: #dcedf5; padding: 16px 14px; border: 1px solid #c9dde6; box-shadow: 0 16px 34px rgba(24, 60, 78, .12); }
.x-core-h { display: flex; align-items: center; gap: 10px; margin: 0 0 4px; font-family: var(--serif); font-size: 19px; color: var(--ink); white-space: nowrap; }
.x-node.big { padding: 18px 16px; }
.x-node.big b { font-size: 15.5px; }
.x-join { width: 100%; height: 100%; }
.x-compute { position: relative; margin: 22px auto 0; width: max-content; max-width: 100%; border: 1px dashed #b9b2a8; border-radius: 10px; padding: 14px 22px; text-align: center; font-size: 13px; color: var(--muted); }
.x-compute::before { content: ""; position: absolute; left: 50%; top: -23px; height: 22px; border-left: 1px dashed #b9b2a8; }
.x-compute-icons { display: flex; justify-content: center; gap: 22px; margin-bottom: 6px; }

.x-structure { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 40px; margin-top: 44px; padding: 22px 0; border-top: 1px solid var(--rule); }
body.hiw .x-structure h2 { font-size: 24px; margin: 0; letter-spacing: -.01em; }
.x-structure ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 0; flex: 1; justify-content: center; }
.x-structure li { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink); }
.x-structure li + li::before { content: "⟶"; color: var(--ink-soft); margin: 0 20px; }
.x-structure p { margin: 0; font-size: 13.5px; color: var(--muted); }

/* admins */
.x-admins { background: var(--bg-soft); padding: 40px 0 46px; }
.x-admins h2, .x-tools h2, .x-hood h2 { font-size: clamp(32px, 3.4vw, 46px); margin: 0 0 30px; }
.x-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 26px; }
.x-step-top { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; }
.x-step-top .n { font-family: var(--serif); font-size: 34px; color: #b9b2a8; line-height: 1; }
.x-step-top svg { flex: none; }
.x-steps li:not(:last-child) .x-step-top::after { content: ""; flex: 1; height: 1px; background: #e9a58c; }
.x-steps h3 { font-family: var(--serif); font-size: 20px; font-weight: 500; margin: 0 0 6px; padding-left: 38px; }
.x-steps p:not(.x-step-top) { margin: 0; padding-left: 38px; font-size: 14px; line-height: 1.55; color: var(--ink-soft); }

/* tools */
.x-tools { padding: 44px 0 30px; }
.x-tool-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.x-tool-grid li { display: flex; gap: 20px; padding: 22px 26px 24px 18px; border-bottom: 1px solid var(--rule); }
.x-tool-grid li:nth-child(3n+1), .x-tool-grid li:nth-child(3n+2) { border-right: 1px solid var(--rule); }
.x-tool-grid li:nth-last-child(-n+3) { border-bottom: 0; }
.x-tool-grid svg { flex: none; }
.x-tool-grid h3 { font-family: var(--serif); font-size: 20px; font-weight: 500; margin: 0 0 6px; }
.x-tool-grid p { margin: 0 0 10px; font-size: 14px; line-height: 1.5; color: var(--muted); }
.x-tool-grid a { font-size: 13.5px; color: var(--accent-deep); }
.x-tag { display: inline-block; font: 600 10px var(--mono); letter-spacing: .06em; text-transform: uppercase; border-radius: 4px; padding: 2px 7px; vertical-align: 3px; margin-left: 6px; }
.x-tag.pv { background: var(--lake); color: #1f5f86; }
.x-tag.pl { background: #e3f4ea; color: var(--ok-text); }
.x-tag.ent { background: var(--tint); color: var(--accent-deep); }

/* under the hood */
.x-hood { background: var(--bg-soft); padding: 40px 0 0; }
.x-hood h2 { margin-bottom: 6px; }
.x-lead { margin: 0 0 26px; font-size: 16px; color: var(--ink-soft); }
.x-tabs { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 24px; background: #fff; border-radius: 12px 12px 0 0; padding: 12px 0 0; }
.x-tablist { display: flex; flex-direction: column; gap: 2px; padding: 0 0 12px; }
.x-tablist button { display: flex; align-items: center; gap: 12px; text-align: left; border: 0; border-left: 3px solid transparent; background: none; padding: 10px 14px; font: 14px var(--sans); color: var(--ink-soft); cursor: pointer; border-radius: 0 6px 6px 0; }
.x-tablist button:hover { background: var(--bg-soft); color: var(--ink); }
.x-tablist button[aria-selected="true"] { background: #e7f2f8; border-left-color: var(--accent); color: var(--ink); font-weight: 500; }
.x-tablist button svg { color: var(--accent); flex: none; }
.x-panels { padding: 10px 28px 26px 0; min-width: 0; }
.x-panel { scroll-margin-top: 90px; }
.x-tabs:not(.js) .x-tablist { display: none; }
.x-tabs:not(.js) { grid-template-columns: minmax(0, 1fr); padding: 12px 28px; }
.x-tabs:not(.js) .x-panel + .x-panel { margin-top: 36px; padding-top: 30px; border-top: 1px solid var(--rule); }
.x-tabs.js .x-panel[hidden] { display: none; }
.x-panel h3 { font-family: var(--serif); font-size: 26px; font-weight: 500; margin: 0 0 6px; }
.x-panel-lead { margin: 0 0 18px; font-size: 14px; color: var(--muted); }
.x-feats { list-style: none; margin: 0 0 20px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.x-feats li { padding: 14px 22px 14px 0; border-bottom: 1px solid var(--rule); font-size: 13.5px; line-height: 1.5; color: var(--muted); }
.x-feats li:nth-child(odd) { border-right: 1px solid var(--rule); }
.x-feats li:nth-child(even) { padding-left: 22px; }
.x-feats b { display: block; font-family: var(--serif); font-size: 17px; font-weight: 500; color: var(--ink); margin-bottom: 4px; }
.x-feats code { font-size: 12px; }
.x-code { background: #1c1f22; border-radius: 8px; margin: 0 0 16px; overflow: hidden; }
.x-code p { display: flex; justify-content: space-between; align-items: center; margin: 0; padding: 8px 14px; font: 11px var(--mono); color: #9aa1a6; border-bottom: 1px solid #2c3135; }
.x-copy { background: none; border: 0; color: #d7dadc; font: 11.5px var(--sans); cursor: pointer; }
.x-code pre { margin: 0; padding: 14px; font: 13px/1.6 var(--mono); color: #e6e1da; overflow-x: auto; }
.x-code .k { color: #f2825a; } .x-code .s { color: #8fc7e8; }
.x-more { font-size: 14px; color: var(--accent-deep); }
.x-details { margin: 0 0 18px; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.x-details summary { cursor: pointer; padding: 12px 0; font-size: 14.5px; font-weight: 500; color: var(--ink); }
.x-details table { display: block; overflow-x: auto; font-size: 13.5px; margin-bottom: 12px; }

/* where it fits */
.x-fits { border-bottom: 1px solid var(--rule); }
.x-fit summary { list-style: none; cursor: pointer; display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 22px; padding: 26px 0; }
.x-fit summary::-webkit-details-marker { display: none; }
.x-fit-h { font-family: var(--serif); font-size: 24px; color: var(--ink); }
.x-fit-sub { font-size: 13.5px; color: var(--muted); flex: 1; }
.x-fit-link { font-size: 14px; color: var(--accent-deep); }
.x-fit[open] .x-fit-link span { display: inline-block; transform: rotate(90deg); }
.x-cmp-wrap { overflow-x: auto; border: 1px solid var(--rule); border-radius: 12px; background: #fff; }
body.hiw table.plain.x-cmp { width: 100%; min-width: 820px; border-collapse: collapse; font-size: 14px; line-height: 1.45; margin: 0; }
body.hiw table.plain.x-cmp th, body.hiw table.plain.x-cmp td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--rule); }
body.hiw table.plain.x-cmp tbody tr:last-child > * { border-bottom: 0; }
body.hiw table.plain.x-cmp thead th { background: var(--bg-soft); }
body.hiw table.plain.x-cmp tbody th { font: 500 14px var(--sans); text-transform: none; letter-spacing: 0; color: var(--ink); width: 15%; }
body.hiw table.plain.x-cmp td { color: var(--ink-soft); }
body.hiw table.plain.x-cmp td:nth-child(2), body.hiw table.plain.x-cmp thead th:nth-child(2) { background: var(--tint); color: var(--ink); }
.x-fit-note { font-size: 14px; color: var(--muted); margin: 14px 0 28px; max-width: 90ch; }

/* start */
.x-start { background: var(--bg-soft); padding: 34px 0; }
.x-start-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.x-start h2 { font-size: clamp(32px, 3.4vw, 46px); margin: 0 0 6px; }
.x-start p { margin: 0; color: var(--ink-soft); font-size: 16px; }
.x-start .x-ctas { margin: 0; }

@media (max-width: 1100px) {
  .x-hero-grid { grid-template-columns: minmax(0, 1fr); }
  .x-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-tool-grid li { border-right: 0 !important; border-bottom: 1px solid var(--rule) !important; }
}
@media (max-width: 760px) {
  .x-flow-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .x-join { display: none; }
  .x-steps, .x-tool-grid, .x-feats { grid-template-columns: minmax(0, 1fr); }
  .x-feats li { border-right: 0 !important; padding-left: 0 !important; }
  .x-tabs.js { grid-template-columns: minmax(0, 1fr); padding: 12px 16px 0; }
  .x-tabs.js .x-tablist { flex-direction: row; overflow-x: auto; }
  .x-tablist button { white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; border-radius: 6px 6px 0 0; }
  .x-tablist button[aria-selected="true"] { border-bottom-color: var(--accent); }
  .x-panels { padding: 10px 0 20px; }
  .x-tabs:not(.js) { padding: 12px 16px; }
  .x-structure li + li::before { margin: 0 10px; }
}
