/* Styles for Tuta Admin Web Chat Settings Page */

/* Card style copied directly from admin.php conversations tab */
.wrap .tab-content .card,
.wrap .tuta-settings-card,
.card.tuta-settings-card {
    padding: 24px;
    margin: 20px 0;
    background: #fff;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
    border: 1px solid #ccd0d4;
    box-sizing: border-box;
    min-width: unset;
    max-width: none;
    position: relative;
    border-radius: 0;
    width: 100%;
}

/* Rest of form styling */
.tuta-tab-intro {
    font-size: 14px;
    color: #50575e;
    margin-bottom: 25px;
}

/* Form layout */
.form-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 15px;
    margin-top: 0;
}

.form-table th {
    width: 220px;
    padding: 15px 20px 15px 0;
    vertical-align: top;
    font-weight: 600;
}

.form-table td {
    padding: 15px 0;
    vertical-align: top;
}

.setting-description {
    color: #646970;
    font-size: 13px;
    margin: 5px 0 10px 0;
    line-height: 1.5;
}

/* Form controls */
.form-table input[type="text"],
.form-table select,
.form-table textarea {
    min-width: 350px;
    max-width: 100%;
}

.form-table select {
    height: 30px;
    padding: 0 24px 0 8px;
}

/* Color picker improvements */
.wp-picker-container {
    margin-top: 5px;
}

/* Welcome message textarea */
#tuta_web_chat_welcome_message {
    height: 80px;
    margin-top: 5px;
    padding: 8px 10px;
    line-height: 1.4;
    width: 100%;
    max-width: 800px;
}

/* Enhanced submit button */
.submit {
    padding: 20px 0 10px 0;
    margin-top: 10px;
    display: flex;
    align-items: center;
    border-top: 1px solid #f0f0f1;
}

#tuta-save-web-chat {
    min-width: 120px;
    padding: 5px 15px;
    height: auto;
    line-height: 2;
    font-size: 14px;
}

.spinner {
    margin-left: 15px;
}

#tuta-web-chat-save-result {
    margin-left: 15px;
    font-weight: 500;
}

/* Switch control styles */
.tuta-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
    vertical-align: middle;
    margin-right: 10px;
}

.tuta-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.tuta-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.tuta-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

input:checked + .tuta-slider {
    background-color: #2196F3;
}

input:checked + .tuta-slider:before {
    transform: translateX(26px);
}

/* Responsive adjustments */
@media screen and (max-width: 782px) {
    .form-table {
        border-spacing: 0 15px;
    }

    .form-table input[type="text"],
    .form-table select,
    .form-table textarea {
        min-width: 250px;
        width: 100%;
    }

    .form-table th {
        width: 100%;
        display: block;
        padding-bottom: 0;
    }

    .form-table td {
        width: 100%;
        display: block;
        padding-top: 5px;
    }

    .tuta-settings-card,
    .card {
        padding: 20px;
    }

    .setting-description {
        margin-bottom: 8px;
    }

    .tuta-tab-intro {
        margin-bottom: 15px;
    }

    .submit {
        flex-wrap: wrap;
    }

    #tuta-save-web-chat {
        width: 100%;
        margin-bottom: 10px; /* Add some space below button on mobile */
    }

    .spinner,
    #tuta-web-chat-save-result {
        width: 100%;
        margin-left: 0;
        text-align: center; /* Center spinner and result message */
        margin-bottom: 10px;
    }
} 