/* ==========================================================
   BLOG — listing grid, category/tag filters, post detail
   Part of the CiaoCity modular stylesheet system.
   New file — extends the existing theme, does not redefine it.
   Reuses: --primary, --radius-*, --glass-*, .glass-panel from base.css
   ========================================================== */

/* ---- Blog filter bar (mirrors .filter-section) ---- */
.blog-filters-wrapper {
    padding: 10px 14px;
    margin-bottom: 28px;
    border-radius: var(--radius-pill);
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.blog-search-wrapper {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-color);
    border-radius: var(--radius-pill);
    padding: 10px 18px;
    transition: all 0.25s ease;
    box-sizing: border-box;
}

.blog-search-wrapper:focus-within {
    background: white;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.blog-search-wrapper i {
    color: var(--text-muted);
    font-size: 1.1rem;
    flex-shrink: 0;
}

.blog-search-wrapper input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 0.9rem;
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text-main);
    min-width: 0;
}

.blog-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.blog-filter-bar:empty { display: none; }

.blog-filter-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 4px;
}

.blog-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(0,0,0,0.05);
    background: white;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.blog-chip:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.blog-chip.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.3);
}

/* ---- Blog list grid (mirrors .cities-grid / .city-card) ---- */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.blog-card {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--glass-shadow);
    border: 1px solid rgba(0,0,0,0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px -12px rgba(0,0,0,0.14);
}

.blog-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card-image {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.blog-card:hover .blog-card-image img { transform: scale(1.06); }

.blog-card-category {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(8px);
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.blog-card-body {
    padding: 18px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
}

.blog-card-meta i { font-size: 0.9rem; }

.blog-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.35;
}

.blog-card-excerpt {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
    flex: 1;
}

.blog-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.blog-tag {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--primary);
    background: rgba(79, 70, 229, 0.08);
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    text-decoration: none;
}

.blog-tag:hover { background: rgba(79, 70, 229, 0.16); }

.blog-empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.blog-empty-state i {
    font-size: 3rem;
    display: block;
    margin-bottom: 16px;
    color: var(--text-muted);
}

.blog-empty-state h3 {
    font-size: 1.2rem;
    color: var(--text-main);
    margin-bottom: 8px;
}

/* ---- Blog teaser section on home page ---- */
.blog-teaser-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 48px 0 20px;
}

.blog-teaser-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-main);
}

.blog-teaser-header a {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ---- Single post page ---- */
.post-hero {
    position: relative;
    height: 46vh;
    min-height: 340px;
    border-radius: var(--radius-lg);
    margin: 0 24px 32px;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
}

.post-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.75) 100%);
}

.post-hero-content {
    position: relative;
    z-index: 2;
    padding: 36px 40px;
    color: white;
    max-width: 780px;
}

.post-category-badge {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(8px);
    padding: 5px 16px;
    border-radius: var(--radius-pill);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border: 1px solid rgba(255,255,255,0.15);
    margin-bottom: 14px;
}

.post-hero-content h1 {
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.25;
    text-shadow: 0 2px 20px rgba(0,0,0,0.35);
    margin-bottom: 14px;
}

.post-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    font-size: 0.85rem;
    opacity: 0.92;
}

.post-hero-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-body {
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--glass-shadow);
    border: 1px solid rgba(0,0,0,0.04);
    padding: 36px 40px;
    margin-bottom: 24px;
}

.post-content p {
    font-size: 1rem;
    line-height: 1.75;
    color: var(--text-main);
    margin-bottom: 20px;
}

.post-content h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 32px 0 14px;
    color: var(--text-main);
}

.post-content h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 26px 0 12px;
    color: var(--text-main);
}

.post-content blockquote {
    border-left: 3px solid var(--primary);
    padding: 4px 20px;
    margin: 24px 0;
    font-style: italic;
    color: var(--text-muted);
    font-size: 1.05rem;
}

.post-content figure {
    margin: 24px 0;
}

.post-content figure img {
    width: 100%;
    border-radius: var(--radius-sm);
    display: block;
}

.post-content figcaption {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 8px;
    text-align: center;
}

.post-tags-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid rgba(0,0,0,0.06);
}

.post-share-row {
    margin-top: 20px;
}

.post-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(0,0,0,0.1);
    background: white;
    color: var(--text-main);
    font-size: 0.88rem;
    font-weight: 600;
    font-family: 'Plus Jakarta Sans', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
}

.post-share-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.post-share-btn i {
    font-size: 1.05rem;
}

.post-related-header {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 8px 0 18px;
}
