@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;800&family=Noto+Sans+Arabic:wght@300;400;600;800&display=swap');

:root {
    --bg: #b7c2ca;
    --text: #171616;
    --card-bg: #c3a7a7;
    --card-border: #dddddd;
    --divider: #cccccc;
    --surface: #efeff0;
    --primary: #516375;
    --on-primary: #ffffff;
    --accent: #28a745;
    --message-bot-bg: #f4f4f4;
    --input-border: #f4eeee;
    --input-bg: #f4eded;
    --shadow-color: rgba(0,0,0,0.1);
    --error: #dc2626;
    --brand: #0d0d0d;
    --brand-hover: #ea580c;
    --muted: #0a0a0b;
    --blue: #1e1f20;
    --transition-fast: 0.2s ease;
    --transition-slow: 0.5s ease;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes blurIn {
    from { filter: blur(10px); opacity: 0; transform: scale(0.95); }
    to { filter: blur(0); opacity: 1; transform: scale(1); }
}

@keyframes textGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes slideInRight {
    from { transform: translateX(50px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.animate-fade {
    animation: fadeIn var(--transition-slow) forwards;
}

.animate-blur {
    animation: blurIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.gradient-text {
    background: linear-gradient(-45deg, var(--primary), var(--accent), var(--brand), var(--primary));
    background-size: 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: textGradient 6s ease infinite;
}

.animate-slide {
    animation: slideInRight var(--transition-slow) forwards;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.hover-lift {
    transition: transform var(--transition-fast);
}

.hover-lift:hover {
    transform: translateY(-5px);
}

[data-theme="dark"] {
    --bg: #111418;
    --text: #4996ae;
    --card-bg: #1a1f29;
    --card-border: #2a2f3a;
    --divider: #2a2f3a;
    --surface: #1f2430;
    --primary: #4996ae;
    --on-primary: #211c1c;
    --accent: #22c55e;
    --message-bot-bg: #2a2f3a;
    --input-border: #344050;
    --input-bg: #1a1f29;
    --shadow-color: rgba(0,0,0,0.6);
    --error: #d3bebe;
    --brand: #f97316;
    --brand-hover: #ea580c;
    --muted: #9ca3af;
}
/* General Reset and Base Styles */
#lang-toggle {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1001;
    text-transform: uppercase;
}

.flag-btn {
    position: absolute;
    top: 16px;
    left: 16px;
    width: 64px;
    height: 44px;
    border: 1px solid var(--card-border);
    border-radius: 10px;
    padding: 0;
    background: transparent;
    cursor: pointer;
    box-shadow: 0 2px 6px var(--shadow-color);
    overflow: hidden;
}

.flag-btn svg {
    display: block;
    width: 100%;
    height: 100%;
}

.flag-btn:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

body {
    font-family: 'Poppins', 'Noto Sans Arabic', sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--bg);
    color: var(--text);
}

/* Marketing Section Styles */
.hero {
     background: url('viber_image_2022-11-30_11-55-37-844-e1670156336633.jpg');
  background-repeat: no-repeat;
    background-size: cover; 
  background-position: center; 
  
    color: var(--text);
    padding: 100px 5%;
    text-align: center;
}
.hero h1 {
    font-size: 2.5em;
}
.hero button {
    padding: 12px 25px;
    background-color: var(--accent);
    color: var(--on-primary);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 1.1em;
    margin-top: 20px;
}
#theme-toggle {
    position: fixed;
    top: 16px;
    right: 16px;
    padding: 10px 14px;
    background-color: var(--primary);
    color: var(--on-primary);
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 0.95em;
    box-shadow: 0 2px 6px var(--shadow-color);
    z-index: 1001;
}
.hero-title {
    display: block;
}
.hero-subtitle {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}
.hero #lang-toggle {
    position: static;
    display: inline-block;
    margin-top: 0;
    padding: 10px 14px;
    background-color: var(--primary);
    color: var(--on-primary);
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    font-size: 0.95em;
    box-shadow: 0 2px 6px var(--shadow-color);
}
/* Login Section */
.login-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 24px;
    border-radius: var(--radius-lg);
    max-width: 420px;
    margin: 0 auto;
    box-shadow: 0 4px 8px var(--shadow-color);
}
.login-controls {
    display: flex;
    gap: 12px;
    justify-content: center;
}
.login-controls input {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--input-border);
    border-radius: var(--radius-md);
    background: var(--input-bg);
    color: var(--text);
}
.login-button {
    background-color: var(--primary);
    color: var(--on-primary);
    border: none;
    border-radius: var(--radius-md);
    padding: 10px 16px;
    cursor: pointer;
}
.login-message {
    margin-top: 12px;
    font-weight: 600;
}
.login-message.success {
    color: var(--accent);
}
.login-message.error {
    color: var(--error);
}
.auth-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 24px var(--shadow-color);
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    overflow: hidden;
    max-width: 960px;
    margin: 0 auto;
}
.auth-media {
    position: relative;
    background: radial-gradient(1000px 1000px at 0% 100%, #fb923c 0%, transparent 50%), radial-gradient(800px 800px at 100% 0%, #fdba74 0%, transparent 50%), linear-gradient(135deg, var(--brand) 0%, #fb923c 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}
.auth-media img {
    max-width: 80%;
    border-radius: var(--radius-md);
}
.auth-content {
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.auth-logo {
    font-weight: 800;
    color: var(--brand);
}
.auth-title {
    margin: 0;
    font-size: 1.75rem;
}
.muted {
    color: var(--muted);
}
.small {
    font-size: 0.9rem;
}
.auth-form input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--input-border);
    border-radius: var(--radius-md);
    background: var(--input-bg);
    color: var(--text);
}
.auth-form .field {
    margin-bottom: 12px;
}
.auth-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0 16px;
}
.link {
    color: var(--brand);
    text-decoration: none;
}
.btn-primary {
    background: var(--brand);
    color: var(--on-primary);
    border: none;
    border-radius: var(--radius-md);
    padding: 12px 16px;
    cursor: pointer;
}
.btn-primary:hover {
    background: var(--brand-hover);
}
.btn-primary[disabled] {
    opacity: 0.6;
    cursor: not-allowed;
}
.shake {
    animation: shake 0.4s ease;
}
@keyframes shake {
    0% { transform: translateX(0); }
    20% { transform: translateX(-3px); }
    40% { transform: translateX(3px); }
    60% { transform: translateX(-3px); }
    80% { transform: translateX(3px); }
    100% { transform: translateX(0); }
}
.btn-google {
    background: var(--card-bg);
    color: var(--text);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    cursor: pointer;
}
.full {
    width: 100%;
}
@media (max-width: 900px) {
    .auth-card { grid-template-columns: 1fr; }
    .auth-media { min-height: 220px; }
}
[data-theme="light"] .hero h1,
[data-theme="light"] .hero p {
    color: var(--blue);
}
[data-theme="light"] .hero button:not(#theme-toggle) {
    color: var(--blue);
}
[data-theme="light"] #theme-toggle {
    color: var(--blue);
}
.section {
    padding: 50px 5%;
    text-align: center;
}
.tier-grid {
    display: flex;
    justify-content: space-around;
    gap: 20px;
    margin-top: 30px;
}
.tier, .card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 0;
    text-align: left;
    transition: all var(--transition-slow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tier {
    width: 30%;
    box-shadow: 0 4px 15px var(--shadow-color);
    position: relative;
}

.tier-image, .card-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
}

.card-image {
    height: 150px;
}

.tier-image img, .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.tier:hover .tier-image img, .card:hover .card-image img {
    transform: scale(1.1);
}

.tier .computer-btn, .card-content {
    padding: 20px;
    flex-grow: 1;
}

.tier .computer-btn {
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
}

.tier h3, .card h3 {
    margin: 0 0 10px 0;
    color: var(--primary);
}

.tier p, .card p {
    margin: 0;
    color: var(--text);
    line-height: 1.6;
}

.tier:hover, .card:hover {
    box-shadow: 0 10px 30px var(--shadow-color);
    border-color: var(--accent);
}

.tier::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: 0.5s;
}

.tier:hover::before {
    left: 100%;
}

/* Chatbot Styles */
.chatbot-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 300px;
    height: 400px;
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 5px 15px var(--shadow-color);
    background: var(--card-bg);
    display: none; /* Starts hidden, activated by button */
    flex-direction: column;
    z-index: 1000;
}
.chatbot-header {
    background-color: var(--primary);
    color: var(--on-primary);
    padding: 10px;
    border-top-left-radius: var(--radius-lg);
    border-top-right-radius: var(--radius-lg);
    font-weight: bold;
    display: flex;
    justify-content: space-between;
}
.close-btn {
    cursor: pointer;
    font-size: 1.2em;
}
.chat-messages {
    flex-grow: 1;
    padding: 10px;
    overflow-y: auto;
    background-color: var(--surface);
}
.message {
    padding: 8px 12px;
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    max-width: 80%;
}
.user-message {
    background-color: var(--primary);
    color: var(--on-primary);
    margin-left: auto;
    text-align: right;
}
.bot-message {
    background-color: var(--message-bot-bg);
    color: var(--text);
    text-align: left;
}
.chat-input {
    display: flex;
    padding: 10px;
    border-top: 1px solid var(--divider);
}
.chat-input input {
    flex-grow: 1;
    padding: 8px;
    border: 1px solid var(--input-border);
    border-radius: var(--radius-full);
    margin-right: 10px;
    background: var(--input-bg);
    color: var(--text);
}
.chat-input button {
    background-color: var(--accent);
    color: var(--on-primary);
    border: none;
    border-radius: var(--radius-full);
    padding: 8px 15px;
    cursor: pointer;
}

/* News & Events Section */
.news-section {
    padding: 60px 20px;
    background: var(--bg);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    max-width: 1200px;
    margin: 40px auto 0;
}

.news-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-slow);
    display: flex;
    flex-direction: column;
    position: relative;
}

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px var(--shadow-color);
}

.news-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--primary);
    color: var(--on-primary);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 1;
}

.news-tag.event {
    background: #e91e63;
}

.news-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.1);
}

.news-body {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-date {
    font-size: 0.85rem;
    color: var(--muted);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.news-body h3 {
    margin: 0 0 12px;
    font-size: 1.25rem;
    color: var(--text);
}

.news-body p {
    font-size: 0.95rem;
    color: var(--muted);
    line-height: 1.6;
    margin-bottom: 20px;
}

.read-more {
    margin-top: auto;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: gap 0.3s;
}

.read-more:hover {
    gap: 10px;
}

@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: 1fr;
    }
}

/* Portal Specific Variables */
:root {
    --portal-sidebar-width: 280px;
    --portal-header-height: 80px;
    --portal-bg: #f8fafc;
    --portal-card-bg: #ffffff;
    --portal-primary: #4f46e5;
    --portal-secondary: #64748b;
    --portal-accent: #10b981;
    --portal-warning: #f59e0b;
    --portal-danger: #ef4444;
    --portal-border: #e2e8f0;
    --portal-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --portal-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

[data-theme="dark"] {
    --portal-bg: #0f172a;
    --portal-card-bg: #1e293b;
    --portal-primary: #818cf8;
    --portal-secondary: #94a3b8;
    --portal-border: #334155;
}

/* PDF Section & Cards */
.pdf-section {
    padding: 24px;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.badge {
    background: var(--portal-primary);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.pdf-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.pdf-card {
    background: var(--portal-bg);
    border: 1px solid var(--portal-border);
    border-radius: 16px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.pdf-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--portal-shadow);
    border-color: var(--portal-primary);
    background: white;
}

.pdf-icon-wrapper {
    width: 48px;
    height: 48px;
    background: rgba(79, 70, 229, 0.1);
    color: var(--portal-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pdf-details {
    flex-grow: 1;
    overflow: hidden;
}

.pdf-details h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--portal-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdf-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    color: #94a3b8;
    margin-top: 4px;
}

.dot {
    width: 4px;
    height: 4px;
    background: #cbd5e1;
    border-radius: 50%;
}

.pdf-download-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--portal-secondary);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.pdf-download-btn:hover {
    background: var(--portal-primary);
    color: white;
}

/* Dark mode overrides for PDF cards */
[data-theme="dark"] .pdf-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .pdf-card:hover {
    background: #1e293b;
    border-color: var(--portal-primary);
}

[data-theme="dark"] .pdf-details h4 {
    color: #e2e8f0;
}

[data-theme="dark"] .pdf-meta {
    color: #64748b;
}

@media (max-width: 640px) {
    .pdf-grid {
        grid-template-columns: 1fr;
    }
}

/* Portal Layout Overhaul */
.portal-body {
    display: flex;
    min-height: 100vh;
    background-color: var(--portal-bg);
    color: var(--text);
    overflow-x: hidden;
}

.sidebar {
    width: var(--portal-sidebar-width);
    background: var(--portal-card-bg);
    border-right: 1px solid var(--portal-border);
    padding: 32px 24px;
    position: fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 100;
    box-shadow: var(--portal-shadow);
}

.sidebar-logo {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--portal-primary);
    text-decoration: none;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 12px;
    color: var(--portal-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.nav-item svg {
    width: 22px;
    height: 22px;
    transition: transform 0.2s ease;
}

.nav-item:hover {
    background: var(--portal-bg);
    color: var(--portal-primary);
}

.nav-item:hover svg {
    transform: scale(1.1);
}

.nav-item.active {
    background: var(--portal-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.main-portal {
    margin-left: var(--portal-sidebar-width);
    flex: 1;
    padding: 40px;
    width: calc(100% - var(--portal-sidebar-width));
}

.portal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 48px;
    animation: fadeIn 0.6s ease-out;
}

.portal-header h1 {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 8px;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 8px 16px;
    background: var(--portal-card-bg);
    border-radius: 16px;
    border: 1px solid var(--portal-border);
    box-shadow: var(--portal-shadow);
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--portal-primary), #a78bfa);
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}

.portal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.portal-card {
    background: var(--portal-card-bg);
    border: 1px solid var(--portal-border);
    border-radius: 24px;
    padding: 32px;
    box-shadow: var(--portal-shadow);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.portal-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--portal-shadow-lg);
    border-color: var(--portal-primary);
}

.portal-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--portal-secondary);
    margin-bottom: 16px;
}

.stat-value.big {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 8px 0;
    letter-spacing: -2px;
}

.schedule-table {
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--portal-border);
    margin-top: 24px;
}

.schedule-table th {
    background: var(--portal-bg);
    padding: 20px;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    color: var(--portal-secondary);
}

.schedule-table td {
    padding: 20px;
    background: var(--portal-card-bg);
    border-bottom: 1px solid var(--portal-border);
}

.schedule-table tr:last-child td {
    border-bottom: none;
}

.schedule-table tr:hover td {
    background: rgba(79, 70, 229, 0.05);
}

.download-item {
    background: var(--portal-bg);
    padding: 16px 20px;
    border-radius: 16px;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

.download-item:hover {
    border-color: var(--portal-primary);
    background: var(--portal-card-bg);
    transform: scale(1.02);
}

.progress-bar {
    height: 10px;
    background: var(--portal-border);
    border-radius: 10px;
    margin: 12px 0;
}

.progress-fill {
    background: linear-gradient(90deg, var(--portal-primary), #a78bfa);
    border-radius: 10px;
}

@media (max-width: 1024px) {
    .sidebar { width: 80px; padding: 32px 16px; }
    .sidebar-logo span, .nav-item span { display: none; }
    .main-portal { margin-left: 80px; width: calc(100% - 80px); }
}

@media (max-width: 768px) {
    .portal-header { flex-direction: column; gap: 24px; }
    .main-portal { padding: 24px; }
}

/* Department Pages Styling */
.dept-header {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: white;
    padding: 60px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.dept-header::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.25);
}

.dept-header * {
    position: relative;
    z-index: 1;
}

.dept-header h1 {
    font-size: 2.5em;
    margin: 0;
    margin-bottom: 10px;
    text-shadow: 0 2px 12px rgba(0,0,0,0.6);
}

.dept-header p {
    font-size: 1.2em;
    margin: 0;
    opacity: 0.95;
    text-shadow: 0 1px 8px rgba(0,0,0,0.6);
}

.nav-bar {
    background-color: var(--card-bg);
    padding: 15px 20px;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    border-bottom: 2px solid var(--divider);
}

.nav-bar a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    padding: 8px 15px;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
}

.nav-bar a:hover {
    background-color: var(--primary);
    color: var(--on-primary);
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.section {
    margin-bottom: 50px;
}

.section h2 {
    font-size: 2em;
    margin-bottom: 20px;
    color: var(--primary);
    border-bottom: 3px solid var(--accent);
    padding-bottom: 10px;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 25px;
    box-shadow: 0 4px 15px var(--shadow-color);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px var(--shadow-color);
    border-color: var(--primary);
}

.card:hover::before {
    transform: scaleX(1);
}

.card h3 {
    color: var(--primary);
    margin-top: 0;
    margin-bottom: 10px;
}

.card p {
    color: var(--text);
    line-height: 1.6;
    margin: 0;
}

.course-list {
    background-color: var(--surface);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 20px;
}

.course-item {
    padding: 15px;
    border-left: 4px solid var(--primary);
    margin-bottom: 12px;
    background-color: var(--card-bg);
    border-radius: var(--radius-sm);
}

.course-item h4 {
    margin: 0 0 8px 0;
    color: var(--primary);
}

.course-item p {
    margin: 0;
    font-size: 0.95em;
}

.instructors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.instructor-card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 8px var(--shadow-color);
}

.instructor-card h4 {
    color: var(--primary);
    margin: 10px 0;
}

.instructor-card p {
    color: var(--text);
    font-size: 0.9em;
    margin: 5px 0;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: var(--accent);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: none;
    font-size: 1em;
    transition: all 0.3s ease;
    margin-right: 10px;
    margin-top: 10px;
}

.btn:hover {
    background-color: var(--primary);
    transform: scale(1.05);
}

.btn-secondary {
    background-color: var(--primary);
}

.btn-secondary:hover {
    background-color: var(--accent);
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-box {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: white;
    padding: 30px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: 0 4px 8px var(--shadow-color);
}

.stat-box h3 {
    margin: 0;
    font-size: 2.5em;
}

.stat-box p {
    margin: 10px 0 0 0;
    opacity: 0.9;
}

.back-btn {
    display: inline-block;
    margin-bottom: 20px;
    padding: 10px 20px;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-md);
    cursor: pointer;
}

.back-btn:hover {
    background-color: var(--accent);
}

@media (max-width: 768px) {
    .dept-header h1 {
        font-size: 1.8em;
    }

    .nav-bar {
        flex-direction: column;
    }

    .nav-bar a {
        width: 100%;
        text-align: center;
    }

    .stats-container {
        grid-template-columns: 1fr;
    }
}

.computer-page .dept-header { background-image: url('https://images.unsplash.com/photo-1518770660439-4636190af475?auto=format&fit=crop&w=1600&q=80'); }
.account-page .dept-header { background-image: url('https://images.unsplash.com/photo-1460925895917-afdab827c52f?auto=format&fit=crop&w=1600&q=80'); }
.business-page .dept-header { background-image: url('https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=1600&q=80'); }
