/* ================================================================
   Canadian Beef Recetario — Plugin Stylesheet
   All selectors are namespaced with .cbr- to avoid conflicts.
================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&family=Inter:wght@300;400;500&display=swap');

/* ---- Reset inside plugin scope ---- */
.cbr-wrap *,
.cbr-wrap *::before,
.cbr-wrap *::after {
    box-sizing: border-box;
}

.cbr-wrap {
    font-family: 'Inter', sans-serif;
    color: #111;
    background: #fff;
    -webkit-font-smoothing: antialiased;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 0 80px;
}

/* ================================================================
   PAGE HEADER
================================================================ */
.cbr-page-header {
    padding: 56px 48px 40px;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
}


.cbr-page-title {
    font-family: 'Libre Baskerville', serif;
    font-size: 50px;
    font-weight: 700;
    line-height: 1;
    color: #111;
    margin: 0 0 10px;
    padding: 0;
    border: none;
}

.cbr-page-desc {
    font-size: 14px;
    color: #888;
    line-height: 1.7;
    max-width: 420px;
    margin: 0;
}

.cbr-count-num {
    font-family: 'Libre Baskerville', serif;
    font-size: 46px;
    color: #c41230;
    line-height: 1;
    text-align: right;
}

.cbr-count-lbl {
    font-size: 11px;
    color: #aaa;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: 4px;
    text-align: right;
}

/* ================================================================
   SECTION HEADER (shared)
================================================================ */
.cbr-sec-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid #111;
}

.cbr-sec-title {
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 500;
    color: #111;
}

.cbr-sec-link {
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #c41230;
    text-decoration: none;
}

.cbr-sec-link:hover { text-decoration: underline; }

/* ================================================================
   TÉCNICAS DE COCINA
================================================================ */
.cbr-tecnicas {
    padding: 40px 48px;
    border-bottom: 1px solid #e8e8e8;
}

.cbr-tec-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1px;
    background: #e8e8e8;
    border: 1px solid #e8e8e8;
}

.cbr-tec-cell {
    background: #fff;
    padding: 24px 16px;
    text-align: center;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: background 0.15s;
}

.cbr-tec-cell:hover {
    background: #fafafa;
}

.cbr-tec-cell:hover .cbr-tec-name {
    color: #c41230;
}

.cbr-tec-img {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 12px;
    background: #f0ebe6;
    display: block;
}

.cbr-tec-name {
    font-size: 12px;
    color: #444;
    line-height: 1.4;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
}

/* ================================================================
   FILTER BAR
================================================================ */
.cbr-filter-bar {
    padding: 0 48px;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 50;
}

.cbr-filters {
    display: flex;
}

.cbr-filter-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    color: #aaa;
    padding: 16px 18px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
    white-space: nowrap;
}

.cbr-filter-btn:hover { color: #111; }

.cbr-filter-btn.is-active {
    color: #111;
    border-bottom-color: #c41230;
}

.cbr-search-wrap {
    flex-shrink: 0;
}

/* Search icon embedded as background-image — immune to theme CSS conflicts */
.cbr-search-input {
    display: block !important;
    border: 1px solid #e0e0e0 !important;
    padding: 8px 14px 8px 34px !important;
    font-size: 13px !important;
    font-family: 'Inter', sans-serif !important;
    color: #111 !important;
    width: 200px !important;
    outline: none !important;
    border-radius: 0 !important;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%23aaaaaa' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: 11px center !important;
    background-size: 13px 13px !important;
    box-shadow: none !important;
    line-height: normal !important;
}

.cbr-search-input:focus {
    border-color: #c41230 !important;
    outline: none !important;
    box-shadow: none !important;
}

/* ================================================================
   TWO-COLUMN LAYOUT
================================================================ */
.cbr-layout {
    display: grid;
    grid-template-columns: 1fr 260px;
    padding: 0 48px;
    align-items: start;
}

.cbr-feed {
    border-right: 1px solid #e8e8e8;
    padding: 40px 48px 60px 0;
}

/* ================================================================
   FEATURED BLOCK
================================================================ */
.cbr-featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: #e8e8e8;
    border: 1px solid #e8e8e8;
    margin-bottom: 48px;
}

.cbr-feat-main {
    background: #fff;
    padding: 28px;
}

.cbr-feat-img-box {
    width: 100%;
    height: 200px;
    background: #f0ebe6;
    margin-bottom: 20px;
    overflow: hidden;
}

.cbr-feat-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cbr-feat-label {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #c41230;
    margin-bottom: 8px;
}

.cbr-feat-title {
    font-family: 'Libre Baskerville', serif;
    font-size: 20px;
    line-height: 1.35;
    color: #111;
    margin-bottom: 8px;
    display: block;
    text-decoration: none;
}

.cbr-feat-title:hover { color: #c41230; }

.cbr-feat-meta {
    font-size: 12px;
    color: #aaa;
}

.cbr-feat-side {
    background: #fff;
    display: flex;
    flex-direction: column;
}

.cbr-side-item {
    padding: 18px 22px;
    text-decoration: none;
    display: block;
    transition: background 0.15s;
    border-bottom: 1px solid #e8e8e8;
    flex: 1;
}

.cbr-side-item:last-child { border-bottom: none; }
.cbr-side-item:hover { background: #fafafa; }

.cbr-side-label {
    font-size: 10px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #aaa;
    margin-bottom: 5px;
}

.cbr-side-title {
    font-family: 'Libre Baskerville', serif;
    font-size: 14px;
    line-height: 1.4;
    color: #111;
}

.cbr-side-date {
    font-size: 11px;
    color: #bbb;
    margin-top: 5px;
}

/* ================================================================
   RECIPE LIST
================================================================ */
.cbr-list-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 12px;
    border-bottom: 2px solid #111;
    margin-bottom: 0;
}

.cbr-list-title {
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 500;
    color: #111;
}

.cbr-recipe-list {
    display: flex;
    flex-direction: column;
}

.cbr-r-item {
    display: grid;
    grid-template-columns: 60px 1fr auto;
    gap: 16px;
    align-items: start;
    padding: 20px 0;
    border-bottom: 1px solid #e8e8e8;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.15s;
}

.cbr-r-item:hover { opacity: 0.65; }

.cbr-r-num {
    font-family: 'Libre Baskerville', serif;
    font-size: 24px;
    color: #e0e0e0;
    font-weight: 700;
    line-height: 1.1;
    padding-top: 2px;
}

.cbr-r-body {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.cbr-r-cat {
    font-size: 10px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #aaa;
    margin-bottom: 5px;
}

.cbr-r-title {
    font-family: 'Libre Baskerville', serif;
    font-size: 16px;
    line-height: 1.4;
    color: #111;
}

.cbr-r-date {
    font-size: 11px;
    color: #bbb;
    margin-top: 5px;
}

.cbr-r-arrow {
    font-size: 12px;
    color: #c41230;
    padding-top: 6px;
}

.cbr-no-results {
    padding: 40px 0;
    color: #aaa;
    font-size: 14px;
}

/* ================================================================
   PAGINATION
================================================================ */
.cbr-pagination {
    padding-top: 32px;
}

.cbr-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.cbr-pagination .page-numbers li { list-style: none; }

.cbr-pagination .page-numbers a,
.cbr-pagination .page-numbers span {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    color: #aaa;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all 0.15s;
    font-family: 'Inter', sans-serif;
}

.cbr-pagination .page-numbers a:hover {
    border-color: #e0e0e0;
    color: #111;
}

.cbr-pagination .page-numbers .current {
    background: #c41230;
    color: #fff;
    border-color: #c41230;
}

/* ================================================================
   SIDEBAR
================================================================ */
.cbr-sidebar {
    padding: 40px 0 60px 36px;
    position: sticky;
    top: 60px;
}

.cbr-sb-block {
    margin-bottom: 36px;
}

.cbr-sb-title {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 500;
    color: #111;
    padding-bottom: 12px;
    border-bottom: 2px solid #111;
    margin-bottom: 16px;
}

.cbr-cat-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.cbr-cat-list li {
    border-bottom: 1px solid #f0f0f0;
}

.cbr-cat-list li a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    font-size: 13px;
    color: #444;
    text-decoration: none;
    transition: color 0.15s;
    font-family: 'Inter', sans-serif;
}

.cbr-cat-list li a:hover { color: #c41230; }

.cbr-cat-list li a span {
    font-size: 11px;
    color: #bbb;
}

.cbr-sb-text {
    font-size: 13px;
    color: #888;
    line-height: 1.6;
    margin-bottom: 12px;
}

.cbr-sb-link {
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #c41230;
    text-decoration: none;
    border-bottom: 1px solid #c41230;
    padding-bottom: 1px;
}

.cbr-sb-link:hover { opacity: 0.75; }

/* ================================================================
   AJAX LOADING STATE
================================================================ */
.cbr-recipe-list.is-loading {
    opacity: 0.4;
    pointer-events: none;
}

/* ================================================================
   RESPONSIVE
================================================================ */
@media (max-width: 900px) {
    .cbr-layout {
        grid-template-columns: 1fr;
        padding: 0 24px;
    }
    .cbr-feed {
        border-right: none;
        padding-right: 0;
    }
    .cbr-sidebar {
        padding-left: 0;
        position: static;
        border-top: 2px solid #e8e8e8;
        padding-top: 40px;
    }
    .cbr-tec-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .cbr-featured {
        grid-template-columns: 1fr;
    }
    .cbr-feat-side {
        flex-direction: row;
        flex-wrap: wrap;
    }
    .cbr-side-item {
        flex: 1 1 50%;
    }
}

@media (max-width: 600px) {
    .cbr-page-header {
        padding: 32px 24px 24px;
        flex-direction: column;
        align-items: flex-start;
    }
    .cbr-page-title { font-size: 36px; }
    .cbr-tecnicas { padding: 32px 24px; }
    .cbr-tec-grid { grid-template-columns: repeat(3, 1fr); }
    .cbr-filter-bar { padding: 0 24px; overflow-x: auto; }
    .cbr-filters { flex-wrap: nowrap; }
    .cbr-search-wrap input { width: 140px; }
    .cbr-count-num { font-size: 32px; }
}
