/* TitanX public design system v2 (P25): the one stylesheet under TitanX Store,
   Careers, Tenders and, later, Booking and Support. See program/P25/design/DESIGN-SYSTEM.md.
   LIGHT ONLY, on purpose: white and very light neutral surfaces, ink text, the TitanX
   indigo as the one brand colour, amber as a sparing highlight. There is no dark theme
   and no OS colour-scheme media rule anywhere, so a phone in dark mode still gets this page.
   Self-hosted Inter (tx/fonts/), no CDN. Every colour is a token below; nothing else
   in the sheets hard-codes one. Contrast (WCAG AA) is checked for each text/background pair
   in the comment beside it. */
@font-face { font-family: 'Inter'; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/inter-Regular.b0e63c8c9933.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/inter-Medium.a77c2391c16d.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/inter-SemiBold.acdcec8422b5.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/inter-Bold.3ed4f2cad74a.woff2") format('woff2'); }

:root {
  color-scheme: light;
  /* Brand: indigo from the TitanX app icon. --brand on white 7.4:1, --brand-strong on --brand-soft 7.2:1. */
  --brand: #3340d6; --brand-rgb: 51, 64, 214; --brand-strong: #2630b0; --brand-soft: #eef0ff; --brand-line: #c9ceff;
  --accent: #f5a524; --accent-soft: #fff4de;               /* highlight only (rules, dots, hero glow): never text on white */
  /* Surfaces */
  --bg: #f6f7fb; --surface: #fff; --surface-2: #fbfbfe; --sunk: #eef0f6;
  /* Ink: --ink on white 17:1; --ink-2 on white 6.3:1, on --bg 5.9:1, on --brand-soft 5.5:1 */
  --ink: #0f1222; --ink-2: #565d70; --line: #dfe2ec; --line-strong: #c4c9d8;
  /* Status (text on its own soft tint all >= 4.5:1) */
  --ok: #157a3c; --ok-soft: #e7f6ec; --warn: #8a4b00; --warn-soft: #fff4de; --bad: #b42318; --bad-soft: #fdeceb;
  --on-brand: #fff;
  --fill: var(--brand); --fill-hover: var(--brand-strong); --bad-fill: #b42318;
  --bar: #fff;
  --shadow: 0 1px 2px rgba(15, 18, 34, .05), 0 4px 16px rgba(15, 18, 34, .05);
  --shadow-hover: 0 2px 4px rgba(15, 18, 34, .06), 0 10px 28px rgba(15, 18, 34, .09);
  /* Shape and space */
  --r-sm: .5rem; --r-md: .75rem; --r-lg: 1rem; --r-xl: 1.5rem; --radius: .75rem; --gap: 1rem;
  --s1: .25rem; --s2: .5rem; --s3: .75rem; --s4: 1rem; --s5: 1.5rem; --s6: 2rem; --s7: 3rem;
  /* Type scale (1.2 ratio) */
  --fs-xs: .8125rem; --fs-sm: .875rem; --fs-base: 1rem; --fs-md: 1.125rem; --fs-lg: 1.375rem; --fs-xl: 1.75rem; --fs-2xl: 2.25rem; --fs-3xl: 3rem;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(.25, .1, .25, 1);
  --wide: 72rem;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: light; }
body { margin: 0; background: var(--bg); color: var(--ink); font: var(--fs-base)/1.55 var(--font); letter-spacing: -.006em;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; width: 100%; max-width: var(--wide); margin: 0 auto; padding: 1.5rem 1rem 4rem; }
@media (min-width: 760px) { main { padding-top: 2rem; } }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 .5rem; font-weight: 700; }
h1 { font-size: var(--fs-xl); } h2 { font-size: var(--fs-lg); font-weight: 650; } h3 { font-size: var(--fs-md); font-weight: 600; }
@media (min-width: 760px) { h1 { font-size: var(--fs-2xl); } }
p { margin: 0 0 .75rem; }
a { color: var(--brand-strong); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
p a:not(.btn), .help a, .legal a { text-decoration: underline; text-underline-offset: 2px; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: var(--r-sm); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: .6rem 1rem; z-index: 99; border-radius: 0 0 var(--r-sm) 0; }
.skip:focus { left: 0; }
.muted { color: var(--ink-2); } .small { font-size: var(--fs-sm); } .right { text-align: right; }

/* ---- Header: solid white bar, brand left, links, then the account and cart slots ---- */
.top { position: sticky; top: 0; z-index: 20; background: var(--bar); border-bottom: 1px solid var(--line); }
.top-in { max-width: var(--wide); margin: 0 auto; padding: .35rem 1rem; display: flex; align-items: center; gap: .25rem .75rem; flex-wrap: wrap; min-height: 60px; }
.brand { display: flex; align-items: center; gap: .6rem; color: var(--ink); font-weight: 700; font-size: 1.05rem; margin-right: auto; min-height: 44px; letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand .tx-mark { width: 32px; height: 32px; border-radius: 9px; flex: none; }
.mark { width: 32px; height: 32px; border-radius: 9px; background: var(--fill); color: var(--on-brand); display: grid; place-items: center; font-weight: 700; flex: none; }
.logo { width: 32px; height: 32px; border-radius: 9px; object-fit: cover; }
.nav { display: flex; gap: .15rem; align-items: center; flex-wrap: wrap; }
.nav a { color: var(--ink); padding: .5rem .85rem; min-height: 44px; display: inline-flex; align-items: center; border-radius: 999px; font-weight: 500; font-size: .95rem; transition: background-color .15s var(--ease); }
.nav a:hover { background: var(--sunk); text-decoration: none; }
.nav a[aria-current] { color: var(--brand-strong); background: var(--brand-soft); font-weight: 600; }
/* The right-hand slots. Today only the cart is filled; "Sign in / My account" drops into
   {% block header_account %} when the shared customer identity ships (P25 IDENT). */
.hdr-actions { display: flex; align-items: center; gap: .25rem; order: 2; }
.nav.main { order: 3; flex: 1 1 100%; overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; margin: 0 -.5rem; }
.nav.main a { white-space: nowrap; }
@media (min-width: 760px) { .nav.main { order: 1; flex: 0 1 auto; margin: 0 0 0 auto; overflow: visible; } .brand { margin-right: 0; } .hdr-actions { order: 2; } }
.cartlink { font-weight: 600; }
.cartlink[aria-current] { color: var(--brand-strong); background: var(--brand-soft); }
.cartlink .n { background: var(--brand); color: #fff; border-radius: 99px; font-size: .75rem; min-width: 1.4rem; height: 1.4rem; display: inline-grid; place-items: center; margin-left: .35rem; padding: 0 .3rem; }

/* ---- Notices ---- */
.notice { padding: .7rem 1rem; font-size: var(--fs-sm); background: var(--warn-soft); color: var(--warn); text-align: center; }
.notice.inline { border-radius: var(--r-md); margin: 0 0 1rem; text-align: left; }
.notice.ok { background: var(--ok-soft); color: var(--ok); } .notice.bad { background: var(--bad-soft); color: var(--bad); }

/* ---- Form controls ---- */
input, select, textarea { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-md); padding: .65rem .85rem; min-height: 44px; width: 100%;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease); }
input::placeholder, textarea::placeholder { color: #6b7284; opacity: 1; }
input:hover, select:hover, textarea:hover { border-color: var(--ink-2); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(var(--brand-rgb), .22); }
input[aria-invalid=true], textarea[aria-invalid=true] { border-color: var(--bad); }
input[type=file] { padding: .5rem; }
input[type=checkbox], input[type=radio] { accent-color: var(--brand); }
textarea { min-height: 6rem; }
label { display: block; font-weight: 600; font-size: var(--fs-sm); margin: 0 0 .3rem; }
.field { margin-bottom: 1rem; }
.help { font-size: var(--fs-sm); color: var(--ink-2); margin-top: .25rem; }
.err { color: var(--bad); font-size: var(--fs-sm); margin-top: .25rem; }
.err:empty { display: none; }
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
fieldset { border: 0; padding: 0; margin: 0 0 1.25rem; } legend { font-weight: 650; padding: 0; margin-bottom: .6rem; font-size: var(--fs-md); }

/* ---- Buttons: .btn primary; .ghost outline; .soft tinted; .sm; .danger ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 44px; padding: .6rem 1.35rem; border-radius: 999px; border: 1px solid transparent;
  background: var(--fill); color: var(--on-brand); font: inherit; font-weight: 600; font-size: .98rem; cursor: pointer; white-space: nowrap;
  transition: background-color .15s var(--ease), transform .1s var(--ease), box-shadow .15s var(--ease); }
.btn:hover { background: var(--fill-hover); text-decoration: none; }
.btn:active { transform: scale(.98); }
.btn.ghost { background: var(--surface); color: var(--brand-strong); border-color: var(--line-strong); }
.btn.ghost:hover { background: var(--brand-soft); border-color: var(--brand-line); }
.btn.soft { background: var(--brand-soft); color: var(--brand-strong); }
.btn.soft:hover { background: var(--brand-line); }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---- Badges and status chips ---- */
.badge { display: inline-flex; align-items: center; gap: .3rem; font-size: var(--fs-xs); font-weight: 600; padding: .2rem .65rem; border-radius: 999px; background: var(--ok-soft); color: var(--ok); vertical-align: middle; }
.badge.neutral { background: var(--brand-soft); color: var(--brand-strong); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.out { background: var(--bad-soft); color: var(--bad); }
.chip { flex: none; padding: .5rem 1rem; min-height: 44px; display: inline-flex; align-items: center; border-radius: 999px; background: var(--surface); color: var(--ink); font-weight: 500;
  border: 1px solid var(--line); transition: border-color .15s var(--ease), background-color .15s var(--ease); }
.chip:hover { text-decoration: none; border-color: var(--brand); background: var(--brand-soft); }
.chip[aria-current] { background: var(--brand); border-color: var(--brand); color: #fff; }
.panel { background: var(--surface); border-radius: var(--r-lg); padding: 1.25rem; box-shadow: var(--shadow); border: 1px solid var(--line); }

/* ---- Footer ---- */
.foot { border-top: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font-size: var(--fs-sm); }
.foot-in { max-width: var(--wide); margin: 0 auto; padding: 1.5rem 1rem 2rem; display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; align-items: center; }
.foot a { color: var(--ink-2); padding: .5rem 0; min-height: 44px; display: inline-flex; align-items: center; }
.foot a:hover { color: var(--ink); }
.foot .grow { flex: 1 1 100%; }
.foot .tx-by { display: inline-flex; align-items: center; gap: .5rem; color: var(--ink); font-weight: 600; }
.foot .tx-by img { width: 22px; height: 22px; border-radius: 6px; }

/* ---- States: empty, loading (skeleton), error ---- */
.empty { text-align: center; padding: 3rem 1rem; color: var(--ink-2); background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--r-lg); display: grid; gap: .5rem; justify-items: center; }
.empty h2, .empty h3 { color: var(--ink); margin: 0; }
.empty p { margin: 0; max-width: 32rem; }
.empty .ico { width: 56px; height: 56px; border-radius: 16px; background: var(--brand-soft); color: var(--brand-strong); display: grid; place-items: center; margin-bottom: .25rem; }
.empty .ico svg { width: 28px; height: 28px; }
.state-error { border: 1px solid var(--bad); background: var(--bad-soft); color: var(--bad); border-radius: var(--r-md); padding: .85rem 1rem; }
.skeleton { background: linear-gradient(90deg, var(--sunk) 25%, #f6f7fb 50%, var(--sunk) 75%); background-size: 200% 100%; animation: tx-shimmer 1.4s linear infinite; border-radius: var(--r-md); min-height: 1rem; }
@keyframes tx-shimmer { to { background-position: -200% 0; } }

/* ---- Image fallback: a soft tinted tile with a quiet line icon, never a letter ---- */
.imgfb { display: grid; place-items: center; color: var(--brand-strong); background:
  radial-gradient(circle at 20% 15%, rgba(245, 165, 36, .16), transparent 45%),
  radial-gradient(circle at 85% 90%, rgba(var(--brand-rgb), .14), transparent 50%), var(--brand-soft); }
.imgfb svg { width: 34%; max-width: 64px; opacity: .8; }

.legal { max-width: 44rem; white-space: pre-wrap; }
.legal.rich { white-space: normal; }
@media (pointer: coarse) { .nav a, .chip, .btn { min-height: 48px; } .active a, .crumbs a, .pcard .by { min-height: 44px; }
  /* A finger needs width too (r11 E41): "RSS", "About" and "Terms" were 26-40px wide. */
  .foot a { min-width: 44px; justify-content: center; }
  .tap { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }

/* Installable app (PWA): offline strip, saved-copy banner, update prompt. Light tokens only; no inline styles (CSP). */
.pwa-bar, .pwa-saved { padding: .6rem 1rem; font-size: var(--fs-sm); background: var(--warn-soft); color: var(--warn); text-align: center; border-bottom: 1px solid var(--line); }
.pwa-update { position: fixed; left: 50%; bottom: 1rem; transform: translateX(-50%); z-index: 50; display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; justify-content: center;
  width: calc(100% - 2rem); max-width: 28rem; padding: .75rem 1rem; background: var(--surface); color: var(--ink); border: 1px solid var(--brand-line); border-radius: var(--r-lg); box-shadow: var(--shadow-hover); font-size: var(--fs-sm); }
.pwa-offline { max-width: 36rem; margin: 0 auto; padding: 2rem var(--s4, 1rem); }
.pwa-offline ul { padding-left: 1.2rem; }

/* P25 FIX5 (F-7): "Sign in" / the person's name never wraps onto two lines in a header. */
.acctnav, .acctnav a.acctlink, .acctnav .al { white-space: nowrap; flex: none; }
