:root {
    --paper:  #fbfaf8;
    --card:   #ffffff;
    --ink:    #191d23;
    --muted:  #5b6571;
    --line:   #e3e0da;
    --accent: #0f5c56;
    --accent-soft: #e8f1ef;
    --warn:   #8a5a12;
    --warn-bg:#fdf4e3;

    --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
    --sans: -apple-system, "Segoe UI", system-ui, sans-serif;
  }

  @media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
      --paper:  #14171b;
      --card:   #1b1f25;
      --ink:    #eceef1;
      --muted:  #a0a8b4;
      --line:   #2b3138;
      --accent: #5fb3a9;
      --accent-soft: #17302e;
      --warn:   #d9a555;
      --warn-bg:#2a2214;
    }
  }

  * { box-sizing: border-box; }
  body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
  }
  .wrap { max-width: 58rem; margin: 0 auto; padding: 0 1.5rem; }
  a { color: var(--accent); }

  /* ---- masthead ---- */
  .brandbar { padding: 2rem 0 0; }
  .wordmark {
    font-family: var(--serif);
    font-size: 1.3rem; font-weight: 600; letter-spacing: -.01em;
    color: var(--ink); text-decoration: none;
  }
  .wordmark span { color: var(--accent); }
  header { padding: 3.5rem 0 3.5rem; }
  .eyebrow {
    display: inline-block;
    font-size: .74rem; font-weight: 600;
    letter-spacing: .1em; text-transform: uppercase;
    color: var(--accent); background: var(--accent-soft);
    padding: .35rem .8rem; border-radius: 4px;
    margin-bottom: 1.6rem;
  }
  h1 {
    font-family: var(--serif);
    font-size: clamp(2.3rem, 5.5vw, 3.5rem);
    font-weight: 600; line-height: 1.12; letter-spacing: -.015em;
    margin: 0 0 1.1rem; text-wrap: balance;
    max-width: 20ch;
  }
  .standfirst {
    font-size: 1.16rem; color: var(--muted);
    max-width: 40rem; margin: 0 0 2.4rem;
  }
  .actions { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
  .btn {
    display: inline-block; background: var(--accent); color: #fff;
    font-weight: 600; font-size: 1rem; text-decoration: none;
    padding: .8rem 1.7rem; border-radius: 5px;
  }
  .btn:hover { filter: brightness(1.12); }
  .aside { font-size: .92rem; color: var(--muted); }

  /* ---- sections ---- */
  section { padding: 3.5rem 0; border-top: 1px solid var(--line); }
  h2 {
    font-family: var(--serif);
    font-size: 1.95rem; font-weight: 600; letter-spacing: -.01em;
    margin: 0 0 .7rem; text-wrap: balance;
  }
  .lede { color: var(--muted); max-width: 42rem; margin: 0 0 2rem; }

  .grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
  .card {
    background: var(--card); border: 1px solid var(--line);
    border-radius: 7px; padding: 1.35rem 1.45rem;
  }
  .card h3 { font-size: 1rem; font-weight: 650; margin: 0 0 .4rem; }
  .card p { margin: 0; font-size: .95rem; color: var(--muted); }

  /* ---- app list ---- */
  .apps { display: grid; gap: .55rem; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); }
  .app {
    display: flex; align-items: center; gap: .6rem;
    background: var(--card); border: 1px solid var(--line);
    border-radius: 6px; padding: .7rem .9rem; font-size: .94rem;
  }
  .tick { color: var(--accent); font-weight: 700; flex: none; }

  /* ---- measurement ---- */
  .table-scroll { overflow-x: auto; }
  table { width: 100%; border-collapse: collapse; font-size: .95rem; min-width: 26rem; }
  th {
    text-align: left; font-size: .72rem; font-weight: 600;
    letter-spacing: .09em; text-transform: uppercase; color: var(--muted);
    padding: 0 1rem .55rem 0; border-bottom: 1px solid var(--line);
  }
  td { padding: .6rem 1rem .6rem 0; border-bottom: 1px solid var(--line); }
  td.n { font-variant-numeric: tabular-nums; font-weight: 600; }
  tr:last-child td { border-bottom: none; }

  .note {
    font-size: .88rem; color: var(--muted);
    border-left: 2px solid var(--line); padding-left: 1rem; margin-top: 1.5rem;
  }

  /* ---- price ---- */
  .price-box {
    background: var(--card); border: 1px solid var(--line);
    border-radius: 8px; padding: 2rem;
    display: flex; flex-wrap: wrap; gap: 2.5rem; align-items: center;
  }
  .amount { font-family: var(--serif); font-size: 3.2rem; font-weight: 600; line-height: 1; }
  .amount small { display: block; font-family: var(--sans); font-size: .9rem; font-weight: 400; color: var(--muted); margin-top: .4rem; }
  .compare { flex: 1; min-width: 16rem; font-size: .95rem; color: var(--muted); }

  .status {
    background: var(--warn-bg); border: 1px solid var(--warn);
    color: var(--warn); border-radius: 7px;
    padding: 1.1rem 1.3rem; font-size: .95rem; margin-top: 2rem;
  }
  .status strong { color: var(--warn); }

  footer { padding: 3rem 0 5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
