/* FED client alterations – frontend (doc items 1–31) */

/* 1 – Fixed top contact / info bar (independent of scrolling header) */
:root {
    --fed-contact-bar-height: 0px;
    --admin-quick-bar-height: 0px;
}

body {
    padding-top: calc(var(--admin-quick-bar-height) + var(--fed-contact-bar-height));
}

.fed-contact-bar.header_main_dollar.foodservice_pad_lr {
    position: fixed;
    top: var(--admin-quick-bar-height, 0px);
    left: 0;
    right: 0;
    z-index: 1020;
    background-color: #f2f2f2;
    margin: 0;
}

/* 31 – Mega menu: no ghost dropdown blocking clicks */
@media (min-width: 992px) {
    .header_megabar .menu > ul > li .sub-menu {
        pointer-events: none;
    }

    .header_megabar .menu > ul > li.menu-item-has-children:hover .sub-menu {
        pointer-events: auto;
    }
}

/* 2 – Category boxes fully clickable */
.food_category_sec .card.category-card-link {
    cursor: pointer;
    transition: box-shadow 0.2s ease;
}

.food_category_sec .card.category-card-link:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.food_category_sec .category-icon-slider,
.food_category_sec .category-icon-slider .item,
.food_category_sec .category-icon-slider img {
    pointer-events: none;
}

/* 3–4 – Home section sort/search toolbar */
.fed-sort-select,
.fed-section-sort-select {
    min-width: 160px;
    display: inline-block;
    width: auto;
}

.fed-sort-label {
    font-weight: 600;
}

.fed-section-toolbar .search-bar {
    position: relative;
}

.fed-section-toolbar .fed-section-search-input {
    width: 100%;
    padding-right: 36px;
}

.fed-section-toolbar .fed-section-search-icon {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    opacity: 0.65;
}

.fed-section-toolbar.is-loading {
    opacity: 0.72;
    pointer-events: none;
}

/* 5 – Single-row responsive product display (home sections) */
.fed-home-products-row {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 20px;
    width: 100%;
    scrollbar-width: thin;
}

.fed-home-products-row .product-card {
    flex: 0 0 calc((100% - 100px) / 6);
    max-width: calc((100% - 100px) / 6);
    min-width: calc((100% - 100px) / 6);
    border: 1px solid #e5e5e5;
}

@media (min-width: 1200px) {
    .fed-home-products-row .product-card {
        flex: 0 0 calc((100% - 60px) / 4);
        max-width: calc((100% - 60px) / 4);
        min-width: calc((100% - 60px) / 4);
    }
}

.fed-home-products-row .product-card h5,
.fed-home-products-row .product-card h5 a {
    font-weight: 700;
    font-size: 15px;
    line-height: 1.35;
}

#food_deals_of_the_week .product-card h5,
#food_deals_of_the_week .product-card h5 a,
.food_services_category_item .product-card h5,
.food_services_category_item .product-card h5 a {
    font-weight: 700;
    font-size: 15px;
    line-height: 1.35;
}

/* 6 – View More content blocks */
.food_services_contents:not(.show) {
    display: none;
}

/* 7 – Blog grid: 4 per row, load more reveals next rows */
.blog_card_sec .fed-blog-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
    width: 100%;
}

.blog_card_sec .fed-blog-card {
    width: 100%;
    height: 100%;
    min-width: 0;
}

.blog_card_sec .fed-blog-card.fed-blog-hidden {
    display: none;
}

.blog_card_sec .fed-blog-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 24px;
}

.fed-blog-load-more-wrap {
    text-align: center;
    margin-top: 24px;
}

.fed-blog-load-more-btn {
    display: inline-block;
    padding: 12px 28px;
    font-weight: 700;
    text-transform: uppercase;
    border: 0;
    border-radius: 4px;
    background-color: #ea4636;
    color: #fff;
    cursor: pointer;
}

.fed-blog-load-more-btn:hover {
    filter: brightness(0.92);
}

@media (max-width: 1199px) {
    .blog_card_sec .fed-blog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575px) {
    .blog_card_sec .fed-blog-grid {
        grid-template-columns: 1fr;
    }
}

/* 8 – Section headers match legacy site weight */
.page_title h2,
.search-section.page_title h2,
.food_services_blog_title h2,
.food_services_equipment_title h2 {
    font-size: clamp(1.75rem, 2.5vw, 2.25rem);
    font-weight: 700;
    letter-spacing: 0.02em;
}

/* 9–10 – Footer balance & contact links */
.footer-container {
    align-items: flex-start;
}

.footer-column.footer-logo img {
    max-height: 100px;
    width: auto;
}

.footer-column.footer-logo p {
    font-size: 14px;
    line-height: 1.5;
}

.footer-column .contact-info {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-column .contact-info > li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}

.footer-column .contact-info > li:last-child {
    margin-bottom: 0;
}

.footer-column .contact-info .contact-info-icon {
    flex: 0 0 22px;
    width: 22px;
    text-align: center;
    line-height: 1.4;
    margin-top: 2px;
}

.footer-column .contact-info .contact-info-icon i {
    font-size: 16px;
}

.footer-column .contact-info a,
.footer-column .contact-info .contact-info-text {
    flex: 1;
    min-width: 0;
    color: inherit;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.45;
}

.footer-column .contact-info a:hover {
    text-decoration: underline;
    color: #ea4636;
}

/* 11 – Catalog / category Read More (keeps original HTML & fonts) */
.catalog-desc {
    position: relative;
}

.catalog-desc.is-collapsed {
    padding-right: 90px;
    min-height: 3em;
}

.catalog-desc .desc-heading {
    font-weight: 700;
    margin-bottom: 6px;
    line-height: 1.3;
    font-size: clamp(1.5rem, 2vw, 2rem);
}

.catalog-desc .desc-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
    max-height: 3em;
    font-size: 16px;
}

.catalog-desc:not(.is-collapsed) .catalog-desc-toggle--more {
    display: none;
}

.catalog-desc.is-collapsed .catalog-desc-toggle--more {
    position: absolute;
    bottom: 0;
    right: 0;
    padding-left: 12px;
    background: linear-gradient(to right, rgba(255, 255, 255, 0), #fff 40%);
}

.catalog-desc-toggle {
    color: #0d6efd;
    text-decoration: none;
    font-weight: 600;
}

.catalog-desc-toggle:hover {
    text-decoration: underline;
}

.catalog-desc-toggle--less {
    display: none;
    margin-top: 8px;
}

.fed-catalog-desc,
.fed-catalog-desc * {
    font-family: inherit !important;
}

.catalog-desc .desc-heading,
.catalog-desc h1,
.catalog-desc h2 {
    font-size: clamp(1.5rem, 2vw, 2rem);
    font-weight: 700;
}

.catalog-desc p,
.catalog-desc li {
    font-size: 16px;
    line-height: 1.6;
}

/* 11–13 – Catalog category page */
.catalog-layout-wrap {
    max-width: 1720px;
}

#main_div .product-card {
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    overflow: hidden;
    height: 100%;
}

#main_div .product-title,
#main_div .product-title a {
    font-weight: 700 !important;
    font-size: 15px !important;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

#main_div .product-category a {
    font-size: 13px;
    font-weight: 600;
}

/* 14–24 – Product detail page */
.padding-bottom-1x.mb-1 > .row:first-child {
    align-items: flex-start;
}

.details-page-top-right-content {
    align-items: flex-start !important;
}

.p-title-main {
    font-size: clamp(1.35rem, 2.2vw, 1.75rem);
    font-weight: 700;
    line-height: 1.25;
}

.fed-product-details,
.fed-product-details p,
.fed-product-details li {
    font-size: 16px;
    line-height: 1.65;
    font-weight: 400;
    font-family: inherit;
}

.fed-product-details--summary {
    color: #444;
    margin-bottom: 1rem;
}

.fed-product-details .fed-product-subtitle,
.fed-product-details p.fed-product-subtitle {
    color: #21759b;
    font-style: italic;
    font-weight: 700;
    font-size: 16px;
    line-height: 1.45;
    margin: 0 0 0.75rem;
}

.fed-product-details ul,
.fed-product-details ol,
.fed-product-details .fed-product-feature-list {
    padding-left: 1.5rem;
    margin: 0 0 1rem;
}

.fed-product-details ul li,
.fed-product-details .fed-product-feature-list li {
    list-style: disc;
    margin-bottom: 0.35rem;
}

.fed-product-details .fed-product-shipping-note {
    margin: 0.75rem 0 0;
    font-size: 15px;
    line-height: 1.45;
}

.fed-product-details .fed-product-shipping-note strong {
    font-weight: 700;
}

.fed-product-details--full ul {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

.fed-product-details--full ul li {
    list-style: disc;
    margin-bottom: 0.35rem;
}

.fed-product-details--full p.fed-spec-line,
.fed-product-spec-tab p.fed-spec-line,
.fed-product-spec-panel p.fed-spec-line {
    text-align: center;
    margin-bottom: 0.35rem;
}

.fed-product-spec-tab,
.fed-product-spec-panel {
    padding: 0.5rem 0 1rem;
}

.fed-product-details--full .fed-pdf-button-wrap {
    text-align: center;
    margin: 1rem 0;
}

.fed-product-details--full .fed-pdf-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 22px;
    background-color: #0b5ed7;
    color: #fff !important;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
}

.fed-product-details--full .fed-pdf-download-btn:hover {
    filter: brightness(0.92);
    color: #fff !important;
}

.fed-product-details--full .fed-collapsible-note {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e5e5;
}

.fed-product-details em,
.fed-product-details i {
    font-style: italic;
}

.fed-product-details a.fed-product-read-more,
.fed-product-details a.scroll-to {
    color: #21759b;
    font-weight: 600;
}

.fed-product-details strong,
.fed-product-details b {
    font-weight: 700;
}

.fed-product-details h2,
.fed-product-details h3,
.fed-product-details h4 {
    font-weight: 700;
    margin-top: 1.25rem;
    margin-bottom: 0.75rem;
}

.product-gallery .gallery-wrapper.video-btn {
    display: none;
}

.main-price {
    font-weight: 700;
}

.price-area small {
    font-size: 0.85em;
    color: #666;
}

/* Product page: action buttons inline (qty left, buttons in a row) */
.details-page-top-right-content .p-action-button {
    display: inline-block;
    vertical-align: bottom;
}

.details-page-top-right-content .p-action-button .btn,
.details-page-top-right-content .p-action-button a.btn {
    display: inline-block;
    vertical-align: middle;
    width: auto;
}

/* Quote button: same hover sweep as Add to Cart / Buy Now (btn-primary ::before) */
.p-action-button .btn.action-quote.quote-this-product,
.p-action-button a.action-compare.product_compare {
    position: relative;
    overflow: hidden;
}

.p-action-button .btn.action-compare,
.p-action-button a.action-compare {
    background: #c62828 !important;
    background-color: #c62828 !important;
    border-color: #c62828 !important;
    color: #fff !important;
}

.p-action-button .btn.action-compare span,
.p-action-button a.action-compare span {
    color: #fff !important;
}

.p-d-f-area .a2a_kit a {
    cursor: pointer;
}

.comparison-table th {
    font-weight: 600;
    width: 35%;
}

#specification .comparison-table tbody th {
    width: 35%;
    vertical-align: top;
    font-weight: 600;
}

#specification .comparison-table tbody td {
    vertical-align: top;
}

.container.padding-bottom-1x.mb-1 {
    max-width: 1400px;
}

/* 20 – Quote button hover on home cards */
.product-card .actions form {
    width: 100%;
    margin: 0;
}

.product-card .actions .action-btn {
    width: 100%;
    box-sizing: border-box;
}

.product-card .actions button.action-btn {
    border: 0;
}

.action-btn.action-quote:hover,
.product-button-group .quote-this-product:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    transition: all 0.2s ease;
}

/* 25–27 – Checkout cart items */
.checkut-page .widget-featured-products .entry-thumb img {
    width: 90px;
    height: 90px;
    object-fit: cover;
}

.checkut-page .widget-featured-products .entry-title,
.checkut-page .widget-featured-products .entry-title a {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
}

/* 29 – Quote page product preview */
.quote-product-item .product-thumb img,
table .product-item .product-thumb img {
    width: 100px !important;
    height: 100px !important;
    object-fit: cover;
}

table .product-item .product-title,
table .product-item .product-title a {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
}

table .product-item .product-info {
    max-width: none;
}

/* FAQ page — WordPress-style accordion */
.fed-faq-page {
    padding-bottom: 2rem;
}

.fed-faq-page h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.fed-faq-accordion .fed-faq-item {
    margin-bottom: 0;
    border-bottom: 1px solid #e0e0e0;
}

.fed-faq-header {
    width: 100%;
    text-align: left;
    background: #f5f5f5;
    border: none;
    padding: 14px 48px 14px 20px;
    font-weight: 700;
    font-size: 1rem;
    color: #222;
    position: relative;
    cursor: pointer;
}

.fed-faq-header::after {
    content: '+';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.25rem;
    font-weight: 400;
}

.fed-faq-header:not(.collapsed)::after {
    content: '\2212';
}

.fed-faq-body {
    background: #fff;
    padding: 20px;
}

.fed-faq-intro {
    margin-bottom: 2rem;
}

.fed-faq-intro h2 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 1.25rem 0 0.75rem;
}
