/* =========================================================
   AYSELL GALLERY - ADMIN CATEGORIES
   categories.css
   ========================================================= */


/* =========================================================
   RESET
   ========================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    direction: rtl;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    font-family:
        Tahoma,
        Arial,
        sans-serif;
    background: #f7f7fb;
    color: #252535;
    overflow-x: hidden;
}

button,
input,
textarea,
select {
    font-family: inherit;
}

button {
    border: 0;
}

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

button,
a {
    -webkit-tap-highlight-color: transparent;
}


/* =========================================================
   LAYOUT
   ========================================================= */

.admin-layout {
    min-height: 100vh;
    display: flex;
    background: #f7f7fb;
}


/* =========================================================
   SIDEBAR
   ========================================================= */

.sidebar {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 1000;

    width: 270px;
    height: 100vh;

    display: flex;
    flex-direction: column;

    background:
        linear-gradient(
            180deg,
            #ffffff 0%,
            #fffafd 100%
        );

    border-left: 1px solid #eee6f2;

    box-shadow:
        -5px 0 25px rgba(90, 55, 95, 0.06);

    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}


/* =========================================================
   SIDEBAR HEADER
   ========================================================= */

.sidebar-header {
    min-height: 90px;

    display: flex;
    align-items: center;
    gap: 13px;

    padding: 20px 22px;

    border-bottom: 1px solid #f0e9f2;
}

.brand-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 15px;

    background:
        linear-gradient(
            135deg,
            #f9d5e8,
            #f5c2dc
        );

    box-shadow:
        0 7px 18px rgba(214, 107, 158, 0.16);

    font-size: 23px;
}

.sidebar-header h2 {
    margin-bottom: 4px;

    color: #292334;

    font-size: 17px;
    font-weight: 800;
}

.sidebar-header span {
    color: #98909d;
    font-size: 11px;
}


/* =========================================================
   SIDEBAR MENU
   ========================================================= */

.sidebar-menu {
    flex: 1;

    display: flex;
    flex-direction: column;

    gap: 6px;

    padding: 22px 14px;
}

.sidebar-menu a {
    min-height: 50px;

    display: flex;
    align-items: center;
    gap: 12px;

    padding: 0 15px;

    border-radius: 13px;

    color: #716a78;

    font-size: 13px;
    font-weight: 600;

    transition:
        background 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.sidebar-menu a:hover {
    color: #c24782;

    background: #fff0f7;

    transform: translateX(-2px);
}

.sidebar-menu a.active {
    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #d9689c,
            #c84f89
        );

    box-shadow:
        0 8px 20px rgba(201, 80, 137, 0.2);
}

.menu-icon {
    width: 27px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    font-size: 17px;
}


/* =========================================================
   SIDEBAR FOOTER
   ========================================================= */

.sidebar-footer {
    padding: 18px 22px 22px;

    border-top: 1px solid #f0e9f2;

    text-align: center;
}

.sidebar-footer span {
    display: block;

    color: #c85a8e;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1px;
}

.sidebar-footer small {
    display: block;

    margin-top: 5px;

    color: #aaa3ad;

    font-size: 10px;
}


/* =========================================================
   OVERLAY
   ========================================================= */

.sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 900;

    display: none;

    background: rgba(20, 15, 25, 0.45);

    backdrop-filter: blur(2px);
}

.sidebar-overlay.show {
    display: block;
}


/* =========================================================
   MAIN CONTENT
   ========================================================= */

.main-content {
    width: calc(100% - 270px);

    min-height: 100vh;

    margin-right: 270px;

    background: #f7f7fb;
}


/* =========================================================
   TOPBAR
   ========================================================= */

.topbar {
    min-height: 88px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding: 18px 30px;

    background: rgba(255, 255, 255, 0.92);

    border-bottom: 1px solid #ece7ef;

    backdrop-filter: blur(12px);

    position: sticky;
    top: 0;
    z-index: 500;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.topbar-right h1 {
    margin-bottom: 5px;

    color: #282331;

    font-size: 21px;
    font-weight: 800;
}

.topbar-right p {
    color: #9a939e;

    font-size: 11px;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}


/* =========================================================
   MENU TOGGLE
   ========================================================= */

.menu-toggle {
    width: 43px;
    height: 43px;

    display: none;
    align-items: center;
    justify-content: center;

    border-radius: 12px;

    background: #fff0f7;

    color: #c64e88;

    cursor: pointer;

    font-size: 21px;
}


/* =========================================================
   LOGOUT
   ========================================================= */

.logout-btn {
    min-height: 40px;

    padding: 0 17px;

    border-radius: 10px;

    background: #fff1f4;

    color: #d45d77;

    cursor: pointer;

    font-size: 12px;
    font-weight: 700;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.logout-btn:hover {
    background: #ffe3ea;
    transform: translateY(-1px);
}


/* =========================================================
   PAGE CONTENT
   ========================================================= */

.page-content {
    padding: 25px 30px 40px;
}


/* =========================================================
   BREADCRUMB
   ========================================================= */

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 18px;

    color: #aaa2ad;

    font-size: 11px;
}

.breadcrumb a {
    color: #c25789;

    transition: color 0.2s ease;
}

.breadcrumb a:hover {
    color: #a63c6c;
}

.breadcrumb strong {
    color: #77707b;
    font-weight: 600;
}


/* =========================================================
   PAGE HEADER
   ========================================================= */

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 25px;
}

.page-header h2 {
    margin-bottom: 7px;

    color: #2b2632;

    font-size: 19px;
    font-weight: 800;
}

.page-header p {
    color: #9c96a1;

    font-size: 11px;
}


/* =========================================================
   BUTTONS
   ========================================================= */

.primary-btn,
.secondary-btn,
.danger-btn {
    min-height: 43px;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 0 18px;

    border-radius: 11px;

    cursor: pointer;

    font-size: 12px;
    font-weight: 700;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.primary-btn {
    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #d9699d,
            #c64e87
        );

    box-shadow:
        0 7px 18px rgba(200, 79, 136, 0.2);
}

.primary-btn:hover {
    transform: translateY(-2px);

    box-shadow:
        0 10px 23px rgba(200, 79, 136, 0.28);
}

.secondary-btn {
    color: #6f6875;

    background: #f3f1f5;

    border: 1px solid #e8e3ea;
}

.secondary-btn:hover {
    background: #eae6ed;
}

.danger-btn {
    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #e16c78,
            #c84d5c
        );

    box-shadow:
        0 7px 18px rgba(200, 77, 92, 0.18);
}

.danger-btn:hover {
    transform: translateY(-1px);
}


/* =========================================================
   PAGE ERROR
   ========================================================= */

.page-error {
    display: none;

    margin-bottom: 18px;

    padding: 13px 16px;

    border-radius: 11px;

    background: #fff0f2;

    border: 1px solid #ffd6dc;

    color: #c24b5d;

    font-size: 12px;
}

.page-error.show {
    display: block;
}


/* =========================================================
   STATS
   ========================================================= */

.stats-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 16px;

    margin-bottom: 22px;
}

.stat-card {
    min-height: 100px;

    display: flex;
    align-items: center;

    gap: 14px;

    padding: 18px;

    background: #ffffff;

    border: 1px solid #eee9f0;

    border-radius: 15px;

    box-shadow:
        0 5px 20px rgba(55, 35, 65, 0.04);
}

.stat-icon {
    width: 51px;
    height: 51px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 14px;

    background: #fff0f7;

    font-size: 21px;
}

.stat-card span {
    display: block;

    margin-bottom: 7px;

    color: #99929e;

    font-size: 11px;
}

.stat-card strong {
    display: block;

    color: #302936;

    font-size: 21px;
    font-weight: 800;
}


/* =========================================================
   CATEGORY CARD
   ========================================================= */

.category-card {
    background: #ffffff;

    border: 1px solid #eee9f0;

    border-radius: 17px;

    box-shadow:
        0 5px 25px rgba(55, 35, 65, 0.045);

    overflow: hidden;
}

.card-header {
    min-height: 85px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding: 18px 21px;

    border-bottom: 1px solid #f0ebf1;
}

.card-header h3 {
    margin-bottom: 5px;

    color: #302936;

    font-size: 15px;
    font-weight: 800;
}

.card-header p {
    color: #aaa3ad;

    font-size: 10px;
}


/* =========================================================
   SEARCH
   ========================================================= */

.search-box {
    width: 270px;
    height: 41px;

    display: flex;
    align-items: center;

    gap: 9px;

    padding: 0 13px;

    border-radius: 10px;

    background: #faf9fb;

    border: 1px solid #ebe6ed;
}

.search-box span {
    flex-shrink: 0;

    font-size: 14px;
}

.search-box input {
    width: 100%;
    height: 100%;

    border: 0;
    outline: 0;

    background: transparent;

    color: #332e37;

    font-size: 11px;
}

.search-box input::placeholder {
    color: #aaa4ad;
}


/* =========================================================
   LOADING
   ========================================================= */

.loading-state {
    min-height: 260px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 14px;

    color: #99929d;

    font-size: 11px;
}

.loading-spinner {
    width: 36px;
    height: 36px;

    border: 3px solid #f3d9e6;

    border-top-color: #ca5b8d;

    border-radius: 50%;

    animation:
        categories-spin 0.8s linear infinite;
}

@keyframes categories-spin {

    to {
        transform: rotate(360deg);
    }

}


/* =========================================================
   EMPTY
   ========================================================= */

.empty-state {
    min-height: 260px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    padding: 30px;

    text-align: center;
}

.empty-state[hidden] {
    display: none;
}

.empty-icon {
    width: 65px;
    height: 65px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 15px;

    border-radius: 20px;

    background: #fff0f7;

    font-size: 28px;
}

.empty-state h3 {
    margin-bottom: 7px;

    color: #3a3440;

    font-size: 14px;
}

.empty-state p {
    color: #a29ba5;

    font-size: 11px;
}


/* =========================================================
   TABLE
   ========================================================= */

.table-wrapper {
    width: 100%;

    overflow-x: auto;
}

.table-wrapper[hidden] {
    display: none;
}

table {
    width: 100%;

    border-collapse: collapse;

    min-width: 760px;
}

thead {
    background: #fcfafc;
}

th {
    height: 52px;

    padding: 0 15px;

    color: #8f8792;

    font-size: 10px;
    font-weight: 700;

    text-align: right;

    white-space: nowrap;

    border-bottom: 1px solid #eee9ef;
}

td {
    min-height: 65px;

    padding: 12px 15px;

    color: #514a55;

    font-size: 11px;

    border-bottom: 1px solid #f1edf2;

    vertical-align: middle;
}

tbody tr {
    transition:
        background 0.2s ease;
}

tbody tr:hover {
    background: #fffafd;
}

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


/* =========================================================
   CATEGORY NAME
   ========================================================= */

.category-name {
    display: flex;
    align-items: center;

    gap: 11px;

    font-weight: 700;

    color: #3b3440;
}

.category-avatar {
    width: 38px;
    height: 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            #fff0f7,
            #fce4ef
        );

    font-size: 16px;
}


/* =========================================================
   SLUG
   ========================================================= */

.category-slug {
    direction: ltr;

    color: #8d8490;

    font-family:
        Consolas,
        Monaco,
        monospace;

    font-size: 10px;

    text-align: right;
}


/* =========================================================
   PRODUCT COUNT
   ========================================================= */

.product-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 35px;
    min-height: 28px;

    padding: 0 9px;

    border-radius: 8px;

    background: #f7f2f7;

    color: #756b78;

    font-size: 10px;
    font-weight: 700;
}


/* =========================================================
   STATUS
   ========================================================= */

.status-badge {
    min-width: 62px;
    min-height: 27px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 10px;

    border-radius: 20px;

    font-size: 9px;
    font-weight: 700;
}

.status-badge.active {
    color: #27845c;

    background: #eaf8f0;
}

.status-badge.inactive {
    color: #a16c35;

    background: #fff4e4;
}


/* =========================================================
   ACTIONS
   ========================================================= */

.action-buttons {
    display: flex;
    align-items: center;

    gap: 7px;
}

.action-btn {
    width: 34px;
    height: 34px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    cursor: pointer;

    font-size: 14px;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.action-btn:hover {
    transform: translateY(-1px);
}

.edit-btn {
    background: #f1f6ff;
    color: #4d78bd;
}

.edit-btn:hover {
    background: #e5efff;
}

.delete-btn {
    background: #fff0f2;
    color: #ce5d6d;
}

.delete-btn:hover {
    background: #ffe3e7;
}


/* =========================================================
   MODAL OVERLAY
   ========================================================= */

.modal-overlay {
    position: fixed;
    inset: 0;

    z-index: 2000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 20px;

    background: rgba(25, 18, 30, 0.5);

    backdrop-filter: blur(5px);

    opacity: 1;

    transition:
        opacity 0.2s ease;
}

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


/* =========================================================
   MODAL
   ========================================================= */

.modal {
    width: min(100%, 500px);

    max-height: calc(100vh - 40px);

    overflow-y: auto;

    padding: 0;

    background: #ffffff;

    border-radius: 18px;

    box-shadow:
        0 25px 70px rgba(35, 20, 40, 0.2);

    animation:
        modal-show 0.22s ease;
}

@keyframes modal-show {

    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

}


/* =========================================================
   MODAL HEADER
   ========================================================= */

.modal-header {
    min-height: 75px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    padding: 17px 20px;

    border-bottom: 1px solid #eee9ef;
}

.modal-header h3 {
    margin-bottom: 5px;

    color: #302936;

    font-size: 16px;
    font-weight: 800;
}

.modal-header p {
    color: #aaa3ad;

    font-size: 10px;
}

.modal-close {
    width: 34px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 9px;

    background: #f7f4f7;

    color: #807783;

    cursor: pointer;

    font-size: 22px;
    line-height: 1;

    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.modal-close:hover {
    background: #fff0f4;
    color: #c94f83;
}


/* =========================================================
   FORM
   ========================================================= */

#categoryForm {
    padding: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;

    margin-bottom: 8px;

    color: #4a434e;

    font-size: 11px;
    font-weight: 700;
}

.required {
    color: #d35c7e;
}

.form-control {
    width: 100%;

    min-height: 43px;

    padding: 0 13px;

    border: 1px solid #e7e1e9;

    border-radius: 10px;

    outline: none;

    background: #fcfbfd;

    color: #37313b;

    font-size: 11px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

textarea.form-control {
    height: auto;

    min-height: 105px;

    padding-top: 12px;
    padding-bottom: 12px;

    resize: vertical;

    line-height: 1.8;
}

.form-control:focus {
    background: #ffffff;

    border-color: #d36a9b;

    box-shadow:
        0 0 0 3px rgba(211, 106, 155, 0.1);
}

.form-control::placeholder {
    color: #b1aab4;
}

.form-group small {
    display: block;

    margin-top: 7px;

    color: #aaa3ad;

    font-size: 9px;
}


/* =========================================================
   SWITCH
   ========================================================= */

.switch-row {
    min-height: 38px;

    display: flex !important;
    align-items: center;

    gap: 10px;

    margin: 0 !important;

    cursor: pointer;
}

.switch-row input {
    position: absolute;

    opacity: 0;

    pointer-events: none;
}

.switch {
    position: relative;

    width: 42px;
    height: 23px;

    flex-shrink: 0;

    border-radius: 20px;

    background: #d9d4db;

    transition:
        background 0.2s ease;
}

.switch::after {
    content: "";

    position: absolute;

    top: 3px;
    right: 3px;

    width: 17px;
    height: 17px;

    border-radius: 50%;

    background: #ffffff;

    box-shadow:
        0 2px 5px rgba(0, 0, 0, 0.12);

    transition:
        transform 0.2s ease;
}

.switch-row input:checked + .switch {
    background: #cf6093;
}

.switch-row input:checked + .switch::after {
    transform: translateX(-19px);
}


/* =========================================================
   FORM ERROR
   ========================================================= */

.form-error {
    display: none;

    margin-bottom: 15px;

    padding: 11px 13px;

    border-radius: 9px;

    background: #fff0f2;

    border: 1px solid #ffd8de;

    color: #c24e60;

    font-size: 10px;

    line-height: 1.7;
}

.form-error.show {
    display: block;
}


/* =========================================================
   MODAL ACTIONS
   ========================================================= */

.modal-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 9px;

    padding-top: 3px;
}

.modal-actions .primary-btn,
.modal-actions .secondary-btn,
.modal-actions .danger-btn {
    min-width: 125px;
}


/* =========================================================
   DELETE MODAL
   ========================================================= */

.delete-modal {
    padding: 30px 25px;

    text-align: center;
}

.delete-icon {
    width: 65px;
    height: 65px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0 auto 15px;

    border-radius: 20px;

    background: #fff0f2;

    font-size: 28px;
}

.delete-modal h3 {
    margin-bottom: 9px;

    color: #342d36;

    font-size: 16px;
}

.delete-modal p {
    margin-bottom: 8px;

    color: #97909a;

    font-size: 11px;
}

.delete-modal strong {
    display: block;

    margin-bottom: 22px;

    color: #c24f69;

    font-size: 13px;
}

.delete-modal .modal-actions {
    justify-content: center;
}


/* =========================================================
   TOAST
   ========================================================= */

.toast-container {
    position: fixed;

    left: 25px;
    bottom: 25px;

    z-index: 5000;

    display: flex;
    flex-direction: column;

    gap: 9px;

    width: min(350px, calc(100vw - 30px));
}

.toast {
    min-height: 48px;

    display: flex;
    align-items: center;

    gap: 10px;

    padding: 11px 14px;

    border-radius: 11px;

    background: #ffffff;

    border: 1px solid #eee8ef;

    box-shadow:
        0 10px 30px rgba(40, 25, 45, 0.13);

    color: #4d4651;

    font-size: 11px;

    animation:
        toast-show 0.25s ease;
}

.toast.success {
    border-right: 4px solid #50a978;
}

.toast.error {
    border-right: 4px solid #d35b6b;
}

@keyframes toast-show {

    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}


/* =========================================================
   BODY LOCK
   ========================================================= */

body.menu-open {
    overflow: hidden;
}


/* =========================================================
   RESPONSIVE — TABLET
   ========================================================= */

@media (max-width: 1050px) {

    .sidebar {
        width: 245px;
    }

    .main-content {
        width: calc(100% - 245px);
        margin-right: 245px;
    }

    .stats-grid {
        gap: 12px;
    }

    .stat-card {
        padding: 15px;
    }

    .page-content {
        padding-right: 22px;
        padding-left: 22px;
    }

}


/* =========================================================
   RESPONSIVE — MOBILE
   ========================================================= */

@media (max-width: 800px) {

    .sidebar {
        width: 275px;

        transform: translateX(100%);

        box-shadow:
            -15px 0 40px rgba(30, 20, 35, 0.18);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        width: 100%;
        margin-right: 0;
    }

    .menu-toggle {
        display: inline-flex;
    }

    .topbar {
        min-height: 75px;

        padding: 15px 17px;
    }

    .topbar-right {
        gap: 10px;
    }

    .topbar-right h1 {
        font-size: 17px;
    }

    .topbar-right p {
        font-size: 9px;
    }

    .logout-btn {
        min-height: 37px;

        padding: 0 12px;

        font-size: 10px;
    }

    .page-content {
        padding: 19px 15px 30px;
    }

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

        margin-bottom: 20px;
    }

    .page-header h2 {
        font-size: 17px;
    }

    .primary-btn {
        min-height: 41px;
    }

    .stats-grid {
        grid-template-columns: 1fr;

        gap: 10px;
    }

    .stat-card {
        min-height: 83px;
    }

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

        padding: 16px;
    }

    .search-box {
        width: 100%;
    }

    .table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 730px;
    }

    .modal-overlay {
        align-items: flex-end;

        padding: 0;
    }

    .modal {
        width: 100%;

        max-height: 92vh;

        border-radius:
            20px 20px 0 0;
    }

    .delete-modal {
        border-radius: 20px 20px 0 0;

        padding-bottom:
            calc(25px + env(safe-area-inset-bottom));
    }

}


/* =========================================================
   RESPONSIVE — SMALL MOBILE
   ========================================================= */

@media (max-width: 480px) {

    .topbar-left {
        gap: 5px;
    }

    .logout-btn {
        padding: 0 10px;
    }

    .topbar-right h1 {
        font-size: 15px;
    }

    .topbar-right p {
        display: none;
    }

    .breadcrumb {
        margin-bottom: 14px;

        font-size: 9px;
    }

    .page-header h2 {
        font-size: 16px;
    }

    .page-header p {
        font-size: 10px;
    }

    .stat-card strong {
        font-size: 19px;
    }

    #categoryForm {
        padding: 17px;
    }

    .modal-header {
        padding: 15px 17px;
    }

    .modal-actions {
        flex-direction: column-reverse;
    }

    .modal-actions .primary-btn,
    .modal-actions .secondary-btn,
    .modal-actions .danger-btn {
        width: 100%;
    }

    .toast-container {
        left: 15px;
        right: 15px;
        bottom: 15px;

        width: auto;
    }

}


/* =========================================================
   DARK MODE
   ========================================================= */

body.dark-mode {
    background: #151219;
    color: #eee8f0;
}

body.dark-mode .admin-layout,
body.dark-mode .main-content {
    background: #151219;
}

body.dark-mode .sidebar {
    background:
        linear-gradient(
            180deg,
            #201a22 0%,
            #1b171e 100%
        );

    border-left-color: #302832;

    box-shadow:
        -8px 0 30px rgba(0, 0, 0, 0.2);
}

body.dark-mode .sidebar-header,
body.dark-mode .sidebar-footer {
    border-color: #302832;
}

body.dark-mode .sidebar-header h2 {
    color: #f5edf5;
}

body.dark-mode .sidebar-header span,
body.dark-mode .sidebar-footer small {
    color: #a89eaa;
}

body.dark-mode .sidebar-menu a {
    color: #aaa0ad;
}

body.dark-mode .sidebar-menu a:hover {
    background: #2d202b;
    color: #f08ab5;
}

body.dark-mode .sidebar-menu a.active {
    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #c65b8e,
            #a94373
        );
}

body.dark-mode .sidebar-footer span {
    color: #e178a8;
}

body.dark-mode .topbar {
    background: rgba(29, 24, 32, 0.94);

    border-bottom-color: #302832;
}

body.dark-mode .topbar-right h1 {
    color: #f3edf3;
}

body.dark-mode .topbar-right p {
    color: #a79da9;
}

body.dark-mode .menu-toggle {
    background: #30232d;
    color: #ed7dae;
}

body.dark-mode .logout-btn {
    background: #32232a;
    color: #ee8798;
}

body.dark-mode .logout-btn:hover {
    background: #412831;
}

body.dark-mode .breadcrumb {
    color: #8f858f;
}

body.dark-mode .breadcrumb strong {
    color: #bbb1bc;
}

body.dark-mode .page-header h2 {
    color: #f2ebf2;
}

body.dark-mode .page-header p {
    color: #9f959f;
}

body.dark-mode .category-card,
body.dark-mode .stat-card {
    background: #211b23;

    border-color: #302832;

    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.15);
}

body.dark-mode .stat-icon,
body.dark-mode .category-avatar,
body.dark-mode .empty-icon {
    background: #32232e;
}

body.dark-mode .stat-card span {
    color: #9e949f;
}

body.dark-mode .stat-card strong {
    color: #f0e9f0;
}

body.dark-mode .card-header {
    border-bottom-color: #302832;
}

body.dark-mode .card-header h3 {
    color: #eee7ee;
}

body.dark-mode .card-header p {
    color: #9f959f;
}

body.dark-mode .search-box {
    background: #19151b;
    border-color: #39303a;
}

body.dark-mode .search-box input {
    color: #eee8ee;
}

body.dark-mode .search-box input::placeholder {
    color: #817781;
}

body.dark-mode thead {
    background: #1c171e;
}

body.dark-mode th {
    color: #9b909c;
    border-bottom-color: #302832;
}

body.dark-mode td {
    color: #bcb2bd;
    border-bottom-color: #302832;
}

body.dark-mode tbody tr:hover {
    background: #281f29;
}

body.dark-mode .category-name {
    color: #e8e0e9;
}

body.dark-mode .category-slug {
    color: #958a96;
}

body.dark-mode .product-count {
    background: #302832;
    color: #b6abb7;
}

body.dark-mode .status-badge.active {
    background: #193329;
    color: #73c398;
}

body.dark-mode .status-badge.inactive {
    background: #3b2e20;
    color: #d8a26c;
}

body.dark-mode .edit-btn {
    background: #202d3e;
    color: #8fb7ef;
}

body.dark-mode .delete-btn {
    background: #382429;
    color: #ed8b99;
}

body.dark-mode .secondary-btn {
    background: #302b32;
    border-color: #403841;
    color: #c4bbc6;
}

body.dark-mode .secondary-btn:hover {
    background: #39333b;
}

body.dark-mode .modal {
    background: #211b23;
}

body.dark-mode .modal-header {
    border-bottom-color: #302832;
}

body.dark-mode .modal-header h3 {
    color: #f0e9f0;
}

body.dark-mode .modal-header p {
    color: #9e949f;
}

body.dark-mode .modal-close {
    background: #302a32;
    color: #aaa0ac;
}

body.dark-mode .modal-close:hover {
    background: #3a2630;
    color: #ef80ad;
}

body.dark-mode .form-group label {
    color: #d0c7d1;
}

body.dark-mode .form-control {
    background: #19151b;
    border-color: #3a323c;
    color: #eee7ef;
}

body.dark-mode .form-control:focus {
    background: #1d1820;
    border-color: #c96193;

    box-shadow:
        0 0 0 3px rgba(201, 97, 147, 0.13);
}

body.dark-mode .form-control::placeholder {
    color: #756b77;
}

body.dark-mode .form-group small {
    color: #877d88;
}

body.dark-mode .switch {
    background: #49424b;
}

body.dark-mode .switch-row input:checked + .switch {
    background: #c85d91;
}

body.dark-mode .delete-modal h3 {
    color: #f0e8f0;
}

body.dark-mode .delete-modal p {
    color: #9e949f;
}

body.dark-mode .toast {
    background: #251f27;
    border-color: #38303a;
    color: #ddd4df;
}


/* =========================================================
   ACCESSIBILITY
   ========================================================= */

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #d36599;
    outline-offset: 2px;
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;

        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;

        transition-duration: 0.01ms !important;
    }

}