/**
 * assets/css/frontend.css
 * Viessmann Boilers Manager frontend stiilid
 */

/* Üldine konteiner */
.vbm-boilers-container,
.vbm-accessories-container {
    max-width: 1200px;
    margin: 0 auto;
    /*padding: 20px;*/
}

/* Boileri üksik element */
.vbm-boiler-item {
    //margin-bottom: 40px;
    //padding: 20px;
    background-color: #fff;
}

.vbm-boiler-item h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
}

/* Tabel pildiga */
.vbm-table-with-image {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    overflow: hidden;
    table-layout: auto;
    margin: 0;
}

/* Pildi lahter - kohandub pildi suurusega */
.vbm-image-cell {
    width: 1%;
    white-space: nowrap;
    vertical-align: top;
    border-right: 1px solid #000;
}

.vbm-image-content {
    padding: 0;
    margin: 0;
    line-height: 0;
}

.vbm-image-content img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    border-radius: 8px 0 0 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Päise lahtrid */
.vbm-table-with-image th {
    background-color: #8a8d8f;
    color: #fff;
    padding: 12px 10px;
    text-align: center;
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sisu lahtrid */
.vbm-table-with-image td {
    padding: 0;
    //vertical-align: top;
    text-align:center;
}

/* Sisu lahtri sisu */
.vbm-cell-content {
    padding: 4px;
    font-weight: normal;
    line-height: 1.5;
    text-align:center;
}

.vbm-cell-content strong {
    font-weight: 700;
}

/* Võimsuste lahtri sisu - joondus */
.vbm-power-cell {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.vbm-code-row {
    align-items: center;
    font-size: 14px;
    font-family: monospace;
}

.vbm-price-row {
    align-items: center;
    font-weight:bold;
}

.vbm-price-row strong {
    font-size: 16px;
}

.vbm-power-separator {
    height: 10px;
}

/* Automaatika */
.vbm-boiler-automatics {
    margin: 20px 0;
    padding: 15px;
    background: #f0f7fc;
    border-radius: 5px;
}

.vbm-boiler-automatics p {
    margin: 0;
    font-size: 15px;
}

.vbm-boiler-automatics strong {
    color: #0073aa;
}

/* Märkused */
.vbm-boiler-note {
    margin-top: 20px;
    padding: 15px;
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
    border-radius: 4px;
}

.vbm-boiler-note p {
    margin: 0;
    color: #856404;
}

/* Admin stiilid */
.vbm-admin-table {
    width: 100%;
    border-collapse: collapse;
}

.vbm-admin-table th {
    background-color: #f1f1f1;
    padding: 10px;
    text-align: left;
}

.vbm-admin-table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

.vbm-admin-table input[type="text"],
.vbm-admin-table input[type="number"] {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Responsive disain */
@media (max-width: 992px) {
    .vbm-table-with-image {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .vbm-table-with-image th,
    .vbm-table-with-image td {
        min-width: 100px;
    }
    
    .vbm-image-cell {
        width: auto;
    }
}

@media (max-width: 768px) {
    .vbm-boilers-container,
    .vbm-accessories-container {
        padding: 10px;
    }
    
    .vbm-boiler-item {
        padding: 15px;
    }
    
    .vbm-table-with-image,
    .vbm-table-with-image thead,
    .vbm-table-with-image tbody,
    .vbm-table-with-image tr,
    .vbm-table-with-image td,
    .vbm-table-with-image th {
        display: block;
    }
    
    .vbm-table-with-image thead {
        display: none;
    }
    
    .vbm-image-cell {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
    }
    
    .vbm-image-content img {
        width: 100%;
        max-width: 100%;
        border-radius: 8px;
    }
    
    .vbm-table-with-image td[rowspan] {
        float: none;
    }
    
    .vbm-table-with-image td {
        position: relative;
        padding-left: 40%;
        border: 1px solid #e0e0e0;
    }
    
    .vbm-table-with-image td:before {
        position: absolute;
        left: 10px;
        width: 35%;
        white-space: nowrap;
        font-weight: 700;
        color: #0073aa;
    }
    
    .vbm-table-with-image tr:nth-child(2) td:before { content: "Sügavus"; }
    .vbm-table-with-image tr:nth-child(3) td:before { content: "Laius"; }
    .vbm-table-with-image tr:nth-child(4) td:before { content: "Kõrgus"; }
    .vbm-table-with-image tr:nth-child(5) td:before { content: "Kaal"; }
    .vbm-table-with-image tr:nth-child(6) td:before { content: "Suitsutoru"; }
    .vbm-table-with-image tr:nth-child(7) td:before { content: "Boileri maht"; }
    
    .vbm-cell-content {
        min-height: 40px;
        padding: 8px;
    }
    
    .vbm-code-row,
    .vbm-price-row {
        min-height: 25px;
    }
    
    .vbm-price-row strong {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .vbm-code-row {
        font-size: 12px;
    }
    
    .vbm-price-row strong {
        font-size: 13px;
    }
    
    .vbm-boiler-note {
        padding: 10px;
        font-size: 13px;
    }
    
    .vbm-table-with-image td {
        padding-left: 45%;
    }
    
    .vbm-table-with-image td:before {
        width: 40%;
        font-size: 12px;
    }
}

/* Trükkimise stiilid */
@media print {
    .vbm-boiler-item {
        border: 1px solid #000;
        box-shadow: none;
        page-break-inside: avoid;
    }
    
    .vbm-table-with-image {
        box-shadow: none;
        border: 1px solid #000;
        table-layout: auto;
    }
    
    .vbm-image-cell {
        width: auto;
    }
    
    .vbm-image-content img {
        box-shadow: none;
        border: 1px solid #ddd;
        max-width: 300px;
    }
    
    .vbm-boiler-note {
        background-color: #fff;
        border: 1px solid #000;
        color: #000;
    }
    
    .vbm-boiler-automatics {
        background-color: #fff;
        border: 1px solid #000;
    }
}

/* Abiklassid */
.vbm-text-center {
    text-align: center;
}

.vbm-text-right {
    text-align: right;
}

.vbm-font-bold {
    font-weight: 700;
}

.vbm-mb-20 {
    margin-bottom: 20px;
}

.vbm-mt-20 {
    margin-top: 20px;
}

.vbm-clear {
    clear: both;
}

table, td, th { border: 0 ; }

.vbm-boiler-item tbody, .vbm-vitocrossal-cascade-table { border-bottom: 1px solid black; }

/* Vitocrossal 100 spetsiaalsed stiilid */
.vbm-section-title {
    font-size: 24px;
    font-weight: bold;
    margin: 30px 0 15px;
}

.vbm-vitocrossal-main-table {
    margin-bottom: 0;
}

.vbm-vitocrossal-detail-table {
    margin-bottom: 0;
}

.vbm-vitocrossal-detail-table th, .vbm-vitocrossal-main-table th, .vbm-accessory-table th, .vbm-vitocrossal-cascade-table th, .vbm-mobile-product-header {
    background-color: #8a8d8f;
    text-align: center;
    font-size: 18px;
    color: white;
    
}

.vbm-accessory-table th:first-child
{
 text-align: left !important;
}

.vbm-vitocrossal-detail-table td {
    text-align: center;
    padding: 5px;
}

/*
.vbm-vitocrossal-detail-table td:first-child {
    font-weight: 600;
    background-color: #f9f9f9;
    width: 150px;
}

.vbm-vitocrossal-detail-table td:nth-child(2) {
    background-color: #f9f9f9;
    width: 50px;
}

.vbm-vitocrossal-detail-table td:nth-child(3) {
    background-color: #f9f9f9;
    width: 50px;
}
*/

.vbm-vitocrossal-cascade-table {
    margin: 0;
}


.vbm-vitocrossal-cascade-table td:first-child {
    width: 200px;
    text-align: center;
}

/* Accessories stiilid */
.vbm-accessories-container {
    margin-top: 0 !important;
}

.vbm-accessory-category {
    margin-bottom: 0;
}

.vbm-accessory-category h2 {
    color: #0073aa;
    margin-bottom: 20px;
    font-size: 22px;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
}

.vbm-accessory-table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
    overflow: hidden;
    table-layout: fixed;
    margin: 0 !important;
}

/* Pildi veerg - võtab täpselt nii palju ruumi kui pilt vajab */
.vbm-accessory-image-cell {
    width: 1%; /* Võimalikult väike, pilt määrab ise laiuse */
    text-align: center;
    vertical-align: middle;
    background-color: #f9f9f9;
}

.vbm-accessory-image-cell img {
    display: block; /* Tagab, et pilt on blokk-element */
    width: auto; /* Loomulik laius */
    height: auto; /* Loomulik kõrgus */
    max-width: none; /* Ei piira laiust */
    max-height: none; /* Ei piira kõrgust */
    border-radius: 4px;
    border: 1px solid #e0e0e0;
    padding: 5px;
    background: #fff;
    margin: 0 auto; /* Keskjoondus */
}

/* Kirjelduse veerg - 80% ülejäänud ruumist */
.vbm-accessory-info-cell {
    width: 85%;
    vertical-align: top;
}

/* Hinna veerg - 20% ülejäänud ruumist + tootekood arvutis */
.vbm-accessory-price-cell {
    width: 15%;
    vertical-align: middle;
    text-align: right;
    font-weight: 600;
    white-space: nowrap;
}

/* Tootekood arvutis - kuvatakse hinna kõrval */
.vbm-accessory-sku {
    margin-left: 10px;
    font-family: monospace;
    color: #000;
    white-space: nowrap;
    display: inline-block;
}

/* Mobiilivaates tootekood peidetakse arvutiversioonist */
.vbm-accessory-sku-mobile {
    display: none;
}


.vbm-accessory-table td {
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    vertical-align: top;
}

.vbm-accessory-table tbody tr:hover {
    background-color: #f9f9f9;
}

/* Accessories täiendavad stiilid */
.vbm-accessory-title-row {
    display: flex;
    align-items: baseline;
    width: 100%;
}

.vbm-accessory-number {
    font-weight: normal;
    color: #666;
    margin-right: 8px;
    min-width: 25px;
}

.vbm-accessory-title {
    flex: 0 1 auto;
}

.vbm-accessory-description {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    margin-top: 5px;
    padding-left: 33px;
}

/* Accessories note */
.vbm-accessory-note {
    margin-top: 20px;
    padding: 15px;
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
    border-radius: 4px;
}

.vbm-accessory-note p {
    margin: 0;
    color: #856404;
}

/* Accessories responsive */
@media (max-width: 768px) {
    .vbm-accessory-table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        table-layout: auto;
    }
    
    .vbm-accessory-table th,
    .vbm-accessory-table td {
        min-width: 150px;
    }
    
    /* Mobiilis ära kasuta fikseeritud veerulaiust */
    .vbm-accessory-image-cell,
    .vbm-accessory-info-cell,
    .vbm-accessory-price-cell {
        width: auto;
    }
    
    .vbm-accessory-title-row {
        flex-wrap: wrap;
    }
    
    /* Mobiilis peida tootekood arvutiversioonist */
    .vbm-accessory-sku {
        display: none;
    }
    
    /* Mobiilis kuva tootekood hinna all */
    .vbm-accessory-sku-mobile {
        display: block;
        margin-top: 5px;
        font-size: 12px;
        color: #666;
        text-align: center;
    }
    
    .vbm-accessory-description {
        padding-left: 33px;
        font-size: 12px;
    }
    
    .vbm-accessory-image-cell {
        text-align: center;
        width: auto;
    }
    
    .vbm-accessory-image-cell img {
        max-width: 80px;
        max-height: 80px;
        width: auto;
        height: auto;
    }
    
    /* Mobiilivaates kuva hind ja tootekood vertikaalselt ja keskele joondatult */
    .vbm-price-stack {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .vbm-accessory-category h2 {
        font-size: 18px;
    }
    
    .vbm-accessory-table td {
        padding: 8px 10px;
    }
    
    .vbm-accessory-number {
        min-width: 20px;
    }
    
    .vbm-accessory-image-cell img {
        max-width: 60px;
        max-height: 60px;
    }
}

/* Tabeli wrapper horisontaalseks kerimiseks */
.vbm-table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 20px;
    width: 100%;
}

.vbm-table-wrapper table {
    min-width: 800px;
    width: 100%;
    table-layout: auto;
}

/* Peida elemendid mobiilivaates */
@media (max-width: 768px) {
    .vbm-hide-on-mobile {
        display: none;
    }
}

@media (min-width: 769px) {
    /* Arvutivaates joonda hind keskele */
    .vbm-accessory-price-cell {
        text-align: center;
    }
    
    .vbm-accessory-price {
        display: inline-block;
        text-align: center;
    }
}

/* MOBIILIVAADE - peida arvutiversioon mobiilis */
@media (max-width: 768px) {
    .vbm-desktop-view {
        display: none;
    }
    
    .vbm-mobile-view {
        display: block;
    }
}

@media (min-width: 769px) {
    .vbm-mobile-view {
        display: none;
    }
    
    .vbm-desktop-view {
        display: block;
    }
}

/* MOBIILIKAARTIDE KUJUNDUS */
.vbm-mobile-view {
    margin-top: 20px;
}

.vbm-mobile-header {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    padding: 15px;
    background-color: #8a8d8f;
}

.vbm-mobile-image {
    flex: 0 0 120px;
}

.vbm-mobile-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.vbm-mobile-title {
    flex: 1;
}

.vbm-mobile-title h3 {
    margin: 0 0 10px 0;
    color: #FFF;
    font-size: 18px;
}

.vbm-mobile-description {
    color: #FFF;
    font-size: 14px;
    line-height: 1.5;
}

.vbm-mobile-products {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.vbm-mobile-product-card {
    border: 1px solid #000;
}

.vbm-mobile-product-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background-color: #8a8d8f;
}

.vbm-mobile-power {
    font-weight: 700;
    //color: #0073aa;
    font-size: 16px;
}

.vbm-mobile-code {
    font-family: monospace;
    //color: #333;
    font-size: 14px;
}

.vbm-mobile-price {
    font-weight: 700;
   // color: #0073aa;
    font-size: 16px;
}

.vbm-mobile-specs {
    padding: 15px;
}

.vbm-mobile-spec-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px dashed #f0f0f0;
}

.vbm-mobile-spec-row:last-child {
    border-bottom: none;
}

.vbm-mobile-spec-label {
    //color: #666;
    font-size: 14px;
}

.vbm-mobile-spec-value {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.vbm-mobile-section-title {
    font-size: 18px;
    font-weight: 600;
    color: #000;
    margin: 15px 0 10px;
    padding-bottom: 5px;
}

/* Väga väikeste ekraanide jaoks */
@media (max-width: 480px) {
    .vbm-mobile-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .vbm-mobile-image {
        flex: 0 0 auto;
        max-width: 200px;
        margin: 0 auto;
    }
    
    .vbm-mobile-product-header {
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .vbm-mobile-power,
    .vbm-mobile-code,
    .vbm-mobile-price {
        font-size: 14px;
    }
}

/* Alista Elementor'i reeglid meie piltide jaoks */
.vbm-accessory-category-image img {
    max-width: none !important;
    width: auto !important;
    height: auto !important;
    border-radius: 4px !important;
    margin: 0 auto;
}

/* Arvutivaates võimsuste veergude vahelduvad värvid - algab hallist */
@media (min-width: 769px) {
    .vbm-desktop-power-column-0 {
        background-color: #f5f5f5; /* Hall */
    }
    
    .vbm-desktop-power-column-1 {
        background-color: #ffffff; /* Valge */
    }
}


/* Mobiilivaates peida pildi veerg */
@media (max-width: 768px) {
    .vbm-accessory-image-cell {
        display: none;
    }
}

/* Arvutivaates näita pildi veergu */
@media (min-width: 769px) {
    .vbm-accessory-image-cell {
        display: table-cell;
    }
}

/* Järjekorra number ja tekst alati samal real */
.vbm-accessory-title-row {
    display: flex;
    align-items: baseline;
    flex-wrap: nowrap; /* Ära kunagi murra rida */
    width: 100%;
}

.vbm-accessory-number {
    font-weight: normal;
    color: #666;
    margin-right: 8px;
    min-width: 25px;
    flex-shrink: 0; /* Ära lase numbril väiksemaks minna */
    white-space: nowrap; /* Ära murra numbrit */
}

.vbm-accessory-title {
    flex: 0 1 auto;
    white-space: normal; /* Luba pealkirjal murduda */
    word-break: break-word; /* Murra sõnu vajadusel */
}

.vbm-accessory-sku {
    margin-left: auto;
    font-family: monospace;
    color: #000;
    padding-left: 15px;
    white-space: nowrap; /* Ära murra tootekoodi */
    flex-shrink: 0; /* Ära lase tootekoodil väiksemaks minna */
}

/* Mobiilivaates kohandused */
@media (max-width: 768px) {
    .vbm-accessory-title-row {
        flex-wrap: nowrap; /* Ära kunagi murra rida ka mobiilis */
    }
    
    .vbm-accessory-number {
        min-width: 20px;
        font-size: 14px;
    }
    
    .vbm-accessory-title {
        font-size: 14px;
        flex: 1; /* Lase pealkirjal võtta ülejäänud ruum */
    }
    
    .vbm-accessory-sku {
        font-size: 12px;
        padding-left: 10px;
        margin-left: 0; /* Muudetud, et mitte segada */
    }
}

/* Tabeli ridade hover-efekt */
.vbm-hover-rows tbody tr:hover {
    background-color: #f5f5f5 !important;
}

.vbm-hover-rows tbody tr:hover td {
    background-color: #f5f5f5 !important;
}

/* Veendu, et hover töötab ka vahelduvate värvidega veergudel */
.vbm-hover-rows tbody tr:hover .vbm-desktop-power-column-0,
.vbm-hover-rows tbody tr:hover .vbm-desktop-power-column-1 {
   // background-color: #F15A22 !important;
    //color: #FFF !important;
}

.vbm-vitocrossal-group table { display: revert-layer !important; }
/*kaotan ära algusest ja lõpust spaceri, mille elementor loob*/
.elementor-widget-spacer{ display:none;}