/* ─── Category SEO Pages ─── */
/* /tenders/{category} — public, RTL Hebrew */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --navy:        #2B3A67;
    --orange:      #FD891B;
    --orange-dark: #e07010;
    --text:        #1a1a2e;
    --muted:       #6b7280;
    --border:      #e5e7eb;
    --bg:          #f9fafb;
    --white:       #ffffff;
    --green:       #16a34a;
    --green-bg:    #dcfce7;
    --amber:       #d97706;
    --radius:      0.75rem;
    --shadow:      0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
}

html { font-size: 16px; }

body {
    font-family: 'Heebo', 'Arial Hebrew', Arial, sans-serif;
    direction: rtl;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
}

/* ── Top Bar ─────────────────────────────────────────────── */

.topbar {
    background: var(--navy);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    color: var(--white);
    font-size: 1.25rem;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: -0.02em;
}

.topbar-cta {
    background: var(--orange);
    color: var(--white);
    text-decoration: none;
    padding: 0.45rem 1.1rem;
    border-radius: 0.4rem;
    font-weight: 700;
    font-size: 0.875rem;
    transition: background 0.15s;
}
.topbar-cta:hover { background: var(--orange-dark); }

/* ── Breadcrumb ──────────────────────────────────────────── */

.breadcrumb {
    max-width: 1100px;
    margin: 1rem auto 0;
    padding: 0 1.5rem;
    font-size: 0.8rem;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--navy); text-decoration: underline; }
.breadcrumb .sep { color: #cbd5e1; }

/* ── Category Hero ───────────────────────────────────────── */

.cat-hero {
    background: linear-gradient(135deg, var(--navy) 0%, #3d5080 100%);
    color: var(--white);
    padding: 2.5rem 1.5rem;
    margin-top: 1rem;
}

.cat-hero-inner {
    max-width: 1100px;
    margin: 0 auto;
}

.cat-title {
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    font-weight: 800;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 0.75rem;
}

.cat-description {
    font-size: 1rem;
    line-height: 1.75;
    color: #c8d4f0;
    max-width: 720px;
    margin-bottom: 1.75rem;
}

/* Stats strip */

.cat-stats {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.cat-stat {
    display: flex;
    flex-direction: column;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 0.6rem;
    padding: 0.75rem 1.25rem;
    min-width: 100px;
}

.cat-stat-active { background: rgba(22,163,74,0.25); border-color: rgba(22,163,74,0.4); }

.cat-stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--white);
    line-height: 1.1;
}

.cat-stat-label {
    font-size: 0.78rem;
    color: #c8d4f0;
    margin-top: 0.2rem;
}

/* ── Page layout ─────────────────────────────────────────── */

.cat-page {
    max-width: 1100px;
    margin: 2rem auto 3rem;
    padding: 0 1.5rem;
}

.cat-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
}

/* ── Section heading ─────────────────────────────────────── */

.cat-section-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.cat-active-badge {
    font-size: 0.75rem;
    font-weight: 600;
    background: var(--green-bg);
    color: var(--green);
    padding: 0.2rem 0.55rem;
    border-radius: 2rem;
}

/* ── Tender cards ────────────────────────────────────────── */

.tender-cards {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tender-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: var(--shadow);
    transition: box-shadow 0.15s, border-color 0.15s;
}

.tender-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
    border-color: #d1d5db;
}

.tender-card-expired { opacity: 0.72; }

.tender-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tender-card-badges {
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.tc-badge {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.18rem 0.55rem;
    border-radius: 2rem;
}

.tc-badge-active  { background: var(--green-bg); color: var(--green); }
.tc-badge-expired { background: #f3f4f6; color: var(--muted); }
.tc-badge-type    { background: #eff6ff; color: #1d4ed8; }

.tender-card-num {
    font-size: 0.75rem;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
}

.tender-card-title {
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.6rem;
}

.tender-card-link {
    color: var(--navy);
    text-decoration: none;
}
.tender-card-link:hover { color: var(--orange); text-decoration: underline; }

.tender-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.85rem;
    margin-bottom: 0.85rem;
}

.tc-meta-item { display: flex; align-items: center; gap: 0.25rem; color: var(--text); }
.tc-meta-label { color: var(--muted); font-weight: 600; }
.tc-meta-deadline { color: var(--green); }
.tc-meta-expired { color: var(--muted); text-decoration: line-through; }
.tc-meta-budget { color: var(--navy); font-weight: 600; }

.tender-card-cta {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--orange);
    text-decoration: none;
}
.tender-card-cta:hover { text-decoration: underline; }

/* ── Empty state ─────────────────────────────────────────── */

.cat-empty {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    text-align: center;
    color: var(--muted);
}
.cat-empty-sub { font-size: 0.875rem; margin-top: 0.5rem; }

/* ── Sidebar ─────────────────────────────────────────────── */

.cat-sidebar { display: flex; flex-direction: column; gap: 1rem; }

.cat-widget {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: var(--shadow);
}

.cat-widget-cta {
    border-color: var(--orange);
    background: linear-gradient(135deg, #fff9f0 0%, var(--white) 100%);
    text-align: center;
}

.cat-widget-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 0.85rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

/* Publisher list */

.publisher-list { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }

.publisher-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    padding: 0.3rem 0;
    border-bottom: 1px solid var(--border);
}
.publisher-item:last-child { border-bottom: none; }

.publisher-name { color: var(--text); font-weight: 500; flex: 1; padding-left: 0.5rem; }

.publisher-count {
    font-size: 0.75rem;
    background: #eff6ff;
    color: #1d4ed8;
    padding: 0.15rem 0.4rem;
    border-radius: 2rem;
    font-weight: 600;
    white-space: nowrap;
}

/* Stats list */

.stats-list { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }

.stats-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
    padding: 0.3rem 0;
    border-bottom: 1px solid var(--border);
}
.stats-item:last-child { border-bottom: none; }

.stats-label { color: var(--muted); }
.stats-value { font-weight: 700; color: var(--navy); }
.stats-value-active { color: var(--green); }
.stats-value-muted  { color: var(--muted); }

/* CTA widget */

.cta-widget-icon { font-size: 1.75rem; margin-bottom: 0.6rem; }

.cta-widget-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 0.6rem;
    border-bottom: none;
    padding-bottom: 0;
}

.cta-widget-body {
    font-size: 0.85rem;
    color: var(--muted);
    line-height: 1.65;
    margin-bottom: 1rem;
}

.cta-widget-btn {
    display: inline-block;
    background: var(--orange);
    color: var(--white);
    text-decoration: none;
    padding: 0.6rem 1.4rem;
    border-radius: 0.4rem;
    font-weight: 700;
    font-size: 0.9rem;
    transition: background 0.15s;
}
.cta-widget-btn:hover { background: var(--orange-dark); }

.cta-widget-note {
    margin-top: 0.6rem;
    font-size: 0.75rem;
    color: var(--muted);
}

/* Related categories */

.related-cats { list-style: none; display: flex; flex-direction: column; gap: 0.35rem; }

.related-cat-link {
    color: var(--navy);
    text-decoration: none;
    font-size: 0.875rem;
    display: block;
    padding: 0.25rem 0;
    border-bottom: 1px solid var(--border);
    transition: color 0.12s;
}
.related-cat-link:hover { color: var(--orange); }
.related-cats li:last-child .related-cat-link { border-bottom: none; }

/* ── Bottom CTA ──────────────────────────────────────────── */

.cat-bottom-cta {
    margin-top: 2.5rem;
    background: linear-gradient(135deg, var(--navy) 0%, #3d5080 100%);
    border-radius: var(--radius);
    padding: 2.5rem 2rem;
    text-align: center;
}

.cat-bottom-cta-inner { max-width: 640px; margin: 0 auto; }

.cat-cta-title {
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    font-weight: 800;
    color: var(--white);
    margin-bottom: 0.85rem;
    line-height: 1.3;
}

.cat-cta-body {
    font-size: 0.97rem;
    color: #c8d4f0;
    line-height: 1.75;
    margin-bottom: 1.5rem;
}

.cat-cta-btn {
    display: inline-block;
    background: var(--orange);
    color: var(--white);
    text-decoration: none;
    padding: 0.85rem 2.25rem;
    border-radius: 0.5rem;
    font-weight: 700;
    font-size: 1rem;
    transition: background 0.15s;
}
.cat-cta-btn:hover { background: var(--orange-dark); }

/* ── Footer ──────────────────────────────────────────────── */

.footer {
    background: var(--navy);
    color: #94a3b8;
    padding: 2rem 1.5rem;
    margin-top: 3rem;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-brand { color: var(--white); font-weight: 700; font-size: 0.95rem; }

.footer-links { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.footer-links a { color: #94a3b8; text-decoration: none; font-size: 0.875rem; }
.footer-links a:hover { color: var(--white); }

.footer-legal { font-size: 0.775rem; color: #64748b; line-height: 1.6; }

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 860px) {
    .cat-layout {
        grid-template-columns: 1fr;
    }
    .cat-sidebar {
        order: -1; /* show sidebar above tenders on mobile */
    }
    .cat-sidebar .cat-widget:not(.cat-widget-cta) {
        display: none; /* hide secondary widgets on mobile, keep CTA */
    }
    .cat-sidebar .cat-widget-cta {
        display: block;
    }
}

@media (max-width: 640px) {
    .cat-hero { padding: 1.75rem 1rem; }
    .cat-page { padding: 0 1rem; }
    .cat-stats { gap: 0.75rem; }
    .cat-stat { padding: 0.6rem 0.9rem; min-width: 80px; }
    .cat-stat-value { font-size: 1.3rem; }
    .tender-card { padding: 1rem; }
}
