/* ======================================================
   CHRÁPÁTKO - PARAMETRY V ZÁLOŽCE POPIS - STEP
   ====================================================== */

#chrapatko-product-parameters {
    width: 100%;
    max-width: 100%;
    margin: 28px 0 10px;
    padding: 22px 24px;
    box-sizing: border-box;
    background: #fff;
    border: 1px solid #dce6e9;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 59, 73, 0.05);
}

/* Nadpis */
#chrapatko-product-parameters .chp-title {
    position: relative;
    margin: 0 0 18px;
    padding: 0 0 10px;
    font-size: 20px;
    line-height: 1.25;
    font-weight: 700;
    color: #003b49;
}

#chrapatko-product-parameters .chp-title::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 46px;
    height: 3px;
    border-radius: 4px;
    background: #0082a3;
}

/* Wrapper */
#chrapatko-product-parameters .detail-parameters-wrapper {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
}

/* Tabulka */
#chrapatko-product-parameters table.detail-parameters {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
}

#chrapatko-product-parameters table.detail-parameters tbody {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 30px;
    row-gap: 0;
    width: 100%;
}

/* řádky */
#chrapatko-product-parameters table.detail-parameters tr {
    display: grid !important;
    grid-template-columns: 150px minmax(0, 1fr);
    align-items: start;
    border-bottom: 1px solid #e7eef1;
    margin: 0;
    padding: 0;
    background: transparent !important;
}

/* dlouhé řádky přes celou šířku */
#chrapatko-product-parameters table.detail-parameters tr.chp-row-wide {
    grid-column: 1 / -1;
    grid-template-columns: 180px minmax(0, 1fr);
}

/* skryté */
#chrapatko-product-parameters table.detail-parameters tr.no-display,
#chrapatko-product-parameters table.detail-parameters tr.chp-hide-param {
    display: none !important;
}

/* buňky */
#chrapatko-product-parameters table.detail-parameters th,
#chrapatko-product-parameters table.detail-parameters td {
    display: block !important;
    padding: 9px 0 !important;
    border: 0 !important;
    text-align: left !important;
    vertical-align: top !important;
    background: transparent !important;
    font-size: 14px;
    line-height: 1.45;
}

/* názvy */
#chrapatko-product-parameters table.detail-parameters th {
    padding-right: 14px !important;
    color: #003b49 !important;
    font-weight: 700 !important;
    text-transform: uppercase;
}

/* hodnoty */
#chrapatko-product-parameters table.detail-parameters td {
    color: #28434b !important;
}

/* odkazy */
#chrapatko-product-parameters table.detail-parameters td a {
    color: #007c9e !important;
    text-decoration: none;
}

#chrapatko-product-parameters table.detail-parameters td a:hover {
    text-decoration: underline;
}

/* tablet */
@media (max-width: 991px) {
    #chrapatko-product-parameters {
        padding: 20px 20px;
    }

    #chrapatko-product-parameters table.detail-parameters tbody {
        grid-template-columns: 1fr;
        column-gap: 0;
    }

    #chrapatko-product-parameters table.detail-parameters tr,
    #chrapatko-product-parameters table.detail-parameters tr.chp-row-wide {
        grid-column: auto;
        grid-template-columns: 170px minmax(0, 1fr);
    }
}

/* ======================================================
   MOBIL - SBALENÝ BLOK PARAMETRŮ
   Desktop zůstává beze změny.
   ====================================================== */

.chp-mobile-accordion-toggle {
    display: none;
}

@media (max-width: 767px) {

    #chrapatko-product-parameters {
        display: grid;
        grid-template-columns: 1fr auto;
        align-items: center;
        column-gap: 12px;

        margin-top: 22px;
        padding: 14px 16px;
        border-radius: 10px;
    }

    #chrapatko-product-parameters .chp-title {
        grid-column: 1;
        margin: 0 !important;
        padding: 0 !important;
        font-size: 17px;
        line-height: 1.2;
    }

    #chrapatko-product-parameters .chp-title::after {
        display: none;
    }

    #chrapatko-product-parameters .chp-mobile-accordion-toggle {
        display: block;
        grid-column: 2;

        margin: 0;
        padding: 7px 10px;

        border: 0;
        border-radius: 6px;
        background: #f3f8f9;

        color: #007c9e;
        font-size: 12px;
        line-height: 1.2;
        font-weight: 700;
        white-space: nowrap;

        cursor: pointer;
    }

    /* Výchozí stav: tabulka schovaná */
    #chrapatko-product-parameters .detail-parameters-wrapper {
        display: none !important;
        grid-column: 1 / -1;
        margin-top: 12px !important;
    }

    /* Po rozbalení se zobrazí */
    #chrapatko-product-parameters.chp-mobile-open .detail-parameters-wrapper {
        display: block !important;
    }

    /* Rozbalená tabulka je kompaktní */
    #chrapatko-product-parameters table.detail-parameters tbody {
        display: block !important;
    }

    #chrapatko-product-parameters table.detail-parameters tr,
    #chrapatko-product-parameters table.detail-parameters tr.chp-row-wide {
        display: grid !important;
        grid-column: auto;
        grid-template-columns: 125px minmax(0, 1fr) !important;
        border-bottom: 1px solid #e7eef1;
    }

    #chrapatko-product-parameters table.detail-parameters th,
    #chrapatko-product-parameters table.detail-parameters td {
        padding: 6px 0 !important;
        font-size: 12px !important;
        line-height: 1.3 !important;
    }

    #chrapatko-product-parameters table.detail-parameters th {
        padding-right: 10px !important;
    }
}
