:root {
  --bg: #060810; --surface: #0d1117; --surface2: #161b22;
  --text: #e6edf3; --muted: #8b949e; --green: #39e058;
  --green-dim: rgba(57,224,88,.12); --bdr: rgba(255,255,255,.08);
  --sans: 'Inter',-apple-system,sans-serif; --display: 'Inter',sans-serif;
  --gold: #f0b429;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 15px; line-height: 1.7; }

/* Nav */
nav { position: fixed; top: 0; left: 0; right: 0; z-index: 200; height: 66px; background: rgba(6,8,16,.95); backdrop-filter: blur(16px); border-bottom: 1px solid var(--bdr); }
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 0 20px; height: 100%; display: flex; align-items: center; justify-content: space-between; }
.nav-logo img { height: 32px; }
.nav-links { display: flex; align-items: center; gap: 24px; list-style: none; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 500; transition: color .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--text); }
.nav-btn { background: var(--green) !important; color: #000 !important; padding: 8px 18px; border-radius: 8px; font-weight: 700 !important; }
.hamburger { display: none; background: none; border: none; color: var(--text); font-size: 22px; cursor: pointer; padding: 4px 8px; line-height: 1; }
.mobile-menu { display: none; position: fixed; top: 66px; left: 0; right: 0; background: rgba(6,8,16,.98); border-bottom: 1px solid var(--bdr); padding: 16px 20px; z-index: 199; flex-direction: column; gap: 12px; }
.mobile-menu.open { display: flex; }
.mobile-menu a { color: var(--text); text-decoration: none; font-size: 15px; font-weight: 500; padding: 12px 0; border-bottom: 1px solid var(--bdr); display: flex; align-items: center; gap: 12px; }
.mobile-menu a:last-child { border-bottom: none; }

/* Main */
main { padding-top: 86px; min-height: 100vh; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 20px 60px; }
.post-container { max-width: 820px; }

/* Breadcrumb */
.breadcrumb { font-size: 12px; color: var(--muted); margin-bottom: 20px; }
.breadcrumb a { color: var(--muted); text-decoration: none; }

/* Page header */
h1 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.subtitle { color: var(--muted); font-size: 15px; margin-bottom: 28px; }

/* Category tabs */
.cat-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 32px; }
.cat-tab { padding: 6px 16px; border-radius: 999px; border: 1px solid var(--bdr); background: transparent; color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: none; transition: all .2s; }
.cat-tab:hover, .cat-tab.active { background: var(--green-dim); border-color: var(--green); color: var(--green); }

/* Posts grid */
.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; margin-bottom: 40px; }
.post-card { background: var(--surface); border: 1px solid var(--bdr); border-radius: 12px; overflow: hidden; transition: transform .2s, border-color .2s; }
.post-card:hover { transform: translateY(-2px); border-color: rgba(57,224,88,.2); }
.post-img { width: 100%; height: 180px; object-fit: cover; display: block; }
.post-body { padding: 16px; }
.post-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.cat-badge { background: var(--green-dim); color: var(--green); font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.post-date { font-size: 12px; color: var(--muted); }
.post-views { font-size: 11px; color: var(--muted); margin-left: auto; }
.post-title { font-size: 16px; font-weight: 700; line-height: 1.4; margin-bottom: 10px; }
.post-title a { color: var(--text); text-decoration: none; }
.post-title a:hover { color: var(--green); }
.post-excerpt { font-size: 13px; color: var(--muted); line-height: 1.6; margin-bottom: 14px; }
.read-more { font-size: 13px; color: var(--green); text-decoration: none; font-weight: 600; }
.no-posts { text-align: center; color: var(--muted); padding: 60px; grid-column: 1/-1; }

/* Pagination */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 40px; }
.page-btn { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; border-radius: 8px; border: 1px solid var(--bdr); color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 600; }
.page-btn.active { background: var(--green); border-color: var(--green); color: #000; }

/* Single post */
.post-header { margin-bottom: 24px; }
.post-header h1 { font-size: 32px; line-height: 1.3; margin: 12px 0; }
.post-info { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); align-items: center; }
.post-hero-img { width: 100%; max-height: 420px; object-fit: cover; border-radius: 12px; margin-bottom: 32px; }
.post-content { font-size: 16px; line-height: 1.85; color: #cdd5e0; margin-bottom: 32px; }
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.tag { background: var(--surface2); color: var(--muted); font-size: 12px; padding: 4px 10px; border-radius: 6px; }

/* Share buttons */
.share-box { background: var(--surface2); border: 1px solid var(--bdr); border-radius: 12px; padding: 20px; margin-bottom: 32px; }
.share-title { font-size: 14px; font-weight: 700; margin-bottom: 14px; }
.share-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.share-btn { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; text-decoration: none; transition: opacity .2s; }
.share-btn:hover { opacity: .85; }
.share-x { background: #000; color: #fff; border: 1px solid #333; }
.share-tg { background: #0088cc; color: #fff; }
.share-wa { background: #25d366; color: #fff; }
.share-tt { background: #000; color: #fff; border: 1px solid #333; }
.share-copy { background: var(--surface); color: var(--text); border: 1px solid var(--bdr); cursor: pointer; }

/* AI Prediction CTA */
.ai-cta { background: linear-gradient(135deg, rgba(57,224,88,.15), rgba(57,224,88,.05)); border: 1px solid rgba(57,224,88,.3); border-radius: 16px; padding: 28px; text-align: center; margin: 36px 0; position: relative; overflow: hidden; }
.ai-cta::before { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: radial-gradient(circle, rgba(57,224,88,.08) 0%, transparent 60%); animation: pulse-bg 3s ease-in-out infinite; }
@keyframes pulse-bg { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.1); opacity: .7; } }
.ai-cta-icon { font-size: 40px; margin-bottom: 12px; }
.ai-cta h3 { font-size: 20px; font-weight: 800; margin-bottom: 8px; position: relative; }
.ai-cta p { color: var(--muted); font-size: 14px; margin-bottom: 20px; position: relative; }
.ai-cta-btn { display: inline-flex; align-items: center; gap: 8px; background: var(--green); color: #000; font-weight: 700; padding: 14px 28px; border-radius: 10px; text-decoration: none; font-size: 15px; position: relative; animation: bounce-btn 2s ease-in-out infinite; }
@keyframes bounce-btn { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.ai-cta-btn:hover { background: #2bc449; transform: scale(1.05) !important; animation: none; }

/* Source credit */
.source-credit { font-size: 12px; color: var(--muted); margin-top: 8px; }
.source-credit a { color: var(--muted); }

/* Related */
.related { margin-top: 48px; }
.related h2 { font-size: 20px; font-weight: 700; margin-bottom: 20px; }

/* Footer */
footer { background: var(--surface); border-top: 1px solid var(--bdr); padding: 40px 20px 24px; }
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer-top { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 28px; gap: 16px; }
.footer-brand { font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.footer-desc { font-size: 13px; color: var(--muted); max-width: 440px; line-height: 1.6; margin-bottom: 8px; }
.social-links { display: flex; gap: 12px; align-items: center; justify-content: center; }
.social-btn { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; background: var(--surface2); border: 1px solid var(--bdr); color: var(--text); text-decoration: none; font-size: 18px; transition: all .2s; }
.social-btn:hover { border-color: var(--green); color: var(--green); transform: translateY(-2px); }
.footer-bottom { border-top: 1px solid var(--bdr); padding-top: 20px; display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); text-align: center; }
.footer-links a { color: var(--muted); text-decoration: none; margin-left: 16px; }
.footer-links a:hover { color: var(--text); }

/* Subscribe Popup */
.popup-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,.75); z-index: 9999; align-items: center; justify-content: center; padding: 20px; backdrop-filter: blur(4px); }
.popup-overlay.show { display: flex; }
.popup-box { background: var(--surface); border: 1px solid rgba(57,224,88,.3); border-radius: 16px; padding: 32px; max-width: 440px; width: 100%; text-align: center; position: relative; animation: popup-in .3s ease; }
@keyframes popup-in { from { transform: scale(.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.popup-close { position: absolute; top: 12px; right: 16px; background: none; border: none; color: var(--muted); font-size: 20px; cursor: pointer; }
.popup-icon { font-size: 48px; margin-bottom: 16px; }
.popup-box h2 { font-size: 22px; font-weight: 800; margin-bottom: 8px; }
.popup-box p { color: var(--muted); font-size: 14px; margin-bottom: 24px; line-height: 1.6; }
.popup-btns { display: flex; flex-direction: column; gap: 10px; }
.popup-btn { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 20px; border-radius: 10px; font-size: 14px; font-weight: 700; text-decoration: none; transition: opacity .2s; }
.popup-btn:hover { opacity: .9; }
.popup-btn-tg { background: #0088cc; color: #fff; }
.popup-btn-wa { background: #25d366; color: #fff; }
.popup-skip { background: none; border: none; color: var(--muted); font-size: 13px; cursor: pointer; margin-top: 8px; text-decoration: underline; }

/* Mobile */
@media (max-width: 768px) {
  h1 { font-size: 22px; }
  .post-header h1 { font-size: 24px; }
  .posts-grid { grid-template-columns: 1fr; }
  .nav-links { display: none !important; }
  .hamburger { display: flex !important; align-items: center; justify-content: center; }
  .share-btns { gap: 8px; }
  .share-btn { padding: 8px 12px; font-size: 12px; }
  .ai-cta { padding: 20px; }
  .ai-cta h3 { font-size: 17px; }
}
@media (min-width: 769px) {
  .hamburger { display: none !important; }
  .mobile-menu { display: none !important; }
}