:root {
    --primary: #2563eb;          /* Professional Coaching Royal Blue */
    --primary-hover: #1d4ed8;
    --accent: #f59e0b;           /* Energetic Gold/Orange Accent */
    --bg-dark: #0f172a;
    --bg-light: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border: #cbd5e1;
    --radius: 12px;
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-light);
    overflow-x: hidden;
}

/* ==========================================
   1. LOGIN PAGE STYLES
   ========================================== */
body.login-page-body {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    min-height: 100vh;
}

.login-container {
    width: 100%;
    max-width: 420px;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    border-top: 5px solid var(--accent);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.login-header {
    background: linear-gradient(135deg, var(--primary), #1e40af);
    color: #ffffff;
    padding: 32px 24px;
    text-align: center;
}

.login-header h2 {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.login-header p {
    font-size: 13px;
    opacity: 0.85;
}

.login-body {
    padding: 32px 24px 24px 24px;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 8px;
}

.input-with-icon {
    position: relative;
}

.input-with-icon i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 16px;
}

.form-control {
    width: 100%;
    padding: 12px 16px 12px 42px;
    font-size: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    transition: all 0.3s ease;
    background-color: #f8fafc;
    color: var(--text-main);
}

.form-control:focus {
    border-color: var(--primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.remember-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.remember-row label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 500;
}

.btn-login {
    width: 100%;
    padding: 12px;
    background-color: var(--primary);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-login:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
}

.msgprint {
    margin-top: 16px;
    font-size: 13px;
    color: #ef4444;
    font-weight: 500;
    text-align: center;
}

.social-section {
    padding: 0 24px 32px 24px;
    text-align: center;
}

.social-section span {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 16px;
    position: relative;
}

.social-section span::before, .social-section span::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 28%;
    height: 1px;
    background-color: var(--border);
}

.social-section span::before { left: 0; }
.social-section span::after { right: 0; }

.social-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.social-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: #ffffff;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.social-btn.fb:hover { background: #1877f2; color: #fff; border-color: #1877f2; }
.social-btn.tw:hover { background: #1da1f2; color: #fff; border-color: #1da1f2; }
.social-btn.gp:hover { background: #db4437; color: #fff; border-color: #db4437; }


/* ==========================================
   2. DASHBOARD & ADMIN LAYOUT STYLES
   ========================================== */
.admin-dashboard-wrapper {
    display: flex;
    min-height: 100vh;
    background-color: var(--bg-light);
    width: 100%;
}

.sidebar-area {
    width: 260px;
    background: #1e293b;
    color: #fff;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    overflow-y: auto;
    z-index: 100;
}

.main-content-area {
    flex: 1;
    margin-left: 260px;
    display: flex;
    flex-direction: column;
    width: calc(100% - 260px);
    min-height: 100vh;
}

.admin-header {
    height: 70px;
    background: #ffffff;
    border-bottom: 1px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 99;
}

.admin-content {
    width: 100%;
    box-sizing: border-box;
    padding: 24px 30px;
}


/* ==========================================
   3. RESPONSIVE MEDIA QUERIES & MOBILE FIXES
   ========================================== */
@media (max-width: 992px) {
    .admin-dashboard-wrapper {
        flex-direction: column;
    }
    .sidebar-area {
        width: 100%;
        position: relative;
        height: auto;
        max-height: none;
    }
    .main-content-area {
        margin-left: 0;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .admin-header {
        padding: 0 15px;
        height: 60px;
    }
    .admin-header div:first-child {
        font-size: 16px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 65%;
    }
    .admin-content {
        padding: 15px !important;
    }
}

@media (max-width: 480px) {
    body.login-page-body {
        padding: 15px;
    }
    .login-container {
        max-width: 100%;
    }
    .login-header {
        padding: 24px 16px;
    }
    .login-body {
        padding: 24px 16px;
    }
}

/* Submenu by default hide rahega */
.sidebar-menu .treeview-menu {
    display: none !important;
}

/* Jab active ya menu-open class lagegi tabhi show hoga */
.sidebar-menu .treeview.menu-open > .treeview-menu,
.sidebar-menu .treeview.active > .treeview-menu {
    display: block !important;
}


/* ==========================================
   4. TOP HEADER STYLES
   ========================================== */
.admin-top-header {
    height: 70px;
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 99;
    width: 100%;
}

.admin-sitename {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
}

.admin-logout-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: #fee2e2;
    color: #dc2626;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s;
}

.admin-logout-btn:hover {
    background: #fecaca;
    color: #b91c1c;
}

/* ==========================================
   5. TINYMCE EDITOR MODERN STYLING
   ========================================== */
/* Main container box styling */
table.mceLayout {
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    overflow: hidden;
    width: 100% !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* Toolbar area styling */
td.mceToolbar {
    background: #f8fafc !important;
    padding: 8px !important;
    border-bottom: 1px solid var(--border) !important;
}

/* Editor editing area (iframe background & padding) */
iframe.mceIframe {
    background: #ffffff !important;
    padding: 10px;
}

/* Statusbar (bottom path and words count) styling */
td.mceStatusbar {
    background: #f8fafc !important;
    border-top: 1px solid var(--border) !important;
    padding: 6px 12px !important;
    color: var(--text-muted) !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 12px !important;
}

/* Fallback textarea styling if JS disabled */
textarea[name="details"] {
    width: 100% !important;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: var(--text-main);
    background: #fff;
    outline: none;
}
textarea[name="details"]:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* ==========================================
   RESPONSIVE TINYMCE EDITOR FIX
   ========================================== */
.admin-content form {
    width: 100%;
    overflow-x: hidden;
}

/* TinyMCE main wrapper */
table.mceLayout, 
table.mceLayout tr, 
table.mceLayout td {
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* Force TinyMCE iframe to stay inside container */
iframe.mceIframe {
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Editor container card padding adjustment on small screens */
@media (max-width: 768px) {
    .admin-content {
        padding: 15px !important;
    }
    .admin-content > div {
        padding: 12px !important;
    }
}

/* ==========================================
   CONTACT FORM PREMIUM GLOBAL STYLING
   ========================================== */
.contact-form-box {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    overflow: hidden;
}

.contact-header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
}

.contact-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    margin: 0;
}

.contact-body {
    padding: 28px;
}

.form-group-custom {
    margin-bottom: 20px;
}

.form-group-custom label {
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 8px;
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
}

.form-group-custom .form-control {
    width: 100% !important;
    padding: 10px 14px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: var(--text-main);
    background-color: #ffffff;
    box-shadow: none;
    outline: none;
}

.form-group-custom .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.form-actions-custom {
    text-align: center;
    margin-top: 30px;
    display: flex;
    justify-content: center;
    gap: 15px;
}

.btn-update-custom {
    width: 150px;
    padding: 11px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    border: none;
    background-color: var(--primary);
    color: #ffffff;
    transition: background 0.2s;
}

.btn-update-custom:hover {
    background-color: var(--primary-hover);
}

.btn-reset-custom {
    width: 120px;
    padding: 11px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    background: #e2e8f0;
    color: #334155;
    border: 1px solid var(--border);
}


/* ==========================================
   BANNER MANAGEMENT CLEAN THEME STYLING
   ========================================== */
.admin-box-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    overflow: hidden;
    margin-bottom: 25px;
}

.admin-box-header {
    padding: 18px 24px !important;
    border-bottom: 1px solid var(--border);
    background: #f8fafc;
}

.admin-box-header .box-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    margin: 0;
}

.box-body.pad {
    padding: 28px !important;
}

.box-body.pad h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-main);
    margin-top: 0;
    margin-bottom: 20px;
}

/* Table styling override for theme compatibility */
.table-bordered {
    border: 1px solid var(--border) !important;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
}

.table-bordered > thead > tr {
    background: #f8fafc;
}

.table-bordered > thead > tr > th {
    color: var(--text-main);
    font-weight: 600;
    padding: 12px 16px !important;
    border-bottom: 1px solid var(--border) !important;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table-bordered > tbody > tr > td {
    padding: 14px 16px !important;
    vertical-align: middle !important;
    border-top: 1px solid var(--border) !important;
    color: var(--text-main);
}

.table-bordered > tbody > tr:nth-child(even) {
    background-color: #f8fafc;
}

/* Form controls inside theme */
.box-body.pad .form-control {
    width: 100% !important;
    padding: 10px 14px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: var(--text-main);
    background-color: #ffffff;
    box-shadow: none;
    outline: none;
}

.box-body.pad input[type="file"] {
    height: auto !important;
    padding: 8px !important;
    background: #fff;
}

/* Links inside tables */
.box-body.pad table a i.fa-pencil-square-o {
    color: var(--primary);
}
.box-body.pad table a {
    font-weight: 600;
    text-decoration: none;
}
.box-body.pad table a[href*="DelBanners"] {
    color: #dc2626;
}
.box-body.pad table img {
    border-radius: 6px;
    border: 1px solid var(--border);
    object-fit: cover;
}

/* ==========================================
   RESPONSIVE FIXES & ICONIC BUTTONS
   ========================================== */
.admin-header-actions {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

@media (min-width: 768px) {
    .admin-box-header .admin-header-actions {
        float: right;
        margin-top: 0;
    }
}

.admin-header-actions .btn {
    font-weight: 600;
    border-radius: 4px;
}

.action-icon-btn {
    padding: 6px 12px !important;
    border-radius: 4px !important;
    font-size: 13px;
}

.banner-table-img {
    width: 140px;
    height: 70px;
    border-radius: 6px;
    border: 1px solid var(--border);
    object-fit: cover;
    max-width: 100%;
}

.banner-preview-img {
    width: 200px;
    height: 100px;
    border-radius: 6px;
    border: 1px solid var(--border);
    object-fit: cover;
    max-width: 100%;
}


/* ==========================================
   COMMON ICONIC EDIT & DELETE BUTTONS CSS
   ========================================== */

/* Buttons ka container alignment */
.action-btn-group {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Common Base Style for Action Buttons */
.btn-action-common {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.25s ease-in-out;
    border: none;
    cursor: pointer;
    text-decoration: none !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
}

/* Edit Button Style (Attractive Blue/Indigo Theme) */
.btn-edit-icon {
    background-color: #eff6ff;
    color: #2563eb !important;
    border: 1px solid #bfdbfe;
}

.btn-edit-icon:hover {
    background-color: #2563eb;
    color: #ffffff !important;
    border-color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

/* Delete Button Style (Attractive Soft Red Theme) */
.btn-delete-icon {
    background-color: #fef2f2;
    color: #dc2626 !important;
    border: 1px solid #fecaca;
}

.btn-delete-icon:hover {
    background-color: #dc2626;
    color: #ffffff !important;
    border-color: #dc2626;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(220, 38, 38, 0.25);
}

/* ==========================================
   GLOBAL PREMIUM BUTTON STYLING
   ========================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 6px;
    border: 1px solid transparent;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s ease-in-out;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
}

.btn-primary {
    background-color: var(--primary);
    color: #ffffff !important;
    border-color: transparent;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.btn-premium {
    letter-spacing: 0.3px;
}