/* =====================================================================
   TITAN 300 — ASCENSION design system
   Dark, cold, cinematic, sporty. Cyan is the brand accent for action and
   progression only. Amber is reserved for records and rare moments.
   ===================================================================== */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(./fonts/archivo-latin-variable.woff2) format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(./fonts/manrope-latin-1.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(./fonts/manrope-latin-0.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+20A0-20AB, U+20AD-20C0;
}

:root {
  color-scheme: dark;
  /* Surfaces: blue-black, steel. */
  --bg: #05070a;
  --bg-1: #090d12;
  --bg-2: #0e141a;
  --bg-3: #141c24;
  --bg-4: #1b2530;
  --line: rgba(150, 180, 205, 0.11);
  --line-2: rgba(150, 180, 205, 0.2);
  --line-3: rgba(150, 180, 205, 0.32);
  /* Text. */
  --tx: #eef3f7;
  --tx-2: #a8b6c3;
  --tx-3: #7f909f;
  --tx-4: #4c5966;
  /* Brand accent (action, progression). */
  --cy: #3dd9e8;
  --cy-2: #8ceaf2;
  --cy-ink: #02181b;
  --cy-soft: rgba(61, 217, 232, 0.12);
  --cy-line: rgba(61, 217, 232, 0.38);
  /* Records and rare moments. */
  --am: #f4bb54;
  --am-soft: rgba(244, 187, 84, 0.12);
  --am-line: rgba(244, 187, 84, 0.4);
  /* States. */
  --ok: #57d39b;
  --warn: #f0a24a;
  --err: #f2665f;
  --err-soft: rgba(242, 102, 95, 0.12);
  /* Sport families (data visualisation, never decoration). */
  --fam-endurance: #3dd9e8;
  --fam-force: #7c93ff;
  --fam-technique: #b693ff;
  --fam-jeu: #57d39b;
  --fam-mobilite: #8ea2b3;
  /* Type. */
  --font-display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --font-text: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* Spacing (4 px grid). */
  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 20px;
  --s6: 24px;
  --s7: 32px;
  --s8: 40px;
  --s9: 56px;
  --s10: 72px;
  --r1: 8px;
  --r2: 12px;
  --r3: 18px;
  --r4: 26px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --t-fast: 140ms;
  --t-med: 240ms;
  --rail: 248px;
  --tabbar: 68px;
  --topbar: 56px;
  --content: 1080px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

/* ---------- Base ---------- */
.asc,
.asc * {
  box-sizing: border-box;
}
html.asc-root {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body.asc {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--tx);
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "tnum" 0;
}
:where(.asc) :where(img, svg) {
  display: block;
  max-width: 100%;
}
/* Resets carry no specificity so components (.asc-btn-primary…) always win. */
:where(.asc) a {
  color: inherit;
  text-decoration: none;
}
:where(.asc) :where(button, input, select, textarea) {
  font: inherit;
  color: inherit;
}
:where(.asc) button {
  cursor: pointer;
}
.asc :focus-visible {
  outline: 2px solid var(--cy);
  outline-offset: 3px;
  border-radius: 6px;
}
.asc ::selection {
  background: var(--cy-soft);
  color: var(--tx);
}
.asc .sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.asc-skip {
  position: fixed;
  top: var(--s3);
  left: var(--s3);
  z-index: 100;
  padding: var(--s2) var(--s4);
  background: var(--cy);
  color: var(--cy-ink);
  border-radius: var(--r1);
  font-weight: 700;
  transform: translateY(-200%);
}
.asc-skip:focus {
  transform: none;
}
.t-icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
}

/* ---------- Typography ---------- */
:where(.asc) :where(h1, h2, h3, h4) {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.01em;
  word-spacing: 0.06em;
  line-height: 1.02;
  color: var(--tx);
}
:where(.asc) h1,
.asc-h1 {
  font-size: clamp(34px, 7vw, 56px);
  font-stretch: 78%;
  text-transform: none;
}
:where(.asc) h2,
.asc-h2 {
  font-size: clamp(22px, 3.6vw, 30px);
  font-stretch: 85%;
}
:where(.asc) h3,
.asc-h3 {
  font-size: 18px;
  font-stretch: 92%;
  font-weight: 750;
  line-height: 1.2;
}
:where(.asc) p {
  margin: 0;
}
.asc-eyebrow {
  font-family: var(--font-display);
  font-stretch: 100%;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tx-3);
}
.asc-eyebrow.cy {
  color: var(--cy);
}
.asc-eyebrow.am {
  color: var(--am);
}
.asc-lead {
  font-size: 16px;
  color: var(--tx-2);
  max-width: 56ch;
}
.asc-muted {
  color: var(--tx-2);
}
.asc-faint {
  color: var(--tx-3);
}
.asc-small {
  font-size: 13px;
  line-height: 1.45;
}
.asc-num {
  font-family: var(--font-display);
  font-variant-numeric: tabular-nums;
  font-stretch: 80%;
  font-weight: 800;
  letter-spacing: -0.01em;
}

/* ---------- Shell ---------- */
.asc-shell {
  min-height: 100vh;
  min-height: 100dvh;
}
.asc-main {
  width: 100%;
  max-width: calc(var(--content) + 2 * var(--s6));
  margin: 0 auto;
  padding: calc(var(--topbar) + var(--safe-t) + var(--s4)) var(--s4) calc(var(--tabbar) + var(--safe-b) + var(--s8));
}
.asc-topbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 40;
  height: calc(var(--topbar) + var(--safe-t));
  padding: var(--safe-t) var(--s4) 0;
  display: flex;
  align-items: center;
  gap: var(--s3);
  background: rgba(5, 7, 10, 0.99); /* near-opaque: text scrolling underneath must not show through (visual audit 21/10/2026) */
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.asc-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 850;
  font-stretch: 82%;
  font-size: 20px;
  letter-spacing: 0.04em;
}
.asc-brand-mark {
  width: 26px;
  height: 26px;
  color: var(--cy);
}
.asc-topbar-title {
  flex: 1;
  min-width: 0;
  font-family: var(--font-display);
  font-weight: 750;
  font-stretch: 88%;
  font-size: 17px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.asc-topbar .asc-brand + .asc-topbar-title {
  display: none;
}
.asc-me {
  display: inline-flex;
  align-items: center;
  gap: var(--s2);
  padding: 3px 3px 3px var(--s3);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-1);
  min-height: 40px;
}
.asc-me-level {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 85%;
  font-size: 13px;
  color: var(--tx-2);
}
.asc-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  flex: none;
}
.asc-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.82) contrast(1.04);
}
.asc-sync {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--tx-4);
  flex: none;
  box-shadow: 0 0 0 3px var(--bg);
}
.asc-sync[data-state="cloud"] {
  background: var(--ok);
}
.asc-sync[data-state="pending"] {
  background: var(--warn);
}
.asc-sync[data-state="offline"],
.asc-sync[data-state="error"] {
  background: var(--err);
}
.asc-sync[data-state="local"] {
  background: var(--tx-3);
}

/* Mobile tab bar: five territories, Séance raised in the middle. */
.asc-tabbar {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 40;
  height: calc(var(--tabbar) + var(--safe-b));
  padding: 0 var(--s2) var(--safe-b);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  background: rgba(7, 10, 14, 0.99);
  backdrop-filter: saturate(140%) blur(16px);
  -webkit-backdrop-filter: saturate(140%) blur(16px);
  border-top: 1px solid var(--line);
}
.asc-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 52px;
  color: var(--tx-3);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.01em;
  border-radius: var(--r2);
  transition: color var(--t-fast) var(--ease);
}
.asc-tab .t-icon {
  width: 22px;
  height: 22px;
}
.asc-tab[aria-current="page"] {
  color: var(--tx);
}
.asc-tab[aria-current="page"] .t-icon {
  color: var(--cy);
}
.asc-tab-record .asc-tab-plus .t-icon {
  color: var(--cy-ink);
}
.asc-tab-record {
  margin-top: -18px;
}
.asc-tab-record .asc-tab-plus {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: var(--cy);
  color: var(--cy-ink);
  box-shadow: 0 10px 28px rgba(61, 217, 232, 0.28), 0 0 0 4px var(--bg);
  transition: transform var(--t-fast) var(--ease);
}
.asc-tab-record .asc-tab-plus .t-icon {
  width: 26px;
  height: 26px;
  stroke-width: 2.2;
}
.asc-tab-record:active .asc-tab-plus {
  transform: scale(0.95);
}
.asc-tab-record[aria-current="page"] {
  color: var(--tx);
}

/* Desktop rail. */
.asc-rail {
  display: none;
}
@media (min-width: 960px) {
  .asc-topbar,
  .asc-tabbar {
    display: none;
  }
  .asc-rail {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 30;
    width: var(--rail);
    display: flex;
    flex-direction: column;
    padding: var(--s6) var(--s4);
    background: var(--bg);
    border-right: 1px solid var(--line);
  }
  .asc-rail .asc-brand {
    padding: 0 var(--s3);
    margin-bottom: var(--s7);
  }
  .asc-rail-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
  }
  .asc-rail-link {
    display: flex;
    align-items: center;
    gap: var(--s3);
    min-height: 44px;
    padding: 0 var(--s3);
    border-radius: var(--r2);
    color: var(--tx-2);
    font-weight: 650;
    transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  }
  .asc-rail-link:hover {
    background: var(--bg-2);
    color: var(--tx);
  }
  .asc-rail-link[aria-current="page"] {
    background: var(--bg-2);
    color: var(--tx);
  }
  .asc-rail-link[aria-current="page"] .t-icon {
    color: var(--cy);
  }
  .asc-rail-record {
    margin: var(--s5) 0;
    justify-content: center;
    background: var(--cy);
    color: var(--cy-ink);
    font-weight: 800;
  }
  .asc-rail-record:hover,
  .asc-rail-record[aria-current="page"] {
    background: var(--cy-2);
    color: var(--cy-ink);
  }
  .asc-rail-record[aria-current="page"] .t-icon {
    color: var(--cy-ink);
  }
  .asc-rail-sub {
    margin-top: var(--s6);
    padding-top: var(--s4);
    border-top: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    gap: 2px;
  }
  .asc-rail-sub .asc-rail-link {
    min-height: 38px;
    font-size: 14px;
    font-weight: 600;
    color: var(--tx-3);
  }
  .asc-rail-foot {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: var(--s3);
    padding: var(--s3);
    border-radius: var(--r2);
    border: 1px solid var(--line);
    background: var(--bg-1);
  }
  .asc-rail-foot:hover {
    border-color: var(--line-2);
  }
  .asc-rail-foot .asc-avatar {
    width: 38px;
    height: 38px;
  }
  .asc-rail-foot strong {
    display: block;
    font-size: 14px;
    line-height: 1.2;
  }
  .asc-rail-foot small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--tx-3);
    font-size: 12px;
  }
  .asc-main {
    padding: var(--s8) var(--s7) var(--s10);
    padding-left: calc(var(--rail) + var(--s7));
    max-width: calc(var(--content) + var(--rail) + 2 * var(--s7));
  }
}

/* ---------- Page header ---------- */
.asc-page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s4);
  margin: var(--s2) 0 var(--s7);
}
.asc-page-head > div {
  display: grid;
  gap: var(--s2);
  min-width: 0;
}
.asc-subnav {
  display: flex;
  gap: var(--s1);
  overflow-x: auto;
  scrollbar-width: none;
  margin: calc(-1 * var(--s3)) calc(-1 * var(--s4)) var(--s6);
  padding: 0 var(--s4);
  border-bottom: 1px solid var(--line);
}
.asc-subnav::-webkit-scrollbar {
  display: none;
}
.asc-subnav a {
  flex: none;
  padding: var(--s3) var(--s3) calc(var(--s3) - 2px);
  border-bottom: 2px solid transparent;
  color: var(--tx-3);
  font-weight: 650;
  font-size: 14px;
  white-space: nowrap;
}
.asc-subnav a:hover {
  color: var(--tx-2);
}
.asc-subnav a[aria-current="page"] {
  color: var(--tx);
  border-color: var(--cy);
}
@media (min-width: 960px) {
  .asc-subnav {
    margin-left: 0;
    margin-right: 0;
    padding: 0;
  }
}

/* ---------- Buttons ---------- */
.asc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s2);
  min-height: 46px;
  padding: 0 var(--s5);
  border-radius: var(--r2);
  border: 1px solid transparent;
  font-weight: 750;
  font-size: 15px;
  line-height: 1;
  white-space: nowrap;
  transition: background var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease),
    transform var(--t-fast) var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.asc-btn:active {
  transform: translateY(1px);
}
.asc-btn[disabled],
.asc-btn[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
}
.asc-btn-primary {
  background: var(--cy);
  color: var(--cy-ink);
}
.asc-btn-primary:hover {
  background: var(--cy-2);
}
.asc-btn-secondary {
  background: var(--bg-2);
  border-color: var(--line-2);
  color: var(--tx);
}
.asc-btn-secondary:hover {
  border-color: var(--line-3);
  background: var(--bg-3);
}
.asc-btn-ghost {
  background: transparent;
  color: var(--tx-2);
  padding: 0 var(--s3);
}
.asc-btn-ghost:hover {
  color: var(--tx);
  background: var(--bg-2);
}
.asc-btn-danger {
  background: var(--err-soft);
  border-color: rgba(242, 102, 95, 0.35);
  color: #ffb3ae;
}
.asc-btn-sm {
  min-height: 36px;
  padding: 0 var(--s3);
  font-size: 13px;
  border-radius: var(--r1);
}
.asc-btn-block {
  width: 100%;
}
.asc-btn-icon {
  width: 44px;
  min-height: 44px;
  padding: 0;
}
.asc-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--cy);
  font-weight: 700;
}
.asc-link:hover {
  color: var(--cy-2);
}
.asc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s3);
  align-items: center;
}

/* ---------- Surfaces ---------- */
.asc-hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--r4);
  background: var(--bg-1);
  border: 1px solid var(--line);
  padding: var(--s6);
  isolation: isolate;
}
.asc-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url("/assets/ascension/contours.svg") right -40px top -60px / 520px auto no-repeat;
  opacity: 0.55;
  pointer-events: none;
}
.asc-hero.is-record {
  border-color: var(--am-line);
}
.asc-hero.is-record::after {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: var(--am);
}
.asc-hero.is-accent::after {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: var(--cy);
}
@media (min-width: 720px) {
  .asc-hero {
    padding: var(--s8);
  }
}
.asc-panel {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: var(--r3);
  padding: var(--s5);
}
.asc-section {
  margin-top: var(--s8);
}
.asc-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s3);
  margin-bottom: var(--s4);
}
.asc-section-head h2 {
  font-size: 20px;
  font-stretch: 90%;
}
.asc-divider {
  height: 1px;
  background: var(--line);
  border: 0;
  margin: var(--s6) 0;
}
.asc-grid-2 {
  display: grid;
  gap: var(--s6);
}
@media (min-width: 860px) {
  .asc-grid-2 {
    grid-template-columns: 1.35fr 1fr;
    align-items: start;
  }
  .asc-grid-2.even {
    grid-template-columns: 1fr 1fr;
  }
}

/* ---------- Data ---------- */
.asc-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: var(--s5) var(--s4);
}
.asc-stat {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.asc-stat-value {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 78%;
  font-size: clamp(28px, 5vw, 38px);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}
.asc-stat-value small {
  font-size: 0.48em;
  font-weight: 700;
  color: var(--tx-2);
  margin-left: 2px;
  letter-spacing: 0;
}
.asc-stat-label {
  font-size: 12.5px;
  color: var(--tx-3);
  font-weight: 600;
}
.asc-delta {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--tx-2);
}
.asc-delta.up {
  color: var(--cy);
}
.asc-delta.down {
  color: var(--tx-3);
}
.asc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.asc-row {
  display: flex;
  align-items: center;
  gap: var(--s3);
  min-height: 60px;
  padding: var(--s3) 0;
  border-bottom: 1px solid var(--line);
}
a.asc-row,
button.asc-row {
  width: 100%;
  background: none;
  border-left: 0;
  border-right: 0;
  border-top: 0;
  text-align: left;
  transition: background var(--t-fast) var(--ease);
}
a.asc-row:hover,
button.asc-row:hover {
  background: linear-gradient(90deg, transparent, var(--bg-1) 12%, var(--bg-1) 88%, transparent);
}
.asc-row-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r2);
  display: grid;
  place-items: center;
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--tx-2);
  flex: none;
}
.asc-row-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 1px;
}
.asc-row-title {
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.asc-row-sub {
  font-size: 13px;
  color: var(--tx-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.asc-row-end {
  text-align: right;
  flex: none;
  display: grid;
  gap: 1px;
  justify-items: end;
}
.asc-row-end strong {
  font-family: var(--font-display);
  font-stretch: 82%;
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}
.asc-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  color: var(--tx-2);
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
}
.asc-chip.cy {
  border-color: var(--cy-line);
  color: var(--cy);
  background: var(--cy-soft);
}
.asc-chip.am {
  border-color: var(--am-line);
  color: var(--am);
  background: var(--am-soft);
}
.asc-chip.warn {
  border-color: rgba(240, 162, 74, 0.45);
  color: var(--warn);
}
.asc-chip.err {
  border-color: rgba(242, 102, 95, 0.45);
  color: var(--err);
}

/* Progression line: an ascension profile that fills up. */
.asc-ascent {
  position: relative;
  height: 10px;
  border-radius: 999px;
  background: var(--bg-3);
  overflow: hidden;
}
.asc-ascent > span {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--p, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(61, 217, 232, 0.55), var(--cy));
  transition: width 900ms var(--ease);
}
.asc-ascent.am > span {
  background: linear-gradient(90deg, rgba(244, 187, 84, 0.5), var(--am));
}
.asc-ascent.thin {
  height: 6px;
}

/* Cadence: eight weekly notches. */
.asc-notches {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 5px;
}
.asc-notch {
  height: 30px;
  border-radius: 6px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  position: relative;
}
.asc-notch[data-state="held"] {
  background: var(--cy);
  border-color: var(--cy);
}
.asc-notch[data-state="partial"] {
  background: linear-gradient(0deg, var(--cy-soft) var(--fill, 50%), var(--bg-3) var(--fill, 50%));
  border-color: var(--cy-line);
}
.asc-notch[data-state="pause"] {
  background: repeating-linear-gradient(135deg, var(--bg-3) 0 4px, var(--bg-2) 4px 8px);
}
.asc-notch[data-state="current"] {
  border: 1px dashed var(--cy-line);
  background: linear-gradient(0deg, var(--cy-soft) var(--fill, 0%), transparent var(--fill, 0%));
}

/* ---------- Forms ---------- */
.asc-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.asc-field > span,
.asc-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--tx-2);
}
.asc-field small {
  color: var(--tx-3);
  font-size: 12px;
}
.asc-input,
.asc select,
.asc textarea {
  width: 100%;
  min-height: 48px;
  padding: 0 var(--s4);
  border-radius: var(--r2);
  border: 1px solid var(--line-2);
  background: var(--bg-1);
  color: var(--tx);
  font-size: 16px;
  transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
  appearance: none;
  -webkit-appearance: none;
}
.asc textarea {
  min-height: 96px;
  padding: var(--s3) var(--s4);
  resize: vertical;
  line-height: 1.5;
}
.asc select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a8b6c3' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 40px;
}
.asc-input:hover,
.asc select:hover,
.asc textarea:hover {
  border-color: var(--line-3);
}
.asc-input:focus,
.asc select:focus,
.asc textarea:focus {
  outline: none;
  border-color: var(--cy);
  background: var(--bg-2);
}
.asc-input::placeholder,
.asc textarea::placeholder {
  color: var(--tx-3);
}
.asc-input[aria-invalid="true"] {
  border-color: var(--err);
}
.asc-form-grid {
  display: grid;
  gap: var(--s4);
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}
.asc-seg {
  display: inline-grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 3px;
  padding: 3px;
  border-radius: var(--r2);
  background: var(--bg-2);
  border: 1px solid var(--line);
}
.asc-seg button {
  min-height: 38px;
  padding: 0 var(--s3);
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--tx-3);
  font-weight: 700;
  font-size: 13.5px;
}
.asc-seg button[aria-pressed="true"],
.asc-seg button[aria-selected="true"] {
  background: var(--bg-4);
  color: var(--tx);
}
.asc-scale {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 4px;
}
.asc-scale button {
  min-height: 42px;
  border-radius: var(--r1);
  border: 1px solid var(--line);
  background: var(--bg-1);
  color: var(--tx-2);
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 85%;
}
.asc-scale button[aria-pressed="true"] {
  background: var(--cy);
  border-color: var(--cy);
  color: var(--cy-ink);
}

/* ---------- Feedback ---------- */
.asc-empty {
  display: grid;
  justify-items: start;
  gap: var(--s3);
  padding: var(--s6) 0;
  color: var(--tx-2);
}
.asc-empty h2,
.asc-empty h3 {
  font-size: 17px;
}
.asc-skeleton {
  border-radius: var(--r2);
  background: linear-gradient(90deg, var(--bg-2), var(--bg-3), var(--bg-2));
  background-size: 200% 100%;
  animation: asc-shimmer 1.4s linear infinite;
  min-height: 20px;
}
@keyframes asc-shimmer {
  to {
    background-position: -200% 0;
  }
}
.asc-note {
  display: flex;
  gap: var(--s3);
  align-items: flex-start;
  padding: var(--s3) var(--s4);
  border-radius: var(--r2);
  border: 1px solid var(--line);
  background: var(--bg-1);
  color: var(--tx-2);
  font-size: 13.5px;
}
.asc-note .t-icon {
  margin-top: 2px;
  color: var(--tx-3);
}
.asc-note.warn {
  border-color: rgba(240, 162, 74, 0.35);
}
.asc-note.warn .t-icon {
  color: var(--warn);
}
.asc-note.err {
  border-color: rgba(242, 102, 95, 0.35);
}
.asc-note.err .t-icon {
  color: var(--err);
}
.asc-toasts {
  position: fixed;
  z-index: 90;
  left: 50%;
  bottom: calc(var(--tabbar) + var(--safe-b) + var(--s3));
  transform: translateX(-50%);
  display: grid;
  gap: var(--s2);
  width: min(440px, calc(100vw - 2 * var(--s4)));
  pointer-events: none;
}
@media (min-width: 960px) {
  .asc-toasts {
    bottom: var(--s6);
    left: calc(50% + var(--rail) / 2);
  }
}
.asc-toast {
  pointer-events: auto;
  display: flex;
  gap: var(--s3);
  align-items: flex-start;
  padding: var(--s3) var(--s4);
  border-radius: var(--r2);
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  animation: asc-rise var(--t-med) var(--ease);
}
.asc-toast strong {
  display: block;
  font-size: 14px;
}
.asc-toast p {
  font-size: 13px;
  color: var(--tx-2);
}
.asc-toast.ok .t-icon {
  color: var(--cy);
}
.asc-toast.err .t-icon {
  color: var(--err);
}
.asc-toast.warn .t-icon {
  color: var(--warn);
}
@keyframes asc-rise {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}

/* ---------- Sheets / dialogs ---------- */
.asc-sheet {
  border: 0;
  padding: 0;
  margin: auto auto 0;
  width: 100%;
  max-width: 560px;
  max-height: 92dvh;
  border-radius: var(--r4) var(--r4) 0 0;
  background: var(--bg-1);
  color: var(--tx);
  border-top: 1px solid var(--line-2);
  box-shadow: 0 -24px 60px rgba(0, 0, 0, 0.5);
}
.asc-sheet::backdrop {
  background: rgba(2, 4, 6, 0.7);
  backdrop-filter: blur(3px);
}
.asc-sheet[open] {
  animation: asc-sheet-in var(--t-med) var(--ease);
}
@keyframes asc-sheet-in {
  from {
    transform: translateY(24px);
    opacity: 0;
  }
}
.asc-sheet-body {
  padding: var(--s6) var(--s5) calc(var(--s6) + var(--safe-b));
  overflow-y: auto;
  max-height: 92dvh;
}
.asc-sheet-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s3);
  margin-bottom: var(--s5);
}
@media (min-width: 720px) {
  .asc-sheet {
    margin: auto;
    border-radius: var(--r4);
    border: 1px solid var(--line-2);
  }
}

/* ---------- Motion ---------- */
.asc-appear {
  animation: asc-rise 420ms var(--ease) both;
}
.asc-appear:nth-child(2) {
  animation-delay: 60ms;
}
.asc-appear:nth-child(3) {
  animation-delay: 120ms;
}
.asc-appear:nth-child(4) {
  animation-delay: 180ms;
}
@media (prefers-reduced-motion: reduce) {
  .asc *,
  .asc *::before,
  .asc *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
/* Same calm experience when the user asks for it in TITAN, whatever the system setting says. */
html[data-motion="reduced"] *,
html[data-motion="reduced"] *::before,
html[data-motion="reduced"] *::after {
  animation-duration: 0.01ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.01ms !important;
  scroll-behavior: auto !important;
}

/* ---------- Utilities ---------- */
.asc-stack {
  display: grid;
  gap: var(--s4);
}
.asc-stack-sm {
  display: grid;
  gap: var(--s2);
}
.asc-stack-lg {
  display: grid;
  gap: var(--s7);
}
.asc-row-flex {
  display: flex;
  align-items: center;
  gap: var(--s3);
  flex-wrap: wrap;
}
.asc-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s3);
}
.asc-hide-mobile {
  display: none;
}
@media (min-width: 960px) {
  .asc-hide-mobile {
    display: initial;
  }
  .asc-hide-desktop {
    display: none !important;
  }
}
[hidden] {
  display: none !important;
}
.asc-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s2);
  margin-top: var(--s2);
}
.asc-more {
  margin-right: var(--s1);
}
.asc-more[aria-current="page"] {
  color: var(--cy);
}
.asc-more-legal {
  margin-top: var(--s4);
  text-align: center;
}
