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

/* SIDEBAR */
.sidebar {
  width: 260px;
  height: 100vh;
  background: #0f172a; /* dark navy */
  position: fixed;
  top: 0;
  left: 0;
  transition: all 0.3s ease;
  overflow-y: auto;
  box-shadow: 2px 0 10px rgba(0,0,0,0.2);
}

/* HIDE SIDEBAR */
.sidebar.hide {
  transform: translateX(-100%);
}

/* LOGO */
.sidebar .logo {
  font-size: 22px;
  font-weight: bold;
  color: #fff;
  padding: 20px 10px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* LINKS */
.sidebar a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  color: #cbd5e1;
  text-decoration: none;
  font-size: 15px;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

/* HOVER EFFECT */
.sidebar a:hover {
  background: rgba(255,255,255,0.05);
  color: #fff;
  border-left: 3px solid #3b82f6;
  padding-left: 25px;
}

/* ACTIVE LINK */
.sidebar a.active {
  background: #1e293b;
  color: #fff;
  border-left: 3px solid #3b82f6;
}

/* MAIN CONTENT */
.main-content {
  margin-left: 260px;
  transition: all 0.3s ease;
  padding: 20px;
  background: #f1f5f9;
  min-height: 100vh;
}

/* FULL WIDTH WHEN SIDEBAR HIDDEN */
.main-content.full {
  margin-left: 0;
}

/* TOPBAR */
.topbar {
  background: #fff;
  padding: 12px 20px;
  margin-bottom: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* TOGGLE BUTTON */
.toggle-btn {
  font-size: 20px;
  cursor: pointer;
  color: #0f172a;
  background: #e2e8f0;
  padding: 6px 10px;
  border-radius: 6px;
  transition: 0.2s;
}

.toggle-btn:hover {
  background: #cbd5e1;
}

.topbar-right{
    margin-left:auto;
}

.profile-dropdown{
    position:relative;
}

.profile-btn{
    display:flex;
    align-items:center;
    gap:10px;
    border:none;
    background:none;
    cursor:pointer;
    font-size:14px;
}

.profile-img{
    width:40px;
    height:40px;
    border-radius:50%;
    object-fit:cover;
}

.dropdown-menu{
    position:absolute;
    right:0;
    top:55px;
    width:220px;
    background:#fff;
    border-radius:10px;
    box-shadow:0 5px 20px rgba(0,0,0,.15);
    display:none;
    overflow:hidden;
    z-index:9999;
}

.dropdown-menu.show{
    display:block;
}

.dropdown-menu a{
    display:flex;
    align-items:center;
    gap:10px;
    padding:12px 16px;
    color:#333;
    text-decoration:none;
}

.dropdown-menu a:hover{
    background:#f5f5f5;
}

.logout{
    color:#dc3545 !important;
}

.profile-container{
    display:flex;
    justify-content:center;
    margin-top:40px;
}

.profile-card{
  position: relative;
    width:420px;
    background:#fff;
    border-radius:12px;
    padding:35px;
    text-align:center;
    box-shadow:0 10px 30px rgba(0,0,0,.08);
}

.profile-image img{
    width:120px;
    height:120px;
    border-radius:50%;
    object-fit:cover;
    border:5px solid #f3f3f3;
}

.profile-card h2{
    margin:18px 0;
}

.profile-info{
    margin:30px 0;
}

.info-row{
    display:flex;
    justify-content:space-between;
    padding:12px 0;
    border-bottom:1px solid #eee;
}

.info-row label{
    font-weight:600;
}







@keyframes drop{

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

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

}



   table.datatable {
            visibility: hidden;
        }

        table.dataTable {
            visibility: visible;
        }

        .alert {
            padding: 12px 15px;
            border-radius: 6px;
            margin-bottom: 15px;
            font-size: 14px;
        }

        .alert-success {
            background: #d1e7dd;
            color: #0f5132;
            border: 1px solid #badbcc;
        }

        .alert-danger {
            background: #f8d7da;
            color: #842029;
            border: 1px solid #f5c2c7;
        }

        .main-footer {
        
            border-top: 1px solid #e5e7eb;
            padding: 12px;
            text-align: center;
        }

        .footer-content p {
            margin: 0;
        }

        .course-selector {
            display: flex;
            gap: 12px;
            align-items: center;
            margin-bottom: 15px;
        }

        .course-select {
            flex: 1;
            padding: 10px 12px;
            border: 1px solid #d1d5db;
            border-radius: 8px;
            background: #fff;
            font-size: 14px;
            outline: none;
            transition: 0.2s;
        }

        .course-select:focus {
            border-color: #007bff;
            box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
        }

        .btn-add {
            padding: 10px 16px;
            background: #28a745;
            color: white;
            border: none;
            border-radius: 8px;
            font-size: 14px;
            cursor: pointer;
            white-space: nowrap;
            transition: 0.2s;
        }

        .btn-add:hover {
            background: #218838;
        }

        body {
            padding-bottom: 50px;
        }


       


@keyframes pop {
    from { transform: translateY(-30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}


.input-wrapper {
    position: relative;
}

.form-control {
    width: 100%;
    padding: 10px 40px 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
}

.form-control:focus {
    border-color: #4F46E5;
}

.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #666;
}



.btn-primary {
    background: #0f172a;
    color: #fff;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
}
;
.btn-primary:hover {
    background: #4338ca;
}


.btn-secondary {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.2s;
}

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

.btn-login {
    background: #0f172a;
    color: #fff;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    width:100%;
}
;
.btn-login:hover {
    background: #4338ca;
    color:white !important;
}

.edit-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #fff;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}


.form-control {
    border-radius: 10px;
    padding: 10px 12px;
}

.form-control:focus {
    box-shadow: none;
    border-color: #0d6efd;
}

.input-wrapper {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 14px;
    opacity: 0.7;
}

.toggle-password:hover {
    opacity: 1;
}

.attendance-switch {
    display:flex;
    border:1px solid #ddd;
    border-radius:30px;
    overflow:hidden;
    width:max-content;
}


.attendance-switch input {
    display:none;
}


.attendance-switch span {
    padding:7px 18px;
    cursor:pointer;
    font-weight:600;
    transition:.3s;
    display:block;
}


.present {
    color:#198754;
}


.absent {
    color:#dc3545;
}


.attendance-switch input:checked + .present {
    background:#198754;
    color:white;
}


.attendance-switch input:checked + .absent {
    background:#dc3545;
    color:white;
}