/* Widget Container */
.dd-sms-widget-container {
    --dd-btn-color: #0073aa;
    position: fixed;
    bottom: 20px;
    z-index: 99999;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.dd-sms-pos-left {
    left: 20px;
}

.dd-sms-pos-right {
    right: 20px;
}

/* Trigger Button */
.dd-sms-trigger-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--dd-btn-color, #0073aa);
    color: #ffffff !important;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    border: none;
    outline: none;
}

.dd-sms-trigger-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
    color: #ffffff !important;
}

.dd-sms-trigger-btn svg {
    width: 20px;
    height: 20px;
    margin-right: 8px;
}

.dd-sms-btn-text {
    font-size: 16px;
    font-weight: 600;
}

/* Popup Modal */
.dd-sms-widget-modal {
    position: absolute;
    bottom: calc(100% + 15px);
    width: var(--dd-widget-width, 280px);
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: opacity 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2), visibility 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2), transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2);
    transform-origin: bottom center;
    overflow: hidden;
    max-height: var(--dd-widget-height, 400px);
    display: flex;
    flex-direction: column;
}

.dd-sms-pos-left .dd-sms-widget-modal {
    left: 0;
    transform-origin: bottom left;
}

.dd-sms-pos-right .dd-sms-widget-modal {
    right: 0;
    transform-origin: bottom right;
}

/* Modal Open State */
.dd-sms-widget-container.is-open .dd-sms-widget-modal {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* Modal Header */
.dd-sms-modal-header {
    background-color: var(--dd-btn-color, #0073aa);
    color: #ffffff;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dd-sms-modal-header h4 {
    margin: 0;
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
}

.dd-sms-close-btn {
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}

/* Modal Body */
.dd-sms-modal-body {
    padding: 0;
    overflow-y: auto;
}

.dd-sms-location-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.dd-sms-location-list li {
    border-bottom: 1px solid #f0f0f0;
}

.dd-sms-location-list li:last-child {
    border-bottom: none;
}

.dd-sms-location-link {
    display: block;
    padding: 15px 20px;
    text-decoration: none !important;
    color: #333333;
    transition: background-color 0.2s ease;
}

.dd-sms-location-link:hover, .dd-sms-location-link:focus {
    background-color: #f9f9f9;
}

.dd-sms-loc-name {
    display: block;
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 3px;
    color: #111;
}

.dd-sms-loc-phone {
    display: block;
    font-size: 13px;
    color: #666;
}

/* Responsiveness adjustments */
@media (max-width: 480px) {
    .dd-sms-widget-modal {
        width: calc(100vw - 40px); /* Fill most of screen width on narrow devices */
    }
}
