/* =============================== */
/* 1. Sidebar smooth transitions   */
/* =============================== */
body.sidebar-mini.sidebar-collapse .main-sidebar {
    width: 80px;
    transition: width 0.4s ease;
}
.main-sidebar {
    transition: width 0.4s ease;
}
.content-wrapper,
.main-header,
.main-footer {
    transition: margin-left 0.4s ease;
}

/* Hover par expand */
body.sidebar-mini.sidebar-collapse .main-sidebar:hover {
    width: 250px;
}

/* Content area adjust */
body.sidebar-mini.sidebar-collapse .content-wrapper,
body.sidebar-mini.sidebar-collapse .main-header,
body.sidebar-mini.sidebar-collapse .main-footer {
    margin-left: 80px;
}
body.sidebar-mini.sidebar-collapse .main-sidebar:hover ~ .content-wrapper,
body.sidebar-mini.sidebar-collapse .main-sidebar:hover ~ .main-header,
body.sidebar-mini.sidebar-collapse .main-sidebar:hover ~ .main-footer {
    margin-left: 250px;
}

/* =============================== */
/* 2. Brand (Logo + Title)         */
/* =============================== */
.brand-link {
    display: flex;
    align-items: center;
    padding: 8px;
    transition: all 0.4s ease;
    position: relative;
}
.brand-link img {
    height: 40px !important;
    width: auto !important;
    margin-right: 8px;
    object-fit: contain;
    transition: all 0.3s ease;
}
.brand-link .brand-text {
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
}

/* Collapsed state → sirf logo */
body.sidebar-mini.sidebar-collapse .brand-link {
    justify-content: center;
}
body.sidebar-mini.sidebar-collapse .brand-link img {
    margin: 0;
}
body.sidebar-mini.sidebar-collapse .brand-link .brand-text {
    display: none;
}

/* Hover expanded state */
body.sidebar-mini.sidebar-collapse .main-sidebar:hover .brand-link {
    justify-content: flex-start;
}
body.sidebar-mini.sidebar-collapse .main-sidebar:hover .brand-link img {
    margin-right: 8px;
}
body.sidebar-mini.sidebar-collapse .main-sidebar:hover .brand-link .brand-text {
    display: inline-block;
}

/* Tooltip collapsed logo */
.brand-link::after {
    content: attr(data-title);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: #111;
    color: #fff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, left 0.3s ease;
    margin-left: 8px;
    z-index: 9999;
}
body.sidebar-mini.sidebar-collapse .brand-link:hover::after {
    opacity: 1;
    left: calc(100% + 10px);
}

/* =============================== */
/* 3. Dashboard Welcome Styling    */
/* =============================== */
.jazzmin-dashboard .card.welcome .card-body h4 {
    font-size: 20px;
    font-weight: 400;
    display: flex;
    align-items: center;
    gap: 10px;
}
.jazzmin-dashboard .card.welcome .card-body h4::before {
    content: url('/static/image/img1.jpg');
    height: 30px;
    width: 30px;
    display: inline-block;
    margin-right: 8px;
    vertical-align: middle;
}

/* Dashboard Cards */
.jazzmin-dashboard .card {
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.jazzmin-dashboard .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 18px rgba(47, 221, 192, 0.2);
}

/* Welcome Card */
.jazzmin-dashboard .card.welcome {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: #f8d0d0;
    text-align: center;
    border: none;
}
.jazzmin-dashboard .card.welcome h4 {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 8px;
}
.jazzmin-dashboard .card.welcome p {
    font-size: 16px;
    opacity: 0.9;
}

/* =============================== */
/* 4. Sidebar Hover & Nav Links    */
/* =============================== */
.nav-sidebar .nav-item .nav-link {
    border-radius: 8px;
    margin: 2px 5px;
    transition: all 0.3s ease;
}
.nav-sidebar .nav-item .nav-link:hover {
    background: #2575fc;
    font-size: large;
    color: #f31fac !important;
}

/* =============================== */
/* 5. Navbar (Top Bar) Styling     */
/* =============================== */
.main-header.navbar {
    height: 60px;
    padding: 0 15px;
    box-shadow: 0 2px 6px rgba(86, 212, 212, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Search box */
.navbar .form-control {
    border-radius: 20px;
    padding: 6px 12px;
    border: 1px solid #ddd;
    transition: all 0.3s ease;
}
.navbar .form-control:focus {
    border-color: #2575fc;
    box-shadow: 0 0 6px rgba(37,117,252,0.4);
    outline: none;
}

/* Search box wrapper */
.navbar-search {
    flex: 1;
    max-width: 400px;
    margin: 0 auto;
}

/* User profile dropdown */
.navbar-nav .nav-item .nav-link {
    color: #333;
    font-weight: 500;
    padding: 8px 12px;
    transition: all 0.3s ease;
}
.navbar-nav .nav-item .nav-link:hover {
    background: #65b34e;
    border-radius: 8px;
}

/* Avatar */
.navbar-nav .nav-item .user-menu img {
    border-radius: 50%;
    height: 35px;
    width: 35px;
    object-fit: cover;
    border: 2px solid #2575fc;
}

/* Dropdown */
.navbar-nav .dropdown-menu {
    border-radius: 10px;
    box-shadow: 0 6px 15px rgba(120, 236, 231, 0.15);
    border: none;
    padding: 8px 0;
}
.navbar-nav .dropdown-menu .dropdown-item {
    padding: 10px 15px;
    font-size: 14px;
    transition: all 0.2s ease;
}
.navbar-nav .dropdown-menu .dropdown-item:hover {
    background: #2575fc;
    color: #66c495;
}

/* =============================== */
/* 6. Login Page Styling           */
/* =============================== */
body.login-page {
    background: linear-gradient(135deg, #6a11cb, #2575fc) !important;
    background-attachment: fixed !important;
    min-height: 100vh !important;
    display: flex;
    justify-content: center;
    align-items: center;
}
body.login-page .login-box {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(12px);
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
}
body.login-page .login-card-body {
    background: transparent !important;
    color: #fff;
}
.login-box {
    width: 380px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    text-align: center;
}
.login-logo img {
    height: 60px;
    margin-bottom: 10px;
    filter: drop-shadow(0 2px 5px rgba(0,0,0,0.4));
}
.login-logo a {
    font-size: 20px;
    font-weight: bold;
    color: #fff !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.login-box .form-control {
    border-radius: 10px;
    border: 1px solid #ddd;
    padding: 12px;
    font-size: 14px;
    transition: all 0.3s ease;
}
.login-box .form-control:focus {
    border-color: #2575fc;
    box-shadow: 0 0 8px rgba(37,117,252,0.5);
}
.login-box .btn-primary {
    background: linear-gradient(90deg, #6a11cb, #2575fc);
    border: none;
    border-radius: 10px;
    padding: 10px;
    font-size: 16px;
    transition: all 0.3s ease;
}
.login-box .btn-primary:hover {
    background: linear-gradient(90deg, #2575fc, #6a11cb);
    transform: scale(1.05);
}
.login-box .alert-danger {
    border-radius: 8px;
    padding: 10px;
    font-size: 13px;
}

/* =============================== */
/* 7. Admin Form + Checkbox Styling */
/* =============================== */
.form-row,
.field-box,
.form-group {
    transition: all 0.3s ease-in-out !important;
    overflow: hidden;
}
.hidden-by-js {
    opacity: 0;
    max-height: 0;
    margin: 0 !important;
    padding: 0 !important;
    pointer-events: none;
}
.visible-by-js {
    opacity: 1;
    max-height: 500px;
    margin: revert !important;
    padding: revert !important;
    pointer-events: auto;
}/* ====================== */
/* Custom Checkbox Grid   */
/* ====================== */

/* Wrapper jo checkboxes ko hold karega */
.checkbox-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;   /* 2 column layout */
    gap: 12px 30px;                   /* row-gap aur col-gap */
    margin: 15px 0;
}

/* Har checkbox container */
.checkbox-grid .field-box {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fafafa;
    transition: all 0.3s ease;
}

/* Hover effect */
.checkbox-grid .field-box:hover {
    background: #f0f7ff;
    border-color: #2575fc;
}

/* Checkbox size + accent color */
.checkbox-grid input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #2575fc;   /* Chrome/Edge/Safari ke liye */
    cursor: pointer;
}

/* Label styling */
.checkbox-grid label {
    font-weight: 600;
    color: #34495e;
    font-size: 14px;
    white-space: nowrap;
}

/* Checked hone par text highlight */
.checkbox-grid input[type="checkbox"]:checked + label {
    color: #2575fc;
    font-weight: 700;
}
/* ----------------------------- */
/* General input, select, textarea styling */
/* ----------------------------- */
input[type="text"], 
input[type="number"], 
input[type="email"], 
textarea, 
select {
    border: 2px solid #3498db !important;  /* Blue border */
    border-radius: 5px;
    padding: 5px 10px;
    background-color: #fff;
    width: 100%;
    box-sizing: border-box;
    font-size: 14px;
}

/* ----------------------------- */
/* Readonly fields styling */
/* ----------------------------- */
input[readonly], textarea[readonly], select[disabled] {
    border: 2px dashed #e74c3c !important; /* Red dashed border */
    background-color: #f9f9f9;
    color: #555;
}

/* ----------------------------- */
/* Checkbox styling */
/* ----------------------------- */
input[type="checkbox"] {
    transform: scale(1.5);
    margin: 5px;
}

/* ----------------------------- */
/* Optional: focus effect for editable fields */
/* ----------------------------- */
input[type="text"]:focus,
textarea:focus,
select:focus {
    border-color: #2ecc71 !important;  /* Green border on focus */
    box-shadow: 0 0 5px rgba(46, 204, 113, 0.5);
}
