.admin-premium-surface #admin-main {
    background:
        radial-gradient(900px 420px at 100% -10%, rgba(124, 58, 237, 0.06), transparent 55%),
        radial-gradient(700px 360px at -5% 0%, rgba(99, 102, 241, 0.05), transparent 50%),
        #f4f6fb;
}

.admin-premium-surface .ta-card,
.admin-premium-surface .ta-surface {
    border-radius: 16px;
    border: none !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
}

.admin-premium-surface .ta-card-header {
    padding: 1.125rem 1.5rem;
    background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
    border-bottom: none !important;
}

.admin-premium-surface .ta-card-title {
    font-size: 1.0625rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: #0f172a;
}

.admin-premium-surface .ta-btn {
    border-radius: 999px;
    border: none;
    background: #7c3aed;
    box-shadow: 0 8px 24px rgba(124, 58, 237, 0.22);
}

.admin-premium-surface .ta-btn:hover {
    background: #6d28d9;
    color: #fff;
}

.admin-premium-surface .ta-btn-outline {
    border-radius: 999px;
    border: none;
    background: #ede9fe;
    color: #6d28d9;
}

.admin-premium-surface .ta-btn-outline:hover {
    background: #ddd6fe;
    color: #5b21b6;
}

.admin-premium-surface .ta-input,
.admin-premium-surface .ta-textarea,
.admin-premium-surface select.ta-input {
    border-radius: 14px;
    border: none;
    background: #f1f5f9;
}

.admin-premium-surface .ta-input:focus,
.admin-premium-surface .ta-textarea:focus,
.admin-premium-surface select.ta-input:focus {
    background: #fff;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
    outline: none;
}

.adm-premium-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.adm-premium-header--action-only {
    justify-content: flex-end;
    margin-bottom: 0.75rem;
}

.adm-premium-header__main {
    display: none;
}

.adm-premium-header__icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.35rem;
    flex-shrink: 0;
    box-shadow: 0 12px 28px rgba(124, 58, 237, 0.28);
}

.adm-tone--rose .adm-premium-header__icon,
.adm-tone--pink .adm-premium-header__icon {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    box-shadow: 0 12px 28px rgba(124, 58, 237, 0.28);
}

.adm-tone--violet .adm-premium-header__icon {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    box-shadow: 0 12px 28px rgba(124, 58, 237, 0.28);
}

.adm-tone--violet .adm-premium-header__title {
    color: #0f172a;
}

.adm-tone--blue .adm-premium-header__icon {
    background: linear-gradient(135deg, #2563eb 0%, #60a5fa 100%);
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}

.adm-tone--emerald .adm-premium-header__icon {
    background: linear-gradient(135deg, #059669 0%, #34d399 100%);
    box-shadow: 0 12px 28px rgba(5, 150, 105, 0.28);
}

.adm-tone--amber .adm-premium-header__icon {
    background: linear-gradient(135deg, #d97706 0%, #fbbf24 100%);
    box-shadow: 0 12px 28px rgba(217, 119, 6, 0.28);
}

.adm-premium-header__title {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    color: #0f172a;
}

.adm-tone--rose .adm-premium-header__title,
.adm-tone--pink .adm-premium-header__title {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.adm-premium-header__subtitle {
    margin: 0.35rem 0 0;
    font-size: 0.9375rem;
    color: #64748b;
    max-width: 40rem;
}

.adm-premium-header__action {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.625rem 1.125rem;
    border-radius: 999px;
    border: none;
    background: #fff;
    color: #334155;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
}

.adm-premium-header__action:hover {
    color: #7c3aed;
    box-shadow: 0 6px 20px rgba(124, 58, 237, 0.12);
}

.adm-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 1200px) {
    .adm-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .adm-stat-grid {
        grid-template-columns: 1fr;
    }
}

.adm-stat-card {
    border-radius: 16px;
    padding: 1.125rem 1.25rem;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
}

.adm-stat-card__label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.35rem;
}

.adm-stat-card__value {
    font-size: 1.625rem;
    font-weight: 800;
    line-height: 1.15;
    color: #0f172a;
    letter-spacing: -0.02em;
}

.adm-panel-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 1.25rem;
}

.adm-panel-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 1024px) {
    .adm-panel-grid--2 {
        grid-template-columns: 1fr;
    }
}

.adm-panel {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.adm-panel__head {
    padding: 1rem 1.25rem;
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
    background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.adm-panel__body {
    padding: 0;
}

.adm-panel__body .ta-table th {
    background: #f8fafc;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
}

.adm-panel__body .ta-table td {
    box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.04);
}

.adm-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.adm-list__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.875rem 1.25rem;
    box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.04);
    font-size: 0.875rem;
    color: #334155;
}

.adm-list__item:last-child {
    box-shadow: none;
}

.adm-list__item a {
    color: #7c3aed;
    font-weight: 600;
    text-decoration: none;
}

.adm-list__item a:hover {
    text-decoration: underline;
}

.admin-premium-surface .page-header {
    margin-bottom: 1.5rem;
}

.admin-premium-surface .page-header .d-flex {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-premium-surface .header-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    color: #fff;
    font-size: 1.25rem;
    box-shadow: 0 10px 24px rgba(124, 58, 237, 0.25);
}

.admin-premium-surface .page-title {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #0f172a;
}

.admin-premium-surface .row {
    display: flex;
    flex-wrap: wrap;
    margin: -0.5rem;
}

.admin-premium-surface .row > [class*='col-'] {
    padding: 0.5rem;
    min-width: 0;
}

.admin-premium-surface .g-3 { margin: -0.375rem; }
.admin-premium-surface .g-3 > [class*='col-'] { padding: 0.375rem; }
.admin-premium-surface .g-4 { margin: -0.5rem; }
.admin-premium-surface .g-4 > [class*='col-'] { padding: 0.5rem; }

.admin-premium-surface .col-md-3,
.admin-premium-surface .col-md-4,
.admin-premium-surface .col-md-6,
.admin-premium-surface .col-lg-4,
.admin-premium-surface .col-lg-6 {
    flex: 0 0 100%;
    max-width: 100%;
}

@media (min-width: 768px) {
    .admin-premium-surface .col-md-3 { flex: 0 0 25%; max-width: 25%; }
    .admin-premium-surface .col-md-4 { flex: 0 0 33.333%; max-width: 33.333%; }
    .admin-premium-surface .col-md-6 { flex: 0 0 50%; max-width: 50%; }
}

@media (min-width: 992px) {
    .admin-premium-surface .col-lg-4 { flex: 0 0 33.333%; max-width: 33.333%; }
    .admin-premium-surface .col-lg-6 { flex: 0 0 50%; max-width: 50%; }
}

.admin-premium-surface .card {
    background: #fff;
    border: none !important;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.admin-premium-surface .card-header {
    padding: 1rem 1.25rem;
    background: linear-gradient(180deg, #fff, #fafafa);
    font-weight: 700;
    color: #0f172a;
}

.admin-premium-surface .card-body {
    padding: 1.25rem;
}

.admin-premium-surface .form-label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #475569;
}

.admin-premium-surface .form-control {
    display: block;
    width: 100%;
    padding: 0.625rem 0.875rem;
    border-radius: 14px;
    border: none;
    background: #f1f5f9;
    font-size: 0.875rem;
    color: #0f172a;
}

.admin-premium-surface .form-control:focus {
    outline: none;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
}

.admin-premium-surface .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.625rem 1.125rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
}

.admin-premium-surface .btn-primary {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    color: #fff;
    box-shadow: 0 8px 24px rgba(124, 58, 237, 0.25);
}

.admin-premium-surface .stat-card,
.admin-premium-surface .orders-premium {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.admin-premium-surface .stat-card {
    padding: 1.125rem 1.25rem;
}

.admin-premium-surface .stat-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.35rem;
}

.admin-premium-surface .stat-value {
    font-size: 1.625rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.15;
}

.admin-premium-surface .orders-premium-header {
    padding: 1rem 1.25rem;
    background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.admin-premium-surface .orders-premium-title {
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
}

.admin-premium-surface .table-responsive {
    overflow-x: auto;
}

.admin-premium-surface .orders-table,
.admin-premium-surface .table {
    width: 100%;
    border-collapse: collapse;
}

.admin-premium-surface .orders-table th,
.admin-premium-surface .table thead th {
    padding: 0.875rem 1.125rem;
    text-align: left;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
    background: #f8fafc;
}

.admin-premium-surface .orders-table td,
.admin-premium-surface .table tbody td {
    padding: 0.875rem 1.125rem;
    font-size: 0.875rem;
    color: #334155;
    box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.04);
}

.admin-premium-surface .orders-table tbody tr:hover,
.admin-premium-surface .table tbody tr:hover {
    background: rgba(124, 58, 237, 0.03);
}

.admin-premium-surface .list-group {
    list-style: none;
    margin: 0;
    padding: 0;
}

.admin-premium-surface .list-group-item {
    padding: 0.875rem 1.25rem;
    box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.04);
    font-size: 0.875rem;
    color: #334155;
}

.admin-premium-surface .list-group-item:last-child {
    box-shadow: none;
}

.admin-premium-surface .text-muted {
    color: #64748b !important;
}

.admin-premium-surface .text-center {
    text-align: center;
}

.admin-premium-surface .fw-semibold {
    font-weight: 600;
}

.adm-module-compose {
    margin-bottom: 1.5rem;
}

.adm-module-table .ta-table th {
    background: #f8fafc;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
}

.adm-module-table .ta-table tbody tr:hover {
    background: rgba(124, 58, 237, 0.03);
}

@media (max-width: 768px) {
    .adm-premium-header__title {
        font-size: 1.375rem;
    }

    .adm-premium-header__icon {
        width: 48px;
        height: 48px;
        font-size: 1.125rem;
    }
}

/* ===== Shared components: back link ===== */
.adm-premium-header--with-back {
    justify-content: space-between;
    align-items: center;
}

.adm-premium-header__action i {
    font-size: 0.8rem;
    line-height: 1;
}

.adm-back-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.adm-back {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    height: 38px;
    padding: 0 1rem 0 0.3rem;
    border: 1px solid #eaecf0;
    border-radius: 999px;
    background: #fff;
    color: #344054;
    font: inherit;
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    text-decoration: none;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.adm-back__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f4f0ff;
    color: #7c3aed;
    flex-shrink: 0;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.adm-back__icon svg {
    width: 15px;
    height: 15px;
}

.adm-back:hover {
    border-color: #c4b5fd;
    color: #6d28d9;
}

.adm-back:hover .adm-back__icon {
    background: #7c3aed;
    color: #fff;
    transform: translateX(-2px);
}

.adm-back:focus-visible {
    outline: 2px solid #7c3aed;
    outline-offset: 2px;
}

.adm-back--icon {
    width: 38px;
    padding: 0;
    justify-content: center;
}

.adm-back--icon .adm-back__icon {
    background: transparent;
}

.adm-back.chat-back-btn {
    display: none;
    flex-shrink: 0;
}

@media (max-width: 767px) {
    .adm-back.chat-back-btn {
        display: inline-flex;
    }
}

html.dark .adm-back {
    border-color: #344054;
    background: #1d2939;
    color: #e4e7ec;
}

html.dark .adm-back__icon {
    background: rgba(124, 58, 237, 0.2);
    color: #c4b5fd;
}

/* ===== Shared components: buttons ===== */
.adm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 32px;
    padding: 0 12px;
    border: 1.5px solid transparent;
    border-radius: 8px;
    box-sizing: border-box;
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    text-decoration: none;
    cursor: pointer;
    box-shadow: none;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.adm-btn svg,
.adm-btn i {
    width: 14px;
    height: 14px;
    font-size: 12px;
    line-height: 1;
    flex-shrink: 0;
}

.adm-btn:disabled,
.adm-btn.is-disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.adm-btn.is-loading {
    cursor: progress;
    opacity: 0.75;
}

.adm-btn:focus-visible {
    outline: 2px solid #7c3aed;
    outline-offset: 2px;
}

.adm-btn--primary {
    border-color: #7c3aed;
    background: #7c3aed;
    color: #fff;
}

.adm-btn--primary:hover:not(:disabled) {
    border-color: #6d28d9;
    background: #6d28d9;
    color: #fff;
}

.adm-btn--ghost {
    border-color: #e2e8f0;
    background: #f8fafc;
    color: #475569;
}

.adm-btn--ghost:hover:not(:disabled) {
    background: #f1f5f9;
    color: #334155;
}

.adm-btn--outline {
    border-color: #e2e8f0;
    background: #fff;
    color: #475569;
}

.adm-btn--outline:hover:not(:disabled) {
    border-color: #c4b5fd;
    color: #6d28d9;
}

.adm-btn--danger {
    border-color: #fecdca;
    background: #fff;
    color: #d92d20;
}

.adm-btn--danger:hover:not(:disabled) {
    border-color: #d92d20;
    background: #fef3f2;
    color: #b42318;
}

.adm-btn--danger-solid {
    background: #d92d20;
    color: #fff;
}

.adm-btn--danger-solid:hover:not(:disabled) {
    background: #b42318;
    color: #fff;
}

.adm-btn--sm {
    height: 28px;
    padding: 0 10px;
    font-size: 12px;
}

.adm-btn--icon {
    width: 32px;
    height: 32px;
    padding: 0;
}

.adm-btn--block {
    width: 100%;
}

/* ===== Shared components: switch ===== */
.adm-switch,
.admin-ui label.adm-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
}

.admin-ui .adm-switch input[type='checkbox'].adm-switch__input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    padding: 0;
    border: 0;
    opacity: 0;
    pointer-events: none;
    appearance: none;
}

.adm-switch__track {
    position: relative;
    width: 36px;
    height: 20px;
    border-radius: 999px;
    background: #d0d5dd;
    flex-shrink: 0;
    transition: background 0.2s ease;
}

.adm-switch__knob {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.2);
    transition: transform 0.2s ease;
}

.adm-switch__input:checked + .adm-switch__track {
    background: #7c3aed;
}

.adm-switch__input:checked + .adm-switch__track .adm-switch__knob {
    transform: translateX(16px);
}

.adm-switch__input:focus-visible + .adm-switch__track {
    outline: 2px solid #7c3aed;
    outline-offset: 2px;
}

.adm-switch__input:disabled + .adm-switch__track {
    opacity: 0.6;
}

.adm-switch.is-busy {
    cursor: progress;
}

.adm-switch__text {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
    line-height: 1.25;
}

.adm-switch__text strong {
    font-size: 13px;
    font-weight: 600;
    color: #0f172a;
}

.adm-switch__text small {
    font-size: 11px;
    color: #64748b;
}

.adm-switch--row,
.admin-ui label.adm-switch--row {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
}

.adm-switch--row:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.adm-switch--row:first-child {
    padding-top: 0;
}

.adm-switch--row .adm-switch__text {
    order: -1;
}

/* ===== Shared components: custom dropdown ===== */
.adm-sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.adm-dd {
    position: relative;
    width: 100%;
}

.adm-dd__btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    width: 100%;
    height: 32px;
    padding: 0 8px 0 10px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    box-sizing: border-box;
    background: #f8fafc;
    color: #475569;
    font: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: 1;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.adm-dd__btn:hover {
    border-color: #c4b5fd;
    color: #6d28d9;
}

.adm-dd.is-open .adm-dd__btn,
.adm-dd__btn:focus-visible {
    outline: none;
    border-color: #c4b5fd;
    background: #faf5ff;
    color: #6d28d9;
}

.adm-dd.is-invalid .adm-dd__btn {
    border-color: #f04438;
}

.adm-dd__label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.adm-dd__chevron {
    display: inline-flex;
    color: #94a3b8;
    transition: transform 0.15s ease;
}

.adm-dd__chevron svg {
    width: 14px;
    height: 14px;
}

.adm-dd.is-open .adm-dd__chevron {
    transform: rotate(180deg);
    color: #7c3aed;
}

.adm-dd__panel {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 60;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 8px 24px -14px rgba(15, 23, 42, 0.18);
    scrollbar-width: thin;
}

.adm-dd__option {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 7px;
    border-radius: 6px;
    font-size: 12px;
    line-height: 1.35;
    color: #334155;
    cursor: pointer;
}

.adm-dd__option.is-active {
    background: #f5f3ff;
}

.adm-dd__option.is-selected {
    color: #6d28d9;
    font-weight: 600;
}

.adm-dd__check {
    display: inline-flex;
    width: 14px;
    height: 14px;
    color: transparent;
    flex-shrink: 0;
}

.adm-dd__check svg {
    width: 14px;
    height: 14px;
}

.adm-dd__option.is-selected .adm-dd__check {
    color: #7c3aed;
}

/* ===== Shared components: confirm modal ===== */
.adm-modal {
    position: fixed;
    inset: 0;
    z-index: 100050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.16s ease;
}

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

.adm-modal.is-open {
    opacity: 1;
}

.adm-modal__box {
    width: 100%;
    max-width: 400px;
    padding: 1.5rem;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 24px 60px -20px rgba(15, 23, 42, 0.35);
    transform: translateY(8px) scale(0.98);
    transition: transform 0.16s ease;
}

.adm-modal.is-open .adm-modal__box {
    transform: none;
}

.adm-modal__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
    border-radius: 14px;
}

.adm-modal__icon svg {
    width: 24px;
    height: 24px;
}

.adm-modal__icon.is-danger {
    background: #fef3f2;
    color: #d92d20;
}

.adm-modal__icon.is-primary {
    background: #f4f0ff;
    color: #7c3aed;
}

.adm-modal__title {
    margin: 0 0 0.4rem;
    font-size: 1.0625rem;
    font-weight: 800;
    color: #101828;
}

.adm-modal__text {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.55;
    color: #475467;
}

.adm-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 1.5rem;
}

/* ===== Shared components: toast ===== */
.adm-toasts {
    position: fixed;
    top: 1.25rem;
    right: 1.25rem;
    z-index: 100100;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    pointer-events: none;
}

.adm-toast {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    max-width: 360px;
    padding: 0.8rem 1rem;
    border: 1px solid #eaecf0;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 16px 36px -14px rgba(15, 23, 42, 0.28);
    font-size: 0.875rem;
    font-weight: 600;
    color: #101828;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: auto;
}

.adm-toast.is-visible {
    opacity: 1;
    transform: none;
}

.adm-toast__icon {
    display: inline-flex;
    flex-shrink: 0;
}

.adm-toast__icon svg {
    width: 20px;
    height: 20px;
}

.adm-toast--success .adm-toast__icon {
    color: #039855;
}

.adm-toast--error {
    border-color: #fecdca;
    color: #d92d20;
}

.adm-toast--error .adm-toast__icon {
    color: #d92d20;
}

/* ===== Shared components: form fields (scoped to redesigned pages) ===== */
#adm-page .adm-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

#adm-page .adm-label {
    display: block;
    margin: 0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #64748b;
}

#adm-page .adm-input {
    width: 100%;
    height: 32px;
    min-height: 32px;
    max-height: 32px;
    padding: 0 10px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    box-sizing: border-box;
    background: #f8fafc;
    font: inherit;
    font-size: 12px;
    color: #0f172a;
    box-shadow: none;
    transition: border-color 0.15s ease, background 0.15s ease;
}

#adm-page input.adm-input[type='number'] {
    appearance: textfield;
    -moz-appearance: textfield;
}

#adm-page input.adm-input[type='number']::-webkit-inner-spin-button,
#adm-page input.adm-input[type='number']::-webkit-outer-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

#adm-page textarea.adm-input {
    height: auto;
    min-height: 88px;
    max-height: none;
    padding: 8px 10px;
    line-height: 1.5;
    resize: vertical;
}

#adm-page .adm-input:hover {
    border-color: #c4b5fd;
}

#adm-page .adm-input:focus {
    outline: none;
    border-color: #7c3aed;
    background: #fff;
}

#adm-page .adm-input.is-invalid {
    border-color: #f04438;
    background: #fff;
}

#adm-page .adm-hint {
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.4;
    color: #98a2b3;
}

#adm-page .adm-hint code {
    padding: 0.05rem 0.3rem;
    border-radius: 6px;
    background: #f4f0ff;
    color: #6d28d9;
    font-size: 0.72rem;
}

.adm-field-error {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: #d92d20;
}

.adm-field-error[hidden],
.adm-errors[hidden] {
    display: none;
}

.adm-errors {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid #fecdca;
    border-radius: 14px;
    background: #fef3f2;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #d92d20;
}

/* ===== Shared components: segmented filter ===== */
.adm-seg {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    height: 32px;
    padding: 2px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    box-sizing: border-box;
    background: #f8fafc;
    overflow-x: auto;
    scrollbar-width: none;
}

.adm-seg::-webkit-scrollbar {
    display: none;
}

.adm-seg__btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 100%;
    padding: 0 10px;
    border: 0;
    border-radius: 6px;
    box-sizing: border-box;
    background: transparent;
    color: #475569;
    font: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.adm-seg__btn:hover {
    color: #6d28d9;
}

.adm-seg__btn.is-active {
    background: #7c3aed;
    color: #fff;
    font-weight: 600;
}

.adm-seg__btn em {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 16px;
    padding: 0 5px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.06);
    font-size: 10px;
    font-style: normal;
    font-weight: 700;
}

.adm-seg__btn.is-active em {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
}

.adm-search,
.admin-ui label.adm-search {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    min-width: 200px;
    margin: 0;
    padding: 0 10px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    box-sizing: border-box;
    background: #f8fafc;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 500;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.adm-search:focus-within {
    border-color: #7c3aed;
    background: #fff;
}

.adm-search svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

#adm-page .adm-search input.adm-search__input {
    flex: 1;
    min-width: 0;
    height: 100%;
    min-height: 0;
    max-height: none;
    padding: 0;
    border: 0;
    background: transparent;
    font: inherit;
    font-size: 12px;
    color: #0f172a;
    box-shadow: none;
    outline: none;
}
