/* ============================================================
   STEP 5 - RIEPILOGO E PAGAMENTO
   ============================================================ */

/* ------------------------------------------------------------
   SEZIONI RIEPILOGO
   ------------------------------------------------------------ */

.preventivo-page .summary-section {
    margin-top: 30px;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 14px;
}

.preventivo-page .summary-section:first-of-type {
    margin-top: 0;
}


/* ------------------------------------------------------------
   HEADER SEZIONE
   ------------------------------------------------------------ */

.preventivo-page .summary-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    margin-bottom: 22px;
    padding-bottom: 15px;

    border-bottom: 1px solid #eeeeee;
}

.preventivo-page .summary-section-header h3 {
    margin: 0 0 5px;

    font-size: 1.15rem;
    font-weight: 700;

    color: #212529;
}

.preventivo-page .summary-section-header p {
    margin: 0;

    font-size: 0.9rem;
    color: #6c757d;
}

.preventivo-page .summary-section-header > i {
    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 10px;

    background: #f1f3f5;

    font-size: 1.25rem;
    color: #495057;
}


/* ------------------------------------------------------------
   SINGOLO DATO
   ------------------------------------------------------------ */

.preventivo-page .summary-item {
    min-height: 68px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 12px 14px;

    background: #f8f9fa;

    border: 1px solid #e9ecef;
    border-radius: 10px;
}

.preventivo-page .summary-label {
    display: block;

    margin-bottom: 5px;

    font-size: 0.78rem;
    font-weight: 600;

    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.preventivo-page .summary-item strong {
    display: block;

    font-size: 0.95rem;
    font-weight: 600;

    color: #212529;

    word-break: break-word;
}


/* ------------------------------------------------------------
   DISPENSA
   ------------------------------------------------------------ */

.preventivo-page .dispensa-summary {
    padding: 18px;

    background: #f8f9fa;

    border: 1px solid #e9ecef;
    border-radius: 12px;
}


/* ------------------------------------------------------------
   FILE PDF
   ------------------------------------------------------------ */

.preventivo-page .dispensa-summary-file {
    display: flex;
    align-items: center;

    gap: 12px;

    padding-bottom: 15px;

    border-bottom: 1px solid #e5e7eb;
}

.preventivo-page .dispensa-summary-file > i {
    width: 45px;
    height: 45px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 10px;

    background: #ffffff;

    font-size: 1.5rem;
    color: #dc3545;

    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
}

.preventivo-page .dispensa-summary-file > div {
    min-width: 0;
}

.preventivo-page .dispensa-summary-file strong {
    display: block;

    font-size: 0.95rem;
    font-weight: 700;

    color: #212529;

    word-break: break-word;
}

.preventivo-page .dispensa-summary-file span {
    display: block;

    margin-top: 3px;

    font-size: 0.82rem;

    color: #6c757d;
}


/* ------------------------------------------------------------
   CONTEGGIO PAGINE
   ------------------------------------------------------------ */

.preventivo-page .dispensa-pages-summary {
    display: grid;

    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 12px;

    margin-top: 18px;
}

.preventivo-page .page-count-box {
    display: flex;
    align-items: center;

    gap: 10px;

    padding: 13px 14px;

    background: #ffffff;

    border: 1px solid #e9ecef;
    border-radius: 10px;
}

.preventivo-page .page-count-box i {
    font-size: 1.15rem;

    color: #495057;
}

.preventivo-page .page-count-box span {
    flex: 1;

    font-size: 0.85rem;

    color: #495057;
}

.preventivo-page .page-count-box strong {
    font-size: 1rem;
    font-weight: 700;

    color: #212529;
}


/* ------------------------------------------------------------
   STATO VUOTO
   ------------------------------------------------------------ */

.preventivo-page .summary-empty {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 10px;

    min-height: 100px;

    padding: 20px;

    background: #f8f9fa;

    border: 1px dashed #ced4da;
    border-radius: 12px;

    color: #6c757d;

    text-align: center;
}

.preventivo-page .summary-empty i {
    font-size: 1.3rem;
}


/* ------------------------------------------------------------
   AZIONI STEP 5
   ------------------------------------------------------------ */

.preventivo-page .step5-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    width: 100%;

    margin-top: 30px;
}

.preventivo-page .step5-actions form {
    margin: 0;
}


/* ------------------------------------------------------------
   RESPONSIVE TABLET
   ------------------------------------------------------------ */

@media (max-width: 991px) {

    .preventivo-page .summary-section {
        padding: 20px;
    }

    .preventivo-page .summary-section-header {
        margin-bottom: 18px;
    }

}


/* ------------------------------------------------------------
   RESPONSIVE MOBILE
   ------------------------------------------------------------ */

@media (max-width: 767px) {

    .preventivo-page .summary-section {
        margin-top: 20px;
        padding: 18px;
    }

    .preventivo-page .summary-section-header {
        align-items: flex-start;
    }

    .preventivo-page .summary-section-header h3 {
        font-size: 1.05rem;
    }

    .preventivo-page .summary-section-header > i {
        width: 38px;
        height: 38px;

        font-size: 1.1rem;
    }

    .preventivo-page .dispensa-pages-summary {
        grid-template-columns: 1fr;
    }

    .preventivo-page .step5-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .preventivo-page .step5-actions form,
    .preventivo-page .step5-actions button,
    .preventivo-page .step5-actions a {
        width: 100%;
    }

}


/* ------------------------------------------------------------
   MOBILE PICCOLO
   ------------------------------------------------------------ */

@media (max-width: 575px) {

    .preventivo-page .summary-section {
        padding: 15px;
    }

    .preventivo-page .summary-item {
        min-height: 62px;
        padding: 10px 12px;
    }

    .preventivo-page .summary-label {
        font-size: 0.72rem;
    }

    .preventivo-page .summary-item strong {
        font-size: 0.9rem;
    }

    .preventivo-page .dispensa-summary {
        padding: 14px;
    }

    .preventivo-page .dispensa-summary-file > i {
        width: 40px;
        height: 40px;

        font-size: 1.3rem;
    }

    .preventivo-page .page-count-box {
        padding: 11px 12px;
    }

}

/* =========================================
   COUPON PROMOZIONALE - BLU COPYCOLOR
   ========================================= */

.coupon-section {
    margin: 25px 0;
    padding: 22px;
    background: linear-gradient(135deg, #f2f7ff, #e8f1ff);
    border: 1px solid #d4e3fa;
    border-radius: 16px;
    box-shadow: 0 5px 18px rgba(25, 75, 145, 0.07);
}

.coupon-heading {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.coupon-icon {
    width: 46px;
    height: 46px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #dceaff;
    color: #1765c1;
    border-radius: 13px;
    font-size: 22px;
}

.coupon-heading h5 {
    margin: 0 0 4px;
    color: #123b70;
    font-size: 16px;
    font-weight: 700;
}

.coupon-heading p {
    margin: 0;
    color: #607b9f;
    font-size: 13px;
}

.coupon-input-group {
    display: flex;
    gap: 10px;
}

.coupon-input-wrapper {
    position: relative;
    flex: 1;
}

.coupon-input-wrapper > i {
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #2874c8;
    font-size: 18px;
    z-index: 2;
}

.coupon-input-wrapper .form-control {
    height: 48px;
    padding-left: 43px;
    border: 1px solid #c8daf2;
    border-radius: 10px;
    background: #fff;
    color: #173f72;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.coupon-input-wrapper .form-control::placeholder {
    color: #91a9c8;
    font-weight: 400;
}

.coupon-input-wrapper .form-control:focus {
    border-color: #2874c8;
    box-shadow: 0 0 0 3px rgba(40, 116, 200, 0.14);
}

.coupon-button {
    min-width: 105px;
    height: 48px;
    padding: 0 17px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #2475d0, #1255a5);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.2s ease;
}

.coupon-button:hover {
    background: linear-gradient(135deg, #185eaf, #0d4389);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(18, 85, 165, 0.22);
}

.coupon-button:active {
    transform: translateY(0);
}

.coupon-message {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 13px;
    padding: 10px 12px;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 600;
}

.coupon-success {
    background: #eaf7ee;
    color: #218348;
}

.coupon-error {
    background: #fff0ef;
    color: #c0392b;
}

.coupon-hint {
    margin-top: 13px;
    color: #6682a5;
    font-size: 11px;
}

.coupon-hint i {
    margin-right: 5px;
    color: #2874c8;
}

/* MOBILE */
@media (max-width: 480px) {
    .coupon-section {
        padding: 16px;
    }

    .coupon-input-group {
        flex-direction: column;
    }

    .coupon-button {
        width: 100%;
    }
}