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

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


/* =========================================================
   ROOT
========================================================= */

:root{

    --primary:#0f172a;

    --secondary:#1e293b;

    --accent:#2962ff;

    --accent-hover:#1d4ed8;

    --background:#f5f7fb;

    --card:#ffffff;

    --text:#111827;

    --muted:#6b7280;

    --border:#e5e7eb;

    --success:#16a34a;

    --danger:#dc2626;

    --shadow:
        0 10px 30px rgba(0,0,0,0.06);

    --radius:20px;
}


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

body{

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    background:var(--background);

    color:var(--text);

    min-height:100vh;
}


/* =========================================================
   LINKS
========================================================= */

a{

    text-decoration:none;
}


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

.app-layout{

    display:flex;

    min-height:100vh;
}


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

.sidebar{

    width:260px;

    background:var(--primary);

    color:#fff;

    padding:30px 20px;

    position:fixed;

    left:0;

    top:0;

    bottom:0;

    overflow-y:auto;
}


.sidebar-logo{

    margin-bottom:50px;
}


.sidebar-logo h2{

    font-size:30px;

    font-weight:700;
}


.sidebar-logo span{

    color:#60a5fa;
}


.sidebar-logo p{

    margin-top:10px;

    color:#94a3b8;

    font-size:14px;
}


/* =========================================================
   NAVIGATION
========================================================= */

.sidebar nav{

    display:flex;

    flex-direction:column;

    gap:10px;
}


.sidebar nav a{

    color:#fff;

    padding:14px 18px;

    border-radius:14px;

    transition:0.3s;

    font-size:15px;
}


.sidebar nav a:hover{

    background:rgba(255,255,255,0.08);
}


.sidebar nav a.active{

    background:linear-gradient(
        135deg,
        #2962ff,
        #1d4ed8
    );
}


/* =========================================================
   USER BOX
========================================================= */

.sidebar-user{

    margin-top:50px;

    padding-top:20px;

    border-top:
        1px solid rgba(255,255,255,0.1);
}


.sidebar-user h4{

    font-size:16px;
}


.sidebar-user p{

    margin-top:8px;

    color:#94a3b8;

    font-size:14px;
}


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

.main-content{

    margin-left:260px;

    padding:30px;

    width:100%;
}


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

.page-header{

    margin-bottom:30px;
}


.page-header h1{

    font-size:38px;

    font-weight:700;

    color:var(--primary);
}


.page-header p{

    margin-top:10px;

    color:var(--muted);
}


/* =========================================================
   CARDS
========================================================= */

.card{

    background:var(--card);

    border-radius:var(--radius);

    padding:30px;

    box-shadow:var(--shadow);

    border:1px solid var(--border);
}


/* =========================================================
   GRID
========================================================= */

.grid{

    display:grid;

    gap:20px;
}


.grid-2{

    grid-template-columns:
        repeat(2,1fr);
}


.grid-3{

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


.grid-4{

    grid-template-columns:
        repeat(4,1fr);
}


.grid-5{

    grid-template-columns:
        repeat(5,1fr);
}


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

.stat-card h3{

    font-size:15px;

    color:var(--muted);

    font-weight:500;
}


.stat-card h1{

    margin-top:20px;

    font-size:42px;

    color:var(--primary);
}


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

input,
select,
textarea{

    width:100%;

    padding:14px 16px;

    border-radius:14px;

    border:1px solid var(--border);

    background:#fff;

    outline:none;

    transition:0.3s;

    font-size:15px;
}


input:focus,
select:focus,
textarea:focus{

    border-color:var(--accent);

    box-shadow:
        0 0 0 4px rgba(41,98,255,0.08);
}


label{

    display:block;

    margin-bottom:10px;

    font-weight:600;

    color:var(--primary);
}


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

.btn{

    display:inline-flex;

    align-items:center;

    justify-content:center;

    gap:10px;

    padding:14px 22px;

    border:none;

    border-radius:14px;

    cursor:pointer;

    transition:0.3s;

    font-size:15px;

    font-weight:600;
}


.btn-primary{

    background:linear-gradient(
        135deg,
        #2962ff,
        #1d4ed8
    );

    color:#fff;
}


.btn-primary:hover{

    opacity:0.9;
}


.btn-danger{

    background:var(--danger);

    color:#fff;
}


.btn-success{

    background:var(--success);

    color:#fff;
}


/* =========================================================
   TABLES
========================================================= */

.table-wrapper{

    overflow-x:auto;
}


table{

    width:100%;

    border-collapse:collapse;
}


table th{

    text-align:left;

    padding:16px;

    font-size:14px;

    color:var(--muted);

    border-bottom:1px solid var(--border);
}


table td{

    padding:16px;

    border-bottom:1px solid var(--border);

    font-size:15px;
}


/* =========================================================
   BADGES
========================================================= */

.badge{

    display:inline-block;

    padding:8px 12px;

    border-radius:999px;

    font-size:13px;

    font-weight:600;
}


.badge-success{

    background:#dcfce7;

    color:#166534;
}


.badge-danger{

    background:#fee2e2;

    color:#991b1b;
}


.badge-warning{

    background:#fef3c7;

    color:#92400e;
}


.badge-info{

    background:#dbeafe;

    color:#1e40af;
}


/* =========================================================
   LOGIN PAGE
========================================================= */

.auth-page{

    min-height:100vh;

    display:flex;

    align-items:center;

    justify-content:center;

    padding:30px;

    background:
        linear-gradient(
            135deg,
            rgba(41,98,255,0.08),
            rgba(255,255,255,1)
        );
}


.auth-container{

    width:100%;

    max-width:1100px;

    display:grid;

    grid-template-columns:
        1fr 1fr;

    background:#fff;

    border-radius:30px;

    overflow:hidden;

    box-shadow:
        0 20px 60px rgba(0,0,0,0.08);
}


.auth-left{

    background:
        linear-gradient(
            135deg,
            #0f172a,
            #1e3a8a
        );

    color:#fff;

    padding:60px;

    display:flex;

    flex-direction:column;

    justify-content:center;
}


.auth-left h1{

    font-size:58px;

    line-height:1.1;
}


.auth-left p{

    margin-top:20px;

    color:#cbd5e1;

    font-size:18px;

    line-height:1.8;
}


.auth-right{

    padding:60px;

    display:flex;

    flex-direction:column;

    justify-content:center;
}


.auth-logo{

    font-size:34px;

    font-weight:700;

    color:var(--primary);

    margin-bottom:40px;
}


.auth-logo span{

    color:var(--accent);
}


.auth-form{

    display:flex;

    flex-direction:column;

    gap:20px;
}


.auth-form button{

    margin-top:10px;
}


/* =========================================================
   MOBILE
========================================================= */

@media(max-width:1024px){

    .grid-5{

        grid-template-columns:
            repeat(2,1fr);
    }
}


@media(max-width:768px){

    .sidebar{

        width:100%;

        height:auto;

        position:relative;
    }

    .main-content{

        margin-left:0;

        padding:20px;
    }

    .app-layout{

        flex-direction:column;
    }

    .grid-2,
    .grid-3,
    .grid-4,
    .grid-5{

        grid-template-columns:1fr;
    }

    .auth-container{

        grid-template-columns:1fr;
    }

    .auth-left{

        display:none;
    }

    .auth-right{

        padding:40px 25px;
    }

    .page-header h1{

        font-size:30px;
    }

    .card{

        padding:20px;
    }

    table{

        min-width:700px;
    }
}

/* =========================================================
   COLLAPSIBLE PANELS
========================================================= */

.collapse-card{

    overflow:hidden;
}


.collapse-header{

    display:flex;

    justify-content:space-between;

    align-items:center;

    cursor:pointer;
}


.collapse-header h2{

    font-size:24px;
}


.collapse-toggle{

    width:42px;

    height:42px;

    border-radius:50%;

    background:#eff6ff;

    color:#2962ff;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:24px;

    font-weight:bold;

    transition:0.3s;
}


.collapse-content{

    display:none;

    margin-top:30px;
}


.collapse-card.active
.collapse-content{

    display:block;
}


.collapse-card.active
.collapse-toggle{

    transform:rotate(45deg);
}

