﻿/* ========================================
   ПРОВЕРКА ПЕРЕД ОТПРАВКОЙ
======================================== */

.presend-page {
    min-height: calc(100vh - 160px);
    padding: 42px 28px 60px;
    background: #f5f7fa;
}


/* ========================================
   ОСНОВНОЙ КОНТЕЙНЕР
======================================== */

.presend-container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
}


/* ========================================
   ЗАГОЛОВОК СТРАНИЦЫ
======================================== */

.presend-header {
    margin-bottom: 32px;
    text-align: center;
}

    .presend-header h1 {
        margin: 0 0 10px;
        font-size: 32px;
        line-height: 1.2;
        font-weight: 700;
        color: #245a9f;
    }

    .presend-header p {
        max-width: 820px;
        margin: 0 auto;
        font-size: 15px;
        line-height: 1.55;
        color: #626d79;
    }


/* ========================================
   КАРТОЧКА ДОКУМЕНТА
======================================== */

.presend-file-card {
    max-width: 820px;
    margin: 0 auto;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #e0e5eb;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}


/* ========================================
   ЗАГОЛОВОК КАРТОЧКИ
======================================== */

.presend-file-title {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
}

    .presend-file-title > i {
        width: 44px;
        height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        border-radius: 9px;
        background: #eef4fb;
        color: #2d61a4;
        font-size: 21px;
    }

    .presend-file-title > div {
        min-width: 0;
    }

    .presend-file-title h2 {
        margin: 0 0 3px;
        font-size: 19px;
        line-height: 1.25;
        color: #242424;
    }

    .presend-file-title p {
        margin: 0;
        font-size: 13px;
        line-height: 1.4;
        color: #737d88;
    }


/* ========================================
   ЗОНА ВЫБОРА ФАЙЛА
======================================== */

.presend-upload-zone {
    min-height: 165px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 22px;
    border: 2px dashed #b7c6d9;
    border-radius: 10px;
    background: #fafcff;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

    .presend-upload-zone:hover {
        border-color: #2d61a4;
        background: #f3f7fc;
    }

    .presend-upload-zone.drag-over {
        border-color: #2d61a4;
        background: #eaf2fb;
        transform: scale(1.01);
    }

    .presend-upload-zone > i {
        margin-bottom: 12px;
        font-size: 31px;
        color: #2d61a4;
    }

    .presend-upload-zone strong {
        display: block;
        margin-bottom: 5px;
        font-size: 15px;
        color: #2b2b2b;
    }

    .presend-upload-zone span {
        font-size: 13px;
        color: #7c8792;
    }


/* ========================================
   ВЫБРАННЫЙ ФАЙЛ
======================================== */

.presend-selected-file {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 15px;
    padding: 12px 14px;
    background: #f5f8fc;
    border: 1px solid #dce5ef;
    border-radius: 8px;
}

    .presend-selected-file > div {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 3px;
    }

    .presend-selected-file strong {
        overflow: hidden;
        font-size: 14px;
        font-weight: 600;
        color: #303030;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .presend-selected-file span {
        font-size: 12px;
        color: #747f8a;
    }

    .presend-selected-file button {
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        border: none;
        border-radius: 6px;
        background: transparent;
        color: #6d7680;
        cursor: pointer;
        transition: background-color 0.2s ease, color 0.2s ease;
    }

        .presend-selected-file button:hover {
            background: #fbecec;
            color: #c44242;
        }


/* ========================================
   КНОПКА ПРОВЕРКИ
======================================== */

.presend-actions {
    display: flex;
    justify-content: center;
    margin-top: 28px;
}

#checkPreSendButton, #buildXRayButton {
    min-width: 270px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 13px 25px;
    border: none;
    border-radius: 8px;
    background: #2d61a4;
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(45, 97, 164, 0.22);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

    #checkPreSendButton:hover:not(:disabled),
    #buildXRayButton:hover:not(:disabled) {
        background: #244f88;
        transform: translateY(-1px);
        box-shadow: 0 6px 16px rgba(45, 97, 164, 0.26);
    }

    #checkPreSendButton:disabled,
    #buildXRayButton:disabled {
        background: #aeb8c5;
        color: #eef0f2;
        cursor: not-allowed;
        box-shadow: none;
    }


/* ========================================
   РЕЗУЛЬТАТЫ ПРОВЕРКИ
======================================== */

.presend-results {
    margin-top: 38px;
    padding-bottom: 30px;
}


/* ========================================
   ЗАГОЛОВОК РЕЗУЛЬТАТОВ
======================================== */

.presend-results-header {
    margin-bottom: 20px;
}

    .presend-results-header h2 {
        margin: 0 0 5px;
        font-size: 27px;
        line-height: 1.25;
        font-weight: 700;
        color: #1f4f8f;
    }

    .presend-results-header p {
        margin: 0;
        font-size: 15px;
        line-height: 1.5;
        color: #4f5965;
    }


/* ========================================
   СВОДКА
======================================== */

.presend-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 30px;
}

.presend-summary-card {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 13px 14px;
    background: #ffffff;
    border: 1px solid #dfe5eb;
    border-radius: 10px;
    box-shadow: 0 3px 9px rgba(0, 0, 0, 0.045);
}

    .presend-summary-card > i {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        border-radius: 8px;
        background: #eef4fb;
        color: #2d61a4;
        font-size: 16px;
    }

    .presend-summary-card > div {
        min-width: 0;
        display: flex;
        flex-direction: column;
    }

    .presend-summary-card strong {
        font-size: 21px;
        line-height: 1.1;
        font-weight: 700;
        color: #20252b;
    }

    .presend-summary-card span {
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        font-weight: 500;
        color: #46515d;
    }


/* ========================================
   ДИАГНОСТИЧЕСКАЯ КАРТОЧКА
======================================== */

.presend-status-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 18px 20px;
    background: #ffffff;
    border: 1px solid #dfe6df;
    border-radius: 10px;
    box-shadow: 0 3px 11px rgba(0, 0, 0, 0.04);
}

    .presend-status-card > i {
        margin-top: 1px;
        font-size: 24px;
        color: #458552;
    }

    .presend-status-card > div {
        min-width: 0;
    }

    .presend-status-card strong {
        display: block;
        margin-bottom: 4px;
        font-size: 16px;
        color: #252b31;
    }

    .presend-status-card span {
        font-size: 14px;
        line-height: 1.5;
        color: #5d6771;
    }


/* ========================================
   БУДУЩИЕ КАРТОЧКИ НАЙДЕННЫХ ЭЛЕМЕНТОВ
======================================== */

.presend-findings {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.presend-finding-card {
    padding: 20px 22px;
    background: #ffffff;
    border: 1px solid #d7dde5;
    border-radius: 10px;
    box-shadow: 0 3px 11px rgba(0, 0, 0, 0.05);
}

.presend-finding-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 14px;
}

    .presend-finding-header strong {
        font-size: 18px;
        line-height: 1.35;
        font-weight: 700;
        color: #1d2329;
    }

.presend-finding-badge {
    flex-shrink: 0;
    padding: 6px 11px;
    border-radius: 20px;
    background: #eaf2fb;
    color: #245a9f;
    font-size: 13px;
    line-height: 1.25;
    font-weight: 700;
}


/* ========================================
   СКРЫТИЕ
======================================== */

.hidden {
    display: none !important;
}


/* ========================================
   АДАПТИВ — НОУТБУК
======================================== */

@media (max-width: 1200px) {

    .presend-container {
        max-width: 1040px;
    }

    .presend-summary {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}


/* ========================================
   АДАПТИВ — ПЛАНШЕТ
======================================== */

@media (max-width: 850px) {

    .presend-page {
        padding: 32px 18px 48px;
    }

    .presend-header h1 {
        font-size: 28px;
    }

    .presend-file-card {
        max-width: 100%;
    }
}


/* ========================================
   АДАПТИВ — ТЕЛЕФОН
======================================== */

@media (max-width: 600px) {

    .presend-page {
        padding: 26px 14px 42px;
    }

    .presend-file-card {
        padding: 20px;
    }

    .presend-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .presend-finding-card {
        padding: 18px;
    }

    .presend-finding-header {
        flex-direction: column;
    }

    #checkPreSendButton {
        width: 100%;
        min-width: 0;
    }
}


/* ========================================
   МЕТАДАННЫЕ ДОКУМЕНТА
======================================== */

.presend-metadata-card .presend-finding-header {
    margin-bottom: 18px;
}

.presend-metadata-properties {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 18px;
}

.presend-metadata-property {
    min-width: 0;
    padding: 12px 14px;
    background: #f7f9fc;
    border: 1px solid #e3e8ef;
    border-radius: 8px;
}

.presend-metadata-property-label {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    line-height: 1.3;
    font-weight: 700;
    color: #66717d;
}

.presend-metadata-property-value {
    overflow-wrap: anywhere;
    font-size: 15px;
    line-height: 1.45;
    font-weight: 500;
    color: #20262d;
}

.presend-metadata-help {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-top: 16px;
    padding: 13px 15px;
    background: #f2f6fb;
    border: 1px solid #dce7f3;
    border-radius: 8px;
}

    .presend-metadata-help > i {
        margin-top: 2px;
        flex-shrink: 0;
        color: #2d61a4;
        font-size: 15px;
    }

    .presend-metadata-help strong {
        display: block;
        margin-bottom: 3px;
        font-size: 13px;
        line-height: 1.35;
        color: #2b4f7c;
    }

    .presend-metadata-help p {
        margin: 0;
        font-size: 13px;
        line-height: 1.5;
        color: #566473;
    }

@media (max-width: 700px) {
    .presend-metadata-properties {
        grid-template-columns: 1fr;
    }
}
/* ========================================
   ИНФОРМАЦИОННЫЙ БЛОК / SEO
======================================== */

.presend-info {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 46px;
}

.presend-info-item {
    padding: 22px 24px;
    background: #ffffff;
    border: 1px solid #e0e5eb;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.045);
}

    .presend-info-item h2 {
        margin: 0 0 10px;
        font-size: 18px;
        line-height: 1.35;
        font-weight: 700;
        color: #245a9f;
    }

    .presend-info-item p {
        margin: 0;
        font-size: 14px;
        line-height: 1.65;
        color: #596572;
        text-align: justify;
        text-justify: inter-word;
        hyphens: auto;
    }


/* ========================================
   SEO-БЛОК — ПЛАНШЕТ
======================================== */

@media (max-width: 850px) {

    .presend-info {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-top: 38px;
    }
}


/* ========================================
   SEO-БЛОК — ТЕЛЕФОН
======================================== */

@media (max-width: 600px) {

    .presend-info {
        margin-top: 32px;
    }

    .presend-info-item {
        padding: 18px 20px;
    }

        .presend-info-item h2 {
            font-size: 17px;
        }

        .presend-info-item p {
            font-size: 13.5px;
            text-align: left;
        }
}