/*
 Theme Name:   Divi Child Theme Zhivi plodove
 Theme URI:    https://zhiviplodove.com/
 Description:  Child Theme for Divi
 Author:       Zhivi plodove
 Author URI:   https://zhiviplodove.com/
 Template:     Divi
 Version:      1.0.0
*/

/*****Add any custom CSS below this line*****/

/* ============================================================
   ORDER-RECEIVED / THANK-YOU PAGE  (zp- prefix)
   Финална цветова схема:
     #FF6D00  — оранжево  (border на блока, стойности в overview)
     #F5efed  — кремав    (фон на блока)
     #5FA832  — светло зелено (лейбъли, хедъри на таблица, продукти, суми)
     #2d6a27  — тъмно зелено (notice, Общо ред, адреси)
   Шрифт: Playpen Sans
   ============================================================ */

/* ---------- Outer wrapper ---------- */
.zp-order-received-wrap {
    padding: 0 0 40px;
    font-family: 'Playpen Sans', cursive;
}

/* ---------- Main box ---------- */
.zp-order-box {
    background: #F5efed;
    border: 2px solid #FF6D00;
    border-radius: 12px;
    padding: 28px 32px 36px;
    margin: 0 auto;
    max-width: 900px;
}

.zp-order-box--error {
    border-color: #c0392b;
    background: #fff5f5;
}

/* ---------- Success notice ---------- */
.zp-thankyou-notice {
    color: #2d6a27 !important;
    font-weight: 600;
    font-size: 1em;
    margin: 0 0 16px;
    padding: 0;
    background: none !important;
    border: none !important;
}

/* ---------- Order overview strip ---------- */
.zp-order-overview {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
    border-top: 1px solid #c8dfbb;
    border-bottom: 1px solid #c8dfbb;
}

.zp-overview-item {
    flex: 1 1 auto;
    padding: 10px 18px 10px 0;
    border-right: 1px solid #c8dfbb;
    font-size: 0.78em;
    color: #5FA832;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.zp-overview-item:last-child {
    border-right: none;
    padding-right: 0;
}

.zp-overview-item strong {
    display: block;
    text-transform: none;
    letter-spacing: 0;
    font-size: 1.15em;
    font-weight: normal;
    color: #FF6D00;
    margin-top: 3px;
}

.zp-overview-label {
    display: block;
}

/* ---------- COD notice ---------- */
.zp-cod-notice {
    color: #5FA832;
    margin: 0 0 8px;
    font-size: 0.95em;
}

/* ---------- Section titles ---------- */
.zp-section-title {
    color: #5FA832;
    font-size: 1.35em;
    font-weight: 700;
    margin: 28px 0 14px;
    padding: 0;
    font-family: 'Playpen Sans', cursive !important;
}

/* ---------- Order details table ---------- */
.zp-order-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 8px;
}

.zp-th {
    text-align: left;
    color: ##E8F5E9;
    font-size: 0.9em;
    font-weight: 700;
    padding: 10px 12px;
    background-color: #5FA832;
    border-bottom: none;
}

.zp-order-table thead tr {
    background-color: #5FA832;
}

.zp-th--right,
.zp-td--right {
    text-align: right;
    color: ##E8F5E9;
}

.zp-order-row td,
.zp-order-row th {
    padding: 10px 12px 10px 0;
    border-bottom: 1px solid #e6efe3;
    color: #1a3f16;
    font-size: 0.95em;
    vertical-align: middle;
}

.zp-order-row th {
    font-weight: 600;
    white-space: nowrap;
}

.zp-order-row td {
    text-align: right;
    color: #5FA832;
}

/* tfoot rows */
tfoot .zp-order-row td,
tfoot .zp-order-row th {
    color: #5FA832;
    text-align: right;
}

/* Total row — тъмно зелено */
.zp-order-row--total td,
.zp-order-row--total th {
    font-weight: 700;
    font-size: 1.05em;
    border-bottom: none;
    color: #2d6a27;
}

/* Product link */
.zp-product-link {
    color: #5FA832 !important;
    text-decoration: none;
}

.zp-product-link:hover {
    text-decoration: underline;
}

/* Qty badge */
.zp-qty {
    color: #5FA832;
    font-size: 0.9em;
    margin-left: 4px;
}

/* Shipping method label */
.zp-shipping-method {
    color: #5FA832;
    font-style: italic;
    font-size: 0.9em;
}

/* Payment method */
.zp-payment-method {
    color: #5FA832 !important;
    font-weight: 600;
}

/* ---------- Addresses section ---------- */
.zp-addresses {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    margin-top: 32px;
}

.zp-address-box {
    flex: 1 1 260px;
    min-width: 220px;
}

.zp-address-box .zp-section-title {
    margin-top: 0;
}

.zp-address {
    background: transparent;
    border: 1.5px solid #4a8c42;
    border-radius: 10px;
    padding: 18px 20px;
    font-style: normal;
    color: #2d6a27;
    font-size: 0.95em;
    line-height: 1.7;
    display: block;
}

.zp-address p {
    margin: 0;
}

.zp-phone,
.zp-email {
    color: #2d6a27;
    margin-top: 6px !important;
    font-size: 0.9em;
}

/* ---------- Buttons (failed order) ---------- */
.zp-btn {
    background: #2d6a27 !important;
    color: #E8F5E9 !important;
    border-radius: 8px !important;
    padding: 10px 24px !important;
    text-decoration: none;
    margin-right: 10px;
    font-weight: 600;
}

.zp-btn--secondary {
    background: #E8F5E9 !important;
    color: #2d6a27 !important;
    border: 2px solid #2d6a27 !important;
}

/* Скрива купонната форма само на order-received страницата */
.woocommerce-order-received .et_pb_wc_cart_notice {
    display: none !important;
}

/* Прозрачен фон и без border на Divi WC Payment Info модула */
.woocommerce-order-received .et_pb_wc_checkout_payment_info,
.woocommerce-order-received .et_pb_wc_checkout_payment_info_0 {
    border: none !important;
    box-shadow: none !important;
    background: transparent !important;
    background-color: transparent !important;
}

/* Скрива дублирано WooCommerce съдържание извън zp-order-box
   (генерирано от Divi/plugins закачени към woocommerce_thankyou) */
.zp-order-received-wrap > .woocommerce-order-overview,
.zp-order-received-wrap > .woocommerce-thankyou-order-received,
.zp-order-received-wrap > .woocommerce-order-details,
.zp-order-received-wrap > .woocommerce-customer-details {
    display: none !important;
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
    .zp-order-box {
        padding: 18px 16px 24px;
    }

    .zp-order-overview {
        flex-direction: column;
        gap: 0;
    }

    .zp-overview-item {
        border-right: none;
        border-bottom: 1px solid #c8dfbb;
        padding: 8px 0;
    }

    .zp-overview-item:last-child {
        border-bottom: none;
    }

    .zp-addresses {
        flex-direction: column;
    }

    .zp-order-table,
    .zp-order-table thead,
    .zp-order-table tbody,
    .zp-order-table tfoot,
    .zp-order-table tr,
    .zp-order-table th,
    .zp-order-table td {
        display: block;
        width: 100%;
        text-align: left !important;
    }

    .zp-th--right,
    .zp-td--right,
    .zp-order-row td {
        text-align: left !important;
    }
}