/* iLive Technologies — site styles
   Palette derived from the iLive logo: blue, leaf green, flame orange.
   Type: IBM Plex (IBM's own family — subject-native for an IBM i audience). */

:root {
  /* neutrals — off-white with a faint green bias, ink with a blue-green bias */
  --paper:      #F7F8F5;
  --paper-2:    #EEF1EC;
  --paper-3:    #E2E7E0;
  --ink:        #0F1922;
  --ink-2:      #34424D;
  --ink-3:      #61707B;
  --rule:       #D5DCD4;

  /* brand */
  --blue:       #1A4F9C;
  --blue-soft:  #2E6BC4;
  --green:      #5D9E32;
  --green-soft: #7FBE45;
  --flame:      #E4551F;

  /* terminal artifact only */
  --term-bg:    #0A1014;
  --term-phos:  #3FD07A;
  --term-dim:   #1E6B45;

  --measure: 68ch;
  --gutter: 20px;
  --maxw: 1100px;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper:      #0D151B;
    --paper-2:    #141F27;
    --paper-3:    #1C2B35;
    --ink:        #E8EDE9;
    --ink-2:      #B3C0BA;
    --ink-3:      #7E8E88;
    --rule:       #24343E;
    --blue:       #6FA8E8;
    --blue-soft:  #8FBFF2;
    --green:      #8FCB55;
    --green-soft: #A6D973;
    --flame:      #F5764A;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --paper:      #0D151B;
  --paper-2:    #141F27;
  --paper-3:    #1C2B35;
  --ink:        #E8EDE9;
  --ink-2:      #B3C0BA;
  --ink-3:      #7E8E88;
  --rule:       #24343E;
  --blue:       #6FA8E8;
  --blue-soft:  #8FBFF2;
  --green:      #8FCB55;
  --green-soft: #A6D973;
  --flame:      #F5764A;
  color-scheme: dark;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "IBM Plex Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16.5px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; }

/* ---------- layout ---------- */

.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.prose { max-width: var(--measure); }

section { padding-block: clamp(36px, 4vw, 56px); }
section + section { border-top: 1px solid var(--rule); }

/* The header already separates the first section — the full inter-section
   padding on top of it reads as dead space, especially on wide screens. */
main > section:first-child { padding-block-start: clamp(22px, 2.4vw, 32px); }

/* ---------- type ---------- */

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.021em;
  text-wrap: balance;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.05rem, 5.2vw, 3.3rem); }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.05rem); margin-bottom: 0.7em; }
h3 { font-size: 1.12rem; letter-spacing: -0.01em; }

p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: clamp(1.08rem, 2.1vw, 1.3rem);
  line-height: 1.55;
  color: var(--ink-2);
}

.eyebrow {
  font-family: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 1.1em;
  display: block;
}

.mono {
  font-family: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: 0.86em;
}

a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--flame); }

:focus-visible {
  outline: 2px solid var(--flame);
  outline-offset: 2px;
  border-radius: 2px;
}

strong { font-weight: 600; }

/* ---------- header ---------- */

.site-head {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 20;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}

.head-in {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: 13px var(--gutter);
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.mark {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.mark img {
  display: block;
  height: 54px;
  width: auto;
}
@media (max-width: 460px) { .mark img { height: 42px; } }

nav.main { display: flex; gap: 20px; flex-wrap: wrap; margin-left: auto; }
nav.main a {
  font-size: 0.9rem;
  color: var(--ink-2);
  text-decoration: none;
}
nav.main a:hover, nav.main a[aria-current="page"] { color: var(--ink); }
nav.main a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--green); }

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.83rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 11px 19px;
  border-radius: 3px;
  text-decoration: none;
  border: 1px solid transparent;
}
.btn-primary { background: var(--flame); color: #fff; }
.btn-primary:hover { background: var(--ink); color: #fff; }
.btn-ghost { border-color: var(--rule); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }

.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }

/* ---------- hero terminal/browser pair ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 40px;
  align-items: stretch;
}
@media (max-width: 720px) { .split { grid-template-columns: 1fr; } }

/* Each column is a flex column so the panel BODY absorbs the spare
   height. The panels used to be height:100%, which resolves against
   the grid item -- and the grid item also holds the panel label above
   them, so each panel rendered one label taller than its own container
   and overlapped the caption underneath. min-width:0 lets the
   overflow-x on .term scroll instead of widening the column. */
.split > div {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.panel-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}

.term {
  background: var(--term-bg);
  border: 1px solid #16232B;
  border-radius: 4px;
  padding: 16px 15px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  line-height: 1.75;
  color: var(--term-phos);
  overflow-x: auto;
  flex: 1;
}
.term .dim { color: var(--term-dim); }
.term .hl { background: var(--term-phos); color: var(--term-bg); }
.term pre { margin: 0; font: inherit; }

.browser {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 4px;
  overflow: hidden;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.browser-bar {
  background: var(--paper-3);
  border-bottom: 1px solid var(--rule);
  padding: 7px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--rule); }
.browser-body { padding: 15px; flex: 1; }

.rec-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 2px;
}
.rec-sub {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  color: var(--ink-3);
  margin: 0 0 13px;
}
.field-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 5px 14px;
  font-size: 0.8rem;
}
.field-grid dt { color: var(--ink-3); }
.field-grid dd { margin: 0; font-variant-numeric: tabular-nums; }
.pill {
  display: inline-block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  padding: 2px 8px;
  border-radius: 99px;
  background: color-mix(in srgb, var(--green) 18%, transparent);
  color: var(--green);
}

/* ---------- tables ---------- */

.table-scroll { overflow-x: auto; margin-block: 26px; }
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.9rem;
  min-width: 520px;
}
th, td {
  text-align: left;
  padding: 11px 14px 11px 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
th {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
  border-bottom-color: var(--ink-3);
}

/* ---------- phase ladder ---------- */

.ladder { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: 4px; overflow: hidden; margin-top: 28px; }
.rung { background: var(--paper); padding: 16px 18px; display: grid; grid-template-columns: 116px 1fr auto; gap: 18px; align-items: baseline; }
@media (max-width: 640px) { .rung { grid-template-columns: 1fr; gap: 5px; } }
.rung-n { font-family: "IBM Plex Mono", monospace; font-size: 0.76rem; letter-spacing: 0.08em; color: var(--blue); text-transform: uppercase; }
.rung-d { color: var(--ink-2); font-size: 0.92rem; }
.risk { font-family: "IBM Plex Mono", monospace; font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; }

/* ---------- misc blocks ---------- */

.claim {
  border-left: 2px solid var(--green);
  padding-left: 20px;
  margin-block: 30px;
  font-size: 1.12rem;
  line-height: 1.5;
  color: var(--ink);
  max-width: var(--measure);
}

.checks { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 9px; max-width: var(--measure); }
.checks li { padding-left: 24px; position: relative; color: var(--ink-2); font-size: 0.94rem; }
.checks li::before {
  content: "—";
  position: absolute; left: 0; top: 0;
  font-family: "IBM Plex Mono", monospace;
  color: var(--green);
}

.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 30px; margin-top: 34px; }
.col h3 { margin-bottom: 0.35em; }
.col p { font-size: 0.93rem; color: var(--ink-2); }

.note {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 18px 20px;
  font-size: 0.92rem;
  color: var(--ink-2);
  max-width: var(--measure);
  margin-top: 26px;
}
.note strong { color: var(--ink); }

.price {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.95rem;
  color: var(--ink);
  white-space: nowrap;
}

/* ---------- footer ---------- */

.site-foot {
  border-top: 1px solid var(--rule);
  padding-block: 40px 52px;
  font-size: 0.87rem;
  color: var(--ink-3);
}
.foot-in { display: flex; gap: 30px; flex-wrap: wrap; justify-content: space-between; }
.site-foot a { color: var(--ink-2); text-decoration: none; }
.site-foot a:hover { color: var(--flame); }
.foot-links { display: flex; gap: 18px; flex-wrap: wrap; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ---------- contact form ---------- */

.form {
  max-width: 560px;
  margin-top: 30px;
  display: grid;
  gap: 18px;
}

.field { display: grid; gap: 6px; }

.field label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.field label .req { color: var(--flame); }

.field input,
.field select,
.field textarea {
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 10px 12px;
  width: 100%;
}
.field textarea { resize: vertical; min-height: 96px; line-height: 1.55; }
.field select { appearance: none; background-image: none; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--ink-3);
  outline: 2px solid var(--flame);
  outline-offset: 1px;
}

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }

/* honeypot — off-screen, never shown, not announced */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form button { cursor: pointer; font-family: "IBM Plex Mono", monospace; }
.form button[disabled] { opacity: 0.55; cursor: default; }

.form-note {
  font-size: 0.82rem;
  color: var(--ink-3);
  line-height: 1.5;
}

.form-status {
  font-size: 0.92rem;
  border-radius: 3px;
  padding: 12px 14px;
  border: 1px solid var(--rule);
  background: var(--paper-2);
}
.form-status.ok { border-color: var(--green); color: var(--ink); }
.form-status.err { border-color: var(--flame); color: var(--ink); }

.alt-contact {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--rule);
  max-width: 560px;
  font-size: 0.92rem;
  color: var(--ink-2);
}

/* ---------- myth / fact pairs ---------- */

.myths { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: 4px; overflow: hidden; margin-block: 30px; }
.myth { background: var(--paper); padding: 20px 22px; display: grid; grid-template-columns: 1fr 1.25fr; gap: 26px; }
@media (max-width: 720px) { .myth { grid-template-columns: 1fr; gap: 12px; } }

.myth-claim { color: var(--ink-3); }
.myth-claim::before {
  content: "Commonly believed";
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 8px;
}
.myth-fact::before {
  content: "Actually";
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 8px;
}
.myth-fact { color: var(--ink); }
.myth p { margin: 0; font-size: 0.94rem; line-height: 1.55; }

.caveat {
  border-left: 2px solid var(--flame);
  padding-left: 20px;
  margin-block: 30px;
  max-width: var(--measure);
  color: var(--ink-2);
}

/* ---------- drawback / mitigation pairs ---------- */

.tradeoffs { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: 4px; overflow: hidden; margin-block: 30px; }
.tradeoff { background: var(--paper); padding: 20px 22px; display: grid; grid-template-columns: 1fr 1.25fr; gap: 26px; }
@media (max-width: 720px) { .tradeoff { grid-template-columns: 1fr; gap: 12px; } }

.tradeoff-issue { color: var(--ink-3); }
.tradeoff-issue::before {
  content: "The drawback";
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--flame);
  margin-bottom: 8px;
}
.tradeoff-fix::before {
  content: "What you do about it";
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 8px;
}
.tradeoff-fix { color: var(--ink); }
.tradeoff p { margin: 0 0 0.6em; font-size: 0.94rem; line-height: 1.55; }
.tradeoff p:last-child { margin-bottom: 0; }
