/* Mobile Fixes for BA Bangunan - Consistency Improvements */

/* ===== FACTS SECTION FIXES ===== */
@media (max-width: 768px) {
    /* Container centering for mobile */
    .container .row.d-flex.justify-content-center {
        justify-content: center !important;
        align-items: stretch !important;
        flex-wrap: wrap !important;
    }
    
    /* Override Bootstrap grid for consistent card sizing */
    .row.g-4.d-flex.justify-content-center.align-items-stretch {
        margin: 0 !important;
        justify-content: center !important;
        align-items: stretch !important;
    }
    
    /* Fixed height for all fact items */
    .fact-item {
        height: 280px !important;
        min-height: 280px !important;
        max-height: 280px !important;
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        padding: 25px 20px !important;
        margin-bottom: 20px !important;
        border-radius: 20px !important;
        background: white !important;
        box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
        transition: all 0.3s ease !important;
        border: 1px solid rgba(40,167,69,0.1) !important;
        position: relative !important;
        overflow: hidden !important;
    }
    
    /* Ensure all cards have same width and height */
    .col-lg-3.col-md-6.col-sm-6 {
        display: flex !important;
        flex-direction: column !important;
        margin-bottom: 20px !important;
    }
    
    .col-lg-3.col-md-6.col-sm-6 a {
        display: flex !important;
        flex-direction: column !important;
        height: 100% !important;
        width: 100% !important;
        text-decoration: none !important;
    }
    
    /* Ensure consistent card dimensions */
    .fact-item {
        flex: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        width: 100% !important;
        min-width: 0 !important;
    }
    
    /* Force equal height for all cards */
    .fact-item,
    .fact-item * {
        box-sizing: border-box !important;
    }
    
    /* Consistent icon sizing */
    .fact-icon {
        margin-bottom: 20px !important;
        flex-shrink: 0 !important;
    }
    
    .fact-icon i {
        font-size: 3rem !important;
        color: #28a745 !important;
        transition: all 0.3s ease !important;
    }
    
    /* Consistent text sizing */
    .fact-item h6 {
        font-size: 0.95rem !important;
        font-weight: 500 !important;
        color: #666 !important;
        margin-bottom: 10px !important;
        line-height: 1.4 !important;
        text-align: center !important;
    }
    
    .fact-item h2 {
        font-size: 2.5rem !important;
        font-weight: 700 !important;
        color: #333 !important;
        margin-bottom: 10px !important;
        line-height: 1.2 !important;
        text-align: center !important;
    }
    
    .fact-item h3 {
        font-size: 1.6rem !important;
        font-weight: 600 !important;
        color: #333 !important;
        margin-bottom: 5px !important;
        line-height: 1.2 !important;
        text-align: center !important;
    }
    
    /* Hover effects */
    .fact-item:hover {
        transform: translateY(-8px) !important;
        box-shadow: 0 15px 40px rgba(0,0,0,0.2) !important;
        border-color: #28a745 !important;
    }
    
    .fact-item:hover .fact-icon i {
        transform: scale(1.15) !important;
        color: #20c997 !important;
    }
    
    /* Top border animation */
    .fact-item::before {
        content: '' !important;
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        height: 4px !important;
        background: linear-gradient(90deg, #28a745, #20c997) !important;
        transform: scaleX(0) !important;
        transition: transform 0.3s ease !important;
    }
    
    .fact-item:hover::before {
        transform: scaleX(1) !important;
    }
}

/* ===== EXTRA SMALL SCREENS ===== */
@media (max-width: 575.98px) {
    /* Center cards on very small screens */
    .container .row.d-flex.justify-content-center {
        justify-content: center !important;
        align-items: center !important;
    }
    
    .col-lg-3.col-md-6.col-sm-6 {
        margin-bottom: 15px !important;
        width: 100% !important;
        max-width: 300px !important;
    }
    
    .fact-item {
        height: 250px !important;
        min-height: 250px !important;
        max-height: 250px !important;
        padding: 20px 15px !important;
        width: 100% !important;
        margin: 0 auto !important;
    }
    
    .fact-item h2 {
        font-size: 2rem !important;
    }
    
    .fact-item h3 {
        font-size: 1.4rem !important;
    }
    
    .fact-item h6 {
        font-size: 0.9rem !important;
    }
    
    .fact-icon i {
        font-size: 2.5rem !important;
    }
}

/* ===== SMALL MOBILE SCREENS ===== */
@media (max-width: 480px) {
    .container .row.d-flex.justify-content-center {
        justify-content: center !important;
        align-items: center !important;
        flex-direction: column !important;
    }
    
    .row.g-4.d-flex.justify-content-center.align-items-stretch {
        justify-content: center !important;
        align-items: center !important;
        flex-direction: column !important;
    }
    
    .col-lg-3.col-md-6.col-sm-6 {
        width: 100% !important;
        max-width: 280px !important;
        margin: 0 auto 15px auto !important;
        flex: 0 0 auto !important;
    }
    
    .fact-item {
        height: 240px !important;
        min-height: 240px !important;
        max-height: 240px !important;
        width: 100% !important;
        margin: 0 auto !important;
    }
}

/* ===== VERY SMALL MOBILE SCREENS ===== */
@media (max-width: 400px) {
    .container .row.d-flex.justify-content-center {
        justify-content: center !important;
        align-items: center !important;
        flex-direction: column !important;
        padding: 0 10px !important;
    }
    
    .row.g-4.d-flex.justify-content-center.align-items-stretch {
        justify-content: center !important;
        align-items: center !important;
        flex-direction: column !important;
        margin: 0 !important;
    }
    
    .col-lg-3.col-md-6.col-sm-6 {
        width: 100% !important;
        max-width: 260px !important;
        margin: 0 auto 10px auto !important;
        flex: 0 0 auto !important;
    }
    
    .fact-item {
        height: 220px !important;
        min-height: 220px !important;
        max-height: 220px !important;
        width: 100% !important;
        margin: 0 auto !important;
        padding: 15px 10px !important;
    }
}

/* ===== LANDSCAPE ORIENTATION ===== */
@media (max-width: 768px) and (orientation: landscape) {
    /* Center cards in landscape mode */
    .container .row.d-flex.justify-content-center {
        justify-content: center !important;
        align-items: stretch !important;
    }
    
    .row.g-4.d-flex.justify-content-center.align-items-stretch {
        justify-content: center !important;
        align-items: stretch !important;
    }
    
    .col-lg-3.col-md-6.col-sm-6 {
        margin-bottom: 10px !important;
        width: 100% !important;
        max-width: 200px !important;
    }
    
    .fact-item {
        height: 220px !important;
        min-height: 220px !important;
        max-height: 220px !important;
        width: 100% !important;
    }
}

/* ===== TEAM ITEMS CONSISTENCY ===== */
@media (max-width: 768px) {
    .team-item {
        height: 450px !important;
        min-height: 450px !important;
        max-height: 450px !important;
        padding: 25px !important;
        margin-bottom: 25px !important;
        border-radius: 20px !important;
        background: white !important;
        box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
        transition: all 0.3s ease !important;
        border: none !important;
        overflow: hidden !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }
    
    .team-image-container {
        height: 220px !important;
        margin-bottom: 20px !important;
        border-radius: 15px !important;
        overflow: hidden !important;
        flex-shrink: 0 !important;
    }
    
    .team-text {
        height: 180px !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }
    
    .team-text h6 {
        font-size: 1.2rem !important;
        font-weight: 600 !important;
        margin-bottom: 12px !important;
        color: #333 !important;
        line-height: 1.3 !important;
        max-height: 3em !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    .team-text p {
        font-size: 0.95rem !important;
        color: #666 !important;
        margin-bottom: 15px !important;
        line-height: 1.5 !important;
        flex-grow: 1 !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 3 !important;
        line-clamp: 3 !important;
        -webkit-box-orient: vertical !important;
    }
}

/* ===== PROJECT ITEMS CONSISTENCY ===== */
@media (max-width: 768px) {
    .project-item {
        height: 320px !important;
        min-height: 320px !important;
        max-height: 320px !important;
        padding: 25px !important;
        margin-bottom: 25px !important;
        border-radius: 20px !important;
        background: white !important;
        box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
        transition: all 0.3s ease !important;
        border: none !important;
        overflow: hidden !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }
    
    .project-item .position-relative {
        height: 200px !important;
        margin-bottom: 20px !important;
        border-radius: 15px !important;
        overflow: hidden !important;
    }
    
    .project-item h6 {
        font-size: 1.1rem !important;
        font-weight: 600 !important;
        color: #333 !important;
        margin: 0 !important;
        text-align: center !important;
        margin-top: auto !important;
    }
}

/* ===== CAROUSEL CONSISTENCY ===== */
@media (max-width: 768px) {
    .owl-carousel .owl-item .team-item {
        height: 450px !important;
        min-height: 450px !important;
        max-height: 450px !important;
    }
    
    .owl-carousel .owl-item .project-item {
        height: 320px !important;
        min-height: 320px !important;
        max-height: 320px !important;
    }
    
    .project-carousel .owl-item {
        padding: 0 10px !important;
    }
}

/* ===== BUTTON CONSISTENCY ===== */
@media (max-width: 768px) {
    .btn {
        min-height: 48px !important;
        min-width: 48px !important;
        padding: 15px 25px !important;
        border-radius: 30px !important;
        font-weight: 600 !important;
        font-size: 16px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        transition: all 0.3s ease !important;
    }
    
    .btn-sm {
        min-height: 40px !important;
        padding: 10px 20px !important;
        font-size: 14px !important;
    }
}

/* ===== NAVIGATION CONSISTENCY ===== */
@media (max-width: 768px) {
    .nav-link {
        min-height: 48px !important;
        padding: 15px 20px !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 8px !important;
        margin: 5px 10px !important;
        transition: all 0.3s ease !important;
    }
    
    .navbar-collapse {
        background: rgba(40, 167, 69, 0.98) !important;
        border-radius: 15px !important;
        margin-top: 15px !important;
        padding: 20px !important;
        backdrop-filter: blur(15px) !important;
        border: 1px solid rgba(255,255,255,0.1) !important;
    }
}

/* ===== SPACING CONSISTENCY ===== */
@media (max-width: 768px) {
    .container-xxl {
        padding: 30px 15px !important;
    }
    
    .container-xxl.py-5 {
        padding: 50px 15px !important;
    }
    
    .mb-5 {
        margin-bottom: 3rem !important;
    }
    
    .mb-4 {
        margin-bottom: 2rem !important;
    }
    
    .mb-3 {
        margin-bottom: 1.5rem !important;
    }
}

/* ===== TYPOGRAPHY CONSISTENCY ===== */
@media (max-width: 768px) {
    h1 {
        font-size: 2rem !important;
        line-height: 1.3 !important;
    }
    
    h2 {
        font-size: 1.8rem !important;
        line-height: 1.3 !important;
    }
    
    h3 {
        font-size: 1.6rem !important;
        line-height: 1.3 !important;
    }
    
    h4 {
        font-size: 1.4rem !important;
        line-height: 1.3 !important;
    }
    
    h5 {
        font-size: 1.2rem !important;
        line-height: 1.3 !important;
    }
    
    h6 {
        font-size: 1.1rem !important;
        line-height: 1.3 !important;
    }
    
    .display-6 {
        font-size: 1.8rem !important;
        line-height: 1.3 !important;
        font-weight: 700 !important;
    }
    
    .section-title {
        font-size: 14px !important;
        font-weight: 600 !important;
        letter-spacing: 1px !important;
        text-transform: uppercase !important;
        color: #28a745 !important;
    }
}

/* ===== SHADOW CONSISTENCY ===== */
@media (max-width: 768px) {
    .card, .team-item, .project-item, .fact-item {
        box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
        transition: all 0.3s ease !important;
    }
    
    .card:hover, .team-item:hover, .project-item:hover, .fact-item:hover {
        box-shadow: 0 15px 40px rgba(0,0,0,0.2) !important;
        transform: translateY(-8px) !important;
    }
}

/* ===== BORDER RADIUS CONSISTENCY ===== */
@media (max-width: 768px) {
    .card, .team-item, .project-item, .fact-item {
        border-radius: 20px !important;
    }
    
    .btn {
        border-radius: 30px !important;
    }
    
    .nav-link {
        border-radius: 8px !important;
    }
    
    .navbar-collapse {
        border-radius: 15px !important;
    }
}

/* ===== COLOR CONSISTENCY ===== */
@media (max-width: 768px) {
    .text-success {
        color: #28a745 !important;
    }
    
    .bg-success {
        background-color: #28a745 !important;
    }
    
    .btn-success {
        background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
        border: none !important;
    }
    
    .btn-outline-success {
        border-color: #28a745 !important;
        color: #28a745 !important;
    }
    
    .btn-outline-success:hover {
        background-color: #28a745 !important;
        color: white !important;
    }
}

/* ===== ANIMATION CONSISTENCY ===== */
@media (max-width: 768px) {
    .card, .team-item, .project-item, .fact-item, .btn, .nav-link {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    .wow {
        animation-duration: 1s !important;
        animation-fill-mode: both !important;
    }
}

/* ===== ACCESSIBILITY CONSISTENCY ===== */
@media (max-width: 768px) {
    .btn:focus, .nav-link:focus, .fab-btn:focus {
        outline: 3px solid rgba(40, 167, 69, 0.5) !important;
        outline-offset: 2px !important;
    }
    
    a, button {
        min-height: 48px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
@media (max-width: 768px) {
    .card, .team-item, .project-item, .fact-item {
        will-change: transform !important;
        backface-visibility: hidden !important;
    }
    
    img {
        max-width: 100% !important;
        height: auto !important;
        border-radius: 8px !important;
    }
}

/* ===== TOUCH OPTIMIZATIONS ===== */
@media (max-width: 768px) {
    .btn, .nav-link, .card, .team-item, .project-item, .fact-item {
        -webkit-tap-highlight-color: transparent !important;
        user-select: none !important;
    }
    
    .btn:active, .nav-link:active {
        transform: scale(0.98) !important;
    }
}

/* ===== FOOTER MOBILE OPTIMIZATIONS ===== */
@media (max-width: 768px) {
    /* Main footer container */
    .footer {
        padding: 40px 0 20px 0 !important;
        background: #212529 !important;
        color: #fff !important;
        margin-top: 0 !important;
    }
    
    .footer .container {
        padding: 0 15px !important;
    }
    
    .footer .container-xxl {
        background: #212529 !important;
    }
    
    .footer .col-lg-6 {
        margin-bottom: 30px !important;
        text-align: center !important;
        padding: 0 10px !important;
    }
    
    .footer h5 {
        font-size: 1.3rem !important;
        margin-bottom: 25px !important;
        text-align: center !important;
        color: #fff !important;
    }
    
    .footer p {
        font-size: 14px !important;
        text-align: center !important;
        margin-bottom: 15px !important;
        color: #adb5bd !important;
    }
    
    .footer .btn-link {
        display: block !important;
        margin: 8px 0 !important;
        text-align: center !important;
        font-size: 14px !important;
        padding: 8px 0 !important;
        color: #adb5bd !important;
        text-decoration: none !important;
    }
    
    .footer .btn-link:hover {
        color: #28a745 !important;
    }
    
    .footer .btn-square {
        margin: 0 8px !important;
        width: 45px !important;
        height: 45px !important;
        border-radius: 12px !important;
        transition: all 0.3s ease !important;
        background: rgba(255,255,255,0.1) !important;
        border: 1px solid rgba(255,255,255,0.2) !important;
        color: white !important;
        backdrop-filter: blur(10px) !important;
    }
    
    .footer .btn-square:hover {
        transform: translateY(-3px) !important;
        box-shadow: 0 6px 20px rgba(0,0,0,0.15) !important;
        background: rgba(255,255,255,0.2) !important;
        border-color: rgba(255,255,255,0.3) !important;
    }
    
    /* Mobile Quick Actions */
    .footer .d-lg-none {
        margin-top: 30px !important;
        padding-top: 20px !important;
        border-top: 1px solid rgba(255,255,255,0.1) !important;
        background: #212529 !important;
    }
    
    .footer .d-lg-none h6 {
        font-size: 1.1rem !important;
        margin-bottom: 20px !important;
        text-align: center !important;
        color: #fff !important;
    }
    
    .footer .d-lg-none .btn {
        font-size: 14px !important;
        padding: 12px 15px !important;
        margin-bottom: 10px !important;
        border-radius: 25px !important;
        font-weight: 600 !important;
        transition: all 0.3s ease !important;
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    .footer .d-lg-none .btn:hover {
        transform: translateY(-2px) !important;
        box-shadow: 0 4px 15px rgba(0,0,0,0.2) !important;
    }
    
    .footer .d-lg-none .btn-success {
        background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
        border: none !important;
        color: white !important;
    }
    
    .footer .d-lg-none .btn-outline-success {
        border: 2px solid #28a745 !important;
        color: #28a745 !important;
        background: transparent !important;
    }
    
    .footer .d-lg-none .btn-outline-success:hover {
        background: #28a745 !important;
        color: white !important;
    }
    
    /* Copyright section */
    .footer .copyright {
        margin-top: 30px !important;
        padding: 20px 0 !important;
        border-top: 1px solid rgba(255,255,255,0.1) !important;
        background: #1a1d20 !important;
    }
    
    .footer .copyright .container {
        background: #1a1d20 !important;
    }
    
    .footer .copyright .row {
        align-items: center !important;
        margin: 0 !important;
    }
    
    .footer .copyright .col-md-6 {
        text-align: center !important;
        margin-bottom: 10px !important;
        padding: 0 15px !important;
    }
    
    .footer .copyright small {
        font-size: 12px !important;
        opacity: 0.8 !important;
        color: #adb5bd !important;
    }
    
    /* Social media buttons */
    .footer .d-flex.pt-3 {
        justify-content: center !important;
        margin-top: 20px !important;
        padding: 0 !important;
    }
    
    .footer .d-flex.pt-3 .btn-square {
        background: rgba(255,255,255,0.1) !important;
        border: 1px solid rgba(255,255,255,0.2) !important;
        color: white !important;
        backdrop-filter: blur(10px) !important;
    }
    
    .footer .d-flex.pt-3 .btn-square:hover {
        background: rgba(255,255,255,0.2) !important;
        border-color: rgba(255,255,255,0.3) !important;
        transform: translateY(-3px) !important;
    }
    
    /* Remove any white backgrounds */
    .footer * {
        background-color: transparent !important;
    }
    
    .footer .container,
    .footer .container-xxl,
    .footer .copyright .container {
        background: #212529 !important;
    }
    
    .footer .copyright {
        background: #1a1d20 !important;
    }
    
    /* Back to Top Button */
    .back-to-top {
        position: fixed !important;
        bottom: 20px !important;
        right: 20px !important;
        width: 50px !important;
        height: 50px !important;
        background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
        color: white !important;
        border-radius: 50% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        text-decoration: none !important;
        box-shadow: 0 8px 25px rgba(40,167,69,0.3) !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        z-index: 999 !important;
        opacity: 0 !important;
        visibility: hidden !important;
        transform: translateY(20px) !important;
        backdrop-filter: blur(10px) !important;
        border: none !important;
    }
    
    .back-to-top.show {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) !important;
    }
    
    .back-to-top:hover {
        background: linear-gradient(135deg, #20c997 0%, #28a745 100%) !important;
        transform: translateY(-3px) !important;
        box-shadow: 0 12px 30px rgba(40,167,69,0.4) !important;
        color: white !important;
    }
    
    .back-to-top i {
        font-size: 20px !important;
    }
    
    /* Ensure no white space at bottom */
    body {
        background: #f8f9fa !important;
    }
    
    /* Remove any white margins/padding */
    .container-fluid {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    
    /* Ensure footer extends to bottom */
    .footer {
        margin-bottom: 0 !important;
        padding-bottom: 20px !important;
    }
    
    /* Remove any white backgrounds from main content */
    .container-xxl {
        background: transparent !important;
    }
    
    /* Ensure proper spacing */
    .mt-5 {
        margin-top: 3rem !important;
    }
    
    /* Fix any potential white gaps */
    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    .col-lg-6, .col-md-6, .col-12 {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }
    
    /* Floating Action Buttons positioning */
    .mobile-fab {
        position: fixed !important;
        bottom: 20px !important;
        right: 20px !important;
        z-index: 1000 !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
    }
    
    .fab-btn {
        width: 56px !important;
        height: 56px !important;
        border-radius: 50% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        color: white !important;
        text-decoration: none !important;
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2) !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        font-size: 20px !important;
        position: relative !important;
        overflow: hidden !important;
        backdrop-filter: blur(10px) !important;
        border: none !important;
    }
    
    .fab-phone {
        background: linear-gradient(135deg, #007bff 0%, #0056b3 100%) !important;
    }
    
    .fab-whatsapp {
        background: linear-gradient(135deg, #25d366 0%, #128c7e 100%) !important;
    }
    
    .fab-btn:hover {
        transform: translateY(-3px) !important;
        color: white !important;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3) !important;
    }
    
    .fab-btn:active {
        transform: translateY(-1px) !important;
    }
    
    /* Remove white space above footer */
    .footer.mt-5 {
        margin-top: 0 !important;
    }
    
    /* Ensure footer starts immediately after content */
    .footer {
        border-top: none !important;
    }
    
    /* Fix any container issues */
    .container-fluid.bg-dark {
        background: #212529 !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    /* Ensure proper footer structure */
    .footer .container-fluid {
        background: #212529 !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    .footer .container-fluid .container {
        background: #212529 !important;
        padding: 40px 15px 20px 15px !important;
    }
    
    .footer .container-fluid .copyright {
        background: #1a1d20 !important;
        padding: 20px 0 !important;
        margin: 0 !important;
    }
    
    .footer .container-fluid .copyright .container {
        background: #1a1d20 !important;
        padding: 0 15px !important;
    }
    
    /* Error Message Styling */
    #error-message {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        transform: translateX(0) !important;
        opacity: 1 !important;
        backdrop-filter: blur(10px) !important;
        border: 1px solid rgba(220, 53, 69, 0.2) !important;
        box-shadow: 0 8px 25px rgba(220, 53, 69, 0.15) !important;
    }
    
    #error-message.hide {
        transform: translateX(100%) !important;
        opacity: 0 !important;
    }
    
    #close-error {
        transition: all 0.3s ease !important;
        position: relative !important;
        overflow: hidden !important;
    }
    
    #close-error::before {
        content: '' !important;
        position: absolute !important;
        top: 50% !important;
        left: 50% !important;
        width: 0 !important;
        height: 0 !important;
        background: rgba(220, 53, 69, 0.1) !important;
        border-radius: 50% !important;
        transform: translate(-50%, -50%) !important;
        transition: all 0.3s ease !important;
    }
    
    #close-error:hover::before {
        width: 100% !important;
        height: 100% !important;
    }
    
    #close-error:hover {
        transform: scale(1.1) !important;
    }
    
    #close-error:active {
        transform: scale(0.95) !important;
    }
    
    #close-error:focus {
        outline: 2px solid rgba(220, 53, 69, 0.5) !important;
        outline-offset: 2px !important;
    }
    
    /* Mobile Error Message */
    @media (max-width: 768px) {
        #error-message {
            top: 10px !important;
            right: 10px !important;
            left: 10px !important;
            max-width: none !important;
            font-size: 13px !important;
            padding: 12px 15px !important;
            border-radius: 12px !important;
            backdrop-filter: blur(15px) !important;
        }
        
        #close-error {
            width: 24px !important;
            height: 24px !important;
            font-size: 16px !important;
            min-height: 24px !important;
        }
        
        #error-message span {
            font-size: 13px !important;
            line-height: 1.4 !important;
        }
        
        #error-message i.fa-exclamation-triangle {
            font-size: 14px !important;
        }
        
        #error-message.hide {
            transform: translateY(-100%) !important;
        }
    }
    
    /* Animation for error message entrance */
    @keyframes slideInFromRight {
        from {
            transform: translateX(100%);
            opacity: 0;
        }
        to {
            transform: translateX(0);
            opacity: 1;
        }
    }
    
    @keyframes slideInFromTop {
        from {
            transform: translateY(-100%);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }
    
    #error-message {
        animation: slideInFromRight 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    @media (max-width: 768px) {
        #error-message {
            animation: slideInFromTop 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        }
    }
}
