.rfs-apply-page {
    direction: rtl;
    text-align: right;
    background: #f7f3e8;
}

.rfs-apply-hero {
    padding: 108px 0 48px;
    background: linear-gradient(135deg, #f4f0e9 0%, #efe9d7 100%);
    border-bottom: 2px solid #222;
}

.rfs-apply-hero h1 {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    color: #222;
    margin-bottom: 16px;
}

.rfs-apply-intro {
    max-width: 820px;
    color: #555;
    font-size: 16px;
    line-height: 1.95;
}

.rfs-apply-intro p + p {
    margin-top: 12px;
}

.rfs-apply-form-wrap {
    padding: 48px 0 96px;
}

.rfs-apply-form {
    max-width: 880px;
    margin: 0 auto;
}

.rfs-apply-section {
    background: #fff;
    border: 2px solid #222;
    border-radius: 5px;
    box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.08);
    padding: 28px 24px;
    margin-bottom: 24px;
}

.rfs-apply-section h2 {
    font-size: 20px;
    font-weight: 800;
    color: var(--main-color);
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.rfs-apply-field {
    margin-bottom: 18px;
}

.rfs-apply-field label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

.rfs-apply-optional {
    font-weight: 400;
    font-size: 12px;
    color: #888;
}

.rfs-apply-field > label.rfs-required::before,
.rfs-apply-field:has(> input[required], > textarea[required], > select[required]) > label:first-of-type::before,
.rfs-apply-field:has(.rfs-apply-options input[required]) > label:first-of-type::before {
    content: '*';
    color: #e24f35;
    margin-left: 4px;
}

.rfs-apply-field input[type="text"],
.rfs-apply-field input[type="email"],
.rfs-apply-field input[type="tel"],
.rfs-apply-field input[type="url"],
.rfs-apply-field input[type="file"],
.rfs-apply-field select,
.rfs-apply-field textarea {
    width: 100%;
    border: 2px solid #333;
    border-radius: 4px;
    padding: 12px 14px;
    font-size: 15px;
    font-family: inherit;
    background: #fff;
    box-sizing: border-box;
}

.rfs-apply-field textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.75;
}

.rfs-apply-field input:focus,
.rfs-apply-field select:focus,
.rfs-apply-field textarea:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(226, 79, 53, 0.12);
}

.rfs-apply-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.rfs-apply-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 15px;
    line-height: 1.7;
    color: #333;
}

.rfs-apply-option input {
    margin-top: 5px;
    flex-shrink: 0;
}

.rfs-apply-hint {
    font-size: 13px;
    color: #777;
    margin: 8px 0 14px;
    line-height: 1.8;
}

.rfs-apply-hint-tag {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.5;
    color: #e24f35;
    background: rgba(226, 79, 53, 0.1);
    vertical-align: middle;
}

.rfs-apply-notice {
    font-size: 13px;
    color: #666;
    margin: 10px 0 0;
    line-height: 1.85;
    padding: 10px 12px;
    background: rgba(226, 79, 53, 0.06);
    border-right: 3px solid #e24f35;
    border-radius: 4px;
}

.rfs-apply-notice strong {
    color: #e24f35;
}

.rfs-apply-conditional {
    display: none;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed #ccc;
}

.rfs-apply-conditional.is-visible {
    display: block;
}

.rfs-apply-member-card {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 16px;
    margin-bottom: 12px;
    background: #fafafa;
}

.rfs-apply-member-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.rfs-apply-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border: 2px solid #333;
    background: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    border-radius: 4px;
}

.rfs-apply-btn-secondary:hover {
    background: #f4f0e9;
}

.rfs-apply-alert {
    display: none;
    margin-bottom: 20px;
    padding: 14px 18px;
    border: 2px solid transparent;
    font-size: 15px;
    line-height: 1.8;
    border-radius: 4px;
}

.rfs-apply-alert.is-visible {
    display: block;
}

.rfs-apply-alert--success {
    background: #ecfdf5;
    border-color: #059669;
    color: #065f46;
}

.rfs-apply-alert--error {
    background: #fef2f2;
    border-color: #dc2626;
    color: #991b1b;
}

.rfs-apply-submit-wrap {
    text-align: center;
    margin-top: 8px;
}

.rfs-apply-loading {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}

.rfs-apply-loading.is-visible {
    display: flex;
}

.rfs-apply-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 768px) {
    .rfs-apply-grid-2 {
        grid-template-columns: 1fr;
    }
}

.rfs-apply-input-narrow {
    max-width: 160px;
}

.rfs-apply-member-title {
    margin: 0 0 12px;
    font-size: 15px;
    font-weight: 700;
    color: #e24f35;
}

.rfs-apply-project-links {
    padding-top: 4px;
    border-top: 1px dashed #ddd;
}
