:root{

    --background:#F5F7FB;

    --sidebar:#0D1B3D;
    --sidebar-light:#162C5F;

    --primary:#3B82F6;
    --primary-light:#60A5FA;

    --success:#22C55E;
    --danger:#EF4444;

    --text:#111827;
    --text-light:#64748B;

}

/* ===================================== */
/* RESET */
/* ===================================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:'Inter',sans-serif;
}

body{

    min-height:100vh;

    display:flex;

    background:

    radial-gradient(
        circle at top right,
        rgba(59,130,246,.08),
        transparent 30%
    ),

    radial-gradient(
        circle at bottom left,
        rgba(96,165,250,.05),
        transparent 25%
    ),

    #F5F7FB;

}

/* ===================================== */
/* SIDEBAR */
/* ===================================== */

.sidebar{

    width:270px;

    position:fixed;

    top:0;
    left:0;
    bottom:0;

    padding:30px 20px;

    background:

    linear-gradient(
        180deg,
        var(--sidebar),
        var(--sidebar-light)
    );

    color:white;

    box-shadow:
    0 20px 40px rgba(0,0,0,.25);

}

.logo{

    font-size:24px;

    font-weight:800;

    margin-bottom:40px;

}

.sidebar nav{

    display:flex;
    flex-direction:column;
    gap:10px;

}

.sidebar nav a{

    text-decoration:none;

    color:white;

    padding:14px 18px;

    border-radius:16px;

    transition:.25s;

}

.sidebar nav a:hover{

    background:
    rgba(255,255,255,.08);

}

.sidebar nav a.active{

    background:var(--primary);

}

/* ===================================== */
/* CONTENT */
/* ===================================== */

.main-content{

    flex:1;

    margin-left:270px;

    padding:35px;

}

/* ===================================== */
/* HEADER */
/* ===================================== */

.page-header{

    margin-bottom:30px;

}

.page-header h1{

    font-size:38px;

    font-weight:800;

    color:var(--text);

}

.page-header p{

    margin-top:8px;

    color:var(--text-light);

}

/* ===================================== */
/* KPI */
/* ===================================== */

.top-grid{

    display:grid;

    grid-template-columns:
    repeat(auto-fit,minmax(250px,1fr));

    gap:20px;

    margin-bottom:25px;

}

.kpi-card{

    background:white;

    border-radius:28px;

    padding:25px;

    box-shadow:
    0 20px 50px rgba(15,23,42,.08);

}

.kpi-card span{

    color:var(--text-light);

    font-size:14px;

}

.kpi-card h2{

    margin-top:10px;

    font-size:36px;

    font-weight:800;

}

/* ===================================== */
/* AJOUT COMPTE */
/* ===================================== */

.add-account-card{

    background:white;

    border-radius:30px;

    padding:30px;

    margin-bottom:25px;

    box-shadow:
    0 20px 50px rgba(15,23,42,.08);

}

.add-account-card h3{

    margin-bottom:20px;

}

.form-grid{

    display:grid;

    grid-template-columns:
    2fr 1.5fr 1.5fr auto;

    gap:15px;

}

.form-grid input,
.form-grid select{

    height:65px;

    border:none;

    border-radius:20px;

    background:#F8FAFC;

    padding:0 20px;

    font-size:16px;

    font-weight:600;

}

.form-grid input:focus,
.form-grid select:focus{

    outline:none;

    box-shadow:
    0 0 0 4px rgba(59,130,246,.15);

}

.form-grid button{

    border:none;

    border-radius:20px;

    padding:0 30px;

    background:

    linear-gradient(
        135deg,
        var(--primary),
        var(--primary-light)
    );

    color:white;

    font-weight:700;

    cursor:pointer;

    transition:.25s;

}

.form-grid button:hover{

    transform:translateY(-2px);

}

/* ===================================== */
/* COMPTES */
/* ===================================== */

.accounts-grid{

    display:grid;

    grid-template-columns:
    repeat(auto-fill,minmax(300px,1fr));

    gap:20px;

}

.account-card{

    position:relative;

    background:white;

    border-radius:30px;

    padding:25px;

    overflow:hidden;

    transition:.25s;

    box-shadow:
    0 20px 50px rgba(15,23,42,.08);

}

.account-card:hover{

    transform:translateY(-5px);

}

.account-card::before{

    content:"";

    position:absolute;

    top:-50px;
    right:-50px;

    width:120px;
    height:120px;

    border-radius:50%;

    background:

    radial-gradient(
        rgba(59,130,246,.08),
        transparent
    );

}

.account-type{

    color:var(--text-light);

    font-size:13px;

}

.account-name{

    margin-top:8px;

    font-size:22px;

    font-weight:700;

}

.account-balance{

    margin-top:20px;

    font-size:38px;

    font-weight:800;

    color:var(--primary);

}

.account-actions{

    margin-top:20px;

    display:flex;

    gap:10px;

}

.account-actions button{

    flex:1;

    height:45px;

    border:none;

    border-radius:14px;

    cursor:pointer;

    font-weight:600;

}

.account-edit{

    margin-top:20px;

}

.account-edit input{

    width:100%;

    height:55px;

    border:none;

    border-radius:16px;

    background:#F8FAFC;

    padding:0 15px;

    font-size:18px;

    font-weight:700;

}

.account-edit input:focus{

    outline:none;

    box-shadow:
    0 0 0 4px rgba(59,130,246,.15);

}

.save-btn{

    flex:1;

    height:45px;

    border:none;

    border-radius:14px;

    cursor:pointer;

    background:
    linear-gradient(
        135deg,
        #3B82F6,
        #60A5FA
    );

    color:white;

    font-weight:700;

}

.edit-btn{

    background:#E0F2FE;

    color:#0369A1;

}

.delete-btn{

    background:#FEE2E2;

    color:#B91C1C;

}

/* ===================================== */
/* MOBILE */
/* ===================================== */

@media(max-width:1100px){

    .form-grid{

        grid-template-columns:1fr;

    }

}

@media(max-width:768px){

    .sidebar{

        width:90px;

    }

    .main-content{

        margin-left:90px;

        padding:20px;

    }

    .logo{

        font-size:14px;

    }

    .sidebar nav a{

        text-align:center;

        font-size:11px;

    }

}

/* ===================================== */
/* SELECT PREMIUM */
/* ===================================== */

#typeCompte{

    appearance:none;
    -webkit-appearance:none;
    -moz-appearance:none;

    background:white;

    border:none;

    border-radius:22px;

    height:65px;

    padding:0 25px;

    font-size:16px;

    font-weight:700;

    color:var(--text);

    cursor:pointer;

    transition:.25s;

    box-shadow:
    0 15px 35px rgba(
        15,
        23,
        42,
        .08
    );

    background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%2364748B' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");

    background-repeat:no-repeat;

    background-position:
    right 20px center;

}

#typeCompte:hover{

    transform:translateY(-2px);

}

#typeCompte:focus{

    outline:none;

    box-shadow:
    0 0 0 4px rgba(
        59,
        130,
        246,
        .15
    );

}

/* ===================================== */
/* CUSTOM ACCOUNT SELECT */
/* ===================================== */

.custom-account-select{

    position:relative;

    width:100%;

}

.account-select-button{

    width:100%;
    height:65px;

    border:none;

    border-radius:20px;

    background:white;

    padding:0 22px;

    display:flex;

    justify-content:space-between;

    align-items:center;

    font-size:16px;

    font-weight:700;

    color:var(--text);

    cursor:pointer;

    box-shadow:
    0 15px 35px rgba(
        15,
        23,
        42,
        .08
    );

    transition:.25s;

}

.account-select-button:hover{

    transform:translateY(-2px);

}

.account-select-menu{

    position:absolute;

    top:75px;
    left:0;
    right:0;

    background:white;

    border-radius:22px;

    overflow:hidden;

    display:none;

    z-index:1000;

    box-shadow:
    0 20px 50px rgba(
        15,
        23,
        42,
        .15
    );

}

.account-select-menu.open{

    display:block;

}

.account-option{

    padding:18px 22px;

    cursor:pointer;

    font-weight:600;

    transition:.2s;

}

.account-option:hover{

    background:#EFF6FF;

    color:#2563EB;

}

.account-option:not(:last-child){

    border-bottom:
    1px solid #F1F5F9;

}

