/* ============================================================================
   HR ZONE — Form Styles
   Form elements, dropdowns, landing page, input icons, password toggle,
   toggle switches, recurrence, form lock overlay
   ============================================================================ */

/* --- Form Elements --- */
.form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-dark);
}

.form-input, .form-select {
    width: 100%;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid #d1d5db;
    font-size: 14px;
    background: #fff;
    box-sizing: border-box;
    transition: all 0.25s ease;
}

.form-input:disabled, .form-select:disabled {
    background-color: #f3f4f6;
}

select.form-input,
.form-select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    cursor: pointer;
    color: #374151;
    background-color: #f3f4f6;
    background-image: linear-gradient(180deg, rgba(249, 250, 251, 0.98), rgba(243, 244, 246, 0.98)), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.6' d='M5.5 7.5 10 12l4.5-4.5'/%3e%3c/svg%3e");
    background-position: 0 0, right 1.35rem center;
    background-repeat: no-repeat;
    background-size: 100% 100%, 1.1em 1.1em;
    padding-right: 3rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

select.form-input:hover,
.form-select:hover {
    border-color: #cbd5e1;
}

select.form-input:disabled,
.form-select:disabled {
    cursor: not-allowed;
    color: #94a3b8;
    background-color: #f8fafc;
    background-image: linear-gradient(180deg, rgba(248, 250, 252, 0.98), rgba(241, 245, 249, 0.98)), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.6' d='M5.5 7.5 10 12l4.5-4.5'/%3e%3c/svg%3e");
}

select.form-input::-ms-expand,
.form-select::-ms-expand {
    display: none;
}

.form-input:focus, .form-select:focus {
    outline: none;
    border-color: var(--brand-red);
    box-shadow: 0 0 0 3px rgba(216, 31, 38, 0.2);
}

.form-trainee {
    border: 1px dashed #d1d5db;
    background: #f9fafb;
    border-radius: 8px;
    padding: 12px;
    margin: 10px 0;
}

/* --- Form Dropdowns --- */
select.form-input:invalid,
.form-select:invalid,
select.form-input option[value=""],
.form-select option[value=""] {
    color: #9ca3af !important;
}

select.form-input option,
.form-select option {
    color: var(--text-dark);
}

/* --- Input with Icon --- */
.input-with-icon {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    font-size: 14px;
    pointer-events: none;
}

.form-input-landing {
    width: 100%;
    padding: 12px 16px 12px 40px;
    padding-right: 40px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    font-size: 14px;
    background: #fff;
    box-sizing: border-box;
    transition: all 0.25s ease;
}

.form-input-landing:focus {
    outline: none;
    border-color: var(--brand-red);
    box-shadow: 0 0 0 3px rgba(216, 31, 38, 0.2);
}

/* --- Password Toggle --- */
.password-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    cursor: pointer;
    z-index: 10;
}

.password-toggle:hover {
    color: var(--brand-red);
}

.password-input-icon {
    padding-right: 60px;
}

/* --- Toggle Switch --- */
.toggle-switch {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.toggle-switch-input {
    display: none;
}

.toggle-switch-label {
    position: relative;
    width: 44px;
    height: 24px;
    background-color: #cbd5e1;
    border-radius: 9999px;
    transition: background-color 0.2s ease;
}

.toggle-switch-label::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.2s ease;
}

.toggle-switch-input:checked + .toggle-switch-label {
    background-color: var(--brand-red);
}

.toggle-switch-input:checked + .toggle-switch-label::after {
    transform: translateX(20px);
}

/* --- Recurrence Toggle --- */
#recurrence-check:checked ~ .toggle-bg {
    background-color: #d81f26;
}

#recurrence-check:checked ~ .dot {
    transform: translateX(100%);
}

/* --- Form Lock Overlay --- */
.form-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(2px);
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    padding: 2rem;
    border: 3px solid #f87171;
    text-align: center;
}
