/* ==========================================
   HOMEPAGE TEMPLATE
   ========================================== */

/* Slider product image container */
.product-content > a {
    display: flex;
    justify-content: center;
    min-height: 220px;
    align-items: space-between;
}
/*.book img { max-width: 200px; width: auto; height: 100%; }*/
.book .product-image {

    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.book img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.product-title { color: #313131; line-height: 20px !important; text-align: center; min-height: 60px; }

.home-swiper { overflow: hidden;max-width: 1920px;margin: 0px auto; }
.home-swiper img { margin: 0 auto; width: 100%; height: auto; }

/* Swiper navigation */
.swiper-button-prev { left: 0; transform: translateX(-200%); color: #000; }
.swiper-button-next { right: 0; transform: translateX(200%); color: #000; }

h3.slider_class_titles { font-size: 25px; font-weight: 400; }

.slider-group {
    padding: 0px;
    position: relative;
    margin-top: 40px;
}

.slider-group .shop-products .vgw-item { background: none !important; }

/* ---- Slider product cards ---- */
.slider-group .swiper-slide.book .product-content > a {
    min-height: 210px;
    align-items: center;
}
.slider-group .swiper-slide.book .product-content > a img {
    height: 210px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}
.slider-group .swiper-slide.book .product-title {
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #000 !important;
    margin-bottom: 5px;
}
.slider-group .swiper-slide.book .product-title a {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #313131;
    line-height: 20px !important;
    text-decoration: none;
    max-height: 60px; /* 3 lines × 20px */
}
.slider-group .swiper-slide.book .product-price {
    font-size: 15px !important;
    text-align: center;
    color: #313131;
    font-weight: bold;
}
.slider-group .swiper-slide.book .product-price del {
    opacity: 0.5;
    margin-right: 6px;
}
.slider-group .swiper-slide.book .product-price ins {
    text-decoration: none;
}
.slider-group .swiper-slide.book ins .woocommerce-Price-amount.amount {
    color: #89a587 !important;
}
.slider-group .swiper-slide.book .button-groups {
    height: 39px;
    text-align: center;
    border: none !important;
}
.slider-group .swiper-slide.book .button-groups .add-to-cart {
    float: none !important;
    background-color: transparent !important;
}
.slider-group .swiper-slide.book .button-groups a.button,
.slider-group .swiper-slide.book .button-groups a.add_to_cart_button {
    background-color: #c7d8c6 !important;
    color: rgb(81, 81, 81) !important;
    padding: 0 10px !important;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    line-height: 32px;
    margin-top: 19px;
    display: block;
}
.slider-group .swiper-slide.book .button-groups a.button:hover,
.slider-group .swiper-slide.book .button-groups a.add_to_cart_button:hover {
    color: #1b1b1b !important;
}

/* ---- Category icon boxes ---- */
#category-icons {
    padding: 40px 0 20px;
}
.cat-icon-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
}
.cat-icon-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    width: 160px;
    padding: 20px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.cat-icon-box:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    text-decoration: none;
}
.cat-icon-img {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    color: var(--heading);
}
.cat-icon-img svg,
.cat-icon-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.cat-icon-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--heading);
    text-align: center;
    line-height: 1.3;
}
@media (max-width: 767px) {
    .cat-icon-grid { gap: 16px; }
    .cat-icon-box { width: calc(50% - 12px); }
}

/* Homepage layout sections */
.left_col, .right_col { width: 50%; }
.left_col > div { height: 100%; }
.left_col > div, .right_col > div { padding-left: 15px; padding-right: 15px; }
.absolute_back_image.wpb_column.vc_column_container.vc_col-sm-12 { margin-left: -56px; }
#second_section_home { display: flex; }

div#icon_with_text_row {
    padding-top: 35px !important;
    padding-bottom: 50px !important;
    background-color: #c7d8c6 !important;
}
div#icon_with_text_row > .container { display: flex; }
div#icon_with_text_row > .container > div { width: 50%; }
div#extra_customs_and_handling_charges { margin: 0 auto; margin-bottom: 60px; }

/* Homepage banners */
#christmas_books { height: 500px; background-size: cover; background-position: center; box-shadow: 1000px 1000px 1000px rgba(0,0,0,0.3) inset; border-radius: 4px; }
#books, #educational_books { height: 207px; background-size: cover; background-position: center; box-shadow: 1000px 1000px 1000px rgba(0,0,0,0.3) inset; text-align: left; border-radius: 4px; }
#children_books { height: 257px; background-size: cover; background-position: center; text-align: left; box-shadow: 1000px 1000px 1000px rgba(0,0,0,0.3) inset; }
#christmas_books a { height: 500px; position: absolute; width: 100%; cursor: pointer; left: 0; }
#books a, #educational_books a { height: 207px; position: absolute; width: 100%; left: 0; cursor: pointer; }
#children_books a { height: 257px; position: absolute; width: 100%; left: 0; cursor: pointer; }
#books p, #educational_books p, #children_books p, #christmas_books p { color: #fff; font-weight: 600; font-size: 26px; }
#christmas_books p { padding-top: 200px; text-align: center; }
#books p, #educational_books p, #children_books p { padding-top: 29px; padding-left: 20px; }

/* Second section */
#second_section_home {
    display: flex;
    margin-top: 50px !important;
    margin-bottom: 130px !important;
}
#second_section_home .left_col { background-color: #1b1b1b; border-radius: 0; height: 258px; padding-right: 65px; }
#second_section_home .heading { font-size: 39px; font-weight: bold; color: #fff; text-align: right; font-family: Roboto; line-height: 49px; margin-top: 18px; }
#second_section_home .main_text { text-align: right; color: #fff; font-size: 29px; line-height: 37px; font-family: Roboto; }
#second_section_home .right_col { background-color: #c7d8c6; height: 258px; padding-left: 65px; }
#second_section_home .right_col p { color: #1b1b1b; font-size: 27px; font-weight: 600; line-height: 35px; font-family: Roboto; margin-top: 75px; }
.absolute_back_image.wpb_column.vc_column_container.vc_col-sm-12 { position: absolute; width: auto; left: 50%; margin-left: -77px; margin-top: 76px; }
.absolute_back_image.wpb_column.vc_column_container.vc_col-sm-12 img { height: auto; max-width: 100%; vertical-align: top; width: 124px; }

#contact_btn { padding: 15px 25px; color: #fff; float: right; position: relative; top: 33px; background: #1b1b1b; margin-top: -76px; border: 2px solid #1b1b1b; min-width: 273px; text-align: center; }
#contact_btn:hover { background-color: #c7d8c6; }
#contact_btn img { width: 41px; left: 11px; display: inline-block; position: relative; }
#book_solutions_btn { padding: 15px 25px; color: #fff; float: left; position: relative; top: 33px; background: #c7d8c6; border: 2px solid #c7d8c6; font-size: 27px; font-weight: 600; line-height: 35px; font-family: Roboto; }
#book_solutions_btn:hover { background-color: #1b1b1b; }
#book_solutions_btn img { width: 41px; left: 11px; display: inline-block; position: relative; }
#contact_btn_container { text-align: left; }

/* Slider titles */
.slider_class_titles {
    text-align: left;
    width: auto;
    display: inline-block;
    background-color: #fff;
    position: relative;
    top: 58px;
    padding-left: 28px;
    left: -15px;
    padding-right: 36px;
    line-height: 35px;
    text-transform: none !important;
    margin-bottom: 50px !important;
    font-weight: 600;
    z-index: 2;
    max-width: 800px;
}
@media(max-width: 767px){
    .slider_class_titles {
        top: 0px;
        left: 0px;
        margin-top: 0px !important;
        margin-bottom: 12px !important;
        padding: 0px !important;
        font-size: 28px;
    }
}
/* OWL/VGW carousel product sliders */
[id^="vgw-product-carousel"], [id^="vgw-byron"], [id^="vgw-harry"],
[id^="vgw-educational"], #sliders_row .owl-theme {
    opacity: 1 !important;
    display: block !important;

}

/* Homepage misc */

#extra_customs_and_handling_charges p { text-align: center; }

/* Icon with text row */
#icon_with_text_row i { font-size: 50px; margin-bottom: 26px; color: #1b1b1b; }
#icon_with_text_row p { font-size: 22px; padding: 0px 40px; }
.icon_text_title { color: #1b1b1b; font-weight: bold; }
.icon_text_desc { line-height: 27px; margin-top: 24px; color: #1b1b1b; }

/* Coocoo image badge (desktop) */
.coocoo_image { position: absolute; background-color: #fff; width: 95px; z-index: 2; right: -15px; margin-top: -50px; padding: 25px; }

/* Owl carousel navigation */
.owl-theme .owl-controls .owl-buttons .owl-prev { left: 0 !important; margin-left: -51px !important; margin-top: -91px !important; background: none !important; visibility: visible !important; }
.owl-theme .owl-controls .owl-buttons .owl-next { right: 0; margin-top: -91px; margin-right: -51px !important; background: none !important; visibility: visible !important; }
