/* DDJK PC Web: unified Windows practice reading-space presentation.
   Only existing HTML and DD LocalFirst events are used. No business callbacks.
   This replaces fragmented visual overrides with one responsive desktop contract.
   Windows reference: sidebar -> reading+image+stats -> controls -> optional
   skill/official explanation -> full-width ten-column question navigation. */
@media screen and (min-width:980px) {
  html:not(.dd-practice-embedded-preview) body.dd-ddesktop-windows {
    --dd-native-sidebar:clamp(222px,18.1vw,266px);
    --dd-native-stat:clamp(192px,15.2vw,224px);
    --dd-native-stage-height:clamp(292px,37.5dvh,460px);
    --dd-native-border:#dce9e7;
    --dd-native-accent:#07877e;
    background:#fff!important;color:#143941!important;
  }
  body.dd-ddesktop-windows .dd-screen{min-width:0!important;max-width:100%!important}
  body.dd-ddesktop-windows :is(.dd-page-shell,.dd-layout){max-width:none!important;width:100%!important;margin:0!important}
  body.dd-ddesktop-windows .dd-topbar{height:66px!important;min-height:66px!important;position:relative!important;box-shadow:none!important;background:#eef8f6!important;border-bottom:1px solid var(--dd-native-border)!important}
  body.dd-ddesktop-windows .dd-header-inner{height:66px!important;padding:0 17px!important;display:flex!important;align-items:center!important;gap:14px!important}
  body.dd-ddesktop-windows .dd-brand{min-width:0!important;flex:0 1 auto!important}
  body.dd-ddesktop-windows .dd-brand-title{font-size:clamp(22px,1.9vw,27px)!important;line-height:1.18!important;color:#087d77!important;font-weight:800!important;white-space:nowrap!important}
  body.dd-ddesktop-windows .dd-brand-sub{font-size:13px!important;margin-top:2px!important;white-space:nowrap!important}
  body.dd-ddesktop-windows .dd-version-badge{display:none!important}
  body.dd-ddesktop-windows .dd-nav{margin-left:auto!important;gap:4px!important;align-items:center!important}
  body.dd-ddesktop-windows .dd-nav-item{height:48px!important;min-width:0!important;padding:0 clamp(5px,.6vw,11px)!important;font-size:13px!important;color:#4c726f!important;white-space:nowrap!important;background:transparent!important;border:0!important}
  body.dd-ddesktop-windows .dd-nav-item.active{color:#07877e!important}

  body.dd-ddesktop-windows .dd-layout{display:grid!important;grid-template-columns:var(--dd-native-sidebar) minmax(0,1fr)!important;align-items:start!important;gap:0!important;padding:0!important;background:#fff!important;position:relative!important}
  body.dd-ddesktop-windows .dd-left{grid-column:1!important;grid-row:1!important;box-sizing:border-box!important;width:100%!important;min-height:calc(100dvh - 66px)!important;max-width:none!important;padding:9px 10px 20px!important;background:#edf8f6!important;border-right:1px solid var(--dd-native-border)!important;align-self:stretch!important}
  body.dd-ddesktop-windows .dd-left .dd-side-card{margin:0 0 8px!important;padding:0!important;background:transparent!important;border:0!important;box-shadow:none!important}
  body.dd-ddesktop-windows .dd-left .dd-side-title{margin:9px 0 6px!important;font-size:14px!important;font-weight:800!important}
  body.dd-ddesktop-windows .dd-bank-card{min-height:48px!important;max-width:100%!important;width:100%!important;padding:5px 9px!important;background:#fff!important;border:1px solid #dceae7!important;border-radius:9px!important;display:flex!important;gap:8px!important;align-items:center!important}
  body.dd-ddesktop-windows .dd-bank-card .dd-bank-icon{flex:none!important}
  body.dd-ddesktop-windows .dd-bank-card>span:nth-child(2){min-width:0!important;flex:1!important;text-align:left!important}
  body.dd-ddesktop-windows .dd-bank-card #sideBankName{display:block!important;font-size:16px!important;line-height:1.3!important;white-space:normal!important;overflow-wrap:break-word!important}
  body.dd-ddesktop-windows .dd-edition-switch{min-height:37px!important;padding:2px!important;margin:6px 0 2px!important;display:flex!important}
  body.dd-ddesktop-windows .dd-edition-link{min-height:32px!important;flex:1!important;font-weight:800!important;font-size:15px!important}
  body.dd-ddesktop-windows .dd-navigation-card .dd-mode-btn{height:43px!important;min-height:43px!important;width:100%!important;display:flex!important;align-items:center!important;gap:9px!important;padding:0 7px!important;margin:0 0 2px!important;border-radius:8px!important;box-sizing:border-box!important}
  body.dd-ddesktop-windows .dd-navigation-card .dd-mode-btn .dd-mode-text{font-size:16px!important;line-height:1.25!important;font-weight:750!important}
  body.dd-ddesktop-windows .dd-mode-icon,body.dd-ddesktop-windows .dd-win-original-icon{flex:none!important}
  body.dd-ddesktop-windows .dd-desktop-left-extras{display:block!important;border:0!important}
  body.dd-ddesktop-windows .dd-desktop-side-link{min-height:42px!important;display:flex!important;align-items:center!important;gap:10px!important;padding:0 7px!important;border:0!important;background:transparent!important;color:#194b50!important;font-size:15px!important;font-weight:750!important;text-decoration:none!important}
  body.dd-ddesktop-windows .dd-desktop-side-link>svg{width:21px!important;height:21px!important;stroke:currentColor!important;fill:none!important;stroke-width:2!important;flex:none!important}
  body.dd-ddesktop-windows .dd-desktop-side-arrow{margin-left:auto!important}
  body.dd-ddesktop-windows .dd-desktop-side-link:hover{background:#dcefeb!important;border-radius:7px!important}

  body.dd-ddesktop-windows .dd-main{grid-column:2!important;grid-row:1!important;box-sizing:border-box!important;min-width:0!important;width:100%!important;max-width:none!important;margin:0!important;padding:0!important;background:#fff!important;overflow:visible!important;display:flex!important;flex-direction:column!important;gap:0!important}
  body.dd-ddesktop-windows .dd-question-card{order:0!important;width:100%!important;min-width:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;overflow:visible!important}
  body.dd-ddesktop-windows .dd-question-head{height:45px!important;min-height:45px!important;padding:0 18px!important;display:flex!important;align-items:center!important;border:0!important;border-bottom:1px solid var(--dd-native-border)!important;border-radius:0!important}
  body.dd-ddesktop-windows .dd-study-breadcrumb{font-size:14px!important;font-weight:760!important}
  body.dd-ddesktop-windows .dd-question-body{box-sizing:border-box!important;width:calc(100% - var(--dd-native-stat))!important;height:var(--dd-native-stage-height)!important;min-height:var(--dd-native-stage-height)!important;max-height:none!important;display:grid!important;grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto auto minmax(0,1fr)!important;row-gap:7px!important;padding:14px clamp(13px,1.4vw,23px) 6px!important;border-right:1px solid var(--dd-native-border)!important;overflow:hidden!important}
  body.dd-ddesktop-windows .dd-question-title-row{grid-row:1!important;grid-column:1!important;margin:0!important;min-height:0!important}
  body.dd-ddesktop-windows .dd-question-title{font-size:clamp(21px,1.65vw,28px)!important;line-height:1.38!important;margin:0!important;font-weight:800!important;color:#14343d!important}
  body.dd-ddesktop-windows .dd-question-content-grid,body.dd-ddesktop-windows .dd-question-body.no-media .dd-question-content-grid{grid-row:3!important;grid-column:1!important;display:grid!important;grid-template-columns:minmax(0,1fr) minmax(210px,37%)!important;column-gap:clamp(10px,1.25vw,22px)!important;min-width:0!important;min-height:0!important;overflow:hidden!important}
  body.dd-ddesktop-windows .dd-question-left{min-height:0!important;min-width:0!important;overflow-y:auto!important;overscroll-behavior:contain!important;padding-right:5px!important}
  body.dd-ddesktop-windows .dd-option{font-size:clamp(18px,1.48vw,23px)!important;line-height:1.48!important;min-height:43px!important;margin-bottom:0!important}
  body.dd-ddesktop-windows .dd-question-right{min-width:0!important;min-height:0!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;gap:6px!important;padding:0!important}
  body.dd-ddesktop-windows .dd-question-body.no-media .dd-question-right{justify-content:flex-end!important}
  body.dd-ddesktop-windows .dd-question-media{width:100%!important;max-width:100%!important;min-height:0!important;margin:0!important;display:flex!important;justify-content:center!important;align-items:flex-start!important;overflow:hidden!important}
  body.dd-ddesktop-windows .dd-media-frame{width:100%!important;height:auto!important;max-height:clamp(160px,26dvh,268px)!important;overflow:hidden!important;display:flex!important;justify-content:center!important;align-items:flex-start!important;background:#f8fbfa!important;border:1px solid #ebf1ef!important;border-radius:7px!important}
  body.dd-ddesktop-windows .dd-question-media img{width:100%!important;height:auto!important;max-width:100%!important;max-height:clamp(160px,26dvh,268px)!important;object-fit:contain!important;margin:0!important;display:block!important}
  body.dd-ddesktop-windows .dd-answer-pad{margin-top:auto!important;min-height:0!important}
  body.dd-ddesktop-windows .dd-answer-pad-options{display:flex!important;justify-content:flex-end!important;gap:6px!important;grid-template-columns:none!important;width:100%!important}
  body.dd-ddesktop-windows .dd-answer-pad-btn{flex:0 0 clamp(42px,3.65vw,66px)!important;width:clamp(42px,3.65vw,66px)!important;max-width:none!important;min-width:0!important;height:36px!important;box-sizing:border-box!important}
  body.dd-ddesktop-windows .dd-practice-control{box-sizing:border-box!important;width:calc(100% - var(--dd-native-stat))!important;height:47px!important;min-height:47px!important;border-right:1px solid var(--dd-native-border)!important;background:#fff!important}
  body.dd-ddesktop-windows .dd-control-toolbar{box-sizing:border-box!important;width:100%!important;height:47px!important;min-height:47px!important;display:flex!important;align-items:center!important;justify-content:flex-end!important;grid-template-columns:none!important;gap:0!important;padding:0 14px 5px!important}
  body.dd-ddesktop-windows .dd-operation-toolbar{width:auto!important;max-width:100%!important;min-width:0!important;display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;justify-content:flex-end!important;align-items:center!important;gap:clamp(3px,.42vw,7px)!important;margin-left:auto!important;grid-template-columns:none!important}
  body.dd-ddesktop-windows .dd-operation-toolbar :is(.dd-action-outline,.dd-preference-button){box-sizing:border-box!important;flex:0 1 auto!important;width:auto!important;min-width:0!important;max-width:none!important;height:33px!important;min-height:33px!important;font-size:clamp(11px,.86vw,13px)!important;line-height:1.2!important;padding:0 clamp(4px,.62vw,10px)!important;white-space:nowrap!important}
  body.dd-ddesktop-windows .dd-operation-toolbar .dd-nav-action{min-width:57px!important}
  body.dd-ddesktop-windows .dd-preference-wrap{flex:0 0 auto!important;min-width:0!important}

  /* Compact, uninterrupted right information panel: only upper reading area. */
  body.dd-ddesktop-windows .dd-desktop-right{position:absolute!important;top:52px!important;right:10px!important;z-index:2!important;display:block!important;box-sizing:border-box!important;width:calc(var(--dd-native-stat) - 19px)!important;max-width:none!important;height:auto!important;min-height:0!important;max-height:calc(var(--dd-native-stage-height) + 37px)!important;overflow:hidden!important;padding:8px 0!important;border:0!important;border-radius:0!important;background:#fff!important;box-shadow:none!important;font-size:12px!important}
  body.dd-ddesktop-windows .dd-desktop-account{min-height:38px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;gap:5px!important;padding:7px 9px!important;border-radius:8px!important;background:#e0f1ee!important;color:#164f51!important;font-size:12px!important;text-decoration:none!important}
  body.dd-ddesktop-windows .dd-desktop-section-title{font-size:13px!important;font-weight:820!important;color:#1c4e51!important;margin:9px 0 5px!important;padding:0 0 0 7px!important;border-left:3px solid var(--dd-native-accent)!important;line-height:1.2!important}
  body.dd-ddesktop-windows .dd-desktop-data-row{display:flex!important;align-items:baseline!important;justify-content:space-between!important;gap:7px!important;margin:3px 0!important;font-size:12px!important;line-height:1.36!important}
  body.dd-ddesktop-windows .dd-desktop-data-row strong{font-size:12px!important;text-align:right!important;overflow-wrap:anywhere!important}
  body.dd-ddesktop-windows .dd-desktop-native-progress{margin:6px 0 0!important;padding:6px 0 0!important;border-top:1px solid #e5eeec!important}
  body.dd-ddesktop-windows .dd-desktop-timer{display:flex!important;justify-content:space-between!important;gap:5px!important;align-items:center!important;padding:8px 0 0!important;font-size:12px!important}
  body.dd-ddesktop-windows .dd-desktop-right .dd-progress-card,body.dd-ddesktop-windows .dd-desktop-shortcuts,body.dd-ddesktop-windows .dd-desktop-right .dd-desktop-section-title:last-of-type{display:none!important}

  /* Explanation belongs directly after operation bar, before question numbers.
     Default hidden: never leave huge empty cards on screen. */
  body.dd-ddesktop-windows .dd-explain-dock{order:1!important;box-sizing:border-box!important;flex:none!important;width:100%!important;min-width:0!important;display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:0!important;margin:0!important;padding:5px 15px 7px!important;border-top:1px solid var(--dd-native-border)!important;border-bottom:1px solid var(--dd-native-border)!important;background:#fff!important}
  /* Windows compact detail rail: a collapsed section must remain discoverable.
     The prior `display:none` made the real skill/official panels impossible to
     open manually. Keep the actual core-owned panels as keyboard-accessible
     headings, but never reserve an empty explanation card. */
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-start!important;flex-wrap:wrap!important;gap:6px!important;min-height:38px!important;padding:4px 14px!important;background:#f7fbfa!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-explain-card{flex:0 1 auto!important;width:auto!important;min-width:0!important;max-width:100%!important;cursor:pointer!important;background:transparent!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-panel-title{height:29px!important;min-height:29px!important;min-width:0!important;width:auto!important;gap:6px!important;padding:0 10px!important;border:1px solid #d4e6e2!important;border-radius:6px!important;background:#fff!important;font-size:13px!important;white-space:nowrap!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-panel-title span{font-size:11px!important;color:#698784!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-panel-title::before{height:13px!important;width:3px!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-panel-content{display:none!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-explain-card:focus-visible .dd-panel-title{outline:2px solid #07877e!important;outline-offset:2px!important}
  body.dd-ddesktop-windows.dd-native-learning-hidden #explainDock .dd-explain-card:hover .dd-panel-title{border-color:#86c6bc!important;background:#effaf7!important}
  body.dd-ddesktop-windows.dd-native-learning-transient #questionSheetPanel{display:none!important}
  body.dd-ddesktop-windows.dd-native-learning-transient #explainDock{display:grid!important;min-height:min(27dvh,210px)!important;align-content:start!important}
  body.dd-ddesktop-windows.dd-native-learning-complete #explainDock{display:grid!important;min-height:0!important;max-height:min(24dvh,220px)!important;overflow-y:auto!important}
  body.dd-ddesktop-windows #explainDock .dd-explain-card{box-sizing:border-box!important;height:auto!important;min-height:0!important;max-height:none!important;border:0!important;border-radius:0!important;background:#fff!important;overflow:visible!important}
  body.dd-ddesktop-windows #explainDock .dd-explain-card[hidden]{display:none!important}
  body.dd-ddesktop-windows #explainDock .dd-panel-title{height:31px!important;min-height:31px!important;padding:0 8px!important;display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:10px!important;background:transparent!important;font-size:14px!important;font-weight:850!important}
  body.dd-ddesktop-windows #explainDock .dd-panel-title::before{content:'';display:block;flex:none;width:3px;height:17px;border-radius:2px;background:#07877e}
  body.dd-ddesktop-windows #officialPanel .dd-panel-title::before{background:#4a93bc}
  body.dd-ddesktop-windows #explainDock .dd-panel-title span{font-size:12px!important}
  body.dd-ddesktop-windows #explainDock .dd-panel-eye{display:none!important}
  body.dd-ddesktop-windows #explainDock .dd-panel-content{box-sizing:border-box!important;height:auto!important;min-height:0!important;max-height:min(20dvh,180px)!important;overflow:auto!important;padding:5px 12px 8px!important;font-size:clamp(15px,1.2vw,19px)!important;line-height:1.55!important}
  body.dd-ddesktop-windows #explainDock .dd-panel-collapsed .dd-panel-content{display:none!important}
  body.dd-ddesktop-windows #explainDock .dd-explain-card:not(.dd-panel-collapsed) .dd-panel-content{display:block!important}
  body.dd-ddesktop-windows .dd-native-learning-pref{border-top:1px solid #e4ece9;margin:8px 4px 0;padding:8px 4px 0}
  body.dd-ddesktop-windows .dd-native-learning-pref label{display:flex;align-items:center;justify-content:space-between;gap:10px;cursor:pointer;font-size:13px}
  body.dd-ddesktop-windows .dd-native-learning-pref small{display:block;color:#6b8582;margin-top:2px}
  body.dd-ddesktop-windows .dd-native-learning-pref input{width:18px;height:18px;accent-color:#07877e}

  /* Number navigator spans full main width; no abandoned white gap below.
     The original real virtualized question click/group controls are retained. */
  body.dd-ddesktop-windows .dd-sheet-card{order:2!important;box-sizing:border-box!important;width:100%!important;min-width:0!important;padding:4px 13px 11px!important;margin:0!important;border-top:1px solid var(--dd-native-border)!important;background:#fff!important}
  body.dd-ddesktop-windows .dd-sheet-head{height:38px!important;min-height:38px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;gap:7px!important;padding:0 3px!important}
  body.dd-ddesktop-windows .dd-sheet-head>b{font-size:15px!important;white-space:nowrap!important}
  body.dd-ddesktop-windows .dd-sheet-head-tools{gap:10px!important;min-width:0!important}
  body.dd-ddesktop-windows .dd-sheet-progress-legend{font-size:10px!important;gap:7px!important}
  body.dd-ddesktop-windows .dd-v3-sheet-groups{min-height:28px!important;padding:0 7px 3px!important}
  body.dd-ddesktop-windows .dd-v3-sheet-groups button{height:26px!important}
  body.dd-ddesktop-windows .dd-sheet-grid.dd-v3-sheet-group-mode{width:100%!important;max-width:100%!important;margin:0!important}
  body.dd-ddesktop-windows .dd-sheet-virtual-window{gap:4px!important}
  body.dd-ddesktop-windows .dd-sheet-grid.dd-sheet-virtualized .dd-sheet-virtual-window .dd-sheet-btn{height:34px!important;min-height:34px!important;max-height:34px!important;font-size:14px!important}
  body.dd-ddesktop-windows .dd-sheet-btn{font-size:14px!important}
}
@media screen and (min-width:980px) and (max-height:819px) {
  html:not(.dd-practice-embedded-preview) body.dd-ddesktop-windows{--dd-native-stage-height:clamp(286px,38dvh,322px)}
  body.dd-ddesktop-windows .dd-navigation-card .dd-mode-btn{height:39px!important;min-height:39px!important}
  body.dd-ddesktop-windows .dd-desktop-right{top:50px!important}
  body.dd-ddesktop-windows .dd-desktop-section-title{margin:6px 0 3px!important}
  body.dd-ddesktop-windows .dd-desktop-data-row{margin:2px 0!important}
  body.dd-ddesktop-windows .dd-sheet-grid.dd-sheet-virtualized .dd-sheet-virtual-window .dd-sheet-btn{height:31px!important;min-height:31px!important;max-height:31px!important}
}
@media screen and (min-width:980px) and (max-width:1199px) {
  html:not(.dd-practice-embedded-preview) body.dd-ddesktop-windows{--dd-native-sidebar:clamp(198px,19.5vw,225px);--dd-native-stat:clamp(160px,16.5vw,185px)}
  body.dd-ddesktop-windows .dd-brand-title{font-size:20px!important}
  body.dd-ddesktop-windows .dd-navigation-card .dd-mode-btn .dd-mode-text{font-size:14px!important}
  body.dd-ddesktop-windows .dd-control-toolbar{padding:0 6px 5px!important}
  body.dd-ddesktop-windows .dd-operation-toolbar .dd-nav-action{min-width:53px!important}
  body.dd-ddesktop-windows .dd-operation-toolbar :is(.dd-action-outline,.dd-preference-button){font-size:11px!important;padding-inline:4px!important}
  body.dd-ddesktop-windows .dd-desktop-data-row,body.dd-ddesktop-windows .dd-desktop-data-row strong{font-size:11px!important}
}
@media screen and (max-width:979px) {
  /* Narrow split-screen/zoom: keep mature DD responsive functionality. */
  .dd-screen{min-width:0!important;max-width:100%!important}
  .dd-page-shell{width:100%!important;max-width:100%!important}
  .dd-layout{grid-template-columns:clamp(150px,20vw,190px) minmax(0,1fr)!important;min-width:0!important}
  .dd-main,.dd-question-body{min-width:0!important}
  .dd-explain-dock{grid-template-columns:minmax(0,1fr)!important}
  .dd-operation-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .dd-operation-toolbar>*{min-width:0!important}
  .dd-sheet-grid{max-width:100%!important}
}
@media screen and (max-width:760px) {
  .dd-layout{grid-template-columns:minmax(0,1fr)!important}
  .dd-left,.dd-main{grid-column:1!important;min-width:0!important}
  .dd-left{min-height:0!important}
  .dd-header-inner{flex-wrap:wrap!important}
  .dd-topbar{height:auto!important;min-height:70px!important}
  .dd-nav{overflow-x:auto!important;max-width:100%!important}
  .dd-question-body{grid-template-columns:minmax(0,1fr)!important;height:auto!important;min-height:280px!important}
  .dd-question-content-grid{grid-template-columns:minmax(0,1fr)!important}
}


/* 2026-10-30: compact-width desktop parity.  At 760..979 the original DD
   breakpoint previously expanded two empty 150px+ explanation cards and split
   six operations across two rows.  These are presentation-only changes: all
   real DD click handlers, permissions and media logic remain untouched. */
@media screen and (min-width:760px) and (max-width:979px) {
  body.dd-subject-study .dd-layout {
    box-sizing:border-box!important;
    grid-template-columns:clamp(174px,19vw,188px) minmax(0,1fr)!important;
    gap:0!important;
    padding:0!important;
    width:100%!important;
  }
  body.dd-subject-study .dd-left {
    box-sizing:border-box!important;
    min-width:0!important;
    width:100%!important;max-width:none!important;margin:0!important;
    max-height:calc(100dvh - 64px)!important;overflow-y:auto!important;scrollbar-width:thin!important;
    padding:8px!important;
    background:#eff8f6!important;
    border-right:1px solid #dbe9e6!important;
  }
  body.dd-subject-study .dd-main {min-width:0!important;margin:0!important;padding:0!important;gap:0!important}
  body.dd-subject-study .dd-question-card {border-radius:0!important;border:0!important;box-shadow:none!important}
  body.dd-subject-study .dd-question-head {min-height:40px!important;height:40px!important;padding:0 12px!important}
  body.dd-subject-study .dd-question-body {box-sizing:border-box!important;min-height:298px!important;height:clamp(298px,41dvh,336px)!important;padding:10px 14px!important;overflow:hidden!important}
  body.dd-subject-study .dd-question-title {font-size:clamp(19px,2.35vw,22px)!important;line-height:1.4!important}
  body.dd-subject-study .dd-option {font-size:17px!important;line-height:1.5!important;min-height:38px!important}
  body.dd-subject-study .dd-question-left {min-width:0!important;max-height:calc(41dvh - 36px)!important;overflow:auto!important}
  body.dd-subject-study .dd-question-content-grid {min-width:0!important;min-height:0!important}
  body.dd-subject-study .dd-question-media img {object-fit:contain!important;max-height:185px!important;width:auto!important;max-width:100%!important}
  body.dd-subject-study .dd-question-media .dd-media-frame {max-height:185px!important;overflow:hidden!important}
  body.dd-subject-study .dd-answer-pad-btn {height:38px!important;min-width:42px!important}
  body.dd-subject-study .dd-practice-control {box-sizing:border-box!important;min-height:45px!important;height:auto!important;padding:0!important}
  body.dd-subject-study .dd-control-toolbar {min-height:45px!important;height:auto!important;box-sizing:border-box!important;padding:4px 9px!important;display:flex!important;align-items:center!important;justify-content:flex-end!important}
  body.dd-subject-study .dd-control-spacer {display:none!important}
  body.dd-subject-study .dd-operation-toolbar {min-width:0!important;max-width:100%!important;width:auto!important;margin-left:auto!important;display:flex!important;flex-wrap:nowrap!important;gap:4px!important;justify-content:flex-end!important;align-items:center!important;grid-template-columns:none!important}
  body.dd-subject-study .dd-operation-toolbar :is(.dd-action-outline,.dd-preference-button) {min-width:0!important;width:auto!important;height:34px!important;min-height:34px!important;padding:0 clamp(5px,.75vw,9px)!important;white-space:nowrap!important;font-size:clamp(11px,1.27vw,13px)!important;box-sizing:border-box!important}
  body.dd-subject-study #explainDock {display:flex!important;flex-direction:row!important;flex-wrap:wrap!important;align-items:flex-start!important;gap:6px!important;min-height:39px!important;height:auto!important;margin:0!important;padding:5px 12px!important;box-sizing:border-box!important;background:#f7fbfa!important;border-top:1px solid #dbe9e6!important;border-bottom:1px solid #dbe9e6!important}
  body.dd-subject-study #explainDock .dd-explain-card {height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important;border:0!important;background:transparent!important;box-shadow:none!important;box-sizing:border-box!important}
  body.dd-subject-study #explainDock .dd-explain-card.dd-panel-collapsed {width:auto!important;flex:0 1 auto!important;cursor:pointer!important}
  body.dd-subject-study #explainDock .dd-explain-card:not(.dd-panel-collapsed) {width:100%!important;flex:1 0 100%!important;background:#fff!important}
  body.dd-subject-study #explainDock .dd-panel-title {height:29px!important;min-height:29px!important;padding:0 9px!important;display:flex!important;align-items:center!important;gap:7px!important;background:#fff!important;border:1px solid #d6e7e3!important;border-radius:6px!important;font-size:13px!important;white-space:nowrap!important}
  body.dd-subject-study #explainDock .dd-panel-title span {font-size:11px!important;color:#698784!important}
  body.dd-subject-study #explainDock .dd-panel-eye {display:none!important}
  body.dd-subject-study #explainDock .dd-panel-content {height:auto!important;max-height:min(20dvh,160px)!important;padding:8px 10px!important;overflow:auto!important}
  body.dd-subject-study #explainDock .dd-explain-card.dd-panel-collapsed .dd-panel-content {display:none!important}
  body.dd-subject-study #explainDock .dd-explain-card:not(.dd-panel-collapsed) .dd-panel-content {display:block!important}
  body.dd-subject-study .dd-sheet-card {box-sizing:border-box!important;padding:5px 10px 12px!important;margin:0!important;max-width:100%!important;border-radius:0!important}
  body.dd-subject-study .dd-sheet-head {min-height:35px!important;height:auto!important;gap:5px!important}
  body.dd-subject-study .dd-sheet-head-tools {min-width:0!important;flex-wrap:wrap!important;justify-content:flex-end!important;gap:5px!important}
  body.dd-subject-study .dd-sheet-grid {width:100%!important;max-width:100%!important}
}

@media screen and (min-width:980px) {
  /* Tall menus scroll in their own pane when the desktop viewport is short. */
  body.dd-ddesktop-windows .dd-left {
    height:calc(100dvh - 66px)!important;
    max-height:calc(100dvh - 66px)!important;
    overflow-y:auto!important;
    scrollbar-width:thin!important;
  }
}

/* Native practice long-question guard: an unusually long stem must never
   consume the entire reading stage and hide the answer choices. The original
   DD question/options handlers, media controls and keyboard events are kept. */
@media screen and (min-width:760px) {
  body.dd-subject-study .dd-question-title-row {
    box-sizing:border-box!important;
    max-height:clamp(74px,10dvh,92px)!important;
    min-height:0!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    overscroll-behavior:contain!important;
    scrollbar-width:thin!important;
  }
  body.dd-subject-study .dd-question-content-grid {
    min-height:0!important;
  }
  body.dd-subject-study .dd-question-left {
    min-height:0!important;
    overflow-y:auto!important;
    overscroll-behavior:contain!important;
    scrollbar-width:thin!important;
  }
}

/* When the stem grows tall, the media viewport shrinks before the answer pad.
   Preserve the original image aspect ratio; never hide the answer controls. */
@media screen and (min-width:760px) {
  body.dd-subject-study .dd-question-right {overflow:hidden!important;}
  body.dd-subject-study .dd-question-media:not([hidden]) {
    flex:1 1 0!important;min-height:0!important;overflow:hidden!important;
    display:flex!important;align-items:stretch!important;justify-content:center!important;
  }
  body.dd-subject-study .dd-question-media[hidden] {display:none!important;}
  body.dd-subject-study .dd-question-media:not([hidden]) .dd-media-frame {
    box-sizing:border-box!important;height:100%!important;max-height:100%!important;
    min-height:0!important;align-items:center!important;
  }
  body.dd-subject-study .dd-question-media:not([hidden]) img {
    height:100%!important;max-height:100%!important;object-fit:contain!important;
  }
  body.dd-subject-study .dd-answer-pad {flex:0 0 auto!important;min-height:34px!important;}
}

/* DD9 R2 — customer acceptance closure. PC-only, CSS/DOM presentation. */
@media screen and (min-width:980px){
 html:not(.dd-practice-embedded-preview) body.dd-ddesktop-windows .dd-layout.dd-page-shell{
   width:min(100%,1480px)!important;max-width:1480px!important;margin-inline:auto!important;
   border-left:1px solid #e0ece9!important;border-right:1px solid #e0ece9!important;
 }
 html:not(.dd-practice-embedded-preview) body.dd-ddesktop-windows .dd-header-inner.dd-page-shell{
   width:min(100%,1480px)!important;max-width:1480px!important;margin-inline:auto!important;
 }
 body.dd-ddesktop-windows .dd-brand>div{display:flex!important;align-items:baseline!important;flex-wrap:wrap!important;column-gap:16px!important;row-gap:2px!important}
 body.dd-ddesktop-windows .dd-brand-title{font-size:clamp(19px,1.6vw,24px)!important;white-space:nowrap!important}
 body.dd-ddesktop-windows .dd-brand-sub{font-size:12px!important;white-space:nowrap!important;margin:0!important}
 body.dd-ddesktop-windows .dd-navigation-card .dd-region-entry{display:none!important}
 body.dd-ddesktop-windows .dd-navigation-card .dd-mode-btn{min-height:39px!important;height:39px!important}
 body.dd-ddesktop-windows .dd-desktop-side-link.dd9-scores-primary{color:#077b74!important;font-weight:800!important}
 /* One setting entry in the sidebar. Retain the original hidden controller button. */
 body.dd-ddesktop-windows .dd-operation-toolbar .dd-preference-wrap>.dd-preference-button{display:none!important}
 body.dd-ddesktop-windows .dd-operation-toolbar .dd-preference-wrap{width:0!important;min-width:0!important;flex:0 0 0!important;margin:0!important}
 body.dd-ddesktop-windows #ddDesktopLeftExtras>#practicePreferencesPanel{
    display:block;position:fixed!important;z-index:3200!important;left:calc((100vw - min(100vw,1480px))/2 + var(--dd-native-sidebar) + 8px)!important;
    top:105px!important;right:auto!important;bottom:auto!important;min-width:295px!important;
    width:min(360px,calc(100vw - 360px))!important;max-height:calc(100dvh - 128px)!important;
    overflow:auto!important;border:1px solid #d5e8e4!important;border-radius:13px!important;
    box-shadow:0 14px 42px rgba(8,43,37,.18)!important;background:#fff!important;
 }
 body.dd-ddesktop-windows #ddDesktopLeftExtras>#practicePreferencesPanel[hidden]{display:none!important}
 body.dd-ddesktop-windows .dd-question-body .dd-question-title-row,
 body.dd-ddesktop-windows .dd-question-body .dd-question-content-grid{
    width:min(100%,1100px)!important;max-width:1100px!important;margin-inline:auto!important;
 }
 body.dd-ddesktop-windows .dd-question-content-grid,
 body.dd-ddesktop-windows .dd-question-body.no-media .dd-question-content-grid{
    grid-template-columns:minmax(0,1fr) minmax(230px,36%)!important;
 }
 body.dd-ddesktop-windows .dd-question-body.no-media .dd-question-content-grid{
    grid-template-columns:minmax(0,1fr) minmax(170px,28%)!important;
 }
 body.dd-ddesktop-windows .dd-sheet-card{padding-left:10px!important;padding-right:10px!important}
 body.dd-ddesktop-windows .dd-sheet-grid.dd-v3-sheet-group-mode{margin-left:0!important}
}
/* Explanation is not a permanent tab. Only a LocalFirst-opened panel shows it;
   opening explanation temporarily takes the place of the entire number map. */
body.dd-subject-study.dd9-detail-hidden #explainDock,
body.dd-ddesktop-windows.dd-native-learning-complete.dd9-detail-hidden #explainDock,
body.dd-ddesktop-windows.dd-native-learning-hidden.dd9-detail-hidden #explainDock{display:none!important;min-height:0!important;padding:0!important;border:0!important}
body.dd-subject-study.dd9-detail-open #questionSheetPanel{display:none!important}
body.dd-subject-study.dd9-detail-open #explainDock{display:grid!important;min-height:0!important;max-height:min(52dvh,440px)!important;overflow-y:auto!important}
body.dd-subject-study.dd9-detail-open #dd9BackToNumbers{display:block!important}
body.dd-subject-study.dd9-detail-hidden #dd9BackToNumbers{display:none!important}
.dd9-back-to-numbers{justify-self:start;order:-1;margin:3px 3px 8px!important;padding:6px 14px!important;border:1px solid #b9d7d1;background:#f0f9f7!important;border-radius:7px;color:#076e67;font-size:13px;font-weight:800;cursor:pointer}
.dd9-back-to-numbers:focus-visible{outline:2px solid #07877e;outline-offset:2px}
/* Number-group slider starts at the real left edge after a compact group header. */
@media screen and (min-width:1180px){
 body.dd-ddesktop-windows .dd-v3-sheet-groups{
   grid-template-columns:auto auto minmax(0,1fr) auto!important;
   gap:12px!important;padding-inline:0!important;
 }
 body.dd-ddesktop-windows .dd-v3-group-status{min-width:0!important;text-align:left!important}
 body.dd-ddesktop-windows .dd-v3-group-slider{display:block!important;min-width:70px!important;width:100%!important}
}
/* Unified core-owned dialog system. Never reorder API source entries. */
body.dd-subject-study .dd-dialog-mask{padding:clamp(12px,2vw,22px)!important}
body.dd-subject-study .dd-dialog{border-radius:13px!important;border-color:#d9e8e5!important;box-shadow:0 18px 52px rgba(10,45,39,.21)!important}
body.dd-subject-study .dd-dialog-head{height:56px!important;flex-basis:56px!important;padding:0 14px 0 20px!important;background:#f8fbfa!important}
body.dd-subject-study .dd-dialog-head h2{font-size:19px!important;font-weight:800!important}
body.dd-subject-study .dd-dialog-content{padding:16px 18px 20px!important}
body.dd-subject-study .dd-dialog-bank .dd-bank-tabs{display:none!important}
body.dd-subject-study .dd-dialog .dd-choice-grid.dd9-ready,
body.dd-subject-study .dd-dialog.dd9-standard-dialog .dd-choice-grid{
   display:grid!important;grid-auto-flow:column!important;
   grid-template-columns:repeat(var(--dd9-cols,3),minmax(0,1fr))!important;
   grid-template-rows:repeat(var(--dd9-rows,1),minmax(46px,auto))!important;
   gap:9px!important;align-content:start!important;
}
body.dd-subject-study .dd-dialog .dd-category-order,
body.dd-subject-study .dd-dialog-chapter .dd-category-order,
body.dd-subject-study .dd-dialog-intensive .dd-category-order{
   display:grid!important;place-items:center!important;flex:0 0 25px!important;
   width:25px!important;height:25px!important;min-width:25px!important;
   border-radius:7px!important;background:#eaf6f3!important;color:#077f77!important;
   font-variant-numeric:tabular-nums!important;font-size:12px!important;font-weight:800!important;
}
body.dd-subject-study .dd-dialog .dd-bank-choice{min-height:46px!important;padding:9px 11px!important;gap:8px!important;align-items:center!important;border-radius:8px!important;transform:none!important}
body.dd-subject-study .dd-dialog .dd-bank-choice-icon{height:24px!important;width:24px!important;flex:0 0 24px!important}
body.dd-subject-study .dd-dialog .dd-bank-choice-icon svg{height:22px!important;width:22px!important}
body.dd-subject-study .dd-dialog .dd-bank-choice-copy b{font-size:13px!important;line-height:1.3!important;white-space:normal!important}
body.dd-subject-study .dd-dialog .dd-bank-choice-copy em{font-size:11px!important;min-height:0!important}
body.dd-subject-study .dd-dialog-special .dd-bank-choice-copy{display:block!important;white-space:normal!important;overflow:hidden!important}
body.dd-subject-study .dd-dialog-special .dd-bank-choice-copy b{white-space:normal!important;overflow-wrap:anywhere!important}
body.dd-subject-study .dd-dialog-special .dd-bank-choice-copy em{margin:2px 0 0!important}
/* Put the real slider immediately after 上一组; the status follows the slider. */
@media screen and (min-width:1180px){
 body.dd-ddesktop-windows .dd-v3-sheet-groups{grid-template-columns:auto minmax(110px,1fr) auto auto!important;gap:10px!important}
 body.dd-ddesktop-windows .dd-v3-group-prev{grid-column:1!important;grid-row:1!important}
 body.dd-ddesktop-windows .dd-v3-group-slider{grid-column:2!important;grid-row:1!important}
 body.dd-ddesktop-windows .dd-v3-group-status{grid-column:3!important;grid-row:1!important;text-align:right!important}
 body.dd-ddesktop-windows .dd-v3-group-next{grid-column:4!important;grid-row:1!important}
}
