/* =====================================================
   FONT
===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700&display=swap');

/* =====================================================
   ROOT VARIABLES
===================================================== */

:root{
    --sidebar-width:260px;
    --primary-color:#1a73e8;
    --bg-color:#f4f6f9;
}

/* =====================================================
   GLOBAL RESET
===================================================== */

*{
    box-sizing:border-box;
}

body{
    margin:0;
    font-family:'Vazirmatn', sans-serif;
    background:var(--bg-color);
    color:#333;
    direction:rtl;
}

a{
    text-decoration:none;
    color:inherit;
}

h1,h2,h3,h4,h5{
    font-weight:600;
    margin:0;
}

/* =====================================================
   NAVBAR (اگر در بعضی صفحات قدیمی استفاده شود)
===================================================== */

.navbar{
    background:var(--primary-color);
    padding:15px;
    display:flex;
    justify-content:center;
    gap:20px;
    box-shadow:0 2px 10px rgba(0,0,0,0.1);
}

.navbar a{
    color:white;
    font-weight:bold;
    padding:8px 15px;
    border-radius:8px;
    transition:.3s;
}

.navbar a:hover{
    background:rgba(255,255,255,.2);
}

/* =====================================================
   LAYOUT STRUCTURE
===================================================== */

.layout{
    display:flex;
    min-height:100vh;
}

/* ================= SIDEBAR ================= */

.sidebar{
    width:var(--sidebar-width);
    background:#2f3e4d;
    color:white;
    padding:20px;
    position:fixed;
    right:0;
    top:0;
    height:100vh;
    overflow-y:auto;
    transition:.3s;
    border-radius: 90px 0px 0px 90px;
}

.sidebar-header{
    margin-bottom:30px;
}

.sidebar-header small{
    color:#cfd8dc;
}

.sidebar-menu{
    list-style:none;
    padding:0;
}

.sidebar-menu li{
    margin-bottom:12px;
}

.sidebar-menu a{
    display:block;
    padding:8px 10px;
    border-radius:6px;
    transition:.2s;
}

.sidebar-menu a:hover{
    background:#3c4f63;
}

/* label داخل منو */

.menu-label{
    font-size:11px;
    color:#8a99a7;
    text-transform:uppercase;
    margin-top:20px;
    margin-bottom:5px;
    padding-right:10px;
    font-weight:bold;
}

/* separator */

.menu-sep{
    height:1px;
    background:#3c4f63;
    margin:20px 0;
}

/* لینک فعال */

.sidebar-menu a.active{
    background:#4f8cff;
}

/* ================= MAIN ================= */

.main{
    flex:1;
    margin-right:var(--sidebar-width);
    width:calc(100% - var(--sidebar-width));
    display:flex;
    flex-direction:column;
}

/* =====================================================
   TOPBAR
===================================================== */

.topbar{
    height:60px;
    background:white;
    display:flex;
    align-items:center;
    padding:0 20px;
    border-bottom:1px solid #ddd;
    box-shadow:0 2px 5px rgba(0,0,0,.05);
}

.topbar-title{
    font-weight:600;
}

.menu-btn{
    font-size:22px;
    border:none;
    background:none;
    cursor:pointer;
    margin-left:15px;
    display:none;
}

/* =====================================================
   CONTENT
===================================================== */

.content{
    padding:20px;
}

/* =====================================================
   TABLES
===================================================== */

.table-container{
    width:100%;
    overflow-x:auto;
    border-radius:12px;
    box-shadow:0 2px 10px rgba(0,0,0,.05);
    margin-top:20px;
}

table{
    width:100%;
    border-collapse:collapse;
    background:white;
    min-width:1000px;
}

table th{
    background:var(--primary-color);
    color:white;
    padding:15px 10px;
    font-size:14px;
    position:sticky;
    top:0;
}

table td{
    padding:12px 10px;
    border-bottom:1px solid #eee;
    text-align:center;
    font-size:13px;
    white-space:nowrap;
}

/* zebra rows */

table tbody tr:nth-child(even){
    background:#f8f9fa;
}

table tbody tr:hover{
    background:#f1f7ff;
}

/* مرخصی */

.off-shift{
    color:#d93025;
    font-weight:bold;
    background:#fff1f0;
}

/* =====================================================
   FILTER BOX
===================================================== */

.filter-box{
    background:#f8fbff;
    border:1px solid #dbe7f5;
    padding:20px;
    border-radius:16px;
    margin-bottom:25px;
    display:flex;
    flex-wrap:wrap;
    gap:15px;
    align-items:flex-end;
}

.filter-select{
    padding:10px 12px;
    border-radius:8px;
    border:1px solid #ccc;
    font-size:14px;
    min-width:180px;
}

.filter-btn{
    padding:10px 20px;
    background:var(--primary-color);
    color:white;
    border:none;
    border-radius:8px;
    cursor:pointer;
}

.filter-btn:hover{
    background:#1557b0;
}

.reset-btn{
    padding:10px 20px;
    background:#f1f3f4;
    border-radius:8px;
    border:1px solid #d0d0d0;
}

/* =====================================================
   FORM (صفحه مرخصی)
===================================================== */

.form-container{
    background:white;
    padding:30px;
    border-radius:15px;
    box-shadow:0 10px 25px rgba(0,0,0,.05);
    max-width:600px;
    margin:20px auto;
    border:1px solid #eee;
}

.form-title{
    color:#2c3e50;
    margin-bottom:25px;
    font-size:1.5rem;
}

.form-group{
    margin-bottom:20px;
    display:flex;
    flex-direction:column;
    gap:8px;
}

.form-group label{
    font-weight:bold;
    color:#555;
}

.form-group select,
.form-group input{
    padding:12px;
    border:1px solid #ddd;
    border-radius:8px;
    background:#f9f9f9;
}

.form-group select:focus,
.form-group input:focus{
    border-color:#3498db;
    background:white;
    outline:none;
}

/* submit button */

.btn-submit{
    background:linear-gradient(135deg,#2ecc71,#27ae60);
    color:white;
    padding:14px;
    border:none;
    border-radius:8px;
    cursor:pointer;
    font-weight:bold;
    width:100%;
}

/* =====================================================
   SUCCESS PAGE
===================================================== */

.success-card{
    background:white;
    padding:40px;
    border-radius:20px;
    box-shadow:0 15px 35px rgba(0,0,0,.1);
    max-width:500px;
    margin:50px auto;
    text-align:center;
    border-top:5px solid #2ecc71;
}

.success-icon{
    font-size:50px;
    color:#2ecc71;
    margin-bottom:20px;
}

.success-details{
    background:#f8f9fa;
    padding:15px;
    border-radius:10px;
    margin-bottom:25px;
}

.action-buttons{
    display:flex;
    gap:10px;
    justify-content:center;
}

.btn-primary-small{
    background:#3498db;
    color:white;
    padding:10px 20px;
    border-radius:8px;
}

.btn-secondary{
    background:#f1f2f6;
    color:#2c3e50;
    padding:10px 20px;
    border-radius:8px;
}

/* =====================================================
   ANIMATIONS
===================================================== */

@keyframes fadeIn{
    from{opacity:0;transform:translateY(-10px);}
    to{opacity:1;transform:translateY(0);}
}

@keyframes slideUp{
    from{opacity:0;transform:translateY(20px);}
    to{opacity:1;transform:translateY(0);}
}

/* =====================================================
   MOBILE (RESPONSIVE)
===================================================== */

@media (max-width:768px){

.sidebar{
    right:calc(-1 * var(--sidebar-width));
}

.sidebar.active{
    right:0;
}

.main{
    margin-right:0;
    width:100%;
}

.menu-btn{
    display:block;
}

}




/* هایلایت صفحه فعال */
.active-link {
    background-color: rgba(255, 255, 255, 0.15) !important; /* یک لایه روشن ملایم */
    color: #ffffff !important; /* سفید خالص شدن متن */
    border-radius: 4px; /* گرد شدن گوشه‌های هایلایت */
    box-shadow: inset 4px 0 0 #00f2fe; /* یک خط عموری خیلی ظریف فقط در سمت راست (سمت راست‌چین) */
    font-weight: bold;
}

/* افکت هاور برای زیبایی بیشتر (اختیاری) */
.sidebar-menu li a:hover {
    background-color: rgba(255, 255, 255, 0.05);
}
