/* Base mobile ; les dispositions plus larges sont ajoutées avec min-width. */
@font-face { font-family: "DM Sans"; src: url("../fonts/dm-sans-latin.woff2") format("woff2"); font-weight: 400 750; font-display: swap; }
:root { color: var(--ink); color-scheme: light; font: 400 16px / 1.5 "DM Sans", "Segoe UI", sans-serif; background: var(--paper); --paper: #f6f6ee; --surface: #fffffb; --ink: #172d27; --muted: #52645b; --line: #cfd6ca; --forest: #174a3c; --lime: #dbea9c; --serif: Georgia, "Times New Roman", serif; --gutter: clamp(18px, 4.8vw, 84px); }
* { box-sizing: border-box; }
body { display: flex; flex-direction: column; margin: 0px; min-height: 100svh; }
main { flex: 1 1 0%; width: 100%; }
[hidden] { display: none !important; }
.symbols, .sr-only { clip-path: inset(50%); height: 1px; overflow: hidden; position: absolute; width: 1px; }
.icon { display: inline-block; fill: none; flex: 0 0 auto; height: 19px; stroke: currentcolor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; width: 19px; }
h1, h2, p, figure { margin: 0px; }
button, input, select { color: inherit; font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-underline-offset: 4px; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: 0.5; }
button, a, input, select { outline-offset: 3px; }
:focus-visible { outline: rgb(27, 115, 92) solid 3px; }
.masthead, .site-footer, #access, #catalog { margin-inline: auto; width: min(100%, 1640px); padding-inline: var(--gutter); }
.masthead { align-items: center; display: flex; border-bottom: 1px solid var(--line); }
.brand { align-items: center; gap: 9px; display: inline-flex; font-weight: 750; letter-spacing: -0.055em; text-decoration: none; }
.brand img { border-radius: 10px; }
.area { border-left: 1px solid rgb(181, 191, 177); color: var(--muted); font-size: 13px; padding-left: 18px; }
.masthead nav { align-items: center; display: flex; margin-left: auto; }
.site-link, .quiet { align-items: center; gap: 6px; display: inline-flex; font-size: 14px; font-weight: 600; }
.site-link { text-decoration: none; }
.site-link:hover, .site-footer a:hover { text-decoration: underline; }
.site-link .icon { width: 15px; }
.quiet { background: transparent; border-left: 0px; }
#access { display: grid; }
.entry { place-items: center; display: grid; }
#login { width: min(100%, 370px); }
#login-title, #catalog-title { font-weight: 600; letter-spacing: -0.068em; line-height: 1.02; }
#login-title { font-size: clamp(46px, 4.65vw, 78px); }
h1 em, #catalog-title em { color: var(--forest); letter-spacing: -0.068em; font: italic 400 .98em/.99 var(--serif); }
.intro { color: var(--muted); }
label { font-size: 14px; font-weight: 650; }
#login > label { display: block; margin: 20px 0px 7px; }
.input-shell { align-items: center; border: 1px solid rgb(169, 183, 168); border-radius: 10px; gap: 10px; display: flex; padding-inline: 14px; background: var(--surface); }
.input-shell > .icon { color: var(--muted); width: 18px; }
.input-shell:focus-within { box-shadow: rgba(23, 74, 60, 0.16) 0px 0px 0px 2px; border-color: var(--forest); }
input, select { min-width: 0px; width: 100%; }
input::placeholder { color: rgb(112, 128, 116); opacity: 1; }
.input-shell input { background: transparent; border: 0px; flex: 1 1 0%; font-size: 16px; height: 48px; outline: 0px; padding: 0px; }
.primary, .row-action, .danger, .icon-button { align-items: center; border-radius: 9px; gap: 8px; display: inline-flex; font-weight: 650; justify-content: center; }
.primary { color: white; font-size: 14px; min-height: 45px; padding: 10px 17px; background: var(--forest); border: 1px solid var(--forest); }
.primary:hover:enabled { background: rgb(14, 55, 43); }
.signin { font-size: 15px; justify-content: space-between; margin-top: 25px; min-height: 50px; padding-inline: 18px; width: 100%; }
.signin .icon { color: var(--lime); }
.icon-button { background: transparent; border: 0px; flex: 0 0 auto; min-height: 44px; padding: 0px; width: 44px; }
.input-shell .icon-button { margin-right: -9px; }
.icon-button:hover:enabled, .row-action:hover:enabled, .quiet:hover:enabled { background: rgb(229, 236, 222); color: var(--forest); }
.bordered { border: 1px solid var(--line); background: var(--surface); }
.panorama { background: rgb(46, 68, 82); color: rgb(255, 255, 255); isolation: isolate; overflow: hidden; position: relative; }
.panorama > img { inset: 0px; height: 100%; object-fit: cover; object-position: 48% 42%; position: absolute; width: 100%; z-index: -2; }
.panorama::after { background: linear-gradient(transparent 44%, rgba(20, 44, 53, 0.44) 69%, rgba(17, 41, 47, 0.937)); inset: 0px; content: ""; position: absolute; z-index: -1; }
.panorama figcaption { bottom: 0px; display: grid; justify-items: start; position: absolute; width: 100%; }
.place { align-items: center; color: rgb(238, 246, 224); gap: 6px; display: inline-flex; font-size: 13px; font-weight: 600; }
.place .icon { color: var(--lime); width: 16px; }
.panorama strong { letter-spacing: -0.045em; }
.panorama a { align-items: center; gap: 6px; display: inline-flex; font-size: 14px; font-weight: 600; }
.panorama a:focus-visible { outline-color: var(--lime); }
.panorama a .icon { width: 15px; }
.site-footer { color: var(--muted); gap: 8px 19px; display: flex; flex-wrap: wrap; font-size: 12px; padding-block: 14px; border-top: 1px solid var(--line); }
.site-footer a { text-decoration: none; }
.catalog-heading { display: flex; justify-content: space-between; }
.catalog-actions { gap: 8px; display: flex; flex-wrap: wrap; }
#station-dialog { border-radius: 14px; inset: 0px; height: fit-content; margin: auto; padding: 22px; width: min(420px, 100% - 24px); border: 1px solid var(--line); }
#station-form { gap: 12px; display: grid; }
#station-form .grid { margin: 0px; }
#catalog-title { font-size: clamp(35px, 4.25vw, 62px); }
.catalog-panel { border-radius: 15px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); }
.toolbar { align-items: flex-end; display: flex; flex-wrap: wrap; justify-content: space-between; }
.tools, .filters, .row-actions, .actions { align-items: center; gap: 7px; display: flex; }
.filters { background: rgb(239, 241, 232); border-radius: 9px; gap: 3px; flex-wrap: wrap; padding: 4px; }
.filters button { background: transparent; border: 0px; border-radius: 6px; font-size: 13px; font-weight: 600; min-height: 44px; padding: 7px 11px; }
.filters [aria-pressed="true"] { color: white; background: var(--forest); }
.filters span { font-variant-numeric: tabular-nums; margin-left: 2px; opacity: 0.85; }
.catalog-search { flex: 1 1 360px; min-width: 0px; }
.catalog-search label { display: block; margin-bottom: 5px; }
.search { flex: 1 1 0%; min-width: 0px; }
.search input { height: 44px; }
#check-filters { margin: 0px 20px 15px; max-width: calc(100% - 40px); width: fit-content; }
table { border-collapse: collapse; text-align: left; width: 100%; }
th, td { border-top: 1px solid rgb(223, 228, 217); padding: 13px clamp(9px, 1.4vw, 23px); }
th { background: rgb(240, 242, 235); color: var(--muted); font-size: 12px; font-weight: 600; white-space: nowrap; }
td { font-size: 14px; overflow-wrap: anywhere; }
tr:hover td { background: rgb(248, 249, 242); }
.identity { display: flex; }
.camera-mark { place-items: center; background: rgb(231, 238, 225); border-radius: 8px; color: var(--forest); display: grid; flex: 0 0 auto; height: 52px; overflow: hidden; width: 76px; }
.camera-mark img { height: 100%; object-fit: cover; width: 100%; }
[data-gallery] { border: 0px; cursor: zoom-in; padding: 0px; }
.gallery-preview { background: transparent; display: block; width: 100%; }
.camera-previews { align-items: center; gap: 5px; display: flex; flex: 0 0 auto; }
.tested-thumbnail { border: 0px; border-radius: 6px; cursor: zoom-in; display: block; height: 52px; overflow: hidden; padding: 0px; width: 76px; }
.tested-thumbnail img { display: block; height: 100%; object-fit: cover; width: 100%; }
tr:has(.tested-thumbnail, .camera-mark[data-gallery]) { cursor: pointer; }
#photo-gallery { border-radius: 12px; inset: 0px; height: fit-content; margin: auto; max-height: 94dvh; width: min(1120px, 96%); border: 1px solid var(--line); }
#photo-gallery::backdrop { background: rgba(16, 33, 30, 0.9); }
#gallery-stage { place-items: center; background: rgb(16, 33, 30); color: white; display: grid; height: min(65dvh, 740px); padding: 6px; }
#gallery-stage img { height: 100%; min-height: 0px; object-fit: contain; width: 100%; }
.gallery-nav { align-items: center; gap: 18px; display: flex; font-variant-numeric: tabular-nums; justify-content: center; padding: 12px; }
.camera-check:not(:empty) { display: block; font-size: 12px; margin-top: 5px; }
.camera-check b { color: rgb(120, 83, 22); }
.camera-check[data-state="recent"] b { color: rgb(36, 93, 62); }
.camera-check[data-state="offline"] b { color: rgb(139, 50, 44); }
#check-progress { margin: 0px 20px 15px; }
#share-status { margin: 0px 20px 15px; }
#comparison { border-radius: 12px; inset: 0px; height: fit-content; margin: auto; max-height: 98dvh; width: 98vw; border: 1px solid var(--line); }
.comparison-body { padding: 16px; }
.capture-pair { gap: 12px; display: grid; grid-template-columns: minmax(0, 1fr); margin-top: 15px; }
.replacement-preview { position: relative; }
#save-capture { box-shadow: rgba(0, 0, 0, 0.333) 0px 1px 5px; line-height: 1.15; max-width: calc(100% - 8px); position: absolute; right: 4px; white-space: normal; top: 4px; }
.capture-pair figcaption { font-weight: 650; }
.capture-pair img { display: block; height: min(65dvh, 37vw); object-fit: contain; width: 100%; background: var(--paper); }
.capture-pair small { color: var(--muted); display: block; }
.logo-preview { place-items: center; background: white; border-radius: 8px; display: grid; height: 66px; border: 1px solid var(--line); }
.logo-preview.dark { background: rgb(25, 37, 34); }
.logo-preview img { height: 56px; object-fit: contain; width: 56px; }
.grid .logo-reuse { align-items: center; gap: 8px; display: flex; }
.logo-reuse input { height: 18px; width: 18px; }
.camera-check .outage { color: rgb(139, 50, 44); display: block; font-weight: 700; }
.row-actions { flex-wrap: wrap; }
.action-cell:has(.retest) { grid-area: auto / 1 / auto / -1; }
.action-cell .row-actions { justify-content: flex-start; }
.identity strong, .identity small { display: block; }
.identity strong { font-weight: 650; }
.identity small { color: var(--muted); font-size: 12px; }
.state { align-items: center; background: rgb(229, 240, 223); border-radius: 20px; color: rgb(36, 93, 62); gap: 6px; display: inline-flex; font-size: 12px; font-weight: 650; padding: 4px 9px; white-space: nowrap; }
.state::before { background: currentcolor; border-radius: 50%; content: ""; height: 6px; width: 6px; }
.state.paused { background: rgb(246, 234, 214); color: rgb(122, 80, 28); }
.action-title { text-align: right; }
.row-actions { justify-content: flex-end; }
.row-action { font-size: 13px; padding: 5px 10px; white-space: nowrap; border: 1px solid var(--line); background: var(--surface); }
.row-action .icon { width: 15px; }
.row-action.toggle { padding: 0px; width: 36px; }
#count { color: var(--muted); font-size: 13px; padding: 12px 22px; border-top: 1px solid var(--line); }
.notice { background: rgb(233, 240, 223); border-radius: 7px; color: rgb(36, 80, 62); font-size: 14px; padding: 11px 14px; }
.notice:empty { display: none; }
.notice.error { background: rgb(248, 232, 226); color: rgb(139, 50, 44); }
#login-status { margin-top: 14px; }
#status { margin: 0px 20px 15px; }
dialog { border-bottom: 0px; border-image: none; border-right: 0px; border-top: 0px; inset: 0px 0px 0px auto; color: var(--ink); height: 100%; margin: 0px; max-height: 100%; max-width: 100%; padding: 0px; position: fixed; width: min(610px, 100%); border-left: 1px solid var(--line); background: var(--surface); }
dialog::backdrop { background: rgba(23, 45, 39, 0.52); }
#webcam-form { display: flex; flex-direction: column; height: 100%; }
.drawer-head, .editor-footer { flex: 0 0 auto; padding: 18px clamp(16px, 3vw, 32px); }
.drawer-head { align-items: center; gap: 12px; display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); }
.drawer-head h2 { letter-spacing: -0.04em; font: 400 clamp(25px,2.8vw,36px)/1.1 var(--serif); }
.editor-body { flex: 1 1 0%; overflow-y: auto; overscroll-behavior: contain; padding: 0px clamp(16px, 3vw, 32px); scroll-padding: 16px; }
fieldset { border: 0px; margin: 26px 0px; min-width: 0px; padding: 0px; }
fieldset + fieldset { padding-top: 14px; border-top: 1px solid var(--line); }
legend { color: var(--forest); font-size: 17px; font-weight: 700; padding: 0px 12px 0px 0px; }
.grid { display: grid; margin-top: 12px; }
.grid label { align-content: start; gap: 5px; display: grid; font-size: 13px; min-width: 0px; }
.wide { grid-column: 1 / -1; }
.grid input, select { background: white; border: 1px solid rgb(171, 185, 174); border-radius: 7px; font-size: 16px; font-weight: 400; height: 44px; padding: 8px 11px; }
.grid small { color: var(--muted); font-size: 12px; font-weight: 400; }
.source-test { gap: 10px; display: grid; min-width: 0px; }
.source-test button { justify-self: start; }
#test-preview:empty { display: none; }
#test-preview img { border-radius: 7px; display: block; max-height: 220px; object-fit: contain; width: 100%; background: var(--paper); }
[aria-invalid="true"] { border-color: rgb(153, 60, 45) !important; }
.editor-footer { padding-bottom: max(18px,env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--paper); }
.editor-footer .notice { margin-bottom: 8px; }
.actions { justify-content: space-between; }
#save { margin-left: auto; }
.danger { background: transparent; border: 0px; color: rgb(136, 59, 50); font-size: 14px; min-height: 42px; padding: 8px; }
.area { display: none; }
.masthead { min-height: 62px; }
.catalog-heading { align-items: flex-start; }
table, tbody { display: block; }
thead { clip-path: inset(50%); height: 1px; overflow: hidden; position: absolute; width: 1px; }
tbody tr { align-items: center; gap: 6px 12px; display: grid; grid-template-columns: minmax(0px, 1fr) auto; padding: 14px 17px; border-top: 1px solid var(--line); }
td { border: 0px; display: block; padding: 0px; }
.identity-cell { grid-column: 1; }
.state-cell { grid-area: 1 / 2; justify-self: end; }
td[data-label] { color: var(--muted); font-size: 12px; grid-column: 1; }
td[data-label]::before { content: attr(data-label) " · "; }
.action-cell { grid-area: 2 / 2 / 4; }
.row-action { min-height: 44px; }
.identity { align-items: flex-start; gap: 8px; flex-direction: column; }
.masthead { gap: 8px; }
.masthead nav { gap: 10px; }
.brand { font-size: 19px; }
.brand img { height: 30px; width: 30px; }
.masthead:has(#logout:not([hidden])) .site-link { display: none; }
.quiet { border: 0px; padding: 8px; }
#access { gap: 12px; grid-template-columns: 1fr; padding-block: 0px 24px; }
#login { padding-block: 35px 18px; }
.intro { margin: 14px 0px 20px; max-width: none; }
.panorama { border-radius: 13px; min-height: 240px; }
.panorama figcaption { padding: 18px; }
.panorama strong { font: 400 2rem/1.06 var(--serif); margin: 5px 0px 9px; }
#catalog { padding-block: 30px; }
.catalog-heading { gap: 14px; flex-direction: column; margin-bottom: 16px; }
.toolbar { gap: 12px; padding: 14px; }
.grid { gap: 13px; grid-template-columns: 1fr; }
.editor-footer, .drawer-head { padding-block: 12px; }
.camera-mark, .tested-thumbnail { height: 38px; width: 48px; }
.row-action.edit .icon { display: none; }
.filters button { padding-inline: 7px; }
/* Le catalogue et les formulaires restent utilisables au toucher et au zoom. */
.catalog-actions, .tools, .actions, .row-actions { flex-wrap: wrap; }
.catalog-heading > *, .toolbar > *, .identity { min-width: 0; }
.identity strong, .identity small, .notice { overflow-wrap: anywhere; }
.quiet, .danger, .row-action.toggle { min-width: 44px; min-height: 44px; }
.editor-footer { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
.capture-pair img { height: min(55dvh, 60vw); }
/* Élargissement progressif : (min-width: 381px) */
@media (min-width: 381px) {
  .camera-mark, .tested-thumbnail { height: 52px; width: 76px; }
  .row-action.edit .icon { display: revert; }
  .filters button { padding-inline: 9px; }
}
/* Élargissement progressif : (min-width: 651px) */
@media (min-width: 651px) {
  .capture-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .capture-pair img { height: min(65dvh, 37vw); }
  .identity { flex-direction: revert; }
  .brand img { height: 36px; width: 36px; }
  .masthead:has(#logout:not([hidden])) .site-link { display: inline-flex; }
  .quiet { border-left: revert; }
  .panorama strong { font-size: clamp(31px,3.3vw,60px); }
  .catalog-heading { flex-direction: revert; }
  .filters button { padding-inline: 11px; }
  .editor-footer, .drawer-head { padding-block: 18px; }
  .masthead { gap: 19px; }
  .brand { font-size: 21px; }
  .masthead nav { gap: 20px; }
  .quiet { padding: 9px 0px 9px 15px; border-left: 1px solid var(--line); }
  #access { gap: clamp(25px, 4vw, 72px); grid-template-columns: minmax(0px, 0.84fr) minmax(0px, 1.16fr); padding-block: clamp(22px, 3.2vw, 54px); }
  #login { padding-block: 26px; }
  .intro { margin-bottom: 35px; margin-top: 19px; max-width: 31ch; }
  .panorama { border-radius: 20px; min-height: clamp(450px, -188px + 100svh, 750px); }
  .panorama figcaption { padding: clamp(22px, 3.5vw, 58px); }
  .panorama strong { margin-bottom: 20px; margin-top: 7px; font: 400 clamp(31px,3.3vw,60px)/1.06 var(--serif); }
  #catalog { padding-block: clamp(35px, 5vw, 82px); }
  .catalog-heading { gap: 20px; margin-bottom: 28px; }
  .toolbar { gap: 16px; padding: 19px 22px; }
  .identity { align-items: center; gap: 12px; }
  .grid { gap: 16px; grid-template-columns: 1fr 1fr; }
}
/* Élargissement progressif : (min-width: 821px) */
@media (min-width: 821px) {
  .action-cell:has(.retest) { grid-area: revert; }
  .action-cell .row-actions { justify-content: flex-end; }
  .row-actions { flex-wrap: revert; }
  .area { display: revert; }
  table, tbody { display: revert; }
  thead { clip-path: revert; height: revert; overflow: revert; position: revert; width: revert; }
  tbody tr { align-items: revert; gap: revert; display: revert; grid-template-columns: revert; padding: revert; border-top: revert; }
  td { border: 0; border-top: 1px solid #dfe4d9; display: table-cell; padding: 13px clamp(9px, 1.4vw, 23px); }
  .identity-cell { grid-column: revert; }
  .state-cell { grid-area: revert; justify-self: revert; }
  td[data-label] { color: revert; font-size: revert; grid-column: revert; }
  td[data-label]::before { content: revert; }
  .action-cell { grid-area: revert; }
  .masthead { min-height: 77px; }
  .catalog-heading { align-items: flex-end; }
  .row-action { min-height: 44px; }
}

/* Statistiques : lecture mobile, agrandissement progressif. */
#statistics, .admin-sections { width: min(100%, 1640px); margin-inline: auto; padding-inline: var(--gutter); }
.admin-sections { display: flex; flex-wrap: wrap; gap: 8px; padding-block: 22px 0; }
.admin-sections button { min-height: 44px; padding: 10px 18px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); font-size: 15px; font-weight: 600; }
.admin-sections button[aria-pressed=true] { color: white; border-color: var(--forest); background: var(--forest); }
#statistics { padding-block: 30px 60px; }
.stats-heading { display: flex; flex-direction: column; gap: 22px; margin-bottom: 24px; }
.stats-heading h2 { margin: 4px 0 14px; font: 600 clamp(34px, 4vw, 58px)/1.08 "DM Sans", sans-serif; letter-spacing: -.05em; }
.stats-heading h2 em { color: var(--forest); font-family: var(--serif); font-weight: 400; }
.stats-heading p:not(.stats-eyebrow) { color: var(--muted); }
.stats-eyebrow { font-size: 12px; font-weight: 650; letter-spacing: .12em; color: var(--forest); }
.stats-controls, .stats-import { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 10px; }
.stats-controls label { display: grid; gap: 5px; }
.stats-controls select { min-width: 170px; padding: 8px 11px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; }
.stats-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-block: 20px; }
.stats-card { min-width: 0; padding: 22px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.stats-card h4 { margin: 0 0 16px; font-size: 14px; font-weight: 500; color: var(--muted); }
.stats-card > strong { display: block; font-size: 38px; font-weight: 600; line-height: 1.15; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.stats-card .stats-note { margin-top: 12px; }
.stats-note { font-size: 14px; line-height: 1.7; color: var(--muted); }
.stats-panel { min-width: 0; margin-top: 18px; padding: 20px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); }
.stats-panel h3 { margin: 0 0 15px; font-size: 20px; font-weight: 600; letter-spacing: -.03em; }
.stats-panel-heading { display: flex; flex-direction: column; gap: 16px; margin-bottom: 14px; }
.stats-panel-heading h3 { margin-bottom: 0; }
.stats-columns { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.stats-columns .stats-panel { margin-top: 18px; }
.stats-side { min-width: 0; }
.stats-chart-labels { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
#stats-chart svg { display: block; width: 100%; height: auto; min-height: 135px; }
.stats-gridline { stroke: var(--line); stroke-width: 1; }
.stats-area { fill: #dbea9c66; }
.stats-line { fill: none; stroke: var(--forest); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.stats-distribution { list-style: none; padding: 0; margin: 18px 0 0; }
.stats-distribution li { margin-top: 16px; }
.stats-distribution li > div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.stats-distribution meter { display: block; width: 100%; height: 14px; margin-top: 6px; }
.stats-distribution meter::-webkit-meter-bar { border: 0; background: #edf0e7; border-radius: 10px; }
.stats-distribution meter::-webkit-meter-optimum-value { background: var(--forest); border-radius: 10px; }
.stats-distribution meter::-moz-meter-bar { background: var(--forest); }
.stats-table { display: table; width: 100%; margin-top: 18px; }
.stats-table tbody { display: table-row-group; }
.stats-table thead { display: table-header-group; position: static; clip-path: none; width: auto; height: auto; overflow: visible; }
.stats-table tbody tr, .stats-table thead tr { display: table-row; border: 0; }
.stats-table th, .stats-table td { display: table-cell; padding: 12px 6px; border-top: 1px solid var(--line); font-size: 13px; }
.stats-table th { white-space: normal; }
.stats-table td:first-child { overflow-wrap: anywhere; }
.stats-table td:not(:first-child) { white-space: nowrap; text-align: right; }
.stats-table th:not(:first-child) { text-align: right; }
.stats-upload { position: relative; cursor: pointer; }
.stats-upload input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.stats-upload:focus-within { outline: 3px solid #1b735c; outline-offset: 3px; }
.stats-upload:has(input:disabled) { opacity: .5; cursor: wait; }
.stats-method { max-width: 1000px; margin-top: 24px; }
.stats-site-title { margin-top: 36px; }
#play-source, #play-coverage { overflow-wrap: anywhere; }
#play-setup { margin: 20px 0; }
#play-setup summary { cursor: pointer; min-height: 44px; padding: 10px 0; font-weight: 600; }
#play-setup li { margin-bottom: 10px; }
.play-form { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; max-width: 800px; }
.play-form label { display: grid; gap: 8px; min-width: 0; font-size: 14px; }
.play-form input { width: 100%; min-width: 0; min-height: 44px; padding: 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: inherit; font: inherit; font-size: 16px; }
.play-form input[type=file] { font-size: 14px; }
.play-form > .stats-import { grid-column: 1 / -1; }
@media (min-width: 700px) { .play-form { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 560px) { .stats-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) {
  .stats-heading, .stats-panel-heading { flex-direction: row; align-items: center; justify-content: space-between; }
  .stats-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  #stats-vitals { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stats-columns { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
}
