/* ========================
   Base wrapper & typography
   ======================== */
.price-list-header-bg {
    background: #fafafa; /* or image */
    padding-top: 20px; /* space below the header */
    padding-bottom: 20px;
}


.wc-price-list-container {
    max-width: 1200px;
    margin: 0 auto 40px;
}

.wc-price-list-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px 12px 24px;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #222;
    font-size: 13px;
    line-height: 1.35;
    box-sizing: border-box;
}

/* Avoid theme margins inside wrapper */
.wc-price-list-wrapper p {
    margin: 0;
}

/* ========================
   Header
   ======================== */

.wc-price-list-header {
    text-align: center;
    margin-bottom: 10px;
}

.wc-price-list-title {
    font-weight: 500;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.wc-price-list-updated {
    font-size: 0.78rem;
    margin-top: 2px;
    opacity: 0.7;
}
/* ========================
   Header with logo
   ======================== */
.wc-price-list-header {
   display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
    text-align: center;
}

.wc-price-list-logo img {
    width: 75px;
    height: 75px;
    object-fit: contain;
}

.wc-price-list-header-text {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wc-price-list-title {
    font-weight: 700;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0;
}

.wc-price-list-updated {
    font-size: 0.78rem;
    margin: 2px 0 0;
    opacity: 0.7;
}

/* Hide logo in print if ever needed (optional) */
/*
@media print {
    .wc-price-list-logo img {
        width: 75px !important;
        height: 75px !important;
    }
}
*/

/* ========================
   Toolbar
   ======================== */

.wc-price-list-toolbar {
    text-align: right;
    margin-bottom: 10px;
    position: relative;
    z-index: 10;           /* keep above page shadow if needed */
    pointer-events: auto;
}

.wc-price-list-download-button {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 4px;
    border: none;
    background: #0052cc;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    z-index: 11;
}

.wc-price-list-download-button:hover {
    background: #003d99;
}

/* ========================
   Page container (A4-like card)
   ======================== */

.wc-price-list-page {
    background: #ffffff;
    margin: 18px auto;
    padding: 5mm 5mm; /* inner margin around content */
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.18); /* tiny shadow to resemble paper */
    border-radius: 4px;
    max-width: 297mm;  /* A4 landscape width */
    position: relative;
    page-break-after: auto; /* used by PDF library / print */
}

/* ========================
   Column layout (flexbox, SCREEN)
   ======================== */

.wc-price-list-columns {
    display: flex;
    flex-wrap: nowrap;
    gap: 16px;
}

/* Each column */
.wc-price-list-column {
    flex: 1 1 0;
    min-width: 0;
}

/* Responsive: stack columns on small screens */
@media screen and (max-width: 767px) {
    .wc-price-list-columns {
        flex-direction: column;
        gap: 12px;
    }

    .wc-price-list-column {
        width: 100%;
    }
}

/* ========================
   Category
   ======================== */

.wc-price-list-category-title {
    font-weight: 700;
    font-size: 15px; /* 14–16 range */
    margin-bottom: 6px;
    padding-bottom: 2px;
    border-bottom: 1px solid #ccc;
    color: #0052cc; /* BLUE for category */
}

/* ========================
   Product item
   ======================== */

.wc-price-list-item {
    margin-bottom: 3px;  /* gap between products */
    padding-bottom: 1px;
}

/* Line 1: Product name, wrapping if long */
.wc-price-list-name {
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 2px;
    word-wrap: break-word;
    color: #c62828; /* RED for product name */
}

/* Line 2: Price */
.wc-price-list-price {
    font-weight: 700;
    font-size: 12px;
    margin-bottom: 2px;
    color: #0052cc; /* BLUE for price */
}

/* Line 3: Short description */
.wc-price-list-desc {
    font-size: 11.5px;
    margin-bottom: 2px;
}

/* Line 4: Tags / allergens */
/* Line 4: Tags / allergens (icons) */
.wc-price-list-tags {
    margin-top: 1px;
}

/* Individual tag icons */
.wc-price-list-tag-icon {
    width: 25px;
    height: 25px;
    display: inline-block;
    margin-right: 3px;
    vertical-align: middle;
}
/* Text row (print) */
.wc-price-list-tags-text {
    display: none;
    font-size: 11px;
    margin-top: 1px;
}

/* Ensure the inline SVG fits the wrapper */
.wc-price-list-tag-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}
/* Page footer legend bar */
.wc-price-list-page-footer {
    border-top: 1px solid #ddd;
    margin-top: 4px;
    padding-top: 3px;
    padding-bottom: 2px;
    font-size: 10px;
}

.wc-price-list-page-footer-inner {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.wc-price-list-tag-legend {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.wc-price-list-tag-label {
    font-size: 10px;
}

@media (max-width: 767px) {
    .wc-price-list-category-title--continuation {
        display: none;
    }
}

/* ========================
   Print styles (A4 LANDSCAPE – optional, for direct print)
   ======================== */

@media print {
    @page {
        size: A4 landscape;
        margin: 5mm;
    }

    html, body {
        background: #ffffff !important;
        width: 297mm;
        height: 210mm;
    }

    body * {
        visibility: hidden;
    }
	 /* In print/PDF: hide icons under products, show text */
    .wc-price-list-tags-icons {
        display: none !important;
    }

    .wc-price-list-tags-text {
        display: block !important;
    }
	/* Hide the legend/footer on print */
    .wc-price-list-page-footer {
        display: none !important;
    }
	.wc-price-list-tag-icon {
        width: 15px;
        height: 15px;
        margin-right: 2px;
    }
    .wc-price-list-wrapper,
    .wc-price-list-wrapper * {
        visibility: visible;
    }

    .wc-price-list-wrapper {
        position: static;
        max-width: none;
        margin: 0;
        padding: 0;
        font-size: 8.2pt;
        line-height: 1.18;
    }

    .wc-price-list-page {
        box-shadow: none;
        margin: 0;
        max-width: 100%;
        padding: 8mm 6mm;
        page-break-after: always;
        border-radius: 0;
    }

    .wc-price-list-page:last-of-type {
        page-break-after: auto;
    }

    .wc-price-list-columns {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 4mm;
        width: 100%;
    }

    .wc-price-list-column {
        flex: 0 0 25%;
        max-width: 25%;
        min-width: 0;
    }

    .wc-price-list-header {
        margin-bottom: 4px;
    }

    .wc-price-list-title {
        font-size: 9.5pt;
        margin-bottom: 2px;
    }

    .wc-price-list-updated {
        font-size: 7.5pt;
        margin-bottom: 4px;
    }

    .wc-price-list-category-title {
        font-size: 8.5pt;
        margin-bottom: 3px;
        padding-bottom: 1px;
    }

    .wc-price-list-name {
        font-size: 8.2pt;
        margin-bottom: 1px;
    }

    .wc-price-list-price {
        font-size: 8pt;
        margin-bottom: 1px;
    }

    .wc-price-list-desc {
        font-size: 7.8pt;
        margin-bottom: 1px;
    }

    .wc-price-list-tags {
        font-size: 7.5pt;
        margin-bottom: 1px;
    }

    .wc-price-list-item {
        margin-bottom: 5px;
        padding-bottom: 2px;
        break-inside: avoid;
        page-break-inside: avoid;
    }

   /* Hide the toolbar completely so it does not take any space */
    .wc-price-list-toolbar {
        display: none !important;
        visibility: hidden !important;
    }
}
/* Make sure there is some space below the theme header
   when using the Price List (A4) template */
body.price-list-template .site-main {
    padding-top: 20px;
}

/* Intro content styling (optional but nice) */
.price-list-template .price-list-intro {
    max-width: 1200px;
    margin: 0 auto 20px;
	margin-top: 150px;
    padding: 0 12px;
    font-size: 14px;
    line-height: 1.5;
}

/* Add a little extra gap between intro and the first A4 page */
.price-list-template .wc-price-list-wrapper {
    margin-top: 10px;
}

/* Full-width layout for the special price list template */
.price-list-template .price-list-template-inner {
    max-width: 1200px;
    margin: 0 auto;
}

/* Optional: if your theme uses constrained content widths, you
   can override them here for this template only */
.price-list-template .site-main {
    padding: 0;
}

/* PRINT: on this template, hide theme chrome (header/footer/title)
   so only the A4 pages show when someone uses Ctrl+P */
@media print {
    body.price-list-template .site-header,
    body.price-list-template .site-footer,
    body.price-list-template .entry-title,
    body.price-list-template .entry-meta,
    body.price-list-template .entry-footer {
        display: none !important;
    }

    /* Make sure main area fills the page */
    body.price-list-template #primary {
        margin: 0;
        padding: 0;
    }
}
/* Force desktop-style columns when generating PDF, regardless of screen size */
body.wc-pl-pdf-export .wc-price-list-columns {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 16px !important;
}

body.wc-pl-pdf-export .wc-price-list-column {
    flex: 1 1 0 !important;
    max-width: none !important;
    min-width: 0 !important;
}
/* When generating PDF (html2pdf export), behave like print for tags */
body.wc-pl-pdf-export .wc-price-list-tags-icons {
    display: none !important;
}

body.wc-pl-pdf-export .wc-price-list-tags-text {
    display: block !important;
}
body.wc-pl-pdf-export .wc-price-list-page-footer {
    display: none !important;
}