/* © 2026 Dr. Varin Dejgambhir. va-test-0.6.1. Research use only; not for clinical decisions. All rights reserved; no copying or redistribution. */
@font-face { font-family: 'Sarabun'; font-weight: 400; font-display: block; src: url(../fonts/sarabun-400-thai.woff2) format('woff2'); unicode-range: U+0E01-0E5B, U+200C-200D, U+25CC; }
@font-face { font-family: 'Sarabun'; font-weight: 400; font-display: block; src: url(../fonts/sarabun-400-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; }
@font-face { font-family: 'Sarabun'; font-weight: 600; font-display: block; src: url(../fonts/sarabun-700-thai.woff2) format('woff2'); unicode-range: U+0E01-0E5B, U+200C-200D, U+25CC; }
@font-face { font-family: 'Sarabun'; font-weight: 600; font-display: block; src: url(../fonts/sarabun-700-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; }
@font-face { font-family: 'SarabunOpt'; font-weight: 800; font-display: block; src: url(../fonts/sarabun-800-latin.woff2) format('woff2'); }
:root {
--colorNeutralBackground1: #ffffff; --colorNeutralBackground1Hover: #f5f5f5; --colorNeutralBackground1Pressed: #e0e0e0;
--colorNeutralBackground2: #F4F6F8; --colorNeutralBackground3: #f5f5f5; --colorNeutralBackground4: #f0f0f0;
--colorNeutralForeground1: #0E1B2C; --colorNeutralForeground2: #2B3A50; --colorNeutralForeground3: #46536A; --colorNeutralForeground4: #6B7688;
--colorNeutralForegroundDisabled: #bdbdbd; --colorNeutralBackgroundDisabled: #f0f0f0; --colorNeutralStrokeDisabled: #e0e0e0;
--colorNeutralStroke1: #D3D9E2; --colorNeutralStroke1Hover: #c7c7c7; --colorNeutralStroke1Pressed: #b3b3b3; --colorNeutralStroke2: #EDF0F4;
--colorNeutralStrokeAccessible: #8A96A8; --colorNeutralForegroundOnBrand: #ffffff;
--brand10: #061724; --brand20: #082338; --brand30: #0a2e4a; --brand40: #0c3b5e; --brand50: #0e4775; --brand60: #0f548c; --brand70: #115ea3; --brand80: #0f6cbd;
--brand90: #2886de; --brand100: #479ef5; --brand110: #62abf5; --brand120: #77b7f7; --brand130: #96c6fa; --brand140: #b4d6fa; --brand150: #cfe4fa; --brand160: #ebf3fc;
--navy: #123B6D; --navyDark: #0A2441; --jade: #0A6B52; --jadeDark: #06493A; --red: #C0392B; --amber: #F3C46A; --amberDark: #D9962B; --amberText: #7A4A00; --plum: #5B3A8C; --ground: #F4F6F8; --line: #D3D9E2; --ink: #0E1B2C; --ink2: #46536A;
--colorBrandBackground: var(--navy); --colorBrandBackgroundHover: #0E2F57; --colorBrandBackgroundPressed: var(--navyDark);
--colorBrandBackground2: #E6EDF6; --colorBrandForeground1: var(--navy); --colorBrandStroke1: var(--navy); --brand40: var(--navyDark);
--colorStrokeFocus2: #000000; --colorPaletteRedForeground1: #C0392B; --colorPaletteRedBackground1: #fdf3f4;
--s2: 2px; --s4: 4px; --s8: 8px; --s12: 12px; --s16: 16px; --s20: 20px; --s24: 24px; --s32: 32px; --s40: 40px;
--radiusSmall: 4px; --radiusMedium: 12px; --radiusLarge: 14px; --radiusXLarge: 16px; --radiusCircular: 10000px;
--caption1: 15px; --caption1Lh: 20px; --body1: 17px; --body1Lh: 24px; --body2: 20px; --body2Lh: 28px;
--subtitle1: 22px; --subtitle1Lh: 30px; --title3: 26px; --title3Lh: 34px; --title2: 30px; --title2Lh: 38px; --title1: 34px; --title1Lh: 44px;
--weightRegular: 400; --weightSemibold: 600;
--shadow2: 0 0 2px rgba(0,0,0,.12), 0 1px 2px rgba(0,0,0,.14);
--shadow4: 0 1px 2px rgba(14,27,44,.06), 0 4px 16px rgba(14,27,44,.06);
--shadow8: 0 1px 2px rgba(14,27,44,.08), 0 4px 16px rgba(14,27,44,.08);
--shadow28: 0 0 8px rgba(0,0,0,.12), 0 14px 28px rgba(0,0,0,.14);
--target: 52px; --targetLarge: 62px;
--fontFamilyBase: 'Sarabun', 'Segoe UI', system-ui, sans-serif;
color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--colorNeutralBackground2); color: var(--colorNeutralForeground1); font-family: var(--fontFamilyBase); font-size: var(--body2); line-height: var(--body2Lh); -webkit-tap-highlight-color: transparent; }
body { overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
.screen { display: none; position: absolute; inset: 0; padding: var(--s20) var(--s24) var(--s16); overflow-y: auto; }
.screen.active { display: block; }
.screen.center.active { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s32); text-align: center; background: var(--colorNeutralBackground1); }
h1 { font-size: var(--title2); line-height: var(--title2Lh); font-weight: var(--weightSemibold); margin: 0 0 var(--s12); }
h2 { font-size: var(--subtitle1); line-height: var(--subtitle1Lh); font-weight: var(--weightSemibold); margin: 0 0 var(--s12); }
.lead { font-size: var(--subtitle1); line-height: var(--subtitle1Lh); margin: var(--s4) 0 var(--s16); }
.lead.xl { font-size: var(--title1); line-height: var(--title1Lh); font-weight: var(--weightSemibold); }
.hint { color: var(--colorNeutralForeground3); font-size: var(--body1); line-height: var(--body1Lh); margin: var(--s8) 0; }
.row { display: flex; gap: var(--s12); flex-wrap: wrap; align-items: center; margin: var(--s12) 0; }
a { color: var(--colorBrandForeground1); }
button {
min-height: var(--target); padding: var(--s8) var(--s20); border-radius: var(--radiusMedium);
border: 1px solid var(--colorNeutralStroke1); background: var(--colorNeutralBackground1); color: var(--colorNeutralForeground1);
font-weight: var(--weightSemibold); cursor: pointer; transition: background .1s, border-color .1s;
}
button:hover { background: var(--colorNeutralBackground1Hover); border-color: var(--colorNeutralStroke1Hover); }
button:active { background: var(--colorNeutralBackground1Pressed); border-color: var(--colorNeutralStroke1Pressed); }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--colorStrokeFocus2); outline-offset: 1px; }
button:disabled, button:disabled:hover { background: var(--colorNeutralBackgroundDisabled); border-color: var(--colorNeutralStrokeDisabled); color: var(--colorNeutralForegroundDisabled); cursor: default; }
button.primary { background: var(--colorBrandBackground); border-color: transparent; color: var(--colorNeutralForegroundOnBrand); }
button.primary:hover { background: var(--colorBrandBackgroundHover); }
button.primary:active { background: var(--colorBrandBackgroundPressed); }
button.primary:disabled { background: var(--colorNeutralBackgroundDisabled); border-color: var(--colorNeutralStrokeDisabled); color: var(--colorNeutralForegroundDisabled); }
button.huge { min-height: 72px; min-width: 280px; font-size: var(--title3); line-height: var(--title3Lh); border-radius: var(--radiusXLarge); }
button.ghost { background: transparent; border-color: transparent; color: var(--colorNeutralForeground2); }
button.ghost:hover { background: var(--colorNeutralBackground1Hover); }
.formhead { display: flex; align-items: baseline; gap: var(--s16); flex-wrap: wrap; }
.research { font-size: 16px; line-height: var(--caption1Lh); color: var(--ink2); }
.grid { display: grid; grid-template-columns: minmax(280px, 1fr) 2fr; gap: var(--s20); align-items: start; }
fieldset { border: none; background: var(--colorNeutralBackground1); box-shadow: var(--shadow4); border-radius: var(--radiusXLarge); padding: var(--s12) var(--s16) var(--s16); margin: 0; }
legend { font-size: var(--body2); font-weight: var(--weightSemibold); padding: 0; margin-bottom: var(--s8); }
.tick { display: flex; gap: var(--s12); align-items: center; min-height: var(--targetLarge); font-size: var(--body2); line-height: var(--body2Lh); border-bottom: 1px solid var(--colorNeutralStroke2); cursor: pointer; }
.tick:last-of-type { border-bottom: none; }
.tick input { appearance: none; -webkit-appearance: none; width: 28px; height: 28px; flex: none; margin: 10px; border: 1px solid var(--colorNeutralStrokeAccessible); border-radius: var(--radiusSmall); background: var(--colorNeutralBackground1); display: grid; place-content: center; cursor: pointer; }
.tick input::after { content: ''; width: 14px; height: 8px; border-left: 3px solid #fff; border-bottom: 3px solid #fff; transform: translateY(-2px) rotate(-45deg); opacity: 0; }
.tick input:checked { background: var(--jade); border-color: var(--jade); }
.tick input:checked::after { opacity: 1; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s12) var(--s20); background: var(--colorNeutralBackground1); box-shadow: var(--shadow4); border-radius: var(--radiusXLarge); padding: var(--s16); }
.field { display: flex; flex-direction: column; gap: var(--s4); font-size: var(--body1); line-height: var(--body1Lh); font-weight: var(--weightSemibold); color: var(--colorNeutralForeground1); }
.field.wide { grid-column: 1 / -1; }
.field input, .field select, .field textarea {
min-height: var(--target); font-size: var(--subtitle1); padding: var(--s8) var(--s12); font-weight: var(--weightRegular);
border: 1px solid var(--colorNeutralStroke1); border-bottom-color: var(--colorNeutralStrokeAccessible); border-radius: var(--radiusMedium); background: var(--colorNeutralBackground1);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom: 2px solid var(--colorBrandStroke1); padding-bottom: 7px; }
.field input::placeholder { color: var(--colorNeutralForeground4); }
.field textarea { font-size: var(--body2); }
.seg { display: flex; gap: var(--s8); flex-wrap: wrap; }
.seg button { flex: 1 1 auto; min-width: 96px; font-weight: var(--weightRegular); }
.seg button.on, .seg button.on:hover { background: var(--navy); border: 2px solid var(--navy); color: #fff; font-weight: var(--weightSemibold); }
.startrow { display: flex; align-items: center; gap: var(--s16); margin-top: var(--s20); flex-wrap: wrap; }
.footline { display: flex; justify-content: space-between; gap: var(--s12); flex-wrap: wrap; margin-top: var(--s16); color: var(--colorNeutralForeground3); font-size: var(--body1); }
#queueline { font-weight: var(--weightSemibold); color: var(--colorNeutralForeground1); }
#modelbar { position: fixed; right: var(--s12); top: var(--s8); z-index: 50; font-size: var(--caption1); line-height: var(--caption1Lh); color: var(--colorNeutralForeground3); display: flex; align-items: center; gap: var(--s8); pointer-events: none; }
#modelbar.ready { display: none; }
#modelprog { width: 72px; height: 4px; background: var(--colorNeutralStroke2); border-radius: var(--radiusCircular); overflow: hidden; }
#modelprog > div { height: 100%; width: 0; background: var(--colorBrandBackground); }
#modelbar.err { color: var(--colorPaletteRedForeground1); font-weight: var(--weightSemibold); }
#calbar-wrap { padding: var(--s20) 0; }
#calbar { height: 24px; background: #000; }
.big { font-size: var(--subtitle1); line-height: var(--subtitle1Lh); font-weight: var(--weightSemibold); display: flex; align-items: center; gap: var(--s12); }
.big input { width: 7em; min-height: var(--targetLarge); font-size: var(--title3); padding: var(--s4) var(--s12); border: 1px solid var(--colorNeutralStroke1); border-bottom-color: var(--colorNeutralStrokeAccessible); border-radius: var(--radiusMedium); }
#scr-test { padding: 0; background: #ffffff; }
#opt { position: absolute; left: 0; top: 0; width: 100%; display: block; }
#testbar { position: absolute; left: 0; right: 0; bottom: 0; height: 56px; display: flex; align-items: center; gap: 8px; padding: 0 8px; color: #b0b0b0; font-size: 12px; background: #ffffff; }
#testbar button { min-height: 48px; min-width: 64px; padding: 4px 12px; font-size: 13px; color: #9e9e9e; border: 1px solid #ececec; background: #ffffff; font-weight: 400; border-radius: 4px; }
#testbar .spacer { flex: 1; }
#state { width: 10px; height: 10px; display: inline-block; border: 2px solid #c8c8c8; border-radius: 50%; }
#state.processing { border-radius: 2px; background: #c8c8c8; }
#state.muted { border-radius: 0; height: 2px; border-width: 1px; }
.overlay { position: absolute; inset: 0; background: rgba(255,255,255,.9); display: flex; align-items: center; justify-content: center; z-index: 20; }
.overlay[hidden] { display: none; }
.card { background: var(--colorNeutralBackground1); box-shadow: var(--shadow28); border-radius: var(--radiusXLarge); padding: var(--s24); max-width: 640px; }
.card li { margin: var(--s8) 0; font-size: var(--body2); }
.meter { height: 16px; background: var(--colorNeutralBackground4); border-radius: var(--radiusCircular); overflow: hidden; margin: var(--s16) 0 var(--s4); }
.meter > div { height: 100%; width: 0; background: var(--colorBrandBackground); }
#results { display: flex; gap: var(--s16); flex-wrap: wrap; margin: var(--s8) 0 var(--s4); }
.rescard { background: var(--colorNeutralBackground1); box-shadow: var(--shadow8); border-radius: var(--radiusXLarge); padding: var(--s16) var(--s20); min-width: 280px; }
.rescard .eye { font-weight: var(--weightSemibold); font-size: var(--subtitle1); line-height: var(--subtitle1Lh); }
.rescard .va { font-size: var(--title1); line-height: var(--title1Lh); font-weight: var(--weightSemibold); margin: var(--s4) 0; }
.rescard .vasub { font-size: var(--body1); line-height: var(--body1Lh); color: var(--colorNeutralForeground2); }
.rescard .sub { color: var(--colorNeutralForeground3); font-size: var(--body1); }
.feedback { margin-top: var(--s12); display: grid; gap: var(--s12); }
.fbrow { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s12); }
.settings { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s12) var(--s20); background: var(--colorNeutralBackground1); box-shadow: var(--shadow4); border-radius: var(--radiusXLarge); padding: var(--s16); }
#st-info { font-size: var(--caption1); line-height: var(--caption1Lh); white-space: pre-wrap; color: var(--colorNeutralForeground3); }
@media (orientation: portrait), (max-width: 900px) {
.grid { grid-template-columns: 1fr; }
.settings, .fbrow { grid-template-columns: 1fr; }
.screen { padding: var(--s16) var(--s16) var(--s12); }
button.huge { min-width: 0; width: 100%; }
.startrow { flex-direction: column; align-items: stretch; }
.startrow .spacer { display: none; }
#digtable th:nth-child(3), #digtable td:nth-child(3) { display: none; }
}
@media (max-width: 520px) { .fields { grid-template-columns: 1fr; } }
.spacer { flex: 1; }
button.small { min-height: var(--target); padding: var(--s4) var(--s12); font-size: var(--body1); }
.banner { background: var(--colorPaletteRedBackground1); color: var(--colorPaletteRedForeground1); border-radius: var(--radiusMedium); padding: var(--s12) var(--s16); margin: 0 0 var(--s12); font-weight: var(--weightSemibold); }
.banner[hidden] { display: none; }
.miccheck { margin-top: var(--s12); padding-top: var(--s12); border-top: 1px solid var(--colorNeutralStroke2); }
.microw { display: flex; gap: var(--s8); font-size: var(--body1); }
.miclabel { font-weight: var(--weightSemibold); }
#micname { color: var(--colorNeutralForeground2); overflow-wrap: anywhere; }
.miccheck .meter { margin: var(--s8) 0 var(--s4); height: 10px; }
.micwarn { color: var(--colorPaletteRedForeground1); font-size: var(--body1); line-height: var(--body1Lh); }
.micwarn.ok { color: #0e700e; }
button.recmode { min-height: 72px; border: 2px solid var(--colorBrandStroke1); color: var(--colorBrandForeground1); font-size: var(--subtitle1); }
.fields.narrow { max-width: 480px; grid-template-columns: 1fr; }
.licence { white-space: pre-wrap; font-family: var(--fontFamilyBase); font-size: var(--body2); background: var(--colorNeutralBackground1); box-shadow: var(--shadow4); border-radius: var(--radiusXLarge); padding: var(--s16); max-width: 900px; }
.infobox { font-family: var(--fontFamilyBase); white-space: pre-wrap; font-size: var(--caption1); line-height: var(--caption1Lh); color: var(--colorNeutralForeground3); }
.tabs { display: flex; gap: var(--s4); flex-wrap: wrap; margin: var(--s8) 0 var(--s16); border-bottom: 1px solid var(--colorNeutralStroke2); }
.tabs button { border: none; border-bottom: 3px solid transparent; border-radius: 0; background: transparent; font-weight: var(--weightRegular); }
.tabs button.on { border-bottom-color: var(--colorBrandStroke1); font-weight: var(--weightSemibold); }
.tabpane { display: none; }
.tabpane.on { display: block; }
.tablewrap { overflow-x: auto; background: var(--colorNeutralBackground1); box-shadow: var(--shadow4); border-radius: var(--radiusXLarge); }
table { border-collapse: collapse; width: 100%; font-size: var(--body1); }
th, td { text-align: left; padding: var(--s8) var(--s12); border-bottom: 1px solid var(--colorNeutralStroke2); vertical-align: middle; }
th { font-weight: var(--weightSemibold); color: var(--colorNeutralForeground2); background: var(--colorNeutralBackground2); }
tr.playable { cursor: pointer; }
tr.playable:hover { background: var(--colorNeutralBackground1Hover); }
tr.playing { background: var(--colorBrandBackground2); }
td select { min-height: var(--target); font-size: var(--body1); border: 1px solid var(--colorNeutralStroke1); border-radius: var(--radiusMedium); padding: 0 var(--s8); }
td.big { display: table-cell; font-size: var(--subtitle1); font-weight: var(--weightSemibold); line-height: 1; vertical-align: middle; }
.conf { display: inline-block; border-radius: var(--radiusMedium); padding: var(--s2) var(--s8); font-size: var(--caption1); font-weight: var(--weightSemibold); }
.conf { padding: 0; border-radius: 0; font-size: var(--body1); }
.conf.clear { color: var(--jade); }
.conf.uncertain { color: var(--amberText); }
.conf.unclear { color: var(--red); }
.conf.operator { color: var(--colorNeutralForeground2); }
.review { margin: var(--s16) 0; }
.review .tick { border: none; }
details { margin-top: var(--s8); }
summary { cursor: pointer; min-height: var(--target); display: flex; align-items: center; color: var(--colorBrandForeground1); font-weight: var(--weightSemibold); }
.rechead { display: flex; align-items: center; gap: var(--s12); }
.recdigit { font-family: 'SarabunOpt', sans-serif; font-weight: 800; font-size: min(52vh, 420px); line-height: 1; text-align: center; color: #000; margin: var(--s8) 0; }
.center-text { text-align: center; }
.center-row { justify-content: center; }
.recmeter { max-width: 420px; margin: var(--s8) auto; }
.pinbox { font-size: var(--title1); width: 8em; text-align: center; min-height: 64px; border: 1px solid var(--colorNeutralStroke1); border-bottom-color: var(--colorNeutralStrokeAccessible); border-radius: var(--radiusMedium); }
#calbar { position: relative; height: 28px; background: #000; touch-action: none; }
#calhandle { position: absolute; right: -24px; top: -18px; width: 48px; height: 64px; cursor: ew-resize; background: transparent; border-right: 3px dashed var(--colorBrandStroke1); }
.statgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--s8); margin: var(--s12) 0; }
.stat { background: var(--colorNeutralBackground1); box-shadow: var(--shadow2); border-radius: var(--radiusLarge); padding: var(--s8) var(--s12); }
.stat b { font-size: var(--subtitle1); }
.bar { height: 6px; background: var(--colorNeutralStroke2); border-radius: var(--radiusCircular); overflow: hidden; margin-top: var(--s4); }
.bar > div { height: 100%; background: var(--colorBrandBackground); }
.standcue { position: absolute; inset: 0; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; z-index: 15; }
.standcue[hidden] { display: none; }
.standtext { font-size: 40px; line-height: 52px; font-weight: 600; color: #242424; }
.transfx { position: absolute; left: 0; top: 0; pointer-events: none; display: none; place-content: center; }
.transfx.run, .transfx.wait { display: grid; }
.transfx.run { grid-template-columns: repeat(12, 1fr); grid-template-rows: repeat(7, 1fr); place-content: stretch; gap: 3px; background: #fff; }
.transfx i { display: block; background: #9aa0a6; opacity: 0; transform: scale(0.15); will-change: transform, opacity; }
.transfx.run i { animation: fxin calc(var(--t, 1000ms) * 0.15) ease-out calc(var(--a) * var(--t, 1000ms) * 0.4) both,
fxout calc(var(--t, 1000ms) * 0.15) ease-in calc(var(--t, 1000ms) * 0.6 + var(--r) * var(--t, 1000ms) * 0.25) forwards; }
.transfx.wait i { display: none; }
.transfx .dots { display: none; gap: 3vmin; }
.transfx.wait .dots { display: flex; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.transfx .dots b { width: 4vmin; height: 4vmin; background: #9aa0a6; opacity: 0.35; animation: fxdot 1050ms ease-in-out infinite; will-change: opacity, transform; }
.transfx .dots b:nth-child(2) { animation-delay: 350ms; }
.transfx .dots b:nth-child(3) { animation-delay: 700ms; }
@keyframes fxin { from { opacity: 0; transform: scale(0.15); } to { opacity: 1; transform: scale(1); } }
@keyframes fxout { from { opacity: 1; transform: scale(1); } to { opacity: 0; transform: scale(0.15); } }
@media (prefers-reduced-motion: reduce) { .transfx.run i { animation: fxin calc(var(--t, 1000ms) * 0.2) linear both, fxout calc(var(--t, 1000ms) * 0.2) linear calc(var(--t, 1000ms) * 0.75) forwards; } }
@keyframes fxdot { 0%, 100% { opacity: 0.35; transform: scale(0.7); } 33% { opacity: 1; transform: scale(1); } }
.field select, .field input, .field textarea { max-width: 100%; min-width: 0; width: 100%; }
.settings > *, .fields > * { min-width: 0; }
button.play { min-height: 48px; min-width: 72px; padding: 4px 10px; font-weight: var(--weightRegular); }
.playcount { margin-left: 6px; color: #0e700e; font-size: var(--caption1); }
.micsteps ol { margin: var(--s8) 0; padding-left: 1.4em; font-size: var(--body1); line-height: var(--body1Lh); }
.micsteps code, details code { font-size: var(--caption1); color: var(--colorNeutralForeground3); overflow-wrap: anywhere; }
#mic-retry { margin-top: var(--s8); }
.standcue { padding: 24px; text-align: center; }
.standtext { max-width: 90vw; overflow-wrap: anywhere; }
@media (orientation: portrait) {
h1 { font-size: var(--title3); line-height: var(--title3Lh); margin-bottom: var(--s8); }
.tick { min-height: 48px; font-size: var(--body1); line-height: var(--body1Lh); }
.tick input { width: 24px; height: 24px; margin: 12px; }
.consent .hint { margin: var(--s4) 0; }
.miccheck { margin-top: var(--s8); padding-top: var(--s8); }
.grid { gap: var(--s12); }
.fields { gap: var(--s8) var(--s12); padding: var(--s12); }
.field input, .field select { min-height: 48px; font-size: var(--body2); }
.startrow { margin-top: var(--s12); gap: var(--s8); }
button.huge { min-height: 60px; font-size: var(--subtitle1); }
button.recmode { min-height: 52px; font-size: var(--body2); }
.footline { margin-top: var(--s8); font-size: var(--caption1); }
fieldset { padding: var(--s8) var(--s12) var(--s12); }
}
body { background: var(--ground); }
button.outline { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 60px; padding: 10px 18px; border-radius: 14px; border: 2px solid var(--line); background: #fff; color: var(--ink); font-size: 19px; font-weight: 600; }
button.outline.navy { border-color: var(--navy); color: var(--navy); font-weight: 700; }
button.outline.navy:disabled { border-color: var(--line); color: var(--colorNeutralForegroundDisabled); background: #fff; }
button.jadebtn { background: var(--jade); border-color: var(--jade); color: #fff; font-weight: 700; border-radius: 16px; }
button.jadebtn:hover { background: #085A45; }
button.jadebtn:disabled { background: #C9D1DB; border-color: #C9D1DB; color: var(--ink2); }
.warntext { color: var(--amberText); font-size: 18px; font-weight: 600; }
.muted { color: var(--ink2); font-size: 17px; }
.tabbar { display: none; position: fixed; left: 0; right: 0; bottom: 0; height: 84px; z-index: 30; background: #fff; border-top: 1px solid var(--line); grid-template-columns: repeat(4, minmax(0, 1fr)); }
body[data-screen="register"] .tabbar, body[data-screen="patients"] .tabbar, body[data-screen="tools"] .tabbar, body[data-screen="settings"] .tabbar, body[data-screen="pin"] .tabbar { display: grid; }
.tabbar button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 84px; border: 0; border-radius: 0; background: #fff; color: var(--ink2); font-size: 17px; font-weight: 600; padding: 4px; }
.tabbar button:hover { background: #fff; }
body[data-screen="register"] .tabbar [data-nav="register"], body[data-screen="patients"] .tabbar [data-nav="patients"], body[data-screen="tools"] .tabbar [data-nav="tools"],
body[data-screen="settings"] .tabbar [data-nav="settings"], body[data-screen="pin"][data-pinfor="patients"] .tabbar [data-nav="patients"], body[data-screen="pin"][data-pinfor="settings"] .tabbar [data-nav="settings"] { color: var(--navy); box-shadow: inset 0 4px 0 var(--navy); }
.screen.navscr { bottom: 84px; }
.screen.v2 { padding: 0; background: var(--ground); }
.v2head { display: flex; align-items: center; gap: 12px; min-height: 76px; padding: 0 20px; }
.v2head h1 { font-size: 28px; line-height: 36px; font-weight: 700; margin: 0; }
.v2body { padding: 0 16px 16px; display: flex; flex-direction: column; gap: 12px; }
.card2 { background: #fff; border-radius: 16px; padding: 16px 20px; box-shadow: var(--shadow4); border: 0; margin: 0; }
.cardhead { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.cardtitle { font-size: 22px; font-weight: 700; flex: 1; }
.grp { font-size: 18px; font-weight: 700; color: var(--ink2); margin-top: 6px; }
#scr-register.active { display: flex; flex-direction: column; }
#scr-register .v2head, #scr-register .actionbar { flex: none; }
#scr-register .v2body { gap: 14px; flex: 1 0 auto; }
.homegrid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.consent.card2 { padding: 16px 20px 6px; }
.consent .tick { min-height: 62px; font-size: 21px; line-height: 28px; gap: 16px; border-bottom: 0; border-top: 1px solid var(--colorNeutralStroke2); }
.consent .tick input { width: 34px; height: 34px; margin: 0; border-radius: 6px; border: 2px solid #8A96A8; }
.consent .tick input::after { width: 16px; height: 9px; }
.consent .consent-hint { margin: 4px 0 8px; font-size: 16px; }
#consent-count.done { color: var(--jade); }
.ptcard-form { padding: 16px 18px 18px; }
.g6 { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); column-gap: 10px; row-gap: 6px; align-items: end; }
.g6 .cardtitle { margin-bottom: 6px; }
.g6 .seg { display: contents; }
.s2 { grid-column: span 2; } .s4 { grid-column: span 4; } .s6 { grid-column: span 6; }
.cap { font-size: 15px; font-weight: 600; color: var(--ink2); margin-top: 8px; }
.capnote { font-weight: 400; }
.g6 .seg button { min-width: 0; min-height: 64px; padding: 0 6px; border-radius: 14px; border: 2px solid var(--line); background: #fff; color: var(--ink); font-size: 22px; font-weight: 400; line-height: 1.2; }
.g6 .seg button.on { background: var(--navy); border-color: var(--navy); color: #fff; font-weight: 600; }
.g6 .seg button.dist, .g6 .seg button.ico { display: flex; align-items: center; justify-content: center; gap: 10px; line-height: 1; }
.g6 .seg button.dist b { font-size: 26px; font-weight: 700; line-height: 1; }
.g6 .seg button.dist span { font-size: 19px; font-weight: 600; line-height: 1; }
.g6 .seg button.ico svg { flex: none; }
.hnbox { display: flex; align-items: stretch; height: 64px; border: 2px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; min-width: 0; }
.hnbox:focus-within { border-color: var(--navy); }
.hntag { display: flex; align-items: center; padding: 0 14px; background: var(--navy); color: #fff; font-size: 18px; font-weight: 700; letter-spacing: 1px; }
.hnbox input { border: 0; outline: 0; flex: 1; min-width: 0; font-size: 30px; font-weight: 700; letter-spacing: 1px; padding: 0 10px 0 14px; color: var(--ink); background: transparent; }
.hnbox input::placeholder { font-size: 20px; font-weight: 400; letter-spacing: 0; color: var(--colorNeutralForeground4); }
button.hnbtn { min-height: 0; display: flex; align-items: center; justify-content: center; padding: 0 14px; border: 0; border-left: 2px solid var(--line); border-radius: 0; background: var(--ground); color: var(--navy); font-size: 18px; font-weight: 700; }
button.hnbtn:hover { background: #E6EDF6; }
button.hnscan { width: 60px; padding: 0; }
.agebox { display: flex; align-items: center; height: 64px; border: 2px solid var(--line); border-radius: 14px; padding: 0 14px; background: #fff; min-width: 0; }
.agebox:focus-within { border-color: var(--navy); }
.agebox span { font-size: 16px; font-weight: 600; color: var(--ink2); }
.agebox input { border: 0; outline: 0; width: 100%; min-width: 0; text-align: right; font-size: 30px; font-weight: 700; padding: 0 6px; color: var(--ink); background: transparent; }
.miccard { display: flex; align-items: center; gap: 14px; padding: 12px 16px 12px 20px; }
.miccard .cardtitle { flex: none; }
.micico { color: var(--jade); flex: none; }
.micmain { flex: 1; min-width: 0; }
.miccard .micwarn { font-size: 19px; line-height: 26px; font-weight: 600; color: var(--red); }
.miccard .micwarn.ok { color: var(--jade); }
.miccard .meter { height: 12px; margin: 4px 0 2px; background: var(--colorNeutralStroke2); }
.meter > div, .tmeter > span { background: var(--jade); }
.micname { font-size: 15px; line-height: 20px; color: var(--ink2); overflow-wrap: anywhere; }
#scr-register .footline { margin: 0 4px; font-size: 15px; }
.actionbar { position: sticky; bottom: 0; z-index: 5; padding: 10px 16px 14px; background: var(--ground); display: flex; flex-direction: column; gap: 8px; }
#startwhy:empty { display: none; }
#startwhy { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.actions { display: grid; grid-template-columns: 1fr 2.2fr; gap: 10px; }
button.plumbtn { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 84px; padding: 10px 12px; border-radius: 16px; border: 0; background: var(--plum); color: #fff; font-size: 19px; font-weight: 700; line-height: 1.2; text-align: center; }
button.plumbtn:hover { background: #4D3077; }
button.plumbtn:disabled, button.plumbtn:disabled:hover { background: #B7A8CF; color: #F3F0F8; border: 0; }
button.plumbtn svg { flex: none; }
button.gostart { min-height: 84px; border-radius: 16px; border: 0; background: var(--jade); color: #fff; font-size: 28px; font-weight: 700; }
button.gostart:hover { background: #085A45; }
button.gostart:disabled, button.gostart:disabled:hover { background: #C9D1DB; color: var(--ink2); border: 0; }
@media (orientation: landscape) and (min-width: 1000px) {
.homegrid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); grid-template-rows: auto 1fr; align-items: start; }
.homegrid .consent { grid-column: 1; grid-row: 1; }
.homegrid .miccard { grid-column: 1; grid-row: 2; }
.homegrid .ptcard-form { grid-column: 2; grid-row: 1 / span 2; }
#scr-register .v2head { min-height: 60px; }
}
@media (orientation: portrait) and (max-height: 1240px) {
.consent .consent-hint, #scr-register .footline { display: none; }
#scr-register .v2head { min-height: 64px; }
.consent.card2 { padding-bottom: 4px; }
}
@media (orientation: portrait) and (max-height: 1120px) {
#scr-register .v2head { min-height: 56px; }
#scr-register .v2body { gap: 10px; }
.homegrid { gap: 10px; }
.consent .tick { min-height: 48px; font-size: 19px; }
.consent .consent-hint { display: none; }
.consent.card2 { padding: 12px 18px 4px; }
.cardhead { margin-bottom: 4px; }
.ptcard-form { padding: 12px 16px 14px; }
.g6 .seg button, .hnbox, .agebox { min-height: 56px; height: 56px; }
#startwhy { font-size: 16px; line-height: 22px; }
.cap { margin-top: 4px; }
.miccard { padding: 8px 14px; }
.miccard button.outline { min-height: 52px; }
.actionbar { padding: 6px 16px 10px; gap: 6px; }
button.plumbtn, button.gostart { min-height: 72px; }
#scr-register .footline { display: none; }
}
#scr-scan { padding: 0; background: #0B1420; color: #fff; overflow: hidden; }
#scan-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: radial-gradient(ellipse at 50% 42%, #3A4655 0%, #1A2431 55%, #0B1420 100%); }
.scanshade { position: absolute; inset: 0; background: linear-gradient(rgba(11,20,32,.55), rgba(11,20,32,0) 18%, rgba(11,20,32,0) 70%, rgba(11,20,32,.6)); pointer-events: none; }
.scanhead { position: absolute; left: 0; right: 0; top: 0; display: flex; align-items: center; gap: 12px; height: 76px; padding: 0 12px 0 8px; z-index: 2; }
button.scanicon { width: 56px; height: 56px; min-height: 56px; padding: 0; display: flex; align-items: center; justify-content: center; border: 0; border-radius: 14px; background: transparent; }
button.scanicon:hover { background: rgba(255,255,255,.12); }
button.scanicon.filled, button.scanicon.filled:hover { background: rgba(255,255,255,.12); }
button.scanicon.filled.on { background: rgba(255,255,255,.38); }
button.scanicon[hidden] { display: none; }
.scantitle { font-size: 26px; font-weight: 700; flex: 1; }
.scanframe { position: absolute; left: 50%; top: 42%; width: min(500px, 82vw); height: min(320px, 34vh); transform: translate(-50%, -50%); z-index: 1; }
.scanframe .cn { position: absolute; width: 56px; height: 56px; border-color: #fff; border-style: solid; }
.cn.tl { left: 0; top: 0; border-width: 6px 0 0 6px; border-radius: 14px 0 0 0; }
.cn.tr { right: 0; top: 0; border-width: 6px 6px 0 0; border-radius: 0 14px 0 0; }
.cn.bl { left: 0; bottom: 0; border-width: 0 0 6px 6px; border-radius: 0 0 0 14px; }
.cn.br { right: 0; bottom: 0; border-width: 0 6px 6px 0; border-radius: 0 0 14px 0; }
.scanline { position: absolute; left: 18px; right: 18px; top: 0; height: 3px; background: #3DDC97; animation: v2scan 2.4s ease-in-out infinite; }
#scr-scan.paused .scanline { animation-play-state: paused; opacity: 0; }
@keyframes v2scan { 0% { top: 0; } 50% { top: calc(100% - 3px); } 100% { top: 0; } }
.scantext { position: absolute; left: 16px; right: 16px; top: calc(42% + min(160px, 17vh) + 24px); text-align: center; z-index: 1; }
.scanmsg { font-size: 24px; font-weight: 600; }
.scansub { font-size: 18px; color: #B8C2CF; margin-top: 4px; }
.scansheet { position: absolute; left: 16px; right: 16px; bottom: 24px; z-index: 3; background: #fff; color: var(--ink); border-radius: 20px; padding: 18px 20px; display: flex; flex-direction: column; gap: 14px; max-width: 760px; margin: 0 auto; }
.scansheet[hidden] { display: none; }
.sheetrow { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.sheetlbl { font-size: 18px; color: var(--ink2); }
.sheethn { font-size: 34px; font-weight: 700; letter-spacing: 1px; overflow-wrap: anywhere; }
#scan-note:empty { display: none; }
.sheetbtns { display: grid; grid-template-columns: 1fr 1.8fr; gap: 10px; }
button.big2 { min-height: 72px; border-radius: 16px; font-size: 21px; font-weight: 700; }
button.jadebtn.big2 { font-size: 24px; }
#pt-queue:empty { display: none; }
#pt-sync { min-height: 52px; padding: 8px 16px; font-size: 18px; }
.searchbox { display: flex; align-items: center; gap: 12px; height: 68px; background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 10px 16px; }
.searchbox:focus-within { border-color: var(--navy); }
.searchbox input { border: 0; outline: 0; font-size: 24px; flex: 1; min-width: 0; color: var(--ink); background: transparent; }
.ftabs { display: flex; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.ftabs button { font-size: 19px; font-weight: 600; min-height: 56px; padding: 8px 14px 10px; margin-right: 6px; border: 0; border-bottom: 3px solid transparent; border-radius: 0; background: transparent; color: var(--ink2); }
.ftabs button:hover { background: transparent; color: var(--ink); }
.ftabs button.cur { color: var(--ink); border-bottom-color: var(--navy); }
#pt-msg:empty { display: none; }
.ptlist { display: flex; flex-direction: column; gap: 12px; }
.ptday { font-size: 18px; font-weight: 700; color: var(--ink2); margin-top: 4px; }
.ptitem { display: flex; align-items: center; gap: 14px; min-height: 104px; padding: 14px 18px; background: #fff; border-radius: 16px; box-shadow: var(--shadow4); }
.ptmain { flex: 1; min-width: 0; }
.pthn { font-size: 22px; font-weight: 700; overflow-wrap: anywhere; }
.ptmeta, .ptlbl { font-size: 17px; font-weight: 400; color: var(--ink2); }
.ptres { font-size: 24px; font-weight: 600; margin-top: 2px; overflow-wrap: anywhere; }
.ptres .ptsys { font-size: 16px; font-weight: 400; color: var(--ink2); }
.ptside { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; flex: none; }
.ptup { font-size: 16px; font-weight: 600; white-space: nowrap; }
.ptup.acked { color: var(--jade); } .ptup.pending { color: var(--amberText); } .ptup.failed { color: var(--red); } .ptup.other { color: var(--ink2); }
.halo { position: relative; display: inline-flex; }
.halo::before { content: ""; position: absolute; inset: -10px; border-radius: 22px; background: radial-gradient(closest-side, rgba(243,196,106,.9), rgba(243,196,106,0)); animation: v2halo 1.8s ease-in-out infinite; pointer-events: none; }
@keyframes v2halo { 0%, 100% { transform: scale(.9); opacity: .35; } 50% { transform: scale(1.08); opacity: 1; } }
button.chk { position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 8px 18px; border-radius: 26px; border: 0; background: var(--amber); color: var(--ink); font-size: 18px; font-weight: 700; box-shadow: 3px 3px 0 #B87A1E; white-space: nowrap; }
button.chk:hover { background: #F0B952; }
button.chk:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #B87A1E; }
button.done { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 4px; border: 0; background: transparent; color: #0A5744; font-size: 16px; font-weight: 600; white-space: nowrap; }
button.done:hover { background: transparent; text-decoration: underline; }
.ptempty { font-size: 20px; color: var(--ink2); padding: 24px 4px; }
.tools { gap: 12px; }
.tile { display: flex; align-items: center; gap: 18px; width: 100%; min-height: 112px; padding: 16px 20px; background: #fff; border: 0; border-radius: 16px; box-shadow: var(--shadow4); text-align: left; color: var(--ink); font-weight: 400; }
button.tile:hover { background: #fff; box-shadow: var(--shadow8); }
button.tile:active { background: var(--ground); }
button.tile:disabled { background: #fff; color: var(--ink); opacity: .55; }
.tile .ic { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; flex: none; }
.tmain { flex: 1; min-width: 0; }
.t1 { font-size: 24px; font-weight: 700; display: block; }
.t1note { font-size: 18px; color: var(--jade); }
.t1note.bad { color: var(--red); }
.t2 { font-size: 18px; color: var(--ink2); display: block; font-weight: 400; }
.tmeter { display: block; height: 14px; margin: 10px 0 4px; }
.tmeter > span { display: block; height: 100%; width: 0; }
.chev { flex: none; }
#tl-sync { min-height: 60px; font-size: 20px; padding: 10px 20px; flex: none; }
.stlist { display: flex; flex-direction: column; gap: 10px; padding: 0 16px 16px; }
.stlist .grp { margin-top: 8px; }
.stlist .grp:first-child { margin-top: 0; }
.list { background: #fff; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow4); }
button.lrow { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 74px; padding: 12px 20px; border: 0; border-bottom: 1px solid var(--colorNeutralStroke2); border-radius: 0; background: #fff; font-size: 23px; font-weight: 600; color: var(--ink); text-align: left; }
button.lrow:last-child { border-bottom: 0; }
button.lrow:hover { background: var(--ground); }
.lt { flex: 1; min-width: 0; }
.lv { font-size: 18px; font-weight: 400; color: var(--ink2); text-align: right; max-width: 45%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lv.ok { color: var(--jade); } .lv.warn { color: var(--amberText); }
.stfoot { font-size: 16px; color: var(--ink2); margin-top: 6px; }
.st-panehead { display: none; }
button.backbtn { display: inline-flex; align-items: center; gap: 4px; min-height: 56px; padding: 8px 14px 8px 6px; border: 0; background: transparent; color: var(--navy); font-size: 20px; font-weight: 700; }
button.backbtn:hover { background: #E6EDF6; }
#st-panetitle { font-size: 26px; }
#scr-settings .tabpane, #scr-settings .st-saverow { margin-left: 20px; margin-right: 20px; }
#scr-settings .st-saverow { display: none; padding-bottom: 16px; }
#scr-settings.detail .st-listhead, #scr-settings.detail .stlist { display: none; }
#scr-settings.detail .st-panehead { display: flex; }
#scr-settings.detail .st-saverow { display: flex; }
#scr-demo { padding: 0; background: #fff; overflow: hidden; }
#scr-demo #demo-exit { position: absolute; left: 16px; top: 16px; right: auto; min-height: 52px; padding: 0 18px; border-radius: 14px; font-size: 18px; color: #6B7688; z-index: 4; }
.demobox { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: max-content; max-width: 94vw; display: flex; align-items: center; gap: 80px; }
.demobtnwrap { position: relative; width: min(300px, 40vmin); height: min(300px, 40vmin); flex: none; }
.demoring { position: absolute; inset: 0; border-radius: 50%; border: 6px solid var(--jade); animation: v2breathe 2.6s ease-out infinite; pointer-events: none; }
button.demogo { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 0; padding: 0; border-radius: 50%; border: 0; background: var(--jade); color: #fff; font-size: min(92px, 12vmin); font-weight: 700; line-height: 1; box-shadow: 0 10px 0 var(--jadeDark); }
button.demogo:hover { background: var(--jade); }
button.demogo:active { transform: translateY(6px); box-shadow: 0 4px 0 var(--jadeDark); }
button.demogo.p { animation: v2press .35s ease-out both; }
button.demogo:disabled, button.demogo:disabled:hover { background: #8a8886; color: #fff; box-shadow: 0 10px 0 #605e5c; }
.demobtnwrap:has(button:disabled) .demoring { display: none; }
.demoside { display: flex; flex-direction: column; justify-content: center; gap: 14px; max-width: 520px; }
.demotext { font-size: min(58px, 7.5vmin); line-height: 1.25; font-weight: 700; color: var(--ink); }
.demotap { display: flex; align-items: center; gap: 12px; font-size: min(28px, 4.2vmin); color: var(--ink2); }
#demo-why:empty { display: none; }
.demowipe { position: absolute; width: 100px; height: 100px; border-radius: 50%; background: var(--jade); transform: scale(0); pointer-events: none; z-index: 2; }
.demowipe.run { animation: v2wipe .7s .2s cubic-bezier(.6,0,.3,1) both; }
.demostarting { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; color: #fff; animation: v2fade .4s .75s ease-out both; }
.demostarting[hidden] { display: none; }
.ds1 { font-size: 64px; line-height: 1.2; font-weight: 700; }
.ds2 { font-size: 30px; }
@keyframes v2breathe { 0% { transform: scale(1); opacity: .45; } 70% { transform: scale(1.32); opacity: 0; } 100% { transform: scale(1.32); opacity: 0; } }
@keyframes v2press { 0% { transform: scale(1); } 35% { transform: scale(.9); } 100% { transform: scale(1); } }
@keyframes v2wipe { 0% { transform: scale(1); } 100% { transform: scale(34); } }
@keyframes v2fade { 0% { opacity: 0; transform: translateY(12px); } 100% { opacity: 1; transform: translateY(0); } }
@media (orientation: portrait) { .demobox { flex-direction: column; gap: 56px; text-align: center; } .demobtnwrap { width: min(300px, 60vw); height: min(300px, 60vw); } button.demogo { font-size: min(92px, 18vw); } .demotext { font-size: min(58px, 8vw); } .demotap { justify-content: center; font-size: 26px; } }
@media (prefers-reduced-motion: reduce) { .demoring, .halo::before, .scanline { animation: none; } }
.screen.plum { padding: 0; background: #F3F0F8; color: #1E1430; }
.screen.plum.active { display: flex; flex-direction: column; }
.plum .rechead { flex: none; background: var(--plum); color: #fff; padding: 0 12px 0 20px; min-height: 84px; display: flex; align-items: center; gap: 14px; }
.rectitle { font-size: 26px; font-weight: 700; flex: 1; }
button.recend { min-height: 56px; padding: 10px 18px; border-radius: 14px; border: 2px solid rgba(255,255,255,.55); background: transparent; color: #fff; font-size: 19px; font-weight: 700; }
button.recend:hover { background: rgba(255,255,255,.12); }
.recprog { flex: none; padding: 16px 20px 0; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
#rec-progress { font-size: 20px; font-weight: 700; }
.recbar { flex: 1; min-width: 160px; height: 12px; background: #E2DAEE; border-radius: 6px; overflow: hidden; }
.recbar > div { height: 100%; width: 0; background: var(--plum); transition: width .3s; }
.reccard { flex: 1; min-height: 0; margin: 16px 20px 0; background: #fff; border-radius: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; box-shadow: 0 1px 2px rgba(30,20,48,.06), 0 4px 16px rgba(30,20,48,.06); overflow: hidden; }
.recask { font-size: 24px; color: #5E5470; }
.plum .recdigit { font-size: min(36vh, 300px); margin: 0; }
.recstate { font-size: 24px; font-weight: 700; color: var(--plum); text-align: center; padding: 0 16px; }
.plum .recmeter { flex: none; max-width: none; height: 22px; margin: 16px 20px 0; background: #E2DAEE; border-radius: 11px; }
.plum .recmeter > div { background: var(--plum); }
.recbtns { flex: none; padding: 14px 20px 22px; display: flex; flex-direction: column; gap: 10px; }
button.recaccept { min-height: 92px; font-size: 32px; border-radius: 18px; width: 100%; }
.rec2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
button.plumside { min-height: 72px; padding: 12px 20px; border-radius: 16px; border: 2px solid #D6CCE6; background: #fff; color: #1E1430; font-size: 22px; font-weight: 700; }
button.plumside:hover { background: #F3F0F8; }
.recdonebody { padding: 20px; overflow-y: auto; }
.recdonebody .stat b { color: var(--plum); }
@media (orientation: landscape) { button.recaccept { min-height: 76px; } button.plumside { min-height: 60px; } .recbtns { padding: 10px 20px 14px; } }
#testbar { padding: 0 10px 20px; gap: 10px; color: #6B7688; font-size: 15px; }
#testbar button { min-height: 32px; min-width: 64px; padding: 0 14px; font-size: 15px; font-weight: 600; color: #8A93A3; border: 1.5px solid #E3E7EC; border-radius: 10px; }
#state { flex: none; }
#state.listening { border-color: var(--jade); background: var(--jade); }
#statetext { min-width: 4.5em; color: #6B7688; }
#tinfo { color: #9AA3B2; }
.tprog { position: absolute; left: 0; right: 0; bottom: 0; height: 20px; background: #E6EAEF; overflow: hidden; }
.tprog > div { height: 20px; width: 0; background: var(--navy); border-radius: 0 10px 10px 0; transition: width .9s cubic-bezier(.3,0,.2,1); }
#opt.fadein { animation: v2in .16s linear both; }
@keyframes v2in { from { opacity: 0; } to { opacity: 1; } }
.readycue { position: absolute; left: 0; right: 0; top: 0; bottom: 56px; z-index: 6; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 36px; text-align: center; padding: 0 24px; color: var(--ink); animation: v2rise .5s ease-out both; }
.readycue[hidden] { display: none; }
.readycue .rq1 { font-size: min(76px, 10vw); line-height: 1.2; font-weight: 700; }
.readycue .rq2 { font-size: min(40px, 5.4vw); line-height: 1.3; color: var(--ink2); }
.rqdots { display: flex; gap: 28px; }
.rqdots span { width: 36px; height: 36px; border-radius: 50%; background: #D3D9E2; }
.readycue.run .rqdots span { animation: v2dot .9s ease-out both; }
.readycue.run .rqdots span:nth-child(1) { animation-delay: .3s; }
.readycue.run .rqdots span:nth-child(2) { animation-delay: 1.1s; }
.readycue.run .rqdots span:nth-child(3) { animation-delay: 1.9s; }
.endcue { gap: 20px; }
@keyframes v2dot { 0%, 20% { background: #D3D9E2; transform: scale(1); } 35% { background: var(--ink); transform: scale(1.25); } 50%, 100% { background: var(--ink); transform: scale(1); } }
@keyframes v2rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #opt.fadein, .readycue, .readycue.run .rqdots span { animation: none; } .readycue.run .rqdots span { background: var(--ink); } .tprog > div { transition: none; } }
#scr-switch { padding: 0; background: #fff; color: var(--ink); }
.swbody { position: absolute; left: 0; right: 0; top: 0; bottom: 130px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; text-align: center; padding: 0 24px; }
.swdone { font-size: 32px; line-height: 1.3; font-weight: 600; color: var(--ink2); }
.sweyes { display: flex; gap: 72px; align-items: center; }
.sweye { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.sweye svg { display: block; width: 230px; height: 200px; }
.sweye .sw-cover, .sweye.covered .sw-open { display: none; }
.sweye.covered .sw-cover { display: block; }
.swlbl { font-size: 34px; line-height: 1.3; font-weight: 700; }
.swtext { font-size: 68px; line-height: 1.2; font-weight: 700; }
button.swgo { position: absolute; right: 24px; bottom: 40px; min-height: 84px; padding: 0 40px; border-radius: 16px; border: 0; background: var(--jade); color: #fff; font-size: 30px; font-weight: 700; }
button.swgo:hover { background: #085A45; }
@media (orientation: portrait) {
.swbody { bottom: 150px; gap: 24px; }
.sweyes { gap: 32px; }
.sweye svg { width: min(230px, 38vw); height: auto; }
.swtext { font-size: min(68px, 8.4vw); }
button.swgo { left: 24px; right: 24px; bottom: 44px; }
}
#scr-report { padding: 0; background: var(--ground); overflow: hidden; }
#scr-report.active { display: flex; flex-direction: column; }
.rephead { flex: none; background: var(--navy); color: #fff; padding: 22px 24px 26px; border-radius: 0 0 28px 28px; }
.rh1 { display: flex; align-items: center; gap: 12px; }
.rh1 h1 { flex: 1; margin: 0; font-size: 34px; line-height: 1.25; font-weight: 700; }
.rh1 .research { color: #C9D6E8; }
.rh2 { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 18px; margin-top: 16px; font-size: 19px; line-height: 1.4; }
.repgrid { flex: 1; min-height: 0; overflow-y: auto; padding: 18px 16px 16px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.repleft, .repeyes { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.eyecard { background: #fff; border-radius: 20px; padding: 18px 24px 20px 28px; box-shadow: var(--shadow4); min-width: 0; }
.eyehd { font-size: 22px; line-height: 1.4; font-weight: 700; color: var(--ink2); }
.eyeva { font-size: 72px; line-height: 1.05; font-weight: 700; letter-spacing: -1px; white-space: nowrap; }
.eyeva.long { font-size: 52px; }
.eyeva .suf { font-size: 40px; color: var(--ink2); letter-spacing: 0; }
.eyeva small { font-size: 26px; color: var(--ink2); letter-spacing: 0; }
.eyeva.none { color: var(--ink2); }
.eyesub { font-size: 17px; color: var(--ink2); }
.mcs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 12px; }
.mc { background: var(--ground); border-radius: 10px; padding: 8px 4px 7px; display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 0; }
.mc span { font-size: 14px; line-height: 1.3; color: var(--ink2); white-space: nowrap; }
.mc b { font-size: 21px; line-height: 1.1; white-space: nowrap; }
.graphwrap { margin-top: 12px; }
.graphlbl { font-size: 15px; line-height: 1.4; color: var(--ink2); margin-bottom: 2px; }
.repgraph { display: block; }
.repnote { display: flex; gap: 10px; align-items: flex-start; background: #FFF3D6; border-radius: 14px; padding: 12px 14px; font-size: 17px; line-height: 1.4; color: var(--amberText); }
.repnote svg { flex: none; margin-top: 2px; }
.repnote.done { background: #E2F1EB; color: var(--jadeDark); }
.repright { display: flex; flex-direction: column; align-items: center; gap: 10px; min-width: 0; }
.replbl { font-size: 17px; line-height: 1.4; font-weight: 700; color: var(--ink2); align-self: flex-start; }
.printer { position: relative; z-index: 2; flex: none; width: 100%; height: 34px; border-radius: 10px 10px 6px 6px; background: #26303D; box-shadow: 0 3px 0 #11171F; }
.printer .led { position: absolute; left: 12px; top: 7px; width: 8px; height: 8px; border-radius: 50%; background: #6B7688; }
.printer .led.busy { background: #3DDC97; }
.printer .slot { position: absolute; left: 12px; right: 12px; bottom: 6px; height: 5px; border-radius: 3px; background: #0B0F14; }
.paperwin { position: relative; z-index: 1; margin-top: -18px; width: 96%; overflow: hidden; display: flex; justify-content: center; align-items: flex-start; padding-bottom: 16px; }
.repbar { flex: none; display: flex; justify-content: center; gap: 12px; padding: 14px 16px 18px; }
button.repnext { width: 70%; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 84px; border: 0; border-radius: 16px; font-size: 26px; }
#rep-back { min-height: 84px; min-width: 120px; font-size: 22px; }
#rep-back[hidden] { display: none; }
@media (orientation: landscape) {
.rephead { padding: 14px 24px 16px; border-radius: 0 0 22px 22px; }
.rh1 h1 { font-size: 30px; }
.rh2 { margin-top: 6px; }
.repgrid { padding-top: 14px; }
.repeyes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.eyecard { padding: 14px 16px 16px 20px; }
.eyeva { font-size: 60px; }
.eyeva.long { font-size: 40px; }
.eyeva .suf { font-size: 34px; }
.mc b { font-size: 19px; }
.paperwin .pp { zoom: .7; }
.repbar { padding: 10px 16px 12px; }
button.repnext, #rep-back { min-height: 72px; }
}
.pp { position: relative; zoom: .92; width: 340px; flex: none; background: #fff; color: #000; padding: 44px 22px 36px; box-shadow: 0 2px 6px rgba(0,0,0,.12); text-align: center; font-size: 17px; line-height: 1.35; }
.pp.feed { animation: v2feed 3.2s cubic-bezier(.25,.1,.25,1) both; }
@keyframes v2feed { 0%, 8% { transform: translateY(-102%); } 84% { transform: translateY(1.6%); } 91% { transform: translateY(-.8%); } 96% { transform: translateY(.3%); } 100% { transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { .pp.feed { animation: none; } }
.rc-brand { font-size: 1.65em; font-weight: 700; letter-spacing: .06em; line-height: 1.3; }
.rc-title { font-size: 1.06em; font-weight: 600; }
.rc-ds { border-top: 2px dashed #000; margin: .6em 0; }
.rc-kv { display: flex; justify-content: space-between; gap: .5em; text-align: left; }
.rc-kv span:last-child { text-align: right; }
.rc-eye { font-size: 1.12em; font-weight: 700; }
.rc-big { font-size: 2.35em; font-weight: 700; line-height: 1.1; }
.rc-box { font-weight: 700; border: 2px solid #000; padding: .6em .8em; }
.rc-copy { margin-top: .5em; font-size: .88em; }
.rc-torn { position: absolute; left: 0; bottom: -13px; width: 100%; height: 14px; display: block; }
#printroot { display: none; }
@media print {
@page { size: 58mm auto; margin: 0; }
html, body { height: auto; overflow: visible; background: #fff; }
body > *:not(#printroot) { display: none !important; }
#printroot { display: block; }
#printroot .pp { zoom: 1; width: 58mm; box-shadow: none; padding: 5mm 3mm 7mm; font-size: 9pt; line-height: 1.35; }
#printroot .rc-ds { border-top-width: 1.5px; }
}
#scr-check { padding: 0; background: #5B6675; overflow: hidden; font-size: 20px; line-height: 1.4; color: #0E1B2C; }
#scr-check.active { display: block; }
#scr-check button { min-height: 0; font-family: inherit; transition: none; }
.ckpeek { position: absolute; left: 24px; right: 24px; top: 14px; height: 60px; border-radius: 16px 16px 0 0; background: #8791A0; }
.cksheet { position: absolute; left: 0; right: 0; top: 36px; bottom: 0; background: #F4F6F8; border-radius: 28px 28px 0 0; display: flex; flex-direction: column; overflow: hidden; }
.cksheet.up { animation: ckup .38s cubic-bezier(.22,.61,.36,1) both; }
@keyframes ckup { from { transform: translateY(100%); } to { transform: translateY(0); } }
.ckscroll { flex: 1; min-height: 0; overflow-y: auto; padding: 10px 16px 10px; display: flex; flex-direction: column; gap: 10px; }
.ckgrab { align-self: center; flex: none; width: 56px; height: 6px; border-radius: 3px; background: #C9D1DB; }
.ckhead { display: flex; align-items: baseline; gap: 12px; }
.cktitle { font-size: 30px; font-weight: 700; flex: 1; line-height: 1.4; }
.ckmeta { font-size: 17px; color: #46536A; }
.ckmain { display: flex; flex-direction: column; gap: 10px; }
.ckleft, .ckright { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ckcols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; align-items: start; }
.ckcol { background: #fff; border-radius: 16px; padding: 12px 12px 10px; display: flex; flex-direction: column; min-width: 0; }
.ckcolhd { display: flex; align-items: baseline; gap: 8px; padding: 0 4px 6px; }
.ckcolhd .sp { flex: 1; }
.ckeye { font-size: 20px; }
.ckreslbl2 { font-size: 15px; color: #46536A; }
.ckva { font-size: 30px; line-height: 1.1; color: #123B6D; white-space: nowrap; }
.ckcolsub { font-size: 14px; color: #46536A; padding: 0 4px 4px; }
.ckrow { display: grid; grid-template-columns: 52px minmax(0, 1fr); align-items: center; gap: 6px; min-height: 54px; padding: 4px 4px; border-top: 1px solid #EDF0F4; border-radius: 8px; background: transparent; }
.ckrow.res { background: #EEF2F8; }
.cksn { font-size: 15px; font-weight: 400; white-space: nowrap; }
.ckrow.res .cksn { font-weight: 700; }
.ckdots { display: flex; flex-wrap: wrap; gap: 8px 4px; align-items: center; min-width: 0; }
.ckdot { position: relative; display: inline-flex; flex: 0 0 40px; width: 40px; height: 40px; }
.ckhalo { position: absolute; left: -9px; top: -9px; width: 58px; height: 58px; border-radius: 50%; background: radial-gradient(circle, rgba(243,196,106,.95) 0%, rgba(243,196,106,.45) 45%, rgba(243,196,106,0) 70%); animation: ckhalo 1.8s ease-in-out infinite; pointer-events: none; }
@keyframes ckhalo { 0%, 100% { transform: scale(.82); opacity: .35; } 50% { transform: scale(1.12); opacity: 1; } }
#scr-check button.cb { position: relative; z-index: 1; width: 40px; height: 40px; min-width: 40px; min-height: 40px; max-width: 40px; max-height: 40px; aspect-ratio: 1/1; flex: 0 0 40px; box-sizing: border-box; padding: 0 0 2px; border-radius: 50%; border: 0; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 700; line-height: 1; }
.cb .tk { position: absolute; right: -3px; top: -3px; background: #0A6B52; border-radius: 50%; padding: 1px; }
.cklegend { display: flex; gap: 8px 18px; flex-wrap: wrap; font-size: 17px; color: #46536A; align-items: center; margin-top: -2px; }
.cklegend span { display: inline-flex; align-items: center; gap: 7px; }
.cklegend i { width: 20px; height: 20px; border-radius: 50%; }
.cklegend i.row { width: 22px; height: 18px; border-radius: 3px; background: #EEF2F8; border: 1px solid #9FB4D1; }
.ckdetail { background: #fff; border-radius: 18px; border: 2px solid #E3E7EC; padding: 14px 18px 16px; display: flex; flex-direction: column; gap: 12px; }
.ckdetail[hidden] { display: none; }
.ckinfo { display: grid; grid-template-columns: auto auto auto auto minmax(0, 1fr) auto; align-items: center; column-gap: 14px; }
.ckwho { display: flex; flex-direction: column; gap: 2px; white-space: nowrap; font-size: 20px; font-weight: 700; }
.ckwe { color: #46536A; }
.ckws { color: #123B6D; }
.ckshown, .ckrec { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.ckshown > span, .ckrec > span:last-child { font-size: 15px; color: #46536A; }
.ckshown img { width: 44px; height: 44px; margin: 10px 0; display: block; }
.ckshown > span.ckshownf { width: 44px; height: 44px; margin: 10px 0; font: 800 44px/44px SarabunOpt, Sarabun, sans-serif; text-align: center; color: #000; }
.ckrec .num { flex: none; width: 64px; height: 64px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding: 0 0 2px; font-size: 34px; font-weight: 700; line-height: 1; color: #fff; }
.ckheard { min-width: 0; display: flex; flex-direction: column; gap: 2px; padding-left: 4px; }
.ckword { font-size: 30px; line-height: 1.2; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ckconf { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ckconft { font-size: 17px; color: #46536A; white-space: nowrap; }
.ckconft b { font-size: 22px; }
.ckbar { position: relative; flex: 1; min-width: 40px; height: 10px; border-radius: 5px; background: #EDF0F4; overflow: hidden; }
.ckbarfill { display: block; height: 10px; border-radius: 5px; transform-origin: left center; animation-duration: .6s; animation-timing-function: cubic-bezier(.22,.61,.36,1); animation-fill-mode: both; }
.ckbartick { position: absolute; left: 95%; top: 0; width: 2px; height: 10px; background: #46536A; }
@keyframes ckwipeA { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes ckwipeB { from { transform: scaleX(0); } to { transform: scaleX(1); } }
#scr-check button.ckplay { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0; border: 0; background: transparent; }
.ckplayc { width: 76px; height: 76px; border-radius: 50%; background: #EEF2F8; border: 2px solid #9FB4D1; display: flex; align-items: center; justify-content: center; }
#scr-check button.ckplay:disabled { background: transparent; opacity: .5; }
.ckpt { font-size: 15px; font-weight: 600; }
.ckkeys { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)) 1.5fr 1.7fr; gap: 6px; }
#scr-check button.key { font-size: 26px; font-weight: 700; height: 58px; padding: 0 6px; border-radius: 12px; border: 2px solid #D3D9E2; background: #fff; color: #0E1B2C; }
#scr-check button.key.word { font-size: 17px; }
#scr-check button.key.on { background: #123B6D; border-color: #123B6D; color: #fff; }
#scr-check button.cknext { min-height: 56px; padding: 8px 16px; border-radius: 14px; border: 2px solid #D9962B; background: #FFF4DE; color: #7A4A00; font-size: 20px; font-weight: 700; }
.ckfoot { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ckres { background: #fff; border-radius: 14px; padding: 10px 16px; min-width: 0; }
.ckreslbl { font-size: 15px; color: #46536A; }
.ckresv { display: flex; justify-content: space-between; gap: 8px; font-size: 30px; line-height: 1.15; font-weight: 700; white-space: nowrap; }
.ckside { font-size: 17px; font-weight: 400; color: #46536A; }
.ckfb { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; align-content: end; }
#scr-check button.ckopt { font-size: 20px; min-height: 56px; padding: 8px 12px; border-radius: 14px; border: 2px solid #D3D9E2; background: #fff; color: #0E1B2C; font-weight: 400; }
#scr-check button.ckopt.on { background: #123B6D; border-color: #123B6D; color: #fff; font-weight: 600; }
#scr-check button.ckmore { align-self: flex-start; padding: 2px 2px; border: 0; background: transparent; color: #123B6D; font-size: 17px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.ckextra { background: #fff; border-radius: 14px; padding: 12px 16px; display: grid; gap: 10px; }
.ckextra[hidden] { display: none; }
.ckconv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ckbtm { flex: none; padding: 12px 16px 18px; background: #F4F6F8; display: grid; grid-template-columns: 1fr 2.2fr; gap: 10px; }
#scr-check button.ckback { display: flex; align-items: center; justify-content: center; min-height: 84px; border-radius: 16px; border: 2px solid #D3D9E2; background: #fff; color: #0E1B2C; font-size: 22px; font-weight: 700; }
#scr-check button.cksave { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 84px; border-radius: 16px; border: 0; background: #0A6B52; color: #fff; font-size: 26px; font-weight: 700; line-height: 1.2; }
#scr-check button.cksave:disabled { background: #C9D1DB; color: #46536A; cursor: default; }
#ck-savesub { font-size: 16px; font-weight: 600; }
@media (orientation: landscape) and (min-width: 1000px) {
.ckmain { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.ckbtm { padding: 10px 16px 14px; }
#scr-check button.ckback, #scr-check button.cksave { min-height: 76px; }
}
@media (prefers-reduced-motion: reduce) { .ckhalo, .cksheet.up { animation: none; } }
#brandfoot { position: fixed; right: 12px; bottom: 6px; z-index: 50; font-size: 13px; line-height: 1.2; color: #6B7688; pointer-events: none; white-space: nowrap; max-width: calc(100vw - 24px); overflow: hidden; text-overflow: ellipsis; }
body[data-screen="register"] #brandfoot, body[data-screen="patients"] #brandfoot, body[data-screen="tools"] #brandfoot, body[data-screen="settings"] #brandfoot, body[data-screen="pin"] #brandfoot { bottom: 90px; }
body[data-screen="test"] #brandfoot, body[data-screen="scan"] #brandfoot { display: none; }
@media print { #brandfoot { display: none; } }
