/* === FundedXYZ Blog Styles — Matches fundedxyz.com design system === */

:root {
    --bg-dark: #0D0D1A;
    --bg-medium: #121224;
    --bg-light: #1A1A2E;
    --primary-color: #3D52D5;
    --secondary-color: #8A2BE2;
    --text-color: #E0E0E0;
    --text-muted: #A0A0B9;
    --font-family: 'Poppins', sans-serif;
    --border-radius: 12px;
    --transition-speed: 0.3s ease;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-family);
    background-color: var(--bg-dark);
    color: var(--text-color);
    line-height: 1.7;
    overflow-x: hidden;
}

a { color: var(--secondary-color); text-decoration: none; transition: color var(--transition-speed); }
a:hover { color: #a855f7; }

img { max-width: 100%; height: auto; }

/* === Layout === */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.article-container { max-width: 820px; margin: 0 auto; padding: 0 24px; }

/* === Header === */
/* ===== UNIFIED NAV WITH DROPDOWNS ===== */
.header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    padding: 14px 0;
    background: rgba(10,10,15,0.92); backdrop-filter: blur(24px);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    box-shadow: 0 4px 30px rgba(0,0,0,0.3);
    transition: all 0.4s ease;
}
.header .container { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.logo { flex-shrink: 0; display: inline-flex; align-items: center; text-decoration: none; }
.logo img { height: auto; }
.nav { flex: 1; display: flex; align-items: center; justify-content: center; }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; }
.nav-item { position: relative; }
.nav-link {
    display: flex; align-items: center; gap: 4px;
    padding: 8px 14px; border-radius: 8px;
    font-size: 14px; font-weight: 500; color: rgba(160,160,176,1);
    transition: all 0.2s; cursor: pointer; white-space: nowrap;
    background: none; border: none; font-family: inherit;
    text-decoration: none;
}
.nav-link:hover { color: white; background: rgba(255,255,255,0.05); }
.nav-link .caret {
    width: 14px; height: 14px; transition: transform 0.3s;
    opacity: 0.5;
}
.nav-item:hover .caret { transform: rotate(180deg); }
.nav-dropdown {
    position: absolute; top: 100%; left: 50%;
    transform: translateX(-50%) translateY(8px);
    background: rgba(14,14,22,0.98); border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px; backdrop-filter: blur(24px);
    padding: 8px; padding-top: 20px; min-width: 220px;
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.04);
}
.nav-dropdown::before {
    content: ''; position: absolute; top: -12px; left: 0; right: 0; height: 12px;
}
.nav-item:hover .nav-dropdown {
    opacity: 1; visibility: visible; pointer-events: all;
    transform: translateX(-50%) translateY(0);
}
.nav-dropdown-item {
    display: flex; align-items: flex-start; gap: 12px;
    padding: 12px 14px; border-radius: 10px;
    color: rgba(160,160,176,1); font-size: 14px;
    transition: all 0.2s; text-decoration: none;
}
.nav-dropdown-item:hover { color: white; background: rgba(255,255,255,0.05); }
.nav-dropdown-icon {
    width: 32px; height: 32px; border-radius: 8px;
    background: rgba(108,92,231,0.15); border: 1px solid rgba(108,92,231,0.2);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.nav-dropdown-icon svg { width: 16px; height: 16px; }
.nav-dropdown-text strong { display: block; font-weight: 600; color: #fff; font-size: 14px; margin-bottom: 2px; }
.nav-dropdown-text span { font-size: 12px; color: #6b6b7b; }
.nav-dropdown-divider { height: 1px; background: rgba(255,255,255,0.06); margin: 6px 0; }
.nav-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.nav-login-btn {
    padding: 8px 18px; border-radius: 50px; font-size: 14px;
    font-weight: 600; color: rgba(160,160,176,1); border: 1px solid rgba(255,255,255,0.08);
    background: none; font-family: inherit; cursor: pointer;
    transition: all 0.2s; text-decoration: none;
}
.nav-login-btn:hover { color: white; border-color: #6c5ce7; }
.header .btn-primary { padding: 10px 22px; font-size: 14px; }
.header .btn-primary.show { display: inline-flex; }
.mobile-toggle {
    display: none; background: none; border: none;
    color: white; cursor: pointer; padding: 4px;
}
.mobile-nav {
    display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(10,10,15,0.98); backdrop-filter: blur(20px); z-index: 9999;
    flex-direction: column; align-items: center; justify-content: center; gap: 8px;
    overflow-y: auto; padding: 20px;
}
.mobile-nav.active { display: flex; }
.mobile-nav-link {
    font-size: 20px; font-weight: 600; color: rgba(160,160,176,1);
    padding: 12px 32px; border-radius: 12px; width: 100%; max-width: 300px;
    text-align: center; transition: all 0.2s; text-decoration: none;
}
.mobile-nav-link:hover { color: white; background: rgba(255,255,255,0.04); }
.mobile-nav .close-btn {
    position: fixed; top: 20px; right: 24px;
    background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
    color: white; cursor: pointer; padding: 8px; border-radius: 10px;
}
.mobile-nav-section-label {
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 2px; color: #6c5ce7; margin-top: 12px; margin-bottom: 0;
    width: 100%; max-width: 300px; text-align: center;
}
.menu-toggle { display: none; }

.btn {
    display: inline-block; padding: 10px 24px; border-radius: 50px;
    text-decoration: none; font-weight: 500; font-size: 0.95rem;
    transition: all var(--transition-speed); border: none; cursor: pointer;
}
.btn-primary {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: #fff;
}
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(57, 65, 179, 0.3);
    color: #fff;
}
.btn-large { padding: 14px 32px; font-size: 1rem; }

/* Mobile menu */
.menu-toggle { display: none; background: none; border: none; color: #fff; font-size: 1.5rem; cursor: pointer; }

/* === Hero / Page Header === */
.page-hero {
    padding: 140px 0 60px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-dark) 0%, rgba(61, 82, 213, 0.08) 100%);
}
.page-hero h1 {
    font-size: 3rem; font-weight: 700; line-height: 1.2; margin-bottom: 16px; color: #fff;
}
.page-hero .gradient-text {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.page-hero p {
    font-size: 1.1rem; color: var(--text-muted); max-width: 640px; margin: 0 auto;
}

/* === Blog Index Grid === */
.blog-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 28px; padding: 60px 0 80px;
}
.blog-card {
    background: rgba(22, 22, 42, 0.5);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: var(--border-radius); overflow: hidden;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}
.blog-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(61, 82, 213, 0.15);
}
.blog-card-img {
    width: 100%; height: 200px; object-fit: cover;
    background: linear-gradient(135deg, var(--bg-medium), var(--bg-light));
}
.blog-card-body { padding: 24px; }
.blog-card-category {
    display: inline-block; font-size: 0.75rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 1px; color: var(--secondary-color); margin-bottom: 10px;
}
.blog-card-body h3 {
    font-size: 1.2rem; font-weight: 600; color: #fff; margin-bottom: 10px; line-height: 1.4;
}
.blog-card-body h3 a { color: #fff; }
.blog-card-body h3 a:hover { color: var(--secondary-color); }
.blog-card-body p {
    font-size: 0.92rem; color: var(--text-muted); margin-bottom: 16px;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.blog-card-meta {
    display: flex; justify-content: space-between; align-items: center;
    font-size: 0.8rem; color: var(--text-muted);
}
.blog-card-meta .author { font-weight: 500; color: var(--text-color); }

/* Category filter */
.category-filter {
    display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
    padding: 0 0 20px;
}
.category-filter a {
    padding: 8px 20px; border-radius: 50px; font-size: 0.85rem; font-weight: 500;
    background: var(--bg-medium); color: var(--text-muted); border: 1px solid var(--bg-light);
    transition: all var(--transition-speed);
}
.category-filter a:hover, .category-filter a.active {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: #fff; border-color: transparent;
}

/* === Article Page === */
.article-header {
    padding: 130px 0 40px;
    background: linear-gradient(180deg, var(--bg-dark) 0%, rgba(61, 82, 213, 0.06) 100%);
}
.article-header .article-container { text-align: left; }
.article-category {
    display: inline-block; font-size: 0.75rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 1px; color: var(--secondary-color); margin-bottom: 16px;
}
.article-header h1 {
    font-size: 2.6rem; font-weight: 700; color: #fff; line-height: 1.25; margin-bottom: 20px;
}
.article-meta {
    display: flex; flex-wrap: wrap; gap: 20px; align-items: center;
    font-size: 0.9rem; color: var(--text-muted); margin-bottom: 8px;
}
.article-meta .author-name { font-weight: 600; color: var(--text-color); }
.article-meta .separator { color: var(--bg-light); }

/* Article content */
.article-content { padding: 50px 0 80px; }
.article-content h2 {
    font-size: 1.8rem; font-weight: 600; color: #fff; margin: 48px 0 20px;
    padding-bottom: 10px; border-bottom: 1px solid var(--bg-light);
}
.article-content h3 {
    font-size: 1.35rem; font-weight: 600; color: #fff; margin: 36px 0 14px;
}
.article-content p {
    margin-bottom: 20px; font-size: 1.05rem; line-height: 1.8; color: var(--text-color);
}
.article-content ul, .article-content ol {
    margin: 0 0 24px 24px; font-size: 1.05rem; line-height: 1.8;
}
.article-content li { margin-bottom: 8px; }
.article-content strong { color: #fff; }
.article-content blockquote {
    border-left: 4px solid var(--secondary-color);
    padding: 16px 24px; margin: 28px 0;
    background: rgba(138, 43, 226, 0.06);
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
    font-style: italic; color: var(--text-muted);
}

/* Comparison tables */
.comparison-table {
    width: 100%; border-collapse: collapse; margin: 28px 0;
    font-size: 0.95rem; border-radius: var(--border-radius); overflow: hidden;
}
.comparison-table thead th {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: #fff; padding: 14px 18px; text-align: left; font-weight: 600;
}
.comparison-table tbody td {
    padding: 12px 18px; border-bottom: 1px solid var(--bg-light);
    background: var(--bg-medium);
}
.comparison-table tbody tr:hover td { background: var(--bg-light); }
.comparison-table .check { color: #28a745; font-weight: 700; }
.comparison-table .cross { color: #dc3545; font-weight: 700; }

/* Info boxes */
.info-box {
    background: rgba(61, 82, 213, 0.08); border: 1px solid rgba(61, 82, 213, 0.2);
    border-radius: var(--border-radius); padding: 24px; margin: 28px 0;
}
.info-box h4 {
    font-size: 1.05rem; color: #fff; margin-bottom: 8px;
}
.info-box p { margin-bottom: 0; font-size: 0.95rem; }

/* CTA box */
.cta-box {
    background: linear-gradient(135deg, rgba(61, 82, 213, 0.15), rgba(138, 43, 226, 0.15));
    border: 1px solid rgba(138, 43, 226, 0.25);
    border-radius: var(--border-radius); padding: 40px; margin: 40px 0;
    text-align: center;
}
.cta-box h3 {
    font-size: 1.5rem; color: #fff; margin-bottom: 12px;
}
.cta-box p { color: var(--text-muted); margin-bottom: 24px; max-width: 500px; margin-left: auto; margin-right: auto; }
.cta-box .btn { margin: 0; }

/* FAQ section */
.faq-section { margin: 48px 0; }
.faq-section h2 { border-bottom: none; }
.faq-item {
    border: 1px solid var(--bg-light); border-radius: var(--border-radius);
    margin-bottom: 12px; overflow: hidden; background: var(--bg-medium);
}
.faq-question {
    padding: 18px 24px; cursor: pointer; font-weight: 600; color: #fff;
    display: flex; justify-content: space-between; align-items: center;
    transition: background var(--transition-speed);
}
.faq-question:hover { background: var(--bg-light); }
.faq-question::after { content: '+'; font-size: 1.3rem; color: var(--secondary-color); transition: transform 0.3s; }
.faq-item.open .faq-question::after { content: '−'; }
.faq-answer {
    max-height: 0; overflow: hidden; transition: max-height 0.4s ease, padding 0.4s ease;
    padding: 0 24px; font-size: 0.95rem; color: var(--text-muted); line-height: 1.7;
}
.faq-item.open .faq-answer { max-height: 600px; padding: 0 24px 20px; }

/* Related posts */
.related-posts { padding: 60px 0; border-top: 1px solid var(--bg-light); }
.related-posts h2 { text-align: center; border-bottom: none; font-size: 1.6rem; margin-bottom: 32px; }
.related-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px;
}

/* === Footer === */
.footer {
    background-color: var(--bg-dark); padding: 60px 0 30px;
    border-top: 1px solid var(--bg-light); color: var(--text-muted);
}
.footer-content {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; margin-bottom: 40px;
}
.footer-column h4 { font-size: 1rem; font-weight: 600; color: #fff; margin-bottom: 20px; }
.footer-column ul { list-style: none; }
.footer-column ul li { margin-bottom: 10px; }
.footer-column ul li a { color: var(--text-muted); font-size: 0.9rem; }
.footer-column ul li a:hover { color: #fff; }
.footer-about p { font-size: 0.9rem; line-height: 1.7; margin-bottom: 16px; }
.footer-social { display: flex; gap: 12px; }
.footer-social a {
    display: flex; justify-content: center; align-items: center;
    width: 38px; height: 38px; background: var(--bg-medium); border-radius: 50%;
    color: var(--text-muted); font-size: 0.9rem; transition: all var(--transition-speed);
}
.footer-social a:hover { background: var(--secondary-color); color: #fff; transform: translateY(-3px); }
.footer-bottom {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 24px; border-top: 1px solid var(--bg-light); font-size: 0.85rem;
}
.footer-bottom-links { display: flex; gap: 20px; }
.footer-bottom-links a { color: var(--text-muted); }
.footer-bottom-links a:hover { color: #fff; }

/* Breadcrumb */
.breadcrumb {
    display: flex; gap: 8px; font-size: 0.85rem; color: var(--text-muted);
    margin-bottom: 16px; flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: #fff; }
.breadcrumb .sep { color: var(--bg-light); }

/* TOC */
.toc {
    background: var(--bg-medium); border: 1px solid var(--bg-light);
    border-radius: var(--border-radius); padding: 24px; margin: 0 0 40px;
}
.toc h4 { font-size: 0.95rem; font-weight: 600; color: #fff; margin-bottom: 12px; }
.toc ul { list-style: none; margin: 0; padding: 0; }
.toc li { margin-bottom: 8px; }
.toc a { font-size: 0.9rem; color: var(--text-muted); }
.toc a:hover { color: var(--secondary-color); }
.toc .toc-h3 { padding-left: 16px; }

/* === Responsive === */
@media (max-width: 900px) {
    .nav, .nav-actions .nav-login-btn { display: none; }
    .mobile-toggle { display: block; }
    .footer-content { grid-template-columns: repeat(2, 1fr); }
    .blog-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .page-hero h1, .article-header h1 { font-size: 2rem; }
    .footer-content { grid-template-columns: 1fr; }
    .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
    .related-grid { grid-template-columns: 1fr; }
}
