/* ===== COMPREHENSIVE MOBILE RESPONSIVE DESIGN ===== */
/* RTB Tutors - Mobile-First Responsive Design System */

/* ===== GLOBAL MOBILE OPTIMIZATIONS ===== */

/* Ensure proper box-sizing and smooth scrolling */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== RESPONSIVE TYPOGRAPHY ===== */

/* Base typography scales with viewport */
h1, .h1 {
    font-size: clamp(1.8rem, 4vw, 3.5rem);
    line-height: 1.2;
    margin-bottom: 1rem;
}

h2, .h2 {
    font-size: clamp(1.5rem, 3.5vw, 2.8rem);
    line-height: 1.25;
    margin-bottom: 0.875rem;
}

h3, .h3 {
    font-size: clamp(1.3rem, 3vw, 2.2rem);
    line-height: 1.3;
    margin-bottom: 0.75rem;
}

h4, .h4 {
    font-size: clamp(1.1rem, 2.5vw, 1.8rem);
    line-height: 1.35;
    margin-bottom: 0.625rem;
}

h5, .h5 {
    font-size: clamp(1rem, 2vw, 1.4rem);
    line-height: 1.4;
    margin-bottom: 0.5rem;
}

h6, .h6 {
    font-size: clamp(0.9rem, 1.5vw, 1.2rem);
    line-height: 1.45;
    margin-bottom: 0.5rem;
}

p {
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* Lead text */
.lead {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
    line-height: 1.7;
    font-weight: 300;
}

/* Small text */
small, .small {
    font-size: clamp(0.75rem, 1vw, 0.875rem);
}

/* ===== HERO SECTION MOBILE RESPONSIVE ===== */

.hero-section {
    min-height: 80vh !important;
    padding: 2rem 0 !important;
}

@media (max-width: 991px) {
    .hero-section {
        min-height: 70vh !important;
        padding: 1.5rem 0 !important;
    }
}

@media (max-width: 767px) {
    .hero-section {
        min-height: 60vh !important;
        padding: 1rem 0 !important;
    }
    
    .hero-content {
        padding: 1rem !important;
        text-align: center !important;
    }
    
    .hero-title {
        font-size: clamp(2.5rem, 8vw, 4rem) !important;
        line-height: 1.1 !important;
        margin-bottom: 2rem !important;
    }
    
    .hero-subtitle {
        font-size: clamp(1rem, 3vw, 1.2rem) !important;
        margin: 1rem auto 2rem !important;
        max-width: 90% !important;
    }
    
    .hero-badge {
        padding: 0.8rem 2rem !important;
        font-size: 0.9rem !important;
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
    }
}

@media (max-width: 575px) {
    .hero-title {
        font-size: clamp(2rem, 7vw, 3rem) !important;
        line-height: 1.1 !important;
        margin-bottom: 1.5rem !important;
    }
    
    .hero-subtitle {
        font-size: clamp(0.9rem, 2.5vw, 1rem) !important;
        margin: 1rem auto 1.5rem !important;
    }
    
    .hero-badge {
        padding: 0.6rem 1.5rem !important;
        font-size: 0.8rem !important;
        margin-top: 1.5rem !important;
        margin-bottom: 1.5rem !important;
    }
}

/* ===== SEARCH CONTAINER RESPONSIVE (FULL WIDTH ON DESKTOP) ===== */

.search-container {
    margin: 2rem auto !important;
    padding: 3rem !important;
    border-radius: 25px !important;
    max-width: none !important;
    width: 100% !important;
}

@media (max-width: 1199px) {
    .search-container {
        margin: 3rem auto !important;
        padding: 2.5rem !important;
        width: 95% !important;
    }
}

@media (max-width: 991px) {
    .search-container {
        margin: 2rem auto !important;
        padding: 2rem !important;
        width: 90% !important;
    }
}

@media (max-width: 767px) {
    .search-container {
        margin: 1.5rem auto !important;
        padding: 1.5rem !important;
        border-radius: 15px !important;
        width: 95% !important;
    }
    
    .search-tabs {
        flex-direction: column !important;
        gap: 0.5rem !important;
        margin-bottom: 1.5rem !important;
        padding: 0.6rem !important;
    }
    
    .search-tab {
        padding: 0.8rem 1rem !important;
        font-size: 0.9rem !important;
        border-radius: 10px !important;
        justify-content: center !important;
    }
    
    .search-input-group {
        flex-direction: column !important;
        gap: 1rem !important;
        align-items: stretch !important;
    }
    
    .search-input {
        min-width: auto !important;
        width: 100% !important;
    }
    
    .search-input.main-search,
    .search-input.location-search {
        min-width: auto !important;
        flex: none !important;
    }
    
    .search-input input,
    .search-input select {
        padding: 1.2rem 1.2rem 1.2rem 3rem !important;
        font-size: 1rem !important;
        border-radius: 12px !important;
    }
    
    .search-btn.primary-search-btn {
        padding: 1.2rem 2rem !important;
        font-size: 1rem !important;
        border-radius: 12px !important;
        min-width: auto !important;
        width: 100% !important;
    }
}

@media (max-width: 575px) {
    .search-container {
        margin: 1rem auto !important;
        padding: 1rem !important;
        border-radius: 12px !important;
        width: 98% !important;
    }
    
    .search-tab {
        padding: 0.7rem 0.8rem !important;
        font-size: 0.85rem !important;
        gap: 0.5rem !important;
    }
    
    .search-input input,
    .search-input select {
        padding: 1rem 1rem 1rem 2.5rem !important;
        font-size: 0.9rem !important;
    }
    
    .search-btn.primary-search-btn {
        padding: 1rem 1.5rem !important;
        font-size: 0.9rem !important;
    }
}

/* ===== SEARCH INPUT GROUP RESPONSIVE ===== */

/* Desktop (1200px+) - Full width container with optimized spacing */
@media (min-width: 1200px) {
    .search-container {
        padding: 3.5rem 4rem !important;
        margin: 4rem auto !important;
        width: 100% !important;
        max-width: none !important;
    }
    
    .search-input-group {
        max-width: none !important;
        width: 100% !important;
        gap: 2rem !important;
    }
    
    .search-input.main-search {
        min-width: 400px !important;
        flex: 2 !important;
    }
    
    .search-input.location-search {
        min-width: 250px !important;
        flex: 1 !important;
    }
    
    .search-btn.primary-search-btn {
        min-width: 200px !important;
        padding: 1.5rem 3rem !important;
        font-size: 1.1rem !important;
    }
}

/* Large Tablets and Small Desktops (992px - 1199px) */
@media (min-width: 992px) and (max-width: 1199px) {
    .search-container {
        padding: 3rem !important;
        margin: 3.5rem auto !important;
    }
    
    .search-input-group {
        gap: 1.5rem !important;
    }
    
    .search-input.main-search {
        min-width: 350px !important;
    }
    
    .search-input.location-search {
        min-width: 200px !important;
    }
    
    .search-btn.primary-search-btn {
        min-width: 180px !important;
        padding: 1.5rem 2.5rem !important;
    }
}

/* Tablets (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .search-container {
        padding: 2.5rem !important;
        margin: 3rem auto !important;
    }
    
    .search-input-group {
        gap: 1.25rem !important;
    }
    
    .search-input.main-search {
        min-width: 300px !important;
    }
    
    .search-input.location-search {
        min-width: 180px !important;
    }
    
    .search-btn.primary-search-btn {
        min-width: 160px !important;
        padding: 1.3rem 2rem !important;
    }
}

/* ===== HERO STATS MOBILE RESPONSIVE ===== */

.hero-stats {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
    gap: 1.5rem !important;
    margin-top: 3rem !important;
    padding: 0 1rem !important;
}

@media (max-width: 767px) {
    .hero-stats {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 1rem !important;
        margin-top: 2rem !important;
        padding: 0 0.5rem !important;
    }
    
    .stat-card {
        padding: 1.5rem 1rem !important;
        border-radius: 15px !important;
    }
    
    .stat-number {
        font-size: 2.2rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .stat-label {
        font-size: 0.8rem !important;
    }
}

@media (max-width: 575px) {
    .hero-stats {
        grid-template-columns: 1fr !important;
        gap: 0.8rem !important;
        margin-top: 1.5rem !important;
    }
    
    .stat-card {
        padding: 1.2rem 0.8rem !important;
        border-radius: 12px !important;
    }
    
    .stat-number {
        font-size: 1.8rem !important;
        margin-bottom: 0.4rem !important;
    }
    
    .stat-label {
        font-size: 0.75rem !important;
    }
}

/* ===== CTA BUTTONS MOBILE RESPONSIVE ===== */

.cta-buttons {
    flex-direction: column !important;
    gap: 1rem !important;
    margin-top: 2rem !important;
    align-items: center !important;
}

@media (max-width: 767px) {
    .cta-buttons {
        gap: 0.8rem !important;
        margin-top: 1.5rem !important;
    }
    
    .cta-buttons .btn,
    .cta-buttons .cta-btn {
        width: 100% !important;
        max-width: 280px !important;
        padding: 1rem 2rem !important;
        font-size: 0.9rem !important;
        border-radius: 12px !important;
    }
}

@media (max-width: 575px) {
    .cta-buttons .btn,
    .cta-buttons .cta-btn {
        max-width: 240px !important;
        padding: 0.9rem 1.5rem !important;
        font-size: 0.85rem !important;
    }
}

/* ===== COURSES GRID MOBILE RESPONSIVE ===== */

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

@media (max-width: 991px) {
    .courses-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
        gap: 1.5rem !important;
    }
}

@media (max-width: 767px) {
    .courses-grid {
        grid-template-columns: 1fr !important;
        gap: 1.2rem !important;
        margin: 1.5rem 0 !important;
    }
    
    .course-card {
        margin-bottom: 0 !important;
        border-radius: 15px !important;
    }
    
    .course-content {
        padding: 1.2rem !important;
    }
    
    .course-title {
        font-size: 1.1rem !important;
        line-height: 1.3 !important;
        margin-bottom: 0.8rem !important;
    }
    
    .course-description {
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
        margin-bottom: 1rem !important;
    }
    
    .course-meta {
        flex-wrap: wrap !important;
        gap: 0.5rem !important;
        margin-bottom: 1rem !important;
    }
    
    .meta-item {
        font-size: 0.8rem !important;
        padding: 0.3rem 0.6rem !important;
        border-radius: 8px !important;
    }
}

@media (max-width: 575px) {
    .course-card {
        border-radius: 12px !important;
    }
    
    .course-content {
        padding: 1rem !important;
    }
    
    .course-title {
        font-size: 1rem !important;
        margin-bottom: 0.6rem !important;
    }
    
    .course-description {
        font-size: 0.85rem !important;
        margin-bottom: 0.8rem !important;
    }
    
    .meta-item {
        font-size: 0.75rem !important;
        padding: 0.25rem 0.5rem !important;
    }
}

/* ===== HOW IT WORKS SECTION MOBILE RESPONSIVE ===== */

.process-timeline {
    display: flex !important;
    flex-direction: column !important;
    gap: 2rem !important;
    margin: 2rem 0 !important;
}

@media (max-width: 767px) {
    .process-timeline {
        gap: 1.5rem !important;
        margin: 1.5rem 0 !important;
    }
    
    .process-step {
        text-align: center !important;
        padding: 1.5rem !important;
        border-radius: 15px !important;
        background: rgba(255, 255, 255, 0.05) !important;
    }
    
    .step-number {
        width: 60px !important;
        height: 60px !important;
        font-size: 1.5rem !important;
        margin: 0 auto 1rem !important;
    }
    
    .step-icon {
        width: 80px !important;
        height: 80px !important;
        font-size: 2rem !important;
        margin: 0 auto 1rem !important;
    }
    
    .step-title {
        font-size: 1.3rem !important;
        margin-bottom: 0.8rem !important;
    }
    
    .step-description {
        font-size: 0.9rem !important;
        line-height: 1.5 !important;
        margin-bottom: 1rem !important;
        max-width: none !important;
    }
    
    .step-features {
        flex-direction: column !important;
        gap: 0.5rem !important;
        align-items: center !important;
    }
    
    .feature-item {
        font-size: 0.85rem !important;
        padding: 0.4rem 0.8rem !important;
        border-radius: 8px !important;
        background: rgba(255, 255, 255, 0.1) !important;
    }
}

@media (max-width: 575px) {
    .process-step {
        padding: 1.2rem !important;
        border-radius: 12px !important;
    }
    
    .step-number {
        width: 50px !important;
        height: 50px !important;
        font-size: 1.3rem !important;
    }
    
    .step-icon {
        width: 70px !important;
        height: 70px !important;
        font-size: 1.8rem !important;
    }
    
    .step-title {
        font-size: 1.1rem !important;
        margin-bottom: 0.6rem !important;
    }
    
    .step-description {
        font-size: 0.85rem !important;
        margin-bottom: 0.8rem !important;
    }
    
    .feature-item {
        font-size: 0.8rem !important;
        padding: 0.3rem 0.6rem !important;
    }
}

/* ===== TESTIMONIALS MOBILE RESPONSIVE ===== */

.testimonials-container {
    margin: 2rem 0 !important;
}

@media (max-width: 767px) {
    .testimonials-container {
        margin: 1.5rem 0 !important;
    }
    
    .testimonial-card {
        padding: 1.5rem !important;
        border-radius: 15px !important;
        margin: 0 0.5rem !important;
    }
    
    .testimonial-text {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
        margin-bottom: 1.5rem !important;
    }
    
    .testimonial-author {
        flex-direction: column !important;
        text-align: center !important;
        gap: 1rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    .author-avatar {
        width: 80px !important;
        height: 80px !important;
        margin: 0 auto !important;
    }
    
    .author-name {
        font-size: 1.1rem !important;
        margin-bottom: 0.3rem !important;
    }
    
    .author-title {
        font-size: 0.9rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .testimonial-achievements {
        flex-direction: column !important;
        gap: 0.8rem !important;
        align-items: center !important;
    }
    
    .achievement-item {
        flex-direction: row !important;
        gap: 0.8rem !important;
        padding: 0.8rem 1rem !important;
        border-radius: 10px !important;
        width: 100% !important;
        max-width: 200px !important;
    }
    
    .achievement-icon {
        width: 40px !important;
        height: 40px !important;
        font-size: 1.2rem !important;
    }
    
    .achievement-value {
        font-size: 1rem !important;
        margin-bottom: 0.2rem !important;
    }
    
    .achievement-label {
        font-size: 0.8rem !important;
    }
}

@media (max-width: 575px) {
    .testimonial-card {
        padding: 1.2rem !important;
        border-radius: 12px !important;
        margin: 0 0.3rem !important;
    }
    
    .testimonial-text {
        font-size: 0.9rem !important;
        margin-bottom: 1.2rem !important;
    }
    
    .author-avatar {
        width: 70px !important;
        height: 70px !important;
    }
    
    .author-name {
        font-size: 1rem !important;
    }
    
    .author-title {
        font-size: 0.85rem !important;
    }
    
    .achievement-item {
        padding: 0.6rem 0.8rem !important;
        max-width: 180px !important;
    }
    
    .achievement-icon {
        width: 35px !important;
        height: 35px !important;
        font-size: 1rem !important;
    }
    
    .achievement-value {
        font-size: 0.9rem !important;
    }
    
    .achievement-label {
        font-size: 0.75rem !important;
    }
}

/* ===== SECTION HEADERS MOBILE RESPONSIVE ===== */

.section-header {
    margin-bottom: 3rem !important;
}

@media (max-width: 767px) {
    .section-header {
        margin-bottom: 2rem !important;
        padding: 0 1rem !important;
    }
    
    .section-badge {
        font-size: 0.8rem !important;
        padding: 0.5rem 1rem !important;
        margin-bottom: 1rem !important;
    }
    
    .section-title {
        font-size: clamp(1.5rem, 5vw, 2.5rem) !important;
        line-height: 1.2 !important;
        margin-bottom: 1rem !important;
    }
    
    .section-subtitle {
        font-size: 0.9rem !important;
        line-height: 1.5 !important;
        max-width: 90% !important;
        margin: 0 auto !important;
    }
}

@media (max-width: 575px) {
    .section-header {
        margin-bottom: 1.5rem !important;
        padding: 0 0.5rem !important;
    }
    
    .section-badge {
        font-size: 0.75rem !important;
        padding: 0.4rem 0.8rem !important;
    }
    
    .section-title {
        font-size: clamp(1.3rem, 4vw, 2rem) !important;
        margin-bottom: 0.8rem !important;
    }
    
    .section-subtitle {
        font-size: 0.85rem !important;
        max-width: 95% !important;
    }
}

/* ===== RESPONSIVE CONTAINERS AND LAYOUT ===== */

.container {
    width: 100%;
    padding-left: 15px;
    padding-right: 15px;
    margin-left: auto;
    margin-right: auto;
}

/* Mobile First Container Sizes */
@media (min-width: 576px) {
    .container {
        max-width: 540px;
        padding-left: 20px;
        padding-right: 20px;
    }
}

@media (min-width: 768px) {
    .container {
        max-width: 720px;
        padding-left: 25px;
        padding-right: 25px;
    }
}

@media (min-width: 992px) {
    .container {
        max-width: 960px;
        padding-left: 30px;
        padding-right: 30px;
    }
}

@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
}

@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

/* ===== RESPONSIVE GRID SYSTEM ===== */

.row {
    display: flex;
    flex-wrap: wrap;
    margin-left: -15px;
    margin-right: -15px;
}

.col {
    flex: 1;
    padding-left: 15px;
    padding-right: 15px;
}

/* Mobile-first columns */
.col-12 { width: 100%; }
.col-11 { width: 91.66666667%; }
.col-10 { width: 83.33333333%; }
.col-9 { width: 75%; }
.col-8 { width: 66.66666667%; }
.col-7 { width: 58.33333333%; }
.col-6 { width: 50%; }
.col-5 { width: 41.66666667%; }
.col-4 { width: 33.33333333%; }
.col-3 { width: 25%; }
.col-2 { width: 16.66666667%; }
.col-1 { width: 8.33333333%; }

/* Responsive columns for different breakpoints */
@media (min-width: 576px) {
    .col-sm-12 { width: 100%; }
    .col-sm-11 { width: 91.66666667%; }
    .col-sm-10 { width: 83.33333333%; }
    .col-sm-9 { width: 75%; }
    .col-sm-8 { width: 66.66666667%; }
    .col-sm-7 { width: 58.33333333%; }
    .col-sm-6 { width: 50%; }
    .col-sm-5 { width: 41.66666667%; }
    .col-sm-4 { width: 33.33333333%; }
    .col-sm-3 { width: 25%; }
    .col-sm-2 { width: 16.66666667%; }
    .col-sm-1 { width: 8.33333333%; }
}

@media (min-width: 768px) {
    .col-md-12 { width: 100%; }
    .col-md-11 { width: 91.66666667%; }
    .col-md-10 { width: 83.33333333%; }
    .col-md-9 { width: 75%; }
    .col-md-8 { width: 66.66666667%; }
    .col-md-7 { width: 58.33333333%; }
    .col-md-6 { width: 50%; }
    .col-md-5 { width: 41.66666667%; }
    .col-md-4 { width: 33.33333333%; }
    .col-md-3 { width: 25%; }
    .col-md-2 { width: 16.66666667%; }
    .col-md-1 { width: 8.33333333%; }
}

@media (min-width: 992px) {
    .col-lg-12 { width: 100%; }
    .col-lg-11 { width: 91.66666667%; }
    .col-lg-10 { width: 83.33333333%; }
    .col-lg-9 { width: 75%; }
    .col-lg-8 { width: 66.66666667%; }
    .col-lg-7 { width: 58.33333333%; }
    .col-lg-6 { width: 50%; }
    .col-lg-5 { width: 41.66666667%; }
    .col-lg-4 { width: 33.33333333%; }
    .col-lg-3 { width: 25%; }
    .col-lg-2 { width: 16.66666667%; }
    .col-lg-1 { width: 8.33333333%; }
}

/* ===== RESPONSIVE BUTTONS AND FORM ELEMENTS ===== */

/* Touch-friendly buttons (minimum 44px) */
.btn,
button,
input[type="submit"],
input[type="button"],
.button {
    min-height: 44px;
    min-width: 44px;
    padding: 12px 24px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Button responsive sizes */
@media (max-width: 575px) {
    .btn,
    button,
    input[type="submit"],
    input[type="button"] {
        padding: 10px 20px;
        font-size: 14px;
        min-height: 40px;
        min-width: 40px;
    }
    
    .btn-lg {
        padding: 12px 24px;
        font-size: 16px;
        min-height: 44px;
    }
    
    .btn-sm {
        padding: 8px 16px;
        font-size: 12px;
        min-height: 36px;
        min-width: 36px;
    }
}

/* Form elements */
input,
textarea,
select {
    width: 100%;
    min-height: 44px;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Prevent zoom on iOS when input is focused */
@media screen and (max-width: 767px) {
    input,
    textarea,
    select {
        font-size: 16px;
    }
}

/* ===== RESPONSIVE IMAGES AND MEDIA ===== */

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Responsive video containers */
.video-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    overflow: hidden;
}

.video-container iframe,
.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* ===== RESPONSIVE NAVIGATION ===== */

/* Hide desktop navigation on mobile */
@media (max-width: 991px) {
    .desktop-nav,
    .main-nav,
    .header-nav {
        display: none !important;
    }
    
    .mobile-menu-toggle,
    .hamburger-menu {
        display: flex !important;
    }
}

/* ===== RESPONSIVE CARDS AND COMPONENTS ===== */

.card {
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

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

.card-body {
    padding: 20px;
}

@media (max-width: 767px) {
    .card-body {
        padding: 15px;
    }
}

@media (max-width: 575px) {
    .card-body {
        padding: 12px;
    }
}

/* ===== RESPONSIVE SECTIONS AND SPACING ===== */

section {
    padding: 60px 0;
}

@media (max-width: 991px) {
    section {
        padding: 40px 0;
    }
}

@media (max-width: 767px) {
    section {
        padding: 30px 0;
    }
}

@media (max-width: 575px) {
    section {
        padding: 20px 0;
    }
}

/* ===== RESPONSIVE UTILITIES ===== */

/* Text alignment */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

@media (max-width: 767px) {
    .text-md-center { text-align: center; }
    .text-md-left { text-align: left; }
    .text-md-right { text-align: right; }
}

@media (max-width: 575px) {
    .text-sm-center { text-align: center; }
    .text-sm-left { text-align: left; }
    .text-sm-right { text-align: right; }
}

/* Display utilities */
.d-none { display: none; }
.d-block { display: block; }
.d-inline { display: inline; }
.d-inline-block { display: inline-block; }
.d-flex { display: flex; }

@media (min-width: 576px) {
    .d-sm-none { display: none; }
    .d-sm-block { display: block; }
    .d-sm-inline { display: inline; }
    .d-sm-inline-block { display: inline-block; }
    .d-sm-flex { display: flex; }
}

@media (min-width: 768px) {
    .d-md-none { display: none; }
    .d-md-block { display: block; }
    .d-md-inline { display: inline; }
    .d-md-inline-block { display: inline-block; }
    .d-md-flex { display: flex; }
}

@media (min-width: 992px) {
    .d-lg-none { display: none; }
    .d-lg-block { display: block; }
    .d-lg-inline { display: inline; }
    .d-lg-inline-block { display: inline-block; }
    .d-lg-flex { display: flex; }
}

/* Responsive spacing */
.m-0 { margin: 0; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.ml-0 { margin-left: 0; }
.mr-0 { margin-right: 0; }

.p-0 { padding: 0; }
.pt-0 { padding-top: 0; }
.pb-0 { padding-bottom: 0; }
.pl-0 { padding-left: 0; }
.pr-0 { padding-right: 0; }

/* Scale spacing for mobile */
@media (max-width: 767px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .row {
        margin-left: -10px;
        margin-right: -10px;
    }
    
    .col,
    [class*="col-"] {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* ===== RESPONSIVE HERO SECTIONS ===== */

.hero-section,
.banner-section {
    min-height: 60vh;
    display: flex;
    align-items: center;
    padding: 80px 0;
}

@media (max-width: 991px) {
    .hero-section,
    .banner-section {
        min-height: 50vh;
        padding: 60px 0;
    }
}

@media (max-width: 767px) {
    .hero-section,
    .banner-section {
        min-height: 40vh;
        padding: 40px 0;
        text-align: center;
    }
}

@media (max-width: 575px) {
    .hero-section,
    .banner-section {
        min-height: 35vh;
        padding: 30px 0;
    }
}

/* ===== RESPONSIVE TABLES ===== */

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

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

@media (max-width: 767px) {
    th,
    td {
        padding: 8px;
        font-size: 14px;
    }
    
    /* Stack table cells on very small screens */
    .table-stack thead {
        display: none;
    }
    
    .table-stack tr {
        display: block;
        border: 1px solid #e9ecef;
        margin-bottom: 10px;
        border-radius: 8px;
        padding: 10px;
    }
    
    .table-stack td {
        display: block;
        text-align: right;
        border-bottom: none;
        padding: 5px 0;
    }
    
    .table-stack td:before {
        content: attr(data-label) ": ";
        float: left;
        font-weight: bold;
    }
}

/* ===== RESPONSIVE MODALS AND OVERLAYS ===== */

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    padding: 20px;
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

@media (max-width: 575px) {
    .modal {
        padding: 10px;
    }
    
    .modal-content {
        max-height: 95vh;
        border-radius: 8px;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */

/* Reduce animations on mobile for better performance */
@media (max-width: 767px) {
    *,
    *::before,
    *::after {
        animation-duration: 0.3s !important;
        transition-duration: 0.3s !important;
    }
}

/* Optimize touch scrolling */
.scroll-container {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

/* ===== ACCESSIBILITY IMPROVEMENTS ===== */

/* Focus styles */
*:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Skip link for screen readers */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #667eea;
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1100;
}

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

/* High contrast mode support */
@media (prefers-contrast: high) {
    .btn {
        border: 2px solid currentColor;
    }
    
    .card {
        border: 1px solid currentColor;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ===== PRINT STYLES ===== */

@media print {
    *,
    *::before,
    *::after {
        background: transparent !important;
        color: black !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
    
    .no-print {
        display: none !important;
    }
    
    a:not(.btn) {
        text-decoration: underline;
    }
    
    a[href]:after {
        content: " (" attr(href) ")";
    }
    
    img {
        max-width: 100% !important;
    }
    
    h1, h2, h3 {
        page-break-after: avoid;
    }
}

/* ===== END OF MOBILE RESPONSIVE CSS ===== */ 
/* ===== END OF MOBILE RESPONSIVE CSS ===== */ 