/* The training desk uses the available window, instead of fixed page heights. */
body[data-screen]{height:100svh;display:flex;flex-direction:column;overflow:hidden}
.site-header{flex:none;width:100%;padding:14px 32px;min-height:64px}
.site-header nav{gap:4px}.site-header .brand{font-size:18px;line-height:1.1}.brand small{font-size:9px}
.site-footer{flex:none;width:100%;padding:9px 32px;font-size:11px;line-height:1.4}
body[data-screen] #app{width:100%;flex:1;min-height:0;padding:18px 32px;overflow:visible}
body[data-screen=history] #app{overflow-y:auto}
.home-layout{height:100%;min-height:0;grid-template-columns:minmax(0,1fr) 350px;grid-template-rows:minmax(0,1fr) auto;gap:18px 44px}
.intro{grid-area:1/1;display:flex;flex-direction:column;min-height:0;padding:0}
.intro h1{font-size:30px;margin-bottom:10px}.intro>p{line-height:1.6;margin-bottom:18px;font-size:13px}
.home-table{flex:1;min-height:130px;margin:0}
.home-layout>.rules-strip{grid-area:2/1;flex:none;margin:0;padding-bottom:0;border-bottom:0}
.configuration{grid-area:1/2;display:flex;flex-direction:column;min-height:0;padding:0}
.configuration-controls{flex:none;min-width:0;margin-block:auto}
.home-branding{flex:none;min-width:0;padding-top:18px}
.configuration .mode-switch{margin-bottom:18px}.mode-switch button{min-height:40px}
.configuration .standard-note{display:none}.configuration-controls>.field-grid{gap:14px}
.preferences-toggle{display:flex;width:100%;align-items:center;justify-content:space-between;margin-top:18px;background:none;font-size:13px;padding:11px 12px;text-align:left}
.preferences-toggle span{font-size:11px;color:var(--muted);font-weight:400}
.configuration .start-button{margin-top:18px;min-height:46px}.configuration .start-hint{margin:10px 0 0}
.configuration .copyright{margin:0;text-align:center;color:#8fa9c7;font-size:14px;line-height:1.6;white-space:nowrap}
.configuration .contact-info{margin:4px 0 0;text-align:center;color:#8fa9c7;font-size:12px;line-height:1.6;white-space:normal}
.contact-info span{display:inline-block;white-space:nowrap}
.configuration .site-url{display:flex;justify-content:center;margin:4px 0 0;font-size:14px;line-height:1.6}
.site-url a{display:inline-flex;align-items:center;justify-content:center;min-height:24px;padding:0 8px;color:#8fa9c7;border-radius:4px;text-decoration:underline;text-underline-offset:3px}
.site-url a:hover{color:var(--paper)}
.site-header .brand img{width:40px;height:40px;flex:none}
.form-error:empty{display:none}
body[data-screen=memory] #app{display:grid;grid-template-rows:auto minmax(0,1fr) auto auto auto;gap:12px}
body[data-screen=prep] #app,body[data-screen=reflection] #app{display:flex;flex-direction:column;gap:12px}
.session-top{position:static;flex:none;padding:0;margin:0;min-height:44px;gap:14px}
.session-top .timer{font-size:28px}.session-label{min-width:0}.phase-tag{white-space:nowrap}
.memory-table{min-height:0;padding:22px;overflow:hidden}
.group-heading{margin-bottom:16px;flex:none}
.memory-hand{display:block!important;position:relative;width:calc(var(--memory-card-width,150px) + (var(--memory-count,2) - 1) * var(--memory-step,48px));height:calc(var(--memory-card-width,150px) * 170 / 120);max-width:none;flex:none;gap:0}
.memory-hand .memory-card{position:absolute;left:calc(var(--card-position) * var(--memory-step));top:0;width:var(--memory-card-width)!important;margin:0!important;filter:drop-shadow(0 6px 7px #08152440)}
.memory-card .card-number{bottom:-21px;font-size:12px}
.memory-controls{margin:0;min-height:44px}.memory-controls .group-status{font-size:12px}
.group-navigation{margin:0;padding:4px 2px 7px;min-height:0;align-items:center;overflow-y:hidden}
.group-preview{min-height:72px;padding:5px 6px 6px}.group-preview span{margin-top:4px}
.keyboard-hint{margin:0;font-size:11px;line-height:1.5}
.prep-table{flex:1;min-height:0}.prep-count{font-size:clamp(52px,14svh,100px)}
body[data-screen=recall] #app,body[data-screen=result] #app{display:flex;flex-direction:column;gap:10px}
.recall-table{flex:1;min-height:0;display:flex;flex-direction:column;gap:10px;padding:16px 18px;overflow:visible}
.answer-heading{flex:none;min-height:32px;margin:0;gap:12px}.answer-heading .direction-button{min-height:32px}
.desktop-answers{flex:1;min-height:0;gap:14px}
.answer-row{flex:1;min-height:0;padding:0;isolation:isolate}
.answer-row .answer-item{height:100%;min-height:0}
.answer-row .answer-item:last-child{flex:0 0 var(--answer-card-width,108px)}
.answer-row .answer-slot{top:22px;bottom:0;height:calc(100% - 22px);width:100%}
.answer-row .answer-slot .card-svg{width:auto;height:100%;max-width:none}
.answer-row.short{align-items:center;gap:8px}
.answer-row.short .answer-item{flex:0 0 var(--answer-card-width,108px);height:var(--short-answer-height,240px)}
.answer-slot.active,.mobile-slot.active{background:#b9dcf8;border-color:#b9dcf8;box-shadow:inset 0 0 0 2px #87c6f8}
.answer-slot.active .slot-placeholder,.mobile-slot.active .slot-placeholder{color:#244c70}
.answer-item:has(.active) .slot-number{color:#c8e7ff}
.answer-slot.filled.active{background:var(--paper)}
.answer-slot.receiving,.mobile-slot.receiving{background:#233d5c}
.receiving .card-svg{visibility:hidden}
.edit-toolbar{flex:none;margin:0;gap:7px;min-height:44px}.edit-toolbar button{padding:10px 12px}
.edit-toolbar .toolbar-note{font-size:11px}.pool-heading{flex:none;margin:0;min-height:18px}
.candidate-pool{--pool-height:clamp(58px,12svh,112px);--pool-width:calc(var(--pool-height) * 120 / 170);flex:none;height:var(--pool-height);isolation:isolate;margin-top:20px}
.candidate-pool .suit-row{overflow:visible;isolation:isolate}
.candidate-pool>.suit-row:last-child{flex:0 0 calc((100% - var(--pool-width)) / 51 * 12 + var(--pool-width))}
.candidate-pool .pool-card{position:relative;overflow:visible;height:var(--pool-height);border:0;border-radius:0;background:none;color:#152238;opacity:1;z-index:auto}
.candidate-pool>.suit-row:last-child>.pool-card:last-child{flex:0 0 var(--pool-width)}
.pool-card:after{display:none}
.pool-visual{display:block;position:absolute;left:0;bottom:0;width:var(--pool-width);height:var(--pool-height);background:var(--paper);border:1px solid #d5e0ec;border-radius:5px;pointer-events:none;overflow:hidden;transition:transform .12s ease-out;transform:translateY(0)}
.pool-visual .card-svg{position:absolute;inset:0;display:block;width:100%;height:100%;clip-path:none}
.pool-visual .pool-head{display:flex;position:absolute;left:0;top:0;min-width:20px;padding:5px 2px;background:var(--paper);gap:2px;font-family:Georgia,serif;font-weight:bold;line-height:1;color:#152238}
.pool-visual .pool-head b{font-size:17px}.pool-visual .pool-head span{font-size:15px}
.pool-card[data-card$="10"] .pool-head b{font-size:15px}
.pool-card.red .pool-head{color:var(--red)}
.pool-card.used .pool-visual{background:#243b55;border-color:#3d5572}
.pool-card.used .pool-head{background:#243b55;color:#708aa8}.pool-card.used.red .pool-head{color:#a47985}
.pool-card.used .card-svg{opacity:.13}
.pool-card.used .pool-visual:after{content:'';position:absolute;top:55%;left:3px;width:17px;height:1px;background:#6c85a0;transform:rotate(-35deg)}
@media(hover:hover) and (pointer:fine){.pool-card:not(:disabled):hover .pool-visual{transform:translateY(-26px)}.pool-card:not(:disabled):focus-visible .pool-visual{transform:translateY(-26px)}}
.pool-card:focus-visible{outline-offset:0;z-index:auto}
.recall-footer{flex:none;margin:0;font-size:11px;line-height:1.5}
.flying-card{position:fixed;z-index:150;pointer-events:none;transform-origin:top left;filter:drop-shadow(0 7px 9px #04101a50)}
.flying-card .card-svg{width:100%;height:100%}
.result-score{font-size:28px;color:var(--blue);font-variant-numeric:tabular-nums;white-space:nowrap}
.result-score small{font-size:12px;color:var(--muted)}.result-time{font-size:23px;white-space:nowrap;font-variant-numeric:tabular-nums}
.result-time small{font-size:11px;color:var(--muted)}.result-accuracy{font-size:12px;color:var(--muted);white-space:nowrap}
.result-legend{display:flex;align-items:center;gap:18px;font-size:12px}
.correct-key{color:#8ee5b6}.wrong-key{color:#ffaeb8}
.result-original{position:absolute;top:0;left:2px;display:flex;align-items:baseline;height:26px;line-height:25px;font-family:Georgia,serif;color:#e5effb;white-space:nowrap;font-size:19px}
.result-original.red{color:#ffaab5}.result-original small{color:#91a8c4;font-family:system-ui,sans-serif;font-size:9px}
.result-original b{font-weight:500}
.answer-slot.result-slot.correct,.mobile-slot.result-slot.correct{background:#183f36;border:2px solid #60d99d}
.answer-slot.result-slot.wrong,.mobile-slot.result-slot.wrong{background:#543545;border:2px solid #ee7b8b}
.result-slot.correct .card-svg>rect:first-child{fill:#e4f7ec;stroke:#60d99d}
.result-slot.wrong .card-svg>rect:first-child{fill:#ffdce2;stroke:#ee7b8b}
.result-slot .result-mark{position:absolute;bottom:6px;left:4px;font-size:13px;color:#a3ebc4;background:#124736;min-width:14px;line-height:18px;border-radius:2px;pointer-events:none}
.result-slot.wrong .result-mark{background:#8f3344;color:#ffe4e9}
.result-slot.blank .slot-placeholder{color:#e5a6b3}.result-slot{cursor:default}
.answer-slot.result-slot.blank,.mobile-slot.result-slot.blank{background:#233b56;border-color:#4a6280}
.result-slot.blank .slot-placeholder{color:#8ca2bd}.result-slot.blank .result-mark{background:none;color:#bc8997}
.result-caption{flex:none;font-size:12px;color:var(--muted);line-height:1.6;margin:7px 0 0}
.result-actions{flex:none;margin:0;gap:10px;min-height:44px}
.result-detail{display:grid;grid-template-columns:1fr 1fr;gap:20px;max-width:340px;margin:auto}
.result-detail p{text-align:center;font-size:12px;color:var(--muted);margin:10px 0 0}.result-detail .review-empty{font-size:14px}
@media(max-width:1100px){.home-layout{grid-template-columns:minmax(0,1fr) 310px;gap:28px}.intro h1{font-size:27px}.timer-area{gap:16px}.result-top .result-accuracy{display:none}}
@media(max-height:680px) and (min-width:801px){.site-header{padding:10px 28px;min-height:54px}.site-footer{display:none}body[data-screen] #app{padding:12px 24px}.intro h1{font-size:26px}.home-table{min-height:110px}.sample-hand{height:190px}.sample-card{width:110px}.configuration .mode-switch{margin-bottom:12px}.preferences-toggle{margin-top:12px}.configuration .start-button{margin-top:12px}.keyboard-hint{display:none}.recall-table{padding:12px 14px;gap:8px}.desktop-answers{gap:10px}.pool-visual .pool-head b{font-size:15px}.pool-visual .pool-head span{font-size:13px}}
@media(max-width:800px){
  .site-header{min-height:54px;padding:10px 18px}.site-footer{padding:6px 18px;font-size:10px;flex-direction:row}.site-footer>span:first-child{display:none}
  body[data-screen] #app{padding:12px 18px}.home-layout{display:grid;grid-template-columns:1fr;grid-template-rows:minmax(90px,1fr) auto;gap:18px}
  .intro{display:flex}.intro h1{font-size:24px;margin-bottom:12px}.intro>p,.home-layout>.rules-strip{display:none}
  .home-table{min-height:70px;border-radius:10px}.home-table:before{inset:9px;border-radius:6px}
  .sample-hand{width:calc(var(--sample-card-width,92px) * 2.5);height:calc(var(--sample-card-width,92px) * 1.65);margin:0;flex:none}.sample-card{width:var(--sample-card-width,92px);left:calc(var(--sample-card-width,92px) * .75)}
  .table-caption{display:none}.intro{--sample-card-width:clamp(56px,calc((100svh - 540px) * .8),104px)}
  .configuration{grid-area:2/1;display:block;height:auto}.configuration-controls{margin:0}.configuration .mode-switch{margin-bottom:13px}.configuration-controls>.field-grid{grid-template-columns:1fr 1fr;gap:12px}.configuration-controls>.field-grid .wide{grid-column:1/-1}
  .field label{font-size:12px}.field-hint{font-size:10px}.preferences-toggle{margin-top:12px;padding:10px 12px;min-height:44px}.configuration .start-button{margin-top:12px;font-size:15px}.configuration .start-hint{font-size:10px;margin-top:8px}
  .session-top{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:7px;min-height:0}.session-actions{margin:0}.session-label{gap:8px}.session-label .muted{font-size:11px}
  .timer-area{grid-column:1/-1;order:3;display:flex;justify-content:space-between;width:100%;gap:10px;padding:0;border:0;min-height:30px}
  .session-top .timer{font-size:25px}.timer-block .timer-label{font-size:11px}.session-actions .primary{font-size:12px;padding:11px 13px}.session-actions .text-button{font-size:11px;padding:10px 8px}
  body[data-screen=memory] .site-footer,body[data-screen=recall] .site-footer,body[data-screen=prep] .site-footer,body[data-screen=reflection] .site-footer,body[data-screen=result] .site-footer{display:none}
  body[data-screen=memory] #app{gap:8px;grid-template-rows:auto minmax(0,1fr) auto auto}.memory-table{padding:16px 12px 28px}.group-heading{font-size:11px;margin-bottom:12px}.memory-card .card-number{font-size:11px}
  .memory-controls button{font-size:12px;padding:10px 13px}.memory-controls .group-status{font-size:11px}.group-preview{min-height:64px}.mini-hand .card-svg{width:29px}.group-navigation{padding-bottom:3px}
  .keyboard-hint{display:none}body[data-screen=recall] #app,body[data-screen=result] #app{gap:8px}
  .recall-table{padding:10px;gap:6px;border-radius:9px}.answer-heading{min-height:44px;gap:7px;font-size:11px}
  .answer-heading .desktop-only{display:none}.direction-button{min-width:44px!important;min-height:44px!important;padding:6px!important;font-size:17px!important}.direction-label{display:none}
  .mobile-pager{display:flex;align-items:center;gap:6px;flex:none;margin:0;margin-left:auto}.mobile-pager button{min-width:44px;min-height:44px}.mobile-pager span{font-size:10px;min-width:25px;text-align:center;white-space:nowrap}
  .desktop-answers{display:none}.mobile-answers{display:grid;flex:none;gap:4px}.mobile-slot{width:100%;min-width:44px;min-height:44px;height:auto;max-height:110px;aspect-ratio:120/170}
  .mobile-slot .card-svg{display:block;width:100%;height:100%;max-width:none}.mobile-slot .slot-number{font-size:11px}.mobile-slot .slot-placeholder{font-size:18px}
  .mobile-slot.filled .slot-number{font-size:9px;bottom:3px;right:3px}
  .edit-toolbar{gap:5px;min-height:44px;flex-wrap:nowrap}.edit-toolbar button{padding:9px 8px;font-size:11px;min-height:44px;flex:1;white-space:nowrap}
  .edit-toolbar .toolbar-note{display:none}.pool-heading,.recall-footer{display:none}
  .candidate-pool{--pool-height:clamp(44px,7svh,60px);--pool-width:47px;flex:1;min-height:calc(var(--pool-height) * 4 + 12px);height:auto;display:flex;flex-direction:column;justify-content:flex-end;gap:4px;margin:0}
  .candidate-pool .suit-row{height:var(--pool-height);min-height:var(--pool-height);flex:none;overflow-x:auto;overflow-y:hidden;isolation:auto;gap:5px;padding:0;scrollbar-width:none}
  .candidate-pool .suit-row::-webkit-scrollbar{display:none}.candidate-pool>.suit-row:last-child{flex:none}
  .candidate-pool .suit-label{display:flex;flex:0 0 22px;font-size:20px;background:var(--table);position:sticky;left:0;z-index:10}
  .candidate-pool .pool-card,.candidate-pool>.suit-row:last-child>.pool-card:last-child{flex:0 0 47px;height:var(--pool-height);min-height:44px;overflow:hidden}
  .pool-visual{width:47px;transform:none!important;height:var(--pool-height);border-radius:4px}.pool-visual .card-svg{display:none}.pool-visual .pool-head{padding:3px 7px;gap:1px;min-width:44px;background:none}
  .pool-visual .pool-head b{font-size:19px}.pool-visual .pool-head span{font-size:17px}.pool-card[data-card$="10"] .pool-head b{font-size:18px}
  .pool-card.used .pool-head{background:none}.pool-card.used .pool-visual:after{top:68%;width:22px;left:8px}
  .result-top .result-score{font-size:24px}.result-score small{font-size:11px}.result-top .secondary{font-size:12px;padding:10px 13px}.result-time{font-size:23px}.result-accuracy{display:none}
  .result-legend{gap:9px;font-size:11px}.result-caption{font-size:11px;line-height:1.7;margin-top:auto}
  .mobile-result-grid{flex:1;align-content:center;gap:4px}.mobile-result-item{position:relative;padding-top:25px;min-width:0}.mobile-result-item .result-original{top:0;left:1px;font-size:12px;gap:2px}.mobile-result-item .result-original small{font-size:8px}
  .mobile-result-item .mobile-slot{max-height:none;min-width:44px}.result-mark{font-size:11px!important;bottom:3px!important;left:3px!important;line-height:15px!important}
  .result-actions button{font-size:13px;padding:10px 16px}
}
@media(max-width:360px){.site-header{padding:10px 12px}.site-header .brand{font-size:16px;gap:7px}.nav-button{padding:9px 6px;min-width:44px;font-size:11px}body[data-screen] #app{padding:10px}.recall-table{padding:8px}.mobile-answers{gap:3px}.answer-heading{gap:4px}.mobile-pager{gap:4px}.edit-toolbar button{padding:9px 6px;font-size:10px}}
@media(max-height:480px){body[data-screen] #app{overflow-y:auto}body[data-screen=home] .home-layout{min-height:480px}body[data-screen=recall] .recall-table{min-height:330px}.site-footer{display:none}}
@media(prefers-reduced-motion:reduce){.pool-visual{transition:none}.flying-card{display:none}}

.history-actions{display:flex;align-items:center;gap:10px;flex:none}
.history-row:hover{background:none}.delete-record{color:#ffabb6}
.history-row .delete-record{justify-self:end;min-width:44px}
.result-item .answer-slot{top:28px;height:calc(100% - 28px)}
.answer-row .large-corner .corner-rank{font-size:var(--corner-rank-size,28px)}
.answer-row .large-corner .corner-rank.letter{font-size:var(--corner-letter-size,24px)}
.answer-row .large-corner .corner-rank.ten{font-size:var(--corner-ten-size,24px)}
.answer-row .large-corner .corner-suit{font-size:var(--corner-suit-size,22px)}
@media(min-width:801px){
  body[data-screen=recall] .site-header{min-height:54px;padding:7px 28px}
  body[data-screen=recall] .site-footer{display:none}
  body[data-screen=recall] #app{padding:10px 24px;gap:8px}
  body[data-screen=recall] .recall-table{padding:10px 12px;gap:7px}
  body[data-screen=recall] .desktop-answers{gap:10px}
  body[data-screen=recall] .recall-footer,body[data-screen=recall] .keyboard-hint,body[data-screen=recall] .pool-heading{display:none}
  body[data-screen=recall] .candidate-pool{--pool-height:clamp(72px,14svh,140px);margin-top:19px}
  body[data-screen=recall] .pool-visual .pool-head{padding:3px 2px;gap:1px}
  body[data-screen=recall] .pool-visual .pool-head b{font-size:17px}
  body[data-screen=recall] .pool-visual .pool-head span{font-size:15px}
  body[data-screen=recall] .pool-card[data-card$="10"] .pool-head b{font-size:15px}
}
@media(min-width:801px) and (max-height:680px){body[data-screen=recall] .candidate-pool{--pool-height:clamp(60px,11.5svh,78px)}}
@media(max-width:800px){
  .mobile-result-item .result-original{font-size:18px;line-height:25px;height:26px}
  .mobile-result-item{padding-top:29px}
  .history-actions{flex-wrap:wrap;justify-content:flex-end;gap:7px}
  .history-page .page-heading{align-items:flex-start;gap:12px}
  .history-actions button{padding:10px 12px;font-size:12px}
}
@media(max-width:520px){.history-page .page-heading{flex-direction:column}.history-actions{justify-content:flex-start}}

.site-header [hidden]{display:none!important}
.recall-tools{display:flex;align-items:center;justify-content:space-between;flex:none;gap:14px;min-height:44px}
.recall-tools .edit-toolbar{display:flex;align-items:center;flex-wrap:nowrap;flex:none;gap:7px;margin:0}
.recall-tools .edit-toolbar button{display:flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:10px 11px;font-size:12px;white-space:nowrap}
.recall-tools .shortcut-key{font-size:10px;line-height:1.4;padding:2px 5px;margin:0;background:#162b43;color:#9cb4d0}
body[data-screen=recall] .recall-tools .keyboard-hint{display:flex;align-items:center;flex-wrap:nowrap;gap:16px;margin:0;font-size:11px;line-height:1.4;white-space:nowrap}
.recall-tools .shortcut{display:inline-flex;align-items:center;gap:5px}
.recall-tools .shortcut .key{font-size:10px;margin:0}
.recall-overflow{font-size:11px;margin-left:auto}
@media(min-width:801px){
  body[data-screen=recall] #app{padding-bottom:14px}
  .recall-tools{margin:0 2px}
}
@media(min-width:801px) and (max-width:1000px){
  .recall-tools{gap:10px}
  .recall-tools .edit-toolbar{gap:5px}
  .recall-tools .edit-toolbar button{padding:9px 8px;gap:6px;font-size:11px}
  body[data-screen=recall] .recall-tools .keyboard-hint{gap:9px;font-size:10px}
}
@media(max-width:800px){
  .recall-tools{gap:0}
  .recall-tools .edit-toolbar{flex:1;gap:5px}
  .recall-tools .edit-toolbar button{flex:1;padding:9px 7px;font-size:11px}
  .recall-tools .shortcut-key,body[data-screen=recall] .recall-tools .keyboard-hint{display:none}
  .answer-heading:has(.recall-overflow){flex-wrap:wrap}
  .recall-overflow{order:4;flex-basis:100%;margin:0;font-size:10px}
}
@media(max-width:360px){.recall-tools .edit-toolbar button{padding:9px 5px;font-size:10px}}

.corner-rank,.pool-visual .pool-head b{font-variant-numeric:lining-nums}
.pool-visual .pool-head b{font-family:'Times New Roman',Georgia,serif}
body[data-screen=result] .site-header nav{display:none}
.history-record-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px}
.history-record-actions .text-button{min-width:44px;padding:9px 8px}
.history-row small{white-space:nowrap}
.review-record{color:var(--blue)}
.result-slot.review-slot{cursor:pointer}
.result-slot.review-slot:hover{filter:brightness(1.05)}
.review-summary-button{margin-left:auto;min-height:44px;color:var(--blue);font-size:12px}
.review-date{font-size:12px;color:var(--muted);margin:0 0 16px}
.review-summary-stats{display:flex;gap:24px;align-items:center;font-size:13px;margin-bottom:18px}
.review-summary-stats strong{font-size:24px;font-weight:500;margin-left:5px;font-variant-numeric:tabular-nums}
.review-filters{display:flex;gap:6px;margin-bottom:12px}
.review-filters button{min-height:44px;flex:1;padding:8px 10px;border:1px solid var(--line);border-radius:5px;color:var(--muted);background:#14243c;font-size:12px;white-space:nowrap}
.review-filters button.selected{background:#284360;color:var(--paper);border-color:#79b4e4}
.review-summary-list{max-height:max(72px,min(36svh,300px,calc(85svh - 338px)));overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#58738f transparent}
.review-error{display:grid;grid-template-columns:64px minmax(0,1fr);gap:8px 14px;border-top:1px solid var(--line);padding:14px 0}
.review-position{font-size:12px;color:#bed3eb;font-weight:500;padding-top:3px}
.review-error-cards{display:flex;gap:28px;align-items:center;color:var(--muted);font-size:12px}
.review-card-label{font-size:20px;font-family:'Times New Roman',Georgia,serif;color:var(--paper);margin-left:6px;white-space:nowrap}
.review-card-label.red{color:#ffaab5}
.review-error p{grid-column:2;margin:0;font-size:11px;color:#8fa8c5;line-height:1.7}
.review-no-errors{color:#a7ddbe;line-height:1.8;font-size:13px;padding:16px 0;margin:0}
@media(max-width:800px){
  .history-record-actions{gap:2px}
  .history-record-actions .text-button{padding:9px 4px;font-size:11px}
  .result-table.is-review .answer-heading{flex-wrap:wrap}
  .result-table.is-review .result-legend{flex-basis:100%}
  .result-table.is-review .review-summary-button{margin-left:0}
}
@media(max-width:520px){
  .review-summary-stats{gap:16px;font-size:12px}
  .review-summary-stats strong{font-size:22px;margin-left:3px}
  .review-filters button{padding:8px 4px;font-size:11px}
  .review-error{grid-template-columns:48px minmax(0,1fr);gap:8px}
  .review-error-cards{gap:13px;font-size:11px}
  .review-card-label{font-size:18px;margin-left:3px}
}

@media(max-width:800px){
  .mobile-answers.mobile-card-board{display:flex;flex-direction:column;justify-content:center;flex:1;min-height:0;gap:var(--mobile-row-gap,10px)}
  .recall-table:not(.result-table) .candidate-pool{flex:none;height:calc(var(--pool-height) * 4 + 12px)}
  .mobile-card-row{display:flex;flex:none;align-items:stretch;justify-content:flex-end;position:relative;height:calc(var(--mobile-face-height,113px) + var(--mobile-label-height,18px));isolation:isolate;max-width:100%}
  .mobile-card-row.ltr{justify-content:flex-start}
  .mobile-card-item{flex:0 0 var(--mobile-step-width,48px);height:100%;position:relative;min-width:0;z-index:0}
  .mobile-card-item:has(.filled:not(.receiving)){z-index:2}
  .mobile-card-row .stack-flight{z-index:1}
  .mobile-card-item:last-child{flex-basis:var(--mobile-card-width,80px)}
  .mobile-card-row .mobile-slot{position:absolute;top:var(--mobile-label-height,18px);left:0;width:100%;height:var(--mobile-face-height,113px);max-height:none;min-height:44px;min-width:0;aspect-ratio:auto;padding:0;display:flex;align-items:center;justify-content:center;overflow:hidden;border-radius:6px}
  .mobile-card-row .mobile-slot .card-svg{position:absolute;left:0;top:0;width:var(--mobile-card-width,80px);height:var(--mobile-face-height,113px);max-width:none}
  .mobile-card-item>.slot-number{position:absolute;top:0;left:3px;height:16px;line-height:16px;font-size:12px;color:#92accb}
  .mobile-card-item:has(.active)>.slot-number{color:#cce9ff}
  .mobile-card-row .slot-placeholder{font-size:22px}
  .mobile-card-row .mobile-result-item{padding-top:0}
  .mobile-card-row .result-original{top:0;left:2px;font-size:18px;height:26px;line-height:25px;max-width:100%;overflow:hidden}
  .mobile-card-row .result-mark{bottom:5px!important;left:4px!important;font-size:13px!important;line-height:18px!important;min-width:16px}
}
@media(max-width:800px) and (max-height:480px){.mobile-answers.mobile-card-board{overflow-y:auto;justify-content:flex-start;scrollbar-width:thin}}

.waiting-table{padding:20px;text-align:center}
.waiting-table .waiting-copy{max-width:360px;line-height:1.8}
.waiting-table .waiting-skip{margin-top:24px;min-height:44px}
.waiting-table .waiting-shortcut{margin-top:12px;font-size:11px;color:#91a9c5}
@media(max-width:800px){.waiting-table h1{font-size:20px}.waiting-table .waiting-copy{font-size:12px}.waiting-table .prep-count{font-size:80px}}

.memory-swipe-guide{display:none}
.memory-swipe-layer{position:fixed;z-index:90;overflow:hidden;border-radius:9px;pointer-events:none}
.memory-swipe-ghost{position:absolute;pointer-events:none;transform-origin:50% 90%;filter:drop-shadow(0 6px 7px #08152440)}
.memory-swipe-ghost .card-svg{width:100%;height:100%}
@media(max-width:800px){
  .memory-hand,.memory-hand .memory-card{touch-action:pinch-zoom}
  .memory-hand{user-select:none;-webkit-user-select:none;cursor:grab}
  .memory-hand .memory-card{transform-origin:50% 90%}
  .memory-hand.is-dragging{cursor:grabbing}
  .memory-hand.is-dragging .memory-card{will-change:transform}
  .memory-controls .group-status{line-height:1.5}
  .memory-swipe-guide{display:block;margin-top:2px;font-size:10px;color:#8fa9c7;white-space:nowrap}
}
@media(max-width:800px){
  .site-header .brand img{width:36px;height:36px}
  .home-branding{padding-top:8px}
  .configuration .start-hint{display:none}
  .configuration .copyright{font-size:12px}
  .configuration .contact-info{font-size:11px}
  .configuration .site-url{font-size:13px}
  .site-url a{min-height:32px}
  .site-footer{display:none}
}
@media(max-height:680px) and (min-width:801px){
  .home-branding{padding-top:12px}
}
@media(max-width:800px) and (max-height:700px){
  .configuration .mode-switch{margin-bottom:8px}
  .configuration-controls>.field-grid{row-gap:10px}
  .configuration .preferences-toggle,.configuration .start-button{margin-top:8px}
  .home-branding{padding-top:4px}
}
