/* ============================================================================
   EKAFA PIUMS - Mobile Responsive Enhancements
   Comprehensive mobile-first responsive design system
   ============================================================================ */

/* ==================
   Mobile Navigation - Hamburger Menu & Sidebar Toggle
   ================== */

/* Collapsed navbar on mobile */
@media (max-width: 767px) {
    /* Bootstrap Navbar Toggler (for guest users) */
    .navbar-toggler {
        border: 2px solid rgba(255, 255, 255, 0.3) !important;
        padding: 8px 12px !important;
        background: rgba(255, 255, 255, 0.1) !important;
        border-radius: 8px !important;
        transition: all 0.3s ease;
        margin-right: 12px !important;
    }

    .navbar-toggler:hover {
        background: rgba(255, 255, 255, 0.2) !important;
        border-color: rgba(255, 255, 255, 0.5) !important;
    }

    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(0, 179, 119, 0.5) !important;
        outline: none !important;
    }

    .navbar-toggler:not(.collapsed) {
        background: rgba(0, 179, 119, 0.3) !important;
        border-color: rgba(255, 255, 255, 0.8) !important;
    }

    .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
        width: 24px !important;
        height: 24px !important;
    }
@media (max-width: 767px) {
    /* Guest users - green background for navbar collapse */
    .navbar-collapse-guest {
        background: rgba(0, 56, 41, 0.98) !important;
        margin-top: 0.5rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
        border-top: 2px solid rgba(0, 179, 119, 0.3) !important;
        position: relative !important;
        z-index: 10500 !important;
    }

    /* Logged-in users - transparent navbar collapse (card has its own green header) */
    .navbar-collapse:not(.navbar-collapse-guest) {
        background: transparent !important;
        margin-top: 0.5rem !important;
        padding: 0 !important;
        border-radius: 0 !important;
        border-top: none !important;
        position: relative !important;
        z-index: 10500 !important;
    }

    /* Let Bootstrap handle collapse animation natively - smoother performance */
    .navbar-collapse {
        overflow: hidden !important;
    }

    .navbar-nav {
        gap: 0.5rem !important;
    }

    .navbar-nav .nav-item {
        width: 100% !important;
    }

    .navbar-nav .nav-link {
        padding: 12px 16px !important;
        border-radius: 8px !important;
        transition: all 0.3s ease !important;
        color: white !important;
        font-weight: 600 !important;
        display: block !important;
        width: 100% !important;
        text-align: left !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .navbar-nav .nav-link:hover {
        background: rgba(0, 179, 119, 0.2) !important;
        color: #10d890 !important;
    }

    .navbar-nav .nav-link:active,
    .navbar-nav .nav-link.active {
        background: rgba(0, 179, 119, 0.3) !important;
        color: white !important;
    }
}

/* Hamburger Menu Button */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 15px;
    left: 15px;
    z-index: 10001;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    width: 48px;
    height: 48px;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
    align-items: center;
    justify-content: center;
}

.mobile-menu-toggle:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

.mobile-menu-toggle:active {
    transform: scale(0.95);
}

/* Hamburger Icon */
.hamburger-icon {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
}

.hamburger-icon span {
    display: block;
    height: 3px;
    background: white;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* Hamburger Animation when active */
.mobile-menu-toggle.active .hamburger-icon span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

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

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

/* Sidebar Overlay for Mobile */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

/* ==================
   Responsive Tables
   ================== */

/* Table Container with Horizontal Scroll */
.table-responsive-mobile {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.table-responsive-mobile::-webkit-scrollbar {
    height: 8px;
}

.table-responsive-mobile::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 4px;
}

.table-responsive-mobile::-webkit-scrollbar-thumb {
    background: #00b377;
    border-radius: 4px;
}

.table-responsive-mobile::-webkit-scrollbar-thumb:hover {
    background: #00563d;
}

/* Ensure tables don't break on mobile */
.table-responsive-mobile table {
    min-width: 600px;
    margin-bottom: 0;
}

/* ==================
   Responsive Images
   ================== */

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

/* Responsive image containers */
.img-fluid {
    max-width: 100%;
    height: auto;
}

/* Hero images */
.hero-image-card img,
.about-image-card img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* ==================
   Touch-Friendly Buttons & Inputs
   ================== */

/* Minimum tap target size: 44x44px (Apple & Google guidelines) */
.btn,
button,
.nav-link,
a.btn,
input[type="submit"],
input[type="button"],
input[type="reset"] {
    min-height: 44px;
    padding: 12px 20px;
    font-size: 16px; /* Prevents zoom on iOS */
}

/* Larger buttons on mobile */
@media (max-width: 768px) {
    .btn-hero {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
        font-size: 1rem;
    }

    .btn-lg {
        padding: 16px 28px;
        font-size: 1.125rem;
    }
}

/* Form inputs - touch friendly */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
textarea,
select {
    font-size: 16px !important; /* Prevents zoom on iOS */
    min-height: 44px;
    padding: 12px 16px;
    border-radius: 8px;
    width: 100%;
}

textarea {
    min-height: 120px;
}

/* ==================
   Mobile Navbar Adjustments
   ================== */

@media (max-width: 768px) {
    /* Navbar height reduction */
    .navbar-custom {
        height: 60px;
    }

    .navbar-custom .container-fluid {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .navbar-custom .navbar-brand {
        font-size: 1rem;
        gap: 0.5rem;
    }

    .navbar-custom .navbar-brand img {
        height: 28px;
    }

    /* For logged-in users: hide navbar nav items on mobile - use sidebar instead */
    /* For guest users: Bootstrap collapse handles visibility */
    .navbar-custom .navbar-nav:not(.ms-auto) {
        display: none;
    }

    /* Ensure guest navbar links (with ms-auto class) are always visible when collapse is open */
    .navbar-collapse.show .navbar-nav.ms-auto {
        display: flex !important;
        flex-direction: column !important;
    }

    /* User info badge - smaller on mobile */
    .user-info-badge {
        font-size: 0.75rem;
        padding: 0.4rem 0.75rem;
        gap: 0.5rem;
    }

    .user-info-badge i {
        font-size: 1.15rem;
    }

    /* Mobile user dropdown inside navbar collapse */
    .user-dropdown-mobile {
        background: white;
        border-radius: 12px;
        overflow: hidden;
        margin: 0.5rem 0;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        width: 100%;
        opacity: 0;
        transform: translateY(-10px);
    }

    /* Smooth fade-in when collapse is fully open */
    .navbar-collapse.show .user-dropdown-mobile {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.3s ease 0.1s, transform 0.3s ease 0.1s;
    }

    .user-dropdown-mobile .user-dropdown-header {
        background: linear-gradient(135deg, #004135 0%, #11684d 100%);
        color: white;
        padding: 1.25rem;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        transition: all 0.2s ease;
    }

    .user-dropdown-mobile .user-dropdown-body {
        padding: 0.5rem 0;
        transition: all 0.2s ease;
        max-height: calc(100vh - 250px);
        overflow-y: auto;
        overflow-x: hidden;
    }
    
    /* Smooth scrolling for mobile dropdown body */
    .user-dropdown-mobile .user-dropdown-body::-webkit-scrollbar {
        width: 6px;
    }
    
    .user-dropdown-mobile .user-dropdown-body::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 10px;
    }
    
    .user-dropdown-mobile .user-dropdown-body::-webkit-scrollbar-thumb {
        background: #004135;
        border-radius: 10px;
    }
    
    .user-dropdown-mobile .user-dropdown-body::-webkit-scrollbar-thumb:hover {
        background: #11684d;
    }

    .user-dropdown-mobile .user-dropdown-item {
        transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Notification bell - adjust positioning */
    .notification-bell-link {
        margin-right: 0.5rem;
    }

    /* Notification dropdown - full width on mobile */
    .notification-dropdown {
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        width: 100%;
        max-width: 100%;
        border-radius: 0;
        max-height: calc(100vh - 60px);
    }

    .notification-dropdown-body {
        max-height: calc(100vh - 200px);
    }

    /* Desktop user dropdown - keep original positioning */
    .user-dropdown {
        position: fixed;
        top: 60px;
        right: 10px;
        width: calc(100% - 20px);
        max-width: 320px;
    }
}

/* ==================
   Mobile Sidebar - Slide In/Out
   ================== */

@media (max-width: 768px) {
    /* Show hamburger menu */
    .mobile-menu-toggle {
        display: flex;
    }

    /* Sidebar transforms */
    .sidebar {
        width: 280px;
        height: 100vh;
        position: fixed;
        top: 0;
        left: -280px;
        padding-top: 70px;
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
        border-right: 2px solid rgba(0, 179, 119, 0.2);
        transition: left 0.3s ease;
        z-index: 1000;
        overflow-y: auto;
    }

    /* Sidebar active state */
    .sidebar.active {
        left: 0;
    }

    /* Content wrapper - no margin on mobile */
    .content-wrapper {
        margin-left: 0;
        padding: 1rem;
        width: 100%;
    }

    /* Footer - no margin */
    .footer-logged-in {
        margin-left: 0;
    }

    /* Sidebar navigation items - larger touch targets */
    .sidebar .nav-link {
        padding: 16px 20px;
        font-size: 1rem;
        min-height: 52px;
    }

    .sidebar .nav-link i {
        font-size: 1.35rem;
        min-width: 28px;
    }

    /* Collapsible submenu items */
    .sidebar .collapse .nav-link {
        padding-left: 60px;
        font-size: 0.95rem;
    }
}

/* ==================
   Dashboard Cards & Grids - Mobile Responsive
   ================== */

@media (max-width: 768px) {
    /* Stats Grid - Single Column */
    .stats-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem;
    }

    /* Widgets Grid - Single Column */
    .widgets-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem;
    }

    /* Stat Cards - Compact */
    .stat-card {
        padding: 1.5rem;
    }

    .stat-icon {
        width: 56px;
        height: 56px;
        font-size: 1.75rem;
    }

    .stat-value {
        font-size: 2rem;
    }

    .stat-label {
        font-size: 0.9rem;
    }

    /* Dashboard cards */
    .dashboard-card {
        padding: 1.5rem;
        margin: 20px auto;
    }
}

/* ==================
   Landing Page - Mobile Optimizations
   ================== */

@media (max-width: 768px) {
    /* Hero Section */
    .hero-section {
        padding: 80px 20px 60px;
        min-height: auto;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero-visual {
        order: -1; /* Image first on mobile */
    }

    .hero-title {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1.25rem;
    }

    .hero-description {
        font-size: 1rem;
        line-height: 1.6;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }

    .btn-hero {
        width: 100%;
        justify-content: center;
    }

    /* Stats Section */
    .stats-section {
        padding: 40px 20px;
    }

    .stats-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .stat-card {
        padding: 2rem 1.5rem;
    }

    /* Features Section */
    .features-section {
        padding: 60px 20px;
    }

    .section-header {
        margin-bottom: 40px;
    }

    .section-title {
        font-size: 2rem;
    }

    .section-description {
        font-size: 1rem;
    }

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

    .feature-card {
        padding: 2rem;
    }

    /* CTA Section */
    .cta-section {
        padding: 60px 20px;
    }

    .cta-title {
        font-size: 2rem;
    }

    .cta-description {
        font-size: 1.125rem;
    }

    .cta-button {
        padding: 16px 32px;
        font-size: 1.125rem;
        width: 100%;
        justify-content: center;
    }
}

/* Small mobile devices (< 576px) */
@media (max-width: 576px) {
    .hero-title {
        font-size: 1.75rem;
    }

    .hero-subtitle {
        font-size: 1.125rem;
    }

    .hero-description {
        font-size: 0.95rem;
    }

    .stat-number {
        font-size: 2.25rem;
    }

    .feature-icon,
    .stat-icon {
        width: 52px;
        height: 52px;
        font-size: 1.5rem;
    }

    .feature-title {
        font-size: 1.375rem;
    }
}

/* ==================
   Login/Registration Pages - Mobile
   ================== */

@media (max-width: 768px) {
    /* Auth wrapper */
    .auth-wrapper {
        padding: 20px 15px;
    }

    .auth-container {
        width: 100%;
        max-width: 100%;
    }

    .auth-card {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    /* Login forms */
    .site-login.container,
    .site-register.container {
        width: 100%;
        max-width: 100%;
        padding: 1.5rem;
        margin: 15px auto;
    }

    /* Form titles */
    .auth-card h1,
    .auth-card h2 {
        font-size: 1.75rem;
    }

    /* Input groups */
    .input-with-icon {
        margin-bottom: 1.25rem;
    }

    .input-with-icon input {
        padding-right: 45px;
    }

    .input-icon {
        right: 15px;
    }
}

/* ==================
   Breadcrumbs - Mobile
   ================== */

@media (max-width: 768px) {
    .breadcrumbs-wrapper {
        margin-bottom: 1rem;
        padding: 0.75rem 0;
    }

    .breadcrumb {
        font-size: 0.85rem;
        flex-wrap: wrap;
    }

    .breadcrumb-item {
        margin-bottom: 0.25rem;
    }
}

/* ==================
   Forms - Mobile Optimizations
   ================== */

@media (max-width: 768px) {
    .form-group {
        margin-bottom: 1.25rem;
    }

    label {
        font-size: 0.95rem;
        font-weight: 600;
        margin-bottom: 0.5rem;
    }

    /* Form actions */
    .form-group .btn {
        width: 100%;
        margin-bottom: 0.75rem;
    }

    /* Multi-column forms become single column */
    .row > [class*="col-"] {
        width: 100%;
        margin-bottom: 1rem;
    }
}

/* ==================
   Modal Dialogs - Mobile
   ================== */

@media (max-width: 768px) {
    .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    .modal-content {
        border-radius: 16px;
    }

    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1.25rem;
    }

    .modal-title {
        font-size: 1.25rem;
    }
}

/* ==================
   Cards - Mobile Responsive
   ================== */

@media (max-width: 768px) {
    .card {
        margin-bottom: 1rem;
        border-radius: 12px;
    }

    .card-body {
        padding: 1.25rem;
    }

    .card-header {
        padding: 1rem 1.25rem;
        font-size: 1.125rem;
    }

    /* Card grids */
    .card-deck,
    .card-group {
        flex-direction: column;
    }

    .card-deck .card,
    .card-group .card {
        margin-bottom: 1rem;
    }
}

/* ==================
   Alerts - Mobile
   ================== */

@media (max-width: 768px) {
    .alert {
        padding: 1rem;
        font-size: 0.9rem;
        border-radius: 10px;
    }

    .alert-dismissible .btn-close {
        padding: 1rem;
    }
}

/* ==================
   Pagination - Mobile
   ================== */

@media (max-width: 768px) {
    .pagination {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
    }

    .pagination .page-item {
        margin: 0;
    }

    .pagination .page-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
        min-width: 40px;
        min-height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Hide some pagination items on very small screens */
    @media (max-width: 480px) {
        .pagination .page-item:not(.active):not(.disabled):nth-child(n+6):nth-last-child(n+3) {
            display: none;
        }
    }
}

/* ==================
   Typography - Mobile Scaling
   ================== */

@media (max-width: 768px) {
    body {
        font-size: 15px;
        line-height: 1.6;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    h4 {
        font-size: 1.25rem;
    }

    h5 {
        font-size: 1.125rem;
    }

    h6 {
        font-size: 1rem;
    }

    p {
        font-size: 1rem;
    }
}

/* ==================
   Spacing Utilities - Mobile
   ================== */

@media (max-width: 768px) {
    .container-fluid {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Reduce vertical spacing */
    .my-5 {
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
    }

    .py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    .my-4 {
        margin-top: 1.5rem !important;
        margin-bottom: 1.5rem !important;
    }

    .py-4 {
        padding-top: 1.5rem !important;
        padding-bottom: 1.5rem !important;
    }
}

/* ==================
   Grid System - Mobile Adjustments
   ================== */

@media (max-width: 768px) {
    /* Force all columns to stack */
    .row > [class*="col-"] {
        flex: 0 0 100%;
        max-width: 100%;
    }

    /* Remove negative margins on small screens */
    .row {
        margin-left: 0;
        margin-right: 0;
    }

    .row > * {
        padding-left: 0;
        padding-right: 0;
    }
}

/* ==================
   About Page - Mobile Responsive
   ================== */

@media (max-width: 768px) {
    .about-hero {
        padding: 60px 20px 50px;
    }

    .about-hero h1 {
        font-size: 2rem;
    }

    .about-hero p {
        font-size: 1.125rem;
    }

    .about-image-section {
        margin: -40px auto 40px;
    }

    .about-image-card {
        padding: 1.5rem;
    }

    .about-content {
        margin-bottom: 40px;
    }

    .content-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .content-text h2 {
        font-size: 2rem;
    }

    .content-text p {
        font-size: 1rem;
    }

    .highlight-box {
        padding: 2rem;
    }

    .mission-vision-section {
        padding: 50px 20px;
    }

    .mission-vision-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .mv-card {
        padding: 2rem;
    }

    .mv-card h3 {
        font-size: 1.75rem;
    }

    /* Timeline adjustments */
    .timeline-section {
        padding: 50px 20px;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        flex-direction: row !important;
    }

    .timeline-content {
        width: calc(100% - 60px);
        margin-left: 60px;
        text-align: left !important;
        padding: 1.75rem;
    }

    .timeline-marker {
        left: 20px;
        transform: none;
    }

    .features-overview {
        padding: 50px 20px;
    }

    .features-grid-about {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .feature-item {
        padding: 2rem;
    }
}

/* ==================
   Contact Page - Mobile Responsive
   ================== */

@media (max-width: 768px) {
    .contact-hero {
        padding: 60px 20px 50px;
    }

    .contact-hero h1 {
        font-size: 2rem;
    }

    .contact-hero p {
        font-size: 1.125rem;
    }

    .contact-content {
        margin: -30px auto 40px;
    }

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

    .contact-info-card,
    .map-card {
        padding: 2rem;
        border-radius: 20px;
    }

    .contact-item {
        padding: 1.25rem;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1rem;
    }

    .contact-item-icon {
        width: 52px;
        height: 52px;
        font-size: 1.5rem;
        margin-bottom: 0;
    }

    .contact-item-content {
        width: 100%;
    }

    .contact-item-label {
        text-align: center;
    }

    .contact-item-text {
        text-align: center;
        margin: 0;
    }

    /* Office Hours Mobile Layout */
    .office-hours {
        padding: 1.5rem;
        margin-top: 1.5rem;
    }

    .office-hours h4 {
        font-size: 1.125rem;
        text-align: center;
        margin-bottom: 1rem;
    }

    .office-hours-grid {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .office-hours-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 1rem;
        background: white;
        border-radius: 12px;
        gap: 0.5rem;
    }

    .office-hours-day {
        font-weight: 600;
        font-size: 1rem;
    }

    .office-hours-time {
        font-size: 0.9rem;
        color: var(--ekafa-gray-600, #4b5563);
    }

    .map-container {
        height: 300px;
    }

    .social-section {
        padding: 40px 20px;
    }

    .social-container h3 {
        font-size: 1.75rem;
    }

    .social-link {
        width: 56px;
        height: 56px;
        font-size: 1.5rem;
    }
}

/* Extra small devices - phones in portrait mode */
@media (max-width: 576px) {
    .contact-hero {
        padding: 50px 15px 40px;
    }

    .contact-hero h1 {
        font-size: 1.75rem;
    }

    .contact-hero p {
        font-size: 1rem;
    }

    .contact-info-card,
    .map-card {
        padding: 1.5rem;
    }

    .contact-item {
        padding: 1rem;
        margin-bottom: 1rem;
    }

    .contact-item-icon {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }

    .contact-item-label {
        font-size: 0.875rem;
        font-weight: 600;
    }

    .contact-item-text {
        font-size: 0.9rem;
    }

    .office-hours {
        padding: 1.25rem;
    }

    .office-hours h4 {
        font-size: 1rem;
    }

    .office-hours-item {
        padding: 0.875rem;
    }

    .map-container {
        height: 250px;
        border-radius: 12px;
    }

    .social-container h3 {
        font-size: 1.5rem;
    }

    .social-link {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }
}

/* ==================
   Performance Optimizations
   ================== */

/* Reduce animations on mobile for better performance */
@media (max-width: 768px) and (prefers-reduced-motion: no-preference) {
    * {
        animation-duration: 0.3s !important;
        transition-duration: 0.3s !important;
    }
}

/* Disable hover effects on touch devices */
@media (hover: none) and (pointer: coarse) {
    .btn:hover,
    .nav-link:hover,
    .card:hover {
        transform: none;
    }
}

/* ==================
   Landscape Orientation Adjustments
   ================== */

@media (max-width: 768px) and (orientation: landscape) {
    .hero-section {
        min-height: auto;
        padding: 60px 20px 40px;
    }

    .sidebar {
        height: 100vh;
    }

    .modal-dialog {
        margin: 5px auto;
    }
}

/* ==================
   Very Small Devices (< 380px)
   ================== */

@media (max-width: 380px) {
    .navbar-custom .navbar-brand {
        font-size: 0.9rem;
    }

    .navbar-custom .navbar-brand img {
        height: 24px;
    }

    .mobile-menu-toggle {
        width: 44px;
        height: 44px;
    }

    .user-info-badge {
        font-size: 0.7rem;
        padding: 0.35rem 0.6rem;
    }

    .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }

    .stat-card,
    .feature-card {
        padding: 1.25rem;
    }
}

/* ==================
   Print Styles
   ================== */

@media print {
    .navbar-custom,
    .sidebar,
    .mobile-menu-toggle,
    .sidebar-overlay,
    .notification-dropdown,
    .user-dropdown,
    footer {
        display: none !important;
    }

    .content-wrapper {
        margin-left: 0 !important;
        padding: 0 !important;
    }

    body {
        background: white !important;
    }

    body::before {
        display: none !important;
    }
}

/* ==================
   Accessibility Enhancements
   ================== */

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid #00b377;
    outline-offset: 2px;
}

/* Skip to main content link */
.skip-to-main {
    position: absolute;
    top: -100px;
    left: 0;
    background: #003829;
    color: white;
    padding: 12px 20px;
    z-index: 10000;
    border-radius: 0 0 8px 0;
}

.skip-to-main:focus {
    top: 0;
}

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

}