/* Imperial "next" look, approved by the owner (docs/19): shared by every page in the new look. Owned by the home page chat; ask it for changes.
   Load it before your page's own CSS:  <link rel="stylesheet" href="next-look.css">  and  <script src="next-motion.js" defer></script>
   The idea: the material is the color. Pages are graphite and limestone; photos and material tones bring the color.
   Yellow (--nx-signal) is only a thin line for "you are here", progress or focus: never a button, a fill or a big area.
   Type: Barlow (from American highway signs) for text; big headlines in Cormorant Garamond, a classic serif that matches
   the logo (the owner's pick, D215). ?font=modern on a link shows Barlow Condensed headlines for comparison. Rules: docs/19-next-look.md */
@import url("https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&family=Barlow+Condensed:wght@500;600;700&family=Cormorant+Garamond:wght@500;600;700&display=swap");
/* Choice dots and tick boxes drawn the same on every page (D410, Buttons chat's file). */
@import url("choice-controls.css");

:root{
  /* Base */
  --nx-graphite:#172126;   /* dark surfaces, main text, primary buttons */
  --nx-shale:#25323a;      /* raised dark surfaces */
  --nx-slate:#3c4a51;      /* secondary text on light */
  --nx-dust:#a3adb1;       /* secondary text on dark, quiet icons */
  --nx-lime:#e6e9e8;       /* page background (limestone) */
  --nx-paper:#f4f6f6;      /* cards and panels on limestone */
  --nx-line:#d5dbdc;       /* hairlines and borders on light */
  --nx-line-dark:rgba(255,255,255,.16);
  --nx-white:#fff;
  /* Signals: small and meaningful only */
  --nx-signal:#ffd34e;     /* thin lines: current item, progress bar, focus ring */
  --nx-live:#2f9e6b;       /* a truck working right now, "done" ticks */
  --nx-warn:#b7791f;       /* needs attention soon */
  --nx-alert:#c2412d;      /* problem, overdue, cancel */
  /* Material tones (backgrounds behind material photos) */
  --nx-tone-soil:#2a221b; --nx-tone-fill:#4a3a2b; --nx-tone-clay:#5c2a1d; --nx-tone-stone:#30383c; --nx-tone-base:#454b4e; --nx-tone-sand:#5e5544;
  /* Type */
  --nx-display:"Cormorant Garamond","Cormorant",Georgia,"Times New Roman",serif;
  --nx-text:"Barlow",system-ui,-apple-system,"Segoe UI",Arial,sans-serif;
  /* Shape and motion */
  --nx-r-s:8px; --nx-r:12px; --nx-r-l:18px; --nx-pill:999px;
  --nx-shadow:0 18px 44px rgba(23,33,38,.12);
  --nx-shadow-lift:0 40px 90px rgba(0,0,0,.35);
  --nx-ease:cubic-bezier(.2,.75,.2,1);
}
/* Numbers stand on the line in every font (Cormorant's default old-style figures make a 1 look like an I). */
:root{font-variant-numeric:lining-nums;font-feature-settings:"lnum" 1}
/* Set on every element (not just inherited), so a page's own font shorthand or tabular-nums can't bring old-style
   figures back; tabular-nums still works alongside it. */
.nx,.nx *{font-feature-settings:"lnum" 1!important}
/* Comparison only (?font=modern, next-motion.js sets <html data-nx-font="modern">): the earlier condensed headlines. */
:root[data-nx-font="modern"]{--nx-display:"Barlow Condensed","Barlow","Arial Narrow",Arial,sans-serif}

/* Opt in by adding class="nx" to <body> (or to a page's root element). */
.nx{font-family:var(--nx-text);color:var(--nx-graphite);background:var(--nx-lime);-webkit-font-smoothing:antialiased}
.nx :focus-visible{outline:3px solid var(--nx-signal);outline-offset:3px}
/* Apps move focus to the main area on each page change, for screen readers. That area gets no ring: a ring there
   draws long lines down the sides of the page. Buttons, links and fields keep their ring. */
.nx main:focus,.nx main:focus-visible,.nx [tabindex="-1"]:focus,.nx [tabindex="-1"]:focus-visible{outline:none!important}
.nx-dark{background:var(--nx-graphite);color:#fff}
.nx-dark .nx-muted{color:var(--nx-dust)}

/* Type scale: one display family, set large; text stays calm. Sentence case, no shouting capitals. */
.nx-display{font-family:var(--nx-display);font-weight:600;line-height:1;letter-spacing:0;margin:0}
:root[data-nx-font="modern"] .nx-display{line-height:.95;letter-spacing:-.005em}
.nx-h1{font-size:clamp(48px,7vw,104px)}
.nx-h2{font-size:clamp(36px,4.6vw,64px)}
.nx-h3{font-size:clamp(24px,2.4vw,32px);line-height:1.05}
.nx-lede{font-size:18px;line-height:1.55;color:var(--nx-slate);max-width:60ch}
.nx-dark .nx-lede{color:#c9d1d4}
.nx-label{font-size:13px;font-weight:600;color:var(--nx-slate)}
.nx-dark .nx-label{color:var(--nx-dust)}
.nx-muted{color:var(--nx-slate)}
.nx-num{font-variant-numeric:tabular-nums lining-nums}

/* The signal line: a short yellow stroke before a line of text, for "this is the current / important one". */
.nx-signal{display:flex;align-items:center;gap:12px}
.nx-signal:before{content:"";flex:none;width:28px;height:2px;background:var(--nx-signal)}

/* Buttons: pills. Graphite on light, white on dark. No yellow buttons. */
.nx-btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;padding:0 22px;border:1px solid var(--nx-graphite);border-radius:var(--nx-pill);background:var(--nx-graphite);color:#fff;font:600 16px/1.1 var(--nx-text);text-decoration:none;cursor:pointer;transition:background-color .2s ease,color .2s ease,border-color .2s ease}
.nx-btn:hover{background:#26343c}
.nx-btn.quiet{background:transparent;color:var(--nx-graphite);border-color:var(--nx-line)}
.nx-btn.quiet:hover{border-color:var(--nx-graphite)}
.nx-dark .nx-btn,.nx-btn.light{background:#fff;color:var(--nx-graphite);border-color:#fff}
.nx-dark .nx-btn:hover,.nx-btn.light:hover{background:#e3e8e9}
.nx-dark .nx-btn.quiet{background:transparent;color:#fff;border-color:rgba(255,255,255,.55)}
.nx-btn.danger{background:transparent;color:var(--nx-alert);border-color:currentColor}
.nx-btn[disabled]{opacity:.45;cursor:not-allowed}

/* The logo: always black, exactly like the original file (imperial-logistics-wordmark.png). Never white, inverted,
   recolored or faded. On a dark header or photo, put it on the light strip (.nx-bar) or a light plate (.nx-logo-plate). */
.nx-logo{display:block;width:auto;height:auto;max-width:100%;filter:none!important;opacity:1!important;mix-blend-mode:normal!important}
.nx-logo-plate{display:inline-flex;align-items:center;padding:10px 16px;border-radius:var(--nx-r);background:#fff}
.nx-bar{background:rgba(244,246,246,.94);color:var(--nx-graphite);border-bottom:1px solid rgba(23,33,38,.08);-webkit-backdrop-filter:blur(16px) saturate(140%);backdrop-filter:blur(16px) saturate(140%)}

/* Surfaces */
.nx-card{background:var(--nx-paper);border:1px solid var(--nx-line);border-radius:var(--nx-r);padding:20px}
.nx-glass{background:rgba(14,20,23,.72);border:1px solid var(--nx-line-dark);border-radius:var(--nx-r-l);color:#fff;-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}
.nx-photo{position:relative;overflow:hidden;border-radius:var(--nx-r);background:var(--nx-shale)}
.nx-photo img{display:block;width:100%;height:100%;object-fit:cover}

/* Status: words first; color only as a small dot. */
.nx-chip{display:inline-flex;align-items:center;gap:8px;min-height:28px;padding:3px 12px;border:1px solid var(--nx-line);border-radius:var(--nx-pill);background:#fff;font-size:14px;font-weight:600}
.nx-dark .nx-chip{background:transparent;border-color:var(--nx-line-dark);color:#fff}
.nx-dot{width:8px;height:8px;border-radius:50%;background:var(--nx-dust);flex:none}
.nx-dot.live{background:var(--nx-live);box-shadow:0 0 0 0 rgba(47,158,107,.55);animation:nxPulse 2.4s ease-out infinite}
.nx-dot.warn{background:var(--nx-warn)}
.nx-dot.alert{background:var(--nx-alert)}

/* Fields */
.nx-field{display:grid;gap:6px;min-width:0}
.nx-field label{font-size:14px;font-weight:600;color:var(--nx-slate)}
.nx-field input,.nx-field select,.nx-field textarea{width:100%;min-height:48px;padding:10px 12px;border:1px solid var(--nx-line);border-radius:10px;background:#fff;color:var(--nx-graphite);font:16px/1.3 var(--nx-text)}
.nx-field input:focus,.nx-field select:focus,.nx-field textarea:focus{border-color:var(--nx-graphite);outline:none;box-shadow:0 0 0 3px rgba(255,211,78,.55)}
.nx-dark .nx-field label{color:#c9d1d4}
.nx-dark .nx-field input,.nx-dark .nx-field select,.nx-dark .nx-field textarea{background:rgba(255,255,255,.08);border-color:rgba(255,255,255,.24);color:#fff}

/* Step forms (one small step at a time, quiet fields): .nx-steps, .nx-line-field, .nx-choices.
   They draw in the text color around them, so they work on light pages and on dark photos alike.
   <ol class="nx-steps"><li class="done"><span>You</span></li><li aria-current="step"><span>Reach you</span></li><li><span>The job</span></li></ol> */
.nx-steps{display:flex;margin:0;padding:0;list-style:none}
.nx-steps li{position:relative;flex:1 1 0;display:flex;flex-direction:column;align-items:flex-start;gap:10px;min-width:0;font-size:13px;font-weight:600;line-height:1.2}
.nx-steps li:last-child{flex:0 0 auto}
.nx-steps li:before{content:"";position:relative;z-index:1;box-sizing:border-box;width:11px;height:11px;border:1px solid currentColor;border-radius:50%;background:transparent;opacity:.55;transition:background-color .35s ease,opacity .35s ease,box-shadow .35s ease}
.nx-steps li:not(:last-child):after{content:"";position:absolute;top:5px;left:11px;right:0;height:1px;background:currentColor;opacity:.28;transform-origin:left;transition:opacity .35s ease}
.nx-steps li span{opacity:.6;transition:opacity .35s ease}
.nx-steps li.done:before,.nx-steps li[aria-current="step"]:before{background:currentColor;opacity:1}
.nx-steps li[aria-current="step"]:before{box-shadow:0 0 0 4px color-mix(in srgb,currentColor 18%,transparent)}
.nx-steps li.done:after{opacity:.85}
.nx-steps li.done span,.nx-steps li[aria-current="step"] span{opacity:1}
/* Underline-only field: <div class="nx-line-field"><label for="x">Your name</label><input id="x"></div> */
.nx-line-field{display:grid;gap:2px;min-width:0}
.nx-line-field label{font-size:14px;font-weight:600;opacity:.78}
.nx-line-field input,.nx-line-field textarea,.nx-line-field select{width:100%;min-height:50px;margin:0;padding:10px 0 9px;border:0;border-bottom:1px solid color-mix(in srgb,currentColor 45%,transparent);border-radius:0;background:transparent;color:inherit;font:400 20px/1.3 var(--nx-text);-webkit-appearance:none;appearance:none}
.nx-line-field textarea{min-height:76px;resize:vertical}
/* Dropdowns keep a small arrow, drawn in the text color so it shows on light pages and dark photos alike. */
.nx-line-field select{padding-right:30px;cursor:pointer;background-image:linear-gradient(45deg,transparent 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,transparent 50%);background-position:calc(100% - 14px) 52%,calc(100% - 8px) 52%;background-size:6px 6px,6px 6px;background-repeat:no-repeat}
.nx-line-field select option{color:var(--nx-graphite);background:#fff}
.nx-line-field input::placeholder,.nx-line-field textarea::placeholder{color:inherit;opacity:.4}
.nx-line-field input:focus,.nx-line-field textarea:focus,.nx-line-field select:focus{outline:none;padding-bottom:8px;border-bottom:2px solid var(--nx-focus-line,var(--nx-graphite))}
.nx-dark .nx-line-field,.nx-on-dark{--nx-focus-line:var(--nx-signal)}
.nx-line-field .nx-hint{margin:0 0 2px;font-size:14px;opacity:.6}
/* Pill choices (radio buttons): <fieldset class="nx-choices"><legend>Best time</legend><div><label><input type="radio" name="t" value="a" checked><span>Morning</span></label>…</div></fieldset> */
.nx-choices{min-width:0;margin:0;padding:0;border:0}
.nx-choices legend{margin:0 0 10px;padding:0;font-size:14px;font-weight:600;opacity:.78}
.nx-choices>div{display:flex;flex-wrap:wrap;gap:8px}
.nx-choices label{position:relative;display:inline-flex}
.nx-choices input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.nx-choices span{display:inline-flex;align-items:center;min-height:44px;padding:0 18px;border:1px solid color-mix(in srgb,currentColor 40%,transparent);border-radius:var(--nx-pill);font-size:15px;font-weight:600;transition:background-color .2s ease,color .2s ease,border-color .2s ease}
.nx-choices input:checked+span{background:var(--nx-choice-on,var(--nx-graphite));border-color:var(--nx-choice-on,var(--nx-graphite));color:var(--nx-choice-on-text,#fff)}
.nx-choices input:focus-visible+span{outline:3px solid var(--nx-signal);outline-offset:3px}
.nx-dark .nx-choices,.nx-on-dark{--nx-choice-on:#fff;--nx-choice-on-text:var(--nx-graphite)}

/* Progress: a thin track with a yellow fill. Use for steps of a job or a scroll story. */
.nx-progress{height:3px;border-radius:3px;background:rgba(23,33,38,.12);overflow:hidden}
.nx-dark .nx-progress{background:rgba(255,255,255,.14)}
.nx-progress>i{display:block;height:100%;width:var(--nx-p,0%);background:var(--nx-signal);transition:width .6s var(--nx-ease)}

/* Motion (next-motion.js). One moment per screen: letters on the main headline, or one reveal. */
.nx-letters .nx-w{display:inline-block;white-space:nowrap}
.nx-letters .nx-l{display:inline-block}
.nx-letters .nx-line{display:block}
.nx-letters.nx-play .nx-l{opacity:0;transform:translateY(.42em) rotate(3deg);filter:blur(12px);animation:nxLetter .95s var(--nx-ease) forwards;animation-delay:calc(var(--i) * 34ms + 200ms)}
[data-nx-reveal]{opacity:0;transform:translateY(24px);transition:opacity .7s ease,transform .9s var(--nx-ease)}
[data-nx-reveal].nx-in{opacity:1;transform:none}
.nx-settle>*{opacity:0;transform:translateY(-20px)}
.nx-settle.nx-in>*{animation:nxSettle .75s var(--nx-ease) forwards;animation-delay:calc(var(--k,0) * 160ms)}

@keyframes nxLetter{to{opacity:1;transform:none;filter:blur(0)}}
@keyframes nxSettle{to{opacity:1;transform:none}}
@keyframes nxPulse{0%{box-shadow:0 0 0 0 rgba(47,158,107,.55)}70%{box-shadow:0 0 0 9px rgba(47,158,107,0)}100%{box-shadow:0 0 0 0 rgba(47,158,107,0)}}

@media(prefers-reduced-motion:reduce){
  .nx-letters.nx-play .nx-l,[data-nx-reveal],.nx-settle>*{animation:none!important;opacity:1!important;transform:none!important;filter:none!important;transition:none!important}
  .nx-dot.live{animation:none}
}
