/* Shared portal polish. Local assets only. */
:root { color-scheme: dark; }
* { scrollbar-width: thin; scrollbar-color: #526780 #0b1423; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: #0b1423; border-radius: 20px; }
*::-webkit-scrollbar-thumb { background: #526780; border: 2px solid #0b1423; border-radius: 20px; }
*::-webkit-scrollbar-thumb:hover { background: #8092ad; }
*::-webkit-scrollbar-corner { background: #0b1423; }

.portal-nav > div { align-items: center; }
.guest-badge {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 7px 12px; border: 1px solid #38516b; border-radius: 12px;
  background: linear-gradient(135deg, #142b3d, #101e33); color: #c7dce9;
  font-size: 12px; font-weight: 650; line-height: 1.2; white-space: nowrap;
  letter-spacing: .02em; box-shadow: inset 0 1px 0 #ffffff06;
}
.guest-mark { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: #70c3d114; color: #8dcbd8; }
.guest-mark svg { width: 17px; height: 17px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
html[dir=rtl] .guest-badge { letter-spacing: 0; }
.discord-icon { display: block; object-fit: contain; width: 24px; height: 18px; flex: 0 0 24px; }
.external-mark { font-size: 14px; opacity: .6; margin-inline-start: auto; line-height: 1; }
.discord-link { gap: 11px; border-color: #414b7d; background: linear-gradient(145deg, #1a2544, #131c32); color: #d7dfff; }
.discord-link:hover { background: #202e50; border-color: #707ef2; }
.discord-link .external-mark { margin-inline-start: 8px; }

.side { overscroll-behavior-y: contain; scrollbar-gutter: stable; padding: 18px 14px; gap: 5px; }
.side .nav, .side button.nav {
  display: flex; align-items: center; gap: 11px; min-height: 48px;
  padding: 12px 15px; font-size: 16px; font-weight: 550; line-height: 1.45; flex-shrink: 0;
}
.side a.nav, .side a.nav:visited, .side a.nav:hover, .side a.nav:focus {
  text-decoration: none !important; color: #c7d1e4;
}
.side a.nav { border: 1px solid transparent; outline-offset: 3px; }
.side a.nav:hover { background: #5865f215; border-color: #5865f244; color: #eef0ff; }
.side a.nav:focus-visible { outline: 2px solid #8290ff; }
.side .nav.on { background: linear-gradient(100deg, #44311677, #2c251d88); border-color: #a67d383e; color: #ffd275; }
.brand { min-height: 114px; padding: 4px 8px 18px; }
.brand img { width: 94px !important; height: 94px !important; }
.brand b { font-size: 22px; }
.brand small { line-height: 1.65; }
.side .srvname { line-height: 1.6; overflow-wrap: anywhere; }
.topbar { align-items: center; }
.uchip { border-color: #2d405c; background: linear-gradient(130deg, #15223a, #101a2e); }
.card { box-shadow: 0 8px 25px #0000000d; }
.card h2, .card h3 { letter-spacing: .1px; }
.row { transition: border-color .16s, background .16s; }
.row:hover { border-color: #344863; }
.btn { font-weight: 650; }
.btn:focus-visible { outline-color: #efc56b; }
.lnk .discord-icon { margin-inline-end: 2px; }

select {
  appearance: none; -webkit-appearance: none; min-height: 44px; padding-inline-end: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23b4c5dd' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 16px;
  border-color: #34465f; cursor: pointer;
}
html[dir=rtl] select { background-position: left 12px center; }
select option { background: #111e31; color: #e4ecfa; }
select:disabled { opacity: .5; cursor: not-allowed; }
details > summary { border-radius: 7px; }
details > summary:focus-visible { outline: 2px solid #718bc0; outline-offset: 5px; }
.j-dialog select { padding-inline-end: 38px; }
.j-dialog { scrollbar-gutter: stable; }
.permission-groups details { background: #0a142533; }
.permission-groups summary { font-size: 14px; font-weight: 600; }

@media(max-width:600px) {
  .portal-nav { gap: 16px; flex-wrap: wrap; }
  .portal-nav > div { flex: 1 1 240px; justify-content: flex-start; }
  .guest-badge { min-height: 37px; padding: 5px 9px; font-size: 12px; }
  .portal-nav .btn { min-height: 37px; }
  .portal-public footer { align-items: stretch; }
  .portal-public footer .discord-link { align-self: flex-start; }
  .side .nav, .side button.nav { font-size: 14px; min-height: 42px; padding: 10px 12px; }
  .side { padding: 12px; scrollbar-gutter: auto; }
  .j-dialog { scrollbar-gutter: auto; }
}

/* Discord application authentication */
.social-auth { margin: 0 0 16px; }
.discord-signin { width:100%;min-height:48px;gap:12px;background:linear-gradient(120deg,#242e59,#1d2845);border-color:#5865a6;color:#e9edff; }
.discord-signin:hover { border-color:#8c97f5;background:#2b3962; }
.social-auth small { display:block;text-align:center;color:#91a3bf;line-height:1.65;font-size:12px;margin:8px 0; }
.social-auth small:empty { display:none; }
.auth-divider { display:flex;align-items:center;gap:12px;color:#8293ad;font-size:12px;justify-content:center;margin:18px 0 0; }
.auth-divider::before,.auth-divider::after { content:'';height:1px;flex:1;background:#2a3c53; }

#loginBox .discord-signin .discord-icon { width:24px!important;height:18px!important;flex:0 0 24px;margin:0!important; }

/* Separate account and community options from server navigation. */
.owner-test-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:24px}.owner-test-heading h1{margin:14px 0 8px}.owner-test-heading p,.owner-test-controls p,.owner-test-link p{color:var(--sub);line-height:1.9}.owner-test-stats{margin-bottom:24px}.owner-test-ip{font-size:16px;margin-top:20px;overflow-wrap:anywhere}.owner-test-controls{margin-bottom:24px}.owner-test-actions{display:flex;flex-wrap:wrap;gap:12px;margin:20px 0}.owner-test-controls .config-sync{margin-bottom:0}.owner-test-link ol{padding-inline-start:24px;color:#c7d3e4;line-height:2.1}.owner-test-link small{display:block;color:var(--sub);line-height:1.8}.owner-test-stats .ok{color:var(--green,#40d7a0)}@media(max-width:700px){.owner-test-heading{align-items:flex-start}.owner-test-actions .btn{width:100%}.owner-test-heading h1{font-size:26px}}
.side > .sp { flex:1 0 24px;min-height:24px;margin-top:14px;border-top:1px solid #2b415d; }
@media(max-width:1000px) {
  .side > .sp { display:block;flex:0 0 100%;height:16px;min-height:16px;margin:8px 0 0; }
}

.bot-settings-form{display:grid;gap:18px}.bot-settings-form label{display:grid;gap:9px;font-size:14px}.bot-settings-form input:not([type=checkbox]),.bot-settings-form textarea{width:100%;padding:12px 14px;background:#0b1526;border:1px solid #314762;border-radius:10px;color:#edf3ff}.bot-settings-form input[type=checkbox]{width:24px;height:24px;accent-color:#eeb343}.bot-settings-form small,.private-status{color:#aabbd0;line-height:1.8}.config-json{direction:ltr;text-align:left;font-family:Consolas,monospace;min-height:160px}.card hr{border:0;border-top:1px solid #2b415c;margin:25px 0}.card>small{display:block;color:#9badc3;margin-top:16px;line-height:1.8}
