/* Li.pad operational workspace: brand blue, neutral surfaces, one control scale. */
:root {
  --lipad-ink: #172e42;
  --lipad-slate: #52687b;
  --lipad-canvas: #f3f6f8;
  --lipad-line: #dce5eb;
  --lipad-action: #086f99;
  --lipad-blue: #086f99;
  --action: #086f99;
  --bg: #ffffff;
  --ink: #172e42;
  --workspace-radius: 16px;
}
body { font-family: "Segoe UI", Inter, system-ui, sans-serif; }
.layout-menu { background: #fff !important; }
.lipad-brand { height: 100px; }
.layout-menu .menu-inner { padding: 12px !important; }
.layout-menu .menu-link { margin: 4px 0; padding: 12px 16px; font-size: 15px; font-weight: 600; border-radius: 10px; }
.layout-menu .menu-item.active > .menu-link { color: #075d81; background: #e8f3f8 !important; box-shadow: inset 3px 0 #086f99; }
.layout-menu .menu-item.active > .menu-link .menu-icon { color: #086f99; }
.layout-menu .menu-header { margin-top: 24px; color: #65798a; font-size: 13px; text-transform: none !important; letter-spacing: 0; }
.layout-navbar { background: #fff !important; }
.layout-navbar-fixed #layout-navbar { width: auto; }
.topbar-kicker { font-size: 13px; letter-spacing: .04em; }
.topbar-context { gap: 16px; white-space: nowrap; }
.topbar-context > span + span { padding-left: 16px; border-left: 1px solid var(--lipad-line); }
.layout-navbar .navbar-nav-right { flex: 0 1 auto; justify-content: flex-end; }
.navbar-text { gap: 8px; }
.admin-page { padding: 40px; max-width: 1440px; }
.admin-page h1 { font-size: clamp(28px, 2.4vw, 38px); line-height: 1.2; letter-spacing: -.035em; }
.admin-page p { font-size: 16px; }
.workspace-label { display: block; margin-bottom: 12px; font-size: 13px; line-height: 1.5; font-weight: 600; color: #48687e; }
.workspace-section-title { margin: 32px 0 16px; color: var(--lipad-ink); font-size: 17px; font-weight: 650; letter-spacing: -.015em; }
.dashboard-hero { min-height: 216px; padding: 32px; border: 1px solid #d1e3ed; border-radius: var(--workspace-radius); background: #e9f3f8; }
.dashboard-hero > div { min-width: 0; }
.dashboard-hero img { display: block; width: 88px; margin: 0 8px 0 24px; }
.dashboard-hero h1.user-identity { align-items: center; gap: 12px; }
.dashboard-hero p { max-width: 48ch; margin-top: 12px; }
.dashboard-actions { gap: 16px; margin-top: 0; overflow: visible; border: 0; background: transparent; border-radius: 0; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.dashboard-action { min-height: 140px; padding: 24px; flex-wrap: wrap; gap: 16px; background: #fff; border: 1px solid var(--lipad-line); border-radius: var(--workspace-radius); }
.dashboard-action + .dashboard-action { border: 1px solid var(--lipad-line); }
.dashboard-action strong { font-size: 17px; }
.dashboard-action small { display: block; font-size: 14px; line-height: 1.5; }
.dashboard-action > span:nth-child(2) { flex: 1 1 120px; }
.dashboard-action > i { color: #557386; }
.action-icon { flex-basis: 44px; width: 44px; height: 44px; border-radius: 12px; }
.dashboard-stats { gap: 16px; margin-top: 0; }
.dashboard-stats article { position: relative; padding: 24px; grid-template-columns: 1fr auto; gap: 12px; border: 1px solid var(--lipad-line); border-radius: var(--workspace-radius); background: #fff; }
.dashboard-stats i { grid-column: 2; grid-row: 1; font-size: 21px; color: #526e81; }
.dashboard-stats span { grid-column: 1; grid-row: 1; font-size: 14px; line-height: 1.5; }
.dashboard-stats strong { grid-column: 1 / -1; font-size: 32px; line-height: 1.2; letter-spacing: -.04em; }
.btn { border-radius: 8px; font-size: 14px; font-weight: 600; padding-inline: 16px; }
.btn-primary, .btn-login { background: var(--lipad-action); border-color: var(--lipad-action); }
.btn-outline-primary:hover { color: #fff; background: var(--lipad-action); border-color: var(--lipad-action); }
.data-card, .discussion-card, .responsive-list, .form-card, .discussion-filter-panel { border-radius: var(--workspace-radius); }
.responsive-list-header { min-height: 52px; font-size: 13px; letter-spacing: 0; text-transform: none; color: #52687b; background: #f8fafb; }
.responsive-list-row { min-height: 88px; }
.list-cell { font-size: 15px; }
.list-cell small, .form-text, .check-card small { font-size: 13px; line-height: 1.5; }
.user-roles .role-badge { white-space: normal; text-align: center; }
.status-badge, .role-badge { font-size: 13px; border-radius: 6px; }
.form-control, .form-select { border-radius: 8px; }
.form-page .form-control, .form-select { border-color: #c6d3dd; }
.form-card { padding: 32px; }
.public-appearance-form { display: grid; gap: 24px; }
.public-appearance-form fieldset { display: grid; min-width: 0; gap: 12px; padding-top: 8px; }
.public-appearance-form legend { float: none; margin-bottom: 0; color: var(--lipad-ink); font-size: 1rem; font-weight: 650; }
.public-appearance-form fieldset + fieldset { padding-top: 14px; border-top: 1px solid var(--lipad-line); }
.public-appearance-colors, .public-appearance-logo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.public-appearance-logo { grid-template-columns: auto minmax(0, 1fr); align-items: center; }
.public-appearance-logo img { display: block; object-fit: contain; border: 1px solid var(--lipad-line); border-radius: 8px; }
.public-appearance-form .form-text { display: block; }
.public-appearance-form .form-actions { margin: 0; }
.public-appearance-form .validation-summary-valid { display: none; }
.telegram-bot { align-self: center; overflow-wrap: anywhere; }
.telegram-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 5px; margin: 0 0 18px; border: 1px solid var(--lipad-line); border-radius: 12px; background: #fff; list-style: none; }
.telegram-steps a, .telegram-step-unavailable { display: flex; min-height: 44px; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 8px; color: var(--lipad-ink); font-size: .875rem; font-weight: 600; line-height: 1.3; }
.telegram-steps a[aria-current] { background: #e8f3f8; color: #075d81; }
.telegram-steps a:not([aria-current]):hover { background: #f3f6f8; }
.telegram-steps li > * > span { display: grid; flex: 0 0 24px; min-height: 24px; place-items: center; border-radius: 50%; background: #edf2f5; color: var(--lipad-ink); }
.telegram-steps a[aria-current] > span { color: #fff; background: var(--lipad-action); }
.telegram-step-unavailable { color: var(--lipad-slate); }
.telegram-panel h2 { margin: 0 0 12px; color: var(--lipad-ink); font-size: 1.3rem; }
.telegram-panel code { color: #075d81; background: #edf5f8; padding: 2px 4px; border-radius: 4px; }
.telegram-setup .alert-success { color: #235d47; background: #e9f4ed; }
.telegram-setup .alert-danger { color: #802920; background: #fcefed; }
.telegram-instructions { display: grid; gap: 8px; margin-top: 16px; padding-left: 1.35rem; }
.telegram-editor { display: grid; gap: 16px; margin-top: 16px; }
.telegram-channel { padding-block: 14px; border-top: 1px solid var(--lipad-line); }
.telegram-channel-heading { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.telegram-channel-heading label { margin: 0; }
.telegram-channel-fields { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 8px; }
.telegram-channel .form-text { margin-bottom: 0; overflow-wrap: anywhere; }
.telegram-switch { min-height: 44px; }
.telegram-switch .form-check-label { font-weight: 600; }
.telegram-switch .form-check-input:checked { background-color: var(--lipad-action); border-color: var(--lipad-action); }
.telegram-panel .form-actions { margin-top: 14px; }
.form-section-title { font-size: 17px; }
.admin-page .eyebrow, .sidebar-section-label, .chat-workspace-header .eyebrow { font-size: 13px; text-transform: none; letter-spacing: 0; font-weight: 600; }
.content-footer { color: #617486; font-size: 13px; }
.content-footer > div { padding-inline: 40px !important; }
.chat-workspace .chat-messages { background: #f3f6f8; gap: 16px; }
.chat-workspace .chat-message { border: 1px solid #e0e7ec; border-radius: 14px 14px 14px 4px; padding: 12px 16px; }
.chat-workspace .chat-message.mine { border-radius: 14px 14px 4px; background: #08678d; border-color: #08678d; }
.chat-workspace .chat-message p { font-size: 16px; line-height: 1.55; }
.chat-workspace .chat-meta { font-size: 13px; }
.chat-sidebar { background: #fff; }
.participant-list strong { font-size: 14px; }
.participant-list small, .discussion-summary dl div, .discussion-summary > p { font-size: 13px; }
.chat-workspace-header { min-height: 88px; }
.chat-workspace-header h1 { font-size: 20px; }
.quote-preview button, .image-preview button { min-width: 44px; min-height: 44px; }
.login-shell { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); }
.login-brand { padding: clamp(32px, 5vw, 80px); background: #e9f3f8; border-color: #d1e3ed; }
.brand-copy { max-width: 520px; }
.brand-copy h1 { font-size: clamp(36px, 4vw, 60px); line-height: 1.08; letter-spacing: -.05em; text-wrap: balance; }
.brand-copy p { margin-top: 24px; font-size: 17px; line-height: 1.65; }
.login-capabilities { display: grid; gap: 16px; margin-top: 32px; color: #344f64; font-size: 15px; }
.login-capabilities span { display: flex; align-items: center; gap: 12px; }
.login-capabilities i { font-size: 21px; color: #086f99; }
.login-card { padding: 32px; width: min(100%, 440px); background: #fff; }
.login-card h2 { font-size: 28px; letter-spacing: -.035em; }
.login-card > p { color: #52687b; font-size: 15px; line-height: 1.6; }
.login-card .form-label { color: #344b60; font-size: 14px; }
.login-card .form-control { background: #f8fafb; color: #172e42; border-color: #c6d3dd; min-height: 48px; }
.login-card .form-control:focus { background: #fff; color: #172e42; }
.login-card .btn { min-height: 48px; font-size: 16px; }
.login-footer { font-size: 13px; }
.login-card .validation-summary-errors { color: #9b3028; background: #fff1ef; }
@media (hover: hover) and (pointer: fine) {
  .dashboard-action:hover { transform: translateY(-2px); background: #fff; border-color: #8db4c9; box-shadow: 0 8px 24px #172e4210; }
  .responsive-list-row:hover { background: #f7fafc; }
}
@media (max-width: 1100px) {
  .admin-page { padding: 32px; }
  .dashboard-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-hero { padding: 24px; }
}
@media (max-width: 1199px) {
  .layout-menu-expanded body { overflow: hidden; }
  .layout-menu { max-width: calc(100vw - 32px); }
}
@media (max-width: 860px) {
  .login-shell { grid-template-columns: minmax(0, 1fr); }
  .login-brand { min-height: auto; padding: 24px; }
  .login-brand-identity, .login-brand-identity .login-wordmark { height: 44px; }
  .login-brand .brand-copy { display: block; margin-top: 32px; max-width: 36rem; }
  .brand-copy h1 { font-size: 36px; }
  .brand-copy p { margin-top: 16px; font-size: 16px; }
  .login-capabilities, .brand-dots { display: none; }
  .login-panel { padding: 24px; }
  .login-card { padding: 8px 0; }
}
@media (max-width: 700px) {
  .telegram-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .telegram-channel-fields { grid-template-columns: minmax(0, 1fr); }
  .telegram-bot { align-self: flex-start; }
  .public-appearance-logo { grid-template-columns: minmax(0, 1fr); }
  .admin-page { padding: 24px 16px calc(32px + env(safe-area-inset-bottom, 0px)); }
  .admin-page h1 { font-size: 28px; }
  .dashboard-hero { padding: 20px; gap: 0; min-height: 0; }
  .dashboard-hero img { display: none; }
  .dashboard-hero h1.user-identity { flex-wrap: wrap; font-size: 26px; }
  .dashboard-hero h1 .user-category-icon { display: none; }
  .dashboard-hero p { font-size: 15px; }
  .workspace-section-title { margin-top: 24px; }
  .dashboard-actions { gap: 12px; grid-template-columns: minmax(0, 1fr); }
  .dashboard-action { flex-wrap: nowrap; min-height: 76px; padding: 12px 14px; gap: 12px; }
  .dashboard-action + .dashboard-action { border: 1px solid var(--lipad-line); }
  .dashboard-action > span:nth-child(2) { flex-basis: 0; }
  .dashboard-stats { gap: 12px; }
  .dashboard-stats article { padding: 16px; gap: 12px 4px; }
  .dashboard-stats span { font-size: 13px; }
  .dashboard-stats strong { font-size: 28px; }
  .dashboard-stats i { font-size: 18px; }
  .layout-navbar .navbar-text { display: inline-flex; max-width: 24vw; min-width: 0; }
  .layout-navbar .layout-menu-toggle { flex: 1 1 auto; align-items: center; }
  .layout-navbar .menu-open, .layout-navbar .navbar-nav-right form { flex-shrink: 0; }
  .layout-navbar .mobile-page-title { max-width: none; }
  .navbar-text .current-user-name { overflow: hidden; text-overflow: ellipsis; }
  .layout-navbar .navbar-text .user-category-icon { display: none; }
  .page-actions { display: flex; flex-wrap: wrap; }
  .page-actions .btn { flex: 1 1 130px; }
  .page-heading > .btn { width: 100%; }
  .responsive-list-row { padding: 16px; }
  .list-cell::before { font-size: 13px; text-transform: none; letter-spacing: 0; }
  .list-cell strong { white-space: normal; }
  .list-actions { flex-wrap: wrap; }
  .list-actions .btn { flex: 1 1 100px; }
  .form-card { padding: 20px 16px; }
  .filter-grid { grid-template-columns: minmax(0, 1fr); }
  .form-actions .btn { width: 100%; }
  .chat-workspace-header { min-height: 72px; }
  .chat-workspace-header h1 { font-size: 17px; }
  .chat-message-tools { opacity: 1; }
  .quote-message { width: 44px; height: 44px; }
  .chat-workspace .chat-meta { min-height: 32px; padding-right: 36px; gap: 4px 8px; }
  .chat-workspace .chat-message { max-width: 94%; padding: 12px; }
  .chat-workspace .chat-messages { padding: 16px 12px; }
  .composer-row { gap: 8px; }
  .composer-row .btn i { margin: 0; }
  .composer-row .btn span { display: none; }
  .composer-row .btn { flex: 0 0 44px; padding: 0; }
  .content-footer > div { padding-inline: 16px !important; gap: 16px; flex-wrap: wrap; }
}
@media (max-width: 360px) {
  .layout-navbar .navbar-text { display: none; }
  .mobile-page-title { max-width: 45vw; }
  .login-brand, .login-panel { padding: 20px 16px; }
  .brand-copy h1 { font-size: 32px; }
  .dashboard-hero { padding: 20px; }
}
