/**
 * KOMPASS360° Contact Form Widget Styles
 *
 * @package KOMPASS360
 * @since 1.2.0
 */

/* ========================================
   FORM CONTAINER
   ======================================== */
.k360-contact-form {
    background: #ffffff;
    border-radius: 32px;
    padding: 48px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    font-family: 'Nunito', sans-serif;
    position: relative;
}

/* ========================================
   FORM HEADER
   ======================================== */
.k360-form-header {
    margin-bottom: 32px;
}

.k360-form-header h3 {
    font-family: 'Nunito', sans-serif;
    font-size: 24px;
    font-weight: 800;
    margin: 0 0 8px 0;
    color: #000000;
}

.k360-form-header p {
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    color: #666666;
    margin: 0;
    line-height: 1.6;
}

/* ========================================
   QUICK OPTIONS (INTEREST)
   ======================================== */
.k360-quick-options {
    margin-bottom: 32px;
}

.k360-quick-options h4 {
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #666666;
    margin: 0 0 12px 0;
}

.k360-quick-option-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.k360-contact-form .k360-quick-option-buttons button.k360-quick-option {
    display: inline-block;
    padding: 10px 18px;
    border: 2px solid #E8E8E8;
    border-radius: 25px;
    background: white;
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 14px;
    line-height: 1.2;
    color: #666666;
    cursor: pointer;
    transition: all 0.3s ease;
    /* Reset button defaults */
    appearance: none;
    -webkit-appearance: none;
    width: auto;
    height: auto;
    min-width: 0;
    min-height: 0;
    box-shadow: none;
    text-transform: none;
    letter-spacing: normal;
    margin: 0;
    text-decoration: none;
}

.k360-contact-form .k360-quick-option-buttons button.k360-quick-option:hover,
.k360-contact-form .k360-quick-option-buttons button.k360-quick-option.active {
    border-color: #FF008B;
    color: #FF008B;
    background: rgba(255, 0, 139, 0.05);
    transform: none;
}

/* ========================================
   FORM LAYOUT
   ======================================== */
.k360-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.k360-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.k360-form-group {
    display: flex;
    flex-direction: column;
}

.k360-form-group.k360-full-width {
    grid-column: 1 / -1;
}

/* ========================================
   FORM FIELDS
   ======================================== */
.k360-form-group label {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 8px;
    color: #000000;
}

.k360-required {
    color: #FF008B;
}

.k360-form-group input,
.k360-form-group select,
.k360-form-group textarea {
    padding: 16px 20px;
    border: 2px solid #E8E8E8;
    border-radius: 14px;
    font-size: 16px;
    font-family: 'Nunito', sans-serif;
    transition: all 0.3s ease;
    background: #FAFAFA;
    color: #000000;
    width: 100%;
    box-sizing: border-box;
}

.k360-form-group input::placeholder,
.k360-form-group textarea::placeholder {
    color: #999999;
}

.k360-form-group input:focus,
.k360-form-group select:focus,
.k360-form-group textarea:focus {
    outline: none;
    border-color: #FF008B;
    background: white;
    box-shadow: 0 0 0 4px rgba(255, 0, 139, 0.1);
}

.k360-form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23666666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 18px;
    padding-right: 48px;
    cursor: pointer;
}

.k360-form-group textarea {
    min-height: 150px;
    resize: vertical;
    line-height: 1.6;
}

/* Input validation states */
.k360-form-group input:invalid:not(:placeholder-shown),
.k360-form-group textarea:invalid:not(:placeholder-shown) {
    border-color: #e74c3c;
}

/* ========================================
   CHECKBOX GROUP
   ======================================== */
.k360-checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.k360-checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    min-width: 20px;
    margin-top: 2px;
    accent-color: #FF008B;
    cursor: pointer;
}

.k360-checkbox-group label {
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    color: #666666;
    font-weight: 400;
    margin-bottom: 0;
    line-height: 1.6;
}

.k360-checkbox-group label a {
    color: #FF008B;
    text-decoration: none;
}

.k360-checkbox-group label a:hover {
    text-decoration: underline;
}

/* ========================================
   SUBMIT BUTTON
   ======================================== */
.k360-form-submit {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 8px;
}

.k360-form-submit button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 200px;
    padding: 16px 32px;
    background: linear-gradient(135deg, #FF9900 0%, #FF008B 100%);
    color: #ffffff;
    border: none;
    border-radius: 30px;
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 30px rgba(255, 0, 139, 0.3);
}

.k360-form-submit button:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(255, 0, 139, 0.4);
}

.k360-form-submit button:active {
    transform: translateY(-1px);
}

.k360-form-submit button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.k360-btn-icon {
    transition: transform 0.3s ease;
}

.k360-form-submit button:hover .k360-btn-icon {
    transform: translateX(3px) translateY(-3px);
}

.k360-form-note {
    font-family: 'Nunito', sans-serif;
    font-size: 13px;
    color: #666666;
}

/* Loading State */
.k360-spinner {
    width: 20px;
    height: 20px;
    animation: k360-spin 1s linear infinite;
}

@keyframes k360-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.k360-form-submit button.loading .k360-btn-text,
.k360-form-submit button.loading .k360-btn-icon {
    display: none;
}

.k360-form-submit button.loading .k360-btn-loading {
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
}

/* ========================================
   MESSAGES
   ======================================== */
.k360-form-message {
    padding: 16px 20px;
    border-radius: 12px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 600;
    margin-top: 8px;
}

.k360-form-message.error {
    background: rgba(231, 76, 60, 0.1);
    color: #c0392b;
    border: 1px solid rgba(231, 76, 60, 0.2);
}

.k360-form-message.success {
    background: rgba(39, 174, 96, 0.1);
    color: #27ae60;
    border: 1px solid rgba(39, 174, 96, 0.2);
}

/* ========================================
   SUCCESS STATE
   ======================================== */
.k360-form-success {
    text-align: center;
    padding: 60px 40px;
}

.k360-success-icon {
    margin-bottom: 24px;
}

.k360-success-icon svg {
    color: #27ae60;
}

.k360-success-icon svg circle {
    stroke: #27ae60;
}

.k360-success-icon svg polyline {
    stroke: #27ae60;
}

.k360-form-success h3 {
    font-family: 'Nunito', sans-serif;
    font-size: 28px;
    font-weight: 800;
    color: #000000;
    margin: 0 0 16px 0;
}

.k360-form-success p {
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    color: #666666;
    line-height: 1.7;
    margin: 0;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .k360-contact-form {
        padding: 32px 24px;
        border-radius: 24px;
    }

    .k360-form-row {
        grid-template-columns: 1fr;
    }

    .k360-form-submit {
        flex-direction: column;
        align-items: stretch;
    }

    .k360-form-submit button {
        width: 100%;
        min-width: auto;
    }

    .k360-form-note {
        text-align: center;
    }

    .k360-quick-option-buttons {
        gap: 8px;
    }

    .k360-contact-form .k360-quick-option-buttons button.k360-quick-option {
        padding: 8px 14px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .k360-contact-form {
        padding: 24px 20px;
    }

    .k360-form-header h3 {
        font-size: 20px;
    }

    .k360-form-group input,
    .k360-form-group select,
    .k360-form-group textarea {
        padding: 14px 16px;
        font-size: 15px;
    }

    .k360-form-submit button {
        padding: 14px 24px;
        font-size: 15px;
    }

    .k360-form-success {
        padding: 40px 20px;
    }

    .k360-form-success h3 {
        font-size: 24px;
    }
}