/* ===================================
   JESSOREBOARD THEME - Education Board Design
   Based on Bangladesh Education Board Portal
   Colors: Green (#006747), White, Red (#F42A41)
   =================================== */

/* Import Bengali Fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Bengali:wght@300;400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@300;400;500;600;700&display=swap');

/* ===== ROOT VARIABLES ===== */
:root {
    /* Jessoreboard Primary Colors */
    --jb-green-primary: #006747;
    --jb-green-dark: #004d35;
    --jb-green-light: #00a86b;
    --jb-red-accent: #F42A41;
    --jb-white: #ffffff;
    --jb-cream: #f8f9fa;
    
    /* Secondary Colors */
    --jb-gold: #FFD700;
    --jb-blue: #0066cc;
    --jb-orange: #ff6b35;
    
    /* Text Colors */
    --jb-text-dark: #1a1a1a;
    --jb-text-light: #666666;
    --jb-text-white: #ffffff;
    
    /* Background Colors */
    --jb-bg-primary: #f5f7fa;
    --jb-bg-secondary: #e8f5e9;
    --jb-bg-card: #ffffff;
    
    /* Border & Shadow */
    --jb-border: #e0e0e0;
    --jb-shadow: 0 4px 15px rgba(0, 103, 71, 0.1);
    --jb-shadow-hover: 0 8px 25px rgba(0, 103, 71, 0.2);
}

/* ===== GLOBAL STYLES ===== */
body {
    font-family: 'Hind Siliguri', 'Noto Sans Bengali', sans-serif !important;
    background: var(--jb-bg-primary);
    color: var(--jb-text-dark);
    line-height: 1.7;
}

/* ===== HEADER & NAVIGATION ===== */
.navbar {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%) !important;
    box-shadow: 0 4px 20px rgba(0, 103, 71, 0.3);
    border-bottom: 3px solid var(--jb-red-accent);
}

.navbar-brand {
    color: var(--jb-white) !important;
    font-weight: 700;
    font-size: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
    color: var(--jb-gold) !important;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 10px 18px !important;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 255, 255, 0.15);
    color: var(--jb-white) !important;
    transform: translateY(-2px);
}

/* ===== SIDEBAR ===== */
.sidebar {
    background: linear-gradient(180deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%) !important;
    box-shadow: 4px 0 20px rgba(0, 103, 71, 0.2);
    border-right: 3px solid var(--jb-red-accent);
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.85) !important;
    padding: 14px 24px !important;
    margin: 4px 12px;
    border-radius: 10px;
    border-left: 4px solid transparent;
    transition: all 0.3s ease;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    background: rgba(255, 255, 255, 0.12);
    color: var(--jb-white) !important;
    border-left-color: var(--jb-red-accent);
    transform: translateX(8px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.sidebar .nav-link i {
    margin-right: 12px;
    font-size: 1.1rem;
    color: var(--jb-gold);
}

/* ===== CARDS ===== */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: var(--jb-shadow);
    transition: all 0.3s ease;
    background: var(--jb-bg-card);
    overflow: hidden;
    border-top: 4px solid var(--jb-green-primary);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--jb-shadow-hover);
    border-top-color: var(--jb-red-accent);
}

.card-header {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%) !important;
    color: var(--jb-white) !important;
    border: none !important;
    font-weight: 600;
    padding: 18px 24px;
    border-radius: 12px 12px 0 0 !important;
}

/* ===== DASHBOARD CARDS ===== */
.dashboard-card {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%);
    color: var(--jb-white);
    border-radius: 15px;
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: 0 10px 30px rgba(0, 103, 71, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    border: none;
    border-top: 4px solid var(--jb-red-accent);
}

.dashboard-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    transition: all 0.4s ease;
}

.dashboard-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 40px rgba(0, 103, 71, 0.3);
}

.dashboard-card:hover::before {
    top: -30%;
    right: -30%;
}

/* Dashboard Card Variants */
.dashboard-card.card-students {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-light) 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-teachers {
    background: linear-gradient(135deg, #d32f2f 0%, var(--jb-red-accent) 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-classes {
    background: linear-gradient(135deg, #1976d2 0%, var(--jb-blue) 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-attendance {
    background: linear-gradient(135deg, #388e3c 0%, #66bb6a 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-fees {
    background: linear-gradient(135deg, #f57c00 0%, var(--jb-orange) 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-exams {
    background: linear-gradient(135deg, #7b1fa2 0%, #9c27b0 100%);
    border-top-color: var(--jb-gold);
}

.dashboard-card.card-visitors {
    background: linear-gradient(135deg, #0097a7 0%, #00bcd4 100%);
    border-top-color: var(--jb-gold);
}

/* ===== BUTTONS ===== */
.btn {
    border-radius: 10px;
    font-weight: 600;
    padding: 12px 28px;
    transition: all 0.3s ease;
    border: none;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.btn-primary {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%) !important;
    border: 2px solid var(--jb-green-primary);
    color: var(--jb-white) !important;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--jb-green-dark) 0%, var(--jb-green-primary) 100%) !important;
    border-color: var(--jb-red-accent);
    box-shadow: 0 6px 20px rgba(0, 103, 71, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #388e3c 0%, #66bb6a 100%) !important;
    color: var(--jb-white) !important;
}

.btn-danger {
    background: linear-gradient(135deg, var(--jb-red-accent) 0%, #d32f2f 100%) !important;
    color: var(--jb-white) !important;
}

.btn-warning {
    background: linear-gradient(135deg, #f57c00 0%, var(--jb-orange) 100%) !important;
    color: var(--jb-white) !important;
}

.btn-info {
    background: linear-gradient(135deg, #1976d2 0%, var(--jb-blue) 100%) !important;
    color: var(--jb-white) !important;
}

/* Quick Action Buttons */
.quick-action-btn {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%);
    border: 2px solid var(--jb-green-primary);
    color: var(--jb-white);
    padding: 18px 28px;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    margin: 6px;
    position: relative;
    overflow: hidden;
}

.quick-action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.quick-action-btn:hover::before {
    left: 100%;
}

.quick-action-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 103, 71, 0.4);
    color: var(--jb-white);
    border-color: var(--jb-red-accent);
    background: linear-gradient(135deg, var(--jb-green-dark) 0%, var(--jb-green-primary) 100%);
}

/* ===== TABLES ===== */
.table {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--jb-shadow);
    background: var(--jb-white);
}

.table thead th {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%);
    color: var(--jb-white);
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-size: 0.9rem;
    padding: 16px;
}

.table tbody tr {
    transition: all 0.3s ease;
    border-bottom: 1px solid var(--jb-border);
}

.table tbody tr:hover {
    background: var(--jb-bg-secondary);
    transform: scale(1.01);
    box-shadow: 0 4px 12px rgba(0, 103, 71, 0.1);
}

/* ===== FORMS ===== */
.form-control,
.form-select {
    border-radius: 10px;
    border: 2px solid var(--jb-border);
    padding: 12px 18px;
    transition: all 0.3s ease;
    background: var(--jb-white);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--jb-green-primary);
    box-shadow: 0 0 0 0.25rem rgba(0, 103, 71, 0.15);
    transform: translateY(-2px);
}

/* ===== ALERTS ===== */
.alert {
    border-radius: 12px;
    border: none;
    font-weight: 500;
    padding: 16px 20px;
    border-left: 4px solid;
}

.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border-left-color: #28a745;
}

.alert-danger {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    border-left-color: var(--jb-red-accent);
}

.alert-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    color: #856404;
    border-left-color: #ffc107;
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
    border-left-color: #17a2b8;
}

/* ===== BADGES ===== */
.badge {
    border-radius: 8px;
    font-weight: 600;
    padding: 8px 14px;
}

.badge.bg-primary {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%) !important;
}

/* ===== WELCOME SECTION ===== */
.welcome-section {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%);
    color: var(--jb-white);
    border-radius: 15px;
    padding: 40px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 5px solid var(--jb-red-accent);
    box-shadow: 0 10px 30px rgba(0, 103, 71, 0.3);
}

.welcome-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: float 8s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-30px) rotate(180deg); }
}

.welcome-title {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 12px;
    position: relative;
    z-index: 2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.welcome-subtitle {
    font-size: 1.2rem;
    opacity: 0.95;
    position: relative;
    z-index: 2;
}

/* ===== INFO CARDS ===== */
.info-card {
    background: var(--jb-white);
    border-radius: 15px;
    padding: 24px;
    box-shadow: var(--jb-shadow);
    margin-bottom: 24px;
    transition: all 0.3s ease;
    border-top: 4px solid var(--jb-green-primary);
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--jb-shadow-hover);
    border-top-color: var(--jb-red-accent);
}

/* ===== ACTIVITY ITEMS ===== */
.activity-item {
    background: var(--jb-white);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 3px 12px rgba(0, 103, 71, 0.08);
    border-left: 4px solid var(--jb-green-primary);
    transition: all 0.3s ease;
}

.activity-item:hover {
    transform: translateX(8px);
    box-shadow: 0 6px 20px rgba(0, 103, 71, 0.15);
    border-left-color: var(--jb-red-accent);
}

.activity-icon {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, var(--jb-green-primary), var(--jb-green-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--jb-white);
    margin-right: 16px;
    box-shadow: 0 4px 12px rgba(0, 103, 71, 0.3);
}

/* ===== CONTENT HEADER ===== */
.content-header {
    background: linear-gradient(135deg, var(--jb-white) 0%, var(--jb-bg-secondary) 100%);
    padding: 24px 28px;
    border-radius: 12px;
    margin-bottom: 28px;
    box-shadow: var(--jb-shadow);
    border-left: 5px solid var(--jb-green-primary);
}

.content-title {
    color: var(--jb-green-primary);
    font-weight: 700;
    font-size: 1.8rem;
    margin: 0;
}

.content-breadcrumb {
    color: var(--jb-text-light);
    margin: 8px 0 0 0;
}

/* ===== CARD ICONS & NUMBERS ===== */
.card-icon {
    font-size: 3.5rem;
    opacity: 0.9;
    margin-bottom: 16px;
    position: relative;
    z-index: 2;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.2));
}

.card-number {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 12px;
    position: relative;
    z-index: 2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.15);
}

.card-title {
    font-size: 1.15rem;
    opacity: 0.95;
    position: relative;
    z-index: 2;
    font-weight: 600;
}

.card-subtitle {
    font-size: 0.95rem;
    opacity: 0.8;
    margin-top: 6px;
    position: relative;
    z-index: 2;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--jb-bg-primary);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--jb-green-primary) 0%, var(--jb-green-dark) 100%);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--jb-green-dark) 0%, var(--jb-green-primary) 100%);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

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

.slide-in {
    animation: slideIn 0.5s ease-out;
}
