.eduhub-manager-wrapper { 
    font-family: 'Segoe UI', 'Roboto', Helvetica, Arial, sans-serif; 
    max-width: 1200px; 
    margin: 0 auto; 
    background: #fff; 
    padding: 20px; 
    border-radius: 8px; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.08); 
}

/* --- FLASH CARDS --- */
.eduhub-context-header { margin-bottom: 30px; border-bottom: 2px solid #f0f0f0; padding-bottom: 20px; }
.eduhub-context-header h3 { margin-top:0; margin-bottom:15px; color:#444; text-transform: uppercase; font-size: 14px; letter-spacing: 1px; }

.eduhub-cards-container { display: flex; gap: 15px; flex-wrap: wrap; justify-content: space-between; }

.eduhub-flash-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px 15px;
    flex: 1;
    min-width: 160px; /* Better for mobile */
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    text-align: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
    position: relative;
    overflow: hidden;
}

.eduhub-flash-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 20px rgba(0,0,0,0.1);
    border-color: #b0d4f1;
}

.eduhub-flash-card.active-card {
    background: linear-gradient(135deg, #0073aa 0%, #00608d 100%);
    color: white;
    border-color: #005177;
    box-shadow: 0 8px 15px rgba(0,115,170,0.25);
}

.eduhub-flash-card.active-card .card-sub { color: #dceefb; }

.card-icon { font-size: 32px; margin-bottom: 12px; }
.card-icon i { transition: color 0.3s ease; }
.card-icon .fa-book { color: #ff9f43; }            
.card-icon .fa-globe-asia { color: #2e86de; }      
.card-icon .fa-mosque { color: #9b59b6; }          
.card-icon .fa-quran { color: #10ac84; }           
.card-icon .fa-plane-departure { color: #ee5253; } 

.eduhub-flash-card.active-card .card-icon i { color: #ffffff !important; }

.card-title { font-weight: 700; font-size: 15px; margin-bottom: 5px; line-height: 1.2; }
.card-sub { font-size: 13px; color: #777; font-weight: 500; }

/* Tabs */
.eduhub-tabs { 
    overflow-x: auto; /* Scroll on very small screens */
    white-space: nowrap;
    border-bottom: 2px solid #f0f0f0; 
    margin-bottom: 25px; 
    -webkit-overflow-scrolling: touch;
}
.eduhub-tab-link { 
    background-color: transparent; 
    display: inline-block;
    border: none; 
    outline: none; 
    cursor: pointer; 
    padding: 14px 24px; 
    transition: 0.3s; 
    font-size: 15px; 
    font-weight: 600; 
    color: #666; 
}
.eduhub-tab-link:hover { color: #0073aa; background-color: #f9f9f9; }
.eduhub-tab-link.active { border-bottom: 3px solid #0073aa; color: #0073aa; background: transparent; }
.eduhub-tab-content { display: none; animation: fadeEffect 0.4s; }
@keyframes fadeEffect { from {opacity: 0; transform: translateY(5px);} to {opacity: 1; transform: translateY(0);} }

/* --- RESPONSIVE SETTINGS GRID (New) --- */
.eduhub-settings-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 25px; 
}

/* Settings Cards Styling */
.eduhub-card.settings-card {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 10px;
    padding: 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
    transition: transform 0.2s;
    display: flex;
    flex-direction: column;
}

.eduhub-card.settings-card:hover {
    box-shadow: 0 6px 15px rgba(0,0,0,0.06);
    border-color: #ccc;
}

.settings-header {
    background: #f8f9fa;
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 10px 10px 0 0;
}
.settings-header i { font-size: 18px; color: #0073aa; opacity: 0.8; }
.settings-header h3 { margin: 0; font-size: 16px; color: #333; font-weight: 600; }

.settings-body { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }

/* Input Groups in Settings */
.input-group { display: flex; gap: 8px; margin-bottom: 20px; }
.input-group input { 
    flex: 1; 
    padding: 10px 12px; 
    border: 1px solid #ddd; 
    border-radius: 6px; 
    font-size: 14px;
    transition: border-color 0.2s;
}
.input-group input:focus { border-color: #0073aa; outline: none; }
.input-group button { padding: 0 15px; border-radius: 6px; }

/* List Items as Mini-Cards */
.eduhub-item-list { 
    list-style: none; 
    padding: 0; 
    margin: 0; 
    max-height: 350px; 
    overflow-y: auto; 
    scrollbar-width: thin;
}
.eduhub-item-list::-webkit-scrollbar { width: 6px; }
.eduhub-item-list::-webkit-scrollbar-thumb { background-color: #ccc; border-radius: 3px; }

.eduhub-item-list li { 
    background: #ffffff; 
    border: 1px solid #f0f0f0; 
    margin-bottom: 8px;
    padding: 10px 12px; 
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    border-radius: 6px;
    transition: background 0.2s;
    font-size: 14px;
}
.eduhub-item-list li:hover { background: #fbfbfb; border-color: #e0e0e0; }

.eduhub-item-list li span { 
    color: #ff5252; 
    cursor: pointer; 
    font-weight: bold; 
    padding: 4px 8px; 
    border-radius: 4px;
    background: #fff0f0;
    font-size: 16px;
    line-height: 1;
    transition: all 0.2s;
}
.eduhub-item-list li span:hover { background: #ff5252; color: #fff; }

/* Generic Inputs */
.eduhub-select, .eduhub-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 18px;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 14px;
    background: #fff;
}
.eduhub-select:focus, .eduhub-input:focus { border-color: #0073aa; outline: none; }

label { display: block; margin-bottom: 6px; font-weight: 600; color: #444; font-size: 14px; }

/* Buttons */
.btn-primary { 
    background: #0073aa; 
    color: white; 
    border: none; 
    padding: 10px 20px; 
    border-radius: 6px; 
    cursor: pointer; 
    font-weight: 600; 
    font-size: 14px;
    transition: background 0.2s; 
}
.btn-primary:hover { background: #005177; }

/* --- RESOURCE GRID (Already responsive, tweaked spacing) --- */
.eduhub-resource-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.eduhub-resource-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
    overflow: hidden;
}

.eduhub-resource-card:hover { transform: translateY(-3px); box-shadow: 0 8px 15px rgba(0,0,0,0.08); border-color: #b0d4f1; }
.card-header { padding: 12px 15px; background: #f8f9fa; border-bottom: 1px solid #eee; display: flex; justify-content: space-between; align-items: center; }
.card-body { padding: 15px; flex-grow: 1; }
.card-chapter-title { margin: 0 0 10px 0; font-size: 16px; color: #333; line-height: 1.4; font-weight: 600; }
.card-meta { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: #888; }
.badge { padding: 4px 10px; border-radius: 12px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.badge-class { background: #e3f2fd; color: #1565c0; }
.badge-subject { background: #e8f5e9; color: #2e7d32; }
.badge-pattern { background: #fff3e0; color: #ef6c00; border: 1px solid #ffe0b2; }

.card-footer { padding: 12px 15px; background: #fff; border-top: 1px solid #f0f0f0; }
.card-actions-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.admin-actions { display: flex; gap: 5px; margin-left: auto; }

.card-btn { padding: 6px 12px; border: none; border-radius: 4px; font-size: 12px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 5px; transition: background 0.2s; font-weight: 500; }
.btn-link { background: #f5f5f5; color: #333; } .btn-link:hover { background: #e0e0e0; }
.btn-embed { background: #e0f7fa; color: #006064; } .btn-embed:hover { background: #b2ebf2; }
.btn-edit { background: #fff8e1; color: #ff8f00; } .btn-edit:hover { background: #ffecb3; }
.btn-delete { background: #ffebee; color: #c62828; } .btn-delete:hover { background: #ffcdd2; }

/* Filter Bar */
.eduhub-filter-bar { background: #f8f9fa; padding: 15px; border-radius: 8px; margin-bottom: 20px; border: 1px solid #eee; }
.filter-group { display: flex; gap: 10px; flex-wrap: wrap; }
.filter-group .eduhub-select { margin: 0; flex: 1; min-width: 150px; }

/* --- MODAL --- */
.eduhub-modal { display: none; position: fixed; z-index: 9999; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.5); backdrop-filter: blur(2px); }
.eduhub-modal-content { background-color: #fefefe; margin: 5% auto; padding: 25px; border: none; width: 90%; max-width: 500px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.2); position: relative; animation: slideDown 0.3s ease-out; }
@keyframes slideDown { from { transform: translateY(-20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.eduhub-close { color: #aaa; float: right; font-size: 24px; font-weight: bold; cursor: pointer; line-height: 1; }
.eduhub-close:hover { color: #333; }