/* Estilos para vista de impresión A4 */
@page {
    size: A4 portrait;
    margin: 1.2cm;
}

:root {
    --print-paper: #ffffff;
    --print-text: #221915;
    --print-muted: #5d4d46;
    --print-border: #e8dccf;
    --print-soft: #f9f3ee;
    --print-accent: #8C2D19;
    --print-accent-strong: #6E2212;
}

body {
    font-family: var(--print-font-body, Arial, Helvetica, sans-serif);
    background: var(--print-paper);
    color: var(--print-text);
    line-height: 1.35;
    padding: 0;
    margin: 0;
}

.print-container {
    width: 100%;
    margin: 0 auto;
}

.print-header {
    background: linear-gradient(180deg, #fffdfb 0%, #f7efe9 100%);
    border: 1px solid var(--print-border);
    border-radius: 18px;
    padding: 18px 18px 14px;
    margin-bottom: 18px;
    box-shadow: 0 8px 18px rgba(34, 25, 21, 0.04);
}

.print-header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    text-align: center;
}

.print-logo {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.9);
    box-shadow: 0 10px 18px rgba(140,45,25,0.12);
    background: #f5ede7;
}

.print-header-copy {
    flex: 1;
}

.print-title {
    font-family: var(--print-font-heading, Georgia, serif);
    font-size: 23pt;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin: 0;
    color: var(--print-accent);
}

.print-subtitle {
    font-size: 9.4pt;
    margin-top: 4px;
    color: var(--print-muted);
}

.print-description {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid var(--print-border);
    font-size: 8.8pt;
    color: var(--print-muted);
    text-align: center;
}

.print-grid {
    column-count: 2;
    column-gap: 16px;
}

.print-category {
    break-inside: avoid;
    page-break-inside: avoid;
    margin: 0 0 14px;
    background: var(--print-soft);
    border: 1px solid var(--print-border);
    border-radius: 12px;
    padding: 10px 12px;
}

.print-category-title {
    font-family: var(--print-font-heading, Georgia, serif);
    font-size: 11.5pt;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(140,45,25,0.18);
    padding-bottom: 5px;
    margin: 0 0 8px;
    color: var(--print-accent-strong);
}

.print-product {
    margin-bottom: 8px;
    break-inside: avoid;
    page-break-inside: avoid;
    padding-bottom: 6px;
    border-bottom: 1px dashed rgba(140,45,25,0.18);
}

.print-product:last-child {
    margin-bottom: 0;
    border-bottom: none;
    padding-bottom: 0;
}

.print-product-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 6px;
    font-size: 10.2pt;
}

.print-product-name {
    font-weight: 700;
    color: var(--print-text);
}

.print-product-dots {
    flex: 1;
    border-bottom: 1px dotted rgba(34,25,21,0.5);
    min-width: 10px;
    margin: 0 4px;
}

.print-product-price {
    font-weight: 800;
    color: var(--print-accent);
    white-space: nowrap;
}

.print-product-desc {
    font-size: 8.2pt;
    color: var(--print-muted);
    margin-top: 3px;
    font-style: italic;
}

.print-footer {
    margin-top: 18px;
    border-top: 1px solid var(--print-border);
    padding-top: 10px;
    text-align: center;
    font-size: 8.5pt;
    color: var(--print-muted);
}

.no-print-bar {
    background: linear-gradient(135deg, #2d1f1a, #1d1412);
    color: #fff;
    padding: 10px 12px;
    text-align: center;
    margin-bottom: 18px;
    border-radius: 10px;
}

.btn-print {
    background: linear-gradient(135deg, var(--print-accent), var(--print-accent-strong));
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 999px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 10px 18px rgba(140,45,25,0.18);
}

@media print {
    body {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .no-print-bar {
        display: none !important;
    }
}