@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400 700;
  font-stretch: 100%;
  font-display: swap;
  src: url(fonts/Roboto-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400 700;
  font-stretch: 100%;
  font-display: swap;
  src: url(fonts/Roboto-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}/* Material Design 3: shared native HTML components and adaptive layouts.
   Semantic color roles come from material-tokens.css (Tonal Spot). */
:root{--ds-space-1:4px;--ds-space-2:8px;--ds-space-3:16px;--ds-space-4:24px;--ds-space-5:32px;--ds-control-height:48px;--ds-font:Roboto,system-ui,sans-serif;--ds-motion:160ms cubic-bezier(.2,0,0,1);--ds-shape-small:12px;--ds-shape-medium:16px;--ds-shape-large:24px;--ds-shape-dialog:28px;--ds-elevation:0 4px 24px #00000024;--bg:var(--md-sys-color-background);--surface:var(--md-sys-color-surface-container-low);--surface-raised:var(--md-sys-color-surface-container);--field:var(--md-sys-color-surface-container-highest);--line:var(--md-sys-color-outline-variant);--text:var(--md-sys-color-on-surface);--muted:var(--md-sys-color-on-surface-variant);--accent:var(--md-sys-color-primary);--hover:var(--md-sys-color-surface-container-high);--selected:var(--md-sys-color-secondary-container);--danger:var(--md-sys-color-error)}
html{color-scheme:light;scroll-padding-top:88px}html[data-theme=dark]{color-scheme:dark}@media(prefers-color-scheme:dark){html[data-theme=system]{color-scheme:dark}}
body{font-family:var(--ds-font);font-size:16px;line-height:1.5;--color-primary:var(--md-sys-color-primary);--color-on-primary:var(--md-sys-color-on-primary);--color-primary-container:var(--md-sys-color-primary-container);--color-on-primary-container:var(--md-sys-color-on-primary-container);--color-secondary:var(--md-sys-color-secondary);--color-on-secondary:var(--md-sys-color-on-secondary);--color-secondary-container:var(--md-sys-color-secondary-container);--color-on-secondary-container:var(--md-sys-color-on-secondary-container);--color-tertiary:var(--md-sys-color-tertiary);--color-background:var(--md-sys-color-background);--color-on-background:var(--md-sys-color-on-background);--color-surface:var(--md-sys-color-surface);--color-surface-container-low:var(--md-sys-color-surface-container-low);--color-surface-container:var(--md-sys-color-surface-container);--color-surface-container-high:var(--md-sys-color-surface-container-high);--color-surface-container-highest:var(--md-sys-color-surface-container-highest);--color-on-surface:var(--md-sys-color-on-surface);--color-on-surface-variant:var(--md-sys-color-on-surface-variant);--color-outline:var(--md-sys-color-outline);--color-outline-variant:var(--md-sys-color-outline-variant);--color-error:var(--md-sys-color-error);--color-error-container:var(--md-sys-color-error-container);--color-success:var(--md-sys-color-on-success-container);--color-success-container:var(--md-sys-color-success-container);--font-sans:var(--ds-font);--radius-xs:8px;--radius-sm:12px;--radius-md:16px;--radius-lg:24px;--radius-xl:28px;--shadow-1:none;--shadow-2:var(--ds-elevation)}
h1,h2,h3{font-weight:500;letter-spacing:0}h1{font-size:clamp(28px,3.2vw,36px);line-height:1.22}h2{font-size:24px;line-height:1.33}h3{font-size:18px;line-height:1.4}p{max-width:85ch}.eyebrow{font-size:12px;line-height:1.5;font-weight:500;letter-spacing:.4px;color:var(--muted)}
button,.button,.button-link{font:500 14px/20px var(--ds-font);letter-spacing:.1px;min-height:48px;border-radius:28px;padding:12px 24px;display:inline-flex;align-items:center;justify-content:center;gap:8px;vertical-align:middle;text-decoration:none;cursor:pointer;transition:background var(--ds-motion),box-shadow var(--ds-motion);border:1px solid var(--md-sys-color-outline);background:transparent;color:var(--md-sys-color-primary);touch-action:manipulation}
button:hover,.button:hover,.button-link:hover{background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container)}button:active,.button:active,.button-link:active{background:var(--md-sys-color-secondary-container);color:var(--md-sys-color-on-secondary-container)}
button.primary,.primary,.button--primary{background:var(--md-sys-color-primary);color:var(--md-sys-color-on-primary);border-color:transparent}.primary:hover,.button--primary:hover,button.primary:hover{background:color-mix(in srgb,var(--md-sys-color-on-primary) 8%,var(--md-sys-color-primary));color:var(--md-sys-color-on-primary);box-shadow:0 1px 3px #0003}
.button--secondary,.form-actions button:not(.primary),.dialog-actions button:first-child{background:var(--md-sys-color-secondary-container);color:var(--md-sys-color-on-secondary-container);border-color:transparent}.button--secondary:hover,.form-actions button:not(.primary):hover,.dialog-actions button:first-child:hover{background:color-mix(in srgb,var(--md-sys-color-on-secondary-container) 8%,var(--md-sys-color-secondary-container));color:var(--md-sys-color-on-secondary-container)}
.button--ghost{border-color:transparent;background:transparent;color:var(--md-sys-color-primary)}.danger{color:var(--md-sys-color-error);border-color:var(--md-sys-color-outline)}.danger:hover{color:var(--md-sys-color-on-error-container);background:var(--md-sys-color-error-container)}
button:disabled,.button:disabled,button[aria-disabled=true]{cursor:not-allowed;background:color-mix(in srgb,var(--md-sys-color-on-surface) 12%,transparent);color:color-mix(in srgb,var(--md-sys-color-on-surface) 38%,transparent);border-color:transparent;box-shadow:none}
button.icon-button,.icon-button{min-width:48px;min-height:48px;width:48px;height:48px;border-radius:50%;padding:12px;border:0;background:transparent;color:var(--md-sys-color-on-surface-variant)}.icon-button:hover{background:var(--md-sys-color-surface-container-highest);color:var(--md-sys-color-on-surface);transform:none}.material-icon{fill:currentColor;flex:none;vertical-align:middle}.icon-button .material-icon{width:24px;height:24px}.with-icon{gap:8px}
:where(a,button,input,textarea,select,summary,[tabindex]):focus-visible{outline:3px solid var(--md-sys-color-primary);outline-offset:3px;box-shadow:none}input:focus-visible,select:focus-visible,textarea:focus-visible{outline-offset:0}
label{font-size:14px;line-height:20px;color:var(--md-sys-color-on-surface-variant)}input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea,.field input,.field textarea,.field select,.role-form select{font:400 16px/24px var(--ds-font);width:100%;min-width:0;min-height:56px;background:var(--md-sys-color-surface);color:var(--md-sys-color-on-surface);border:1px solid var(--md-sys-color-outline);border-radius:12px;padding:14px 16px;box-shadow:none}
input::placeholder,textarea::placeholder{color:var(--md-sys-color-on-surface-variant);opacity:1}.field input:focus,.field textarea:focus,.field select:focus,.role-form select:focus{outline:2px solid var(--md-sys-color-primary);outline-offset:-2px;box-shadow:none;background:var(--md-sys-color-surface)}input:disabled,select:disabled,textarea:disabled{opacity:.5;cursor:not-allowed}
:where(input,textarea,select)[aria-invalid=true]{outline:2px solid var(--md-sys-color-error);outline-offset:-2px}.field-error{display:block;color:var(--md-sys-color-error);font-size:12px;line-height:18px;margin-top:6px}.field-error .material-icon{width:16px;height:16px;margin-right:6px}
input[type=checkbox],input[type=radio]{accent-color:var(--md-sys-color-primary);width:20px;height:20px;min-height:20px;flex:none}.toggle,.checkbox-line,.overview-preference-row label{min-height:48px;cursor:pointer}.nav__link:focus-visible{outline:3px solid var(--md-sys-color-primary);outline-offset:-3px}
section{border:1px solid var(--md-sys-color-outline-variant);border-radius:24px;background:var(--md-sys-color-surface-container-low);padding:24px;box-shadow:none}pre,.json-editor{border-radius:12px;background:var(--md-sys-color-surface-container-high);font-family:ui-monospace,Consolas,monospace}details>summary{min-height:48px;display:flex;align-items:center;gap:12px;cursor:pointer;padding:12px 4px}summary::before{content:'›';font-size:24px;line-height:20px;transition:transform var(--ds-motion);flex:none}details[open]>summary::before{transform:rotate(90deg)}
::selection{background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container)}[hidden]{display:none!important}
/* Administration scaffold. Expanded drawer on wide screens, modal drawer below. */
.admin-view .topbar,.auth-view .topbar{height:64px;padding:0 24px;border:0;background:var(--md-sys-color-surface-container);color:var(--md-sys-color-on-surface)}.brand strong{font-size:18px;font-weight:500}.brand small,.node-context{color:var(--md-sys-color-on-surface-variant)}.brand-mark{width:40px;height:40px;border-radius:12px;background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container)}.topbar-actions button{height:48px;color:var(--md-sys-color-on-surface-variant);background:transparent}.topbar-actions button:hover{background:var(--md-sys-color-surface-container-highest)}.node-context{border-color:var(--md-sys-color-outline-variant)}
main.app-shell{grid-template-columns:280px minmax(0,1fr);gap:24px;padding:0 32px 32px 0}.side-nav{width:280px;top:64px;min-height:calc(100dvh - 64px);background:var(--md-sys-color-background);padding:24px 12px}.nav-caption{padding:0 16px 16px;font-size:12px;font-weight:500}.side-nav a,.drawer-nav a{min-height:56px;padding:16px;border:0;border-radius:28px;margin:2px 0;font-size:14px;font-weight:500;color:var(--md-sys-color-on-surface-variant)}.side-nav a[aria-current=page],.drawer-nav a[aria-current=page]{border:0;background:var(--md-sys-color-secondary-container);color:var(--md-sys-color-on-secondary-container);font-weight:600}.side-nav a:hover,.drawer-nav a:hover{background:var(--md-sys-color-surface-container-high)}.side-nav a .material-icon,.drawer-nav a .material-icon{width:24px;height:24px}.nav-note{margin:24px 16px 0;padding-top:16px;font-size:12px;line-height:1.5}
.page-content{padding-top:32px}.page-heading{gap:16px;margin-bottom:24px}.page-heading h1{font-size:32px;font-weight:500}.page-heading p{font-size:14px;line-height:1.5}.page-heading button{min-height:48px}.heading-count{background:var(--md-sys-color-secondary-container);color:var(--md-sys-color-on-secondary-container);padding:4px 12px;font-size:14px;font-weight:500}
.kpis{gap:16px}.kpis>div{border:0;padding:16px!important;background:var(--md-sys-color-surface-container);border-radius:16px}.kpis strong{font-size:36px;font-weight:400}.kpis span{font-size:14px}.node-card,.incoming-card,.outbound,.service-card,.subscription-option{border-radius:16px;background:var(--md-sys-color-surface-container);padding:20px}.user-columns{background:transparent;padding-block:12px;font-size:12px;color:var(--muted)}.user-card{padding:20px 16px;border-radius:12px;font-size:14px;transition:background var(--ds-motion)}.user-card:hover,.user-card:focus-within{background:var(--md-sys-color-surface-container)}.user-card h3{font-size:16px;font-weight:500}.user-head{min-width:0}.badge,.audit-state,.status-tag{font-size:12px;font-weight:500;line-height:18px;border-radius:8px;padding:4px 10px}.badge.online,.audit-state.ok,.status--live{background:var(--md-sys-color-success-container);color:var(--md-sys-color-on-success-container)}.badge.disabled,.audit-state.failed{background:var(--md-sys-color-error-container);color:var(--md-sys-color-on-error-container)}.badge:not(.online):not(.disabled){background:var(--md-sys-color-surface-container-highest);color:var(--md-sys-color-on-surface-variant)}
.user-query{align-items:end;gap:12px}.user-query input,.user-query select{height:56px}.user-query button{margin-bottom:4px}.filter-context{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;margin-bottom:16px}.filter-context .list-caption{margin:0}.filter-reset{font-size:14px;margin:0;min-height:48px;display:inline-flex;align-items:center;gap:8px;padding:8px 12px;border-radius:24px}.search-hint{font-size:12px;color:var(--muted);margin:8px 0}.search-hint kbd{border:1px solid var(--line);padding:0 5px;border-radius:4px;font-family:inherit}.pagination a{min-height:48px;border-radius:24px}.empty-state{padding:32px 16px;text-align:center;border-radius:16px;background:var(--md-sys-color-surface-container)}
.detail-tabs,.route-tabs{gap:0;border-bottom:1px solid var(--line);padding:0 4px}.detail-tabs button,.route-tabs button{min-height:48px;border:0;border-bottom:3px solid transparent;border-radius:0;padding:12px 16px;background:transparent;color:var(--muted)}.detail-tabs button:hover,.route-tabs button:hover{background:var(--md-sys-color-surface-container-high);color:var(--text)}.detail-tabs button[aria-selected=true],.route-tabs button[aria-selected=true]{border-bottom-color:var(--accent);background:transparent;color:var(--accent)}
/* Dialogs keep native focus management; actions no longer form a solid slab. */
dialog{border:0;border-radius:28px;padding:24px;background:var(--md-sys-color-surface-container-high);color:var(--text);box-shadow:var(--ds-elevation);max-height:calc(100dvh - 32px);scroll-padding-bottom:96px}dialog::backdrop{background:#0009}dialog h2{font-size:24px;font-weight:400}.form-actions,.configuration-dialog .form-actions{display:flex;justify-content:flex-end;gap:8px;padding:16px 24px;border-top:1px solid var(--line);border-radius:0 0 28px 28px;margin:24px -24px -24px;bottom:-24px;background:var(--md-sys-color-surface-container-high)}.form-actions button{min-height:48px;padding:12px 24px;border-radius:28px;flex:none}.dialog-actions{gap:8px;padding-top:16px}.mobile-navigation{inset:0 auto 0 0;margin:0;width:320px;max-width:calc(100vw - 40px);height:100dvh;max-height:100dvh;border-radius:0 28px 28px 0;padding:16px;background:var(--md-sys-color-surface-container-low)}.mobile-navigation-close{border:0;border-radius:28px;min-height:56px;padding:12px 16px;justify-content:space-between}.drawer-nav{padding:16px 0}.drawer-nav .nav-note{padding:16px 0}
.info-banner,.danger-note,.change-note{border:0;border-radius:12px;padding:16px 16px 16px 48px;background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container);font-size:14px}.danger-note{background:var(--md-sys-color-error-container);color:var(--md-sys-color-on-error-container)}.change-note{background:var(--md-sys-color-warning-container);color:var(--md-sys-color-on-warning-container)}.info-banner p,.danger-note p,.change-note p{color:inherit}.icon-tooltip{border-radius:8px;background:var(--md-sys-color-inverse-surface);color:var(--md-sys-color-inverse-on-surface);font-size:12px;padding:8px 12px}
.health-grid meter::-webkit-meter-bar{border-radius:8px}.health-grid meter::-webkit-meter-optimum-value,.usage-fill,.chart-row i{background:var(--md-sys-color-primary);border-radius:8px}.usage>div,.chart-track{border-radius:8px;background:var(--md-sys-color-surface-container-highest)}.history-chart{background:var(--md-sys-color-surface-container);border-radius:12px 12px 0 0}.history-up,.chart-legend span:before{background:var(--md-sys-color-tertiary)}.chart-legend span:nth-child(2):before{background:var(--md-sys-color-primary)}.table-scroll{border-radius:12px}.history-table th,.history-table td{min-height:48px;height:48px}.history-table thead th{background:var(--md-sys-color-surface-container-highest)}
.auth-view .login-shell{max-width:560px;padding-top:64px}.login{padding:32px;border-radius:28px}.login h1{font-size:32px;font-weight:500}.login p{font-size:16px}.login label{margin-top:24px}.auth-icon{color:var(--md-sys-color-primary)}
/* Learning: same colors, shapes and type roles, with more room for reading. */
.learning-view .topbar{min-height:64px;background:var(--md-sys-color-surface-container);border:0}.learning-view .topbar__inner{min-height:64px}.learning-view .brand__mark{border-radius:12px;background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container)}.learning-view .nav__link{border-radius:24px;min-height:48px;display:inline-flex;align-items:center}.learning-view .hero h1{font-size:clamp(36px,5vw,56px);line-height:1.12;font-weight:500;letter-spacing:-.5px}.learning-view .hero .lead{font-size:18px;line-height:1.55}.learning-view .start-path,.learning-view .catalog-search,.learning-view .course-card,.learning-view .auth-card,.learning-view .settings-head,.learning-view .settings-group{border-radius:24px}.learning-view .choice-card{min-height:96px;border-radius:16px}.learning-view .choice-card:has(input:checked){background:var(--md-sys-color-secondary-container);color:var(--md-sys-color-on-secondary-container);border-color:var(--md-sys-color-primary)}.learning-view .choice-card:has(input:focus-visible){outline:3px solid var(--md-sys-color-primary);outline-offset:3px}.learning-view .notice--error{background:var(--md-sys-color-error-container);color:var(--md-sys-color-on-error-container)}.learning-view .reading-content{font-size:18px;line-height:1.7}.learning-view .progress-track span{background:var(--md-sys-color-primary)}.learning-view .question-card{border-radius:20px}.learning-view .answer-option{min-height:56px;border-radius:16px}.learning-view .role-chip,.learning-view .status{border-radius:8px}.learning-view .field span{font-weight:500;font-size:14px}.learning-view .field input,.learning-view .field select{min-height:56px}.learning-view .auth-card .button--wide{margin-top:8px}
/* Shared ergonomics. No secrets or draft values are stored in the browser. */
.password-control{display:flex;align-items:stretch;position:relative;gap:8px;min-width:0;margin-top:8px}.password-control input{flex:1;width:100%;margin:0;padding-right:100px!important}.password-control .password-toggle{position:absolute;right:4px;top:4px;bottom:4px;min-height:48px;min-width:88px;border:0;border-radius:10px;padding:8px 12px;font-size:12px;background:transparent;color:var(--md-sys-color-primary)}.password-control .password-toggle:hover{background:var(--md-sys-color-primary-container)}.password-control input[disabled]+button{display:none}.connection-notice{position:sticky;top:64px;z-index:9;margin:0;padding:12px 24px;background:var(--md-sys-color-warning-container);color:var(--md-sys-color-on-warning-container);font-size:14px}.submit-status{color:var(--muted);font-size:14px;min-height:20px}.learning-view .password-control{margin-top:0}.learning-view .password-control input{padding-top:14px;padding-bottom:14px}.password-control:has(input:focus-visible){z-index:1}
/* Subscription: primary import action first; technical formats stay folded. */
.subscription-view{min-height:100vh}.subscription-view .topbar{height:auto;min-height:80px;max-width:none;padding:16px max(24px,calc((100% - 1080px)/2));border:0;background:var(--md-sys-color-surface-container);color:var(--text);gap:16px}.subscription-view .brand{display:block;font-size:18px;font-weight:500}.subscription-view .brand small{display:block;font-size:12px;font-weight:400;color:var(--muted);overflow-wrap:anywhere}.subscription-shell{max-width:1128px;padding:48px 24px;margin:auto}.subscription-intro{margin-bottom:32px}.subscription-intro h1{font-size:clamp(32px,4vw,44px);font-weight:500}.subscription-intro p{max-width:64ch;font-size:16px}.subscription-grid{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,1fr);gap:24px}.subscription-grid section{margin:0;min-width:0;padding:28px;border:0;border-radius:28px;background:var(--md-sys-color-surface-container-low)}.subscription-grid h2{margin-top:0;font-size:24px}.subscription-grid .wide{grid-column:1/-1}.subscription-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px;margin:24px 0 0}.subscription-facts dt{font-size:12px;color:var(--muted)}.subscription-facts dd{margin:8px 0 0;font-size:16px;overflow-wrap:anywhere}.subscription-view .status-tag{display:inline-flex;align-items:center;gap:8px;background:var(--md-sys-color-success-container);color:var(--md-sys-color-on-success-container)}.subscription-link{overflow-wrap:anywhere;font-size:13px;background:var(--md-sys-color-surface-container-highest);padding:16px;border-radius:12px;user-select:all}.subscription-view .row{align-items:center;margin-top:16px;gap:12px}.subscription-view .row a{margin:0}.subscription-view .button-link{min-height:48px;padding:12px 20px}.subscription-view .button-link:not(.primary):hover{background:var(--md-sys-color-primary-container);color:var(--md-sys-color-on-primary-container)}.subscription-view .primary:hover{color:var(--md-sys-color-on-primary)}.subscription-view details{border-top:1px solid var(--line);padding:0}.subscription-view summary{font-size:16px;padding:16px 0}.subscription-view li{padding:6px 0;color:var(--muted)}.subscription-view #subscription-qr{display:block;max-width:min(100%,280px);height:auto;border:16px solid white;border-radius:12px;margin:24px auto}.subscription-view #copy-status{min-height:24px}.subscription-view footer{max-width:1128px}.subscription-view .muted{color:var(--muted)}
.skip-link{position:fixed;top:-100px;left:16px;z-index:1000;background:var(--md-sys-color-inverse-surface);color:var(--md-sys-color-inverse-on-surface);padding:12px 20px;border-radius:24px;text-decoration:none}.skip-link:focus{top:8px}
@media(max-width:1056px){.has-mobile-navigation .side-nav{display:none}.has-mobile-navigation main.app-shell{display:block;padding:0 24px 24px}.has-mobile-navigation .nav-toggle{display:inline-flex;align-items:center;justify-content:center;width:48px;min-height:48px;margin-right:8px}.has-mobile-navigation .brand{flex:1;min-width:0}.has-mobile-navigation .brand-mark{display:none}}
@media(max-width:760px){body{font-size:16px}.admin-view .topbar,.auth-view .topbar{padding:0 8px;height:64px;gap:4px}.brand strong{font-size:16px}.brand small{font-size:12px}.topbar-actions .icon-button{padding:12px;min-width:48px;min-height:48px;width:48px;height:48px}.has-mobile-navigation main.app-shell{padding:0 16px 24px}.page-content{padding-top:24px}.page-heading h1{font-size:28px}.page-heading p{font-size:14px}.page-heading .page-actions{justify-content:flex-start;flex-wrap:wrap}.page-heading button{font-size:14px}.page-heading>button{margin-left:0}.page-heading .primary{width:100%;min-height:48px}section{padding:20px;border-radius:20px}.user-card{padding:20px 12px;margin:8px 0;border-radius:16px;border:1px solid var(--line);background:var(--md-sys-color-surface)}.user-actions button{min-height:48px;padding:12px 16px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.kpis strong{font-size:28px}.kpis span{font-size:12px}.user-query button{width:100%}.form-actions button{padding:12px 16px;flex:1}.filter-context{gap:8px}.search-hint{display:none}.mobile-navigation-close{min-height:56px}.user-dialog .detail-tabs button{padding:12px 8px;font-size:14px}.overview-preference-row button{min-width:48px;min-height:48px}.connection-notice{padding:12px 16px}.learning-view .nav{gap:4px;flex-wrap:wrap}.learning-view .topbar__inner{padding-block:8px}.learning-view .reading-content{font-size:17px}.learning-view .page{padding-top:24px}}
@media(max-width:700px){.subscription-shell{padding:32px 16px}.subscription-grid{grid-template-columns:minmax(0,1fr)}.subscription-grid .wide{grid-column:auto}.subscription-grid section{padding:24px;border-radius:24px}.subscription-view .topbar{padding:16px;min-height:80px}.subscription-view .row>*{flex:1 1 100%;text-align:center}.subscription-facts{gap:20px}.subscription-intro h1{font-size:32px}.subscription-view #subscription-theme{padding:12px 16px;flex:none;white-space:nowrap}}
@media(max-width:600px){.user-dialog,.configuration-dialog,.route-rule-dialog,#outbound-editor,#inbound-editor{width:100%;max-width:100vw;max-height:calc(100dvh - 16px);margin:auto 0 0;border-radius:28px 28px 0 0;padding:24px}.user-dialog .form-actions,.configuration-dialog .form-actions,.route-rule-dialog .form-actions,#outbound-editor .form-actions,#inbound-editor .form-actions{margin:24px -24px -24px;bottom:-24px;border-radius:0}.auth-view .login-shell{padding:32px 16px}.login{padding:24px}.subscription-view .brand{min-width:0}.learning-view .catalog-search{padding:16px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;animation:none!important;transition:none!important}}
@media(forced-colors:active){button,.button,.button-link,input,select,textarea{border:1px solid ButtonText}.badge,.status-tag,.choice-card:has(input:checked){border:1px solid CanvasText}.side-nav a[aria-current=page]{outline:2px solid Highlight}.material-icon{fill:currentColor}}

.topbar .icon-button,.has-mobile-navigation .topbar .nav-toggle{color:var(--md-sys-color-on-surface-variant)}.topbar .icon-button:hover{background:var(--md-sys-color-surface-container-highest);color:var(--md-sys-color-on-surface)}.topbar .icon-button:focus-visible{outline-color:var(--md-sys-color-primary)}

.toolbar .toolbar-field{display:grid;gap:8px;margin:0;min-width:0;font-size:14px}.toolbar-field input,.toolbar-field select{margin:0}button.with-icon{display:inline-flex;padding:12px 24px;justify-content:center;gap:8px;min-width:0}button.with-icon>.material-icon{position:static;transform:none;order:-1;width:20px;height:20px}
@media(max-width:600px){dialog .form-actions{padding-bottom:calc(16px + env(safe-area-inset-bottom,0px))}.mobile-navigation{padding-bottom:calc(16px + env(safe-area-inset-bottom,0px))}.subscription-shell{padding-bottom:calc(32px + env(safe-area-inset-bottom,0px))}}

.learning-view .choice-card small{opacity:1;color:var(--md-sys-color-on-surface-variant)}.learning-view .choice-card:has(input:checked) small{color:var(--md-sys-color-on-secondary-container);opacity:1}

/* Touch targets must survive the more specific legacy layout selectors. */
.page-heading button,.subscription-option-actions button,.pagination a{min-height:48px}
@media(max-width:600px){.subscription-option-actions{flex-wrap:wrap}.subscription-option-actions button{flex:1 1 auto}.create-dialog{width:100%;max-width:100vw;margin:auto 0 0;border-radius:28px 28px 0 0}.form-actions{flex-wrap:wrap}.form-actions button{white-space:normal;overflow-wrap:anywhere}.route-rule-dialog .route-grid{grid-template-columns:minmax(0,1fr)}}

#action-confirm-message{white-space:pre-line}#action-confirm-review,.operations-result{overflow-wrap:anywhere}#action-confirm-review th,#action-confirm-review td,#compare-result th,#compare-result td{white-space:normal;overflow-wrap:anywhere;min-width:100px;padding:12px}#diagnostics-result article{padding:16px 0}#diagnostics-result h3{font-size:18px}#restore-result p,#compare-result p{overflow-wrap:anywhere}.audit-state.pending{background:var(--md-sys-color-warning-container);color:var(--md-sys-color-on-warning-container)}

/* Subscription: the first screen contains access and connection actions. */
.subscription-compact .topbar{min-height:56px;padding:8px max(16px,calc((100% - 640px)/2));gap:12px}
.subscription-compact .brand{font-size:14px;line-height:18px;min-width:0}
.subscription-compact .brand small{font-size:12px;line-height:16px}
.subscription-compact #subscription-theme{min-height:44px;padding:8px 12px;font-size:12px;white-space:nowrap}
.subscription-compact .subscription-shell{max-width:672px;padding:12px 16px calc(16px + env(safe-area-inset-bottom,0px))}
.subscription-compact .subscription-grid{grid-template-columns:minmax(0,1fr);gap:10px}
.subscription-compact .subscription-grid section{padding:12px 16px;border-radius:20px}
.subscription-card-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}
.subscription-compact .subscription-card-heading h1,.subscription-compact .subscription-card-heading h2{font-size:20px;line-height:26px;margin:0;font-weight:500;min-width:0}
.subscription-compact .status-tag{padding:3px 8px;flex:none}
.subscription-compact .subscription-facts{margin:10px 0;gap:12px}
.subscription-compact .subscription-facts dd{font-size:14px;line-height:20px;margin:2px 0 0}
.subscription-compact .subscription-hint{font-size:12px;color:var(--muted);margin:8px 0 0}
.subscription-compact .row{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}
.subscription-compact .row>*{flex:1 1 0;min-width:0;text-align:center}
.subscription-compact .button-link,.subscription-compact .row button{min-height:44px;line-height:20px;padding:12px 10px;font-size:14px;justify-content:center}
.subscription-compact summary{min-height:44px;padding:10px 0;font-size:14px;line-height:24px}
.subscription-compact .subscription-other{margin-top:8px}
.subscription-compact #copy-status{min-height:0;margin:0;font-size:13px;overflow-wrap:anywhere}
.subscription-compact #copy-status:not(:empty){margin-top:8px}
.subscription-compact .subscription-other>details{padding-left:12px}
.subscription-compact details p{font-size:13px;line-height:1.5;margin:8px 0}
.subscription-compact .subscription-link{padding:10px}
.subscription-compact .subscription-telegram .button-link{margin:0}
.subscription-compact .subscription-web-details{margin-top:8px}
.subscription-compact .subscription-more{border:0;border-radius:16px;background:var(--md-sys-color-surface-container-low);padding:0 16px}
.subscription-compact .subscription-more-content{padding-bottom:12px}
.subscription-compact .subscription-more-content h2{font-size:18px;margin:8px 0}
.subscription-compact #subscription-qr{margin:12px auto}
.subscription-compact .subscription-more li{font-size:13px;overflow-wrap:anywhere}
.subscription-compact .subscription-more ul{padding-left:18px}
.subscription-compact input{min-width:0;max-width:100%}
@media(max-width:360px){.subscription-compact .subscription-shell{padding-left:10px;padding-right:10px}.subscription-compact .subscription-grid section{padding-left:12px;padding-right:12px}.subscription-compact .subscription-card-heading h1,.subscription-compact .subscription-card-heading h2{font-size:18px}}

.subscription-compact .subscription-measured{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

.subscription-view #subscription-theme.subscription-theme-icon{width:44px;height:44px;min-width:44px;min-height:44px;padding:10px;display:inline-flex;align-items:center;justify-content:center;flex:none;border:0;background:transparent;border-radius:50%}
.subscription-view #subscription-theme:hover{background:var(--md-sys-color-surface-container-highest)}
.subscription-theme-icon .theme-sun,html[data-theme="dark"] .subscription-theme-icon .theme-moon{display:none}
html[data-theme="dark"] .subscription-theme-icon .theme-sun{display:block}

/* Compact administration: fewer decorative rows, unchanged controls and warnings. */
.admin-view .page-content{padding-top:16px}
.admin-view .page-heading{margin-bottom:12px;gap:10px}
.admin-view .page-heading h1{font-size:26px;line-height:1.2;margin:4px 0}
.admin-view section{padding:16px;margin-bottom:12px;border-radius:18px}
.admin-view h2{font-size:20px;margin:0 0 12px}
.admin-view h3{font-size:16px}
.admin-view p{font-size:14px;line-height:1.45;margin:8px 0}
.admin-view p:empty{margin:0}
.admin-view label{margin:12px 0;font-size:13px}
.admin-view .settings-grid{gap:14px}
.admin-view .settings-grid label{margin:0}
.admin-view .settings-grid small{margin-top:4px;font-size:12px;line-height:17px}
.admin-view input:not([type=checkbox]):not([type=radio]):not([type=hidden]),.admin-view select{min-height:48px;padding:10px 12px;margin-top:4px;font-size:16px}
.admin-view textarea{padding:10px 12px;font-size:15px}
.admin-view .toolbar{gap:10px;margin-bottom:10px}
.admin-view .toolbar label{margin:0}
.admin-view .user-query input,.admin-view .user-query select{height:48px}
.admin-view .user-query button{margin-bottom:0}
.admin-view .filter-context{margin-bottom:8px;gap:8px}
.admin-view .user-card{min-height:72px;padding:12px;gap:12px}
.admin-view[data-density=compact] .user-card{min-height:60px;padding:8px 12px}
.admin-view .user-card h3{font-size:15px}
.admin-view .user-actions button{padding:8px;min-height:44px}
.admin-view .badge{padding:2px 7px;font-size:11px}
.admin-view .service-grid,.admin-view .node-grid{gap:10px}
.admin-view .service-card,.admin-view .outbound,.admin-view .node-card{padding:12px;border-radius:14px}
.admin-view .connection-facts{margin:10px 0;gap:4px 10px}
.admin-view .info-banner,.admin-view .danger-note,.admin-view .change-note{padding:10px 12px 10px 40px;margin-bottom:12px;font-size:13px}
.admin-view .info-banner .material-icon,.admin-view .danger-note .material-icon{left:12px}
.admin-view .route-tabs,.admin-view .detail-tabs{margin:0 0 12px}
.admin-view .route-tabs button,.admin-view .detail-tabs button{padding:10px 12px;min-height:44px;font-size:13px}
.admin-view summary{min-height:44px;padding:10px 0;font-size:14px}
.admin-view .panel-fold{border:0;padding:0}
.admin-view .panel-fold>summary{font-size:18px;font-weight:500}
.admin-view [data-overview-block=health]{padding-block:4px}
.admin-view .kpis{gap:8px}
.admin-view .kpis>div{padding:10px!important;border-radius:12px}
.admin-view .kpis strong{font-size:28px;margin-bottom:0}
.admin-view .kpis span{font-size:12px}
.admin-view .health-grid label{margin:8px 0}
.admin-view .history-chart{height:160px;margin-top:12px}
.admin-view .chart{margin-top:12px;gap:10px}
.admin-view .shortcut-list a{min-height:48px;padding:10px 0}
.admin-view .outbound-heading{margin-bottom:12px}
.admin-view .outbound-add,.admin-view .quick-route{padding:12px;margin:12px 0}
.admin-view .route-toolbar{margin:12px 0;gap:8px}
.admin-view .subscription-options{grid-template-columns:1fr;gap:10px;margin-bottom:12px}
.admin-view .user-dialog .subscription-option{min-height:0;padding:12px;gap:6px}
.admin-view .user-dialog .detail-pane{min-height:0}
.admin-view .profile-summary{margin:6px 0 12px;font-size:13px}
.admin-view .detail-pane>p{margin:8px 0}
.admin-view .subscription-option-actions{padding-top:4px;margin-top:0}
.admin-view .profile-actions{gap:6px;background:transparent;border:0}
.admin-view .profile-actions form{border-radius:12px;background:transparent}
.admin-view .profile-actions button{min-height:44px;padding:10px 12px;font-size:13px}
.admin-view .user-dialog #credential-viewer{margin-top:12px;padding-top:12px}
.admin-view .telegram-status{display:grid;grid-template-columns:minmax(100px,.7fr) minmax(0,1fr);gap:4px 12px;margin:12px 0;font-size:13px}
.admin-view .telegram-status dd{margin:0;overflow-wrap:anywhere}
.admin-view #telegram-settings-form .settings-grid{margin-bottom:12px}
.admin-view .audit-entry{padding-block:10px}
.admin-view .page-heading .icon-button{min-width:44px;min-height:44px;width:44px;height:44px;padding:10px}
@media(max-width:760px){
 .admin-view .topbar{height:56px}
 .admin-view .topbar .icon-button{width:44px;height:44px;min-width:44px;min-height:44px;padding:10px}
 .admin-view .brand small{display:none}
 .admin-view .brand strong{font-size:14px}
 .admin-view .topbar-actions{gap:0}
 .admin-view.has-mobile-navigation main.app-shell{padding:0 12px 16px}
 .admin-view .page-content{padding-top:12px}
 .admin-view .page-heading{flex-wrap:wrap;align-items:center;gap:8px}
 .admin-view .page-heading>div:first-child{flex:1 1 150px}
 .admin-view .page-heading>.page-actions{width:auto;flex:0 0 auto;justify-content:flex-end;gap:4px}
 .admin-view .page-heading h1{font-size:23px;overflow-wrap:anywhere}
 .admin-view .page-heading>button{width:auto;min-height:44px;padding:10px 12px;margin:0}
 .admin-view .page-heading .page-actions button{min-height:44px;padding:10px 12px}
 .admin-view .page-heading .page-actions .icon-button{padding:10px}
 .admin-view section{padding:12px;border-radius:16px}
 .admin-view .settings-grid{gap:12px}
 .admin-view .user-query{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;gap:8px;align-items:end}
 .admin-view .user-query .toolbar-field:first-child{grid-column:1/3;grid-row:1}
 .admin-view .user-query>button{grid-column:3;grid-row:1;padding:10px 12px;min-height:48px}
 .admin-view .user-query .toolbar-field:nth-child(2){grid-column:1;grid-row:2}
 .admin-view .user-query .toolbar-field:nth-child(3){grid-column:2/4;grid-row:2}
 .admin-view .user-card{margin:6px 0;padding:10px;min-height:0}
 .admin-view .user-head{gap:8px;flex-wrap:nowrap}
 .admin-view .user-head .user-identity{min-width:0;gap:4px}
 .admin-view .user-head .user-actions{display:flex;gap:2px;flex:0 0 auto;margin-left:0}
 .admin-view .user-actions button{padding:8px 6px;min-height:44px}
 .admin-view .usage{margin-top:8px}
 .admin-view .user-meta{margin-top:4px}
 .admin-view .usage>div{margin-bottom:4px}
 .admin-view .pagination{gap:8px}
 .admin-view .pagination form{gap:8px}
 .admin-view .pagination>span{flex-basis:auto}
 .admin-view .kpis{gap:8px}
 .admin-view .history-chart{height:128px}
 .admin-view #overview-blocks .toolbar{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .admin-view #overview-blocks .toolbar label:first-child{grid-column:1/-1}
 .admin-view .user-dialog,.admin-view .configuration-dialog,.admin-view .route-rule-dialog,.admin-view #inbound-editor{padding:16px;max-height:calc(100dvh - 12px)}
 .admin-view dialog h2{font-size:21px}
 .admin-view dialog .form-actions{padding:12px 16px;margin:16px -16px -16px;bottom:-16px}
 .admin-view .form-actions button{padding:10px 14px;min-height:44px}
 .admin-view .password-toggle{min-height:48px}
 .admin-view .routing-policy{padding:12px}
 .admin-view .route-builder{gap:8px}
 .admin-view #route-rules .row>button{min-height:44px}
}
.admin-view .settings-section-picker{display:none}
@media(max-width:760px){
 .admin-view .brand small{display:block;font-size:11px;line-height:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:180px}
 .admin-view .brand{overflow:hidden}
 .admin-view .user-card{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px 8px}
 .admin-view .user-head{display:contents}
 .admin-view .user-head .user-identity{grid-column:1;grid-row:1}
 .admin-view .user-head .user-actions{grid-column:2;grid-row:1}
 .admin-view .usage{grid-column:1/-1;grid-row:2;margin:0}
 .admin-view .limit-value{display:inline}
 .admin-view .user-meta{grid-column:1/-1;grid-row:3;display:flex;justify-content:space-between;gap:4px 12px;flex-wrap:wrap;margin:0;font-size:12px}
 .admin-view .user-meta>span{min-width:0;overflow-wrap:anywhere}
 .admin-view #settings-save .row{display:flex;gap:8px}
 .admin-view #settings-save .row>button{flex:1;min-width:0;width:auto;padding:10px 12px;min-height:44px}
 .admin-view .settings-section-picker{display:block;margin:0 0 12px}
 .admin-view #settings-tabs.has-section-picker{display:none}
}
.admin-view .usage p{margin:0}
.admin-view .user-query{grid-template-columns:minmax(160px,2fr) minmax(250px,2fr) auto}
.admin-view .user-filters{padding:0;border:0;min-width:0}
.admin-view .user-filters>summary{display:none}
.admin-view .user-filter-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
@media(max-width:760px){
 .admin-view .user-query{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto}
 .admin-view .user-query .user-filters{grid-column:1/-1;grid-row:2}
 .admin-view .user-filters>summary{display:flex;padding:6px 0;min-height:44px}
 .admin-view .user-filter-fields{gap:8px}
 .admin-view .user-query .user-filter-fields .toolbar-field{grid-column:auto;grid-row:auto}
}
.private-qr-image{image-rendering:pixelated;max-width:100%;height:auto}
@media(max-width:760px){
 .admin-view .create-dialog{padding:16px}
 .admin-view #inbound-editor .form-actions,.admin-view #outbound-editor .form-actions,.admin-view .route-rule-dialog .form-actions,.admin-view .create-dialog .form-actions{margin:16px -16px -16px;bottom:-16px;padding:12px 16px}
}
