/*  Generated: 2026-10-15 13:34:30 */
/* ============================================================
   Design system — blog a poradna (Phase 99, vlastník 14. 10. 2026, varianta A — mřížka): výpis článků (i výpis
   kategorie) a detail článku. Načítá se jen s $dsBlog (@layout.latte) — nový desktop za designSystem.desktopBlog,
   telefon a tablet za designSystem.blog. Šablony Aktuality/default.latte a article.latte beze změny: tenhle soubor
   jen restyluje jejich legacy markup (#blog-top, #blog-categories, #blog-articles, #blog-article).

   blog.css se načítá AŽ ZA námi ({block css} šablony se vykreslí v <body>), a míří na id — proto každý selektor
   začíná html.ds-blog a nese totéž id jako legacy pravidlo: vyhrává specificitou, ne pořadím.

   Mobile-first: telefon — jeden sloupec, kategorie jako vodorovně posuvná řada pilulek; tablet v mobilním režimu
   (html.ds-tablet, od 768 px) dva sloupce; nový desktop (html.ds-desktop, ne podle šířky) tři sloupce,
   kategorie se zalamují.
   ============================================================ */

/* ---------- hlavička výpisu: bez šedého boxu, text vlevo */
html.ds-blog #blog-top {
    margin: 0 0 8px;
    padding: 0;
    border-radius: 0;
    background: none;
}
html.ds-blog #blog-header h1,
html.ds-blog #blog-header .h1 {
    margin: 4px 0 8px;
    color: var(--ds-text-primary);
    font-size: 26px;
    font-weight: 700;
    line-height: 1.25;
    text-align: left;
    text-transform: none;
}
html.ds-blog #blog-header p {
    max-width: 820px;
    margin: 0;
    color: var(--ds-text-secondary);
    font-size: 15px;
    line-height: 1.5;
    text-align: left;
}

/* ---------- kategorie: pilulky */
html.ds-blog #blog-categories {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 8px;
    margin: 16px -16px 24px;
    padding: 0 16px 4px;
    overflow-x: auto;
    scrollbar-width: none;
}
html.ds-blog #blog-categories::-webkit-scrollbar {
    display: none;
}
html.ds-blog #blog-categories.no-articles {
    display: block;
    margin: 16px 0 40px;
    padding: 0;
    color: var(--ds-text-secondary);
}
html.ds-blog #blog-categories .blog-category {
    flex: none;
    width: auto;
    margin: 0;
    padding: 0;
}
html.ds-blog #blog-categories .blog-category a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 16px;
    border: 0;
    border-radius: var(--ds-radius-pill);
    background: var(--ds-surface-muted);
    color: var(--ds-text-primary);
    font-size: 15px;
    font-weight: 500;
    line-height: 1.2;
    text-decoration: none;
    text-transform: none;
    white-space: nowrap;
}
html.ds-blog #blog-categories .blog-category a:hover {
    background: var(--ds-surface-muted);
    color: var(--ds-text-primary);   /* iOS drží :hover po ťuknutí — legacy hover by plochu přebarvil na tyrkysovou */
    text-decoration: underline;
}
html.ds-blog #blog-categories .blog-category a i {
    display: none;
}

/* ---------- mřížka článků */
html.ds-blog #blog-articles {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 28px 24px;
    margin: 0 0 40px;
}
html.ds-blog #blog-articles .blog-article {
    width: auto;
    margin: 0;
    padding: 0;
    float: none;
    text-align: left;   /* mobilní legacy obsah centruje, perex článku je do bloku */
}
html.ds-blog #blog-articles .blog-article .image a {
    display: block;
}
html.ds-blog #blog-articles .blog-article .image img {
    display: block;
    width: 100%;
    max-width: none;
    height: auto;
    margin: 0;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: var(--ds-radius-card);
}
html.ds-blog #blog-articles .blog-article .title {
    margin: 14px 0 4px;
}
html.ds-blog #blog-articles .blog-article .title a {
    color: var(--ds-text-primary);
    font-size: 19px;
    font-weight: 700;
    line-height: 1.3;
    text-decoration: none;
}
html.ds-blog #blog-articles .blog-article .title a:hover {
    color: var(--ds-text-primary);
    text-decoration: underline;
}
html.ds-blog #blog-articles .blog-article .date {
    margin: 0 0 8px;
    color: var(--ds-text-muted);
    font-size: 13px;
}
html.ds-blog #blog-articles .blog-article .text {
    display: -webkit-box;
    overflow: hidden;
    max-height: 4.5em;   /* 3 řádky × 1,5 — perex mívá víc odstavců a line-clamp je neusekne čistě (prosvítal 4. řádek) */
    color: var(--ds-text-secondary);
    font-size: 15px;
    line-height: 1.5;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}
html.ds-blog #blog-articles .blog-article .text p {
    margin: 0;
    text-align: left;
}

/* ---------- odkaz zpět na všechny články */
html.ds-blog #blog-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    margin: 8px 0 32px;
    padding: 0 20px;
    border: 1px solid var(--ds-outline-soft);
    border-radius: var(--ds-radius-pill);
    background: var(--ds-surface);
    color: var(--ds-text-primary);
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
}
html.ds-blog #blog-links a:hover {
    background: var(--ds-surface);
    color: var(--ds-text-primary);
    text-decoration: underline;
}

/* ---------- detail článku */
html.ds-blog .blog-detail__hero {
    border-radius: var(--ds-radius-card);
}
html.ds-blog .blog-detail__category {
    border-radius: var(--ds-radius-pill);
}
html.ds-blog #blog-article .article,
html.ds-blog #blog-article .blog-content {
    font-size: 17px;
}
html.ds-blog #blog-article .blog-content__intro {
    font-size: 18px;
}
html.ds-blog #blog-article .article-menu__in {
    gap: 16px;
    padding: 20px;
    border: 1px solid var(--ds-outline-soft);
    border-radius: var(--ds-radius-card);
    background: var(--ds-surface);
}
html.ds-blog #blog-article .article-menu__in .title {
    color: var(--ds-text-primary);
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
}
html.ds-blog #blog-article .other-article .col-image img {
    border-radius: var(--ds-radius-sm);
}
html.ds-blog #blog-article .other-article .col-date {
    color: var(--ds-text-muted);
    font-size: 13px;
}
html.ds-blog #blog-article .other-article .col-link a {
    color: var(--ds-text-primary);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    text-decoration: none;
}
html.ds-blog #blog-article .other-article .col-link a:hover {
    color: var(--ds-text-primary);
    text-decoration: underline;
}

/* ---------- tablet v mobilním režimu: dva sloupce */
@media (min-width: 768px) {
    html.ds-blog.ds-tablet #blog-articles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ---------- nový desktop: tři sloupce, kategorie se zalamují */
html.ds-blog.ds-desktop #blog-header h1,
html.ds-blog.ds-desktop #blog-header .h1 {
    font-size: 32px;
}
html.ds-blog.ds-desktop #blog-header p {
    font-size: 16px;
}
html.ds-blog.ds-desktop #blog-categories {
    flex-wrap: wrap;
    margin: 18px 0 28px;
    padding: 0;
    overflow: visible;
}
html.ds-blog.ds-desktop #blog-articles {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-bottom: 48px;
}
