/* Khwarizmi Center - Professional CSS */
@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Tajawal', sans-serif;
    background: #f8fafc;
    color: #1e293b;
    direction: rtl;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Scroll to Top Button */
#backToTop {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: #dc2626;
    color: white;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
    border: none;
    font-size: 20px;
}

#backToTop:hover {
    background: #b91c1c;
    transform: translateY(-5px);
}

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

.reveal {
    opacity: 0;
    transition: all 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    animation: fadeInUp 0.8s ease-out;
}

/* Section Header Improvement */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 900;
    color: #1e40af;
    margin-bottom: 16px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: 50%;
    transform: translateX(50%);
    width: 80px;
    height: 4px;
    background: #dc2626;
    border-radius: 2px;
}

.section-subtitle {
    font-size: 18px;
    color: #64748b;
    font-weight: 700;
}

/* Utility Classes */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
}

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

.btn-primary:hover {
    background: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(220, 38, 38, 0.3);
}

.btn-secondary {
    background: #1e40af;
    color: white;
}

.btn-secondary:hover {
    background: #1e3a8a;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid #1e40af;
    color: #1e40af;
}

.btn-outline:hover {
    background: #1e40af;
    color: white;
}

/* Sticky Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #1e40af;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    border-bottom: 4px solid #dc2626;
    width: 100%;
}

.navbar .container,
.navbar-container {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.navbar-container {
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: white;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: white;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #1e40af;
    font-weight: 900;
    font-size: 20px;
    line-height: 1;
    border: 2px solid #dc2626;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.logo-text h1 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 2px;
}

.logo-text p {
    font-size: 10px;
    color: #fca5a5;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-style: italic;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    position: static;
}

/* Mobile Navigation (max-width: 768px) */
@media (max-width: 768px) {
    /* Show hamburger button on mobile */
    .mobile-menu-btn {
        display: flex !important;
    }
    
    /* Mobile nav container */
    .navbar .container,
    .navbar-container {
        height: 65px !important;
        max-width: 100% !important;
        padding: 0 16px !important;
    }
    
    /* Nav links - hidden by default on mobile */
    .nav-links {
        position: fixed !important;
        top: 65px !important;
        right: 0 !important;
        width: 100% !important;
        background: #1e40af !important;
        flex-direction: column !important;
        padding: 0 !important;
        gap: 0 !important;
        transform: translateY(-120%) !important;
        opacity: 0 !important;
        visibility: hidden !important;
        transition: transform 0.3s ease, opacity 0.3s ease !important;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
        z-index: 998 !important;
        margin: 0 !important;
        border-top: 4px solid #dc2626;
    }
    
    /* Nav links when active (open) */
    .nav-links.active {
        transform: translateY(0) !important;
        opacity: 1 !important;
        visibility: visible !important;
    }
    
    /* Nav links items */
    .nav-links a {
        display: block !important;
        width: 100% !important;
        padding: 16px 20px !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
        font-size: 16px !important;
        text-align: right !important;
        color: white !important;
        text-decoration: none !important;
        font-weight: 700 !important;
    }
    
    .nav-links a:hover {
        background: rgba(255, 255, 255, 0.1) !important;
    }
    
    .nav-links a:last-child {
        border-bottom: none !important;
    }
    
    /* Nav links button */
    .nav-links .btn {
        margin: 16px 20px !important;
        text-align: center !important;
        width: calc(100% - 40px) !important;
    }
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #fca5a5;
}

.nav-links a.active {
    color: #fca5a5;
}

/* Mobile Menu Button - Desktop: Hidden, Mobile: Visible */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    padding: 10px;
    transition: all 0.3s ease;
    gap: 5px;
    z-index: 1001;
    flex-shrink: 0;
}

.mobile-menu-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.mobile-menu-btn span {
    display: block;
    width: 22px;
    height: 2.5px;
    background: white;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

/* Hero Section with Slideshow - 30% smaller */
.hero {
    position: relative;
    height: 55vh;
    min-height: 400px;
    background: #1e40af;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: all 1s ease-in-out;
    transform: scale(1.1) translateX(20px);
}

.slide.active {
    opacity: 1;
    transform: scale(1) translateX(0);
}

.slide img,
.slide video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, #1e40af, rgba(30, 64, 175, 0.4), transparent);
    display: flex;
    align-items: center;
}

.slide-text-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    z-index: 5;
}

.slide-text-overlay.center {
    justify-content: center;
    text-align: center;
}

.slide-text-overlay.right {
    justify-content: flex-end;
    text-align: right;
    padding-right: 10%;
}

.slide-text-overlay.left {
    justify-content: flex-start;
    text-align: left;
    padding-left: 10%;
}

.slide-content {
    max-width: 768px;
    animation: slideInRight 1s ease-out;
    padding: 20px;
    color: white;
}

.slide-text-overlay .slide-content {
    margin: 0;
}

.slide-badge {
    display: inline-block;
    padding: 8px 16px;
    background: #dc2626;
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 24px;
}

.slide-title {
    font-size: clamp(24px, 4vw, 48px);
    font-weight: 900;
    color: white;
    margin-bottom: 16px;
    line-height: 1.2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.slide-subtitle {
    font-size: clamp(14px, 2vw, 20px);
    color: #dbeafe;
    margin-bottom: 24px;
    font-weight: 700;
    line-height: 1.4;
}

.slide-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.slide-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 12px;
    z-index: 10;
}

.slide-btn {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.15);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
}

.slide-btn:hover {
    background: #dc2626;
}

.slide-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.dot {
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.5s ease;
    width: 8px;
}

.dot.active {
    width: 48px;
    background: #dc2626;
}

.dot:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Features Section */
.features {
    padding: 80px 0;
    background: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 48px;
}

.feature-card {
    text-align: center;
    padding: 32px;
    border-radius: 24px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    background: #f8fafc;
    transform: translateY(-4px);
}

.feature-icon {
    width: 80px;
    height: 80px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    font-size: 40px;
    border: 4px solid white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
}

.feature-icon.red {
    background: #fef2f2;
    color: #dc2626;
}

.feature-icon.blue {
    background: #eff6ff;
    color: #1e40af;
}

.feature-icon.green {
    background: #f0fdf4;
    color: #16a34a;
}

.feature-title {
    font-size: 24px;
    font-weight: 900;
    color: #1e40af;
    margin-bottom: 16px;
}

.feature-description {
    color: #64748b;
    font-weight: 700;
    line-height: 1.6;
}

/* Registration Form */
.registration {
    padding: 80px 0;
    background: #f8fafc;
}

.registration-form {
    background: white;
    border-radius: 48px;
    padding: 40px 80px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-top: 8px solid #dc2626;
    max-width: 900px;
    margin: 0 auto;
}

.form-header {
    text-align: center;
    margin-bottom: 64px;
}

.form-title {
    font-size: 36px;
    font-weight: 900;
    color: #1e40af;
    margin-bottom: 16px;
}

.form-subtitle {
    color: #64748b;
    font-weight: 700;
    max-width: 400px;
    margin: 0 auto;
    line-height: 1.6;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-label {
    font-size: 14px;
    font-weight: 900;
    color: #1e40af;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.form-input,
.form-select,
.form-textarea {
    padding: 20px;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 700;
    background: #f8fafc;
    transition: all 0.3s ease;
    font-family: 'Tajawal', sans-serif;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: #dc2626;
    background: white;
}

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

/* Footer */
.footer {
    background: #1e40af;
    color: white;
    padding: 96px 0 48px;
    position: relative;
    overflow: hidden;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 8px;
    background: #dc2626;
}

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

.footer-brand {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
}

.footer-logo {
    width: 56px;
    height: 56px;
    background: white;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #1e40af;
    font-weight: 900;
    font-size: 24px;
    line-height: 1;
    border: 2px solid #dc2626;
}

.footer-name {
    font-size: 28px;
    font-weight: 900;
}

.footer-description {
    color: #dbeafe;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 32px;
    max-width: 400px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-link {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.social-link:hover {
    background: #dc2626;
    transform: translateY(-2px);
}

.footer-section h3 {
    font-size: 20px;
    font-weight: 900;
    margin-bottom: 32px;
    color: #fca5a5;
    border-right: 4px solid #dc2626;
    padding-right: 16px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 16px;
}

.footer-links a {
    color: #dbeafe;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #fca5a5;
}

.contact-info {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: #dc2626;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: transform 0.3s ease;
}

.contact-info:hover .contact-icon {
    transform: scale(1.1);
}

.contact-text {
    color: #dbeafe;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.6;
}

.footer-bottom {
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    color: #93c5fd;
    font-size: 12px;
    font-weight: 700;
}

/* Alert Messages */
.alert {
    padding: 16px 24px;
    border-radius: 16px;
    margin-bottom: 24px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-success {
    background: #f0fdf4;
    color: #16a34a;
    border: 2px solid #16a34a;
}

.alert-error {
    background: #fef2f2;
    color: #dc2626;
    border: 2px solid #dc2626;
}

/* Animations */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(48px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    .hero {
        min-height: 45vh;
        height: 45vh;
    }
    
    .hero-content {
        padding: 0 16px;
    }
    
    .hero-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .features-grid,
    .courses-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .feature-card,
    .course-card {
        padding: 24px;
    }
    
    .admin-container {
        flex-direction: column;
    }
    
    .admin-sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    
    .admin-content {
        margin-right: 0;
        margin-left: 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    
    .admin-grid {
        grid-template-columns: 1fr;
    }
    
    .data-table {
        overflow-x: auto;
    }
    
    .table-header {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }
    
    .student-card {
        padding: 16px;
    }
    
    .slide-card {
        margin-bottom: 16px;
    }
    
    .slides-grid {
        grid-template-columns: 1fr;
    }
    
    .content-tabs .tab-navigation {
        flex-direction: column;
    }
    
    .tab-btn {
        border-bottom: 1px solid #e2e8f0 !important;
        border-right: none !important;
    }
    
    .tab-btn.active {
        border-bottom: 3px solid #1e40af !important;
    }
    
    .tab-content {
        padding: 20px;
    }
    
    .media-upload-section {
        padding: 20px;
    }
    
    .dropZone {
        padding: 32px 16px;
        font-size: 14px;
    }
    
    .quick-actions {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    /* Footer mobile */
    .footer .footer-content {
        flex-direction: column;
        gap: 24px;
    }
    
    .footer .footer-section {
        width: 100%;
    }
    
    /* Registration form mobile */
    .registration-form {
        padding: 20px;
        margin: 0 8px;
        border-radius: 20px;
    }
    
    .form-grid {
        grid-template-columns: 1fr !important;
        gap: 16px;
    }
    
    /* Course details mobile */
    .course-details-wrapper {
        padding: 0 16px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
    
    /* Logo mobile */
    .logo img {
        width: 42px !important;
        height: 42px !important;
    }
    
    .logo-text h1 {
        font-size: 16px !important;
    }
    
    .logo-text p {
        font-size: 9px !important;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 20px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .btn {
        font-size: 14px;
        padding: 10px 20px;
    }
    
    .btn-large {
        font-size: 16px;
        padding: 14px 28px;
    }
    
    .feature-card,
    .course-card {
        padding: 20px;
    }
    
    .course-image {
        height: 180px;
    }
    
    .course-content {
        padding: 20px;
    }
    
    .course-title {
        font-size: 18px;
    }
    
    .course-description {
        font-size: 14px;
    }
    
    .course-meta {
        flex-direction: column;
        gap: 8px;
        text-align: center;
        padding: 12px 0;
    }
    
    .course-features {
        justify-content: center;
    }
    
    .btn-outline {
        width: 100%;
        justify-content: center;
    }
    
    .admin-header {
        padding: 20px;
    }
    
    .admin-card {
        padding: 20px;
    }
    
    .data-table {
        margin-bottom: 20px;
    }
    
    .table-title {
        font-size: 18px;
    }
    
    .search-box {
        width: 100%;
    }
    
    .student-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .student-actions form {
        width: 100%;
    }
    
    .status-select {
        width: 100%;
    }
    
    .btn-delete {
        width: 100%;
        justify-content: center;
    }
    
    .content-tabs .tab-navigation {
        flex-direction: column;
    }
    
    .tab-btn {
        border-bottom: 1px solid #e2e8f0 !important;
        border-right: none !important;
    }
    
    .tab-btn.active {
        border-bottom: 3px solid #1e40af !important;
    }
    
    .tab-content {
        padding: 16px;
    }
    
    .media-upload-section {
        padding: 16px;
    }
    
    .dropZone {
        padding: 24px 12px;
        font-size: 14px;
    }
    
    .quick-actions {
        grid-template-columns: 1fr;
        gap: 8px;
    }
}

/* Admin Panel Styles */
.admin-container {
    min-height: 100vh;
    background: #f1f5f9;
    display: flex;
    align-items: stretch;
}

.admin-sidebar {
    width: 320px;
    background: #1e40af;
    color: white;
    min-height: 100vh;
    padding: 24px;
    position: sticky;
    top: 0;
    flex: 0 0 320px;
}

.admin-logo {
    text-align: center;
    margin-bottom: 40px;
}

.admin-logo h2 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 8px;
}

.admin-logo p {
    color: #fca5a5;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.admin-nav {
    list-style: none;
}

.admin-nav li {
    margin-bottom: 8px;
}

.admin-nav a {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 24px;
    color: white;
    text-decoration: none;
    font-weight: 700;
    border-radius: 16px;
    transition: all 0.3s ease;
}

.admin-nav a:hover,
.admin-nav a.active {
    background: #dc2626;
    transform: translateX(-4px);
}

.admin-content {
    flex: 1;
    padding: 32px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    padding: 32px;
    border-radius: 32px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border-right: 8px solid #1e40af;
}

.stat-card.red {
    border-right-color: #dc2626;
}

.stat-card.blue {
    border-right-color: #3b82f6;
}

.stat-card.green {
    border-right-color: #16a34a;
}

.stat-label {
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 36px;
    font-weight: 900;
    color: #1e40af;
}

.stat-card.red .stat-value {
    color: #dc2626;
}

.stat-card.blue .stat-value {
    color: #3b82f6;
}

.stat-card.green .stat-value {
    color: #16a34a;
}

/* Table Styles */
.data-table {
    background: white;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.table-header {
    padding: 32px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.table-title {
    font-size: 28px;
    font-weight: 900;
    color: #1e40af;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    padding: 12px 20px;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
}

.search-box input {
    border: none;
    background: transparent;
    outline: none;
    font-weight: 700;
    font-family: 'Tajawal', sans-serif;
}

.table-content {
    padding: 32px;
}

.student-card {
    background: #f8fafc;
    border-radius: 24px;
    padding: 24px;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.student-card:hover {
    border-color: #fca5a5;
    transform: translateY(-2px);
}

.student-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.student-name {
    font-size: 20px;
    font-weight: 900;
    color: #1e40af;
}

.student-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
}

.student-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.status-select {
    background: #e2e8f0;
    border: none;
    padding: 12px 16px;
    border-radius: 12px;
    font-weight: 700;
    font-family: 'Tajawal', sans-serif;
    cursor: pointer;
}

.btn-delete {
    background: #fef2f2;
    color: #dc2626;
    border: none;
    padding: 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-delete:hover {
    background: #dc2626;
    color: white;
}

.badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.badge-danger {
    background: #fef2f2;
    color: #dc2626;
}

.badge-success {
    background: #f0fdf4;
    color: #16a34a;
}

/* Forms */
.admin-form {
    background: white;
    border-radius: 48px;
    padding: 40px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-top: 8px solid #dc2626;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.form-actions {
    margin-top: 32px;
}

.btn-admin {
    background: #1e40af;
    color: white;
    padding: 20px 40px;
    border: none;
    border-radius: 16px;
    font-weight: 700;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-admin:hover {
    background: #dc2626;
    transform: translateY(-2px);
}

/* Login Form */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    padding: 20px;
}

.login-form {
    background: white;
    border-radius: 48px;
    padding: 48px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-bottom: 8px solid #dc2626;
    max-width: 400px;
    width: 100%;
    text-align: center;
}

.login-icon {
    width: 80px;
    height: 80px;
    background: #1e40af;
    color: white;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 32px;
    font-size: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.login-title {
    font-size: 28px;
    font-weight: 900;
    color: #1e40af;
    margin-bottom: 8px;
}

.login-subtitle {
    color: #64748b;
    font-weight: 700;
    margin-bottom: 32px;
}

.login-input {
    width: 100%;
    padding: 20px;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    letter-spacing: 8px;
    margin-bottom: 24px;
    background: #f8fafc;
    font-family: 'Tajawal', sans-serif;
}

.login-input:focus {
    outline: none;
    border-color: #dc2626;
    background: white;
}

/* Loading */
.loading {
    opacity: 0.5;
    pointer-events: none;
}

/* Print Styles */
@media print {
    .navbar,
    .admin-sidebar,
    .btn,
    .slide-controls,
    .slide-dots {
        display: none !important;
    }
    
    .admin-content {
        padding: 0 !important;
    }
    
    .student-card {
        break-inside: avoid;
    }
}

/* ============================================
   MOBILE RESPONSIVE STYLES
   ============================================ */

/* Tablet and smaller (max-width: 1024px) */
@media (max-width: 1024px) {
    .container {
        padding: 0 20px;
    }
    
    .hero {
        height: 55vh;
        min-height: 400px;
    }
    
    .footer .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px;
    }
}

/* Mobile and smaller (max-width: 768px) */
@media (max-width: 768px) {
    /* Base mobile styles */
    * {
        -webkit-tap-highlight-color: transparent;
    }
    
    html {
        font-size: 16px;
    }
    
    body {
        overflow-x: visible;
    }
    
    .container {
        padding: 0 16px;
        max-width: 100%;
    }
    
    /* Navbar */
    .navbar {
        position: sticky;
        top: 0;
        z-index: 1000;
    }
    
    .navbar .container {
        height: 65px;
        padding: 0 16px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    
    /* Logo */
    .logo {
        display: flex;
        align-items: center;
        gap: 10px;
        text-decoration: none;
    }
    
    .logo img {
        width: 42px;
        height: 42px;
        border-radius: 10px;
    }
    
    .logo-text h1 {
        font-size: 18px;
        font-weight: 900;
    }
    
    .logo-text p {
        font-size: 9px;
    }
    
    /* Hamburger Menu Button */
    .mobile-menu-btn {
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 44px;
        height: 44px;
        background: rgba(255, 255, 255, 0.15);
        border: none;
        border-radius: 8px;
        cursor: pointer;
        padding: 8px;
        gap: 5px;
    }
    
    .mobile-menu-btn span {
        display: block;
        width: 22px;
        height: 2.5px;
        background: white;
        border-radius: 2px;
        transition: all 0.3s ease;
    }
    
    .mobile-menu-btn.active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }
    
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-btn.active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }
    
    /* Navigation Links - Mobile */
    .nav-links {
        position: fixed;
        top: 65px;
        right: 0;
        width: 100%;
        background: #1e40af;
        flex-direction: column;
        padding: 0;
        gap: 0;
        transform: translateY(-150%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        z-index: 999;
        border-top: 4px solid #dc2626;
    }
    
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-links a {
        display: block;
        width: 100%;
        padding: 16px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        color: white;
        text-decoration: none;
        font-weight: 700;
        font-size: 16px;
        text-align: right;
    }
    
    .nav-links a:hover {
        background: rgba(255, 255, 255, 0.1);
    }
    
    .nav-links .btn {
        margin: 16px 20px;
        text-align: center;
    }
    
    /* Hero Section - 30% smaller */
    .hero {
        height: 45vh;
        min-height: 300px;
    }
    
    .slide-content {
        padding: 20px;
        text-align: center;
    }
    
    .slide-title {
        font-size: clamp(22px, 5vw, 32px);
        font-weight: 900;
        margin-bottom: 12px;
    }
    
    .slide-subtitle {
        font-size: clamp(14px, 3vw, 18px);
        margin-bottom: 20px;
    }
    
    .slide-button {
        padding: 10px 24px;
        font-size: 14px;
    }
    
    .slide-controls {
        bottom: 15px;
        right: 15px;
    }
    
    .slide-btn {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
    
    .slide-dots {
        bottom: 15px;
    }
    
    /* Features Section */
    .features {
        padding: 40px 0;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .feature-card {
        padding: 20px;
    }
    
    .section-title {
        font-size: clamp(24px, 5vw, 32px);
    }
    
    .section-subtitle {
        font-size: 14px;
    }
    
    /* Courses Section */
    .courses-section {
        padding: 40px 0;
    }
    
    .courses-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .course-card {
        border-radius: 16px;
    }
    
    .course-image {
        height: 180px;
    }
    
    .course-content {
        padding: 20px;
    }
    
    .course-title {
        font-size: 18px;
    }
    
    /* Registration Form */
    .registration {
        padding: 40px 0;
    }
    
    .registration-form {
        padding: 24px 20px;
        margin: 0 10px;
        border-radius: 20px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .form-title {
        font-size: 22px;
    }
    
    .form-input,
    .form-select,
    .form-textarea {
        padding: 14px 16px;
        font-size: 15px;
    }
    
    /* Contact Section */
    #contact {
        padding: 40px 0;
    }
    
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .contact-item {
        flex-direction: row;
        gap: 12px;
    }
    
    .contact-icon {
        width: 44px;
        height: 44px;
    }
    
    .contact-form-wrapper {
        padding: 20px;
    }
    
    /* Footer */
    .footer {
        padding: 40px 0 24px;
    }
    
    .footer .footer-content {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .footer-brand {
        flex-direction: row;
        gap: 12px;
    }
    
    .footer-section h3 {
        font-size: 16px;
    }
    
    .footer-links li {
        margin-bottom: 10px;
    }
    
    /* Buttons */
    .btn {
        width: 100%;
        max-width: 280px;
        padding: 14px 20px;
        font-size: 15px;
    }
    
    .btn-primary,
    .btn-secondary,
    .btn-outline {
        display: flex;
        justify-content: center;
        align-items: center;
    }
    
    /* Course Details */
    .course-hero {
        height: 40vh;
        min-height: 280px;
    }
    
    .course-hero h1 {
        font-size: clamp(24px, 5vw, 32px);
    }
    
    .course-hero p {
        font-size: clamp(14px, 3vw, 18px);
    }
    
    .course-info-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .course-features-grid {
        grid-template-columns: 1fr;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    /* Login */
    .login-container {
        padding: 20px;
    }
    
    .login-form {
        padding: 24px 20px;
        border-radius: 20px;
    }
}

/* Very small mobile (max-width: 480px) */
@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
    
    .navbar .container {
        height: 60px;
        padding: 0 12px;
    }
    
    .logo img {
        width: 38px;
        height: 38px;
    }
    
    .logo-text h1 {
        font-size: 16px;
    }
    
    .mobile-menu-btn {
        width: 40px;
        height: 40px;
    }
    
    .nav-links {
        top: 60px;
    }
    
    .hero {
        height: 40vh;
        min-height: 280px;
    }
    
    .slide-title {
        font-size: 20px;
    }
    
    .slide-subtitle {
        font-size: 13px;
    }
    
    .features,
    .courses-section,
    .registration,
    #contact {
        padding: 32px 0;
    }
    
    .section-title {
        font-size: 22px;
    }
    
    .feature-card,
    .course-card {
        padding: 16px;
    }
    
    .registration-form {
        padding: 20px 16px;
        margin: 0 8px;
    }
    
    .footer {
        padding: 32px 0 20px;
    }
    
    .footer-brand img {
        width: 40px;
        height: 40px;
    }
    
    .footer-name {
        font-size: 18px;
    }
}
