/**
 * SMS Send Dialog Styles
 * Modern unified dialog design matching the CFS dialog system
 */

/* SMS Form Container */
.sms-send-form {
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Form Sections */
.sms-form-section {
    margin-bottom: 20px;
}

.sms-form-section:last-of-type {
    margin-bottom: 0;
}

.sms-form-section label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 500;
    font-size: 0.95em;
}

.sms-form-section textarea {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    box-sizing: border-box;
}

.sms-form-section textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.1);
}

/* Results Section */
.sms-results {
    background-color: #f8f9fa;
    border-radius: 6px;
    padding: 12px;
}

/* Tabs */
.sms-tabs {
    display: flex;
    gap: 8px;
    border-bottom: 2px solid #e0e0e0;
    margin-bottom: 12px;
}

.sms-tab-btn {
    background: transparent;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 0.95em;
    font-weight: 500;
    color: #7f8c8d;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s ease;
    position: relative;
}

.sms-tab-btn:hover {
    color: #2c3e50;
    background-color: rgba(0, 0, 0, 0.02);
}

.sms-tab-btn.active {
    color: #3498db;
    border-bottom-color: #3498db;
}

.sms-tab-btn .sms-result-count,
.sms-tab-btn #sms_send_errors_count {
    margin-left: 4px;
    background-color: #ecf0f1;
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
}

.sms-tab-btn.active .sms-result-count,
.sms-tab-btn.active #sms_send_errors_count {
    background-color: #3498db;
    color: white;
}

/* Tab Content */
.sms-tab-content {
    min-height: 100px;
}

.sms-tab-pane {
    display: none;
    animation: fadeIn 0.2s ease;
}

.sms-tab-pane.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.sms-tab-pane p {
    margin: 0;
    line-height: 1.6;
    color: #2c3e50;
}

.sms-tab-pane ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sms-tab-pane li {
    padding: 8px 0;
    border-bottom: 1px solid #ecf0f1;
    color: #555;
    line-height: 1.5;
    font-size: 0.95em;
}

.sms-tab-pane li:last-child {
    border-bottom: none;
}

.sms-tab-pane li:first-child {
    padding-top: 0;
}

/* Button Styles */
.cfs-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    font-size: 0.95em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.cfs-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Primary Button */
.cfs-btn-primary {
    background-color: #3498db;
    color: white;
}

.cfs-btn-primary:hover:not(:disabled) {
    background-color: #2980b9;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.cfs-btn-primary:active:not(:disabled) {
    background-color: #2471a3;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Secondary Button */
.cfs-btn-secondary {
    background-color: #ecf0f1;
    color: #2c3e50;
}

.cfs-btn-secondary:hover:not(:disabled) {
    background-color: #bdc3c7;
}

.cfs-btn-secondary:active:not(:disabled) {
    background-color: #95a5a6;
}

/* Success message styling */
.sms-tab-pane strong[style*="color: #27ae60"] {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background-color: #d5f4e6;
    border-left: 4px solid #27ae60;
    border-radius: 4px;
    margin: 0;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .sms-form-section {
        margin-bottom: 16px;
    }

    .sms-form-section textarea {
        font-size: 16px; /* Prevents zoom on iOS */
    }

    .sms-tabs {
        flex-wrap: wrap;
    }

    .sms-tab-btn {
        flex: 1;
        min-width: 120px;
        padding: 10px 8px;
    }
}
