/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* Navigation */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2563eb;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: #4b5563;
    font-weight: 500;
}

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

.nav-links form {
    margin: 0;
    padding: 0;
}

.nav-links .btn-link {
    background: none;
    border: none;
    padding: 0;
    color: #4b5563;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
}

.nav-links .btn-link:hover {
    color: #2563eb;
}

/* Buttons */
.btn {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
    display: inline-block;
}

.btn-primary {
    background-color: #2563eb;
    color: white !important;
    border: none;
}

.btn-primary:hover {
    background-color: #1d4ed8;
    color: white !important;
}

/* Hero section */
.hero {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
    padding: 4rem 5%;
    text-align: center;
}

.hero-text h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero-text p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
}

/* Features section */
.features {
    padding: 4rem 5%;
    background-color: #f8fafc;
}

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

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.feature-card h3 {
    color: #2563eb;
    margin-bottom: 1rem;
}

/* Testimonials section */
.testimonials {
    padding: 4rem 5%;
}

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

.testimonial-card {
    background: #f8fafc;
    padding: 2rem;
    border-radius: 0.5rem;
    border-left: 4px solid #2563eb;
}

.testimonial-card cite {
    display: block;
    margin-top: 1rem;
    color: #6b7280;
}

/* CTA section */
.cta {
    padding: 4rem 5%;
    text-align: center;
    background-color: #f8fafc;
}

.cta h2 {
    margin-bottom: 1rem;
}

.cta p {
    margin-bottom: 2rem;
    color: #6b7280;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    background-color: #1e293b;
    color: white;
}

/* Responsive design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hero-text h1 {
        font-size: 2rem;
    }
    
    .feature-grid,
    .testimonial-grid {
        grid-template-columns: 1fr;
    }
}

/* Messages */
.messages {
    padding: 1rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.alert {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
}

.alert-success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.alert-warning {
    background-color: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

.alert-info {
    background-color: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

/* Authentication Forms */
.auth-form {
    max-width: 400px;
    margin: 2rem auto;
    padding: 2rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.auth-form h1 {
    color: #2563eb;
    margin-bottom: 0.5rem;
    font-size: 1.75rem;
}

.auth-form .text-muted {
    color: #6b7280;
    margin-bottom: 1.5rem;
}

.auth-form .form-group {
    margin-bottom: 1rem;
}

.auth-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: #4b5563;
    font-weight: 500;
}

.auth-form input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    margin-bottom: 0.5rem;
}

.auth-form input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.auth-form .btn {
    width: 100%;
    padding: 0.75rem;
    font-size: 1rem;
}

.auth-form .border-top {
    border-color: #e5e7eb;
}

.auth-form a {
    color: #2563eb;
    text-decoration: none;
}

.auth-form a:hover {
    text-decoration: underline;
}

/* About Page */
.about-section {
    padding: 4rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.about-section h1 {
    color: #2563eb;
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

.about-content {
    display: grid;
    gap: 3rem;
}

.about-section h2 {
    color: #1e40af;
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.about-section p {
    color: #4b5563;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

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

.value-card {
    background: white;
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

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

.value-card h3 {
    color: #2563eb;
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.mission, .story, .team {
    background: white;
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    .about-section h1 {
        font-size: 2rem;
    }
    
    .values-grid {
        grid-template-columns: 1fr;
    }
    
    .mission, .story, .team {
        padding: 1.5rem;
    }
}

/* Profile Page Styles */
.profile-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.profile-image {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #2563eb;
}

.profile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info h1 {
    color: #2563eb;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.profile-form {
    margin-top: 1.5rem;
}

.profile-form h2 {
    color: #1e40af;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.form-fields p {
    margin-bottom: 1rem;
}

.form-fields label {
    display: block;
    margin-bottom: 0.5rem;
    color: #4b5563;
    font-weight: 500;
}

.form-fields input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
}

.form-fields input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.profile-form .btn-primary {
    width: 100%;
    margin-top: 1.5rem;
}

@media (max-width: 768px) {
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    
    .profile-image {
        margin: 0 auto;
    }
}

.code-entry {
    text-align: center;
    margin: 2rem 0;
    padding: 2rem;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.code-input-container {
    max-width: 400px;
    margin: 1rem auto;
}

.code-input-container label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.code-input {
    width: 200px;
    padding: 0.75rem;
    font-size: 1.2rem;
    text-align: center;
    letter-spacing: 0.5rem;
    border: 2px solid #ddd;
    border-radius: 4px;
    transition: border-color 0.3s ease;
}

.code-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Teacher Dashboard Styles */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.dashboard-header h1 {
    color: #2563eb;
    font-size: 1.75rem;
    margin: 0;
}

.dashboard-actions {
    display: flex;
    gap: 1rem;
}

.activities-section {
    margin-top: 2rem;
}

.activities-section h2 {
    color: #1e40af;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.activities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.activity-card {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 1.5rem;
    transition: transform 0.2s ease;
}

.activity-card:hover {
    transform: translateY(-2px);
}

.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.activity-header h3 {
    color: #2563eb;
    font-size: 1.25rem;
    margin: 0;
}

.activity-type {
    background: #e5e7eb;
    color: #4b5563;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
}

.activity-description {
    color: #6b7280;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.activity-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    color: #6b7280;
    font-size: 0.875rem;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.activity-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-secondary {
    background-color: #4b5563;
    color: white;
}

.btn-outline {
    background: none;
    border: 1px solid #e5e7eb;
    color: #4b5563;
}

.btn-outline:hover {
    background-color: #f3f4f6;
}

.no-activities {
    text-align: center;
    padding: 3rem;
    background: #f8fafc;
    border-radius: 0.5rem;
}

.no-activities p {
    color: #6b7280;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .dashboard-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .activities-grid {
        grid-template-columns: 1fr;
    }
    
    .activity-actions {
        flex-direction: column;
    }
    
    .activity-actions .btn {
        width: 100%;
        text-align: center;
    }
}

.activity-title {
    color: #2563eb;
    text-decoration: none;
    transition: color 0.2s ease;
}

.activity-title:hover {
    color: #1d4ed8;
    text-decoration: underline;
}
