:root {
  --navy: #0f2a4a;
  --navy-dark: #0a1d33;
  --blue: #1c6fd6;
  --blue-dark: #14539f;
  --paper: #f5f7fa;
  --line: #dde3ea;
  --text: #1e2733;
  --muted: #6b7684;
  --accent: #e8a33d;
  --ok: #2f9e5b;
  --radius: 10px;
  --font-ui: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --fns-blue: #0054a6;
  --z-sticky-nav: 1000;
  --z-modal: 1100;
  --z-modal-top: 1200;
  --z-admin: 1300;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
}

html.settings-loading {
  background: var(--paper);
}

html.settings-loading body {
  visibility: hidden;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  border: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 3px solid rgba(28, 111, 214, 0.35);
  outline-offset: 2px;
}

.audience-bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 29px;
  padding: 0 28px;
  background: var(--fns-blue);
  color: #fff;
  font-size: 12px;
}

.audience-bar .tabs {
  display: flex;
  gap: 15px;
  min-width: 0;
}

.audience-bar a {
  display: inline-flex;
  align-items: center;
  min-height: 29px;
  padding: 0 8px;
  color: #fff;
  opacity: 0.8;
  white-space: nowrap;
}

.audience-bar a.active,
.audience-bar a:hover {
  opacity: 1;
  font-weight: 600;
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 92px;
  padding: 19px 30px;
  background: #fff;
}

.logo-block {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.logo-block img {
  width: 54px;
  height: 54px;
  object-fit: contain;
  flex: 0 0 auto;
}

.logo-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.logo-title {
  margin: 0;
  color: var(--fns-blue);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.25;
  text-transform: uppercase;
}

.logo-sub {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 280px;
  min-height: 40px;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}

.search-box svg {
  width: 18px;
  height: 18px;
  color: #99a5b5;
  flex: 0 0 auto;
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 14px;
}

.search-box input::placeholder {
  color: #99a5b5;
  opacity: 1;
}

.nav-main {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky-nav);
  display: flex;
  min-height: 53px;
  padding: 0 30px;
  overflow-x: auto;
  border-top: 2px solid var(--fns-blue);
  border-bottom: 1px solid var(--line);
  background: #fff;
  font-size: 14px;
  scrollbar-width: thin;
}

.nav-main a {
  display: flex;
  align-items: center;
  padding: 0 19px;
  margin-bottom: -1px;
  border-bottom: 3px solid transparent;
  color: var(--navy-dark);
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, opacity 0.2s;
}

.nav-main a.active {
  border-bottom-color: var(--fns-blue);
  background: #eaf2fb;
  color: var(--fns-blue);
}

.nav-main a:hover:not(.active):not(.disabled) {
  color: var(--fns-blue);
}

.nav-main a.disabled {
  opacity: 0.4;
  cursor: default;
}

.nav-main a.nav-static,
.nav-main a.nav-static:hover {
  color: var(--navy-dark);
  cursor: default;
}

.nav-main a.admin-entry {
  margin-left: auto;
  color: var(--blue-dark);
}

.news-ticker {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 9px 30px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.news-badge {
  margin-right: 16px;
  padding: 4px 12px;
  border-radius: 4px;
  background: var(--fns-blue);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.news-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.news-date {
  color: #99a5b5;
  font-size: 13px;
  white-space: nowrap;
}

main {
  width: 100%;
  max-width: 970px;
  margin: 0 auto;
  padding: 39px 24px 80px;
  flex: 1;
}

.layout-2col {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 248px;
  gap: 28px;
  align-items: start;
}

.left-col {
  display: flex;
  flex-direction: column;
}

.breadcrumb {
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 13px;
}

h1.page-title {
  margin: 0 0 12px;
  color: var(--navy-dark);
  font-size: 28px;
  font-weight: 700;
  line-height: 1.32;
}

.page-sub {
  max-width: 100%;
  margin: 0 0 24px;
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
}

.card {
  position: relative;
  z-index: 1;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.action-card {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
  padding: 40px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 480px;
  min-height: 52px;
  padding: 14px 22px;
  border-radius: 4px;
  background: var(--blue);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  background: var(--blue-dark);
}

.btn:active {
  transform: translateY(1px);
}

.btn svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.8;
}

.tiles {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 0;
}

.tile {
  display: flex;
  flex: 1 1 calc(33.333% - 12px);
  align-items: center;
  gap: 12px;
  min-width: 180px;
  min-height: 68px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.tile-wide {
  flex-basis: 100%;
}

.tile:hover {
  border-color: var(--blue);
  background: #f9fbfd;
}

.tile .icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: var(--blue);
}

.tile .icon svg,
.activity-card svg {
  width: 20px;
  height: 20px;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.sidebar-stack {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

aside.info-box {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  font-size: 14px;
}

aside.info-box h3 {
  margin: 0 0 12px;
  color: var(--navy-dark);
  font-size: 14px;
}

aside.info-box h3.bordered-title {
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--blue-dark);
}

aside.info-box ul.arrow-list {
  margin: 0;
  padding-left: 0;
  color: var(--muted);
  list-style: none;
}

aside.info-box ul.arrow-list li {
  position: relative;
  margin-bottom: 12px;
  padding-left: 20px;
  font-size: 13.5px;
}

aside.info-box ul.arrow-list li:last-child {
  margin-bottom: 0;
}

aside.info-box ul.arrow-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--blue);
  font-weight: 700;
}

.notice-box {
  border: 0 !important;
  background: #f0f5fc !important;
}

.notice-box p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.news-list {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 20px;
}

.news-item {
  padding: 20px 24px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.news-item:hover {
  border-color: var(--blue);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.news-item-date {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  color: #99a5b5;
  font-size: 13px;
  font-weight: 600;
}

.news-item-title {
  margin: 0 0 10px;
  color: var(--blue-dark);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
}

.news-item-desc {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
  text-align: justify;
}

.activity-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.activity-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 180px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.activity-card:hover {
  border-color: var(--blue);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.activity-card .icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 8px;
  border-radius: 8px;
  background: #eaf2fb;
  color: var(--fns-blue);
  font-weight: 700;
}

.activity-card .icon-wrap svg {
  width: 24px;
  height: 24px;
}

.activity-card h3 {
  margin: 0;
  color: var(--navy-dark);
  font-size: 16px;
  line-height: 1.35;
}

.activity-card p {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}

.bottom-white-field {
  position: fixed;
  bottom: 0;
  left: 0;
  z-index: 10;
  width: 100%;
  height: 40vh;
  border-radius: 20px 20px 0 0;
  background: #fff;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1);
  pointer-events: none;
}

.spa-page {
  display: none;
}

.spa-page.active {
  display: block;
}

.demo-only-card {
  max-width: 620px;
}

.demo-only-card h2 {
  margin: 0 0 10px;
  color: var(--navy-dark);
  font-size: 20px;
}

.demo-only-card p {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 14px;
}

.modal-open {
  overflow: hidden;
}

.admin-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-admin);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 16px;
  overflow: auto;
  background: rgba(10, 29, 51, 0.62);
}

.admin-overlay[hidden],
.admin-gate[hidden],
.admin-workspace[hidden] {
  display: none;
}

.admin-shell {
  position: relative;
  width: min(1180px, 100%);
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 24px;
  border-radius: 12px;
  background: var(--paper);
  box-shadow: 0 14px 40px rgba(10, 29, 51, 0.28);
}

.admin-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--navy-dark);
  cursor: pointer;
}

.admin-close svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
}

.admin-gate {
  max-width: 440px;
  margin: 80px auto;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-login-form {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.admin-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
  padding-right: 48px;
}

.admin-header h3 {
  margin: 0 0 8px;
  color: var(--navy-dark);
  font-size: 24px;
  line-height: 1.2;
}

.admin-header-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.admin-header .page-sub {
  max-width: 72ch;
  margin-bottom: 0;
}

.admin-status {
  flex: 0 0 auto;
  padding: 7px 11px;
  border: 1px solid #bfd7f4;
  border-radius: 999px;
  background: #eaf2fb;
  color: var(--blue-dark);
  font-size: 12px;
  font-weight: 700;
}

.admin-status.saved {
  border-color: #b7dfc8;
  background: #edf8f1;
  color: #277247;
}

.admin-status.error {
  border-color: #f0c3bd;
  background: #fff1ef;
  color: #a33a2f;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.admin-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-panel-wide {
  grid-column: 1 / -1;
}

.panel-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.panel-title h2 {
  margin: 0;
  color: var(--navy-dark);
  font-size: 16px;
  line-height: 1.3;
}

.panel-title span,
.field-hint {
  color: var(--muted);
  font-size: 12px;
}

.admin-field {
  display: grid;
  gap: 7px;
  color: var(--navy-dark);
  font-size: 13px;
  font-weight: 700;
}

.admin-field input,
.admin-field textarea,
.json-box {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfe;
  color: var(--text);
  font-size: 14px;
  line-height: 1.45;
  outline: 0;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.admin-field input {
  min-height: 40px;
  padding: 9px 11px;
}

.admin-toggle-field {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  cursor: pointer;
}

.admin-toggle-field input[type="checkbox"] {
  width: 20px;
  min-height: 20px;
  height: 20px;
  padding: 0;
  justify-self: end;
  accent-color: var(--blue);
  cursor: pointer;
}

.admin-logo-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfe;
}

.admin-logo-preview {
  width: 54px;
  height: 54px;
  object-fit: contain;
  flex: 0 0 auto;
}

.admin-field textarea,
.json-box {
  min-height: 92px;
  resize: vertical;
  padding: 10px 11px;
}

.json-box {
  min-height: 150px;
  font-family: Consolas, "Courier New", monospace;
  font-size: 12px;
}

.admin-field input:focus,
.admin-field textarea:focus,
.json-box:focus {
  border-color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(28, 111, 214, 0.14);
}

.field-hint {
  margin: -2px 0 0;
  line-height: 1.5;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-actions .btn {
  width: auto;
  max-width: none;
  min-height: 42px;
  padding: 10px 16px;
}

.secondary-button,
.danger-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 14px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.secondary-button {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--blue-dark);
}

.secondary-button:hover {
  border-color: var(--blue);
  background: #f7fbff;
}

.danger-button {
  border: 1px solid #ecc5c0;
  background: #fff;
  color: #a33a2f;
}

.danger-button:hover {
  border-color: #d66d62;
  background: #fff4f2;
}

.client-panel-title {
  align-items: center;
}

.client-panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.client-filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--navy-dark);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.client-filter-toggle input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--blue);
}

.client-summary {
  padding: 10px 12px;
  border: 1px solid #bfd7f4;
  border-radius: 6px;
  background: #f3f8ff;
  color: var(--blue-dark);
  font-size: 13px;
  font-weight: 700;
}

.client-session-list {
  display: grid;
  gap: 12px;
}

.client-session-list-limited {
  max-height: 860px;
  overflow-y: auto;
  padding-right: 4px;
  overscroll-behavior: contain;
}

.client-session-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfe;
}

.client-session-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--navy-dark);
}

.client-session-head strong {
  font-size: 15px;
}

.client-session-head span {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.client-session-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.client-session-grid span {
  min-width: 0;
  padding: 8px 9px;
  border-radius: 5px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
}

.client-session-grid b {
  color: var(--navy-dark);
  font-weight: 700;
}

.client-session-grid-compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  width: 100%;
  max-width: 420px;
  padding: 32px 24px;
  border-radius: 12px;
  background: #fff;
  text-align: center;
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.22);
}

.modal-content h3 {
  margin: 0 0 16px;
  color: var(--navy-dark);
  font-size: 20px;
}

.modal-content p {
  margin: 0 0 20px;
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
}

.support-list {
  display: grid;
  gap: 8px;
  margin: 0 0 20px;
  padding: 18px 14px;
  border-radius: 8px;
  background: #f4f8fc;
  color: var(--navy-dark);
}

.support-list button {
  width: 100%;
  min-height: 34px;
  border-radius: 4px;
  background: transparent;
  color: var(--navy-dark);
  font-size: 20px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}

.support-list button:hover {
  background: #eaf2fb;
}

.modal-content .btn {
  max-width: none;
  min-height: 44px;
  padding: 12px;
  font-size: 14px;
}

.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal-top);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(244, 247, 251, 0.97);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.auth-overlay.active {
  opacity: 1;
  visibility: visible;
}

.auth-flow {
  position: relative;
  width: min(100%, 430px);
}

.auth-step {
  display: none;
}

.auth-step.active {
  display: block;
}

.auth-step-loading {
  padding: 28px 0;
}

.auth-card {
  width: min(100%, 380px);
  margin: 0 auto;
  padding: 30px 28px 26px;
  border: 1px solid #d5dde7;
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.auth-close {
  position: absolute;
  top: -42px;
  right: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: transparent;
  color: #6b7684;
  cursor: pointer;
}

.auth-close:hover {
  background: #f1f5fa;
  color: var(--navy-dark);
}

.auth-close svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.auth-card h3 {
  margin: 0 0 10px;
  color: #001b44;
  font-size: 18px;
  line-height: 1.25;
}

.auth-card > p {
  margin: 0 0 18px;
  color: #556579;
  font-size: 13px;
  line-height: 1.45;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-phone-field {
  display: block;
}

.auth-phone-input {
  width: 100%;
  height: 52px;
  padding: 0 18px;
  border: 1px solid #d5dde7;
  border-radius: 8px;
  background: #fff;
  color: #172235;
  font-size: 18px;
  line-height: 52px;
  text-align: center;
  letter-spacing: 0;
}

.auth-phone-input::placeholder {
  color: #53657c;
  opacity: 1;
}

.auth-phone-input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(28, 111, 214, 0.16);
  outline: 0;
}

.auth-phone-input[aria-invalid="true"] {
  border-color: #c73e35;
  box-shadow: 0 0 0 3px rgba(199, 62, 53, 0.12);
}

.auth-error {
  margin: -6px 0 0;
  color: #b42318;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
}

.contact-consent {
  display: grid;
  gap: 7px;
  padding: 10px 12px;
  border: 1px solid #d7e1ee;
  border-radius: 8px;
  background: #f7faff;
  color: #33445b;
  text-align: left;
}

.contact-consent[hidden] {
  display: none;
}

.contact-consent .consent-line {
  display: block;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 700;
}

.contact-consent p {
  margin: 0;
  color: #64758a;
  font-size: 12px;
  line-height: 1.35;
}

.contact-consent .auth-error {
  margin: 0;
  color: #b42318;
  font-size: 12px;
}

.auth-form .btn {
  width: 100%;
  max-width: none;
  min-height: 46px;
  margin-top: 2px;
  padding: 12px 16px;
}

.auth-safe-note {
  margin: -2px 0 0;
  color: #657489;
  font-size: 12px;
  line-height: 1.35;
}

.auth-loader {
  width: min(100%, 390px);
  margin: 0 auto;
  text-align: center;
}

.auth-loader h3 {
  margin: 0 0 28px;
  color: #001b44;
  font-size: 20px;
  line-height: 1.25;
}

.auth-progress {
  width: 100%;
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: #dce4ed;
}

.auth-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #005bad;
  transition: width 0.25s ease;
}

.auth-loader strong {
  display: block;
  margin-top: 28px;
  color: #001b44;
  font-size: 16px;
}

.auth-step-code {
  width: min(100%, 380px);
  margin: 0 auto;
}

.demo-code-card,
.code-entry-card {
  width: 100%;
  border: 1px solid #d5dde7;
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.demo-code-card {
  margin-bottom: 18px;
  padding: 20px 20px;
  border-color: #f0a32e;
  background: #fff8e8;
}

.demo-code-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  margin-bottom: 12px;
  padding: 3px 12px;
  border-radius: 999px;
  background: #eca536;
  color: #1d2430;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.demo-code-card p,
.code-entry-card p {
  margin: 0;
  color: #1f2a3a;
  font-size: 14px;
}

.demo-code-value {
  margin-top: 2px;
  padding: 12px 16px;
  border: 1px dashed #d5dde7;
  border-radius: 8px;
  background: #f8fbff;
  color: #001b44;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: 0.2em;
  line-height: 1.25;
}

.code-entry-card {
  padding: 28px;
}

.code-entry-card h3 {
  margin: 0 0 12px;
  color: #001b44;
  font-size: 18px;
}

.code-entry-card > p {
  margin-bottom: 16px;
  color: #556579;
  font-size: 13px;
}

.code-form {
  display: grid;
  gap: 12px;
}

.code-field {
  display: block;
}

.code-input {
  width: 100%;
  height: 56px;
  padding: 0 18px;
  border: 1px solid #d5dde7;
  border-radius: 8px;
  background: #fff;
  color: #172235;
  font-size: 22px;
  line-height: 56px;
  letter-spacing: 0.35em;
  text-align: center;
}

.code-input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(28, 111, 214, 0.16);
  outline: 0;
}

.code-input[aria-invalid="true"] {
  border-color: #c73e35;
  box-shadow: 0 0 0 3px rgba(199, 62, 53, 0.12);
}

.code-error {
  text-align: center;
}

.code-timer {
  margin: 0 0 24px;
  color: #657489;
  font-size: 13px;
}

.code-form .btn {
  width: 100%;
  max-width: none;
  min-height: 46px;
  padding: 12px 16px;
}

.auth-step-security {
  width: min(100%, 650px);
  margin: 0 auto;
}

.security-alert-card {
  width: 100%;
  padding: 30px;
  border: 1px solid #d5dde7;
  border-radius: 8px;
  background: #fff;
}

.security-alert-header {
  display: flex;
  align-items: center;
  gap: 18px;
}

.security-alert-icon {
  flex: 0 0 auto;
  width: 50px;
  height: 50px;
  fill: none;
  stroke: #005bad;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.security-alert-header h3 {
  margin: 0 0 4px;
  color: #001b44;
  font-size: 21px;
  line-height: 1.25;
}

.security-alert-header p {
  margin: 0;
  color: #005bad;
  font-size: 15px;
  font-weight: 700;
}

.security-alert-divider {
  height: 1px;
  margin: 22px 0 24px;
  background: #d5dde7;
}

.security-alert-body {
  color: #0b1728;
  font-size: 15px;
  line-height: 1.55;
}

.security-alert-body p {
  margin: 0 0 14px;
}

.security-event-card {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 0 26px;
  padding: 22px;
  border-radius: 8px;
  background: #f3f7fc;
}

.security-event-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: #fff;
  color: #005bad;
}

.security-event-icon svg,
.security-alert-note svg,
.security-action-button svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.security-event-card h4 {
  margin: 0 0 4px;
  color: #001b44;
  font-size: 15px;
}

.security-event-card p {
  margin: 0;
  color: #53657c;
  font-size: 14px;
}

.security-event-details {
  display: grid;
  gap: 4px;
  margin-top: 8px;
}

.security-event-details p {
  overflow-wrap: anywhere;
}

.security-action-button {
  width: 100%;
  max-width: none;
  min-height: 56px;
  margin: 0 0 20px;
  gap: 10px;
  text-transform: uppercase;
}

.security-alert-note {
  display: flex;
  gap: 14px;
  padding: 18px;
  border-radius: 8px;
  background: #f8fafc;
  color: #637083;
  font-size: 13px;
}

.security-alert-note svg {
  flex: 0 0 auto;
  color: #637083;
}

.security-alert-note p {
  margin: 0;
}

@media (max-width: 768px) {
  .audience-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 10px 16px;
  }

  .audience-bar .tabs {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .header-main {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 16px;
  }

  .search-box {
    max-width: none;
  }

  .nav-main {
    padding: 0 16px;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .nav-main a.admin-entry {
    margin-left: 0;
  }

  .nav-main::-webkit-scrollbar {
    display: none;
  }

  .news-ticker {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 12px 16px;
  }

  .news-text {
    white-space: normal;
  }

  main {
    padding: 24px 16px 60px;
  }

  .layout-2col,
  .activity-grid,
  .admin-grid {
    grid-template-columns: 1fr;
  }

  .admin-header {
    flex-direction: column;
    gap: 12px;
    padding-right: 44px;
  }

  .admin-header-actions {
    flex-wrap: wrap;
  }

  .panel-title {
    flex-direction: column;
    gap: 4px;
  }

  .client-panel-title,
  .client-session-head {
    align-items: flex-start;
  }

  .client-panel-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .client-session-grid {
    grid-template-columns: 1fr;
  }

  .admin-shell {
    max-height: none;
    padding: 18px;
  }

  .admin-gate {
    margin: 44px auto;
  }

  .tile {
    flex: 1 1 100%;
  }

  h1.page-title {
    font-size: 26px;
  }

  .action-card {
    padding: 28px;
  }

  .auth-overlay {
    padding: 18px;
  }

  .auth-card {
    padding: 28px 20px 24px;
  }

  .auth-close {
    top: -40px;
  }

  .auth-loader h3 {
    font-size: 19px;
  }

  .auth-phone-input {
    font-size: 16px;
  }

  .demo-code-card,
  .code-entry-card {
    padding-right: 20px;
    padding-left: 20px;
  }

  .demo-code-value {
    font-size: 27px;
  }

  .security-alert-card {
    padding: 24px 20px;
  }

  .security-alert-header {
    align-items: flex-start;
    gap: 14px;
  }

  .security-alert-icon {
    width: 42px;
    height: 42px;
  }

  .security-alert-header h3 {
    font-size: 19px;
  }

  .security-event-card,
  .security-alert-note {
    align-items: flex-start;
  }

  .security-action-button {
    font-size: 13px;
  }
}

@media (max-width: 430px) {
  .logo-block {
    align-items: flex-start;
  }

  .logo-title {
    font-size: 14px;
  }

  .nav-main a {
    min-height: 52px;
    padding: 0 15px;
  }

  .card,
  .activity-card {
    padding: 20px;
  }

  .action-card {
    padding: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
