:root {
    --topbar: #344258;
    --topbar-dark: #2d394d;
    --sidebar: #ffffff;
    --page: #f1f3f7;
    --card: #ffffff;
    --text: #4a5368;
    --text-dark: #31384b;
    --muted: #8b98ad;
    --line: #e8ecf3;
    --accent: #ff6579;
    --accent-dark: #f04e64;
    --blue: #4f7cff;
    --cyan: #30b7d7;
    --green: #38c172;
    --gold: #f3bc30;
    --purple: #8668ff;
    --shadow: 0 12px 32px rgba(49, 56, 75, .08);
    --soft-shadow: 0 4px 18px rgba(49, 56, 75, .055);
    --radius: 6px;
    --sidebar-width: 250px;
    --topbar-height: 68px;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--page);
    font-size: 14px;
    line-height: 1.45;
}

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

button,
input {
    font: inherit;
}

.admin-shell {
    min-height: 100vh;
    padding-top: var(--topbar-height);
}

.topbar {
    height: var(--topbar-height);
    background: var(--topbar);
    color: rgba(255, 255, 255, .78);
    position: fixed;
    z-index: 50;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .04);
}

.topbar__left,
.topbar__right {
    display: flex;
    align-items: center;
    gap: 16px;
    height: 100%;
}

.brand {
    width: var(--sidebar-width);
    height: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 28px;
    color: #fff;
    font-weight: 800;
    letter-spacing: .7px;
    background: rgba(0, 0, 0, .05);
}

.brand__mark {
    width: 27px;
    height: 27px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    color: #fff;
    font-size: 11px;
    font-weight: 900;
    background: linear-gradient(135deg, #18b9c7, #2f80ff);
    box-shadow: 0 6px 16px rgba(24, 185, 199, .28);
}

.brand__text {
    font-size: 18px;
}

.icon-button,
.topbar-icon,
.user-menu__button,
.mega-menu,
.card-menu,
.button {
    border: 0;
    cursor: pointer;
}

.topbar__toggle {
    width: 42px;
    height: 42px;
    background: transparent;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 0 10px;
}

.topbar__toggle span {
    height: 2px;
    width: 18px;
    background: #aeb7c9;
    display: block;
    border-radius: 5px;
}

.topbar-search {
    height: 44px;
    width: 270px;
    border-radius: 22px;
    background: rgba(0, 0, 0, .2);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 15px;
    color: #aeb7c9;
}

.topbar-search input {
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    min-width: 0;
    width: 100%;
}

.topbar-search input::placeholder {
    color: #aeb7c9;
}

.topbar-search__hint {
    font-weight: 700;
    font-size: 12px;
    opacity: .9;
}

.mega-menu {
    background: transparent;
    color: #c7cfdd;
    font-weight: 600;
}

.topbar__right {
    gap: 8px;
    padding-right: 0;
}

.topbar-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #c7cfdd;
    border-radius: 10px;
}

.topbar-icon:hover,
.topbar__toggle:hover,
.user-menu__button:hover {
    background: rgba(255, 255, 255, .07);
}

.user-menu {
    position: relative;
    height: 100%;
}

.user-menu__button {
    height: 100%;
    min-width: 205px;
    background: var(--topbar-dark);
    color: #fff;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 18px;
}

.user-menu__avatar {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #eef2f8;
    color: var(--topbar-dark);
    font-weight: 800;
    font-size: 12px;
}

.user-menu__meta {
    text-align: left;
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.user-menu__meta strong {
    font-size: 13px;
}

.user-menu__meta small {
    color: #aeb7c9;
    font-size: 11px;
    margin-top: 3px;
}

.user-menu__chevron {
    color: #aeb7c9;
}

.user-menu__dropdown {
    position: absolute;
    right: 12px;
    top: calc(100% + 8px);
    width: 170px;
    background: #fff;
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-5px);
    transition: .16s ease;
}

.user-menu__dropdown.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-menu__dropdown a {
    display: block;
    padding: 10px 12px;
    border-radius: 5px;
    font-weight: 700;
    font-size: 13px;
}

.user-menu__dropdown a:hover {
    background: #f6f8fb;
    color: var(--accent);
}

.sidebar {
    position: fixed;
    top: var(--topbar-height);
    left: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: var(--sidebar);
    border-right: 1px solid #edf0f5;
    z-index: 40;
    transition: transform .2s ease, width .2s ease;
}

.sidebar__scroll {
    height: 100%;
    overflow: auto;
    padding: 22px 20px 24px;
}

.sidebar-group + .sidebar-group {
    margin-top: 27px;
}

.sidebar-group__label {
    color: #9aa5b6;
    font-weight: 800;
    font-size: 11px;
    letter-spacing: .75px;
    margin-bottom: 9px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 10px 2px;
    color: #697386;
    font-weight: 600;
    position: relative;
    border-radius: 7px;
}

.sidebar-link:hover,
.sidebar-link.is-active {
    color: #3f4a5f;
}

.sidebar-link__icon {
    width: 22px;
    color: #8791a3;
    font-size: 17px;
    text-align: center;
}

.sidebar-link.is-active .sidebar-link__icon,
.sidebar-link:hover .sidebar-link__icon {
    color: var(--accent);
}

.sidebar-link__text {
    flex: 1;
}

.sidebar-link__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 23px;
    height: 18px;
    border-radius: 14px;
    background: #31b9e6;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
}

.sidebar-link__chevron {
    color: #aeb7c9;
    font-size: 18px;
}

.sidebar-link.is-disabled {
    cursor: default;
}

.sidebar-upgrade {
    margin-top: 32px;
    padding: 22px 18px;
    text-align: center;
    border-radius: 6px;
    background: #f3f6fb;
}

.sidebar-upgrade strong {
    display: block;
    color: #3d4659;
    margin-bottom: 7px;
}

.sidebar-upgrade p {
    margin: 0 0 14px;
    color: #9aa5b6;
    font-size: 13px;
}

.sidebar-upgrade span {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 4px;
    background: #456be7;
    color: #fff;
    font-weight: 800;
    font-size: 12px;
}

.main-content {
    margin-left: var(--sidebar-width);
    padding: 28px 26px 92px;
    transition: margin-left .2s ease;
}

.page-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
}

.page-head h1 {
    margin: 0;
    color: #42495d;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: .2px;
    text-transform: uppercase;
}

.page-head p {
    margin: 6px 0 0;
    color: var(--muted);
}

.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #9aa5b6;
    font-size: 13px;
}

.breadcrumbs a:hover {
    color: var(--accent);
}

.metric-grid,
.dashboard-grid,
.people-grid {
    display: grid;
    gap: 24px;
}

.metric-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 24px;
}

.metric-card,
.card,
.person-card {
    background: var(--card);
    border: 1px solid rgba(232, 236, 243, .75);
    border-radius: var(--radius);
    box-shadow: var(--soft-shadow);
}

.metric-card {
    min-height: 132px;
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.metric-card::after {
    content: "";
    position: absolute;
    right: -28px;
    top: -30px;
    width: 108px;
    height: 108px;
    border-radius: 50%;
    background: rgba(255, 101, 121, .1);
}

.metric-card--primary {
    background: linear-gradient(135deg, #ffffff 0%, #fff5f7 100%);
}

.metric-card__eyebrow {
    display: block;
    color: #8c97aa;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .45px;
    text-transform: uppercase;
}

.metric-card strong {
    display: block;
    margin-top: 12px;
    color: var(--text-dark);
    font-size: 30px;
    line-height: 1;
}

.metric-card p {
    margin: 12px 0 0;
    color: var(--muted);
    max-width: 260px;
}

.dashboard-grid--top {
    grid-template-columns: 1.05fr 1.05fr 1fr;
    margin-bottom: 24px;
}

.dashboard-grid--bottom {
    grid-template-columns: 1.1fr .9fr;
    margin-bottom: 24px;
}

.card {
    padding: 0;
    overflow: hidden;
}

.card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px 18px;
}

.card__header h2 {
    margin: 0;
    color: #3d4659;
    font-size: 15px;
    font-weight: 800;
}

.card__header p {
    margin: 6px 0 0;
    color: #8b98ad;
    font-size: 13px;
}

.card-menu {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: transparent;
    color: #7d899d;
    font-size: 20px;
    line-height: 1;
}

.card-menu:hover {
    background: #f5f7fb;
}

.card--tall {
    min-height: 374px;
}

.donut-wrap {
    position: relative;
    width: 260px;
    height: 260px;
    margin: 0 auto;
}

.donut-wrap canvas {
    display: block;
}

.donut-center {
    position: absolute;
    inset: 76px;
    border-radius: 50%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    box-shadow: inset 0 0 0 1px #f0f2f6;
}

.donut-center strong {
    color: #3d4659;
    font-size: 23px;
}

.donut-center span {
    color: #9aa5b6;
    font-size: 12px;
}

.legend-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px 18px;
    padding: 2px 22px 24px;
    color: #8b98ad;
    font-size: 12px;
}

.legend-dot {
    width: 10px;
    height: 10px;
    display: inline-block;
    border-radius: 50%;
    margin-right: 6px;
}

.legend-dot--one { background: var(--accent); }
.legend-dot--two { background: #ff9bac; }
.legend-dot--three { background: #ffc8d1; }
.legend-dot--four { background: #f1dbe0; }

.bar-chart {
    padding: 32px 26px 26px;
}

.bar-row {
    display: grid;
    grid-template-columns: 54px 1fr 66px;
    align-items: center;
    gap: 14px;
    margin-bottom: 23px;
}

.bar-row span,
.bar-row strong {
    color: #596175;
    font-weight: 800;
}

.bar-row div,
.progress-line {
    height: 7px;
    border-radius: 7px;
    background: #edf2f8;
    overflow: hidden;
}

.bar-row i,
.progress-line i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent), #ff9bac);
}

.snapshot-list {
    padding: 6px 24px 24px;
}

.snapshot-list div {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid #f0f2f6;
}

.snapshot-list div:last-child {
    border-bottom: 0;
}

.snapshot-list span {
    color: #7f8ba0;
    font-weight: 700;
}

.snapshot-list strong {
    color: #3d4659;
    font-size: 18px;
}

.people-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 24px;
}

.person-card {
    min-height: 96px;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 22px;
}

.person-card__avatar {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 12px;
    font-weight: 900;
}

.person-card__avatar--red { background: linear-gradient(135deg, #ff6579, #ff8a9a); }
.person-card__avatar--gold { background: linear-gradient(135deg, #f3bc30, #f8d77e); color: #5f4200; }
.person-card__avatar--blue { background: linear-gradient(135deg, #4f7cff, #67c4ff); }
.person-card__avatar--green { background: linear-gradient(135deg, #38c172, #76df9f); }

.person-card strong,
.person-card small,
.person-card em {
    display: block;
}

.person-card strong {
    color: #3d4659;
    font-size: 14px;
}

.person-card small {
    color: #768296;
    margin-top: 3px;
}

.person-card em {
    color: #1fb565;
    font-size: 12px;
    font-style: normal;
    font-weight: 800;
    margin-top: 7px;
}

.text-warning { color: #e5a313 !important; }
.text-info { color: #28a8c9 !important; }
.text-success { color: #1fb565 !important; }

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 35px;
    padding: 0 15px;
    border-radius: 5px;
    font-weight: 800;
    font-size: 12px;
}

.button--light {
    background: #f3f6fb;
    color: #687386;
}

.button--accent {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 6px 16px rgba(255, 101, 121, .24);
}

.button--accent:hover,
.button--login:hover {
    background: var(--accent-dark);
}

.adlevel-list {
    padding: 4px 24px 26px;
}

.adlevel-row + .adlevel-row {
    margin-top: 19px;
}

.adlevel-row__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    color: #687386;
    font-weight: 800;
}

.progress-line {
    height: 6px;
}

.table-wrap {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 520px;
}

.admin-table th,
.admin-table td {
    padding: 15px 24px;
    border-top: 1px solid #eef1f6;
    text-align: left;
    vertical-align: middle;
}

.admin-table th {
    background: #f7f9fc;
    color: #9aa5b6;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .45px;
}

.admin-table td {
    color: #596175;
    font-weight: 600;
}

.admin-table td strong {
    display: block;
    color: #3d4659;
    font-size: 13px;
}

.admin-table td span:not(.pill):not(.status-dot) {
    display: block;
    color: #96a2b5;
    font-size: 12px;
    margin-top: 4px;
    font-weight: 600;
}

.admin-table--large {
    min-width: 780px;
}

.empty-state,
.empty-table {
    color: #9aa5b6;
    text-align: center;
}

.status-dot {
    width: 8px;
    height: 8px;
    display: inline-block;
    border-radius: 50%;
    margin-right: 8px;
    vertical-align: 1px;
}

.status-dot--warning { background: var(--gold); }
.status-dot--muted { background: #c5ccd8; }

.pill {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
}

.pill--success {
    color: #119653;
    background: #e8f8ee;
}

.pill--warning {
    color: #ad7c06;
    background: #fff6d9;
}

.pill--danger {
    color: #cf3d50;
    background: #ffedf0;
}

.admin-footer {
    position: fixed;
    left: var(--sidebar-width);
    right: 0;
    bottom: 0;
    z-index: 35;
    min-height: 58px;
    background: rgba(247, 249, 252, .94);
    backdrop-filter: blur(10px);
    border-top: 1px solid #e9edf4;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 0 28px;
    color: #7d899d;
    font-size: 13px;
    transition: left .2s ease;
}

.admin-footer__links {
    display: flex;
    align-items: center;
    gap: 28px;
}

.admin-footer a:hover {
    color: var(--accent);
}

.admin-shell.sidebar-collapsed .sidebar {
    transform: translateX(calc(-1 * var(--sidebar-width)));
}

.admin-shell.sidebar-collapsed .main-content {
    margin-left: 0;
}

.admin-shell.sidebar-collapsed .admin-footer {
    left: 0;
}

.login-body {
    min-height: 100vh;
    background: radial-gradient(circle at top left, rgba(255, 101, 121, .16), transparent 30%), #f1f3f7;
}

.login-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
}

.login-panel {
    width: min(450px, 100%);
}

.login-panel__brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 13px;
    margin-bottom: 22px;
    color: #334058;
}

.login-panel__brand span {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(135deg, #18b9c7, #2f80ff);
    font-weight: 900;
}

.login-panel__brand strong,
.login-panel__brand small {
    display: block;
}

.login-panel__brand strong {
    font-size: 15px;
    letter-spacing: .75px;
}

.login-panel__brand small {
    color: #8b98ad;
    margin-top: 2px;
}

.login-card {
    background: #fff;
    border: 1px solid rgba(232, 236, 243, .85);
    border-radius: 10px;
    box-shadow: var(--shadow);
    padding: 34px;
}

.login-card__head {
    margin-bottom: 26px;
    text-align: center;
}

.login-card__head h1 {
    margin: 0;
    color: #31384b;
    font-size: 26px;
}

.login-card__head p {
    margin: 8px 0 0;
    color: #8b98ad;
}

.login-form label {
    display: block;
    color: #566177;
    font-weight: 800;
    margin: 16px 0 7px;
}

.login-form input {
    width: 100%;
    height: 46px;
    border: 1px solid #dde4ef;
    border-radius: 5px;
    outline: 0;
    padding: 0 14px;
    color: #394154;
    background: #fff;
}

.login-form input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 101, 121, .12);
}

.button--login {
    width: 100%;
    height: 48px;
    margin-top: 24px;
    color: #fff;
    background: var(--accent);
    box-shadow: 0 9px 20px rgba(255, 101, 121, .24);
}

.alert {
    border-radius: 5px;
    padding: 12px 14px;
    margin-bottom: 18px;
    font-weight: 700;
}

.alert--danger {
    color: #c43a4d;
    background: #ffedf0;
    border: 1px solid #ffd4dc;
}

@media (max-width: 1300px) {
    .metric-grid,
    .people-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-grid--top,
    .dashboard-grid--bottom {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 980px) {
    :root {
        --sidebar-width: 236px;
    }

    .topbar-search,
    .mega-menu,
    .topbar-icon:not(:first-child) {
        display: none;
    }

    .sidebar {
        transform: translateX(calc(-1 * var(--sidebar-width)));
    }

    .admin-shell.mobile-sidebar-open .sidebar {
        transform: translateX(0);
        box-shadow: 0 18px 42px rgba(49, 56, 75, .2);
    }

    .main-content,
    .admin-footer {
        margin-left: 0;
        left: 0;
    }
}

@media (max-width: 700px) {
    .brand {
        width: auto;
        min-width: 174px;
        padding: 0 18px;
    }

    .brand__text {
        font-size: 15px;
    }

    .user-menu__button {
        min-width: 0;
        padding: 0 12px;
    }

    .user-menu__meta,
    .user-menu__chevron {
        display: none;
    }

    .main-content {
        padding: 22px 16px 96px;
    }

    .page-head {
        display: block;
    }

    .breadcrumbs {
        margin-top: 12px;
    }

    .metric-grid,
    .people-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .dashboard-grid {
        gap: 16px;
    }

    .card__header,
    .metric-card,
    .person-card {
        padding: 20px;
    }

    .donut-wrap {
        width: 220px;
        height: 220px;
    }

    .donut-wrap canvas {
        width: 220px;
        height: 220px;
    }

    .donut-center {
        inset: 65px;
    }

    .admin-footer {
        position: static;
        flex-direction: column;
        align-items: flex-start;
        padding: 18px 20px;
    }
}

/* Customers data table viewer */
.datatable-card {
    background: #fff;
    border: 1px solid rgba(232, 236, 243, .9);
    border-radius: 6px;
    box-shadow: var(--soft-shadow);
    overflow: hidden;
}

.datatable-card__head {
    padding: 27px 30px 17px;
}

.datatable-card__head h2 {
    margin: 0;
    color: #4a5368;
    font-size: 17px;
    font-weight: 800;
}

.datatable-card__head p {
    margin: 4px 0 0;
    color: #9aa5b6;
    font-size: 14px;
}

.datatable-tabs {
    display: flex;
    align-items: flex-end;
    gap: 24px;
    padding: 0 30px;
    border-bottom: 1px solid #eef1f6;
}

.datatable-tab {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: #5d6678;
    font-weight: 800;
    position: relative;
}

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

.datatable-tab.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    background: var(--accent);
}

.datatable-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 30px 15px;
    border-top: 1px solid #eef1f6;
}

.datatable-toolbar__left,
.datatable-toolbar__right,
.datatable-toolbar label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.datatable-toolbar__left {
    gap: 18px;
}

.datatable-toolbar__right--customer-searches {
    gap: 22px;
    flex-wrap: nowrap;
    justify-content: flex-end;
    align-items: center;
}

.datatable-search-group {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
    white-space: nowrap;
    flex: 0 0 auto;
}

.datatable-search-group label {
    flex-wrap: nowrap;
    flex: 0 0 auto;
    width: auto;
}

.datatable-search-group .datatable-search-button {
    flex: 0 0 auto;
    white-space: nowrap;
}

.datatable-search-group--qbid {
    padding-right: 18px;
    border-right: 1px solid #e6ebf3;
}

.datatable-search-group--qbid input[type="search"] {
    width: 84px;
    min-width: 84px;
}

.datatable-toolbar span,
.datatable-toolbar label {
    color: #4f586b;
    font-weight: 600;
}

.datatable-toolbar select,
.datatable-toolbar input[type="search"] {
    height: 38px;
    border: 1px solid #d8e0eb;
    border-radius: 5px;
    background: #fff;
    color: #566177;
    outline: 0;
}

.datatable-toolbar select {
    min-width: 77px;
    padding: 0 28px 0 12px;
}

.datatable-toolbar input[type="search"] {
    width: 235px;
    padding: 0 12px;
}

.datatable-toolbar select:focus,
.datatable-toolbar input[type="search"]:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 101, 121, .1);
}

.datatable-search-button,
.datatable-clear {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 800;
    padding: 0 13px;
}

.datatable-search-button {
    border: 0;
    background: var(--accent);
    color: #fff;
    cursor: pointer;
}

.datatable-search-button:hover {
    background: var(--accent-dark);
}

.datatable-clear {
    color: #657388;
    background: #f3f6fb;
}

.datatable-clear:hover {
    color: var(--accent);
}

.datatable-wrap {
    overflow-x: auto;
    padding: 0 30px;
}

.datatable-table {
    width: 100%;
    min-width: 1280px;
    border-collapse: collapse;
}

.datatable-table th,
.datatable-table td {
    border-bottom: 1px solid #eef1f6;
    text-align: left;
    vertical-align: middle;
}

.datatable-table th {
    color: #5b6376;
    font-size: 13px;
    font-weight: 900;
    padding: 18px 10px;
}

.datatable-table td {
    color: #555e70;
    font-size: 14px;
    font-weight: 600;
    padding: 15px 10px;
}

.datatable-table tbody tr:nth-child(odd) {
    background: #f7f9fc;
}

.datatable-table tbody tr:hover {
    background: #fff2f5;
}

.datatable-table td strong {
    display: block;
    color: #42495d;
    font-size: 14px;
    font-weight: 800;
}

.datatable-table td span:not(.status-badge):not(.datatable-action-disabled):not(.datatable-muted-text):not(.datatable-last-sold-line) {
    display: block;
    margin-top: 3px;
    color: #8e9aab;
    font-size: 12px;
    font-weight: 600;
}

.datatable-sub-link,
.datatable-phone-link {
    color: #6d7890;
    font-weight: 700;
}

.datatable-sub-link {
    display: inline-flex;
    margin-top: 3px;
    font-size: 12px;
}

.datatable-sub-link:hover,
.datatable-phone-link:hover {
    color: var(--accent);
}

.datatable-date-value {
    font-size: 13px !important;
}

.datatable-last-sold-line {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 3px;
    color: #8e9aab;
    font-size: 12px;
    font-weight: 700;
}

.datatable-last-sold-line span {
    display: inline-flex !important;
    margin-top: 0 !important;
    color: inherit !important;
    font-size: inherit !important;
    font-weight: inherit !important;
}

.datatable-muted-text {
    color: #7c8799;
    font-size: 13px;
    line-height: 1.35;
}

.datatable-sort {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #5b6376;
}

.datatable-sort i {
    color: #c2c9d5;
    font-style: normal;
    font-size: 14px;
    line-height: 1;
}

.datatable-sort.is-sorted,
.datatable-sort:hover {
    color: #41495d;
}

.datatable-sort.is-sorted i,
.datatable-sort:hover i {
    color: var(--accent);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    gap: 7px;
    font-size: 13px;
    font-weight: 800;
}

.status-badge i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-badge--success {
    color: #1fb565;
}

.status-badge--success i {
    background: #38c172;
}

.status-badge--warning {
    color: #c69213;
}

.status-badge--warning i {
    background: #f3bc30;
}

.status-badge--danger {
    color: #d64b5e;
}

.status-badge--danger i {
    background: var(--accent);
}

.datatable-action-disabled {
    display: inline-flex;
    align-items: center;
    min-height: 27px;
    padding: 0 10px;
    border-radius: 5px;
    color: #9aa5b6;
    background: #f3f6fb;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}

.datatable-empty {
    text-align: center !important;
    color: #9aa5b6 !important;
    padding: 36px 10px !important;
    background: #fff !important;
}

.datatable-footerbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 19px 30px 27px;
    color: #4f586b;
    font-weight: 800;
}

.datatable-footerbar span {
    color: #9aa5b6;
    font-weight: 600;
}

.datatable-pagination {
    display: flex;
    align-items: center;
    gap: 8px;
}

.datatable-pagination a,
.datatable-pagination span {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    color: #657388;
    background: #fff;
    border: 1px solid #e2e8f1;
    font-weight: 800;
}

.datatable-pagination a:hover,
.datatable-pagination span.is-active {
    color: #fff;
    background: var(--accent);
    border-color: var(--accent);
}

.datatable-pagination span.is-disabled {
    opacity: .45;
}

@media (max-width: 1450px) {
    .datatable-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .datatable-toolbar__right--customer-searches {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
}

@media (max-width: 1200px) {
    .datatable-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .datatable-toolbar__right {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
}

@media (max-width: 700px) {
    .datatable-card__head,
    .datatable-toolbar,
    .datatable-wrap,
    .datatable-footerbar,
    .datatable-tabs {
        padding-left: 18px;
        padding-right: 18px;
    }

    .datatable-toolbar__left,
    .datatable-toolbar__right {
        flex-direction: column;
        align-items: flex-start;
    }

    .datatable-toolbar__right--customer-searches,
    .datatable-search-group {
        width: 100%;
        gap: 10px;
    }

    .datatable-search-group {
        flex-direction: column;
        align-items: flex-start;
    }

    .datatable-search-group--qbid {
        padding-right: 0;
        padding-bottom: 14px;
        border-right: 0;
        border-bottom: 1px solid #e6ebf3;
    }

    .datatable-toolbar label,
    .datatable-toolbar input[type="search"],
    .datatable-toolbar select,
    .datatable-search-button,
    .datatable-clear {
        width: 100%;
    }

    .datatable-toolbar label {
        align-items: flex-start;
        flex-direction: column;
    }

    .datatable-footerbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .datatable-pagination {
        flex-wrap: wrap;
    }
}

/* Customer edit module */
.datatable-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 27px;
    padding: 0 12px;
    border-radius: 5px;
    color: #fff;
    background: var(--accent);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
    box-shadow: 0 5px 14px rgba(255, 101, 121, .2);
}

.datatable-action-button:hover {
    background: var(--accent-dark);
    color: #fff;
}

.alert--success {
    color: #15995a;
    background: #e9f8ef;
    border: 1px solid #ccefd9;
}

.customer-edit-page {
    padding-bottom: 115px;
}

.customer-edit-actions {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px;
    margin: -8px 0 18px;
}

.customer-edit-form {
    display: grid;
    gap: 20px;
}

.form-card {
    background: #fff;
    border: 1px solid rgba(232, 236, 243, .9);
    border-radius: 6px;
    box-shadow: var(--soft-shadow);
    overflow: hidden;
}

.form-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 30px 17px;
    border-bottom: 1px solid #eef1f6;
}

.form-card__head h2 {
    margin: 0;
    color: #4a5368;
    font-size: 17px;
    font-weight: 800;
}

.form-card__head p {
    margin: 5px 0 0;
    color: #9aa5b6;
    font-size: 13px;
}

.form-card--blank {
    min-height: 92px;
}

.form-grid {
    display: grid;
    gap: 18px 20px;
    padding: 24px 30px 30px;
}

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

.form-grid--one {
    grid-template-columns: minmax(0, 1fr);
}

.form-grid__wide {
    grid-column: 1 / -1;
}

.admin-form-field {
    display: grid;
    gap: 8px;
}

.admin-form-field > span,
.admin-form-field > label > span {
    color: #4f586b;
    font-size: 13px;
    font-weight: 800;
}

.admin-form-field em {
    color: var(--accent);
    font-style: normal;
}

.admin-form-control {
    width: 100%;
    min-height: 42px;
    border: 1px solid #d8e0eb;
    border-radius: 5px;
    background: #fff;
    color: #566177;
    outline: 0;
    padding: 0 12px;
    font-size: 14px;
    font-weight: 600;
}

select.admin-form-control {
    padding-right: 32px;
}

.admin-form-control--textarea {
    min-height: 132px;
    padding-top: 11px;
    padding-bottom: 11px;
    resize: vertical;
    line-height: 1.55;
}

.admin-form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 101, 121, .1);
}

.category-check-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.check-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    min-height: 58px;
    border: 1px solid #e6ebf3;
    border-radius: 6px;
    background: #fbfcfe;
    padding: 12px;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.check-card:hover {
    border-color: #ffd4dc;
    background: #fff7f9;
}

.check-card input {
    margin-top: 2px;
    accent-color: var(--accent);
}

.check-card strong {
    display: block;
    color: #42495d;
    font-size: 13px;
    font-weight: 800;
}

.check-card small {
    display: block;
    margin-top: 2px;
    color: #9aa5b6;
    font-size: 11px;
    font-weight: 700;
}

.status-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 24px 30px 30px;
}

.switch-check {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    cursor: pointer;
    color: #4f586b;
    font-weight: 800;
}

.switch-check input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.switch-check > span {
    width: 42px;
    height: 24px;
    border-radius: 999px;
    background: #d9e1ec;
    position: relative;
    transition: background .15s ease;
}

.switch-check > span::after {
    content: "";
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    position: absolute;
    left: 3px;
    top: 3px;
    box-shadow: 0 2px 7px rgba(49, 56, 75, .18);
    transition: transform .15s ease;
}

.switch-check input:checked + span {
    background: var(--accent);
}

.switch-check input:checked + span::after {
    transform: translateX(18px);
}

.switch-check--large {
    font-size: 15px;
}

.hours-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 30px 18px;
}

.hours-top-row p {
    max-width: 600px;
    margin: 0;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 600;
}

.form-divider {
    height: 1px;
    border: 0;
    background: #eef1f6;
    margin: 0;
}

.hours-table {
    padding: 18px 30px 30px;
    transition: opacity .15s ease;
}

.hours-table.is-muted-by-24hours {
    opacity: .58;
}

.hours-row {
    display: grid;
    grid-template-columns: 150px 140px 1fr 1fr;
    gap: 14px;
    align-items: center;
    padding: 9px 0;
    border-bottom: 1px solid #f1f4f8;
}

.hours-row:last-child {
    border-bottom: 0;
}

.hours-row__day {
    color: #42495d;
    font-weight: 900;
}

.blank-section {
    color: #9aa5b6;
    font-weight: 700;
    padding: 4px 0;
}

.sticky-save-bar {
    position: fixed;
    right: 28px;
    bottom: 72px;
    z-index: 40;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border: 1px solid rgba(232, 236, 243, .9);
    border-radius: 8px;
    background: rgba(255, 255, 255, .94);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.sticky-save-bar .button {
    min-height: 40px;
    padding-left: 18px;
    padding-right: 18px;
}

@media (max-width: 1100px) {
    .category-check-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hours-row {
        grid-template-columns: 120px 135px 1fr 1fr;
    }
}

@media (max-width: 760px) {
    .form-card__head,
    .form-grid,
    .status-checks,
    .hours-top-row,
    .hours-table {
        padding-left: 18px;
        padding-right: 18px;
    }

    .form-grid--two,
    .category-check-grid,
    .hours-row {
        grid-template-columns: 1fr;
    }

    .hours-top-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .customer-edit-actions {
        justify-content: flex-start;
    }

    .sticky-save-bar {
        left: 18px;
        right: 18px;
        bottom: 18px;
        justify-content: space-between;
    }

    .sticky-save-bar .button {
        flex: 1 1 0;
    }
}

/* Customer edit geo module */
.geo-editor {
    padding: 24px 30px 30px;
}

.geo-editor__controls {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: end;
}

.geo-editor__address {
    min-width: 0;
}

.geo-editor__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-bottom: 1px;
}

.geo-editor__buttons .button {
    min-height: 42px;
    white-space: nowrap;
}

.geo-editor__coords {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    margin-top: 13px;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 700;
}

.geo-editor__coords strong {
    color: #4a5368;
    font-weight: 900;
}

.geo-editor__divider {
    margin: 20px -30px 0;
}

.geo-editor__map {
    width: 100%;
    height: 420px;
    margin-top: 24px;
    border: 1px solid #e6ebf3;
    border-radius: 6px;
    background: #eef1f6;
    overflow: hidden;
}

.geo-editor__note {
    margin: 12px 0 0;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 600;
}

.geo-editor__status {
    min-height: 20px;
    margin-top: 10px;
    font-size: 13px;
    font-weight: 800;
}

.geo-editor__status--success {
    color: #15995a;
}

.geo-editor__status--danger {
    color: #c43a4d;
}

.geo-editor__status--info {
    color: #28a8c9;
}

@media (max-width: 760px) {
    .geo-editor {
        padding-left: 18px;
        padding-right: 18px;
    }

    .geo-editor__controls {
        grid-template-columns: 1fr;
    }

    .geo-editor__buttons .button {
        flex: 1 1 0;
    }

    .geo-editor__divider {
        margin-left: -18px;
        margin-right: -18px;
    }

    .geo-editor__map {
        height: 340px;
    }
}

/* Customer edit image crop module */
.customer-image-editor {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
    padding: 24px 30px 30px;
}

.customer-image-preview {
    position: relative;
    width: 220px;
    height: 310px;
    border: 1px solid #e6ebf3;
    border-radius: 8px;
    background: #f7f9fc;
    box-shadow: 0 10px 24px rgba(49, 56, 75, .08);
    overflow: hidden;
    cursor: pointer;
    padding: 0;
}

.customer-image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.customer-image-preview__placeholder {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #9aa5b6;
    font-weight: 900;
    font-size: 18px;
    text-transform: lowercase;
    letter-spacing: .02em;
}

.customer-image-preview__overlay {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: rgba(49, 56, 75, .86);
    color: #fff;
    font-size: 12px;
    font-weight: 900;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity .15s ease, transform .15s ease;
}

.customer-image-preview:hover .customer-image-preview__overlay,
.customer-image-preview:focus .customer-image-preview__overlay {
    opacity: 1;
    transform: translateY(0);
}

.customer-image-editor__meta h3 {
    margin: 2px 0 7px;
    color: #42495d;
    font-size: 18px;
}

.customer-image-editor__meta p {
    margin: 0 0 13px;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 600;
}

.customer-image-editor__path {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    max-width: 100%;
    padding: 10px 12px;
    border: 1px solid #e6ebf3;
    border-radius: 6px;
    background: #fbfcfe;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 700;
}

.customer-image-editor__path strong {
    color: #4a5368;
    word-break: break-all;
}

.customer-image-editor__actions {
    margin-top: 16px;
}

.customer-image-editor__status {
    min-height: 20px;
    margin-top: 12px;
    font-size: 13px;
    font-weight: 900;
}

.customer-image-editor__status--success {
    color: #15995a;
}

.customer-image-editor__status--danger {
    color: #c43a4d;
}

.image-crop-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: rgba(35, 42, 61, .78);
}

.image-crop-modal.show {
    display: flex;
}

.image-crop-modal__panel {
    width: min(1180px, 96vw);
    max-height: 92vh;
    overflow: auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 24px 54px rgba(0, 0, 0, .28);
    border: 1px solid rgba(232, 236, 243, .9);
}

.image-crop-modal__head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 24px;
    border-bottom: 1px solid #eef1f6;
}

.image-crop-modal__head h2 {
    margin: 0;
    color: #4a5368;
    font-size: 20px;
}

.image-crop-modal__head p {
    margin: 6px 0 0;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 600;
}

.image-crop-modal__close {
    min-height: 38px;
    border: 0;
    border-radius: 5px;
    padding: 0 14px;
    color: #657388;
    background: #f3f6fb;
    font-weight: 900;
    cursor: pointer;
}

.image-crop-modal__close:hover {
    color: var(--accent);
}

.image-crop-modal__grid {
    display: grid;
    grid-template-columns: 340px minmax(0, 1fr);
    gap: 20px;
    padding: 24px;
}

.image-crop-controls,
.image-crop-workspace {
    border: 1px solid #e6ebf3;
    border-radius: 8px;
    background: #fff;
    padding: 18px;
}

.image-crop-controls {
    display: grid;
    gap: 14px;
    align-content: start;
}

.image-crop-controls h3 {
    margin: 0 0 2px;
    color: #42495d;
    font-size: 16px;
}

.image-crop-controls input[type="range"] {
    width: 100%;
    accent-color: var(--accent);
}

.image-paste-box {
    border: 2px dashed #ffc5cf;
    border-radius: 8px;
    background: #fff7f9;
    color: #9b5260;
    padding: 13px;
    text-align: center;
    line-height: 1.5;
    font-size: 13px;
    font-weight: 900;
}

.image-crop-controls__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.image-crop-help {
    margin: 0;
    color: #8b98ad;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
}

.image-crop-status {
    min-height: 20px;
    margin-bottom: 12px;
    color: #8b98ad;
    font-size: 13px;
    font-weight: 900;
}

.image-crop-status--success {
    color: #15995a;
}

.image-crop-status--danger {
    color: #c43a4d;
}

.image-crop-status--info {
    color: #28a8c9;
}

.image-stage-wrap {
    display: grid;
    place-items: center;
    min-height: 540px;
    padding: 20px;
    border-radius: 8px;
    background:
        linear-gradient(45deg, #e5e9f0 25%, transparent 25%),
        linear-gradient(-45deg, #e5e9f0 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #e5e9f0 75%),
        linear-gradient(-45deg, transparent 75%, #e5e9f0 75%);
    background-size: 24px 24px;
    background-position: 0 0, 0 12px, 12px -12px, -12px 0;
    user-select: none;
}

.image-crop-frame {
    position: relative;
    overflow: hidden;
    border: 2px solid #31384b;
    border-radius: 8px;
    background: #31384b;
    box-shadow: 0 16px 38px rgba(49, 56, 75, .22);
    cursor: grab;
}

.image-crop-frame.dragging {
    cursor: grabbing;
}

.image-crop-frame::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background-image:
        linear-gradient(to right, rgba(255, 255, 255, .2) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, .2) 1px, transparent 1px);
    background-size: 33.333% 100%, 100% 33.333%;
}

.image-crop-frame img {
    position: absolute;
    max-width: none;
    user-select: none;
    pointer-events: none;
    -webkit-user-drag: none;
}

.image-placeholder {
    display: grid;
    place-items: center;
    height: 100%;
    padding: 24px;
    color: #c8d0dc;
    text-align: center;
    line-height: 1.5;
    font-weight: 900;
}

@media (max-width: 980px) {
    .image-crop-modal__grid {
        grid-template-columns: 1fr;
    }

    .image-stage-wrap {
        min-height: 420px;
    }
}

@media (max-width: 760px) {
    .customer-image-editor {
        grid-template-columns: 1fr;
        padding-left: 18px;
        padding-right: 18px;
    }

    .customer-image-preview {
        width: 190px;
        height: 268px;
    }

    .image-crop-modal {
        padding: 12px;
    }

    .image-crop-modal__head,
    .image-crop-modal__grid {
        padding-left: 16px;
        padding-right: 16px;
    }

    .image-crop-modal__head {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* V15: force QBid search box to stay compact. This is intentionally placed
   after the generic datatable input width so it wins in the cascade. */
.datatable-toolbar .datatable-search-group--qbid input[type="search"] {
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    flex: 0 0 72px !important;
}

/* V16: universal tap/pressed behavior for admin buttons. */
button,
.button,
.datatable-search-button,
.datatable-clear,
.datatable-action-button,
.icon-button,
.topbar-icon,
.user-menu__button,
.card-menu,
.mega-menu {
    transition: transform .12s ease, background-color .12s ease, filter .12s ease, box-shadow .12s ease, color .12s ease;
    transform-origin: center;
}

button:active:not(:disabled),
.button:active:not(.is-disabled),
.datatable-search-button:active:not(:disabled),
.datatable-clear:active:not(.is-disabled),
.datatable-action-button:active:not(.is-disabled),
.icon-button:active:not(:disabled),
.topbar-icon:active:not(:disabled),
.user-menu__button:active:not(:disabled),
.card-menu:active:not(:disabled),
.mega-menu:active:not(:disabled) {
    transform: scale(.97);
    filter: brightness(.94);
}

button:disabled,
.button.is-disabled {
    cursor: not-allowed;
}


/* V17: customer table create button placement. */
.datatable-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.datatable-create-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0 16px;
    border: 0;
    border-radius: 5px;
    color: #fff;
    background: var(--accent);
    font-size: 13px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    box-shadow: 0 8px 18px rgba(255, 101, 121, .2);
    cursor: pointer;
}

.datatable-create-button:hover {
    background: var(--accent-dark);
}

@media (max-width: 640px) {
    .datatable-card__head {
        flex-direction: column;
        align-items: stretch;
    }

    .datatable-create-button {
        width: 100%;
    }
}


.datatable-create-button {
    transition: transform .12s ease, background-color .12s ease, filter .12s ease, box-shadow .12s ease, color .12s ease;
    transform-origin: center;
}

.datatable-create-button:active:not(:disabled) {
    transform: scale(.97);
    filter: brightness(.94);
}

/* V19: place Create New Customer in the top-right corner of the card header. */
.datatable-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.datatable-card__head .datatable-create-button {
    width: auto;
    flex: 0 0 auto;
    min-height: 35px;
    padding: 0 15px;
}

@media (max-width: 640px) {
    .datatable-card__head {
        flex-direction: column;
        align-items: stretch;
    }

    .datatable-card__head .datatable-create-button {
        width: 100%;
    }
}


/* V20: force the Customers card header to span the full card width and keep the action button inline on the right. */
.datatable-card {
    width: 100%;
    box-sizing: border-box;
}

.datatable-card > .datatable-card__head {
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    width: 100% !important;
    box-sizing: border-box !important;
    gap: 20px;
}

.datatable-card > .datatable-card__head .datatable-card__title {
    min-width: 0;
    flex: 1 1 auto;
}

.datatable-card > .datatable-card__head .datatable-card__actions {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    flex: 0 0 auto;
    margin-left: auto;
}

.datatable-card > .datatable-card__head .datatable-create-button {
    width: auto !important;
    flex: 0 0 auto;
    margin: 0;
}

@media (max-width: 640px) {
    .datatable-card > .datatable-card__head {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .datatable-card > .datatable-card__head .datatable-card__actions,
    .datatable-card > .datatable-card__head .datatable-create-button {
        width: 100% !important;
    }
}


/* V21: create-new-customer loader page. */
.admin-create-loader-card {
    min-height: 360px;
    margin: 0;
    padding: 54px 28px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 10px 35px rgba(36, 43, 60, .08);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.admin-create-loader-card h2 {
    margin: 18px 0 8px;
    color: #3d4356;
    font-size: 22px;
    font-weight: 800;
}

.admin-create-loader-card p {
    margin: 0;
    color: #8a97ad;
    font-size: 14px;
    font-weight: 600;
}

.admin-create-loader-card__link {
    margin-top: 24px;
    min-height: 38px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.admin-create-loader {
    width: 58px;
    height: 58px;
    border-radius: 999px;
    border: 5px solid #eef2f7;
    border-top-color: var(--accent);
    animation: admin-create-spin .8s linear infinite;
}

.admin-create-error-icon {
    width: 58px;
    height: 58px;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    font-weight: 900;
    box-shadow: 0 12px 24px rgba(255, 101, 121, .25);
}

@keyframes admin-create-spin {
    to {
        transform: rotate(360deg);
    }
}

/* V22: customer table row actions with edit + clone buttons. */
.datatable-row-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    white-space: nowrap;
}

.datatable-action-button--clone {
    text-transform: lowercase;
}


/* V24: right-align customer table action buttons. */
.datatable-actions-heading,
.datatable-actions-cell {
    text-align: right !important;
}

.datatable-actions-cell .datatable-row-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    width: 100%;
    white-space: nowrap;
}


/* V25: customer delete action and confirmation modal. */
.datatable-action-button--delete {
    border: 0;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background: #f1556c;
    font-family: inherit;
    text-transform: lowercase;
}

.datatable-action-button--delete:hover {
    background: #d94359;
    color: #fff;
}

.admin-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: rgba(31, 39, 57, .48);
    backdrop-filter: blur(3px);
}

.admin-modal-backdrop.is-open {
    display: flex;
}

.admin-modal {
    width: min(460px, 100%);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(31, 39, 57, .28);
    overflow: hidden;
    transform: translateY(0);
}

.admin-modal__head,
.admin-modal__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 18px 22px;
}

.admin-modal__head {
    border-bottom: 1px solid #edf1f7;
}

.admin-modal__head h3 {
    margin: 0;
    color: #3d4356;
    font-size: 18px;
    font-weight: 800;
}

.admin-modal__close {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 6px;
    background: #f3f6fb;
    color: #7b879c;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.admin-modal__close:hover {
    background: #e9eef6;
    color: #3d4356;
}

.admin-modal__body {
    padding: 22px;
}

.admin-modal__message {
    margin: 0 0 8px;
    color: #4f586b;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;
}

.admin-modal__message strong {
    color: #303545;
}

.admin-modal__muted {
    margin: 0;
    color: #8a97ad;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

.admin-modal__foot {
    justify-content: flex-end;
    border-top: 1px solid #edf1f7;
    background: #fbfcff;
}

.button--light {
    min-height: 36px;
    padding: 0 16px;
    border: 1px solid #dfe6f1;
    border-radius: 5px;
    color: #536176;
    background: #fff;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.button--light:hover {
    background: #f3f6fb;
    color: #303545;
}

.button--danger {
    min-height: 36px;
    padding: 0 16px;
    border: 0;
    border-radius: 5px;
    color: #fff;
    background: #f1556c;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(241, 85, 108, .22);
}

.button--danger:hover {
    background: #d94359;
    color: #fff;
}

.button--danger:disabled,
.button--light:disabled,
.admin-modal__close:disabled {
    opacity: .65;
    cursor: not-allowed;
}

.admin-modal-loader {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 12px 14px;
    border-radius: 7px;
    background: #f3f6fb;
    color: #4f586b;
}

.admin-modal-loader span {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    border: 3px solid #dfe6f1;
    border-top-color: #f1556c;
    animation: admin-modal-spin .75s linear infinite;
}

.admin-modal-loader strong {
    font-size: 13px;
    font-weight: 800;
}

.admin-modal-alert {
    margin-top: 16px;
    padding: 11px 13px;
    border-radius: 7px;
    background: #fff1f3;
    color: #bd3147;
    font-size: 13px;
    font-weight: 800;
}

@keyframes admin-modal-spin {
    to {
        transform: rotate(360deg);
    }
}
