/* The Pip hardware fit panel.

   These rules used to sit in pip.css, which only the marketing landing page
   loads. The panel now also renders inside the signup flow (views/pages/
   pip-plans.ejs), whose stylesheet is pip-account.css, so the panel keeps its
   own file and both pages link it. One copy, not two.

   Two things make that portable:

   1. Custom properties. pip-account.css defines --ink, --muted, --line,
      --paper, --orange and --orange2; it has never defined --cream, --blue,
      --green, --night or --orange-dark. Every var() below carries the
      landing-page value as its fallback, so a rule renders the same whether or
      not the host stylesheet happens to define the name.

   2. Buttons. The panel's three buttons took their shape from `.button` in
      pip.css. pip-account.css has no `.button` at all - it styles bare
      <button> instead - so those declarations are written out in full here,
      scoped under .hardware-check to stay ahead of both. The values are the
      ones that were already winning on /pip, so that page is unchanged.

   The landing-page furniture around the panel (.hardware-lab, .fit-facts, the
   mascot, the speech bubble) stayed in pip.css: only /pip has it. */

/* The panel hides its verdict, its waitlist and its continue link with the
   hidden attribute, and any author `display` beats the browser's [hidden] rule.
   Several below have to declare one - to hold their shape against a host
   stylesheet - so this keeps the attribute meaning what it says. */
.hardware-check [hidden] { display: none !important; }

.hardware-check {
    display: grid;
    grid-template-columns: .95fr 1.05fr;
    gap: 60px;
    align-items: center;
    margin-top: 42px;
    padding: 44px;
    border: 1px solid rgba(68, 114, 118, .16);
    border-radius: 30px;
    background: rgba(241, 251, 252, .88);
    box-shadow: 0 30px 80px rgba(60, 91, 94, .1);
}

/* .plain-kicker is a landing-page utility the panel borrows. Repeated here,
   scoped, so the signup flow gets it without pip.css. */
.hardware-check .plain-kicker { padding-top: 5px; color: #55767a; font-size: 12px; font-weight: 720; letter-spacing: .12em; text-transform: uppercase; }
.hardware-check-copy .plain-kicker { margin: 0 0 17px; }
.hardware-check-copy h3 { max-width: 520px; margin: 0; font-size: clamp(28px, 3.4vw, 45px); letter-spacing: -.045em; line-height: 1.08; }
.hardware-check-copy > p:not(.plain-kicker) { max-width: 590px; margin: 20px 0 0; color: #5e6f70; font-size: 15px; line-height: 1.7; }
.hardware-check-copy .hardware-supported { margin-top: 12px; color: #345d60; font-size: 12px; }
.privacy-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 26px; padding: 14px 16px; border: 1px solid rgba(65,107,111,.14); border-radius: 13px; background: rgba(255,255,255,.65); color: #416b6f; font-size: 12px; line-height: 1.55; }
.privacy-note svg { flex: 0 0 auto; margin-top: 1px; }
.privacy-note strong { color: #254f52; }

.hardware-check-panel {
    padding: 26px;
    border: 1px solid #ded9d2;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 14px 35px rgba(57, 75, 76, .08);
}

.hardware-panel-header {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 20px;
}

.hardware-panel-header p {
    margin: 0 0 4px;
    color: var(--muted, #736c62);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hardware-panel-header h3 {
    margin: 0;
    font-size: 23px;
    letter-spacing: -.035em;
    line-height: 1.2;
}

.hardware-private-badge {
    display: inline-flex;
    flex: 0 0 auto;
    gap: 6px;
    align-items: center;
    padding: 7px 9px;
    border: 1px solid #cfe2dc;
    border-radius: 999px;
    background: #f4faf7;
    color: #246247;
    font-size: 11px;
    font-weight: 700;
}

.hardware-platforms {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    margin-bottom: 0;
    padding: 4px;
    border-radius: 11px;
    background: #eeece8;
}

/* padding is spelled out because pip-account.css pads every bare <button>. */
.hardware-platforms button {
    min-height: 36px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--muted, #736c62);
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
}

.hardware-platforms button.is-selected {
    background: white;
    color: var(--ink, #25211e);
    box-shadow: 0 1px 4px rgba(37, 33, 30, .12);
}

.hardware-form-step {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ebe7e1;
}

.hardware-step-heading {
    display: grid;
    grid-template-columns: 27px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    margin-bottom: 12px;
}

.hardware-step-heading > span {
    display: grid;
    width: 27px;
    height: 27px;
    place-items: center;
    border-radius: 50%;
    background: var(--ink, #25211e);
    color: white;
    font-size: 11px;
    font-weight: 750;
}

.hardware-step-heading strong {
    display: block;
    margin-top: 1px;
    color: var(--ink, #25211e);
    font-size: 13px;
}

.hardware-step-heading p {
    margin: 3px 0 0;
    color: var(--muted, #736c62);
    font-size: 12px;
    line-height: 1.5;
}

/* The command is the one thing on this panel we ask a non-technical person to
   audit before running: "Read it first, then paste it here when you are
   comfortable." It used to be set in 10px on a single nowrap line inside a
   horizontally scrolling box, so reading it meant dragging a scrollbar through
   roughly four screens of text. Nobody did. It wraps now, at a size a person
   can actually read, and grows to about eight lines before it scrolls
   vertically - which is a familiar direction, and keeps the paste box in view. */
.hardware-command-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: stretch;
    overflow: hidden;
    border: 1px solid #dcd7d0;
    border-radius: 10px;
    background: #292624;
}

.hardware-command-wrap code {
    max-height: 190px;
    overflow-y: auto;
    padding: 13px;
    color: #f9f5ef;
    font: 12px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

/* What a working result looks like, so there is something to compare against.
   Quieter than the command: this one is read, never run. */
.hardware-example {
    margin-bottom: 12px;
    padding: 12px 13px;
    border: 1px solid #dfe8e2;
    border-radius: 10px;
    background: #f6faf8;
}

.hardware-example p { margin: 0 0 8px; color: #3f6a58; font-size: 11px; line-height: 1.5; }
.hardware-example strong { color: #24543f; }

.hardware-example code {
    display: block;
    max-height: 96px;
    overflow-y: auto;
    color: #35594a;
    font: 11px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

/* The "it did not work" path. Same disclosure shape as the six-details list,
   because it sits beside it and is the same kind of thing: something you open
   only if you want it. */
.hardware-trouble-body { padding: 4px 13px 14px; }
.hardware-trouble-body ul { margin: 0; padding-left: 17px; color: var(--muted, #736c62); font-size: 11px; line-height: 1.55; }
.hardware-trouble-body li { padding: 4px 0; }
.hardware-manual-intro { margin: 13px 0 0; padding-top: 12px; border-top: 1px solid #e9e5df; color: var(--muted, #736c62); font-size: 11px; line-height: 1.55; }

/* display and gap are spelled out because pip-account.css lays every bare
   <form> out as a 16px grid with a 26px top margin, which is far too loose
   inside a disclosure. */
.hardware-manual { display: grid; gap: 10px; margin: 12px 0 0; }
.hardware-manual-field { display: grid; gap: 5px; margin: 0; color: var(--ink, #25211e); font-size: 11px; font-weight: 700; }
.hardware-manual-field select,
.hardware-manual-field input[type="number"] {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid #dcd7d0;
    border-radius: 9px;
    background: #fff;
    color: var(--ink, #25211e);
    font: inherit;
    font-size: 12px;
    font-weight: 450;
}

.hardware-manual-field select:focus,
.hardware-manual-field input[type="number"]:focus { outline: 3px solid rgba(240, 84, 63, .18); border-color: var(--orange, #f0543f); }
.hardware-manual-hint { margin: 0; color: var(--muted, #736c62); font-size: 10px; line-height: 1.5; }
.hardware-check .hardware-manual button { min-height: 38px; padding: 0 14px; border: 0; border-radius: 9px; background: var(--ink, #25211e); color: #fff; cursor: pointer; font: inherit; font-size: 12px; font-weight: 700; }

.hardware-command-wrap button {
    min-width: 60px;
    padding: 0 12px;
    border: 0;
    border-radius: 0;
    border-left: 1px solid rgba(255,255,255,.14);
    background: #3b3734;
    color: white;
    cursor: pointer;
    font: inherit;
    font-size: 11px;
    font-weight: 700;
}

.hardware-read-first { margin: 8px 0 0; color: var(--muted, #736c62); font-size: 11px; line-height: 1.5; }

.hardware-script-link {
    display: inline-block;
    color: #35696c;
    font-size: 11px;
}

.hardware-details {
    margin-bottom: 16px;
    border: 1px solid #e5e0d9;
    border-radius: 10px;
    background: #fbfaf8;
}

.hardware-details summary {
    padding: 11px 13px;
    color: #575047;
    cursor: pointer;
    font-size: 11px;
    font-weight: 700;
}

.hardware-details[open] summary { border-bottom: 1px solid #e5e0d9; }
.hardware-details ul { margin: 0; padding: 0 13px 8px; list-style: none; }
.hardware-details li { display: flex; justify-content: space-between; gap: 20px; padding: 9px 0; border-bottom: 1px solid #e9e5df; color: var(--muted, #736c62); font-size: 11px; }
.hardware-details li:last-child { border-bottom: 0; }
.hardware-check-panel output { color: var(--ink, #25211e); font-weight: 650; text-align: right; }
.hardware-result-label { display: block; margin: 0 0 7px 37px; color: var(--ink, #25211e); font-size: 11px; font-weight: 700; }
.hardware-check-panel textarea { width: 100%; min-height: 82px; margin: 0 0 10px; padding: 11px 12px; resize: vertical; border: 1px solid #dcd7d0; border-radius: 10px; background: #fbfaf8; color: var(--ink, #25211e); font: 11px/1.45 ui-monospace, SFMono-Regular, Menlo, monospace; }
.hardware-check-panel textarea:focus { outline: 3px solid rgba(240, 84, 63, .18); border-color: var(--orange, #f0543f); }
.hardware-check-status { margin: 12px 0 0; color: #7c756c; font-size: 11px; text-align: center; }

/* The shape `.button` gave these on /pip, written out so the signup flow gets
   the same buttons from this file alone. */
.hardware-check .button {
    display: inline-flex;
    min-height: 52px;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 0 25px;
    border: 1px solid transparent;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 720;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.hardware-check .button:hover { transform: translateY(-2px); }
.hardware-check .button:focus-visible { outline: 3px solid rgba(240, 84, 63, .34); outline-offset: 3px; }
.hardware-check .hardware-check-button { width: 100%; border: 0; background: var(--orange, #f0543f); color: white; cursor: pointer; box-shadow: none; }
.hardware-check .hardware-check-button:hover { background: var(--orange-dark, #d9412d); }
.hardware-check .hardware-check-button[disabled] { cursor: wait; opacity: .7; }

/* Where the panel runs inside the signup flow the continue link is the way
   back to the plan grid, so it reads as a button. The landing page keeps the
   quieter link it has today. */
.hardware-check[data-hardware-continue-always] .hardware-continue { margin-top: 14px; background: var(--ink, #25211e); color: white; }

.hardware-verdict {
    margin-top: 18px;
    padding: 16px;
    border: 1px solid #baddc9;
    border-radius: 12px;
    background: #effaf4;
}

.hardware-verdict[data-compatibility="limited"] {
    border-color: #e5c989;
    background: #fff9e9;
}

.hardware-verdict[data-compatibility="unsupported"] {
    border-color: #ebbbb4;
    background: #fff4f2;
}

.hardware-verdict strong { font-size: 14px; }
.hardware-verdict p { margin: 6px 0 0; color: #5e5850; font-size: 12px; line-height: 1.5; }

/* display is spelled out because pip-account.css lays every bare <form> out as
   a 16px grid, which would pull this one apart. */
.hardware-waitlist {
    display: block;
    margin-top: 14px;
    padding: 17px;
    border: 1px solid #ded9d2;
    border-radius: 12px;
    background: white;
}

.hardware-waitlist > label:first-child { display: block; margin-bottom: 9px; color: var(--ink, #25211e); font-size: 13px; font-weight: 700; }
.hardware-waitlist > input[type="email"] { width: 100%; height: 42px; padding: 0 12px; border: 1px solid #d7d1ca; border-radius: 9px; background: white; color: var(--ink, #25211e); font: inherit; font-size: 13px; }
.hardware-waitlist > input[type="email"]:focus { outline: 3px solid rgba(240, 84, 63, .18); border-color: var(--orange, #f0543f); }
.hardware-consent { display: flex; gap: 8px; align-items: flex-start; margin: 11px 0 13px; color: var(--muted, #736c62); font-size: 10px; line-height: 1.45; }
/* pip-account.css styles every bare <input> as a full-width text field, which
   would swell this checkbox into a box the width of the form. */
.hardware-consent input[type="checkbox"] { width: auto; margin: 2px 0 0; padding: 0; border: 0; background: none; -webkit-appearance: checkbox; appearance: auto; }
.hardware-check .hardware-waitlist .button { width: 100%; min-height: 42px; border: 0; background: var(--ink, #25211e); color: white; cursor: pointer; }
.hardware-check .hardware-waitlist .button:disabled { cursor: wait; opacity: .65; }
.hardware-waitlist p { margin: 10px 0 0; color: var(--muted, #736c62); font-size: 11px; line-height: 1.45; text-align: center; }

@media (max-width: 980px) {
    .hardware-check { grid-template-columns: 1fr; gap: 32px; }
}

@media (max-width: 700px) {
    .hardware-check { margin-top: 38px; padding: 27px; }
}
