/* Mobile controls remain readable without changing print layouts or board rules. */
@media screen and (max-width:900px){
  input:not([type=range]):not([type=checkbox]):not([type=radio]),select,textarea{font-size:16px!important;max-width:100%;box-sizing:border-box}
  .btn,.btn-action,.btn-mini,.btn-primary,.btn-secondary,.tab-btn,.nav-tab,.card-btn,.arcade-mode,.enhanced-tool,.arcade-filter-chip,.filter-chip,.theme-btn,.brush-btn,#selectFilesBtn,#btnPauseTimer,#btn-pause,#btnCloseHint,#btnBackToYinYang{min-height:44px;touch-action:manipulation}
  .btn.mini,.enhanced-tool,#btnPauseTimer,#btn-pause,#btnCloseHint{min-width:44px}
  .header-inner{flex-wrap:wrap;gap:10px;max-width:100%;box-sizing:border-box}
  .brand-wrap{min-width:0;flex:1 1 180px}
  .nav-tabs,.nav-tabs-wrapper{order:3;flex:1 1 100%;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;max-width:100%;overflow:visible;box-sizing:border-box}
  .nav-tabs .tab-btn,.nav-tabs-wrapper button{white-space:normal;min-width:0;margin:0;line-height:1.4;padding:8px}
  .arcade-filter-bar,.filter-nav{display:flex;flex-wrap:wrap;overflow:visible;gap:8px}
  .arcade-filter-chip,.filter-chip{max-width:100%;white-space:normal;line-height:1.4}
  .enhanced-tools{gap:6px}.enhanced-tool{padding:8px;line-height:1.4}
  .mobile-board-help{margin:8px 0;padding:10px;border-radius:8px;background:#eaf3ff;color:#24486a;font-size:14px;line-height:1.5}
  .mobile-board-help[hidden]{display:none}
  .logic-frogs{flex-wrap:nowrap;justify-content:flex-start;overflow-x:auto;max-width:100%;box-sizing:border-box;overscroll-behavior-x:contain}
  .logic-frog{flex-shrink:0}
  .btn-theme-preset{min-height:44px;touch-action:manipulation}
  .app-container button{min-height:44px;touch-action:manipulation}
  .file-row,.photo-card,.file-info{min-width:0;overflow-wrap:anywhere}
  .modal,.modal-overlay{padding:12px;box-sizing:border-box}.modal-content{max-width:100%;max-height:calc(100dvh - 24px);overflow:auto;box-sizing:border-box}
}
@media print{.mobile-board-help{display:none!important}}
