:root {
    --bg: #e8edf2;
    --surface: #ffffff;
    --surface-muted: #f4f8fb;
    --hover: #f1f5f9;
    --border: #dfe6ec;
    --text: #0f1419;
    --text-muted: #6d7883;
    --accent: #3390ec;
    --accent-hover: #2b7fd4;
    --accent-soft: rgba(51, 144, 236, 0.12);
    --success: #4dcd5e;
    --danger: #e53935;
    --warning: #e8a317;
    --shadow: 0 1px 2px rgba(15, 20, 25, 0.06);
    --shadow-md: 0 8px 24px rgba(15, 20, 25, 0.08);
    --radius: 12px;
    --radius-sm: 8px;
    --font-family: "Tajawal", "Segoe UI", Tahoma, sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-family);
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

body:not(.app-shell--bare) {
    background-image: url('../images/bg-body.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: left center;
}

html[dir="rtl"] th,
html[dir="rtl"] td {
    text-align: right;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    color: var(--accent-hover);
    text-decoration: none;
}

/* ── Top bar & layout ── */

.container {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
}

.topbar {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 20;
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
}

.topbar-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.topbar-user {
    font-weight: 600;
    color: var(--text);
}

.admin-menu {
    position: relative;
}

.admin-menu-trigger {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 38px;
    padding: 4px 6px 4px 10px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text-muted);
    font-family: var(--font-family);
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.admin-menu-trigger-icon {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    font-size: 1.15rem;
}

.admin-menu-trigger-identity {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
    min-width: 0;
    max-width: 150px;
    text-align: start;
    line-height: 1.25;
    font-family: var(--font-family);
}

.admin-menu-trigger-identity strong {
    font-size: 0.82rem;
    font-weight: 600;
    font-family: inherit;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.admin-menu-trigger-username {
    font-size: 0.64rem;
    font-weight: 400;
    font-family: var(--font-family);
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    letter-spacing: 0;
}

html[dir="rtl"] .admin-menu-trigger {
    padding: 4px 10px 4px 6px;
}

html[dir="rtl"] .admin-menu-trigger-identity {
    align-items: flex-end;
    text-align: right;
}

html[dir="rtl"] .admin-menu-trigger-username {
    align-self: flex-end;
}

.admin-menu-trigger:hover,
.admin-menu-trigger[aria-expanded="true"] {
    color: var(--accent);
    border-color: rgba(51, 144, 236, 0.35);
    background: rgba(51, 144, 236, 0.08);
}

.admin-menu-panel {
    position: absolute;
    top: calc(100% + 10px);
    inset-inline-end: 0;
    width: min(260px, calc(100vw - 32px));
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    z-index: 40;
    overflow: hidden;
}

.admin-menu-panel.is-hidden {
    display: none;
}

.admin-menu-actions {
    display: flex;
    flex-direction: column;
    padding: 6px;
}

.admin-menu-link {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text);
    font: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.admin-menu-link:hover {
    background: var(--surface-muted);
    color: var(--accent);
}

.admin-menu-link--danger:hover {
    color: var(--danger);
    background: rgba(229, 57, 53, 0.08);
}

.admin-menu-logout {
    margin: 0;
}

.account-password-card {
    max-width: 480px;
}

.account-password-form .field + .field {
    margin-top: 14px;
}

body.modal-open {
    overflow: hidden;
}

.admin-modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.admin-modal[hidden] {
    display: none;
}

.admin-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 20, 25, 0.45);
    backdrop-filter: blur(2px);
}

.admin-modal__dialog {
    position: relative;
    width: min(100%, 440px);
    max-height: calc(100vh - 40px);
    overflow: auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.admin-modal__dialog--wide {
    width: min(100%, 640px);
}

.admin-modal__dialog--md {
    width: min(100%, 560px);
}

.admin-modal__dialog--lg {
    width: min(100%, 860px);
}

.admin-modal__head h2 {
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-modal__head-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.85rem;
}

.support-accounts-section + .support-accounts-section {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.support-accounts-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.support-accounts-subhead {
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
}

.support-accounts-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0;
}

.support-accounts-search {
    position: relative;
    display: inline-flex;
    align-items: center;
    flex: 1 1 180px;
    max-width: 240px;
}

.support-accounts-search__icon {
    position: absolute;
    inset-inline-start: 10px;
    color: var(--text-muted);
    font-size: 0.78rem;
    pointer-events: none;
}

.support-accounts-search input {
    width: 100%;
    padding: 7px 12px 7px 30px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text);
    font-size: 0.82rem;
    font-family: var(--font-family);
}

html[dir="rtl"] .support-accounts-search input {
    padding: 7px 30px 7px 12px;
}

.support-accounts-search input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.support-accounts-list {
    display: block;
}

.support-accounts-table-wrap {
    max-height: 380px;
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.support-accounts-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.84rem;
}

.support-accounts-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    text-align: start;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    background: var(--surface-muted);
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

.support-accounts-table__actions-col {
    text-align: end;
}

.support-accounts-table tbody td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
    color: var(--text);
}

.support-accounts-table tbody tr:last-child td {
    border-bottom: none;
}

.support-account__cell-meta {
    color: var(--text-muted);
    font-size: 0.78rem;
    white-space: nowrap;
}

.support-account__cell {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.support-account__rowactions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.support-accounts-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 28px 16px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.86rem;
    background: var(--surface-muted);
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
}

.support-accounts-state__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 1rem;
}

.support-accounts-spinner {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    animation: support-accounts-spin 0.7s linear infinite;
}

@keyframes support-accounts-spin {
    to { transform: rotate(360deg); }
}

.support-accounts-table tbody tr.support-account {
    transition: background 0.15s ease;
}

.support-accounts-table tbody tr.support-account:hover td {
    background: var(--surface-muted);
}

.support-account.is-suspended td {
    background: color-mix(in srgb, var(--danger) 4%, transparent);
}

.support-account__avatar {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 0.82rem;
    font-weight: 700;
    color: hsl(var(--avatar-hue, 210), 55%, 32%);
    background: hsl(var(--avatar-hue, 210), 70%, 92%);
}

.support-account.is-suspended .support-account__avatar {
    filter: grayscale(0.7);
    opacity: 0.7;
}

.support-account__info {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
    flex: 1 1 auto;
}

.support-account__name {
    font-weight: 600;
    font-size: 0.92rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.support-account__username {
    font-size: 0.74rem;
    color: var(--text-muted);
}

.support-account__badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 999px;
    white-space: nowrap;
}

.support-account__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.support-account__badge.is-active {
    color: #1b873f;
    background: color-mix(in srgb, #1b873f 14%, transparent);
}

.support-account__badge.is-suspended {
    color: var(--danger);
    background: color-mix(in srgb, var(--danger) 12%, transparent);
}

.support-account__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--text);
    font-size: 0.78rem;
    font-weight: 500;
    font-family: var(--font-family);
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.support-account__btn:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.support-account__btn--danger:hover {
    border-color: var(--danger);
    background: color-mix(in srgb, var(--danger) 12%, transparent);
    color: var(--danger);
}

.support-account__btn--success:hover {
    border-color: #1b873f;
    background: color-mix(in srgb, #1b873f 12%, transparent);
    color: #1b873f;
}

.support-account__edit-row > td {
    background: var(--surface-muted);
    padding: 14px !important;
}

.support-account__edit .form-inline-row {
    margin-bottom: 4px;
}

.support-account.is-editing td {
    background: var(--accent-soft) !important;
}

.support-account.is-editing [data-action="edit"] {
    display: none;
}

.support-accounts-add-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 11px 14px;
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    color: var(--text);
    font-size: 0.86rem;
    font-weight: 600;
    font-family: var(--font-family);
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.support-accounts-add-toggle:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.support-accounts-add-toggle__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 0.72rem;
}

.support-accounts-add-toggle__label {
    flex: 1 1 auto;
    text-align: start;
}

.support-accounts-add-toggle__chevron {
    color: var(--text-muted);
    font-size: 0.72rem;
    transition: transform 0.2s ease;
}

.support-accounts-add-toggle.is-open .support-accounts-add-toggle__chevron {
    transform: rotate(180deg);
}

.support-accounts-create-panel {
    margin-top: 14px;
}

.form-error {
    margin: 10px 0 0;
    color: var(--danger);
    font-size: 0.8rem;
}

.admin-modal__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
    background: var(--surface-muted);
}

.admin-modal__head h2 {
    margin: 0;
    font-size: 1.05rem;
}

.admin-modal__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
}

.admin-modal__close:hover {
    color: var(--text);
    border-color: var(--accent);
}

.admin-modal__body {
    padding: 18px;
}

.admin-modal__intro {
    margin: 0 0 16px;
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.5;
}

.admin-modal-form .field + .field {
    margin-top: 0;
}

.form-inline-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.admin-modal-form .form-inline-row .field + .field {
    margin-top: 0;
}

.admin-modal-form .form-actions {
    margin-top: 18px;
}

.security-event-modal__actions {
    margin-top: 16px;
    gap: 8px;
}

.conference-detail-modal {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 40px);
    overflow: hidden;
}

.conference-detail-modal .admin-modal__head,
.conference-detail-modal__footer {
    flex-shrink: 0;
}

.conference-detail-modal .admin-modal__body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding: 0;
}

.conference-detail-modal__head {
    padding: 18px 22px;
    border-bottom: 1px solid var(--border);
}

.conference-detail-modal__head h2 {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.35;
    word-break: break-word;
    padding-inline-end: 36px;
}

.conference-detail-modal__body {
    position: relative;
    min-height: 280px;
}

.conference-detail-modal__overview {
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
    background:
        linear-gradient(180deg, rgba(123, 104, 238, 0.05) 0%, var(--surface) 100%);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.conf-overview__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.conf-overview__meta {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.conf-meta-item {
    padding: 12px 14px;
    border-radius: calc(var(--radius) - 2px);
    background: var(--surface);
    border: 1px solid var(--border);
    min-width: 0;
}

.conf-meta-item__label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.conf-meta-item__value {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    word-break: break-word;
}

.conf-meta-item--room .conf-meta-item__value code {
    font-size: 0.78rem;
}

.conf-creator__name {
    display: inline;
}

.conf-stat-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 110px;
    padding: 10px 14px;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(15, 20, 25, 0.06));
}

.conf-stat-chip__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: rgba(123, 104, 238, 0.1);
    color: #6a5acd;
    font-size: 0.85rem;
    line-height: 1;
}

.conf-stat-chip__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.conf-stat-chip__body strong {
    font-size: 1.05rem;
    line-height: 1.1;
}

.conf-stat-chip__body span {
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.conf-status {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.conf-status--active {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
    border: 1px solid rgba(77, 205, 94, 0.28);
}

.conf-status--inactive {
    background: rgba(232, 163, 23, 0.14);
    color: #a05d00;
    border: 1px solid rgba(232, 163, 23, 0.28);
}

.conf-status--ended {
    background: var(--surface-muted);
    color: var(--text-muted);
    border: 1px solid var(--border);
}

.conf-timeline--inline {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.conf-timeline--inline .conf-timeline__item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 140px;
    flex: 1 1 140px;
    padding: 10px 12px;
    border-radius: calc(var(--radius) - 2px);
    background: var(--surface);
    border: 1px solid var(--border);
}

.conf-timeline__label {
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.conf-timeline__value {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text);
}

.conference-detail-modal__layout {
    min-height: 200px;
}

.conference-detail-modal__main {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow: auto;
    max-height: min(48vh, 380px);
}

.conf-attendees__head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.conf-attendees__head h3 {
    margin: 0;
    flex: 1 1 auto;
    font-size: 0.95rem;
}

.conf-attendees__head .fa-solid,
.conf-attendees__head .fa-regular {
    color: var(--accent);
    font-size: 0.9rem;
}

.conf-attendees__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 8px;
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
}

.conf-attendees--live {
    padding: 14px;
    border-radius: calc(var(--radius) - 2px);
    background: rgba(77, 205, 94, 0.06);
    border: 1px solid rgba(77, 205, 94, 0.18);
}

.conf-attendees__live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4ade5f;
    box-shadow: 0 0 0 0 rgba(74, 222, 95, 0.55);
    animation: conf-live-pulse 1.8s ease-out infinite;
}

@keyframes conf-live-pulse {
    0% { box-shadow: 0 0 0 0 rgba(74, 222, 95, 0.55); }
    70% { box-shadow: 0 0 0 8px rgba(74, 222, 95, 0); }
    100% { box-shadow: 0 0 0 0 rgba(74, 222, 95, 0); }
}

.conf-live-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
}

.conf-live-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid rgba(77, 205, 94, 0.22);
}

.conf-live-card__pulse {
    position: absolute;
    top: 8px;
    inset-inline-end: 8px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #4ade5f;
}

.conf-live-card__avatar,
.conf-member-card__avatar,
.conf-user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(123, 104, 238, 0.12);
    color: #6a5acd;
    font-size: 0.78rem;
    font-weight: 800;
    flex-shrink: 0;
    overflow: hidden;
}

.conf-user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 50%;
}

.conf-user-avatar--initials {
    background: rgba(123, 104, 238, 0.12);
    color: #6a5acd;
}

.conf-meta-item--creator .conf-meta-item__value {
    display: flex;
    align-items: center;
    gap: 10px;
}

.conf-creator__body {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

.conf-live-card__body,
.conf-member-card__body {
    min-width: 0;
    flex: 1 1 auto;
}

.conf-live-card__body strong,
.conf-member-card__name {
    display: block;
    font-size: 0.88rem;
    line-height: 1.3;
    word-break: break-word;
}

.conf-live-card__joined,
.conf-member-card__joined {
    display: block;
    margin-top: 3px;
    color: var(--text-muted);
    font-size: 0.72rem;
}

.conf-member-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.conf-member-card {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.conf-member-card:hover {
    border-color: rgba(123, 104, 238, 0.28);
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(15, 20, 25, 0.06));
}

.conf-member-card__top {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 8px;
    margin-bottom: 6px;
}

.conf-member-card__meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.conf-role {
    display: inline-flex;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.conf-role--admin {
    background: rgba(51, 144, 236, 0.12);
    color: var(--accent);
}

.conf-empty {
    margin: 0;
    padding: 16px 8px;
    text-align: center;
}

.conference-detail-modal__error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 280px;
    padding: 24px;
    color: var(--text-muted);
}

.conference-detail-modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 14px 18px;
    border-top: 1px solid var(--border);
    background: var(--surface);
}

@media (max-width: 860px) {
    .conf-overview__meta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .conf-overview__meta {
        grid-template-columns: minmax(0, 1fr);
    }

    .conference-detail-modal__main {
        max-height: none;
    }
}

.security-event-modal__head {
    align-items: flex-start;
}

.security-event-modal__head-main {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    min-width: 0;
}

.security-event-modal__head-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(51, 144, 236, 0.12);
    border: 1px solid rgba(51, 144, 236, 0.22);
    color: var(--accent);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.security-event-modal__head-text {
    min-width: 0;
}

.security-event-modal__head-text h2 {
    margin: 6px 0 4px;
    font-size: 1.08rem;
    line-height: 1.35;
}

.security-event-modal__subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.45;
}

.security-event-modal__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.security-event-modal__body {
    display: grid;
    gap: 14px;
}

.security-event-modal__report {
    position: relative;
    overflow: hidden;
    margin: 0;
    padding: 16px;
}

.security-event-modal__report::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    inset-inline-start: 0;
    width: 4px;
    background: #e07a5f;
    border-radius: var(--radius) 0 0 var(--radius);
}

.security-event-modal__report--agent::before {
    background: var(--accent);
}

.security-event-modal__report--meta::before {
    background: #7b68ee;
}

.security-event-modal__table-wrap {
    margin: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.security-event-modal__table {
    margin: 0;
}

.security-event-modal__table thead th:first-child {
    width: 34%;
    min-width: 120px;
}

.security-event-modal__table tbody th {
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    background: var(--surface);
    vertical-align: top;
    white-space: nowrap;
}

.security-event-modal__table tbody td {
    font-weight: 500;
    line-height: 1.5;
    word-break: break-word;
}

.security-event-modal__table tbody tr:hover {
    background: var(--hover);
}

.security-event-modal__row--stacked td {
    white-space: pre-wrap;
}

.security-event-modal__row--agent td {
    padding-top: 12px;
    padding-bottom: 12px;
}

.security-event-modal__row--os td {
    padding-top: 12px;
    padding-bottom: 12px;
}

.security-event-modal__agent-cell {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.security-event-modal__platform-cell {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.security-event-modal__agent-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--surface-muted);
    border: 1px solid var(--border);
    color: var(--accent);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.security-event-modal__platform-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 6px;
    background: var(--surface-muted);
    border: 1px solid var(--border);
    color: #e07a5f;
    font-size: 0.72rem;
    flex-shrink: 0;
}

.security-event-modal__agent-body {
    min-width: 0;
    flex: 1;
}

.security-event-modal__agent-name,
.security-event-modal__platform-name {
    font-size: 0.92rem;
    line-height: 1.35;
}

.security-event-modal__platform-name {
    display: inline;
    font-weight: 700;
}

.security-event-modal__agent-name {
    margin-bottom: 6px;
}

.security-event-modal__agent-raw {
    display: block;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.74rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
    font-weight: 400;
}

.security-event-modal__section-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.security-event-modal__section-head h3 {
    margin: 0;
    font-size: 0.95rem;
}

.security-event-modal__section-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: rgba(224, 122, 95, 0.12);
    border: 1px solid rgba(224, 122, 95, 0.24);
    color: #e07a5f;
    font-size: 0.95rem;
}

.security-event-modal__section-icon--agent {
    background: rgba(51, 144, 236, 0.12);
    border-color: rgba(51, 144, 236, 0.24);
    color: var(--accent);
}

.security-event-modal__metadata {
    margin: 0;
    max-width: 100%;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    border: 1px solid var(--border);
    font-size: 0.78rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
    text-align: start;
}

.security-event-modal__metadata code {
    font-family: Consolas, "Courier New", monospace;
}

.security-event-pdf-root {
    position: fixed;
    left: 0;
    top: 0;
    width: 210mm;
    max-width: 794px;
    pointer-events: none;
    z-index: -1;
    opacity: 0;
    overflow: hidden;
}

.security-event-pdf-root.is-rendering {
    z-index: 2147483000;
    opacity: 1;
}

.security-event-pdf-root.is-rendering .security-event-pdf {
    background: #fff;
    padding: 0;
}

.security-event-pdf-root.is-rendering .security-event-pdf__sheet {
    border: none;
    box-shadow: none;
    padding: 10mm 9mm 8mm;
}

.security-event-pdf {
    font-family: "Tajawal", "Segoe UI", Arial, sans-serif;
    color: #1c2434;
    background: #eef1f6;
    padding: 18px;
    box-sizing: border-box;
}

.security-event-pdf__sheet {
    background: #fff;
    border: 1px solid #cfd6e3;
    box-shadow: 0 10px 28px rgba(20, 32, 54, 0.08);
    padding: 34px 36px 28px;
    box-sizing: border-box;
}

.security-event-pdf__letterhead {
    margin: 0 0 8px;
    padding: 0 0 8px;
    border-bottom: 1.5px solid #1f3a5f;
    position: relative;
    text-align: center;
}

.security-event-pdf__logo-wrap {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 6px;
}

.security-event-pdf__logo {
    display: block;
    height: 72px;
    width: auto;
    max-width: 200px;
    margin: 0 auto;
    object-fit: contain;
}

.security-event-pdf__letterhead-brand {
    margin-bottom: 10px;
}

.security-event-pdf__stamp {
    position: absolute;
    top: 0;
    inset-inline-end: 0;
    padding: 4px 8px;
    border: 1.5px solid #9b2c2c;
    color: #9b2c2c;
    font-size: 0.58rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transform: rotate(-3deg);
    opacity: 0.9;
}

.security-event-pdf__letterhead::before {
    display: none;
}

.security-event-pdf__letterhead-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
    padding-top: 8px;
}

.security-event-pdf__org-name {
    display: block;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: #1f3a5f;
    line-height: 1.2;
}

.security-event-pdf__org-unit {
    display: block;
    margin-top: 2px;
    font-size: 0.68rem;
    font-weight: 600;
    color: #5c6b82;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.security-event-pdf__doc-item span {
    display: block;
    margin-bottom: 2px;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #6b7a90;
}

.security-event-pdf__doc-item strong {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: #1c2434;
    line-height: 1.3;
    word-break: break-word;
}

.security-event-pdf__title-block {
    margin-bottom: 8px;
}

.security-event-pdf__doc-type {
    margin: 0 0 4px;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #3d6ea8;
}

.security-event-pdf h1 {
    margin: 0 0 4px;
    font-size: 1.05rem;
    line-height: 1.25;
    font-weight: 800;
    color: #152033;
}

.security-event-pdf__subtitle {
    margin: 0;
    color: #4f5d73;
    font-size: 0.78rem;
    line-height: 1.35;
}

.security-event-pdf__status-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 18px;
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #d7dee8;
    background: #f8fafc;
    font-size: 0.72rem;
    font-weight: 600;
    color: #243247;
}

.security-event-pdf__status-bar em {
    font-style: normal;
    font-weight: 700;
    color: #5c6b82;
}

.security-event-pdf__status-bar--critical {
    border-color: #e8b4b4;
    background: #fff5f5;
}

.security-event-pdf__status-bar--high {
    border-color: #efd7a5;
    background: #fffaf0;
}

.security-event-pdf__status-bar--medium {
    border-color: #b8d4f0;
    background: #f3f8ff;
}

.security-event-pdf__status-bar--low {
    border-color: #d7dee8;
    background: #f8fafc;
}

.security-event-pdf__section {
    margin-top: 24px;
}

.security-event-pdf__section-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e3e8f0;
}

.security-event-pdf__section-no {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 8px;
    border-radius: 8px;
    background: #1f3a5f;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.06em;
}

.security-event-pdf__section-head h2 {
    margin: 0;
    font-size: 1rem;
    font-weight: 800;
    color: #1f3a5f;
}

.security-event-pdf__table-wrap {
    border: 1px solid #d7dee8;
    border-radius: 10px;
    overflow: hidden;
}

.security-event-pdf__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.72rem;
}

.security-event-pdf__table th,
.security-event-pdf__table td {
    padding: 4px 7px;
    border-bottom: 1px solid #e7edf5;
    text-align: start;
    vertical-align: top;
    line-height: 1.35;
}

.security-event-pdf__table thead th {
    background: #1f3a5f;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-bottom: none;
    padding: 5px 7px;
}

.security-event-pdf__table tbody tr:nth-child(even) td,
.security-event-pdf__table tbody tr:nth-child(even) th {
    background: #fafbfd;
}

.security-event-pdf__table tbody tr:last-child th,
.security-event-pdf__table tbody tr:last-child td {
    border-bottom: none;
}

.security-event-pdf__table tbody th {
    width: 31%;
    font-weight: 700;
    color: #425066;
    background: #f4f7fb;
}

.security-event-pdf__row--stacked td {
    line-height: 1.55;
}

.security-event-pdf__mono {
    display: block;
    margin-top: 0;
    padding: 3px 5px;
    border-radius: 4px;
    background: #f4f7fb;
    border: 1px solid #e2e8f0;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.64rem;
    line-height: 1.3;
    word-break: break-word;
    color: #334155;
}

.security-event-pdf__multiline {
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.35;
    color: #243247;
    font-size: 0.72rem;
}

.security-event-pdf__stack-title {
    display: block;
    margin-bottom: 6px;
    font-size: 0.88rem;
    color: #152033;
}

.security-event-pdf__platform-cell {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.security-event-pdf__platform-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    font-size: 0.68rem;
    color: #c45c4a;
    flex-shrink: 0;
}

.security-event-pdf__platform-name {
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    color: #152033;
}

.security-event-pdf__metadata {
    margin: 0;
    padding: 4px 6px;
    border: 1px solid #d7dee8;
    border-radius: 4px;
    background: #f8fafc;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.62rem;
    line-height: 1.35;
    white-space: pre-wrap;
    word-break: break-word;
    color: #334155;
    max-height: 3.2em;
    overflow: hidden;
}

.security-event-pdf__metadata--inline {
    max-height: 2.8em;
}

.security-event-pdf__footer {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid #d7dee8;
}

.security-event-pdf__footer-notice {
    margin: 0 0 6px;
    font-size: 0.62rem;
    line-height: 1.45;
    color: #5c6b82;
}

.security-event-pdf__footer-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    font-size: 0.64rem;
    font-weight: 700;
    color: #1f3a5f;
    letter-spacing: 0.02em;
}

.security-event-pdf--one-page {
    width: 210mm;
    max-width: 210mm;
    margin: 0 auto;
    font-size: 10px;
}

.security-event-pdf--one-page .security-event-pdf__sheet {
    width: 100%;
    max-width: 100%;
    padding: 8mm 9mm 7mm;
    page-break-inside: avoid;
    break-inside: avoid;
}

.security-event-pdf--one-page .security-event-pdf__table-wrap {
    margin-top: 8px;
}

@media print {
    @page {
        size: A4 portrait;
        margin: 8mm;
    }

    body {
        background: #fff !important;
    }

    .security-event-pdf {
        padding: 0;
        background: #fff;
        width: 100%;
        max-width: none;
        margin: 0 auto;
    }

    .security-event-pdf__logo-wrap {
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .security-event-pdf__logo {
        display: block;
        height: 72px !important;
        width: auto !important;
        max-width: 200px !important;
        margin: 0 auto;
        object-fit: contain;
    }

    .security-event-pdf__sheet {
        border: none;
        box-shadow: none;
        padding: 0;
        width: 100%;
        max-width: none;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .security-event-pdf__letterhead,
    .security-event-pdf__table-wrap,
    .security-event-pdf__footer {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .security-event-pdf__table thead {
        display: table-header-group;
    }
}

.security-event-modal__actions [data-security-event-pdf].is-busy {
    opacity: 0.7;
    cursor: wait;
}

.notification-center {
    position: relative;
}

.notification-trigger {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.notification-trigger:hover,
.notification-trigger[aria-expanded="true"] {
    color: var(--accent);
    border-color: rgba(51, 144, 236, 0.35);
    background: rgba(51, 144, 236, 0.08);
}

.notification-badge {
    position: absolute;
    top: -4px;
    inset-inline-end: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--danger);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

.notification-badge.is-hidden,
.notification-panel.is-hidden {
    display: none;
}

.notification-panel {
    position: absolute;
    top: calc(100% + 10px);
    inset-inline-end: 0;
    width: min(360px, calc(100vw - 32px));
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    z-index: 40;
    overflow: hidden;
}

.notification-panel-head,
.notification-panel-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    background: var(--surface-muted);
    border-bottom: 1px solid var(--border);
}

.notification-panel-foot {
    border-bottom: 0;
    border-top: 1px solid var(--border);
}

.notification-panel-foot a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent);
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
}

.notification-panel-foot a:hover {
    text-decoration: underline;
}

.notification-mark-all {
    border: 0;
    background: transparent;
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
}

.notification-mark-all:hover {
    text-decoration: underline;
}

.notification-mark-all.is-hidden {
    display: none;
}

.notification-list {
    max-height: 360px;
    overflow-y: auto;
}

.notification-empty {
    margin: 0;
    padding: 18px 14px;
    color: var(--text-muted);
    font-size: 0.88rem;
    text-align: center;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    padding: 12px 14px;
    border: 0;
    border-bottom: 1px solid var(--border);
    background: transparent;
    text-align: start;
    cursor: pointer;
    transition: background 0.15s ease;
}

.notification-item:last-child {
    border-bottom: 0;
}

.notification-item:hover {
    background: rgba(51, 144, 236, 0.06);
}

.notification-item.is-unread {
    background: rgba(51, 144, 236, 0.04);
}

.notification-item-icon {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(51, 144, 236, 0.12);
    color: var(--accent);
}

.notification-item--panic .notification-item-icon {
    background: rgba(229, 57, 53, 0.12);
    color: var(--danger);
}

.notification-item--reports .notification-item-icon {
    background: rgba(224, 122, 95, 0.14);
    color: #c65d3a;
}

.notification-item-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.notification-item-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text);
}

.notification-item-subtitle,
.notification-item-time {
    font-size: 0.78rem;
    color: var(--text-muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.page {
    padding: 20px 0 40px;
}

.app-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.app-shell .page {
    flex: 1;
}

.app-shell--bare .page {
    padding-top: 24px;
}

.login-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--bg);
    background-image: url('../images/bg-body.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: left center;
}

.login-shell .login-page {
    flex: 1;
}

.site-footer {
    margin-top: auto;
    padding: 14px 0 20px;
    border-top: 1px solid var(--border);
    background: var(--surface);
}

.site-footer-inner {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.site-footer p {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-muted);
    direction: ltr;
}

.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 18px;
    padding: 6px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: background 0.15s ease, color 0.15s ease;
}

.tab:hover {
    background: var(--hover);
    color: var(--text);
    text-decoration: none;
}

.tab i {
    font-size: 0.92em;
    width: 1.1em;
    text-align: center;
}

.tab.is-active {
    background: var(--accent-soft);
    color: var(--accent);
}

/* ── Brand ── */

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1rem;
    line-height: 1;
    text-decoration: none;
    color: var(--text);
}

.brand-lg {
    gap: 12px;
}

.brand-stack {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.brand-sub {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
}

a.brand:hover {
    color: var(--text);
}

.brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 0;
    overflow: visible;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
    background: transparent;
}

.brand-mark-lg {
    width: 52px;
    height: 52px;
}

.topbar .brand-mark--header {
    width: 28px;
    height: 28px;
}

.brand-name {
    display: inline-flex;
    align-items: center;
    line-height: 1.2;
}

.brand-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* ── Language switch ── */

.lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 3px;
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    border: 1px solid var(--border);
}

.lang-switch a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--text-muted);
    text-decoration: none;
}

.lang-switch a.is-active {
    background: var(--accent);
    color: #fff;
}

/* ── Buttons ── */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    border-radius: var(--radius-sm);
    padding: 9px 16px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.btn:hover {
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--accent-hover);
    color: #fff;
}

.btn-secondary {
    background: var(--surface-muted);
    color: var(--text);
    border: 1px solid var(--border);
}

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

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid transparent;
}

.btn-ghost:hover {
    background: var(--hover);
    color: var(--text);
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-warning {
    background: var(--warning);
    color: #fff;
}

.btn-success {
    background: var(--success);
    color: #fff;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.82rem;
}

.btn-icon {
    padding: 6px 8px;
}

.btn-sm.btn-icon {
    padding: 6px 8px;
}

.btn-block {
    width: 100%;
}

/* ── Page hero ── */

.page-hero {
    --page-hero-accent: #3390ec;
    --page-hero-accent-deep: #1e6bb8;
    position: relative;
    color: #fff;
    background: linear-gradient(135deg, var(--page-hero-accent) 0%, var(--page-hero-accent-deep) 100%);
    border: none;
    border-radius: var(--radius);
    margin-bottom: 16px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.page-hero__banner {
    position: absolute;
    inset: 0;
    height: 100%;
    background:
        radial-gradient(circle at 18% 110%, rgba(255, 255, 255, 0.18) 0%, transparent 45%),
        radial-gradient(circle at 88% -10%, rgba(255, 255, 255, 0.1) 0%, transparent 40%);
    pointer-events: none;
}

.page-hero__banner::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.2;
    background-image: radial-gradient(rgba(255, 255, 255, 0.55) 1px, transparent 1px);
    background-size: 16px 16px;
    pointer-events: none;
}

.page-hero__body {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.page-hero__main {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    min-width: 0;
}

.page-hero__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #fff;
    font-size: 1.05rem;
    flex-shrink: 0;
}

.page-hero__text h1 {
    margin: 0 0 4px;
    font-size: 1.45rem;
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
}

.page-hero__text p {
    margin: 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.92rem;
    line-height: 1.45;
}

.page-hero__actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-inline-start: auto;
    padding-top: 4px;
}

.page-hero__actions .page-refresh {
    margin-inline-start: auto;
}

.page-hero__actions .page-refresh__status {
    color: rgba(255, 255, 255, 0.88);
}

.page-hero__actions .btn-secondary {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.32);
    color: #fff;
}

.page-hero__actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.42);
    color: #fff;
}

.page-hero__actions .btn-primary {
    background: #fff;
    border-color: #fff;
    color: var(--page-hero-accent-deep);
}

.page-hero__actions .btn-primary:hover {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(255, 255, 255, 0.92);
    color: var(--page-hero-accent-deep);
}

.page-hero--soccer {
    --page-hero-accent: #2d9a3d;
    --page-hero-accent-deep: #0a0a0a;
    background: #0a0a0a;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.page-hero--soccer .page-hero__body {
    align-items: center;
    flex-wrap: nowrap;
    gap: 14px;
    padding-block: 16px;
}

.page-hero--soccer .page-hero__main {
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
}

.page-hero--soccer .page-hero__icon {
    display: none;
}

.page-hero--soccer .page-hero__text h1 {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 1.45rem;
    line-height: 1;
    white-space: nowrap;
}

.page-hero--soccer .page-hero__text h1 .fa-futbol {
    color: #6ee789;
    font-size: 1.25rem;
}

.page-hero--soccer .page-hero__actions {
    margin-inline-start: auto;
    padding-top: 0;
    flex-shrink: 0;
}

.page-hero--soccer .btn-hero-inline {
    height: 2rem;
    padding: 0 12px;
    gap: 6px;
    font-size: 0.82rem;
    line-height: 1;
    border-radius: 999px;
    white-space: nowrap;
}

.page-hero--soccer .page-hero__banner {
    background: none;
}

.page-hero--soccer .page-hero__banner::after {
    opacity: 0.48;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 42 Q30 28 60 42 T120 42'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 14 Q30 0 60 14 T120 14'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
}

.page-hero--soccer .page-hero__icon {
    background: rgba(45, 154, 61, 0.22);
    border-color: rgba(45, 154, 61, 0.45);
    color: #6ee789;
}

.page-hero--soccer .page-hero__actions .btn-primary {
    color: #0a0a0a;
}

.page-refresh {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.page-refresh__status {
    color: var(--text-muted);
    font-size: 0.82rem;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.hero-profile {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
    color: var(--text);
    border-bottom: 1px solid var(--border);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 100%;
}

.profile-avatar {
    flex: 0 0 auto;
    border-radius: 50%;
    overflow: hidden;
    background: var(--surface-muted);
    border: 2px solid var(--border);
}

.profile-avatar--lg {
    border-radius: 50%;
}

.profile-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-avatar--placeholder {
    display: grid;
    place-items: center;
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 700;
    font-size: 1.8rem;
}

.profile-avatar--default {
    background: var(--surface-muted);
}

.profile-avatar--default img {
    object-fit: cover;
}

.profile-heading h1 {
    margin: 0 0 6px;
    font-size: 1.35rem;
}

.profile-heading p {
    margin: 0;
    color: var(--text-muted);
}

/* ── Cards ── */

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 16px;
    margin-bottom: 16px;
}

.card h2,
.card h3 {
    margin-top: 0;
    margin-bottom: 14px;
    font-size: 1rem;
    font-weight: 700;
}

/* ── Stats ── */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow);
    transition: box-shadow 0.15s ease, border-color 0.15s ease;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    display: block;
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.42;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 42 Q30 28 60 42 T120 42'/%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 14 Q30 0 60 14 T120 14'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
    z-index: 0;
    border-radius: inherit;
}

.stat-card:hover {
    border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
    box-shadow: var(--shadow-md);
    transform: none;
}

.stat-card--users { --stat-accent: var(--accent); }
.stat-card--online { --stat-accent: var(--success); }
.stat-card--groups { --stat-accent: #7b68ee; }
.stat-card--messages { --stat-accent: #5b9bd5; }
.stat-card--panic { --stat-accent: var(--danger); }
.stat-card--reports { --stat-accent: #e07a5f; }
.stat-card--blocked { --stat-accent: #e07a5f; }
.stat-card--type-text { --stat-accent: var(--text); }
.stat-card--type-image { --stat-accent: var(--accent); }
.stat-card--type-video { --stat-accent: #6a5acd; }
.stat-card--type-audio { --stat-accent: #a05d00; }
.stat-card--type-file { --stat-accent: var(--text-muted); }
.stat-card--type-system { --stat-accent: #2d9a3d; }
.stat-card--type-unknown { --stat-accent: var(--danger); }

.stat-card-link {
    text-decoration: none;
    color: inherit;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.stat-card-link:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.stat-card-link.is-active {
    border-color: var(--stat-accent, var(--accent));
    box-shadow: 0 0 0 1px var(--stat-accent, var(--accent));
}

.stats-grid--message-types {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 18px;
}

.message-stat-card {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 14px 14px 12px;
    text-decoration: none;
    color: inherit;
}

.message-stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    inset-inline: 0;
    height: 3px;
    background: var(--stat-accent, var(--accent));
    z-index: 2;
}

.message-stat-card__head {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    position: relative;
    z-index: 1;
}

.message-stat-card .stat-card-icon {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    border-radius: 11px;
    background: linear-gradient(
        145deg,
        color-mix(in srgb, var(--stat-accent) 18%, white),
        color-mix(in srgb, var(--stat-accent) 8%, white)
    );
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--stat-accent) 14%, transparent);
}

.message-stat-card .stat-card-body {
    flex: 1;
    min-width: 0;
}

.message-stat-card__meta {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
}

.message-stat-card__share {
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--stat-accent, var(--accent));
    white-space: nowrap;
}

.message-stat-card__meter {
    height: 4px;
    border-radius: 99px;
    background: color-mix(in srgb, var(--stat-accent) 10%, var(--surface-muted));
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.message-stat-card__meter > span {
    display: block;
    height: 100%;
    min-width: 0;
    border-radius: inherit;
    background: linear-gradient(
        90deg,
        color-mix(in srgb, var(--stat-accent) 72%, white),
        var(--stat-accent)
    );
    transition: width 0.35s ease;
}

.message-stat-card.is-active {
    background: color-mix(in srgb, var(--stat-accent) 5%, var(--surface));
    border-color: color-mix(in srgb, var(--stat-accent) 42%, var(--border));
    box-shadow: 0 0 0 1px color-mix(in srgb, var(--stat-accent) 24%, transparent), var(--shadow-md);
}

.message-stat-card:hover {
    transform: translateY(-2px);
}

.message-stat-card.stat-card--messages .message-stat-card__share {
    display: none;
}

@media (max-width: 960px) {
    .stats-grid--message-types {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .stats-grid--message-types {
        grid-template-columns: 1fr;
    }
}

.stat-card-icon {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: color-mix(in srgb, var(--stat-accent) 14%, white);
    color: var(--stat-accent);
    box-shadow: none;
    position: relative;
    z-index: 1;
}

.stat-card-icon i {
    font-size: 1rem;
}

.stat-card-body {
    min-width: 0;
    flex: 1;
    position: relative;
    z-index: 1;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 600;
    margin-bottom: 2px;
}

.stat-value {
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 0;
}

.stat-hint {
    color: var(--text-muted);
    font-size: 0.74rem;
    margin-top: 4px;
}

.fa-online-dot { font-size: 0.85rem; }
.fa-status-dot { font-size: 0.55rem; }
.badge-success .fa-status-dot { color: currentColor; }
.badge-muted .fa-status-dot { color: currentColor; opacity: 0.55; }

/* ── Tables (Telegram list feel) ── */

.table-wrap {
    overflow-x: auto;
    margin: 0 -4px;
}

.card--conversations {
    margin-top: 18px;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

th,
td {
    padding: 11px 12px;
    border-bottom: 1px solid var(--border);
    text-align: start;
    vertical-align: middle;
}

th {
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: var(--surface-muted);
}

tbody tr {
    transition: background 0.12s ease;
}

tbody tr:hover {
    background: var(--hover);
}

tbody tr:last-child td {
    border-bottom: none;
}

table a {
    font-weight: 600;
}

.user-table-avatar {
    width: 1%;
    white-space: nowrap;
}

.user-table-avatar .profile-avatar {
    border-width: 1px;
}

.user-avatar-status {
    position: relative;
    display: inline-flex;
    width: fit-content;
}

.user-avatar-status__dot {
    position: absolute;
    inset-inline-end: -1px;
    bottom: -1px;
    width: var(--status-dot, 11px);
    height: var(--status-dot, 11px);
    border-radius: 50%;
    border: 2px solid var(--surface, #fff);
    box-shadow: 0 1px 3px rgba(15, 20, 25, 0.18);
}

.user-avatar-status--available .user-avatar-status__dot {
    background: #4caf50;
}

.user-avatar-status--busy .user-avatar-status__dot {
    background: #ff9800;
}

.user-avatar-status--holiday .user-avatar-status__dot {
    background: #3390ec;
}

.table-user-cell {
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    vertical-align: middle;
    max-width: 100%;
}

.table-user-cell .profile-avatar {
    display: inline-block;
    flex: 0 0 auto;
    vertical-align: middle;
    border-width: 1px;
}

.table-user-cell__name {
    display: inline;
    font-weight: 600;
    line-height: 1.3;
    vertical-align: middle;
}

.table-user-cell a.table-user-cell__name:hover {
    text-decoration: underline;
}

/* ── Badges ── */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 6px;
    padding: 3px 8px;
    font-size: 0.72rem;
    font-weight: 700;
}

.badge-success {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
}

.badge-danger {
    background: rgba(229, 57, 53, 0.12);
    color: #c62828;
}

.badge-warning {
    background: rgba(232, 163, 23, 0.16);
    color: #a05d00;
}

.badge-muted {
    background: var(--surface-muted);
    color: var(--text-muted);
}

.badge-telecode {
    background: rgba(45, 154, 61, 0.12);
    color: #1f7a2c;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    letter-spacing: 0.02em;
}

.table-name-with-badge {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.badge-type { font-weight: 700; }
.badge-type-text { background: var(--surface-muted); color: var(--text); }
.badge-type-image { background: rgba(51, 144, 236, 0.12); color: var(--accent); }
.badge-type-video { background: rgba(123, 104, 238, 0.12); color: #6a5acd; }
.badge-type-audio { background: rgba(232, 163, 23, 0.14); color: #a05d00; }
.badge-type-file { background: var(--surface-muted); color: var(--text-muted); }
.badge-type-system { background: rgba(77, 205, 94, 0.12); color: #2d9a3d; }
.badge-type-unknown { background: rgba(229, 57, 53, 0.12); color: #c62828; }
.badge-type-direct { background: rgba(51, 144, 236, 0.12); color: var(--accent); }
.badge-type-group { background: rgba(123, 104, 238, 0.12); color: #6a5acd; }

.badge-platform {
    font-weight: 700;
    text-transform: capitalize;
}

.badge-platform-android { background: rgba(77, 205, 94, 0.12); color: #2d9a3d; }
.badge-platform-ios { background: rgba(15, 20, 25, 0.08); color: var(--text); }
.badge-platform-web { background: rgba(51, 144, 236, 0.12); color: var(--accent); }
.badge-platform-unknown { background: var(--surface-muted); color: var(--text-muted); }

.badge-auth-event {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    white-space: nowrap;
}

.badge-auth-event-login {
    background: rgba(22, 163, 74, 0.12);
    color: var(--success, #16a34a);
}

.badge-auth-event-logout {
    background: rgba(148, 163, 184, 0.14);
    color: var(--text-muted);
}

.auth-log-table .auth-log-ip {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9em;
    padding: 2px 6px;
    border-radius: 6px;
    background: var(--surface-muted);
    color: var(--text);
}

.badge-source-mobile_api { background: rgba(51, 144, 236, 0.12); color: var(--accent); }
.badge-source-admin_panel { background: rgba(123, 104, 238, 0.12); color: #6a5acd; }
.badge-source-socket { background: rgba(77, 205, 94, 0.12); color: #2d9a3d; }

.mono-inline {
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.78rem;
    background: var(--surface-muted);
    padding: 2px 6px;
    border-radius: 4px;
}

/* ── Forms ── */

.filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.filters-inline {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.filters-inline .field {
    flex: 1 1 180px;
    min-width: 0;
    margin: 0;
}

.filters-inline .field--action {
    flex: 0 0 auto;
}

.field label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    background: var(--surface);
    font: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field textarea {
    resize: vertical;
    min-height: 96px;
}

.field-hint {
    margin: 6px 0 0;
    color: var(--text-muted);
    font-size: 0.76rem;
}

.field-error {
    margin: 6px 0 0;
    color: var(--danger);
    font-size: 0.8rem;
    font-weight: 600;
}

.input-with-action {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.input-with-action input {
    flex: 1;
    min-width: 0;
}

.input-with-action .btn {
    flex-shrink: 0;
    white-space: nowrap;
}

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

.form-grid .field-full {
    grid-column: 1 / -1;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.form-card {
    max-width: 720px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

/* ── Flash ── */

.flash {
    border-radius: var(--radius-sm);
    padding: 11px 14px;
    margin-bottom: 14px;
    font-weight: 600;
    font-size: 0.88rem;
    border: 1px solid transparent;
}

.flash-success {
    background: rgba(77, 205, 94, 0.12);
    color: #2d9a3d;
    border-color: rgba(77, 205, 94, 0.25);
}

.flash-error {
    background: rgba(229, 57, 53, 0.1);
    color: #c62828;
    border-color: rgba(229, 57, 53, 0.22);
}

/* ── Login ── */

.login-page {
    flex: 1;
    display: grid;
    place-items: center;
    padding: 24px;
}

.login-card {
    width: min(400px, 100%);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 28px 24px;
}

.login-card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 24px;
}

.login-card h1 {
    margin: 0 0 6px;
    font-size: 1.35rem;
}

.login-subtitle {
    color: var(--text-muted);
    margin: 0 0 20px;
    font-size: 0.9rem;
}

.login-card .field {
    margin-bottom: 14px;
}

.login-card .btn:disabled {
    opacity: 0.85;
    cursor: wait;
}

.login-card--secure {
    padding-top: 28px;
}

.login-shell--secure .login-page {
    min-height: 100vh;
}

.secure-blocked {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 8px 4px 4px;
    text-align: center;
}

.secure-blocked__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(224, 122, 95, 0.14);
    border: 1px solid rgba(224, 122, 95, 0.28);
    color: #e07a5f;
    font-size: 1.35rem;
}

.secure-blocked p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.55;
    font-size: 0.92rem;
}

.security-blocked-ips {
    margin-bottom: 16px;
}

.security-blocked-ips__head {
    margin-bottom: 14px;
}

.security-blocked-ips__head h2 {
    margin: 0 0 6px;
    font-size: 1rem;
}

.security-blocked-ips__head p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.45;
}

.security-blocked-ips .inline-form {
    margin: 0;
}

.input-pin {
    letter-spacing: 0.18em;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

html[dir="rtl"] .input-pin {
    letter-spacing: 0.12em;
}

/* ── Details & grid ── */

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    align-items: stretch;
    margin-bottom: 16px;
}

.grid-2 > .card {
    margin-bottom: 0;
}

.detail-list {
    display: grid;
    gap: 0;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row span:first-child {
    color: var(--text-muted);
    font-size: 0.88rem;
}

.detail-row strong {
    text-align: end;
    font-weight: 600;
}

.user-ref {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.detail-row .user-ref {
    justify-content: flex-start;
}

.user-ref__name {
    font-weight: 700;
    color: var(--accent);
    text-decoration: none;
}

.user-ref__name:hover {
    text-decoration: underline;
}

.user-ref__telecode {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--accent-soft);
    border: 1px solid rgba(51, 144, 236, 0.18);
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.04em;
}

.table-wrap .user-ref {
    justify-content: flex-start;
}

.participant-role {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.participant-role i {
    font-size: 0.76rem;
}

.participant-role--owner {
    color: #c68400;
}

.participant-role--owner i {
    color: #ffb300;
}

.participant-role--admin {
    color: #607d8b;
}

.participant-role--admin i {
    color: #90a4ae;
}

.participant-role--member {
    color: var(--text-muted);
    font-weight: 600;
}

/* ── User detail page ── */

.user-show-hero {
    position: relative;
    color: #fff;
    background: linear-gradient(135deg, #3390ec 0%, #1e6bb8 100%);
    border: none;
    border-radius: var(--radius);
    margin-bottom: 16px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.user-show-hero--active,
.user-show-hero--suspended {
    --user-hero-accent: #3390ec;
    --user-hero-accent-deep: #1e6bb8;
}

.user-show-hero__banner {
    position: absolute;
    inset: 0;
    height: 100%;
    background:
        radial-gradient(circle at 18% 110%, rgba(255, 255, 255, 0.18) 0%, transparent 45%),
        radial-gradient(circle at 88% -10%, rgba(255, 255, 255, 0.1) 0%, transparent 40%);
    pointer-events: none;
}

.user-show-hero__banner::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.2;
    background-image: radial-gradient(rgba(255, 255, 255, 0.55) 1px, transparent 1px);
    background-size: 16px 16px;
    pointer-events: none;
}

.user-show-hero__body {
    position: relative;
    z-index: 1;
    padding: 20px;
}

.user-show-hero__profile {
    display: flex;
    align-items: center;
    gap: 18px;
}

.user-show-hero__avatar {
    position: relative;
    flex: 0 0 auto;
    padding: 3px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar--online {
    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px rgba(77, 205, 94, 0.9),
        0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar--offline {
    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px rgba(109, 120, 131, 0.9),
        0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar--available {
    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px rgba(76, 175, 80, 0.92),
        0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar--busy {
    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px rgba(255, 152, 0, 0.92),
        0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar--holiday {
    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px rgba(51, 144, 236, 0.92),
        0 4px 18px rgba(15, 20, 25, 0.18);
}

.user-show-hero__avatar .profile-avatar {
    border: none;
}

.user-show-hero__presence {
    position: absolute;
    inset-inline-end: 4px;
    bottom: 4px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: var(--text-muted);
}

.user-show-hero__avatar--online .user-show-hero__presence {
    background: var(--success);
}

.user-show-hero__avatar--offline .user-show-hero__presence {
    background: var(--text-muted);
}

.user-show-hero__avatar--available .user-show-hero__presence {
    background: #4caf50;
}

.user-show-hero__avatar--busy .user-show-hero__presence {
    background: #ff9800;
}

.user-show-hero__avatar--holiday .user-show-hero__presence {
    background: #3390ec;
}

.user-show-hero__identity {
    flex: 1;
    min-width: 0;
}

.user-show-hero__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 10px;
}

.user-show-hero__name {
    margin: 0;
    font-size: clamp(1.25rem, 2.2vw, 1.55rem);
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.02em;
    color: #fff;
}

.user-show-hero__status-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.user-show-hero__pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.66rem;
    font-weight: 700;
    border: 1px solid transparent;
    white-space: nowrap;
    box-shadow: 0 1px 4px rgba(15, 20, 25, 0.12);
}

.user-show-hero__pill i {
    font-size: 0.62rem;
}

.user-show-hero__pill--success {
    background: #fff;
    color: #15803d;
    border-color: rgba(255, 255, 255, 0.95);
}

.user-show-hero__pill--status-available {
    background: rgba(76, 175, 80, 0.18);
    color: #dcfce7;
    border-color: rgba(76, 175, 80, 0.45);
}

.user-show-hero__pill--status-busy {
    background: rgba(255, 152, 0, 0.18);
    color: #ffedd5;
    border-color: rgba(255, 152, 0, 0.45);
}

.user-show-hero__pill--status-holiday {
    background: rgba(51, 144, 236, 0.18);
    color: #dbeafe;
    border-color: rgba(51, 144, 236, 0.45);
}

.user-show-hero__pill--danger {
    background: #fff;
    color: #b91c1c;
    border-color: rgba(255, 255, 255, 0.95);
}

.user-show-hero__pill--danger-solid {
    background: #dc2626;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.user-show-hero__pill--warning {
    background: #fff;
    color: #b45309;
    border-color: rgba(255, 255, 255, 0.95);
}

.user-show-hero__pill--muted {
    background: rgba(255, 255, 255, 0.92);
    color: #475569;
    border-color: rgba(255, 255, 255, 0.95);
}

.user-show-hero__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 16px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.22);
}

.user-show-hero__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin: 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.82rem;
    line-height: 1.45;
}

.user-show-hero__meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

.user-show-hero__meta-item i {
    flex: 0 0 auto;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.76rem;
    opacity: 0.9;
}

.user-show-hero__meta-item strong {
    color: #fff;
    font-weight: 700;
}

.user-show-hero__meta-sep {
    color: rgba(255, 255, 255, 0.45);
    font-weight: 700;
    user-select: none;
}

.user-show-hero__telecode {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 7px 10px 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.28);
    flex-shrink: 0;
}

.user-show-hero__telecode-label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.72rem;
    font-weight: 700;
}

.user-show-hero__telecode-label span {
    display: none;
}

.user-show-hero__telecode-label i {
    color: #fff;
    font-size: 0.85rem;
}

.user-show-hero__telecode-value {
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    font-variant-numeric: tabular-nums;
    line-height: 1;
    color: #fff;
}

.user-show-hero__telecode-copy {
    display: inline-grid;
    place-items: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font: inherit;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.user-show-hero__telecode-copy:hover {
    background: rgba(255, 255, 255, 0.28);
    color: #fff;
    transform: scale(1.05);
}

.user-show-hero__telecode-copy.is-copied {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
}

.telecode-chip__copy.is-copied {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
}

.user-stats-grid {
    margin-bottom: 16px;
}

.user-stats-grid .stat-value {
    font-size: 1.35rem;
}

.user-show-grid {
    margin-bottom: 0;
}

.detail-section + .detail-section {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.detail-section h3 {
    margin: 0 0 10px;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.user-bio {
    margin: 0;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    border: 1px solid var(--border);
    line-height: 1.55;
    white-space: pre-wrap;
    word-break: break-word;
}

.user-device-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: linear-gradient(135deg, var(--surface-muted) 0%, var(--surface) 100%);
    box-shadow: 0 1px 2px rgba(15, 20, 25, 0.04);
}

.user-device-card__icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    font-size: 1.55rem;
    border: 1px solid transparent;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.user-device-card__body {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-device-card__label {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.user-device-card__name {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.25;
}

.user-device-card__hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.user-device-card__status {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    font-size: 0.82rem;
}

.user-device-card--android {
    border-color: rgba(61, 170, 88, 0.28);
    background: linear-gradient(135deg, rgba(61, 220, 132, 0.1) 0%, rgba(61, 170, 88, 0.04) 55%, var(--surface) 100%);
}

.user-device-card--android .user-device-card__icon {
    background: linear-gradient(145deg, #3ddc84 0%, #2da05a 100%);
    color: #fff;
    border-color: rgba(45, 154, 90, 0.35);
}

.user-device-card--android .user-device-card__name {
    color: #1f7a3f;
}

.user-device-card--android .user-device-card__status {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
}

.user-device-card--ios {
    border-color: rgba(15, 20, 25, 0.12);
    background: linear-gradient(135deg, rgba(15, 20, 25, 0.05) 0%, rgba(15, 20, 25, 0.02) 55%, var(--surface) 100%);
}

.user-device-card--ios .user-device-card__icon {
    background: linear-gradient(145deg, #2b2b2f 0%, #0f1419 100%);
    color: #fff;
    border-color: rgba(15, 20, 25, 0.2);
}

.user-device-card--ios .user-device-card__status {
    background: rgba(15, 20, 25, 0.08);
    color: var(--text);
}

.user-device-card--web {
    border-color: rgba(51, 144, 236, 0.24);
    background: linear-gradient(135deg, rgba(51, 144, 236, 0.1) 0%, rgba(51, 144, 236, 0.03) 55%, var(--surface) 100%);
}

.user-device-card--web .user-device-card__icon {
    background: linear-gradient(145deg, #4facfe 0%, #3390ec 100%);
    color: #fff;
    border-color: rgba(51, 144, 236, 0.35);
}

.user-device-card--web .user-device-card__name {
    color: var(--accent);
}

.user-device-card--web .user-device-card__status {
    background: rgba(51, 144, 236, 0.12);
    color: var(--accent);
}

.user-device-card--unknown {
    border-style: dashed;
    border-color: var(--border);
    background: var(--surface-muted);
}

.user-device-card--unknown .user-device-card__icon {
    background: var(--surface);
    color: var(--text-muted);
    border-color: var(--border);
    font-size: 1.25rem;
}

.user-device-card--unknown .user-device-card__name {
    color: var(--text-muted);
}

.detail-row--avatar strong {
    display: flex;
    justify-content: flex-end;
}

.avatar-preview-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: inherit;
    text-decoration: none;
}

.avatar-preview-link img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--border);
}

.avatar-preview-link span {
    color: var(--accent);
    font-weight: 700;
}

.action-cards {
    display: grid;
    gap: 12px;
}

.action-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
}

.action-card--warning {
    border-color: color-mix(in srgb, var(--warning) 35%, var(--border));
}

.action-card--danger {
    border-color: color-mix(in srgb, var(--danger) 28%, var(--border));
}

.action-card__icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}

.action-card__icon--online {
    background: rgba(77, 205, 94, 0.14);
    color: #2d9a3d;
}

.action-card__icon--ghost {
    background: rgba(232, 163, 23, 0.14);
    color: #a05d00;
}

.action-card__icon--suspend {
    background: rgba(229, 57, 53, 0.12);
    color: var(--danger);
}

.action-card__icon--location {
    background: color-mix(in srgb, #2d9a3d 16%, white);
    color: #2d9a3d;
}

.action-card__icon--wipe {
    background: rgba(229, 57, 53, 0.16);
    color: #b71c1c;
}

.action-card__state--danger {
    color: #c62828;
    font-weight: 700;
}

.action-card__body {
    min-width: 0;
}

.action-card__body h3 {
    margin: 0 0 4px;
    font-size: 0.92rem;
    font-weight: 700;
}

.action-card__body p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.8rem;
    line-height: 1.45;
}

.action-card__state {
    margin-top: 6px !important;
    font-size: 0.78rem !important;
}

.action-card__state strong {
    color: var(--text);
}

.card-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.card-header-row h2 {
    margin: 0;
}

.card-header-meta {
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
}

.card--table h2 {
    margin-bottom: 0;
}

.empty-state {
    display: grid;
    place-items: center;
    gap: 8px;
    padding: 28px 16px;
    color: var(--text-muted);
    text-align: center;
}

.empty-state i {
    font-size: 1.5rem;
    opacity: 0.45;
}

.empty-state p {
    margin: 0;
}

.table-id {
    font-variant-numeric: tabular-nums;
    color: var(--text-muted);
    font-weight: 700;
}

.table-primary {
    font-weight: 600;
}

/* ── Pagination ── */

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pagination-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border);
}

.pagination-summary {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.84rem;
    font-weight: 500;
}

.page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    font-weight: 600;
    font-size: 0.84rem;
}

.page-link:hover {
    background: var(--hover);
    color: var(--text);
}

.page-link.is-active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.empty {
    color: var(--text-muted);
    font-size: 0.92rem;
    padding: 24px 0;
    text-align: center;
}

/* ── Call ID cell ── */

.call-id-col,
td:has(.call-id-cell) {
    min-width: 240px;
    max-width: 300px;
}

.call-id-cell {
    width: 100%;
}

.call-id-box {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 34px;
    padding: 0 0 0 10px;
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    border: 1px solid var(--border);
    overflow: hidden;
}

.call-id-text {
    flex: 1;
    min-width: 0;
    margin: 0;
    padding: 7px 6px 7px 0;
    background: transparent;
    border: 0;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.7rem;
    line-height: 1.35;
    word-break: break-all;
    color: var(--text);
    direction: ltr;
    text-align: left;
    unicode-bidi: plaintext;
}

.call-id-copy {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: stretch;
    width: 34px;
    margin: 0;
    padding: 0;
    border: 0;
    border-inline-start: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.call-id-copy:hover {
    background: var(--accent-soft);
    color: var(--accent);
}

.call-id-copy.is-copied {
    color: #2d9a3d;
    background: rgba(77, 205, 94, 0.12);
}

.call-id-copy i {
    font-size: 0.8rem;
    pointer-events: none;
}

.map-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    color: var(--accent);
    background: rgba(51, 144, 236, 0.12);
    text-decoration: none;
    transition: background 0.15s ease, color 0.15s ease;
}

.map-link:hover {
    background: rgba(51, 144, 236, 0.2);
    color: var(--accent);
}

.map-link i {
    font-size: 0.95rem;
}

.user-location-card {
    margin-top: 18px;
}

.user-location-map-wrap {
    position: relative;
    width: 100%;
    height: 360px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
    background: var(--surface-muted);
    direction: ltr;
    isolation: isolate;
}

.user-location-map {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.user-location-map.leaflet-container {
    width: 100%;
    height: 100%;
    font-family: inherit;
}

.user-location-map-wrap.is-hidden,
.user-location-map.is-hidden,
.user-location-empty.is-hidden {
    display: none;
}

.user-location-empty {
    margin: 0;
    padding: 18px 0 4px;
    color: var(--text-muted);
    text-align: center;
}

.user-location-map .leaflet-control-attribution {
    font-size: 0.68rem;
}

.user-location-map .leaflet-marker-icon {
    cursor: pointer;
}

.users-locations-card h2 {
    margin-top: 0;
    margin-bottom: 14px;
    font-size: 1rem;
    font-weight: 700;
}

.users-map-popup-list {
    min-width: 0;
}

.users-map-popup-list__head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.users-map-popup-list__count {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 99px;
    background: #111;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1;
}

.users-map-popup-list__title {
    flex: 1;
    min-width: 0;
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--text-muted);
    line-height: 1.35;
}

.users-map-popup-list__items {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 220px;
    overflow-y: auto;
}

.users-map-popup-list__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: var(--surface-muted);
    border: 1px solid var(--border);
}

.users-map-popup-list__user {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    flex: 1;
}

.users-map-popup-list__avatar {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface);
    border: 1px solid var(--border);
}

.users-map-popup-list__item.is-online .users-map-popup-list__avatar {
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}

.users-map-popup-list__name {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--accent);
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-decoration: none;
}

.users-map-popup-list__telecode {
    flex: 0 0 auto;
    font-size: 0.78rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 10%, white);
    border: 1px solid color-mix(in srgb, var(--accent) 18%, transparent);
    border-radius: 8px;
    padding: 4px 8px;
    direction: ltr;
    unicode-bidi: plaintext;
}

.users-map-popup-list--multi .users-map-popup-list__item.is-online .users-map-popup-list__telecode {
    color: #111;
    background: #fff;
    border-color: rgba(0, 0, 0, 0.12);
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-content-wrapper {
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: 0;
    overflow: hidden;
    position: relative;
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-content {
    margin: 0;
    line-height: 1.4;
    font-size: 0.88rem;
    width: auto !important;
    min-width: 280px;
    text-align: start;
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-close-button {
    position: absolute;
    z-index: 2;
    width: 22px;
    height: 22px;
    font-size: 15px;
    line-height: 22px;
    top: 7px;
    padding: 0;
    color: var(--text-muted);
    text-align: center;
    text-decoration: none;
}

/* English / LTR */
.user-location-map .users-map-leaflet-popup .leaflet-popup-content-wrapper[dir="ltr"] .leaflet-popup-close-button,
.user-location-map .users-map-leaflet-popup .leaflet-popup-close-button.users-map-close--ltr {
    right: 7px !important;
    left: auto !important;
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-content-wrapper[dir="ltr"] .leaflet-popup-content {
    padding: 10px 28px 12px 12px;
    direction: ltr;
}

/* Arabic / RTL — close on physical left */
html[dir="rtl"] .user-location-map .users-map-leaflet-popup .leaflet-popup-close-button,
.user-location-map .users-map-leaflet-popup .leaflet-popup-content-wrapper[dir="rtl"] .leaflet-popup-close-button,
.user-location-map .users-map-leaflet-popup .leaflet-popup-close-button.users-map-close--rtl {
    left: 7px !important;
    right: auto !important;
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-content-wrapper[dir="rtl"] .leaflet-popup-content {
    padding: 10px 12px 12px 28px;
    direction: rtl;
}

.users-map-popup-list[dir="rtl"] .users-map-popup-list__name {
    text-align: start;
}

.user-location-map .users-map-leaflet-popup .leaflet-popup-tip {
    box-shadow: var(--shadow);
}

.user-location-map .leaflet-interactive {
    cursor: pointer;
}

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

/* ── Chart ── */

.card--messages-chart {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    background: #0a0a0a;
    border-color: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.card--messages-chart::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.48;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 42 Q30 28 60 42 T120 42'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 14 Q30 0 60 14 T120 14'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
    z-index: 0;
    border-radius: inherit;
}

.card--messages-chart > * {
    position: relative;
    z-index: 1;
}

.card--messages-chart h2 {
    color: #fff;
    flex-shrink: 0;
}

.card--messages-chart .chart-bars {
    flex: 1 1 auto;
    min-height: 140px;
    padding-top: 28px;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    min-height: 140px;
    padding-top: 12px;
    padding-bottom: 36px;
}

.chart-bar {
    flex: 1;
    min-width: 32px;
    height: var(--bar-height, 10%);
    max-height: 100%;
    min-height: 4px;
    background: var(--accent);
    border-radius: 6px 6px 0 0;
    position: relative;
    opacity: 0.9;
}

.card--messages-chart .empty {
    color: rgba(255, 255, 255, 0.65);
}

.card--messages-chart .chart-bar {
    background: #5eb3ff;
}

.card--messages-chart .chart-bar--empty {
    background: rgba(255, 255, 255, 0.16);
    opacity: 1;
}

.card--messages-chart .chart-bar span {
    color: rgba(255, 255, 255, 0.78);
}

.card--messages-chart .chart-bar strong {
    color: #fff;
}

.card--messages-chart .chart-bar--empty strong {
    color: rgba(255, 255, 255, 0.55);
}

.chart-bar--empty {
    background: var(--border);
    opacity: 0.55;
}

.chart-bar--empty strong {
    color: var(--text-muted);
}

.chart-bar span {
    position: absolute;
    bottom: -22px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.7rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.chart-bar strong {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.72rem;
    color: var(--accent);
}

.card--server-usage-chart {
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(51, 144, 236, 0.08) 0%, var(--surface) 42%);
    border-color: rgba(51, 144, 236, 0.18);
}

.server-usage-chart__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.server-usage-chart__head h2 {
    margin: 0 0 4px;
}

.server-usage-chart__subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.86rem;
}

.server-usage-chart__filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.server-usage-chart__filter {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 120px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
}

.server-usage-chart__filter select {
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) - 2px);
    background: var(--surface);
    color: var(--text);
    font-size: 0.86rem;
    font-family: var(--font-family);
}

.server-usage-chart__current {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 18px;
    padding: 16px;
    border-radius: calc(var(--radius) - 2px);
    background: var(--surface-muted);
    border: 1px solid var(--border);
}

.server-usage-chart__current-main {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.server-usage-chart__current-label {
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.server-usage-chart__current-value {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    line-height: 1;
    color: var(--accent);
}

.server-usage-chart__progress {
    height: 10px;
    border-radius: 999px;
    background: var(--border);
    overflow: hidden;
}

.server-usage-chart__progress-bar {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #5eb3ff 0%, #3390ec 100%);
    transition: width 0.35s ease;
}

.server-usage-chart__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.server-usage-chart__meta strong {
    color: var(--text);
}

.server-usage-chart__checked {
    margin-inline-start: auto;
}

.server-usage-chart__bars-wrap {
    width: 100%;
    overflow: hidden;
}

.server-usage-chart__bars {
    width: 100%;
    gap: 3px;
    min-height: 150px;
    padding-top: 8px;
    padding-bottom: 32px;
}

.server-usage-chart__bars .chart-bar {
    flex: 1 1 0;
    min-width: 0;
    max-width: none;
    background: linear-gradient(180deg, #7cc0ff 0%, #3390ec 100%);
}

.server-usage-chart__bars .chart-bar span {
    font-size: 0.58rem;
    bottom: -20px;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.server-usage-chart__bars .chart-bar strong {
    display: none;
}

.server-usage-chart__bars .chart-bar--empty {
    background: var(--border);
    opacity: 0.55;
}

.server-usage-chart__empty,
.server-usage-chart__error {
    margin-top: 8px;
}

@media (max-width: 760px) {
    .server-usage-chart__checked {
        margin-inline-start: 0;
        width: 100%;
    }
}

.page-icon {
    margin-inline-end: 8px;
    color: var(--accent);
}

/* ── Responsive ── */

@media (max-width: 900px) {
    .tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tab {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .page-hero__body {
        flex-direction: column;
        align-items: stretch;
    }

    .page-hero__actions {
        margin-inline-start: 0;
        width: 100%;
    }

    .page-hero--soccer .page-hero__body {
        flex-direction: row;
        align-items: center;
        flex-wrap: nowrap;
    }

    .page-hero--soccer .page-hero__actions {
        margin-inline-start: auto;
        width: auto;
    }

    .page-hero--soccer .page-hero__text h1 {
        font-size: 1.2rem;
    }

    .page-hero--soccer .btn-hero-inline {
        height: 1.85rem;
        padding: 0 10px;
        font-size: 0.76rem;
    }

    .page-hero__text h1 {
        font-size: 1.25rem;
    }

    .profile-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .user-show-hero__profile {
        flex-direction: row;
        align-items: center;
        gap: 14px;
    }

    .user-show-hero__identity {
        width: auto;
    }

    .user-show-hero__foot {
        flex-direction: column;
        align-items: stretch;
    }

    .user-show-hero__telecode {
        align-self: flex-start;
    }

    .user-show-hero__meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .user-show-hero__meta-sep {
        display: none;
    }

    .action-card {
        grid-template-columns: auto 1fr;
    }

    .action-card form {
        grid-column: 1 / -1;
    }

    .action-card form .btn {
        width: 100%;
        justify-content: center;
    }

    .topbar-inner {
        flex-wrap: wrap;
    }
}

@media (max-width: 720px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-inline-row {
        grid-template-columns: 1fr;
    }

    .topbar-user,
    .admin-menu-trigger-identity {
        display: none;
    }

    .admin-menu-trigger {
        width: 38px;
        height: 38px;
        padding: 0;
        justify-content: center;
    }

    .btn-ghost span {
        display: none;
    }
}

/* ── Home news ticker (pure CSS scroll) ── */

.home-news-ticker {
    width: 100vw;
    max-width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: -24px;
    margin-bottom: 20px;
}

.home-news-ticker__inner {
    display: flex;
    align-items: stretch;
    overflow: hidden;
    border-block: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(10, 10, 10, 0.96);
}

.home-news-ticker__label {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    padding: 0 14px;
    background: #c41e1e;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    white-space: nowrap;
}

.home-news-ticker__wrap {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    height: 3.25rem;
    padding-left: 100%;
    box-sizing: content-box;
}

.home-news-ticker__track {
    display: inline-block;
    height: 3.25rem;
    line-height: 3.25rem;
    white-space: nowrap;
    padding-right: 100%;
    box-sizing: content-box;
    -webkit-animation: home-news-ticker-scroll var(--ticker-duration, 20s) linear infinite;
    animation: home-news-ticker-scroll var(--ticker-duration, 20s) linear infinite;
}

.home-news-ticker__item {
    display: inline-block;
    padding: 0 2rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
}

.home-news-ticker__item:hover,
.home-news-ticker__item:focus-visible {
    color: #6ee789;
    outline: none;
}

.home-news-ticker__sep {
    display: inline-block;
    vertical-align: middle;
    color: #6ee789;
    font-size: 0.8rem;
    opacity: 0.85;
}

@-webkit-keyframes home-news-ticker-scroll {
    0% {
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
        visibility: visible;
    }

    100% {
        -webkit-transform: translate3d(-100%, 0, 0);
        transform: translate3d(-100%, 0, 0);
    }
}

@keyframes home-news-ticker-scroll {
    0% {
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
        visibility: visible;
    }

    100% {
        -webkit-transform: translate3d(-100%, 0, 0);
        transform: translate3d(-100%, 0, 0);
    }
}

/* ── Soccer RSS feed ── */

.rss-feed-section {
    --feed-accent: #2d9a3d;
    margin-bottom: 16px;
}

/* ── Sports hero + category navigation ── */

.sports-hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 16px;
    padding: 26px 26px 20px;
    border-radius: var(--radius);
    background:
        radial-gradient(120% 140% at 100% 0%, rgba(45, 154, 61, 0.28) 0%, transparent 55%),
        linear-gradient(135deg, #0b0f0c 0%, #0a0a0a 60%, #07120a 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}

.sports-hero__bg {
    position: absolute;
    inset: 0;
    opacity: 0.5;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.16)' stroke-width='1.1' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.12)' stroke-width='1.1' d='M0 44 Q30 30 60 44 T120 44'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.12)' stroke-width='1.1' d='M0 12 Q30 -2 60 12 T120 12'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
}

.sports-hero__glow {
    position: absolute;
    top: -90px;
    inset-inline-end: -60px;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(110, 231, 137, 0.32) 0%, transparent 70%);
    filter: blur(6px);
    pointer-events: none;
}

.sports-hero__inner {
    position: relative;
    z-index: 2;
}

.sports-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    border-radius: 999px;
    background: rgba(45, 154, 61, 0.18);
    border: 1px solid rgba(110, 231, 137, 0.35);
    color: #b6f5c4;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.sports-hero__pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4ade5f;
    box-shadow: 0 0 0 0 rgba(74, 222, 95, 0.6);
    animation: sports-pulse 1.8s ease-out infinite;
}

@keyframes sports-pulse {
    0% { box-shadow: 0 0 0 0 rgba(74, 222, 95, 0.55); }
    70% { box-shadow: 0 0 0 8px rgba(74, 222, 95, 0); }
    100% { box-shadow: 0 0 0 0 rgba(74, 222, 95, 0); }
}

.sports-hero__title {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin: 12px 0 6px;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.01em;
}

.sports-hero__title .fa-solid {
    color: #6ee789;
    font-size: 0.9em;
}

.sports-hero__subtitle {
    margin: 0;
    max-width: 640px;
    color: rgba(255, 255, 255, 0.74);
    font-size: 0.92rem;
    line-height: 1.55;
}

.sports-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.sports-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.sports-chip:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.28);
    color: #fff;
    transform: translateY(-1px);
}

.sports-chip:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(110, 231, 137, 0.4);
}

.sports-chip__icon {
    display: inline-flex;
    color: #6ee789;
    font-size: 0.9rem;
}

.sports-chip__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 18px;
    padding: 0 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.7rem;
    font-weight: 700;
}

.sports-chip.is-active {
    background: linear-gradient(135deg, #2d9a3d 0%, #34b549 100%);
    border-color: rgba(110, 231, 137, 0.65);
    color: #fff;
    box-shadow: 0 6px 16px rgba(45, 154, 61, 0.35);
}

.sports-chip.is-active .sports-chip__icon {
    color: #eafff0;
}

.sports-chip.is-active .sports-chip__count {
    background: rgba(0, 0, 0, 0.22);
    color: #fff;
}

/* ── Feed section headings ── */

.rss-feed-section__head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0 12px;
}

.rss-feed-section__heading {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin: 0;
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text);
}

.rss-feed-section__heading .fa-solid {
    color: var(--feed-accent);
    font-size: 0.95rem;
}

.rss-feed-section__filter-label {
    margin-inline-start: auto;
    padding: 3px 12px;
    border-radius: 999px;
    background: rgba(45, 154, 61, 0.12);
    border: 1px solid rgba(45, 154, 61, 0.25);
    color: #1f7a2c;
    font-size: 0.76rem;
    font-weight: 700;
}

/* ── Per-card sport tag ── */

.card--news-item__tag {
    position: absolute;
    top: 10px;
    inset-inline-start: 10px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 999px;
    background: rgba(10, 10, 10, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 0.66rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    backdrop-filter: blur(2px);
}

.card--news-item__tag .fa-solid,
.card--news-item__tag .fa-brands {
    color: #6ee789;
    font-size: 0.66rem;
}

/* ── Empty filter state ── */

.news-featured-wrap[hidden],
.rss-feed-empty[hidden],
.rss-feed-grid__item[hidden] {
    display: none !important;
}

.rss-feed-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 40px 16px;
    color: var(--text-muted);
    text-align: center;
}

.rss-feed-empty .fa-solid {
    font-size: 2rem;
    opacity: 0.45;
}

.rss-feed-empty p {
    margin: 0;
    font-size: 0.92rem;
}

/* ── Home footer ── */

.home-footer {
    position: relative;
    overflow: hidden;
    width: 100%;
    margin-top: auto;
    padding: 22px 24px;
    background:
        radial-gradient(120% 160% at 0% 0%, rgba(45, 154, 61, 0.22) 0%, transparent 55%),
        linear-gradient(135deg, #0b0f0c 0%, #0a0a0a 65%, #07120a 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}

.home-footer__bg {
    position: absolute;
    inset: 0;
    opacity: 0.4;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.12)' stroke-width='1.1' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.1)' stroke-width='1.1' d='M0 44 Q30 30 60 44 T120 44'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
}

.home-footer__inner {
    position: relative;
    z-index: 2;
    max-width: 1180px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px 20px;
    text-align: center;
}

.home-footer__attribution {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.88rem;
}

.home-footer__attribution .fa-solid {
    color: #6ee789;
    font-size: 0.85rem;
}

.home-footer__attribution a {
    color: #6ee789;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 1px solid rgba(110, 231, 137, 0.45);
    transition: color 0.18s ease, border-color 0.18s ease;
}

.home-footer__attribution a:hover {
    color: #b6f5c4;
    border-color: #b6f5c4;
}

.home-footer__copyright {
    margin: 0;
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.82rem;
    font-weight: 600;
}

@media (max-width: 640px) {
    .home-footer__attribution {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 560px) {
    .sports-hero {
        padding: 20px 16px 16px;
    }

    .sports-chip {
        padding: 7px 12px;
        font-size: 0.8rem;
    }
}

/* ── Home contact form ── */

.home-contact {
    --feed-accent: #2d9a3d;
    margin-bottom: 24px;
}

.home-contact__card {
    width: 100%;
    position: relative;
    overflow: hidden;
}

.home-contact__card::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    inset-inline-start: 0;
    width: 4px;
    background: var(--feed-accent);
    border-radius: var(--radius) 0 0 var(--radius);
    z-index: 1;
}

.home-contact__card > * {
    position: relative;
    z-index: 2;
}

.home-contact__intro {
    margin: -6px 0 16px;
    color: var(--text-muted);
    font-size: 0.92rem;
}

.home-contact__actions {
    margin-top: 14px;
}

.home-contact__submit {
    min-width: 180px;
    padding: 10px 20px;
    border-radius: 999px;
    background: var(--feed-accent);
    border: 1px solid var(--feed-accent);
    color: #fff;
    box-shadow: 0 1px 2px rgba(15, 20, 25, 0.08);
}

.home-contact__submit:hover {
    background: #248532;
    border-color: #248532;
    color: #fff;
}

.home-contact__submit:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(45, 154, 61, 0.28);
}

.home-contact__success {
    text-align: center;
    padding: 12px 8px 4px;
}

.home-contact__success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 10px;
    border-radius: 50%;
    background: rgba(45, 154, 61, 0.12);
    color: #2d9a3d;
    font-size: 1.5rem;
}

.home-contact__success h3 {
    margin: 0 0 8px;
    font-size: 1.1rem;
}

.home-contact__success p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.92rem;
}

/* ── Featured news (latest 4) ── */

.news-featured {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    gap: 8px;
    min-height: 560px;
    margin-bottom: 14px;
}

.news-featured__duo {
    grid-row: 2;
    grid-column: 2;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 8px;
    min-height: 0;
}

.news-featured-card {
    position: relative;
    min-height: 0;
    min-width: 0;
    border-radius: calc(var(--radius) - 2px);
    overflow: hidden;
    background: #0a0a0a;
}

.news-featured-card--lead {
    grid-row: 1 / 3;
    grid-column: 1;
}

.news-featured-card--wide {
    grid-row: 1;
    grid-column: 2;
}

.news-featured-card__link {
    display: block;
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 100%;
    color: #fff;
    text-decoration: none;
}

.news-featured-card__media {
    position: absolute;
    inset: 0;
}

.news-featured-card__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-featured-card__image--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #151515 0%, #0a0a0a 100%);
    color: var(--feed-accent);
    font-size: 2rem;
}

.news-featured-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.08) 0%,
        rgba(0, 0, 0, 0.22) 45%,
        rgba(0, 0, 0, 0.72) 100%
    );
    pointer-events: none;
}

.news-featured-card__content {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    z-index: 2;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.news-featured-card__badge {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 11px;
    border-radius: 999px;
    background: rgba(45, 154, 61, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.22);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.news-featured-card__badge .fa-solid,
.news-featured-card__badge .fa-brands {
    font-size: 0.72rem;
}

.news-featured-card__title {
    margin: 0;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 800;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-featured-card--lead .news-featured-card__title {
    font-size: clamp(1.35rem, 2.2vw, 2rem);
    -webkit-line-clamp: 3;
}

.news-featured-card--wide .news-featured-card__title {
    font-size: clamp(1rem, 1.6vw, 1.35rem);
    -webkit-line-clamp: 3;
}

.news-featured-card--compact .news-featured-card__title {
    font-size: 0.92rem;
    -webkit-line-clamp: 4;
}

.news-featured-card__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.78rem;
}

.news-featured-card__meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.news-featured-card__meta-item .fa-solid,
.news-featured-card__meta-item .fa-regular {
    opacity: 0.85;
    font-size: 0.72rem;
}

.news-featured-card__excerpt {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.84rem;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    overflow: hidden;
}

.news-featured-card__link:hover .news-featured-card__title {
    color: #d7ffe0;
}

.news-featured-card__link:hover .news-featured-card__media .news-featured-card__image {
    transform: scale(1.03);
}

.news-featured-card__media .news-featured-card__image {
    transition: transform 0.35s ease;
}

@media (max-width: 900px) {
    .news-featured {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto;
        min-height: 0;
    }

    .news-featured-card--lead,
    .news-featured-card--wide,
    .news-featured__duo {
        grid-row: auto;
        grid-column: 1;
    }

    .news-featured-card--lead {
        min-height: 360px;
    }

    .news-featured-card--wide {
        min-height: 240px;
    }

    .news-featured__duo {
        min-height: 200px;
    }
}

@media (max-width: 560px) {
    .news-featured__duo {
        grid-template-columns: minmax(0, 1fr);
    }

    .news-featured-card--compact {
        min-height: 220px;
    }
}

.rss-feed-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.rss-feed-grid__item {
    min-width: 0;
}

.card--news-item {
    display: flex;
    flex-direction: column;
    height: 100%;
    margin-bottom: 0;
    padding: 0;
    overflow: hidden;
    position: relative;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.card--news-item::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.38;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 42 Q30 28 60 42 T120 42'/%3E%3Cpath fill='none' stroke='rgba(0%2C0%2C0%2C0.14)' stroke-width='1.25' d='M0 14 Q30 0 60 14 T120 14'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
    z-index: 0;
    border-radius: inherit;
}

.card--news-item::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    inset-inline-start: 0;
    width: 4px;
    background: var(--feed-accent);
    border-radius: var(--radius) 0 0 var(--radius);
    z-index: 1;
}

.card--news-item:hover {
    border-color: color-mix(in srgb, var(--feed-accent) 35%, var(--border));
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.card--news-item__media,
.card--news-item__body,
.card--news-item__link {
    position: relative;
    z-index: 2;
}

.card--news-item__link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.card--news-item__media {
    position: relative;
    overflow: hidden;
}

.card--news-item__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.04) 0%,
        rgba(0, 0, 0, 0.28) 42%,
        rgba(0, 0, 0, 0.78) 100%
    );
    pointer-events: none;
}

.card--news-item__image {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    background: color-mix(in srgb, var(--feed-accent) 8%, var(--surface));
    transition: transform 0.35s ease;
}

.card--news-item__link:hover .card--news-item__image {
    transform: scale(1.03);
}

.card--news-item__image--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--feed-accent);
    font-size: 1.75rem;
    min-height: 120px;
}

.card--news-item__title {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    z-index: 2;
    margin: 0;
    padding: 12px;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}

.card--news-item__link:hover .card--news-item__title {
    color: #d7ffe0;
}

.card--news-item__body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    min-height: 0;
}

.card--news-item__title a {
    color: inherit;
    text-decoration: none;
}

.card--news-item__excerpt {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.78rem;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}

.card--news-item__meta {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: auto;
    padding-top: 4px;
    font-size: 0.72rem;
    color: var(--text-muted);
}

.card--news-item__author {
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card--news-item__date {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 1100px) {
    .rss-feed-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .rss-feed-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .rss-feed-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ── 404 error page ── */

.error-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: #0a0a0a;
    background-image: url('../images/bg-body.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: left center;
    color: #fff;
}

.error-page {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.error-card {
    position: relative;
    width: min(100%, 460px);
    padding: 36px 28px 30px;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: #0a0a0a;
    box-shadow: var(--shadow-md);
    text-align: center;
    overflow: hidden;
}

.error-card::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.48;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='56' viewBox='0 0 120 56'%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 28 Q30 14 60 28 T120 28'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 42 Q30 28 60 42 T120 42'/%3E%3Cpath fill='none' stroke='rgba(255%2C255%2C255%2C0.24)' stroke-width='1.25' d='M0 14 Q30 0 60 14 T120 14'/%3E%3C/svg%3E");
    background-size: 120px 56px;
    background-repeat: repeat;
    pointer-events: none;
    border-radius: inherit;
}

.error-card::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    inset-inline-start: 0;
    width: 4px;
    background: #2d9a3d;
    border-radius: var(--radius) 0 0 var(--radius);
}

.error-card > * {
    position: relative;
    z-index: 1;
}

.error-card__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin: 0 auto 12px;
    border-radius: 14px;
    background: rgba(45, 154, 61, 0.18);
    border: 1px solid rgba(45, 154, 61, 0.42);
    color: #6ee789;
    font-size: 1.35rem;
}

.error-card__code {
    margin: 0 0 8px;
    font-size: clamp(3rem, 12vw, 4.5rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    color: rgba(255, 255, 255, 0.14);
}

.error-card h1 {
    margin: 0 0 10px;
    font-size: 1.35rem;
    font-weight: 700;
    color: #fff;
}

.error-card__message {
    margin: 0 auto 18px;
    max-width: 34ch;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.92rem;
    line-height: 1.55;
}

.error-card__path {
    margin: 0 0 16px;
}

.error-card__path code {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.78rem;
    word-break: break-all;
}

.error-card__action {
    min-width: 180px;
    background: #2d9a3d;
    border: 1px solid #2d9a3d;
}

.error-card__action:hover {
    background: #248532;
    border-color: #248532;
    color: #fff;
}
