/* "Read and agree" modal (consent.js). Uses the site colour tokens from style.css, with fallbacks so it also works on its own. */
.hgc{position:fixed;inset:0;z-index:120;display:flex;align-items:center;justify-content:center;padding:16px;font-family:Kanit,system-ui,sans-serif}
.hgc-bg{position:absolute;inset:0;background:rgba(5,6,14,.72);backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px)}
.hgc-card{position:relative;width:100%;max-width:560px;max-height:calc(100dvh - 32px);display:flex;flex-direction:column;gap:12px;padding:20px;border-radius:var(--r,18px);background:var(--bg2,#12152a);color:var(--text,#f1f3fb);border:1px solid var(--line2,rgba(255,255,255,.14));box-shadow:var(--shadow,0 12px 34px rgba(0,0,0,.45));animation:hgc-in .2s ease-out}
.hgc h2{margin:0;font-size:20px;line-height:1.35}
.hgc-sub{margin:0;color:var(--mute,#9aa2c4);font-size:14px;line-height:1.5}
.hgc-box{flex:1 1 auto;min-height:140px;max-height:46vh;overflow-y:auto;overscroll-behavior:contain;padding:12px 16px;border-radius:12px;background:var(--card,#171b33);border:1px solid var(--line,rgba(255,255,255,.08));font-size:14.5px;line-height:1.65}
.hgc-box:focus-visible{outline:2px solid var(--acc,#ffa53d);outline-offset:2px}
.hgc-box ol{margin:0;padding-left:20px}
.hgc-box li{margin:0 0 8px}
.hgc-box b{color:var(--text,#f1f3fb)}
.hgc-box p{margin:10px 0 0;color:var(--mute,#9aa2c4);font-size:13.5px}
.hgc-links{display:flex;flex-wrap:wrap;gap:4px 12px;margin:10px 0 2px;padding:0;list-style:none;font-size:13.5px}
.hgc-links li{margin:0}
.hgc a{color:var(--acc,#ffa53d)}
.hgc-hint{margin:0;font-size:13px;color:var(--acc,#ffa53d);text-align:center;transition:opacity .2s}
.hgc-hint[hidden]{display:block;visibility:hidden;opacity:0}
.hgc-chk{display:flex;gap:10px;align-items:flex-start;font-size:14px;line-height:1.5;cursor:pointer}
.hgc-chk input{flex:0 0 auto;width:20px;height:20px;margin:1px 0 0;accent-color:var(--acc,#ffa53d);cursor:pointer}
.hgc-chk.off{opacity:.5;cursor:not-allowed}
.hgc-chk.off input{cursor:not-allowed}
.hgc-row{display:flex;gap:10px;justify-content:flex-end}
.hgc-btn{font:inherit;font-weight:600;font-size:15px;border-radius:12px;padding:10px 18px;border:1px solid var(--line2,rgba(255,255,255,.14));background:transparent;color:var(--text,#f1f3fb);cursor:pointer;min-height:44px}
.hgc-ok{flex:1 1 auto;border:0;background:var(--grad,linear-gradient(135deg,#ffcf6b,#ff8a3d 55%,#ff4f7b));color:#2a1000}
.hgc-btn:disabled{opacity:.4;cursor:not-allowed;filter:grayscale(.5)}
.hgc-btn:focus-visible{outline:2px solid var(--acc,#ffa53d);outline-offset:2px}
html.hgc-lock,html.hgc-lock body{overflow:hidden}
@keyframes hgc-in{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}
@media (max-width:480px){.hgc{padding:10px;align-items:flex-end}.hgc-card{padding:16px;max-height:calc(100dvh - 20px)}.hgc-box{max-height:50vh}}
@media (prefers-reduced-motion:reduce){.hgc-card{animation:none}}
/* light theme: the site sets html[data-theme=light]; pages without the site script follow the device */
html[data-theme=light] .hgc-bg{background:rgba(20,24,60,.45)}
html[data-theme=light] .hgc-card{background:var(--bg2,#fff);color:var(--text,#151935)}
@media (prefers-color-scheme:light){html:not([data-theme]) .hgc-bg{background:rgba(20,24,60,.45)}html:not([data-theme]) .hgc-card{background:#fff;color:#151935;border-color:rgba(22,26,60,.16)}html:not([data-theme]) .hgc-box{background:#eef0f7;border-color:rgba(22,26,60,.09)}html:not([data-theme]) .hgc-box b{color:#151935}html:not([data-theme]) .hgc-sub,html:not([data-theme]) .hgc-box p{color:#5d6488}html:not([data-theme]) .hgc-btn{color:#151935;border-color:rgba(22,26,60,.16)}html:not([data-theme]) .hgc-ok{color:#2a1000}html:not([data-theme]) .hgc a,html:not([data-theme]) .hgc-hint{color:#c45f12}}
