/*
Theme Name: AKTutor - AKTU Student Portal
Description: High-performance WordPress theme for AKTU Engineering, Management, and Pharmacy students. Features study materials, video lectures, previous year papers, quizzes, jobs board, and community forums.
Version: 1.0.0
Author: AKTutor Team
Text Domain: aktutor
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 8.0
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Tags: education, responsive, accessibility-ready, custom-post-types, threaded-comments
*/

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

:root {
    /* Color Palette */
    --primary-blue: #1e3a8a;
    --secondary-orange: #f59e0b;
    --success-green: #10b981;
    --neutral-light: #f8fafc;
    --neutral-medium: #64748b;
    --neutral-dark: #1e293b;
    --white: #ffffff;
    --error-red: #ef4444;
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-body: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'Courier New', Monaco, monospace;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    
    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-normal: 300ms ease-in-out;
}

/* Base Typography */
body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--neutral-dark);
    background-color: var(--neutral-light);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: var(--spacing-md);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1.125rem; }

p {
    margin-bottom: var(--spacing-md);
}

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--secondary-orange);
}

/* Layout Components */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.grid {
    display: grid;
    gap: var(--spacing-lg);
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Header Styles */
.site-header {
    background: var(--white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md) 0;
}

.site-logo {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-blue);
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: var(--spacing-lg);
}

.main-navigation a {
    font-weight: 500;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.main-navigation a:hover,
.main-navigation a.current {
    background-color: var(--primary-blue);
    color: var(--white);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-blue) 0%, #3b82f6 100%);
    color: var(--white);
    padding: var(--spacing-2xl) 0;
    text-align: center;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: var(--spacing-lg);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-xl);
    opacity: 0.9;
}

/* Search Form */
.search-form {
    display: flex;
    gap: var(--spacing-md);
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: var(--spacing-sm);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.search-select,
.search-input {
    flex: 1;
    padding: var(--spacing-md);
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-md);
    font-size: 1rem;
}

.search-button {
    background: var(--secondary-orange);
    color: var(--white);
    border: none;
    padding: var(--spacing-md) var(--spacing-xl);
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: background-color var(--transition-fast);
}

.search-button:hover {
    background: #d97706;
}

/* Feature Cards */
.features-section {
    padding: var(--spacing-2xl) 0;
}

.feature-card {
    background: var(--white);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: var(--secondary-orange);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--spacing-lg);
    font-size: 1.5rem;
    color: var(--white);
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

.feature-description {
    color: var(--neutral-medium);
    margin-bottom: 0;
}

/* Course Cards */
.courses-section {
    padding: var(--spacing-2xl) 0;
    background: var(--white);
}

.course-card {
    background: var(--neutral-light);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    border: 2px solid transparent;
    transition: all var(--transition-normal);
}

.course-card:hover {
    border-color: var(--primary-blue);
    transform: translateY(-2px);
}

.course-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: var(--primary-blue);
}

.course-explore {
    color: var(--secondary-orange);
    font-weight: 600;
    text-decoration: underline;
}

/* Community and Jobs Section */
.community-jobs {
    padding: var(--spacing-2xl) 0;
    background: var(--neutral-light);
}

.section-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-2xl);
}

.section-card {
    background: var(--white);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: var(--spacing-lg);
    color: var(--primary-blue);
}

.forum-item,
.job-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md) 0;
    border-bottom: 1px solid #e2e8f0;
}

.forum-item:last-child,
.job-item:last-child {
    border-bottom: none;
}

.item-title {
    font-weight: 500;
    color: var(--neutral-dark);
}

.item-meta {
    color: var(--neutral-medium);
    font-size: 0.875rem;
}

/* Footer */
.site-footer {
    background: var(--primary-blue);
    color: var(--white);
    padding: var(--spacing-2xl) 0 var(--spacing-lg);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-2xl);
    margin-bottom: var(--spacing-xl);
}

.footer-section h3 {
    margin-bottom: var(--spacing-lg);
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    display: block;
    margin-bottom: var(--spacing-sm);
}

.footer-section a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .section-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    .header-content {
        flex-direction: column;
        gap: var(--spacing-md);
    }
    
    .main-navigation ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    :root {
        --spacing-xl: 1.5rem;
        --spacing-2xl: 2rem;
    }
    
    .hero-content h1 {
        font-size: 1.75rem;
    }
    
    .feature-card,
    .course-card,
    .section-card {
        padding: var(--spacing-lg);
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }
.mb-xl { margin-bottom: var(--spacing-xl); }

.hidden { display: none; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

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

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: var(--white);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary-blue);
    color: var(--white);
    padding: 8px;
    text-decoration: none;
    border-radius: var(--radius-sm);
    z-index: 10000;
}

.skip-link:focus {
    top: 6px;
}

/* Focus styles for better accessibility */
button:focus,
input:focus,
select:focus,
textarea:focus,
a:focus {
    outline: 2px solid var(--secondary-orange);
    outline-offset: 2px;
}
