/* Mobile Bottom Bar Styles */

.mobile-bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    padding: 0 12px 12px 12px;
    transform: translateY(0) !important;
    transition: none !important;
}

.bottom-bar-container {
    background: hsla(0, 0%, 93%, 0.72);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border-radius: 30px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.6);
    padding: 12px 8px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: relative;
    max-width: 500px;
    margin: 0 auto;
    border: 0.5px solid rgba(255, 255, 255, 0.5);
}

.bottom-bar-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: rgba(0, 0, 0, 0.7);
    padding: 8px 5px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    z-index: 1;
}

.bottom-bar-item.active {
    color: rgba(0, 0, 0, 0.95);
}

.bottom-bar-icon {
    font-size: 22px;
    margin-bottom: 4px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bottom-bar-icon svg {
    width: 22px;
    height: 22px;
}

.bottom-bar-item:active {
    transform: scale(0.92);
}

.bottom-bar-item.active .bottom-bar-icon {
    transform: translateY(-2px);
}

.bottom-bar-label {
    font-size: 10px;
    font-weight: 600;
    text-align: center;
    letter-spacing: -0.01em;
}

/* Center Emergency Button */
.bottom-bar-item.center-item {
    position: relative;
    margin: 0 5px;
}

.center-emergency-btn {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff3b30 0%, #ff6b6b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(255, 59, 48, 0.3),
                0 8px 32px rgba(255, 59, 48, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
    position: relative;
    margin-top: -32px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 4px solid hsla(0, 0%, 93%, 0.9);
    text-decoration: none;
}

.center-emergency-btn:active {
    transform: scale(0.92);
}

.center-emergency-btn .bottom-bar-icon {
    color: white;
    font-size: 26px;
    margin: 0;
}

.center-emergency-btn .bottom-bar-label {
    position: absolute;
    bottom: -22px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    color: rgba(0, 0, 0, 0.7);
    font-weight: 600;
    font-size: 10px;
}

/* Subtle ripple effect */
.center-emergency-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 59, 48, 0.4);
    transform: translate(-50%, -50%);
    opacity: 0;
}

/* Badge */
.emergency-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: linear-gradient(135deg, #ff3b30, #ff6b6b);
    color: white;
    font-size: 9px;
    font-weight: 700;
    padding: 3px 7px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(255, 59, 48, 0.4);
    border: 1.5px solid white;
}

/* Contact Popup */
.contact-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.25s ease-in-out;
}

.contact-popup-overlay.show {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 1;
}

.contact-popup {
    background: hsla(0, 0%, 97%, 0.85);
    backdrop-filter: blur(60px) saturate(180%);
    -webkit-backdrop-filter: blur(60px) saturate(180%);
    width: 100%;
    max-width: 500px;
    border-radius: 20px 20px 0 0;
    transform: translate3d(0, 100%, 0);
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.12);
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    will-change: transform;
    border: 0.5px solid rgba(255, 255, 255, 0.6);
}

.contact-popup-overlay.show .contact-popup {
    transform: translate3d(0, 0, 0);
}

.contact-popup-header {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%);
    backdrop-filter: blur(20px);
    color: white;
    padding: 24px 20px 20px;
    position: relative;
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.2);
}

.popup-drag-handle {
    width: 36px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    margin: 0 auto 16px;
}

.contact-popup-header h2 {
    font-size: 22px;
    margin-bottom: 6px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.contact-popup-header p {
    font-size: 14px;
    opacity: 0.9;
    font-weight: 500;
}

.popup-close-btn {
    position: absolute;
    top: 20px;
    right: 16px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.popup-close-btn:hover {
    background: rgba(255, 255, 255, 0.35);
}

.popup-close-btn:active {
    transform: scale(0.92);
}

.contact-popup-body {
    padding: 20px 16px;
    overflow-y: auto;
    flex: 1;
}

.contact-item {
    display: flex;
    align-items: center;
    padding: 16px;
    margin-bottom: 10px;
    background: hsla(0, 0%, 100%, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    text-decoration: none;
    color: rgba(0, 0, 0, 0.85);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.contact-item:active {
    transform: scale(0.97);
    background: hsla(0, 0%, 100%, 0.8);
}

.contact-item-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-right: 14px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.contact-item-content {
    flex: 1;
}

.contact-item-title {
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 3px;
    color: rgba(0, 0, 0, 0.9);
    letter-spacing: -0.01em;
}

.contact-item-text {
    font-size: 13px;
    color: rgba(0, 0, 0, 0.6);
    font-weight: 500;
}

.contact-item-arrow {
    font-size: 16px;
    color: rgba(0, 0, 0, 0.3);
}

/* Responsive */
@media (max-width: 480px) {
    .bottom-bar-container {
        padding: 10px 6px;
    }

    .bottom-bar-item {
        padding: 6px 3px;
    }

    .bottom-bar-icon {
        font-size: 20px;
    }

    .bottom-bar-label {
        font-size: 9px;
    }

    .center-emergency-btn {
        width: 56px;
        height: 56px;
        margin-top: -28px;
    }

    .center-emergency-btn .bottom-bar-icon {
        font-size: 24px;
    }
}
