/* GimbForms Public Stylesheet - Premium Visual Theme v1.4.2 */

.gimbforms-form-container {
    background-color: #fcfbf4;
    padding: 8px 10px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #0c1c18;
    max-width: 650px;
    margin: 0 auto;
    border-radius: 4px;
}

.gimbforms-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* Sections & Dividers */
.gimbforms-field-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
    padding-bottom: 12px;
}

.gimbforms-field-section:not(:last-of-type)::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background-color: #dce7e3; /* Soft green-tinted divider line */
}

/* Input Fields styling */
.gimbforms-input-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.gimbforms-input-label {
    font-size: 9px;
    line-height: 1.1;
    color: #6f897f;
    font-weight: 400;
    transition: font-weight 0.2s ease;
}

.gimbforms-form input.gimbforms-text-input,
.gimbforms-form textarea.gimbforms-textarea-input {
    border-top: 0;
    border-right: 0;
    border-left: 0;
    border-bottom: 1px solid #4f796c;
    background: transparent;
    background-color: transparent;
    padding: 0 0 1px;
    font-size: 12px;
    line-height: 1.2;
    color: #8c8c8c;
    font-weight: 400;
    outline: none;
    transition: border-bottom-color 0.25s ease, border-bottom-width 0.2s ease, font-weight 0.2s ease;
    border-radius: 0;
    box-shadow: none;
    appearance: none;
}

.gimbforms-form input.gimbforms-text-input:focus,
.gimbforms-form textarea.gimbforms-textarea-input:focus {
    border-bottom-color: #4f796c;
    border-bottom-width: 2px;
    font-weight: 700;
    background: transparent;
    background-color: transparent;
    box-shadow: none;
}

.gimbforms-input-wrapper:focus-within .gimbforms-input-label {
    font-weight: 700;
}

.gimbforms-form input.gimbforms-text-input::placeholder,
.gimbforms-form textarea.gimbforms-textarea-input::placeholder {
    color: #c4d4cf; /* Soft grey/green placeholder */
}

.gimbforms-form textarea.gimbforms-textarea-input {
    resize: vertical;
    font-size: 12px;
    font-family: inherit;
    line-height: 1.4;
}

/* File Upload styling */
.gimbforms-file-input {
    font-size: 14px;
    color: #4f796c;
    padding: 10px 0;
    border-bottom: 1px dashed #c4d4cf;
    cursor: pointer;
}

/* Checkbox (Boolean / Acceptance) styling */
.gimbforms-checkbox-label {
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    font-size: 16px;
    color: #0c1c18;
    user-select: none;
    line-height: 1.4;
}

.gimbforms-checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.gimbforms-custom-checkbox {
    height: 20px;
    width: 20px;
    background-color: transparent;
    border: 2px solid #4f796c;
    border-radius: 4px; /* Square with rounded corners */
    display: inline-block;
    position: relative;
    box-sizing: border-box;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    flex-shrink: 0;
}

.gimbforms-checkbox-label:hover .gimbforms-custom-checkbox {
    border-color: #5ab2a2;
}

.gimbforms-checkbox-label input[type="checkbox"]:checked ~ .gimbforms-custom-checkbox {
    border-color: #4f796c;
    background-color: #4f796c;
}

.gimbforms-checkbox-label input[type="checkbox"]:checked ~ .gimbforms-custom-checkbox::after {
    content: "";
    position: absolute;
    display: block;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Heading Typography */
.gimbforms-section-heading {
    font-size: 16px;
    font-weight: 700;
    color: #0c1c18;
    margin: 0 0 10px 0;
    line-height: 1.4;
}

/* Custom Radio Group styling */
.gimbforms-radio-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.gimbforms-radio-label {
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    font-size: 16px;
    color: #0c1c18;
    user-select: none;
    transition: opacity 0.2s ease;
}

/* Hide Native Radio Buttons */
.gimbforms-radio-label input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

/* Custom Radio Circle Outer */
.gimbforms-custom-radio {
    height: 20px;
    width: 20px;
    background-color: transparent;
    border: 2px solid #4f796c;
    border-radius: 50%;
    display: inline-block;
    position: relative;
    box-sizing: border-box;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    flex-shrink: 0;
}

/* Radio button Hover State */
.gimbforms-radio-label:hover .gimbforms-custom-radio {
    border-color: #5ab2a2;
}

/* Radio Checked State (Filled In Inner Circle) */
.gimbforms-radio-label input[type="radio"]:checked ~ .gimbforms-custom-radio {
    border-color: #4f796c;
}

.gimbforms-radio-label input[type="radio"]:checked ~ .gimbforms-custom-radio::after {
    content: "";
    position: absolute;
    display: block;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #4f796c;
}

.gimbforms-radio-text {
    line-height: 1.2;
}

/* Disabled/Full Option styling */
.gimbforms-radio-label.disabled {
    cursor: not-allowed;
    opacity: 0.4;
}

.gimbforms-radio-label.disabled .gimbforms-custom-radio {
    border-color: #c4d4cf;
}

.gimbforms-full-label {
    color: #c84343;
    font-size: 13px;
    font-weight: bold;
    margin-left: 5px;
}

/* Submit Section & Button */
.gimbforms-submit-section {
    display: flex;
    justify-content: flex-start;
    margin-top: 15px;
}

.gimbforms-submit-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background-color: #5ab2a2; /* Teal background */
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
    padding: 14px 28px;
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    box-shadow: 0 4px 0px #3f8e80, 0 8px 15px rgba(90, 178, 162, 0.2); /* 3D bottom border styling */
    transition: transform 0.1s ease, box-shadow 0.1s ease, background-color 0.25s ease;
    outline: none;
}

.gimbforms-submit-button:hover {
    background-color: #4ca292;
}

.gimbforms-submit-button:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0px #3f8e80, 0 3px 8px rgba(90, 178, 162, 0.2);
}

.gimbforms-submit-arrow {
    --gimbforms-submit-icon-offset-y: 1px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transform: translateY(var(--gimbforms-submit-icon-offset-y));
    transition: transform 0.2s ease;
}

.gimbforms-submit-arrow svg {
    width: 1.25em;
    height: 1.25em;
    display: block;
}

.gimbforms-submit-arrow i {
    display: block;
}

.gimbforms-submit-button:hover .gimbforms-submit-arrow {
    transform: translate(4px, var(--gimbforms-submit-icon-offset-y));
}

/* Message box feedback styling */
.gimbforms-message-box {
    margin-top: 15px;
    font-size: 15px;
    line-height: 1.4;
    padding: 12px;
    border-radius: 4px;
    display: none;
}

.gimbforms-message-box.success {
    display: block;
    background-color: #e6f6f4;
    border: 1px solid #bce6df;
    color: #2b7064;
}

.gimbforms-message-box.error {
    display: block;
    background-color: #fdf2f2;
    border: 1px solid #fde2e2;
    color: #b83c3c;
}

.gimbforms-limit-reached {
    background-color: #fdf2f2;
    border-left: 4px solid #b83c3c;
    padding: 15px;
    color: #b83c3c;
    border-radius: 0 4px 4px 0;
    font-family: sans-serif;
}
