:root {
    /* ===== FONT FAMILY ===== */
    --font-base: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

    /* ===== COLORS ===== */
    --clr-primary: #004D5D;
    --clr-secondary: #42BAD3;
    --clr-primary-active: #004452;
    --clr-white: #ffffff;

    --clr-bg-main: #f4f6f8;

    --clr-text-light-white: #f3f3f3;
    --clr-text-main: #0f172a;
    --clr-text-muted: #9aa0a6;

    --clr-border: #d6dbe1;

    --clr-success: #4caf50;
    --clr-warning: #3f7cff;
    --clr-error: #ff5252;

    /* ===== FONT SIZES ===== */
    --fs-12: 12px;
    --fs-13: 13px;
    --fs-14: 14px;
    --fs-16: 16px;
    --fs-18: 18px;
    --fs-20: 20px;
    --fs-24: 24px;

    /* ===== SHADOWS ===== */
    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);

    /* ===== TRANSITIONS ===== */
    --transition-fast: 0.25s ease;
    --transition-base: 0.3s ease;

}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-base);
}

body {
    background: var(--clr-bg-main);
    font-size: var(--fs-14);
    color: var(--clr-text-main);
}

/* Layout */
.layout {
    display: flex;
    min-height: 100vh;
    overflow: hidden;
}

/*------------------ Sidebar  Start ------------------*/
.sidebar {
    width: 260px;
    height: 100vh;
    background: var(--clr-primary);
    overflow-y: auto;
    flex-shrink: 0;
    transition: width 0.3s ease;
}

.sidebar.collapsed {
    width: 0;
}


.logo {
    padding: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo img {
    max-width: 120px;
}

/* Navigation */
.nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Main nav items */
.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--transition-fast);
}

.nav-item span {
    font-weight: 500;
    font-size: var(--fs-18);
    color: var(--clr-white);
}

.nav-item img {
    width: 21px;
    height: 21px;
    object-fit: contain;
}

.nav-item .drop-image img {
    width: 12px;
    height: 12px;
    position: absolute;
    right: 20px;
    top: 20px;
}

.nav-item .drop-image img {
    transition: transform var(--transition-fast);
    transform: rotate(180deg);
}

.nav-group.active .drop-image img {
    transform: rotate(0deg);
}

.nav-item.active {
    background: var(--clr-primary-active);
}

.nav-group {
    display: flex;
    flex-direction: column;
    position: relative;
}

.nav-group .nav-sub {
    max-height: 0;
    opacity: 0;
    padding-top: 0;
    padding-bottom: 0;
    overflow: hidden;
    transition:
        max-height var(--transition-fast),
        opacity var(--transition-fast),
        padding var(--transition-fast);
}

.nav-group.active .nav-sub {
    max-height: 40px;
    opacity: 1;
    padding-top: 8px;
    padding-bottom: 8px;
}

.nav-sub {
    padding: 0 14px 8px 54px;
    font-size: var(--fs-13);
    color: var(--clr-text-light-white);
    position: relative;
    cursor: pointer;
}

.nav-group.active {
    background: var(--clr-primary-active);
}

.nav-sub::before {
    content: "•";
    position: absolute;
    left: 40px;
    color: var(--clr-white);
    font-size: 18px;
    top: 7px;
    font-size: var(--fs-14);
}

.nav-sub:hover {
    color: var(--clr-white);
}

/*------------------ Sidebar  End ------------------*/

/* Main */
.main {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

/*------------------ Topbar  Start ------------------*/

.topbar {
    height: 76px;
    background: var(--clr-white);
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.topbar-body {
    display: flex;
    height: 100%;
    padding: 12px 24px;
    align-items: center;
    justify-content: space-between;
}

.menu-btn {
    font-size: 22px;
    background: none;
    border: none;
    cursor: pointer;
}


.topbar-right {
    position: relative;
    display: flex;
    align-items: center;
}

.profile {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
}

.profile span {
    font-size: var(--fs-16);
}

.profile img:first-child {
    width: 44px;
    height: 44px;
    border-radius: 50%;
}

.profile .arrow {
    width: 12px;
    transition: transform var(--transition-fast);
    filter: invert(1) brightness(0.7) contrast(0);
    transform: rotate(180deg);
}

.profile-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: var(--clr-white);
    box-shadow: var(--shadow-md);
    border-radius: 8px;
    min-width: 180px;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
    transition: all var(--transition-fast);
    z-index: 100;
}

.profile-dropdown a {
    display: block;
    padding: 12px 16px;
    font-size: var(--fs-14);
    color: var(--clr-text-main);
    text-decoration: none;
}

.profile-dropdown a:hover {
    background: var(--clr-bg-main);
}

.topbar-right.active .profile-dropdown {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.topbar-right.active .profile .arrow {
    transform: rotate(0);
}

/*------------------ Topbar  End ------------------*/
/*------------------ Body  Start ------------------*/
.content {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    background: #F1F3F4;
}
.page {
    display: none;
}

.page.active {
    display: block;
}
.main-tilte {
    margin-bottom: 15px;
}

/* Stats */
.stats {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

/* card start */
.card {
    background: var(--clr-white);
    padding: 20px;
    border-radius: 12px;
    flex: 1;
    min-width: 220px;
    box-shadow: var(--shadow-md);
    display: flex;
    width: 100%;
    justify-content: space-between;
    /* flex-wrap: wrap; */

}

.card-title {
    font-size: var(--fs-16);
    display: flex;
    align-items: center;
    gap: 5px;
    color: #333333;
    font-weight: 500;
    margin-bottom: 12px;
}

.graph-image {
    background: #e0f6f5;
    width: 38px;
    height: 38px;
    border-radius: 50%;
}

.graph-image img {
    padding: 10px;
}

.card-price {
    font-size: var(--fs-24);
    font-weight: 500;
}

.progress-circle {
    position: relative;
    width: 80px;
    height: 80px;
}

.progress-circle {
    position: relative;
    width: 80px;
    height: 80px;
}

.progress-circle svg {
    transform: rotate(-90deg);
}

.progress-circle circle {
    fill: none;
    stroke-width: 4;
}

.progress-circle .bg {
    stroke: #e6e6e6;
}

.progress-circle .progress {
    stroke: var(--clr-secondary);
    stroke-linecap: round;
    stroke-dasharray: 220;
    stroke-dashoffset: calc(220 - (220 * var(--percent)) / 100);
    transition: stroke-dashoffset 0.4s ease;
}

.progress-circle span {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: var(--clr-secondary);
}

/* card end */

/* Panel */
.panel {
    background: var(--clr-white);
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    margin-bottom: 24px;
}

.panel-title {
    font-size: 20px;
    font-weight: 500;
    margin-bottom: 16px;
}

/* FORM start*/
.form {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
    justify-content: space-between;
}

.field {
    position: relative;
    width: calc(33.33% - 14px);
}
@media (max-width:991px) {
    .field {
        width: calc(50% - 10px);
    }
}
@media (max-width:767px) {
    .field {
        width: 100%;
    }
}

/* INPUTS */
.field input,
.field select {
    width: 100%;
    padding: 13px 12px;
    font-size: var(--fs-14);
    line-height: 1.4;
    border-radius: 8px;
    border: 1px solid var(--clr-border);
    outline: none;
    background: var(--clr-white);
    height: 48px;
}

/* LABEL */
.field label {
    position: absolute;
    left: 12px;
    top: 16px;
    padding: 0 6px;
    font-size: var(--fs-14);
    color: var(--clr-text-muted);
    background: var(--clr-white);
    pointer-events: none;
    transition: var(--transition-fast);
}

/* FLOAT */
.field.filled label,
.field input:focus+label,
.field select:focus+label {
    top: -7px;
    font-size: var(--fs-12);
    color: var(--clr-primary);

}

/* STATES */
.field input:focus,
.field select:focus {
    border-color: var(--clr-secondary);
    outline: none;
}

.field {
    position: relative;
}

.field select {
    width: 100%;
    height: 48px;
    padding: 14px 40px 14px 12px;
    border: 1px solid var(--clr-border);
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    outline: none;
    appearance: none;
    cursor: pointer;
}

/* Dropdown arrow */
.field::after {
    content: "";
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background-image: url("/assets/images/dropdown-black.png");
    background-repeat: no-repeat;
    background-size: contain;
    pointer-events: none;
    filter: invert(1);
}

.field:has(select:valid)::after {
    filter: none;
}

.field:has(input)::after {
    display: none;
}

.field.error input,
.field.error select {
    border-color: var(--clr-error);
}

.field.error label {
    color: var(--clr-error);
}

.field.success input,
.field.success select {
    border-color: var(--clr-success);
}

.field.success label {
    color: var(--clr-success);
}

/* ERROR TEXT */
.field small {
    display: none;
    font-size: var(--fs-12);
    margin-top: 4px;
    color: var(--clr-error);
}

.field.error small {
    display: block;
}

.btn-group {
    display: flex;
    gap: 16px;
    width: 100%;
}

/* Base button */
.btn {
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.25s ease;
}

/* Save (filled) */
.btn-primary {
    background: var(--clr-primary);
    color: var(--clr-white);
    border-color: var(--clr-primary);
}

.btn-primary:hover {
    background: #00a5bb;
}

/* Cancel (outline) */
.btn-outline {
    background: transparent;
    color: var(--theme-color);
    border-color: var(--theme-color);
}

.btn-outline:hover {
    border-color: var(--clr-primary);

}

/* FORM end */

/* TABLE */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    overflow: auto;
}

th,
td {
    padding: 14px 10px;
    border-bottom: 1px solid #eee;
    text-align: left;
    font-size: var(--fs-14);
}

/* STATUS */
.status {
    padding: 5px 12px;
    border-radius: 4px;
    font-size: var(--fs-12);
    color: #fff;
}

.status.done {
    background: var(--clr-success);
}

.status.pending {
    background: var(--clr-warning);
}

.status.cancel {
    background: var(--clr-error);
}

.action-icons img {
    padding: 0 10px;
    cursor: pointer;
}

/* ------------------data table strat  ----------------------*/

/* .table-top {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
}


.dataTables_filter {
    position: relative;
    margin: 0;
}

.dataTables_filter input {
    height: 36px;
    padding: 8px 12px 8px 32px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
}

.dataTables_filter::before {
    content: "";
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background: url("assets/images/search.png") no-repeat center;
    background-size: contain;
    opacity: 0.5;
}


.table-filter {
    height: 36px;
    padding: 6px 30px 6px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
    background: #fff url("assets/images/dropdown-black.png") no-repeat right 10px center;
    background-size: 10px;
    appearance: none;
    cursor: pointer;
}


.table-bottom {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
}

.dataTables_length {
    margin-left: auto;
}

.dataTables_info {
    white-space: nowrap;
}

.dataTables_paginate {
    margin-left: 12px;
}

.dataTables_wrapper .dataTables_info {
    padding-top: 0;
} */

/* ------------------data table end  ----------------------*/
.copyright {
    margin-top: 8px;
    text-align: right;
    font-size: var(--fs-16);
    color: #333333;
}



@media (max-width: 767px) {

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 260px;
        z-index: 1001;

        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    /* Sidebar OPEN */
    .sidebar.active {
        transform: translateX(0);
    }

    /* Overlay behind sidebar */
    .overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.35);
        z-index: 1000;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease;
    }

    .overlay.active {
        opacity: 1;
        visibility: visible;
    }

    /* Content stays behind */
    .content {
        width: 100%;
    
    }


}

