/* ===== BASE ===== */
.application-page {
    padding: 48px 0 72px;
}

/* ===== HEADER ===== */
.application-header {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 36px;
}

.application-badge {
    display: inline-block;
    margin-bottom: 16px;
    padding: 6px 16px;
    border-radius: 999px;
    background: #fff0e6;
    color: #FF6711;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.application-header h2 {
    font-size: 38px;
    font-weight: 800;
    color: #2b2118;
    margin: 0 0 14px;
    line-height: 1.15;
}

.application-header p {
    color: #6b6158;
    line-height: 1.65;
    margin: 0;
}

/* ===== CARD ===== */
.application-card {
    max-width: 820px;
    margin: 0 auto;
    background: #fff;
    border-radius: 24px;
    padding: 44px 48px 40px;
    box-shadow: 0 20px 50px rgba(43, 33, 24, 0.08);
}

/* ===== SECTIONS ===== */
.form-section {
    margin: 0 0 34px;
    padding: 0;
    border: 0;
    min-width: 0;
}

.form-section legend {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin: 0 0 20px;
    padding: 0;
    font-size: 20px;
    font-weight: 700;
    color: #2b2118;
}

.form-step {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #FF6711;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
}

/* ===== FIELDS ===== */
.form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.form-group {
    margin: 0;
    min-width: 0;
}

.form-group label,
.upload__title {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #3d342c;
}

.req {
    color: #FF6711;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 12px;
    border: 1.5px solid #e8e1da;
    background: #fff;
    color: #2b2118;
    font-family: inherit;
    font-size: 15px;
    line-height: 1.4;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #b3a9a0;
}

.form-group input:hover,
.form-group textarea:hover {
    border-color: #d8cec4;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #FF6711;
    box-shadow: 0 0 0 4px rgba(255, 103, 17, 0.14);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.form-hint {
    margin: 0 0 10px;
    font-size: 13px;
    line-height: 1.5;
    color: #8a7f75;
}

/* ===== UPLOAD ===== */
.upload + .upload {
    margin-top: 22px;
}

.dropzone {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 22px 20px;
    border: 2px dashed #e0d5ca;
    border-radius: 14px;
    background: #fcfaf8;
    color: #6b6158;
    font-size: 15px;
    text-align: left;
    cursor: pointer;
    transition: border-color .2s ease, background .2s ease;
}

.dropzone:hover,
.dropzone.is-drag {
    border-color: #FF6711;
    background: #fff6f0;
}

.dropzone:focus-within {
    border-color: #FF6711;
    box-shadow: 0 0 0 4px rgba(255, 103, 17, 0.14);
}

/* Сам input занимает всю зону: клик и перетаскивание работают без скриптов */
.dropzone input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.dropzone__icon {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    color: #FF6711;
}

.dropzone__text b {
    color: #FF6711;
    font-weight: 600;
}

.file-list {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.file-list:empty {
    display: none;
}

.file {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px 10px 14px;
    border-radius: 10px;
    background: #f7f3ef;
    font-size: 14px;
}

.file__name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #2b2118;
}

.file__size {
    flex: 0 0 auto;
    color: #8a7f75;
    font-size: 13px;
}

.file__remove {
    flex: 0 0 auto;
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #8a7f75;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}

.file__remove:hover {
    background: #e8e1da;
    color: #2b2118;
}

.file.is-bad {
    background: #fdecec;
}

.file.is-bad .file__size {
    color: #d33b3b;
    font-weight: 600;
}

/* ===== AGREEMENT ===== */
.form-agreement {
    margin-top: 6px;
}

.form-agreement label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    line-height: 1.5;
    color: #6b6158;
    cursor: pointer;
}

.form-agreement input[type="checkbox"] {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin-top: 1px;
    accent-color: #FF6711;
    cursor: pointer;
}

.form-agreement a {
    color: #FF6711;
    text-decoration: underline;
}

/* ===== BUTTON ===== */
.form-submit {
    margin-top: 28px;
}

.form-submit button {
    display: block;
    width: 100%;
    padding: 17px 24px;
    border-radius: 14px;
    border: none;
    background: #FF6711;
    color: #fff;
    font-family: inherit;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s ease, box-shadow .2s ease, transform .1s ease;
}

.form-submit button:hover {
    background: #f05a05;
    box-shadow: 0 10px 25px rgba(255, 103, 17, 0.35);
}

.form-submit button:active {
    transform: translateY(1px);
}

.form-submit button:disabled {
    opacity: .65;
    cursor: progress;
    box-shadow: none;
}

.form-note {
    margin: 14px 0 0;
    text-align: center;
    font-size: 13px;
    color: #8a7f75;
}

/* ===== MODAL ===== */
.custom-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    z-index: 999;
}

.custom-modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(24, 18, 12, 0.55);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.modal-box {
    position: relative;
    background: #fff;
    padding: 36px 32px 30px;
    border-radius: 20px;
    text-align: center;
    z-index: 1;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
}

.modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto 18px;
    border-radius: 50%;
    background: #e8f7ee;
    color: #1fa35a;
}

.modal-box h3 {
    margin: 0 0 10px;
    font-size: 24px;
    color: #2b2118;
}

.modal-box p {
    margin: 0;
    color: #6b6158;
    line-height: 1.5;
}

.modal-box button {
    margin-top: 24px;
    padding: 12px 44px;
    border: none;
    border-radius: 12px;
    background: #FF6711;
    color: #fff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

/* ===== ADAPTIVE ===== */
@media (max-width: 993px) {
    .application-page {
        padding: 20px 0 40px;
    }

    .application-header {
        margin: 0 auto 22px;
    }

    .application-header h2 {
        font-size: 28px;
    }

    .application-header p {
        font-size: 14px;
    }

    .application-card {
        padding: 26px 18px 24px;
        border-radius: 18px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .form-section {
        margin-bottom: 28px;
    }

    .form-section legend {
        font-size: 18px;
    }

    .dropzone {
        padding: 18px 14px;
        font-size: 14px;
    }

    .dropzone__icon {
        width: 34px;
        height: 34px;
    }
}
