/* Shared, keyboard-accessible disclosure headers throughout the console. */
:is(.console-shell,.public-site,.login-body) [hidden] { display: none !important; }
:is(.console-shell,.public-site,.login-body) details {
  border: 1px solid #365165;
  border-radius: 14px;
  background: linear-gradient(120deg, #172b39, #14232f 78%);
  overflow: hidden;
  margin-block: 14px;
}
:is(.console-shell,.public-site,.login-body) details.box { padding: 0; }
:is(.console-shell,.public-site,.login-body) details > summary {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 64px;
  padding: 17px 20px;
  margin: 0;
  list-style: none;
  color: #e2edf6;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.5;
  cursor: pointer;
  transition: background .18s ease;
}
:is(.console-shell,.public-site,.login-body) details > summary::-webkit-details-marker { display: none; }
:is(.console-shell,.public-site,.login-body) details > summary::marker { content: ''; }
:is(.console-shell,.public-site,.login-body) details > summary::before {
  content: '';
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border: 1px solid #477082;
  border-radius: 9px;
  background: #203d4c url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 20 20' fill='none' stroke='%2393e1e9' stroke-width='1.4' stroke-linecap='round'%3E%3Crect x='3' y='3.5' width='14' height='13' rx='2'/%3E%3Cpath d='M3 7.5h14M7 11h6M7 13.5h4'/%3E%3C/svg%3E") center / 20px no-repeat;
}
:is(.console-shell,.public-site,.login-body) details > summary::after {
  content: 'Открыть';
  margin-left: auto;
  flex: 0 0 auto;
  padding: 5px 10px;
  border: 1px solid #3b5b6e;
  border-radius: 7px;
  color: #9ebfd0;
  font-size: 11px;
  font-weight: 500;
}
:is(.console-shell,.public-site,.login-body) details > summary:hover { background: #203a4a; }
:is(.console-shell,.public-site,.login-body) details > summary:focus-visible {
  outline: 2px solid #87e2e8;
  outline-offset: -4px;
  border-radius: 12px;
}
:is(.console-shell,.public-site,.login-body) details[open] > summary {
  background: linear-gradient(110deg, #234151, #1a303e);
  border-bottom: 1px solid #365165;
}
:is(.console-shell,.public-site,.login-body) details[open] > summary::after { content: 'Свернуть'; color: #a7e5e9; }
:is(.console-shell,.public-site,.login-body) details > :not(summary) { margin-left: 20px; margin-right: 20px; }
:is(.console-shell,.public-site,.login-body) details > :last-child:not(summary) { margin-bottom: 20px; }
.console-shell .header-service-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}
.console-shell #header-plan { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.console-shell .current-plan {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 13px;
  min-height: 53px;
  border-radius: 11px;
  border: 1px solid #97652f;
  background: linear-gradient(120deg, #3b2d22, #25252a 85%);
  box-shadow: inset 0 1px #e6b75d20;
  color: #ffe0a6;
  cursor: default;
}
.current-plan .plan-mark { font-size: 23px; color: #ffc06b; line-height: 1; }
.current-plan small { display: block; font-size: 8px; letter-spacing: 1.1px; color: #c0a782; }
.current-plan b { display: block; font-size: 13px; line-height: 1.5; }
.current-plan .plan-term { font-size: 10px; margin-left: 6px; color: #d0bda1; }
.console-shell .current-plan.plan-free { background: #192b38; border-color: #416174; color: #d7e6f2; box-shadow: none; }
.plan-free .plan-mark { color: #9fc8dd; font-weight: 750; }
.plan-free small, .plan-free .plan-term { color: #91aabb; }
.console-shell .plan-upgrade {
  border: 1px solid #ffc26b;
  border-radius: 10px;
  padding: 12px 15px;
  background: linear-gradient(130deg, #ffb64b, #f49336);
  color: #2f1e12;
  font-size: 12px;
  font-weight: 700;
}
.console-shell .plan-upgrade:hover { background: #ffc772; }
@media (max-width: 1050px) {
  .console-shell main > header { flex-wrap: wrap; }
  .console-shell .header-service-meta { justify-content: flex-start; }
}
@media (max-width: 600px) {
  .console-shell details > summary { padding: 14px; gap: 10px; font-size: 12px; }
  .console-shell details > summary::after { padding: 4px 7px; font-size: 10px; }
  .console-shell .header-service-meta { width: 100%; gap: 9px; }
  .console-shell #header-plan { gap: 9px; }
  .console-shell .current-plan { padding: 8px 11px; }
  .console-shell .plan-upgrade { padding: 11px 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .console-shell details > summary { transition: none; }
}

/* Native file pickers keep their accessible input and filename display. */
:is(.public-site,.login-body) .faq details { padding: 0; }
:is(.console-shell,.public-site,.login-body) input[type="color"] {
  appearance: none;
  width: 100%;
  height: 50px;
  min-height: 50px;
  padding: 6px;
  border: 1px solid #47687b;
  border-radius: 10px;
  background: #142633;
  cursor: pointer;
}
input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 6px; }
input[type="color"]::-moz-color-swatch { border: 0; border-radius: 6px; }
:is(.console-shell,.public-site,.login-body) input[type="file"] {
  padding: 6px;
  min-width: 0;
  min-height: 52px;
  border: 1px solid #3b5b70;
  border-radius: 11px;
  background: #10232f;
  color: #9ab5c6;
  font: inherit;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
}
:is(.console-shell,.public-site,.login-body) input[type="file"]::file-selector-button {
  margin: 0 12px 0 0;
  padding: 10px 14px;
  border: 1px solid #e3a45b;
  border-radius: 8px;
  background: linear-gradient(135deg, #ffbb59, #f6963b);
  color: #2c1d10;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: inset 0 1px #ffe8c780;
}
:is(.console-shell,.public-site,.login-body) input[type="file"]:hover::file-selector-button { background: #ffc577; }
:is(.console-shell,.public-site,.login-body) input[type="file"]:focus-visible { outline: 2px solid #8ee4e7; outline-offset: 3px; }
:is(.console-shell,.public-site,.login-body) input[type="file"]:disabled { opacity: .55; }
:is(.console-shell,.public-site,.login-body) input[type="file"]:disabled::file-selector-button { cursor: not-allowed; }

.public-site .compare-mode-switch {
  display: inline-flex; align-items: center; gap: 12px;
  border: 1px solid #3f5b6f; border-radius: 12px;
  padding: 12px 15px; background: #142733; color: #c5dce9;
  font: inherit; font-size: 13px; cursor: pointer;
}
.compare-mode-switch .switch-track {
  display: inline-block; position: relative; width: 38px; height: 22px;
  border: 1px solid #527083; border-radius: 20px; background: #233c4c;
}
.compare-mode-switch .switch-track::before {
  content: ''; position: absolute; width: 14px; height: 14px;
  left: 3px; top: 3px; background: #99b6c8; border-radius: 50%;
  transition: transform .2s ease, background .2s ease;
}
.public-site .compare-mode-switch[aria-checked="true"] { border-color: #ecaa5b; background: #352b21; color: #ffe2ab; }
.compare-mode-switch[aria-checked="true"] .switch-track { background: #5d4223; border-color: #d39850; }
.compare-mode-switch[aria-checked="true"] .switch-track::before { transform: translateX(16px); background: #ffbe65; box-shadow: 0 0 10px #ffb84c60; }
.public-site .compare-filter-status { margin: 18px 0; color: #98bdce; font-size: 13px; }
.console-shell .section-command-list {
  padding: 17px 18px; border: 1px solid #416273; border-radius: 10px;
  background: linear-gradient(115deg, #1d3847, #142936);
}
.section-command-list p { line-height: 1.8; margin: 8px 0; }
.section-command-list a { color: #a8e9ec; font-size: 12px; }
.console-shell .platform-preview { min-width: 0; overflow: hidden; }
.console-shell .platform-preview>.eyebrow { margin: 0; padding: 16px 20px 0; overflow-wrap: anywhere; }
.console-shell .platform-preview>.inner { padding: 20px; min-width: 0; }
.console-shell .platform-preview h3,.console-shell .platform-preview p,.console-shell .platform-preview small { overflow-wrap: anywhere; }
.console-shell .welcome-uploads { align-items: stretch; }
.console-shell .welcome-uploads>label { display: flex; flex-direction: column; align-items: stretch; margin: 0; }
.console-shell .welcome-uploads>label>.muted { flex: 1; margin: 0 0 10px; }
.console-shell .welcome-uploads>label>button { align-self: flex-start; margin-top: auto; }
.reference-toolbar,.reference-heading,.reference-jump,.reference-card-title { display: flex; align-items: center; justify-content: space-between; gap: 15px; flex-wrap: wrap; }
.reference-toolbar { margin: 28px 0 18px; }
.reference-toolbar label { flex: 1 1 280px; }
.reference-toolbar input { display: block; width: 100%; margin-top: 9px; padding: 12px 15px; border: 1px solid #426277; border-radius: 10px; background: #102634; color: #e1eff8; font: inherit; font-size: 14px; }
.reference-toolbar input::placeholder { color: #8ba6ba; }
.reference-jump { justify-content: flex-start; margin-bottom: 24px; }
.reference-jump a { padding: 10px 15px; border: 1px solid #426176; border-radius: 9px; color: #a8e7eb; text-decoration: none; }
.reference-section { margin-top: 42px; scroll-margin-top: 25px; }
.premium-retention { margin: 22px 0; padding: 22px 25px; border: 1px solid #b48043; border-radius: 15px; background: linear-gradient(125deg,#38291d,#182a35); color: #efdbb4; }
.premium-retention h3 { margin: 0 0 13px; color: #ffd79b; font-size: 20px; }
.premium-retention p { line-height: 1.8; overflow-wrap: anywhere; font-size: 13px; }
.premium-retention .retention-countdown { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.premium-retention b[data-retention-deadline] { background: #101e2a; border: 1px solid #795b35; border-radius: 9px; padding: 8px 13px; font-variant-numeric: tabular-nums; color: #ffc978; font-size: 18px; }
.command-reference-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.command-reference-card { padding: 22px; background: #142331; border: 1px solid #385265; border-radius: 15px; min-width: 0; }
.reference-card-title code { font-size: 18px; color: #9ee4e9; overflow-wrap: anywhere; }
.reference-badge { border: 1px solid #425b73; padding: 5px 9px; border-radius: 7px; font-size: 10px; color: #b9ccdd; }
.reference-badge.owner { border-color: #a8753c; color: #ffcb85; }
.command-purpose { color: #bbcbd9; line-height: 1.8; font-size: 13px; }
.command-example { padding: 15px; background: #0d1b27; border: 1px solid #314e62; border-radius: 10px; }
.command-example small,.command-example code { display: block; margin-bottom: 11px; }
.command-example small { color: #8eaebf; font-size: 10px; }
.command-example code { color: #d6e9f5; overflow-wrap: anywhere; font-size: 12px; line-height: 1.8; user-select: all; }
.command-reference-card dt { font-size: 12px; margin-top: 12px; }
.command-reference-card dd { margin: 5px 0 14px; font-size: 12px; line-height: 1.7; color: #a5bacb; }
.reference-pending { font-size: 11px; color: #ffc57f; }
.legal-document { max-width: 960px; }
.legal-document section { margin-block: 30px; }
.legal-document section h2 { font-size: 22px; }
.legal-document section p { color: #b8cbd9; line-height: 1.9; }
.document-acceptance { padding: 24px; border: 1px solid #4c657b; border-radius: 13px; background: #172c39; }
.login-consent { width: min(760px,calc(100% - 28px)); max-height: calc(100dvh - 32px); padding: 0; border: 1px solid #547488; border-radius: 20px; background: #102331; color: #e0edf8; box-shadow: 0 30px 100px #0008; }
.login-consent::backdrop { background: #020b15ba; backdrop-filter: blur(5px); }
.login-consent { overflow: hidden; }
.login-consent form { padding: 25px; display: flex; flex-direction: column; max-height: calc(100dvh - 36px); box-sizing: border-box; }
.consent-heading,.consent-bottom { flex-shrink: 0; }
.consent-body { min-height: 0; overflow: auto; padding-right: 7px; scrollbar-width: thin; scrollbar-color: #50758a #102331; }
.consent-bottom { border-top: 1px solid #345368; padding-top: 8px; margin-top: 12px; }
.login-consent h2 { font-size: 26px; margin: 12px 0; }
.login-consent p { font-size: 13px; line-height: 1.8; color: #adc5d6; }
.consent-document { padding: 19px; border: 1px solid #395e75; border-radius: 12px; background: #152f3e; margin-block: 18px; }
.consent-document:first-child { margin-top: 6px; }.consent-document:last-child { margin-bottom: 6px; }
.consent-document h3 { font-size: 17px; }
.consent-document h4 { font-size: 14px; }
.consent-document a { font-size: 12px; color: #9be1e7; }
.consent-check { display: flex; gap: 12px; align-items: flex-start; margin-top: 18px; font-size: 12px; line-height: 1.8; cursor: pointer; }
.consent-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.login-consent .primary { padding: 12px 18px; border: 1px solid #ffc173; border-radius: 10px; background: #ffb14a; color: #2d1e12; font-weight: 700; }
.login-consent .primary:disabled { opacity: .45; cursor: not-allowed; }
@media(max-width:600px) { .login-consent form { padding: 17px; }.login-consent h2 { font-size: 22px; }.consent-document { padding: 14px; }.consent-actions { margin-top: 12px; justify-content: stretch; }.consent-actions button { flex: 1 1 auto; }.consent-bottom>p { margin: 5px 0; font-size: 11px; } }
@media(max-width:720px) { .command-reference-grid { grid-template-columns: 1fr; }.command-reference-card { padding: 17px; } }
@media print {
 .console-shell .sidebar,.console-shell main>header,.console-shell #notice,.console-shell [data-section-help] { display: none !important; }
 .console-shell main { margin: 0; padding: 0; }
 .command-reference { color: #111; padding: 0; }
 .site-nav,.site-footer,.release-note,.reference-toolbar,.reference-jump,.command-reference button { display: none !important; }
 .command-reference-grid { display: block; }.command-reference-card { break-inside: avoid; background: white; border: 1px solid #888; margin-bottom: 12px; color: #111; }
 .command-reference code,.command-purpose,.command-example small { color: #111; }.command-example { background: white; }
}
