/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: #d42f32;
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo .logo-img {
    height: 40px;
    width: auto;
}

.nav-logo h2 {
    color: #ffffff;
    font-weight: 700;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #ffffff;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #ffffff;
    opacity: 0.8;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: #ffffff;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #ffffff;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #d42f32 0%, #942123 100%);
    color: white;
    padding-top: 80px;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: #d42f32;
    color: white;
    border-color: #d42f32;
}

.btn-primary:hover {
    background: #942123;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(212, 47, 50, 0.3);
}

.btn-secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background: white;
    color: #d42f32;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: #d42f32;
    border-color: #d42f32;
}

.btn-outline:hover {
    background: #d42f32;
    color: white;
    transform: translateY(-2px);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-placeholder {
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.hero-placeholder i {
    font-size: 6rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Section Styles */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #242323;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.1rem;
    color: #6b7280;
    max-width: 600px;
    margin: 0 auto;
}

/* About Section */
.about {
    background: #f9fafb;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text h3 {
    font-size: 1.8rem;
    color: #242323;
    margin-bottom: 1rem;
}

.about-text p {
    font-size: 1.1rem;
    color: #6b7280;
    margin-bottom: 2rem;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.feature:hover {
    transform: translateY(-5px);
}

.feature i {
    font-size: 3rem;
    color: #d42f32;
    margin-bottom: 1rem;
}

.feature h4 {
    font-size: 1.3rem;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.feature p {
    color: #6b7280;
}

/* Courses Section */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.course-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.course-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.course-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #d42f32, #942123);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.course-icon i {
    font-size: 2rem;
    color: white;
}

.course-card h3 {
    font-size: 1.5rem;
    color: #1f2937;
    margin-bottom: 1rem;
}

.course-card p {
    color: #6b7280;
    margin-bottom: 1.5rem;
}

.course-features {
    list-style: none;
    margin-bottom: 2rem;
}

.course-features li {
    padding: 0.5rem 0;
    color: #374151;
    position: relative;
    padding-left: 1.5rem;
}

.course-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: bold;
}

/* Results Section */
.results {
    background: linear-gradient(135deg, #242323 0%, #1f2937 100%);
    color: white;
}

.results .section-header h2,
.results .section-header p {
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-card {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: #d42f32;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Faculty Section */
.faculty {
    background: #f9fafb;
    padding: 5rem 0;
}

.faculty-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.faculty-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    text-align: center;
}

.faculty-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.faculty-image {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #d42f32, #942123);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2.5rem;
    color: white;
}

.faculty-info h3 {
    color: #242323;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.faculty-title {
    color: #d42f32;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.faculty-qualification {
    color: #6b7280;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.faculty-experience {
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.faculty-subjects {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.subject-tag {
    background: #d42f32;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Timetable Section */
.timetable {
    padding: 5rem 0;
    background: white;
}

.timetable-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.tab-btn {
    background: transparent;
    border: 2px solid #d42f32;
    color: #d42f32;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn.active,
.tab-btn:hover {
    background: #d42f32;
    color: white;
}

.timetable-content {
    margin-top: 2rem;
}

.timetable-tab {
    display: none;
}

.timetable-tab.active {
    display: block;
}

.schedule-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.schedule-item {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border-left: 4px solid #d42f32;
}

.schedule-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.subject-info {
    margin-bottom: 15px;
}

.subject-name {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 5px 0;
    color: #242323;
}

.teacher-name {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    font-weight: 500;
}

.schedule-details {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 15px;
}

.timing {
    flex: 1;
    font-size: 14px;
    color: #242323;
    font-weight: 600;
    line-height: 1.4;
}

.room {
    background: #d42f32;
    color: white;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

/* Subject-specific colors for schedule items */
.schedule-item .subject-name.math {
    color: #3b82f6;
}

.schedule-item .subject-name.physics {
    color: #10b981;
}

.schedule-item .subject-name.chemistry {
    color: #f59e0b;
}

.schedule-item .subject-name.english {
    color: #ef4444;
}

.schedule-item .subject-name.biology {
    color: #8b5cf6;
}

.schedule-item .subject-name.economics {
    color: #06b6d4;
}

.schedule-item .subject-name.ict {
    color: #6366f1;
}

.schedule-item .subject-name.business {
    color: #f97316;
}

.schedule-item .subject-name.pakistan {
    color: #059669;
}

.schedule-item .subject-name.islamiyat {
    color: #7c3aed;
}

.schedule-item .subject-name.urdu {
    color: #dc2626;
}

.schedule-item .subject-name.sociology {
    color: #0891b2;
}

.schedule-item .subject-name.psychology {
    color: #be185d;
}

.timetable-grid {
    display: grid;
    grid-template-columns: 120px repeat(6, 1fr);
    gap: 1px;
    background: #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    margin-top: 1rem;
}

.time-slot,
.day-header,
.class-slot,
.break-slot {
    background: white;
    padding: 1rem;
    text-align: center;
    font-weight: 500;
}

.time-slot.header,
.day-header {
    background: #242323;
    color: white;
    font-weight: 600;
}

.time-slot {
    background: #f9fafb;
    color: #242323;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.time-slot.break {
    background: #942123;
    color: white;
}

.break-slot {
    background: #fef3f3;
    color: #942123;
    font-style: italic;
}

.class-slot {
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer;
}

.class-slot:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.class-slot small {
    display: block;
    font-size: 0.8rem;
    color: #6b7280;
    margin-top: 0.25rem;
}

/* Subject-specific colors */
.class-slot.math {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
}

.class-slot.physics {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.class-slot.chemistry {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.class-slot.english {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
}

.class-slot.biology {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: white;
}

.class-slot.economics {
    background: linear-gradient(135deg, #d42f32, #942123);
    color: white;
}

.class-slot.ict,
.class-slot.cs {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: white;
}

.class-slot.business {
    background: linear-gradient(135deg, #ec4899, #db2777);
    color: white;
}

/* Contact Section */
.contact {
    background: #f9fafb;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.contact-item i {
    font-size: 1.5rem;
    color: #d42f32;
    margin-top: 0.25rem;
}

.contact-item h4 {
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.contact-item p {
    color: #6b7280;
}

.contact-form {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #d42f32;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Footer */
.footer {
    background: #1f2937;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: #d42f32;
}

.footer-section p {
    color: #d1d5db;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: #d42f32;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #374151;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: #d42f32;
    transform: translateY(-2px);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #374151;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: #d42f32;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        z-index: 1000;
    }
    
    /* Faculty responsive */
    .faculty-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .faculty-card {
        padding: 1.5rem;
    }
    
    /* Timetable responsive */
    .schedule-list {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 0 10px;
    }
    
    .schedule-item {
        padding: 15px;
    }
    
    .subject-name {
        font-size: 16px;
    }
    
    .teacher-name {
        font-size: 13px;
    }
    
    .timing {
        font-size: 13px;
    }
    
    .room {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .schedule-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .room {
        align-self: flex-end;
    }
    
    /* Legacy grid styles for mobile */
    .timetable-grid {
        grid-template-columns: 80px repeat(6, 1fr);
        font-size: 0.8rem;
    }
    
    .time-slot,
    .day-header,
    .class-slot,
    .break-slot {
        padding: 0.5rem 0.25rem;
    }
    
    .timetable-tabs {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
    
    .tab-btn {
        width: 200px;
        padding: 0.6rem 1.5rem;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-placeholder {
        width: 200px;
        height: 200px;
    }
    
    .hero-placeholder i {
        font-size: 4rem;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .courses-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 250px;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content,
.section-header,
.feature,
.course-card,
.stat-card {
    animation: fadeInUp 0.6s ease-out;
}

/* Smooth scrolling for older browsers */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* Focus styles for accessibility */
.btn:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #d42f32;
    outline-offset: 2px;
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #d42f32;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    box-shadow: 0 5px 15px rgba(212, 47, 50, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(212, 47, 50, 0.4);
}

/* Notification styles */
.notification {
    position: fixed;
    top: 100px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    color: white;
    font-weight: 500;
    z-index: 1001;
    transform: translateX(400px);
    transition: transform 0.3s ease;
}

.notification.show {
    transform: translateX(0);
}

.notification.success {
    background: #10b981;
}

.notification.error {
    background: #ef4444;
}

.notification.info {
    background: #d42f32;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .hero {
        background: #242323;
        color: #fff;
    }
    
    .btn-primary {
        background: #242323;
        border-color: #242323;
    }
}