#terms-dialog { width:min(620px,calc(100% - 24px)); padding:20px 24px; max-height:90dvh; overflow:hidden; }
#terms-dialog[open] { display:flex; flex-direction:column; gap:16px; }
#terms-dialog .dialog-header { flex:none; gap:12px; background:var(--surface); }
#terms-dialog h2#terms-title { margin:0; font-size:20px; }
#terms-scroll { min-height:0; height:52dvh; overflow:auto; overscroll-behavior:contain; border:1px solid var(--line); border-radius:10px; padding:0 18px 20px; scrollbar-width:thin; }
#terms-scroll:focus-visible { outline:2px solid #cbbaff; outline-offset:2px; }
#terms-scroll h2 { font-size:15px; margin:22px 0 8px; line-height:1.6; }
#terms-scroll p,#terms-scroll li { font-size:12px; line-height:1.9; overflow-wrap:anywhere; }
#terms-scroll ul { padding-left:20px; }
#terms-scroll a { text-decoration:underline; text-underline-offset:3px; }
#terms-scroll .date { margin-top:16px; color:var(--muted); }
.terms-consent-footer { flex:none; }
#terms-read-status { margin:0 0 10px; font-size:11px; line-height:1.7; }
#terms-accept { width:100%; justify-content:center; min-height:48px; }
#terms-retry { margin-bottom:12px; min-height:36px; }
@media(max-width:600px) {
  #terms-dialog { padding:16px; max-height:94dvh; }
  #terms-scroll { height:55dvh; padding-inline:12px; }
}
