/* Denshub UI/UX Phase 7 — mobile-only popup styling, never overrides admin Body background. */
@media(max-width:575.98px){
  /* The original Bootstrap popup remains #exampleModal with the same AJAX opt-out. */
  body .modal-backdrop {z-index:2050!important;background:#010613!important;}
  body .modal-backdrop.show {opacity:.85!important;}
  body .modal.show,body .modal.fade {z-index:2060!important;}
  body #exampleModal.dhm-news-modal {padding:0!important;overflow-y:auto!important;}
  body #exampleModal .dhm-news-dialog {width:calc(100% - 22px)!important;max-width:450px!important;margin:12px auto!important;min-height:calc(100% - 24px);display:flex;align-items:center;top:30px;}
  body #exampleModal .dhm-news-panel {position:relative;width:100%;max-height:calc(100dvh - 28px);display:flex;flex-direction:column;background:linear-gradient(145deg,rgba(4,19,47,.98),rgba(2,8,21,.98) 78%)!important;border:1px solid #47b8ff!important;border-radius:18px!important;box-shadow:inset 0 0 0 1px rgba(174,255,43,.15),0 0 0 3px rgba(45,171,255,.12),0 18px 55px rgba(0,0,0,.9),0 0 22px rgba(7,94,211,.3)!important;overflow:hidden;color:#fff!important;animation:dhm-news-arrive .23s cubic-bezier(.2,.9,.2,1) both;}
  body #exampleModal .dhm-news-panel:before {content:"";position:absolute;top:0;left:17px;right:17px;height:2px;background:linear-gradient(90deg,transparent,#a4ff08,#51caff,transparent);pointer-events:none;}
  body #exampleModal .dhm-news-top {position:relative;flex:none;display:flex!important;justify-content:space-between;align-items:center;min-height:44px;padding:10px 14px 2px;}
  body #exampleModal .dhm-news-label {display:inline-flex;align-items:center;gap:7px;font-size:10px!important;font-weight:900;letter-spacing:.11em;color:#b9ff47;}
  body #exampleModal .dhm-news-label i {color:#7fd5ff;font-size:13px;}
  body #exampleModal .dhm-news-x {display:grid;place-items:center;width:29px;height:29px;border:1px solid rgba(143,208,255,.4);border-radius:9px;background:rgba(8,33,74,.75);color:#fff;font-size:13px;cursor:pointer;}
  body #exampleModal .dhm-news-body {min-height:0;overflow-y:auto!important;overscroll-behavior:contain;padding:4px 13px 12px!important;color:#f2f7ff!important;scrollbar-width:thin;scrollbar-color:#276dd3 transparent;}
  body #exampleModal .dhm-news-heading {font-size:16px!important;font-weight:900!important;line-height:1.25!important;color:#fff!important;margin:0 0 12px!important;text-align:left!important;}
  body #exampleModal .dhm-news-image-wrap {position:relative;margin:0 0 14px;border-radius:13px;overflow:hidden;border:1px solid rgba(103,200,255,.52);box-shadow:0 5px 17px rgba(0,0,0,.48);background:#021025;}
  body #exampleModal .dhm-news-image {display:block!important;width:100%!important;max-height:min(36dvh,330px)!important;height:auto!important;object-fit:contain!important;margin:0 auto!important;}
  body #exampleModal .dhm-news-copy {font-size:13px!important;line-height:1.55!important;color:#f1f7ff!important;overflow-wrap:anywhere;}
  body #exampleModal .dhm-news-copy h1,body #exampleModal .dhm-news-copy h2,body #exampleModal .dhm-news-copy h3,body #exampleModal .dhm-news-copy h4 {font-size:15px!important;font-weight:900!important;line-height:1.35!important;color:#fff!important;margin:10px 0!important;}
  body #exampleModal .dhm-news-copy p {margin:0 0 9px!important;font-size:13px!important;line-height:1.45!important;}
  body #exampleModal .dhm-news-copy a {color:#b8ff54!important;text-decoration:underline;text-underline-offset:3px;}
  body #exampleModal .dhm-news-actions {display:flex!important;flex:none;gap:8px;align-items:center;justify-content:space-between!important;padding:12px 13px calc(12px + env(safe-area-inset-bottom,0px))!important;border:0!important;border-top:1px solid rgba(102,177,255,.28)!important;background:rgba(1,8,23,.88);}
  body #exampleModal .dhm-news-optout {display:flex;align-items:center;gap:8px;min-width:0;margin:0!important;color:#e6f1ff!important;font-size:11px!important;font-weight:650;cursor:pointer;}
  body #exampleModal .dhm-news-optout input {appearance:auto!important;position:static!important;width:16px;height:16px;margin:0!important;accent-color:#a7ff00;flex:none;}
  body #exampleModal .dhm-news-dismiss {display:inline-flex;align-items:center;justify-content:center;gap:6px;min-width:90px;height:38px;padding:0 14px;border:0;border-radius:10px;background:linear-gradient(115deg,#afff11,#85ed00);box-shadow:inset 0 -2px 0 #4a8b00,0 3px 12px #64ce0033;color:#071c00!important;font-size:12px!important;font-weight:900;cursor:pointer;}
  body #exampleModal .dhm-news-dismiss:focus-visible,body #exampleModal .dhm-news-x:focus-visible {outline:2px solid white!important;outline-offset:2px;}

  /* 'LAINNYA' is a centered sheet, not the full-width legacy sidebar. */
  body .dhm-more-overlay {position:fixed;inset:0;display:flex;align-items:center;justify-content:center;padding:18px;z-index:1900!important;isolation:isolate;box-sizing:border-box;}
  body .dhm-more-overlay[hidden] {display:none!important;}
  body .dhm-more-shade {position:absolute;inset:0;background:rgba(0,5,15,.79);backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px);}
  body .dhm-more-panel {position:relative;width:min(100%,300px);max-height:calc(100dvh - 55px);overflow-y:auto;box-sizing:border-box;padding:16px 13px 15px;border:1px solid rgba(102,201,255,.55);border-radius:17px;background:linear-gradient(160deg,rgba(4,19,46,.98),rgba(0,8,22,.98));box-shadow:inset 0 1px 0 rgba(190,250,255,.16),0 20px 55px #000b,0 0 18px rgba(17,145,255,.3);animation:dhm-more-arrive .22s ease-out both;}
  body .dhm-more-head {display:flex;align-items:center;justify-content:center;min-height:27px;margin:0 0 12px;position:relative;}
  body .dhm-more-head h2 {font-size:15px!important;font-weight:900!important;color:#fff!important;line-height:25px!important;margin:0!important;text-align:center!important;letter-spacing:.02em;}
  body .dhm-more-close {position:absolute;top:-1px;right:0;width:25px;height:25px;display:grid;place-items:center;border:1px solid #a7c6d9;border-radius:7px;background:rgba(14,31,62,.72);color:#fff;font-size:12px;cursor:pointer;}
  body .dhm-more-links {display:grid;gap:9px;}
  body .dhm-more-link {display:grid;grid-template-columns:33px minmax(0,1fr) 9px;align-items:center;gap:9px;min-height:49px;padding:6px 10px!important;background:linear-gradient(95deg,rgba(0,13,36,.95),rgba(7,29,55,.86));border:1px solid rgba(231,243,255,.78);border-radius:9px;color:#f9fcff!important;text-decoration:none!important;box-shadow:inset 0 0 5px rgba(36,147,242,.16);}
  body .dhm-more-icon {display:grid;place-items:center;width:33px;height:33px;border-radius:9px;background:linear-gradient(135deg,#1164c7,#083477);color:#c8ff49;font-size:17px;}
  body .dhm-more-link-label {min-width:0;line-height:1.25;font-size:11px!important;font-weight:900!important;text-transform:uppercase;overflow-wrap:anywhere;}
  body .dhm-more-next {color:#99d0fa;font-size:9px!important;}
  body .dhm-more-link:focus-visible,body .dhm-more-close:focus-visible {outline:2px solid #9fff0d!important;outline-offset:2px;}
  body.dhm-more-open {overflow:hidden!important;}
  body .dhm-bottom-nav [data-dhm-more-trigger][aria-expanded="true"] {background:rgba(16,74,153,.6)!important;border-radius:12px;}
  @keyframes dhm-more-arrive{from{opacity:.6;transform:translateY(10px) scale(.96)}to{opacity:1;transform:translateY(0) scale(1)}}
  @keyframes dhm-news-arrive{from{opacity:.7;transform:scale(.97)}to{opacity:1;transform:scale(1)}}
  @media(prefers-reduced-motion:reduce){body .dhm-more-panel,body #exampleModal .dhm-news-panel{animation:none!important;}}
}
@media(min-width:576px){
  body .dhm-more-overlay{display:none!important;}
  /* Keep desktop behavior and original admin-selected background unchanged. */
}
