/**
 * Hubb Phone Bubble - Styles
 * Version: 1.0.0
 */

/* Base bubble styling */
.hubb-phone-bubble {
    position: fixed;
    z-index: 9998;
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    cursor: pointer;
}

/* Position variations */
.hubb-position-bottom-right {
    bottom: 30px;
    right: 30px;
}

.hubb-position-bottom-left {
    bottom: 30px;
    left: 30px;
}

.hubb-position-top-right {
    top: 180px;
    right: 30px;
}

.hubb-position-top-left {
    top: 180px;
    left: 30px;
}

/* Phone link */
.hubb-phone-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    gap: 10px;
}

/* Phone icon */
.hubb-phone-link i {
    font-size: 18px;
}

/* Phone number text */
.hubb-phone-number,
.hubb-phone-text {
    font-size: 15px;
    font-weight: 600;
    white-space: nowrap;
}

/* Icon only style */
.hubb-style-icon_only {
    padding: 15px;
    border-radius: 50%;
}

.hubb-style-icon_only .hubb-phone-number,
.hubb-style-icon_only .hubb-phone-text {
    display: none;
}

/* Expand on hover style */
.hubb-style-expand_hover {
    padding: 15px;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    overflow: hidden;
}

.hubb-style-expand_hover .hubb-phone-link {
    gap: 0;
}

.hubb-style-expand_hover .hubb-phone-number-hover {
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-size: 15px;
    font-weight: 600;
}

.hubb-style-expand_hover:hover {
    width: auto;
    padding: 12px 20px;
    border-radius: 50px;
}

.hubb-style-expand_hover:hover .hubb-phone-link {
    gap: 10px;
}

.hubb-style-expand_hover:hover .hubb-phone-number-hover {
    max-width: 200px;
    opacity: 1;
    margin-left: 10px;
}

/* Tooltip */
.hubb-phone-tooltip {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: #1e293b;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.hubb-phone-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #1e293b;
}

/* Show tooltip on desktop hover */
@media (min-width: 769px) {
    .hubb-phone-bubble:hover .hubb-phone-tooltip {
        opacity: 1;
    }
}

/* Copied message */
.hubb-phone-copied {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) scale(0.8);
    background: #10b981;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
}

.hubb-phone-copied.show {
    opacity: 1;
    transform: translateX(-50%) scale(1);
}

.hubb-phone-copied::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #10b981;
}

/* Hover effect */
.hubb-phone-bubble:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Mobile specific - remove tooltip, enable direct calling */
@media (max-width: 768px) {
    .hubb-phone-tooltip {
        display: none;
    }
    
    .hubb-phone-bubble {
        bottom: 20px;
        right: 20px;
    }
    
    .hubb-position-bottom-left {
        left: 20px;
    }
    
    .hubb-position-top-right {
        top: 170px;
        right: 20px;
    }
    
    .hubb-position-top-left {
        top: 170px;
        left: 20px;
    }
    
    /* Hide phone number on very small screens for icon+number style */
    .hubb-style-icon_number .hubb-phone-number {
        display: none;
    }
    
    .hubb-style-icon_number {
        padding: 15px;
        border-radius: 50%;
    }
}

/* Accessibility */
.hubb-phone-bubble:focus {
    outline: 3px solid #FFB84D;
    outline-offset: 2px;
}

/* Smooth animations */
@media (prefers-reduced-motion: reduce) {
    .hubb-phone-bubble,
    .hubb-phone-tooltip,
    .hubb-phone-copied,
    .hubb-style-expand_hover .hubb-phone-number-hover {
        transition: none;
    }
}