@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

.contact-sh-form-container {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    max-width: 850px;
    margin: 40px auto;
    padding: 40px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05), 0 5px 15px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(230, 230, 230, 0.8);
    box-sizing: border-box;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-sh-form-container * {
    box-sizing: border-box;
}

/* Responsive Grid layout */
.contact-sh-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 24px;
    row-gap: 20px;
}

/* Full width fields */
.contact-sh-full-width {
    grid-column: span 2;
}

.contact-sh-field-group {
    display: flex;
    flex-direction: column;
}

/* Label Styling */
.contact-sh-label {
    font-size: 0.95rem;
    font-weight: 500;
    color: #1e293b;
    margin-bottom: 8px;
    transition: color 0.2s ease;
}

.required-star {
    color: #ef4444;
    margin-left: 2px;
    font-weight: 700;
}

/* Inputs styling */
.contact-sh-input-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
}

.contact-sh-input-wrapper input[type="text"],
.contact-sh-input-wrapper input[type="email"],
.contact-sh-input-wrapper input[type="tel"],
.contact-sh-input-wrapper select,
.contact-sh-input-wrapper textarea {
    font-family: inherit;
    font-size: 0.95rem;
    padding: 12px 16px;
    color: #334155;
    background-color: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    outline: none;
    transition: all 0.25s ease-in-out;
    width: 100%;
}

.contact-sh-input-wrapper textarea {
    resize: vertical;
    min-height: 100px;
}

/* Input Focus Ring */
.contact-sh-input-wrapper input:focus,
.contact-sh-input-wrapper select:focus,
.contact-sh-input-wrapper textarea:focus {
    background-color: #ffffff;
    border-color: #4f46e5;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.12);
}

/* Error States */
.contact-sh-field-group.has-error .contact-sh-label {
    color: #ef4444;
}

.contact-sh-field-group.has-error input,
.contact-sh-field-group.has-error select,
.contact-sh-field-group.has-error textarea {
    border-color: #fca5a5;
    background-color: #fff5f5;
}

.contact-sh-field-group.has-error input:focus,
.contact-sh-field-group.has-error select:focus,
.contact-sh-field-group.has-error textarea:focus {
    border-color: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.12);
}

.contact-sh-error-msg {
    font-size: 0.8rem;
    color: #ef4444;
    margin-top: 6px;
    font-weight: 500;
    display: none;
    animation: slideDown 0.2s ease-out;
}

/* Radio & Checkbox Choices Styling */
.contact-sh-choices-list {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding: 8px 0;
}

.contact-sh-choice-item {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.contact-sh-choice-item input[type="radio"],
.contact-sh-choice-item input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 1.5px solid #cbd5e1;
    background-color: #f8fafc;
    margin-right: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-grid;
    place-content: center;
    position: relative;
}

.contact-sh-choice-item input[type="radio"] {
    border-radius: 50%;
}

.contact-sh-choice-item input[type="checkbox"] {
    border-radius: 6px;
}

/* Checked styling */
.contact-sh-choice-item input[type="radio"]::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 50%;
    transform: scale(0);
    transition: 0.15s transform ease-in-out;
    background-color: #ffffff;
}

.contact-sh-choice-item input[type="checkbox"]::before {
    content: "";
    width: 10px;
    height: 8px;
    clip-path: polygon(14% 44%, 0 58%, 38% 95%, 100% 16%, 86% 2%, 38% 68%);
    transform: scale(0);
    transition: 0.15s transform ease-in-out;
    background-color: #ffffff;
}

.contact-sh-choice-item input:checked {
    background-color: #4f46e5;
    border-color: #4f46e5;
}

.contact-sh-choice-item input:checked::before {
    transform: scale(1);
}

.contact-sh-choice-item input:focus-visible {
    outline: 2px solid #4f46e5;
    outline-offset: 2px;
}

.contact-sh-choice-text {
    font-size: 0.92rem;
    color: #475569;
    font-weight: 400;
}

/* Submit Container & Button */
.contact-sh-submit-container {
    margin-top: 30px;
    text-align: right;
}

#contact-sh-submit-btn {
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    border: none;
    border-radius: 10px;
    padding: 14px 32px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.3);
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

#contact-sh-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.4);
}

#contact-sh-submit-btn:active {
    transform: translateY(0);
}

#contact-sh-submit-btn:disabled {
    background: #94a3b8;
    box-shadow: none;
    cursor: not-allowed;
    transform: none;
}

/* Spinner SVG classes */
.btn-spinner {
    fill: #ffffff;
}

/* Notices & Alert Styles */
.contact-sh-response-notice {
    margin-top: 24px;
    padding: 16px 20px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.5;
    animation: fadeIn 0.3s ease-out;
}

.contact-sh-response-notice.success {
    background-color: #ecfdf5;
    border: 1px solid #10b981;
    color: #065f46;
}

.contact-sh-response-notice.error {
    background-color: #fef2f2;
    border: 1px solid #ef4444;
    color: #991b1b;
}

/* Keyframes animations */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Mobile responsive fixes */
@media (max-width: 680px) {
    .contact-sh-grid {
        grid-template-columns: 1fr;
    }
    .contact-sh-full-width {
        grid-column: span 1;
    }
    .contact-sh-form-container {
        padding: 24px 16px;
        margin: 20px auto;
    }
    .contact-sh-submit-container {
        text-align: center;
    }
    #contact-sh-submit-btn {
        width: 100%;
    }
}
