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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    overflow: auto;
}

/* Splash Screen */
#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    z-index: 9999;
}

.logo-container {
    text-align: center;
}

.logo {
    font-size: 4rem;
    font-weight: bold;
    color: white;
}

.animated-logo {
    animation: fadeIn 2s ease-in-out, pulse 2s infinite 2s;
}

.animated-logo span {
    display: inline-block;
    animation: bounce 1s ease-in-out 1s;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.5); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

/* Hide splash after animation */
#splash-screen.hide {
    display: none;
}

/* Login Page */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-form {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
}

.login-form h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #555;
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.btn-primary {
    width: 100%;
    padding: 0.75rem;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: #5a6fd8;
}

.login-form p {
    text-align: center;
    margin-top: 1rem;
}

.login-form a {
    color: #667eea;
    text-decoration: none;
}

.error {
    background: #ffebee;
    color: #c62828;
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
    text-align: center;
}

/* Register Page */
.register-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 2rem 0;
}

.register-form {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
}

.register-form h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.register-form p {
    text-align: center;
    margin-top: 1rem;
}

.register-form a {
    color: #667eea;
    text-decoration: none;
}

.errors {
    background: #ffebee;
    color: #c62828;
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
}

.errors p {
    margin: 0.5rem 0;
}

/* Dashboard */
.dashboard-container {
    min-height: 100vh;
    background: #f5f5f5;
}

.dashboard-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dashboard-header h1 {
    margin: 0;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info a {
    color: white;
    text-decoration: none;
    background: rgba(255,255,255,0.2);
    padding: 0.5rem 1rem;
    border-radius: 5px;
}

.dashboard-main {
    padding: 2rem;
}

.notification {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
}

.notification h3 {
    margin-top: 0;
    color: #856404;
}

.notification ul {
    margin: 1rem 0;
    padding-right: 1.5rem;
}

.notification li {
    margin: 0.5rem 0;
}

.dashboard-content h2 {
    color: #333;
    margin-bottom: 2rem;
}

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

.option-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

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

.option-card h3 {
    color: #667eea;
    margin-bottom: 1rem;
}

.option-card p {
    color: #666;
}

/* Complete Profile Page */
.profile-container {
    min-height: 100vh;
    background: #f5f5f5;
    padding: 2rem 0;
}

.profile-form {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    max-height: 80vh;
    overflow-y: auto;
}

.profile-form h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.form-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #fafafa;
}

.form-section h3 {
    color: #667eea;
    margin-bottom: 1rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 0.5rem;
}

.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    min-height: 80px;
    resize: vertical;
}

.form-group img {
    border-radius: 5px;
    margin-top: 10px;
}

.current-certs {
    margin-top: 10px;
    padding: 10px;
    background: #f0f0f0;
    border-radius: 5px;
}

.current-certs a {
    color: #667eea;
    text-decoration: none;
}

.current-certs a:hover {
    text-decoration: underline;
}

small {
    color: #666;
    font-size: 0.9rem;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 2rem;
    text-align: center;
    border: 1px solid #c3e6cb;
}

/* Teacher Dashboard */
.next-lesson-section {
    margin-bottom: 2rem;
}

.next-lesson-section h2 {
    color: #333;
    margin-bottom: 1rem;
}

.next-lesson-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.lesson-info h3 {
    margin: 0 0 1rem 0;
    font-size: 1.5rem;
}

.lesson-info p {
    margin: 0.5rem 0;
    opacity: 0.9;
}

.time-remaining {
    text-align: center;
}

.countdown {
    background: rgba(255,255,255,0.2);
    padding: 1rem;
    border-radius: 10px;
    min-width: 150px;
}

.time-label {
    display: block;
    font-size: 0.9rem;
    opacity: 0.8;
}

.time-value {
    display: block;
    font-size: 1.5rem;
    font-weight: bold;
}

.no-lessons {
    text-align: center;
    padding: 3rem;
    background: #f9f9f9;
    border-radius: 10px;
    margin-bottom: 2rem;
}

.upcoming-lessons-section h2 {
    color: #333;
    margin-bottom: 1rem;
}

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

.lesson-card {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-right: 4px solid #667eea;
}

.lesson-card h4 {
    color: #667eea;
    margin: 0 0 1rem 0;
}

.lesson-card p {
    margin: 0.5rem 0;
    color: #666;
    font-size: 0.9rem;
}

.quick-actions h2 {
    color: #333;
    margin-bottom: 1rem;
}

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

.action-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s, box-shadow 0.3s;
    display: block;
}

.action-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.action-card h3 {
    color: #667eea;
    margin: 0 0 0.5rem 0;
}

.action-card p {
    color: #666;
    margin: 0;
}

/* Calendar */
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.view-selector {
    display: flex;
    gap: 0.5rem;
}

.view-btn {
    padding: 0.5rem 1rem;
    background: #f5f5f5;
    color: #666;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s;
}

.view-btn.active, .view-btn:hover {
    background: #667eea;
    color: white;
}

.date-navigation {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-btn {
    padding: 0.5rem 1rem;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
}

.nav-btn:hover {
    background: #5a6fd8;
}

.current-period {
    font-weight: bold;
    color: #333;
}

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

/* Day View */
.day-view h2 {
    color: #333;
    margin-bottom: 1rem;
}

.day-lessons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.lesson-item {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-right: 4px solid #667eea;
}

.lesson-item.completed {
    border-right-color: #28a745;
    opacity: 0.7;
}

.lesson-item.cancelled {
    border-right-color: #dc3545;
    opacity: 0.5;
}

.lesson-time {
    font-weight: bold;
    color: #667eea;
    min-width: 120px;
}

.lesson-details h4 {
    margin: 0 0 0.5rem 0;
    color: #333;
}

.lesson-details p {
    margin: 0.25rem 0;
    color: #666;
    font-size: 0.9rem;
}

.lesson-actions {
    display: flex;
    gap: 0.5rem;
}

.lesson-actions button {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9rem;
}

.no-lessons-day {
    text-align: center;
    padding: 3rem;
    background: #f9f9f9;
    border-radius: 10px;
    color: #666;
}

/* Week View */
.week-view {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1rem;
}

.week-day {
    background: white;
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    min-height: 200px;
}

.week-day h3 {
    color: #667eea;
    margin: 0 0 1rem 0;
    text-align: center;
    font-size: 1rem;
}

.week-day .day-lessons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.week-day .lesson-item {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
}

.week-day .no-lessons {
    text-align: center;
    color: #999;
    font-size: 0.8rem;
    margin-top: 1rem;
}

/* Month View */
.month-view {
    background: white;
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.month-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
}

.month-header {
    padding: 1rem;
    text-align: center;
    font-weight: bold;
    color: #667eea;
    background: #f5f5f5;
    border-radius: 5px;
}

.month-day {
    min-height: 100px;
    padding: 0.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    position: relative;
}

.month-day.today {
    background: #e8f4fd;
    border-color: #667eea;
}

.month-day.empty {
    background: #f9f9f9;
}

.day-number {
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: #333;
}

.day-lessons {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
}

.lesson-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #667eea;
}

.lesson-dot.completed {
    background: #28a745;
}

.lesson-dot.cancelled {
    background: #dc3545;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 2rem;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    position: relative;
}

.close {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #666;
}

.close:hover {
    color: #333;
}

/* Settings Page */
.settings-section {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.settings-section h2 {
    color: #667eea;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-row .form-group {
    margin-bottom: 0;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.btn-secondary {
    padding: 0.75rem 2rem;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    display: inline-block;
    transition: background 0.3s;
}

.btn-secondary:hover {
    background: #5a6268;
}

.current-certificates {
    margin-top: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 5px;
}

.current-certificates h3 {
    margin: 0 0 1rem 0;
    color: #333;
}

.certificate-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    background: white;
    border-radius: 5px;
    margin-bottom: 0.5rem;
}

.certificate-item a {
    color: #667eea;
    text-decoration: none;
}

.certificate-item a:hover {
    text-decoration: underline;
}

.remove-cert {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.8rem;
}

.remove-cert:hover {
    background: #c82333;
}

.redirect-notice, .incomplete-profile-notice {
    background: #e8f4fd;
    border: 1px solid #667eea;
    color: #667eea;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    text-align: center;
}

.redirect-notice p, .incomplete-profile-notice p {
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
}

.incomplete-profile-notice {
    background: #fff3cd;
    border-color: #ffeaa7;
    color: #856404;
}

/* Wallet Page */
.balance-section {
    margin-bottom: 2rem;
}

.balance-section h2 {
    color: #333;
    margin-bottom: 1rem;
}

.balance-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.balance-amount .amount {
    font-size: 3rem;
    font-weight: bold;
    display: block;
}

.balance-amount .currency {
    font-size: 1.2rem;
    opacity: 0.9;
}

.withdrawal-section h2 {
    color: #333;
    margin-bottom: 1rem;
}

.withdrawal-form {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.transactions-section h2,
.earnings-section h2 {
    color: #333;
    margin-bottom: 1rem;
}

.transactions-table,
.earnings-table {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.transactions-table table,
.earnings-table table {
    width: 100%;
    border-collapse: collapse;
}

.transactions-table th,
.earnings-table th,
.transactions-table td,
.earnings-table td {
    padding: 1rem;
    text-align: right;
    border-bottom: 1px solid #eee;
}

.transactions-table th,
.earnings-table th {
    background: #f8f9fa;
    font-weight: bold;
    color: #333;
}

.status {
    padding: 0.25rem 0.5rem;
    border-radius: 5px;
    font-size: 0.9rem;
    font-weight: bold;
}

.status.pending {
    background: #fff3cd;
    color: #856404;
}

.status.completed {
    background: #d4edda;
    color: #155724;
}

.status.failed {
    background: #f8d7da;
    color: #721c24;
}

.no-transactions,
.no-earnings {
    text-align: center;
    padding: 3rem;
    background: #f9f9f9;
    border-radius: 10px;
    color: #666;
}

/* Requests Page */
.requests-tabs {
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    overflow: hidden;
}

.tab-buttons {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    position: relative;
}

.tab-btn.active {
    background: white;
    color: #667eea;
    font-weight: bold;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: #667eea;
}

.tab-content {
    display: none;
    padding: 2rem;
}

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

.requests-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.request-card {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    border-right: 4px solid #667eea;
}

.request-card.accepted {
    border-right-color: #28a745;
    background: #d4edda;
}

.request-card.rejected {
    border-right-color: #dc3545;
    background: #f8d7da;
}

.request-card.completed {
    border-right-color: #17a2b8;
    background: #d1ecf1;
}

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

.request-header h4 {
    margin: 0;
    color: #333;
}

.request-date {
    color: #666;
    font-size: 0.9rem;
}

.request-details p {
    margin: 0.5rem 0;
    color: #555;
}

.request-actions {
    margin-top: 1rem;
    display: flex;
    gap: 1rem;
}

.request-actions form {
    flex: 1;
}

.request-actions textarea {
    width: 100%;
    margin-bottom: 0.5rem;
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    resize: vertical;
}

.btn-accept {
    background: #28a745;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
}

.btn-reject {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
}

.request-status {
    margin-top: 1rem;
    text-align: center;
}

.status {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: bold;
}

.status.accepted {
    background: #d4edda;
    color: #155724;
}

.status.rejected {
    background: #f8d7da;
    color: #721c24;
}

.status.completed {
    background: #d1ecf1;
    color: #0c5460;
}

.no-requests {
    text-align: center;
    padding: 3rem;
    color: #666;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

/* Tablet and Mobile Styles */
@media (max-width: 1024px) {
    .dashboard-header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .dashboard-header h1 {
        font-size: 1.5rem;
    }

    .user-info {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
    }

    .user-info a {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
    }

    .dashboard-main {
        padding: 1rem;
    }

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

    .option-card {
        padding: 1.5rem;
    }

    .next-lesson-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .calendar-grid {
        grid-template-columns: repeat(7, 1fr);
        gap: 0.5rem;
    }

    .calendar-day {
        padding: 0.5rem;
        font-size: 0.9rem;
        min-height: 60px;
    }

    .form-row {
        flex-direction: column;
        gap: 1rem;
    }

    .settings-section {
        padding: 1.5rem;
    }

    .wallet-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .teachers-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 1rem;
    }

    .teacher-card {
        padding: 1rem;
    }

    .teacher-image {
        height: 150px;
    }

    .lesson-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .lesson-date, .lesson-time {
        min-width: auto;
        width: 100%;
    }

    /* Search form responsive */
    .search-form {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        margin-top: 1rem;
    }

    .search-form input {
        width: 100%;
        padding: 0.875rem;
        border: 1px solid #ddd;
        border-radius: 5px;
        font-size: 16px; /* Prevents zoom on iOS */
        box-sizing: border-box;
    }

    .search-form .btn-primary {
        width: 100%;
        padding: 0.875rem;
    }

    /* Desktop search form */
    @media (min-width: 769px) {
        .search-form {
            flex-direction: row;
            align-items: center;
        }

        .search-form input {
            width: auto;
            flex: 1;
        }

        .search-form .btn-primary {
            width: auto;
            margin-right: 0;
        }
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    body {
        font-size: 14px;
        line-height: 1.5;
    }

    /* Better readability on mobile */
    h1 {
        font-size: 1.5rem;
        line-height: 1.3;
    }

    h2 {
        font-size: 1.25rem;
        line-height: 1.4;
    }

    h3 {
        font-size: 1.1rem;
        line-height: 1.4;
    }

    p {
        line-height: 1.6;
    }

    .logo {
        font-size: 3rem;
    }

    .login-form, .register-form {
        padding: 1.5rem;
        margin: 1rem;
        max-width: none;
    }

    .login-form h2, .register-form h2 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .dashboard-header {
        padding: 0.75rem;
    }

    .dashboard-header h1 {
        font-size: 1.3rem;
    }

    .user-info {
        flex-direction: column;
        width: 100%;
    }

    .user-info a {
        width: 100%;
        text-align: center;
        padding: 0.6rem;
        box-sizing: border-box;
    }

    .dashboard-main {
        padding: 0.75rem;
    }

    .options-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .option-card {
        padding: 1.25rem;
    }

    .option-card h3 {
        font-size: 1.2rem;
    }

    .next-lesson-card {
        padding: 1.5rem;
        margin: 0.5rem 0;
    }

    .calendar-grid {
        grid-template-columns: repeat(7, 1fr);
        gap: 0.25rem;
    }

    .calendar-day {
        padding: 0.4rem;
        font-size: 0.8rem;
        min-height: 50px;
    }

    .calendar-day span {
        font-size: 0.9rem;
    }

    .profile-form {
        padding: 1rem;
        margin: 0.5rem;
        max-width: none;
    }

    .form-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .settings-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .wallet-content {
        grid-template-columns: 1fr;
    }

    .balance-card {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
        margin-bottom: 1rem;
    }

    .balance-amount {
        font-size: 2rem;
    }

    .teachers-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .teacher-card {
        padding: 1rem;
    }

    .teacher-image {
        height: 180px;
    }

    .teacher-profile {
        margin-bottom: 1.5rem;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }

    .profile-image {
        width: 120px;
        height: 120px;
        margin-bottom: 1rem;
        margin-right: 0;
    }

    .profile-details {
        padding: 1.5rem;
    }

    .reviews-section, .booking-section {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .lesson-card {
        padding: 1rem;
    }

    .transaction-item {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .transaction-icon {
        align-self: center;
    }

    .transaction-status {
        align-self: center;
    }

    .request-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .request-actions form {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .btn-accept, .btn-reject {
        width: 100%;
    }

    /* Tables responsive */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 600px;
    }

    /* Form improvements for mobile */
    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 0.75rem;
    }

    .btn-primary {
        width: 100%;
        padding: 0.875rem;
        font-size: 1rem;
    }

    .form-actions {
        flex-direction: column;
        gap: 1rem;
    }

    .form-actions .btn-secondary {
        width: 100%;
    }

    /* Modal improvements */
    .modal-content {
        margin: 1rem;
        max-width: none;
    }
}

/* Small Mobile Styles */
@media (max-width: 480px) {
    .login-form, .register-form {
        padding: 1rem;
        margin: 0.5rem;
    }

    .dashboard-main {
        padding: 0.5rem;
    }

    .option-card {
        padding: 1rem;
    }

    .next-lesson-card {
        padding: 1rem;
    }

    .calendar-day {
        padding: 0.3rem;
        min-height: 45px;
        font-size: 0.75rem;
    }

    .teacher-card {
        padding: 0.75rem;
    }

    .teacher-image {
        height: 150px;
    }

    .profile-form {
        padding: 0.75rem;
    }

    .settings-section {
        padding: 0.75rem;
    }

    .balance-card {
        padding: 1rem;
    }

    .balance-amount {
        font-size: 1.5rem;
    }

    .balance-icon {
        font-size: 3rem;
    }
}

/* Touch-friendly buttons and links */
@media (hover: none) and (pointer: coarse) {
    .btn-primary,
    .btn-secondary,
    .option-card,
    .teacher-card,
    .user-info a {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .option-card:hover {
        transform: none;
    }

    .teacher-card:hover {
        transform: none;
    }

    /* Improve touch targets */
    .btn-primary,
    .btn-secondary {
        min-height: 48px;
        padding: 12px 16px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        min-height: 44px;
        padding: 12px 16px;
    }

    .user-info a {
        min-height: 44px;
        padding: 12px 16px;
    }

    /* Better spacing for touch */
    .form-group {
        margin-bottom: 1.5rem;
    }

    .dashboard-main {
        padding: 1rem;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo {
        font-size: 3.5rem;
    }

    .balance-icon {
        font-size: 3.5rem;
    }
}

/* Print styles */
@media print {
    .dashboard-header,
    .user-info,
    .btn-primary,
    .btn-secondary,
    .form-actions {
        display: none !important;
    }

    .dashboard-main {
        padding: 0;
    }

    body {
        background: white !important;
    }

    .dashboard-container {
        background: white !important;
    }
}