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

:root {
    --primary: #f59e0b;
    --primary-light: #fef3c7;
    --primary-dark: #d97706;
    --dark: #0f172a;
    --dark2: #1e293b;
    --text: #1e293b;
    --muted: #64748b;
    --border: #e2e8f0;
    --bg: #f8fafc;
    --white: #ffffff;
    --radius: 14px;
    --shadow: 0 2px 20px rgba(0,0,0,0.05);
}

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
}

/* ===========================
   PRELOADER
=========================== */
#preloader {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: white;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s ease;
}

.preloader-logo {
    width: 90px; height: 90px;
    background: white;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    animation: preloaderSpin 3s linear infinite;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    overflow: hidden;
    padding: 10px;
    border: 1px solid var(--border);
}

.preloader-logo img { width: 100%; height: 100%; object-fit: contain; }

.preloader-text {
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 0.5rem;
    color: var(--dark);
    animation: preloaderPulse 1.5s infinite;
}

.preloader-sub {
    font-size: 0.7rem;
    color: var(--muted);
    margin-top: 8px;
    font-weight: 600;
}

@keyframes preloaderSpin {
    0%   { transform: rotate(0deg) scale(1); }
    50%  { transform: rotate(180deg) scale(1.1); }
    100% { transform: rotate(360deg) scale(1); }
}

@keyframes preloaderPulse {
    0%, 100% { opacity: 0.4; }
    50%       { opacity: 1; }
}

/* ===========================
   NAVBAR
=========================== */
.fp-nav {
    background: white;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 8px rgba(0,0,0,0.04);
}

.fp-nav-inner {
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 30px;
    height: 58px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.fp-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}

.fp-logo-icon {
    width: 36px; height: 36px;
    background: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid var(--border);
    padding: 3px;
}

.fp-logo-icon img { width: 100%; height: 100%; object-fit: contain; }

.fp-logo-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--dark);
}

/* Navbar Search */
.fp-nav-search {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0 15px;
    max-width: 500px;
    transition: border-color 0.2s;
}

.fp-nav-search:focus-within { border-color: var(--primary); }

.fp-nav-search i { color: var(--muted); font-size: 0.85rem; }

.fp-nav-search input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    padding: 9px 0;
    font-size: 0.875rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 500;
    color: var(--text);
}

.fp-nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}

.fp-nav-links a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: color 0.2s;
    white-space: nowrap;
}

.fp-nav-links a:hover { color: var(--primary); }

.fp-nav-ai {
    background: var(--primary) !important;
    color: white !important;
    padding: 8px 16px;
    border-radius: 50px;
    font-weight: 700 !important;
}

.fp-nav-ai:hover { background: var(--primary-dark) !important; }

/* ===========================
   HERO
=========================== */
.fp-hero {
    background: linear-gradient(135deg, #0f172a 0%, #1a3558 100%);
    padding: 70px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.fp-hero::before {
    content: '';
    position: absolute;
    top: -80px; left: -80px;
    width: 500px; height: 500px;
    background: radial-gradient(circle, rgba(245,158,11,0.12) 0%, transparent 70%);
    pointer-events: none;
}

.fp-hero::after {
    content: '';
    position: absolute;
    bottom: -80px; right: -80px;
    width: 400px; height: 400px;
    background: radial-gradient(circle, rgba(59,130,246,0.08) 0%, transparent 70%);
    pointer-events: none;
}

.fp-hero-inner { position: relative; z-index: 1; }

.fp-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(245,158,11,0.15);
    color: var(--primary);
    border: 1px solid rgba(245,158,11,0.3);
    padding: 6px 18px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15rem;
    margin-bottom: 22px;
}

.fp-hero h1 {
    font-size: clamp(2rem, 5vw, 3.8rem);
    font-weight: 800;
    color: white;
    margin-bottom: 12px;
    letter-spacing: -0.05rem;
    line-height: 1.1;
}

.fp-hero h1 span { color: var(--primary); }

.fp-hero p {
    color: rgba(255,255,255,0.5);
    font-size: 1rem;
    margin-bottom: 35px;
    max-width: 580px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.fp-search-box {
    max-width: 660px;
    margin: 0 auto 25px;
    background: white;
    border-radius: 16px;
    display: flex;
    align-items: center;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}

.fp-search-icon { padding: 0 14px 0 20px; color: var(--muted); }

.fp-search-box input {
    flex: 1;
    padding: 18px 0;
    border: none;
    outline: none;
    font-size: 1rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 500;
    color: var(--text);
}

.fp-search-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 18px 26px;
    font-size: 0.875rem;
    font-weight: 800;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: background 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    flex-shrink: 0;
}

.fp-search-btn:hover { background: var(--primary-dark); }

.fp-popular-tags {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.fp-tag-label {
    color: rgba(255,255,255,0.4);
    font-size: 0.78rem;
    font-weight: 600;
}

.fp-popular-tags a {
    color: rgba(255,255,255,0.65);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    background: rgba(255,255,255,0.08);
    padding: 5px 13px;
    border-radius: 50px;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.2s;
}

.fp-popular-tags a:hover {
    background: rgba(245,158,11,0.2);
    border-color: rgba(245,158,11,0.4);
    color: var(--primary);
}

/* ===========================
   STATS BAR
=========================== */
.fp-stats-bar {
    background: white;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 30px;
    gap: 25px;
    flex-wrap: wrap;
}

.fp-stat { font-size: 0.82rem; color: var(--muted); font-weight: 600; }
.fp-stat strong { color: var(--dark); font-weight: 800; }
.fp-stat-divider { width: 1px; height: 18px; background: var(--border); }

/* ===========================
   3-COLUMN LAYOUT (HOME)
=========================== */
.fp-three-col {
    max-width: 1500px;
    margin: 0 auto;
    padding: 30px;
    display: grid;
    grid-template-columns: 220px 1fr 300px;
    gap: 25px;
    align-items: start;
}

/* ===========================
   WIKI NAVIGATION SIDEBAR
=========================== */
.fp-wiki-nav {
    position: sticky;
    top: 78px;
}

.wiki-nav-section {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 15px;
    box-shadow: var(--shadow);
}

.wiki-nav-title {
    background: var(--dark);
    color: white;
    padding: 10px 14px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.wiki-nav-list {
    list-style: none;
    padding: 6px 0;
}

.wiki-nav-list li a {
    display: block;
    padding: 5px 14px;
    font-size: 0.8rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: background 0.15s;
}

.wiki-nav-list li a:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.wiki-nav-group-label {
    padding: 6px 14px 2px;
    font-size: 0.62rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12rem;
    color: var(--muted);
    border-top: 1px solid var(--border);
    margin-top: 2px;
}

.wiki-nav-group-label:first-child { border-top: none; margin-top: 0; }

.wiki-ai-promo {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, var(--dark), #1e3a5f);
    color: white;
    padding: 14px;
    border-radius: var(--radius);
    text-decoration: none;
    font-size: 0.8rem;
    transition: opacity 0.2s;
    border: 1px solid rgba(255,255,255,0.08);
}

.wiki-ai-promo:hover { opacity: 0.9; }

.wiki-ai-promo div:first-child { font-size: 1.5rem; }

.wiki-ai-promo strong {
    display: block;
    font-weight: 800;
    margin-bottom: 2px;
    color: var(--primary);
}

.wiki-ai-promo p { font-size: 0.72rem; opacity: 0.5; margin: 0; }

/* ===========================
   CARDS
=========================== */
.fp-card {
    background: white;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
    margin-bottom: 22px;
    box-shadow: var(--shadow);
}

.fp-card-header {
    padding: 13px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fafafa;
}

.fp-card-title {
    font-size: 0.67rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.18rem;
    color: var(--primary);
}

.fp-card-date { font-size: 0.75rem; color: var(--muted); font-weight: 600; }
.fp-card-link { font-size: 0.75rem; color: var(--primary); font-weight: 700; text-decoration: none; }
.fp-card-link:hover { text-decoration: underline; }
.fp-card-body { padding: 20px; }

/* ===========================
   FEATURED ARTICLE
=========================== */
.fp-featured-img {
    width: 100%; height: 190px;
    background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
    display: flex; align-items: center; justify-content: center;
    font-size: 5rem;
}

.fp-featured-content { padding: 20px; }

.fp-tag {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.62rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    margin-bottom: 10px;
}

.fp-tag-cuisine { background: var(--primary-light); color: var(--primary); }

.fp-featured-title {
    font-family: 'Lora', serif;
    font-size: 1.45rem;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 10px;
    line-height: 1.3;
}

.fp-featured-excerpt {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.75;
    margin-bottom: 16px;
}

.fp-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 800;
    text-decoration: none;
    font-size: 0.82rem;
    transition: gap 0.2s;
}

.fp-read-more:hover { gap: 14px; }

/* ===========================
   DID YOU KNOW
=========================== */
.fp-dyk-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.fp-dyk-list li {
    font-size: 0.875rem;
    line-height: 1.65;
    color: var(--text);
    padding-left: 16px;
    position: relative;
}

.fp-dyk-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: 900;
    font-size: 1rem;
}

/* ===========================
   ARTICLE LIST
=========================== */
.fp-article-list { padding: 5px 0; }

.fp-article-item {
    display: flex;
    gap: 15px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

.fp-article-item:last-child { border-bottom: none; }

.fp-article-item:hover { 
    background: #f8fafc;
    padding-left: 25px;
}

.fp-article-emoji {
    width: 52px; height: 52px;
    min-width: 52px;
    background: white;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem;
    border: 1px solid var(--border);
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.fp-article-tag {
    font-size: 0.62rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12rem;
    margin-bottom: 4px;
}

.fp-article-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.35;
    transition: color 0.2s;
}

.fp-article-meta { font-size: 0.7rem; color: var(--muted); margin-top: 3px; }

/* ===========================
   IN THE NEWS
=========================== */
.fp-news-item {
    display: flex;
    gap: 14px;
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.fp-news-item:last-child { border-bottom: none; }

.fp-news-date {
    min-width: 38px;
    font-size: 0.68rem;
    font-weight: 800;
    color: var(--primary);
    text-transform: uppercase;
    padding-top: 2px;
}

.fp-news-text { font-size: 0.845rem; line-height: 1.6; color: var(--text); }

/* ===========================
   RIGHT SIDEBAR WIDGETS
=========================== */
.fp-sidebar { position: sticky; top: 78px; }

.fp-cat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.fp-cat {
    padding: 12px 10px;
    border-radius: 11px;
    font-size: 0.72rem;
    font-weight: 700;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.15s;
    line-height: 1.6;
    display: block;
}

.fp-cat:hover { transform: translateY(-2px); }

.fp-otd-date {
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.fp-otd-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.fp-otd-list li { font-size: 0.8rem; line-height: 1.6; color: var(--text); }

.fp-stat-list { padding: 4px 20px; }

.fp-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 9px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.82rem;
    color: var(--muted);
}

.fp-stat-row:last-child { border-bottom: none; }
.fp-stat-row strong { color: var(--primary); font-weight: 800; }

.fp-random-card { background: var(--dark); }
.fp-random-card h4, .fp-random-card p { color: rgba(255,255,255,0.85); }

.fp-random-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 11px 22px;
    border-radius: 11px;
    font-weight: 800;
    font-size: 0.78rem;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: background 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
}

.fp-random-btn:hover { background: var(--primary-dark); }

/* ===========================
   FOOTER
=========================== */
.fp-footer {
    background: var(--dark);
    padding: 45px 30px;
    text-align: center;
}

.fp-footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
    color: white;
    font-size: 1.15rem;
}

.fp-footer-desc { color: rgba(255,255,255,0.35); font-size: 0.82rem; margin-bottom: 18px; }

.fp-footer-links {
    display: flex;
    justify-content: center;
    gap: 22px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.fp-footer-links a {
    color: rgba(255,255,255,0.35);
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 600;
    transition: color 0.2s;
}

.fp-footer-links a:hover { color: var(--primary); }
.fp-footer-copy { color: rgba(255,255,255,0.2); font-size: 0.72rem; }


/* ===========================
   ARTICLE PAGE – 3-COL LAYOUT
=========================== */
.article-nav-breadcrumb {
    background: white;
    border-bottom: 1px solid var(--border);
    padding: 10px 30px;
    font-size: 0.78rem;
    color: var(--muted);
    font-weight: 600;
}

.article-nav-breadcrumb a { color: var(--primary); text-decoration: none; }
.article-nav-breadcrumb a:hover { text-decoration: underline; }

.article-three-col {
    max-width: 1500px;
    margin: 0 auto;
    padding: 28px 30px;
    display: grid;
    grid-template-columns: 200px 1fr 280px;
    gap: 25px;
    align-items: start;
}

/* Wiki nav on article pages (slightly compact) */
.fp-wiki-nav-article .wiki-nav-list li a { font-size: 0.77rem; padding: 4px 13px; }

/* ===========================
   ARTICLE BODY
=========================== */
.article-body {
    background: white;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    padding: 36px;
    box-shadow: var(--shadow);
}

.article-title {
    font-family: 'Lora', serif;
    font-size: 2.1rem;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 8px;
    line-height: 1.2;
    border-bottom: 3px solid var(--primary);
    padding-bottom: 14px;
}

.article-subtitle {
    color: var(--muted);
    font-size: 0.95rem;
    margin-bottom: 18px;
    font-style: italic;
    line-height: 1.5;
}

.article-meta-bar {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    padding: 10px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    margin-bottom: 22px;
    font-size: 0.76rem;
    color: var(--muted);
    font-weight: 600;
}

.article-meta-bar span { display: flex; align-items: center; gap: 5px; }

/* ===========================
   ENHANCED INFOBOX / QUICK SUMMARY BOX
=========================== */
.article-infobox {
    float: right;
    margin: 0 0 22px 22px;
    width: 270px;
    background: #fafafa;
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    font-size: 0.8rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.article-infobox-img {
    width: 100%;
    height: 150px;
    background: linear-gradient(135deg, var(--primary) 0%, #ef4444 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.article-infobox-title {
    background: var(--dark);
    color: white;
    padding: 10px 14px;
    font-weight: 800;
    font-size: 0.88rem;
    text-align: center;
    letter-spacing: 0.02rem;
}

.article-infobox-row {
    display: flex;
    border-bottom: 1px solid var(--border);
    padding: 8px 12px;
    gap: 8px;
    align-items: flex-start;
}

.article-infobox-row:last-of-type { border-bottom: none; }

.infobox-label {
    color: var(--muted);
    font-weight: 700;
    min-width: 85px;
    font-size: 0.72rem;
    padding-top: 1px;
    line-height: 1.4;
}

.infobox-value {
    color: var(--dark);
    font-weight: 600;
    font-size: 0.78rem;
    line-height: 1.4;
    flex: 1;
}

/* Scientific name in italic */
.infobox-scientific {
    font-style: italic;
    color: var(--primary-dark) !important;
    font-weight: 700 !important;
}

/* Health Benefits inside infobox */
.infobox-benefits-header {
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 8px 12px;
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12rem;
    border-top: 1px solid var(--border);
}

.infobox-benefits-list {
    list-style: none;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    background: white;
}

.infobox-benefits-list li {
    font-size: 0.74rem;
    line-height: 1.5;
    color: var(--text);
    padding-left: 14px;
    position: relative;
}

.infobox-benefits-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #16a34a;
    font-weight: 900;
    font-size: 0.7rem;
}

/* ===========================
   TABLE OF CONTENTS
=========================== */
.article-toc {
    background: #f8f9fa;
    border: 1px solid #a2a9b1;
    padding: 12px 18px;
    margin-bottom: 24px;
    display: inline-block;
    min-width: 280px;
    font-size: 0.85rem;
    clear: none;
}

.article-toc-title {
    font-weight: 700;
    font-size: 0.9rem;
    color: black;
    text-align: center;
    margin-bottom: 8px;
    text-transform: none;
    letter-spacing: normal;
}

.wiki-edit-toc {
    font-weight: normal;
    font-size: 0.75rem;
    margin-left: 8px;
}

.wiki-edit-toc a { color: #0645ad !important; text-decoration: none; }
.wiki-edit-toc a:hover { text-decoration: underline; }

.article-toc ol { padding-left: 0; list-style-type: none; margin-top: 8px; }
.article-toc li { padding: 3px 0; }
.article-toc a { color: #0645ad; text-decoration: none; font-weight: normal; }
.article-toc a:hover { text-decoration: underline; }
.toc-number { color: black; font-weight: 600; margin-right: 6px; }

/* ===========================
   ARTICLE SECTIONS
=========================== */
.article-section { margin-bottom: 28px; clear: both; }

.wiki-intro {
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 22px;
    color: var(--text);
}

.wiki-heading {
    font-family: 'Lora', serif;
    font-size: 1.6rem;
    font-weight: normal;
    color: black;
    margin-bottom: 10px;
    padding-bottom: 4px;
    border-bottom: 1px solid #a2a9b1;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
}

.wiki-edit {
    font-family: 'Outfit', sans-serif;
    font-size: 0.75rem;
    font-weight: normal;
    color: var(--text);
}

.wiki-edit a { color: #0645ad; text-decoration: none; }
.wiki-edit a:hover { text-decoration: underline; }

.wiki-subheading {
    font-size: 1.15rem;
    font-weight: 700;
    color: black;
    margin-bottom: 8px;
    margin-top: 18px;
}

.article-section p {
    font-size: 0.9rem;
    line-height: 1.8;
    color: var(--text);
    margin-bottom: 10px;
}

.article-section ul, .article-section ol {
    padding-left: 20px;
    margin-bottom: 10px;
}

.article-section li {
    font-size: 0.88rem;
    line-height: 1.7;
    color: var(--text);
    margin-bottom: 4px;
}

/* ===========================
   NUTRITION GRID
=========================== */
.article-nutrition-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin: 16px 0;
}

.nutrition-cell {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px;
    text-align: center;
    transition: border-color 0.2s;
}

.nutrition-cell:hover { border-color: var(--primary); }

.nutrition-value {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--primary);
}

.nutrition-label {
    font-size: 0.65rem;
    color: var(--muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08rem;
    margin-top: 3px;
}

/* ===========================
   ARTICLE CATEGORIES
=========================== */
.article-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
    margin-top: 18px;
}

.article-cat-tag {
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 4px 13px;
    border-radius: 20px;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08rem;
    text-decoration: none;
    transition: background 0.15s;
}

.article-cat-tag:hover { background: var(--primary); color: white; }

/* Article sidebar */
.article-sidebar { position: sticky; top: 78px; }

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE OPTIMIZATION)
   ========================================================================== */

@media (max-width: 1200px) {
    .fp-three-col {
        grid-template-columns: 240px 1fr;
    }
    .fp-latest-sidebar {
        display: none; /* Hide latest on medium screens to keep it clean */
    }
}

@media (max-width: 1024px) {
    .fp-nav-search {
        max-width: 300px;
    }
}

@media (max-width: 768px) {
    /* Navbar stacking - More compact and centered */
    .fp-nav-inner {
        padding: 12px 15px;
        height: auto;
        flex-direction: column;
        gap: 12px;
    }
    .fp-logo {
        justify-content: center;
        margin-bottom: 2px;
    }
    .fp-nav-links {
        width: 100%;
        justify-content: center;
        gap: 15px;
        font-size: 0.85rem;
    }
    .fp-nav-search {
        max-width: 100%;
        width: 100%;
        height: 40px;
    }
    .fp-hero {
        padding: 50px 20px;
    }
    .fp-hero h1 {
        font-size: 2.2rem;
    }
    .fp-search-box {
        flex-direction: column;
        background: transparent;
        box-shadow: none;
    }
    .fp-search-box input {
        width: 100%;
        background: white;
        border-radius: 12px;
        margin-bottom: 10px;
        padding: 15px;
        box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    }
    .fp-search-btn {
        width: 100%;
        border-radius: 12px;
        padding: 15px;
    }

    /* Popular tags */
    .fp-popular-tags {
        flex-wrap: wrap;
        gap: 8px;
    }

    /* Stats bar */
    .fp-stats-bar {
        flex-direction: column;
        padding: 20px;
        gap: 15px;
    }
    .fp-stat-divider {
        display: none;
    }

    /* Main layout stacking */
    .fp-three-col {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    .fp-wiki-nav {
        display: none; /* Hide wiki sidebar on mobile for cleaner view */
    }

    /* Article items */
    .fp-article-item {
        flex-direction: column;
    }
    .fp-article-item > div:first-child {
        width: 100% !important;
        height: 180px !important;
        margin-bottom: 15px;
        margin-right: 0 !important;
    }

    /* Section headers */
    .fp-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    /* Footer */
    .fp-footer {
        padding: 50px 20px;
        text-align: center;
    }
    .fp-footer-logo {
        justify-content: center;
    }
    .fp-footer-links {
        justify-content: center;
        flex-wrap: wrap;
    }

    /* Article Pages Stacking */
    .article-three-col {
        grid-template-columns: 1fr;
        padding: 15px;
    }
    .article-nav-breadcrumb {
        padding: 10px 15px;
    }
    .article-body {
        padding: 24px 20px;
    }
    .article-title {
        font-size: 1.7rem;
    }
    .article-meta-bar {
        flex-direction: column;
        gap: 10px;
    }
    .article-infobox {
        float: none;
        width: 100%;
        margin: 20px 0;
    }
    .article-infobox-img {
        height: 200px;
    }
    .article-toc {
        display: block;
        width: 100%;
        min-width: 0;
    }
    .article-sidebar {
        position: static;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .fp-hero h1 {
        font-size: 1.8rem;
    }
    .article-nutrition-grid {
        grid-template-columns: 1fr;
    }
    .article-meta-box {
        grid-template-columns: 1fr 1fr;
    }
    .fp-article-title {
        font-size: 1.4rem;
    }
}
