/* Blog Twoje-Drzwi.pl - style frontowe. Responsywne (mobile-first: siatka 1 kolumna do
   ~600px, 2 kolumny do ~900px, 3 kolumny powyzej). Bez stylow komentarzy/lajkow (nie istnieja). */

.tdblog-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    align-items: flex-start;
}

.tdblog-main {
    flex: 1 1 640px;
    min-width: 0;
}

.tdblog-sidebar {
    flex: 0 0 240px;
}

.tdblog-category-list {
    list-style: none;
    margin: 0 0 20px;
    padding: 0;
}

.tdblog-category-list li {
    margin-bottom: 6px;
}

.tdblog-category-list a {
    text-decoration: none;
    color: inherit;
}

.tdblog-category-list li.active a {
    font-weight: 700;
}

.tdblog-rss-link a {
    font-size: 0.9em;
}

.tdblog-category-description {
    margin-bottom: 24px;
}

.tdblog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}

.tdblog-grid--products {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 900px) {
    .tdblog-grid { grid-template-columns: repeat(2, 1fr); }
    .tdblog-grid--products { grid-template-columns: repeat(3, 1fr); }
    .tdblog-sidebar { flex-basis: 100%; order: 2; }
}

@media (max-width: 600px) {
    .tdblog-grid { grid-template-columns: 1fr; }
    .tdblog-grid--products { grid-template-columns: repeat(2, 1fr); }
}

.tdblog-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
}

.tdblog-card-image {
    display: block;
    aspect-ratio: 4 / 3;
    background: #f4f4f4;
    overflow: hidden;
}

.tdblog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tdblog-card-image-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f0f0f0, #e2e2e2);
}

.tdblog-card-body {
    padding: 14px 16px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.tdblog-card-category {
    display: inline-block;
    font-size: 0.75em;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #8a6d3b;
    text-decoration: none;
    margin-bottom: 6px;
}

.tdblog-card-title {
    margin: 0 0 8px;
    font-size: 1.1em;
    line-height: 1.3;
}

.tdblog-card-title a {
    color: inherit;
    text-decoration: none;
}

.tdblog-card-excerpt {
    margin: 0 0 10px;
    font-size: 0.92em;
    color: #555;
    flex: 1;
}

.tdblog-card-meta {
    font-size: 0.82em;
    color: #888;
}

.tdblog-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    margin: 24px 0;
}

.tdblog-page-link,
.tdblog-page-current {
    display: inline-block;
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: inherit;
}

.tdblog-page-current {
    background: #222;
    color: #fff;
    border-color: #222;
}

/* Pojedynczy wpis */
.tdblog-single-header h1 {
    margin: 6px 0 10px;
}

.tdblog-single-cover {
    margin: 16px 0;
}

.tdblog-single-cover img {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    border-radius: 6px;
}

.tdblog-single-content {
    margin: 20px 0;
    line-height: 1.7;
}

.tdblog-single-content img {
    max-width: 100%;
    height: auto;
}

.tdblog-tags {
    margin: 20px 0;
}

.tdblog-tag {
    display: inline-block;
    background: #f2f2f2;
    border-radius: 999px;
    padding: 4px 12px;
    margin: 0 6px 6px 0;
    font-size: 0.85em;
    text-decoration: none;
    color: #444;
}

.tdblog-related-products,
.tdblog-related-posts {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid #eee;
}

.tdblog-product-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
    border-radius: 6px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    background: #fff;
}

.tdblog-product-card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.tdblog-product-name {
    padding: 10px 12px 2px;
    font-size: 0.92em;
    font-weight: 600;
}

.tdblog-product-price {
    padding: 0 12px 12px;
    color: #b5121b;
    font-weight: 700;
}

.tdblog-back-link {
    margin-top: 30px;
}
