/* ==========================================================================
   Ferticure Journal — PCOS & Women's Health Resource Library
   Scoped Stylesheet for india-pcos-pcod-blogs.php
   ========================================================================== */

.journal-page {
    width: 100%;
    margin: 0;
    padding: 0;
    color: #2d1822;
    background: #ffffff;
    font-family: var(--font-body, 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif);
}

.journal-container {
    width: 95%;
    max-width: 1560px;
    margin: 0 auto;
    padding: 0 16px;
    box-sizing: border-box;
}

/* --------------------------------------------------------------------------
   1. Hero & Search / Filter Controls
   -------------------------------------------------------------------------- */
.journal-hero {
    background: linear-gradient(180deg, #faf6f7 0%, #ffffff 100%);
    padding: 44px 0 36px;
    border-bottom: 1px solid #ebdcd6;
}

.journal-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    color: #7a666e;
    margin-bottom: 16px;
}

.journal-breadcrumb a {
    color: #7a666e;
    text-decoration: none;
    transition: color 0.15s ease;
}

.journal-breadcrumb a:hover {
    color: #a83d70;
}

.journal-hero-eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #a83d70;
    background: rgba(168, 61, 112, 0.08);
    padding: 5px 12px;
    border-radius: 20px;
    margin-bottom: 12px;
}

.journal-hero-title {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: clamp(30px, 3.8vw, 44px);
    line-height: 1.22;
    color: #2d1822;
    margin: 0 0 14px;
    font-weight: 700;
}

.journal-hero-intro {
    font-size: clamp(16px, 1.3vw, 18px);
    line-height: 1.65;
    color: #55444c;
    max-width: 860px;
    margin: 0 0 28px;
}

/* Search Bar */
.journal-search-panel {
    background: #ffffff;
    border: 1px solid #e5d7dc;
    border-radius: 16px;
    padding: 20px 24px;
    box-shadow: 0 4px 18px rgba(45, 24, 34, 0.04);
    margin-bottom: 24px;
}

.journal-search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.journal-search-icon {
    position: absolute;
    left: 16px;
    width: 20px;
    height: 20px;
    color: #8c737d;
    pointer-events: none;
}

.journal-search-input {
    width: 100%;
    height: 52px;
    padding: 12px 48px 12px 46px;
    font-size: 16px;
    color: #2d1822;
    background: #faf7f8;
    border: 1.5px solid #e0d0d6;
    border-radius: 12px;
    outline: none;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.journal-search-input:focus {
    background: #ffffff;
    border-color: #a83d70;
    box-shadow: 0 0 0 4px rgba(168, 61, 112, 0.12);
}

.journal-search-clear {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    font-size: 20px;
    line-height: 1;
    color: #8c737d;
    cursor: pointer;
    padding: 8px;
    display: none;
}

.journal-search-clear.visible {
    display: block;
}

.journal-search-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 14px;
    font-size: 13.5px;
    color: #6d5b63;
}

.journal-results-count {
    font-weight: 600;
    color: #2d1822;
}

.journal-helper-text {
    color: #7b6871;
    font-style: italic;
}

/* Category Filter Chips */
.journal-filter-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.journal-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: 28px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    color: #4a3840;
    background: #ffffff;
    border: 1.5px solid #e2d2d8;
    cursor: pointer;
    transition: all 0.2s ease;
}

.journal-filter-chip:hover {
    border-color: #a83d70;
    color: #a83d70;
    background: #fff8fa;
}

.journal-filter-chip.active {
    background: #5c3546;
    border-color: #5c3546;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(92, 53, 70, 0.25);
}

.journal-chip-count {
    font-size: 11.5px;
    opacity: 0.8;
    font-weight: 700;
}

/* --------------------------------------------------------------------------
   2. Featured Guides Section
   -------------------------------------------------------------------------- */
.journal-featured-section {
    padding: 44px 0 40px;
    background: #ffffff;
    border-bottom: 1px solid #ebdcd6;
}

.journal-featured-header {
    margin-bottom: 24px;
}

.journal-featured-header h2 {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: clamp(24px, 2.5vw, 30px);
    color: #2d1822;
    margin: 0 0 8px;
}

.journal-featured-header p {
    font-size: 15.5px;
    color: #635058;
    margin: 0;
}

.journal-featured-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

/* --------------------------------------------------------------------------
   3. Distinct Visual Identity for Each Category Section
   -------------------------------------------------------------------------- */
.journal-category-section {
    padding: 56px 0 60px;
    border-bottom: 1px solid rgba(45, 24, 34, 0.08);
    transition: background 0.3s ease;
}

/* Section Backgrounds per Requirement */
.journal-category-section.cat-pcos {
    background: #fff5f7; /* Very light blush pink */
    border-top: 1px solid #f6d8e0;
}

.journal-category-section.cat-fertility {
    background: #f8f4fb; /* Soft lavender */
    border-top: 1px solid #e7dcf5;
}

.journal-category-section.cat-menstrual-health {
    background: #f1f6fb; /* Pale powder blue */
    border-top: 1px solid #d3e4f6;
}

.journal-category-section.cat-nutrition {
    background: #f2f7f4; /* Light sage green */
    border-top: 1px solid #d3e7d9;
}

.journal-category-section.cat-lifestyle {
    background: #fdfbf7; /* Warm ivory */
    border-top: 1px solid #f3e9d8;
}

.journal-category-section.cat-aesthetics {
    background: #fbf5f3; /* Subtle rose-beige */
    border-top: 1px solid #eddcd6;
}

/* Category Headers */
.journal-cat-header {
    margin-bottom: 30px;
}

.journal-cat-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.cat-pcos .journal-cat-badge {
    background: #fadfe5;
    color: #8c264a;
}
.cat-fertility .journal-cat-badge {
    background: #ebdcf7;
    color: #603289;
}
.cat-menstrual-health .journal-cat-badge {
    background: #d8e8f8;
    color: #21517f;
}
.cat-nutrition .journal-cat-badge {
    background: #dbecdf;
    color: #286438;
}
.cat-lifestyle .journal-cat-badge {
    background: #f5eedb;
    color: #72591e;
}
.cat-aesthetics .journal-cat-badge {
    background: #f4e3dd;
    color: #834430;
}

.journal-cat-title {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: clamp(26px, 2.8vw, 34px);
    color: #2d1822;
    margin: 0 0 8px;
    font-weight: 700;
}

.journal-cat-desc {
    font-size: 15.5px;
    line-height: 1.6;
    color: #55444c;
    max-width: 760px;
    margin: 0 0 14px;
}

.journal-cat-rule {
    width: 60px;
    height: 3px;
    border-radius: 2px;
    margin: 0;
}

.cat-pcos .journal-cat-rule { background: #d95d82; }
.cat-fertility .journal-cat-rule { background: #8b52b8; }
.cat-menstrual-health .journal-cat-rule { background: #4079af; }
.cat-nutrition .journal-cat-rule { background: #4d8f5f; }
.cat-lifestyle .journal-cat-rule { background: #a6843b; }
.cat-aesthetics .journal-cat-rule { background: #b0654e; }

/* --------------------------------------------------------------------------
   4. Article Card Grid & Cards
   -------------------------------------------------------------------------- */
.journal-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.journal-card {
    background: #ffffff;
    border: 1px solid rgba(45, 24, 34, 0.08);
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}

.journal-card:hover,
.journal-card:focus-visible {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(45, 24, 34, 0.09);
    border-color: rgba(168, 61, 112, 0.35);
    outline: none;
}

.journal-card-media {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #f7f1ee;
}

.journal-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.journal-card:hover .journal-card-media img {
    transform: scale(1.03);
}

/* Fallback SVG Thumbnail */
.journal-card-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    text-align: center;
    box-sizing: border-box;
}

.journal-card-fallback svg {
    width: 44px;
    height: 44px;
    margin-bottom: 8px;
    opacity: 0.85;
}

.journal-card-fallback span {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.9;
}

.fallback-pcos { background: linear-gradient(135deg, #faedf0 0%, #f7dbe2 100%); color: #8c264a; }
.fallback-fertility { background: linear-gradient(135deg, #f5edf9 0%, #ebd8f5 100%); color: #603289; }
.fallback-menstrual-health { background: linear-gradient(135deg, #edf4fa 0%, #d5e5f5 100%); color: #21517f; }
.fallback-nutrition { background: linear-gradient(135deg, #edf5ef 0%, #d6ecd9 100%); color: #286438; }
.fallback-lifestyle { background: linear-gradient(135deg, #fbf7ee 0%, #f3e9d3 100%); color: #72591e; }
.fallback-aesthetics { background: linear-gradient(135deg, #f9f1ee 0%, #f0ded6 100%); color: #834430; }

.journal-card-body {
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.journal-card-eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #a83d70;
    margin-bottom: 8px;
}

.journal-card-title {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: 19px;
    line-height: 1.35;
    color: #2d1822;
    margin: 0 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.journal-card-intro {
    font-size: 14.5px;
    line-height: 1.6;
    color: #5f5258;
    margin: 0 0 18px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.journal-card-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13.5px;
    font-weight: 600;
    color: #a83d70;
    margin-top: auto;
    transition: gap 0.2s ease;
}

.journal-card:hover .journal-card-cta {
    gap: 10px;
}

/* View More Button */
.journal-view-more-wrap {
    text-align: center;
    margin-top: 32px;
}

.journal-view-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 24px;
    background: #ffffff;
    border: 1.5px solid #d8c7ce;
    border-radius: 30px;
    color: #5c3546;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.journal-view-more-btn:hover {
    background: #5c3546;
    border-color: #5c3546;
    color: #ffffff;
}

/* --------------------------------------------------------------------------
   5. Empty State
   -------------------------------------------------------------------------- */
.journal-empty-state {
    padding: 60px 24px;
    text-align: center;
    background: #faf6f7;
    border: 1px dashed #d9c5cc;
    border-radius: 16px;
    margin: 40px 0;
    display: none;
}

.journal-empty-state.visible {
    display: block;
}

.journal-empty-icon {
    width: 48px;
    height: 48px;
    color: #8c737d;
    margin: 0 auto 16px;
}

.journal-empty-title {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: 22px;
    color: #2d1822;
    margin: 0 0 8px;
}

.journal-empty-text {
    font-size: 15px;
    color: #6d5b63;
    max-width: 480px;
    margin: 0 auto 20px;
}

.journal-reset-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 22px;
    background: #a83d70;
    color: #ffffff;
    border: none;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.journal-reset-btn:hover {
    background: #8b2856;
}

/* --------------------------------------------------------------------------
   6. Closing Consultation CTA Section
   -------------------------------------------------------------------------- */
.journal-closing-cta {
    background: linear-gradient(135deg, #fbf7f8 0%, #f6eff1 100%);
    padding: 64px 0;
    border-top: 1px solid #ebdcd6;
}

.journal-cta-box {
    background: #ffffff;
    border: 1px solid #ebd8df;
    border-radius: 20px;
    padding: 44px 48px;
    box-shadow: 0 8px 30px rgba(92, 53, 70, 0.05);
    max-width: 960px;
    margin: 0 auto;
    text-align: center;
}

.journal-cta-box h2 {
    font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
    font-size: clamp(24px, 2.8vw, 32px);
    color: #2d1822;
    margin: 0 0 14px;
}

.journal-cta-box p {
    font-size: 16px;
    line-height: 1.65;
    color: #55444c;
    margin: 0 auto 28px;
    max-width: 720px;
}

.journal-cta-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.journal-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 28px;
    background: #a83d70;
    color: #ffffff;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 14px rgba(168, 61, 112, 0.25);
}

.journal-btn-primary:hover {
    background: #8b2856;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(168, 61, 112, 0.35);
}

.journal-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 26px;
    background: #ffffff;
    color: #2d1822;
    text-decoration: none;
    border: 1.5px solid #d4c2c9;
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.2s ease;
}

.journal-btn-secondary:hover {
    border-color: #a83d70;
    color: #a83d70;
    background: #fff8fa;
}

/* --------------------------------------------------------------------------
   7. Responsive Viewports
   -------------------------------------------------------------------------- */
@media (max-width: 1200px) {
    .journal-featured-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 992px) {
    .journal-cards-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
    }
    .journal-cta-box {
        padding: 32px 24px;
    }
}

@media (max-width: 640px) {
    .journal-hero {
        padding: 28px 0 24px;
    }
    .journal-cards-grid,
    .journal-featured-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .journal-search-panel {
        padding: 16px;
    }
    .journal-search-input {
        height: 48px;
        font-size: 15px;
    }
    .journal-filter-nav {
        gap: 8px;
    }
    .journal-filter-chip {
        padding: 7px 14px;
        font-size: 13px;
    }
    .journal-category-section {
        padding: 40px 0 44px;
    }
    .journal-cta-buttons {
        flex-direction: column;
        width: 100%;
    }
    .journal-btn-primary,
    .journal-btn-secondary {
        width: 100%;
        justify-content: center;
        box-sizing: border-box;
    }
}
