/*
Theme Name: Organic STAX Child
Theme URI: https://www.organicthemes.com/theme/stax-theme
Description: Child theme for Organic STAX
Author: Elijah David
Author URI: 
Template: organic-stax
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: organic-stax-child
*/

/* Import parent theme styles */
@import url("../organic-stax/style.css");

/* Hide header spacer when no post title exists */
.site-header + .wp-block-spacer {
    transition: opacity 0.3s ease;
}

.site-logo-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: #000;
    margin-left: 1rem;
}

.page .wp-block-post-title:empty ~ .site-header + .wp-block-spacer,
.page .wp-block-post-title:empty + .wp-block-spacer {
    display: none;
}

/* Custom Logo Styling */
.custom-logo {
    margin: 0;
    padding: 0;
}

.custom-logo a {
    display: contents !important;
}

.custom-logo:hover {
    opacity: 0.8 !important;
}

.custom-logo img {
    max-height: 60px;
    width: auto;
    height: auto;
    object-fit: contain;
}

@media (max-width: 767px) {
    .site-logo-text {
        font-size: 1rem !important;
    }
}

.site-logo-wrapper .custom-logo {
    display: flex;
    align-items: center;
}

.custom-logo a {
    text-decoration: none;
    display: block;
    transition: opacity 0.3s ease;
}



.custom-logo a:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

@media (max-width: 768px) {
    .custom-logo img {
        max-height: 50px;
    }
}

/* Latest Posts List Hover Effects */
.wp-block-latest-posts__list li {
    transition: all 0.3s ease;
    padding: 1rem;
    margin-bottom: 1rem;
}

.wp-block-latest-posts__list li:hover {
    background-color: #f8f9fa;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* Force Latest Posts Featured Image to 150x150px */
.wp-block-latest-posts__featured-image.alignleft {
    width: 150px !important;
    height: 150px !important;
    max-width: 150px !important;
    max-height: 150px !important;
    min-width: 150px !important;
    min-height: 150px !important;
    float: left;
    margin-right: 1rem;
    margin-bottom: 0.5rem;
}

.wp-block-latest-posts__featured-image.alignleft img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* Make list item height adjust to content and add a border */
.wp-block-latest-posts__list li {
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 0;
    margin-top: 0;
    padding-bottom: .8rem;
    height: auto;
    min-height: fit-content;
    display: block;
    overflow: auto;
}

.wp-block-latest-posts__list li:first-child{
    border-top: 1px solid #e0e0e0;
}

/* Ensure featured image maintains its size */
.wp-block-latest-posts__featured-image.alignleft {
    width: 150px;
    height: 150px;
    float: left;
    margin-right: 1rem;
    margin-bottom: 0.5rem;
}

/* Mobile styles - remove left and right padding */
@media (max-width: 768px) {
    .wp-block-latest-posts__list {
        padding-right: 10px !important;
        padding-left: 0 !important;
        margin-right: 0 !important;
    }

   .wp-block-latest-posts__list li {
        padding-right: 0;
    }
}

.wp-block-latest-posts__post-title { 
    font-weight: 600;
    font-size: 1.4rem;
    color: #000 !important;
}

.wp-block-woocommerce-customer-account {
    display: none !important;
    pointer-events: none !important;
    user-select: none !important;
    left: -9999px !important;
    opacity: 0 !important;
}

.wc-block-mini-cart {
    display: none !important;
    pointer-events: none !important;
    user-select: none !important;
    left: -9999px !important;
    opacity: 0 !important;
}

.obb-style-rounded .obb-content {
    display: block !important;
}

.obb-posts .obb-post-container .obb-content {
    position: relative;
}

.obb-featured-img img {
    width: 100%;
    height: 200px !important;
    object-fit: cover;
    object-position: center;
    display: block;
    overflow: hidden;
}

@media (min-width: 767px) {
    .obb-featured-img img {
        height: 250px !important;
    }
}

@media (max-width: 767px) {
    .product-button {
        display: contents !important;
    }
}
