/* ==========================================================================
   DRIVER APPLICATION FORM — Mobile-first, thumb-friendly
   Inputs: 52-56px height, 44px+ tap targets, full-width mobile button
   ========================================================================== */

.forsage-application-form {
    max-width: 100%;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* --------------------------------------------------------------------------
   SUCCESS / ERROR MESSAGES
   -------------------------------------------------------------------------- */
.forsage-form-success {
    background: #f0fdf4;
    border: none;
    color: #166534;
    padding: 32px 24px;
    border-radius: 14px;
    text-align: center;
    max-width: 100%;
    margin: 0;
}

.forsage-form-success h3 {
    margin: 0 0 8px;
    font-size: 20px;
    font-weight: 600;
}

.forsage-form-success p {
    margin: 0;
    font-size: 15px;
}

.forsage-form-error {
    background: #fef2f2;
    border: none;
    color: #991b1b;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
}

/* --------------------------------------------------------------------------
   FORM SECTIONS — Grouped by spacing, no borders
   -------------------------------------------------------------------------- */
.forsage-form-section {
    background: #f8f8f9;
    border: none;
    border-radius: 14px;
    padding: 24px 20px;
    margin-bottom: 16px;
}

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

.forsage-form-section h4 {
    margin: 0 0 18px;
    padding: 0;
    border-bottom: none;
    color: #1a1a2e;
    font-size: 16px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
}

/* --------------------------------------------------------------------------
   FORM ROWS — Mobile-first single column
   -------------------------------------------------------------------------- */
.forsage-form-row {
    margin-bottom: 16px;
}

.forsage-form-row:last-child {
    margin-bottom: 0;
}

/* Mobile: always single column */
.forsage-form-row-2,
.forsage-form-row-3 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* Desktop: 2-column at 900px+ */
@media (min-width: 900px) {
    .forsage-form-section {
        padding: 28px 28px;
    }
    .forsage-form-row-2 {
        grid-template-columns: 1fr 1fr;
    }
    .forsage-form-row-3 {
        grid-template-columns: 1fr 1fr 1fr;
    }
}

/* --------------------------------------------------------------------------
   FORM FIELDS — Tall inputs (52-56px), thumb-friendly
   -------------------------------------------------------------------------- */
.forsage-form-field {
    min-height: 44px; /* Apple HIG tap target */
}

.forsage-form-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
    line-height: 1.3;
}

.forsage-form-field label .required {
    color: #dc2626;
    margin-left: 2px;
}

.forsage-form-field input,
.forsage-form-field select,
.forsage-form-field textarea {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    border: none;
    border-radius: 12px;
    font-size: 16px; /* Prevents iOS zoom */
    background: #fff;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.08);
    transition: box-shadow 0.15s ease;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}

.forsage-form-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-color: #fff;
    padding-right: 40px;
}

.forsage-form-field input:focus,
.forsage-form-field select:focus,
.forsage-form-field textarea:focus {
    outline: 0;
    box-shadow: 0 0 0 2px #1a1a2e;
}

.forsage-form-field input::placeholder,
.forsage-form-field textarea::placeholder {
    color: #9ca3af;
}

.forsage-form-field input[type="number"] {
    max-width: 100%;
    -moz-appearance: textfield;
    appearance: textfield;
}

.forsage-form-field input[type="number"]::-webkit-inner-spin-button,
.forsage-form-field input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.forsage-form-field textarea {
    height: auto;
    min-height: 100px;
    padding: 14px 16px;
    resize: vertical;
}

/* --------------------------------------------------------------------------
   SUBMIT BUTTON — Full-width mobile, 56px height, rounded
   -------------------------------------------------------------------------- */
.forsage-form-submit {
    padding-top: 24px;
}

.forsage-submit-btn {
    display: block;
    width: 100%;
    height: 56px;
    background: #1a1a2e;
    color: #fff;
    border: none;
    font-size: 17px;
    font-weight: 600;
    border-radius: 14px;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
    letter-spacing: 0;
    -webkit-tap-highlight-color: transparent;
}

.forsage-submit-btn:hover {
    background: #2d2d4a;
}

.forsage-submit-btn:active {
    background: #0f0f1a;
    transform: scale(0.98);
}

/* Desktop: centered button */
@media (min-width: 900px) {
    .forsage-form-submit {
        text-align: center;
    }
    .forsage-submit-btn {
        display: inline-block;
        width: auto;
        min-width: 280px;
        padding: 0 48px;
    }
}

/* --------------------------------------------------------------------------
   QUALIFICATION STATUS — Disqualification message box
   -------------------------------------------------------------------------- */
.forsage-qual-status {
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.5;
}

.forsage-qual-status strong {
    display: block;
    margin-bottom: 8px;
}

.forsage-qual-status ul {
    margin: 0;
    padding: 0 0 0 18px;
}

.forsage-qual-status li {
    margin-bottom: 4px;
}

.forsage-qual-disqualified {
    background: #fef2f2;
    color: #991b1b;
}

.forsage-qual-review {
    background: #fef3c7;
    color: #92400e;
}

/* --------------------------------------------------------------------------
   FIELD HINTS & ERRORS
   -------------------------------------------------------------------------- */
.forsage-field-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #666;
}

.forsage-field-error {
    display: none;
    margin-top: 6px;
    font-size: 12px;
    color: #dc2626;
    font-weight: 500;
}

/* --------------------------------------------------------------------------
   DISABLED BUTTON STATE
   -------------------------------------------------------------------------- */
.forsage-submit-btn.disabled,
.forsage-submit-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    opacity: 0.7;
}

.forsage-submit-btn.disabled:hover,
.forsage-submit-btn:disabled:hover {
    background: #9ca3af;
    transform: none;
}
