/* ============ CSS VARIABLES (THEMES) ============ */
:root {
  --mono: 'IBM Plex Mono', monospace;
  --display: 'Playfair Display', serif;
  --body: 'Source Serif 4', 'Georgia', serif;
  --red: #cb0000;
  --red-hover: #e51a1a;
}

/* Light theme (default) */
body, [data-theme="light"] {
  --bg: #f8f7f4; --bg-alt: #fff; --bg-alt2: #f0efe9;
  --surface: #fff; --surface-border: #e4e2da; --surface-hover: #f5f4f0;
  --border: #e4e2da; --border-subtle: #eceae3; --border-light: #d8d6ce;
  --text: #1a1a1e; --text-secondary: #5a5a66; --text-muted: #888; --text-faint: #aaa; --text-ghost: #ccc;
  --nav-bg: #f8f7f4ee; --nav-link: #777; --nav-link-hover: #1a1a1e;
  --card-bg: #fff; --card-border: #e8e6de; --card-border-hover: #d0cec6;
  --input-bg: #fff; --input-border: #d8d6ce;
  --dot-inactive: #d4d2ca;
  --logo-text: #1a1a1e; --overlay-bg: #f8f7f4;
  --social-bg: #f5f4f0; --social-border: #e4e2da;
  --live-dot: #cb0000;
  --breaking-bg: #fef0f0; --breaking-border: #f5d5d5;
  --row-hover: rgba(0,0,0,0.012); --most-read-num: #e0ddd6;
}

/* Dark theme */
[data-theme="dark"] {
  --bg: #0a0a0c; --bg-alt: #0e0e12; --bg-alt2: #08080a;
  --surface: #131316; --surface-border: #1a1a22; --surface-hover: #1a1a22;
  --border: #18181e; --border-subtle: #151518; --border-light: #1e1e28;
  --text: #e0e0e6; --text-secondary: #8a8a9a; --text-muted: #666; --text-faint: #444; --text-ghost: #333;
  --nav-bg: #0a0a0cee; --nav-link: #888; --nav-link-hover: #fff;
  --card-bg: #0e0e14; --card-border: #16161e; --card-border-hover: #252530;
  --input-bg: #08080a; --input-border: #222230;
  --dot-inactive: #252530;
  --logo-text: #fff; --overlay-bg: #0a0a0c;
  --social-bg: #0e0e12; --social-border: #18181e;
  --live-dot: #e51a1a;
  --breaking-bg: #1a0a0a; --breaking-border: #301515;
  --row-hover: rgba(255,255,255,0.012); --most-read-num: #1e1e24;
}

@media (prefers-color-scheme: dark) {
  [data-theme="system"] {
    --bg: #0a0a0c; --bg-alt: #0e0e12; --bg-alt2: #08080a;
    --surface: #131316; --surface-border: #1a1a22; --surface-hover: #1a1a22;
    --border: #18181e; --border-subtle: #151518; --border-light: #1e1e28;
    --text: #e0e0e6; --text-secondary: #8a8a9a; --text-muted: #666; --text-faint: #444; --text-ghost: #333;
    --nav-bg: #0a0a0cee; --nav-link: #888; --nav-link-hover: #fff;
    --card-bg: #0e0e14; --card-border: #16161e; --card-border-hover: #252530;
    --input-bg: #08080a; --input-border: #222230;
    --dot-inactive: #252530;
    --logo-text: #fff; --overlay-bg: #0a0a0c;
    --social-bg: #0e0e12; --social-border: #18181e;
    --live-dot: #e51a1a;
    --breaking-bg: #1a0a0a; --breaking-border: #301515;
    --row-hover: rgba(255,255,255,0.012); --most-read-num: #1e1e24;
  }
}

/* ============ RESET & BASE ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--body); background: var(--bg); color: var(--text); transition: background 0.35s, color 0.35s; line-height: 1.6; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; cursor: pointer; }
.container { max-width: 1200px; margin: 0 auto; padding: 0; }

/* Ghost CMS default overrides */
.gh-content a { color: var(--red); text-decoration: underline; text-underline-offset: 3px; }
.gh-content a:hover { text-decoration-color: var(--red-hover); }

/* ============ ANIMATIONS ============ */
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
@keyframes progress { from { width: 0%; } to { width: 100%; } }
@keyframes slideIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
@keyframes imgIn { from { opacity: 0; transform: scale(1.04); } to { opacity: 1; transform: scale(1); } }

/* ============ BREAKING BAR ============ */
.breaking-bar { background: var(--breaking-bg); border-bottom: 1px solid var(--breaking-border); font-size: 13px; font-family: var(--mono); }
.breaking-bar-inner { max-width: 1200px; margin: 0 auto; padding: 8px 24px; display: flex; align-items: center; gap: 12px; }
.breaking-label { display: flex; align-items: center; gap: 6px; color: var(--live-dot); font-weight: 700; font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; flex-shrink: 0; }
.breaking-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live-dot); animation: pulse 2s infinite; }
.breaking-text { color: var(--text-secondary); font-size: 13px; text-decoration: none; transition: color 0.2s; }
.breaking-text:hover { color: var(--text); }

/* Badges */
.badge-exclusive { position: absolute; top: 12px; left: 12px; z-index: 2; background: var(--red); color: #fff; font-family: var(--mono); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; padding: 4px 10px; }
.badge-exclusive-sm { position: static; display: inline-block; background: var(--red); color: #fff; font-family: var(--mono); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; padding: 3px 8px; margin-bottom: 6px; }
.badge-pinned { display: inline-block; font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--text-muted); margin-bottom: 6px; }
.main-story-pinned { background: var(--surface-hover); border-left: 3px solid var(--red); padding-left: 20px !important; }
.slide-image { position: relative; display: block; }
.story-card-image { position: relative; display: block; }

/* ============ MASTHEAD ============ */
.masthead { border-bottom: 1px solid var(--border); padding: 50px 24px; position: relative; background: var(--nav-bg); backdrop-filter: blur(14px); z-index: 110; transition: background 0.35s; }
.masthead-inner { max-width: 1200px; margin: 0 auto; }
.masthead-row { display: flex; align-items: center; justify-content: space-between; }
.masthead-left, .masthead-right { display: flex; align-items: center; gap: 12px; width: 180px; }
.masthead-right { justify-content: flex-end; }
.masthead-tagline { font-size: 12px; color: var(--text-muted); font-family: var(--mono); margin-top: 8px; letter-spacing: 0.06em; text-align: center; }

/* Logo */
.site-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--logo-text); }
.logo-icon-img { height: 42px; width: auto; flex-shrink: 0; }
.logo-icon-nav { height: 32px; }
.logo-wordmark { font-family: var(--display); font-weight: 900; font-size: 28px; letter-spacing: -0.02em; color: var(--logo-text); line-height: 1; }
.site-logo-sm .logo-icon-img { height: 36px; }
.site-logo-sm .logo-wordmark { font-size: 24px; }
.nav-logo-link { display: flex; align-items: center; text-decoration: none; }
.footer-brand .logo-icon-img { height: 36px; }
.footer-brand .logo-wordmark { font-size: 24px; }
.logo-accent { color: inherit; }

/* Language picker */
.lang-picker { position: relative; }
.lang-btn { background: none; border: none; cursor: pointer; padding: 6px; display: flex; align-items: center; gap: 5px; color: var(--text-muted); font-size: 12px; font-family: var(--mono); transition: color 0.2s; }
.lang-btn:hover { color: var(--text); }
.lang-dropdown { display: none; position: absolute; top: 100%; left: 0; background: var(--surface); border: 1px solid var(--surface-border); border-radius: 8px; padding: 6px 0; min-width: 140px; box-shadow: 0 12px 40px rgba(0,0,0,0.15); z-index: 200; }
.lang-picker:hover .lang-dropdown { display: block; }
.lang-option { padding: 9px 16px; cursor: pointer; font-size: 12px; color: var(--text-muted); font-family: var(--mono); font-weight: 500; display: flex; align-items: center; justify-content: space-between; transition: background 0.15s; }
.lang-option:hover { background: var(--surface-hover); }
.lang-option.active { color: var(--red); font-weight: 700; }
.lang-check { font-size: 10px; display: none; }
.lang-option.active .lang-check { display: inline; }

/* Login / Subscribe */
.login-link{white-space:nowrap} .login-link { font-size: 12px; color: var(--text-muted); font-family: var(--mono); cursor: pointer; transition: color 0.2s; }
.login-link{white-space:nowrap} .login-link:hover { color: var(--text); }
.subscribe-btn { background: var(--red); color: #fff; border: none; border-radius: 5px; padding: 7px 18px; font-weight: 700; font-size: 11px; cursor: pointer; font-family: var(--mono); letter-spacing: 0.04em; transition: background 0.2s; display: inline-block; text-align: center; }
.subscribe-btn:hover { background: var(--red-hover); }

/* Hamburger */
.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 8px; z-index: 301; }
.hamburger-bar { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); transform-origin: center; }
.hamburger.open .hamburger-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open .hamburger-bar:nth-child(2) { opacity: 0; }
.hamburger.open .hamburger-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============ GHOST NAVIGATION HELPER ============ */
/* Ghost's {{navigation}} outputs: ul.nav > li.nav-item > a */

/* Section nav bar */
.section-nav-links .nav { list-style: none; display: flex; align-items: center; justify-content: center; margin: 0; padding: 0; }
.section-nav-links .nav li { display: inline-block; }
.section-nav-links .nav li a { padding: 12px 16px; font-size: 12px; font-weight: 600; color: var(--nav-link); font-family: var(--mono); white-space: nowrap; transition: color 0.2s; border-bottom: 2px solid transparent; letter-spacing: 0.03em; display: inline-block; text-decoration: none; }
.section-nav-links .nav li a:hover { color: var(--nav-link-hover); border-bottom-color: var(--red); }
.section-nav-links .nav li.nav-current a { color: var(--nav-link-hover); border-bottom-color: var(--red); }

/* Mobile menu */
/* Mobile nav list - see below for main styles */

/* Footer */
.footer-col .nav { list-style: none; margin: 0; padding: 0; }
.footer-col .nav .nav-item { display: block; }
.footer-col .nav .nav-item a { display: block; font-size: 13px; color: var(--text-muted); margin-bottom: 12px; cursor: pointer; transition: color 0.2s; text-decoration: none; }
.footer-col .nav .nav-item a:hover { color: var(--text); }

/* ============ SECTION NAV ============ */
.section-nav { border-bottom: 1px solid var(--border); position: sticky; top: 0; background: var(--nav-bg); backdrop-filter: blur(14px); z-index: 100; transition: background 0.35s; }
.section-nav-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: center; position: relative; padding: 0 24px; }
.section-nav-links { display: flex; align-items: center; justify-content: center; }
.section-nav-links a, .section-nav-links .nav-item { padding: 12px 16px; font-size: 12px; font-weight: 600; color: var(--nav-link); font-family: var(--mono); cursor: pointer; white-space: nowrap; transition: color 0.2s; border-bottom: 2px solid transparent; letter-spacing: 0.03em; display: inline-block; }
.section-nav-links a:hover { color: var(--nav-link-hover); border-bottom-color: var(--red); }

/* Nav logo & subscribe reveal */
.nav-logo-reveal, .nav-subscribe-reveal { position: absolute; top: 50%; transform: translateY(-50%); opacity: 0; pointer-events: none; transition: opacity 0.3s; }
.nav-logo-reveal { left: 24px; }
.nav-subscribe-reveal { right: 24px; }
.nav-logo-reveal.visible, .nav-subscribe-reveal.visible { opacity: 1; pointer-events: auto; }

/* More dropdown */
.nav-more { position: relative; display: inline-block; }
.nav-more-label { padding: 12px 16px; font-size: 12px; font-weight: 600; color: var(--nav-link); font-family: var(--mono); cursor: pointer; white-space: nowrap; border-bottom: 2px solid transparent; letter-spacing: 0.03em; display: flex; align-items: center; gap: 4px; transition: color 0.2s; }
.nav-more:hover .nav-more-label { color: var(--nav-link-hover); border-bottom-color: var(--red); }
.nav-more-arrow { font-size: 9px; transition: transform 0.25s; display: inline-block; }
.nav-more:hover .nav-more-arrow { transform: rotate(180deg); }
.nav-more-dropdown { display: none; position: absolute; top: 100%; right: 0; background: var(--surface); border: 1px solid var(--surface-border); border-radius: 8px; padding: 6px 0; min-width: 180px; box-shadow: 0 12px 40px rgba(0,0,0,0.15); z-index: 200; }
.nav-more:hover .nav-more-dropdown { display: block; }
.nav-more-dropdown a { padding: 10px 20px !important; display: block !important; font-size: 12px !important; color: var(--text-muted) !important; font-family: var(--mono) !important; font-weight: 500 !important; transition: all 0.15s !important; border-bottom: none !important; white-space: nowrap; }
.nav-more-dropdown a:hover { background: var(--surface-hover) !important; color: var(--text) !important; border-bottom: none !important; }

/* ============ MOBILE MENU ============ */
.mobile-menu { position: fixed; inset: 0; z-index: 250; background: var(--overlay-bg); opacity: 0; pointer-events: none; transition: opacity 0.35s ease; display: flex; flex-direction: column; overflow-y: auto; }
.mobile-menu.open { opacity: 1; pointer-events: auto; }
.mobile-menu-header { display: flex; justify-content: space-between; align-items: center; padding: 0 16px; height: 56px; flex-shrink: 0; border-bottom: 1px solid var(--border); }
.site-logo-mobile { display: flex; align-items: center; text-decoration: none; }
.site-logo-mobile .logo-icon-img { height: 36px; }
.mobile-menu-close { background: none; border: none; width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; color: var(--text); font-size: 22px; cursor: pointer; }
.mobile-menu-nav { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 0 16px; }
.mobile-menu-nav a, .mobile-menu-nav .nav-item { display: block; padding: 18px 0; font-size: clamp(24px, 5vw, 36px); font-family: var(--display); font-weight: 900; color: var(--text); letter-spacing: -0.02em; border-bottom: 1px solid var(--border-subtle); transition: color 0.2s; }
.mobile-menu-nav a:hover { color: var(--red); }
.mobile-menu-footer { padding: 24px 16px; flex-shrink: 0; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 12px; }

/* Mobile menu nav list */
.mobile-menu-nav .nav { list-style: none; display: flex; flex-direction: column; justify-content: center; margin: 0; padding: 0; flex: 1; }
.mobile-menu-nav .nav li { display: block; opacity: 0; transform: translateY(20px); }
.mobile-menu.open .mobile-menu-nav .nav li { animation: menuSlideIn 0.4s ease forwards; }
.mobile-menu-nav .nav li a { display: block; padding: 16px 0; font-size: clamp(24px, 5vw, 36px); font-family: var(--display); font-weight: 900; color: var(--text); letter-spacing: -0.02em; border-bottom: 1px solid var(--border-subtle); transition: color 0.2s; text-decoration: none; }
.mobile-menu-nav .nav li a:hover { color: var(--red); }

/* Staggered animation for menu items */
@keyframes menuSlideIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(1) { animation-delay: 0.05s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(2) { animation-delay: 0.1s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(3) { animation-delay: 0.15s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(4) { animation-delay: 0.2s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(5) { animation-delay: 0.25s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(6) { animation-delay: 0.3s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(7) { animation-delay: 0.35s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(8) { animation-delay: 0.4s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(9) { animation-delay: 0.45s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(10) { animation-delay: 0.5s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(11) { animation-delay: 0.55s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(12) { animation-delay: 0.6s; }
.mobile-menu.open .mobile-menu-nav .nav li:nth-child(n+13) { animation-delay: 0.65s; }
.mobile-login-btn { width: 100%; background: transparent; color: var(--text); border: 2px solid var(--border-light); border-radius: 10px; padding: 14px; font-weight: 700; font-size: 15px; cursor: pointer; font-family: var(--mono); text-align: center; display: block; }
.mobile-subscribe-btn { width: 100%; background: var(--red); color: #fff; border: 2px solid var(--red); border-radius: 10px; padding: 14px; font-weight: 700; font-size: 15px; cursor: pointer; font-family: var(--mono); text-align: center; display: block; }

/* Mobile menu more */
.mobile-menu-more { border-bottom: 1px solid var(--border-subtle); }
.mobile-menu-more-btn { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 18px 0; background: none; border: none; color: var(--text); font-size: clamp(24px, 5vw, 36px); font-family: var(--display); font-weight: 900; cursor: pointer; letter-spacing: -0.02em; text-align: left; }
.mobile-more-arrow { font-size: 14px; color: #cb0000; font-family: var(--mono); transition: transform 0.3s; display: inline-block; }
.mobile-menu-more-items { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.mobile-menu-more-items.open { max-height: 400px; }
.mobile-menu-sub-link { display: block; padding: 8px 0 8px 8px; font-size: 15px; color: var(--text-secondary); font-family: var(--mono); border-left: 2px solid var(--border-subtle); margin-left: 4px; transition: all 0.2s; }
.mobile-menu-sub-link:hover { color: var(--text); border-left-color: var(--red); padding-left: 14px; }

/* Opinion placeholder avatar */
.opinion-avatar-placeholder { width: 56px; height: 56px; border-radius: 50%; background: var(--surface-border); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 900; font-size: 22px; color: var(--text-muted); flex-shrink: 0; }
.opinion-title-wrap { margin-top: 4px; }

/* ============ TOP STRIP (LEAD + HEADLINES) ============ */
.top-strip-section { border-bottom: 1px solid var(--border-subtle); padding: 36px 0; }
.top-strip { display: grid; grid-template-columns: 1.6fr 1fr; gap: 36px; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* Lead slider */
.lead-slider { position: relative; }
.slider-viewport { position: relative; }
.slider-progress { position: absolute; bottom: 0; left: 0; right: 0; height: 4px; background: rgba(0,0,0,0.3); z-index: 3; pointer-events: none; }
.slider-progress-bar { height: 100%; background: linear-gradient(90deg, #cb0000, #e51a1a); width: 0%; }
.slider-progress-bar.animating { animation: progress 6s linear forwards; }
.slide { display: none; cursor: pointer; }
.slide-active { display: block; }
.slide-image { display: block; border-radius: 6px; overflow: hidden; aspect-ratio: 16/9; margin-bottom: 18px; position: relative; }
.slide-image img { width: 100%; height: 100%; object-fit: cover; animation: imgIn 0.5s ease both; display: block; }
.slide-content { animation: slideIn 0.45s ease both; }
.slide-title { font-size: clamp(26px, 3vw, 38px); font-weight: 900; line-height: 1.12; margin: 12px 0 14px; font-family: var(--display); letter-spacing: -0.03em; }
.slide-title a { color: var(--text); text-decoration: none; transition: color 0.2s; }
.slide-title a:hover { color: var(--red); }
.slide-excerpt { font-size: 15px; line-height: 1.65; color: var(--text-secondary); margin: 0 0 14px; max-width: 560px; }
.slide-meta, .story-meta { font-size: 12px; color: var(--text-faint); font-family: var(--mono); }
.meta-author { color: var(--text-muted); font-weight: 600; }
.meta-sep { color: var(--text-ghost); margin: 0 2px; }

/* Slider controls */
.slider-controls { position: absolute; bottom: 16px; left: 16px; right: 16px; display: flex; align-items: center; justify-content: space-between; z-index: 4; pointer-events: none; }
.slider-controls > * { pointer-events: auto; }
.slider-dots { display: flex; gap: 6px; align-items: center; }
.slider-dot { width: 8px; height: 6px; border-radius: 3px; border: none; background: rgba(255,255,255,0.3); cursor: pointer; transition: all 0.3s; padding: 0; }
.slider-dot.active { width: 24px; background: var(--red); }
.slider-counter { margin-left: 10px; font-family: var(--mono); font-size: 11px; color: rgba(255,255,255,0.7); font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,0.5); }
.slider-arrows { display: flex; gap: 6px; }
.slider-arrow { width: 34px; height: 34px; border-radius: 6px; border: 1px solid rgba(255,255,255,0.25); background: rgba(0,0,0,0.4); color: rgba(255,255,255,0.85); font-size: 14px; cursor: pointer; display: flex; align-items: center; justify-content: center; font-family: system-ui; transition: all 0.2s; backdrop-filter: blur(8px); }
.slider-arrow:hover { border-color: rgba(255,255,255,0.6); color: #fff; background: rgba(0,0,0,0.6); }

/* Top stories sidebar */
.top-stories { display: flex; flex-direction: column; }
.sidebar-heading { font-size: 11px; font-family: var(--mono); font-weight: 700; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.1em; padding-bottom: 12px; border-bottom: 2px solid var(--red); margin-bottom: 0; }
.top-story-item { display: block; padding: 18px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; transition: background 0.15s; text-decoration: none; }
.top-story-item:hover { background: var(--row-hover); }
.top-story-title { font-size: 17px; font-weight: 700; line-height: 1.3; margin: 8px 0; font-family: var(--display); color: var(--text); }
.top-story-item:hover .top-story-title { color: var(--red); }

/* ============ TAGS ============ */
.tag { display: inline-block; padding: 3px 10px; border-radius: 3px; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; font-family: var(--mono); background: var(--surface-border); color: var(--text-muted); text-decoration: none; }
.tag-sm { padding: 2px 7px; font-size: 10px; }

/* Tag colors are applied dynamically via JavaScript */

/* ============ MAIN + SIDEBAR ============ */
.main-sidebar-section { padding: 36px 0; }
.main-sidebar { display: grid; grid-template-columns: 1fr 320px; gap: 36px; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* Main stories */
.main-story { display: grid; grid-template-columns: 1fr 220px; gap: 20px; padding: 24px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; transition: background 0.15s; }
.main-story:last-child { border-bottom: none; }
.main-story:hover { background: var(--row-hover); }
.main-story.no-image { grid-template-columns: 1fr; }
.main-story-title { font-size: 20px; font-weight: 800; line-height: 1.25; margin: 8px 0; font-family: var(--display); }
.main-story-title a { color: var(--text); text-decoration: none; transition: color 0.2s; }
.main-story-title a:hover { color: var(--red); }
.main-story-excerpt { font-size: 14px; line-height: 1.6; color: var(--text-secondary); margin: 0 0 10px; }
.main-story-image { display: block; border-radius: 6px; overflow: hidden; aspect-ratio: 4/3; align-self: start; }
.main-story-image img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s; }
.main-story:hover .main-story-image img { transform: scale(1.04); }

/* Sidebar */
.sidebar { display: flex; flex-direction: column; gap: 32px; }
.sidebar-block { }
.most-read-item { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; text-decoration: none; transition: background 0.15s; }
.most-read-item:hover { background: var(--row-hover); }
.most-read-num { font-family: var(--display); font-size: 28px; font-weight: 900; color: var(--most-read-num); line-height: 1; min-width: 28px; }
.most-read-title { font-size: 14px; font-weight: 700; line-height: 1.35; color: var(--text); font-family: var(--display); }
.most-read-item:hover .most-read-title { color: var(--red); }
.podcast-item { display: block; padding: 14px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; text-decoration: none; transition: background 0.15s; }
.podcast-item:hover { background: var(--row-hover); }
.podcast-show { font-size: 10px; font-weight: 700; color: #d48a1e; font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.06em; display: block; }
.podcast-title { font-size: 14px; font-weight: 700; line-height: 1.35; margin-top: 4px; color: var(--text); font-family: var(--display); display: block; }
.podcast-item:hover .podcast-title { color: var(--red); }
.podcast-time { font-size: 11px; color: var(--text-faint); font-family: var(--mono); margin-top: 4px; display: block; }

/* Newsletter sidebar */
.sidebar-newsletter { background: var(--bg-alt); border: 1px solid var(--surface-border); border-radius: 10px; padding: 24px; position: relative; overflow: hidden; }
.newsletter-accent { position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, #cb0000, #e8a05d, #cb0000); }
.newsletter-title { font-size: 17px; font-weight: 900; color: var(--text); font-family: var(--display); margin-bottom: 8px; }
.newsletter-desc { font-size: 12px; color: var(--text-muted); line-height: 1.55; margin-bottom: 14px; }
.newsletter-input { display: block; width: 100%; padding: 10px 14px; border-radius: 6px; border: 1px solid var(--input-border); background: var(--input-bg); color: var(--text); font-size: 12px; font-family: var(--mono); outline: none; transition: border-color 0.2s; margin-bottom: 8px; }
.newsletter-input:focus { border-color: var(--red); }
.newsletter-btn { display: block; width: 100%; background: var(--red); color: #fff; border: none; border-radius: 6px; padding: 10px; font-weight: 700; font-size: 12px; cursor: pointer; font-family: var(--mono); transition: background 0.2s; }
.newsletter-btn:hover { background: var(--red-hover); }

/* ============ OPINION ============ */
.opinion-section { padding: 36px 24px; max-width: 1200px; margin: 0 auto; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; padding-bottom: 12px; border-bottom: 2px solid var(--red); }
.section-title { font-size: 16px; font-weight: 800; color: var(--text); margin: 0; font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.08em; }
.section-see-all { font-size: 11px; color: var(--red); cursor: pointer; font-family: var(--mono); font-weight: 600; text-decoration: none; }
.section-see-all:hover { text-decoration: underline; }
.opinion-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.opinion-card { display: flex; gap: 16px; cursor: pointer; padding: 16px; border-radius: 8px; border: 1px solid var(--card-border); background: var(--card-bg); transition: border-color 0.2s; text-decoration: none; flex-direction: row; align-items: flex-start; }
.opinion-card:hover { border-color: var(--card-border-hover); }
.opinion-avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.opinion-avatar-placeholder { width: 56px; height: 56px; border-radius: 50%; background: var(--surface-border); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 900; font-size: 22px; color: var(--text-muted); flex-shrink: 0; }
.opinion-content { flex: 1; min-width: 0; }
.opinion-author { font-size: 12px; font-family: var(--mono); font-weight: 700; color: var(--red); }
.opinion-role { font-size: 11px; font-family: var(--mono); color: var(--text-faint); margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.opinion-title { font-size: 15px; font-weight: 700; line-height: 1.3; color: var(--text); font-family: var(--display); display: block; margin-top: 6px; }
.opinion-card:hover .opinion-title { color: var(--red); }
.opinion-title-wrap { margin-top: 4px; }

/* ============ CATEGORY SECTIONS ============ */
.category-section { padding: 36px 24px; max-width: 1200px; margin: 0 auto; }
.category-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.story-card { cursor: pointer; transition: transform 0.25s; }
.story-card:hover { transform: translateY(-4px); }
.story-card-image { display: block; border-radius: 6px; overflow: hidden; aspect-ratio: 16/10; margin-bottom: 12px; }
.story-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; display: block; }
.story-card:hover .story-card-image img { transform: scale(1.05); }
.story-card-title { font-size: 16px; font-weight: 700; line-height: 1.3; margin: 0 0 8px; font-family: var(--display); }
.story-card-title a { color: var(--text); text-decoration: none; transition: color 0.2s; }
.story-card-title a:hover { color: var(--red); }

/* ============ POST (SINGLE) ============ */
.post-title { font-size: clamp(32px, 4vw, 48px); font-weight: 900; line-height: 1.1; font-family: var(--display); letter-spacing: -0.03em; margin: 12px 0 20px; }
.post-excerpt { font-size: 20px; line-height: 1.5; color: var(--text-secondary); margin-bottom: 24px; }
.post-feature-image { max-width: 960px; margin: 0 auto 0; padding: 32px 24px 0; }
.post-feature-image img { width: 100%; border-radius: 8px; display: block; }
.post-feature-image figcaption { font-size: 12px; color: var(--text-faint); font-family: var(--mono); margin-top: 10px; text-align: center; }
.post-tags { max-width: 720px; margin: 40px auto; display: flex; flex-wrap: wrap; gap: 8px; }
.post-tag { display: inline-block; padding: 4px 12px; border-radius: 4px; font-size: 12px; font-family: var(--mono); background: var(--surface-border); color: var(--text-muted); transition: all 0.2s; }
.post-tag:hover { background: var(--red); color: #fff; }

/* ============ TAG / AUTHOR ARCHIVES ============ */
.author-header { text-align: center; padding: 48px 0 36px; }
.author-name { font-size: 36px; font-weight: 900; font-family: var(--display); }
.author-bio { font-size: 16px; color: var(--text-secondary); max-width: 560px; margin: 12px auto 0; }
.author-avatar-lg { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin: 0 auto 16px; }
.tag-grid { margin-bottom: 48px; }

/* Pagination */
.pagination { text-align: center; padding: 40px 0; font-family: var(--mono); font-size: 13px; color: var(--text-muted); }
.pagination a { color: var(--red); font-weight: 600; margin: 0 8px; }

/* ============ FOOTER ============ */
/* Newsletter CTA (full-width) */
.newsletter-cta { padding: 72px 24px; border-top: 2px solid var(--red); position: relative; overflow: hidden; }
.newsletter-cta-inner { max-width: 560px; margin: 0 auto; text-align: center; position: relative; z-index: 1; }
.newsletter-cta-label { font-family: var(--mono); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.15em; color: var(--red); margin-bottom: 16px; display: inline-flex; align-items: center; gap: 8px; }
.newsletter-cta-label::before, .newsletter-cta-label::after { content: ''; width: 24px; height: 1px; background: var(--red); }
.newsletter-cta-title { font-family: var(--display); font-size: clamp(28px, 3.5vw, 38px); font-weight: 900; letter-spacing: -0.02em; margin-bottom: 14px; line-height: 1.15; }
.newsletter-cta-desc { font-size: 16px; color: var(--text-secondary); line-height: 1.7; margin-bottom: 32px; }
.newsletter-cta-form { display: flex; gap: 0; max-width: 460px; margin: 0 auto; }
.newsletter-cta-input { flex: 1; padding: 16px 20px; border: 2px solid var(--border); border-right: none; background: var(--bg); color: var(--text); font-family: var(--body); font-size: 15px; outline: none; transition: border-color 0.2s; }
.newsletter-cta-input:focus { border-color: var(--red); }
.newsletter-cta-input::placeholder { color: var(--text-faint); }
.newsletter-cta-btn { background: var(--red); color: #fff; border: 2px solid var(--red); padding: 16px 32px; font-family: var(--mono); font-size: 13px; font-weight: 700; letter-spacing: 0.03em; cursor: pointer; transition: background 0.2s; white-space: nowrap; flex-shrink: 0; }
.newsletter-cta-btn:hover { background: #a00; border-color: #a00; }
.newsletter-cta-note { font-family: var(--mono); font-size: 11px; color: var(--text-faint); margin-top: 14px; }

/* Ghost form states (applied automatically by Ghost Portal) */
form[data-members-form].loading .newsletter-btn,
form[data-members-form].loading .newsletter-cta-btn { opacity: 0.6; pointer-events: none; }
form[data-members-form].loading .newsletter-btn::after,
form[data-members-form].loading .newsletter-cta-btn::after { content: '...'; }
form[data-members-form].success .newsletter-input,
form[data-members-form].success .newsletter-cta-input { display: none; }
form[data-members-form].success .newsletter-btn,
form[data-members-form].success .newsletter-cta-btn { display: none; }
form[data-members-form] .message-success,
form[data-members-form] .message-error { font-family: var(--mono); font-size: 13px; padding: 12px 16px; margin-top: 8px; text-align: center; }
form[data-members-form] .message-success { color: var(--correct, #538d4e); }
form[data-members-form] .message-error { color: var(--red); }
@media (max-width: 640px) { .newsletter-cta { padding: 48px 24px; } .newsletter-cta-form { flex-direction: column; } .newsletter-cta-input { border-right: 2px solid var(--border); border-bottom: none; } .newsletter-cta-btn { width: 100%; } }

.login-link { white-space: nowrap; }

/* Reading Progress Bar */
.reading-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; background: transparent; z-index: 999; pointer-events: none; }
.reading-progress-bar { height: 100%; width: 0%; background: linear-gradient(90deg, #cb0000, #e51a1a); transition: width 0.1s linear; }

/* Audio Player */
.audio-btn { background: none; border: 1px solid var(--border); color: var(--text-muted); font-family: var(--mono); font-size: 11px; font-weight: 600; padding: 6px 14px; border-radius: 4px; cursor: pointer; transition: all 0.2s; white-space: nowrap; display: flex; align-items: center; gap: 5px; }
.audio-btn:hover { border-color: var(--red); color: var(--red); }
.audio-btn.playing { border-color: var(--red); color: var(--red); }
.audio-btn.playing .audio-icon { animation: audioPulse 1s infinite; }
@keyframes audioPulse { 0%,100%{opacity:1} 50%{opacity:0.4} }

.audio-player { display: none; background: var(--bg-alt2); border: 1px solid var(--border); border-radius: 8px; padding: 14px 18px; margin-bottom: 24px; }
.audio-player.visible { display: flex; align-items: center; gap: 14px; }
.audio-play-btn { width: 36px; height: 36px; border-radius: 50%; background: var(--red); color: #fff; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; transition: background 0.2s; }
.audio-play-btn:hover { background: #a00; }
.audio-info { flex: 1; min-width: 0; }
.audio-title { font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--text); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audio-status { font-family: var(--mono); font-size: 10px; color: var(--text-faint); }
.audio-progress-wrap { flex: 1; height: 4px; background: var(--border); border-radius: 2px; cursor: pointer; min-width: 80px; }
.audio-progress-fill { height: 100%; background: var(--red); border-radius: 2px; width: 0%; transition: width 0.3s; }
.audio-speed { background: none; border: 1px solid var(--border); color: var(--text-muted); font-family: var(--mono); font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 3px; cursor: pointer; flex-shrink: 0; }
.audio-speed:hover { border-color: var(--text); color: var(--text); }
.audio-close { background: none; border: none; color: var(--text-faint); cursor: pointer; font-size: 16px; padding: 0 4px; flex-shrink: 0; }
.audio-close:hover { color: var(--text); }
.translate-btn { background: none; border: 1px solid var(--border); color: var(--text-muted); font-family: var(--mono); font-size: 11px; font-weight: 600; padding: 6px 14px; border-radius: 4px; cursor: pointer; transition: all 0.2s; white-space: nowrap; }
.translate-btn:hover { border-color: var(--red); color: var(--red); }
.translate-btn.loading { opacity: 0.5; pointer-events: none; }
.post-content.translated { position: relative; }
.translation-notice { font-family: var(--mono); font-size: 11px; color: var(--text-faint); background: var(--bg-alt2); padding: 10px 16px; border-radius: 6px; margin-bottom: 24px; display: flex; align-items: center; gap: 8px; }
.translation-notice button { background: none; border: 1px solid var(--border); color: var(--text-muted); font-family: var(--mono); font-size: 10px; padding: 3px 10px; border-radius: 3px; cursor: pointer; margin-left: auto; }
.translation-notice button:hover { border-color: var(--text); color: var(--text); }


/* Video Shorts Section */
.video-section { padding: 36px 24px; max-width: 1200px; margin: 0 auto; }
.video-scroll { position: relative; }
.video-track { display: flex; gap: 16px; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none; padding: 8px; cursor: grab; }
.video-track::-webkit-scrollbar { display: none; }
.video-track.dragging { cursor: grabbing; scroll-behavior: auto; }
.video-track.dragging .video-card { pointer-events: none; }
.video-scroll::before, .video-scroll::after { content: ''; position: absolute; top: 0; bottom: 0; width: 60px; z-index: 2; pointer-events: none; transition: opacity 0.3s; }
.video-scroll::before { left: 0; background: linear-gradient(to right, var(--bg), transparent); opacity: 0; }
.video-scroll::after { right: 0; background: linear-gradient(to left, var(--bg), transparent); }
.video-scroll.scrolled-start::before { opacity: 0; }
.video-scroll.scrolled-mid::before { opacity: 1; }
.video-scroll.scrolled-end::after { opacity: 0; }
.video-card { flex-shrink: 0; width: 220px; border-radius: 10px; overflow: hidden; position: relative; cursor: pointer; background: #000; transition: transform 0.2s; }
.video-card:hover { transform: scale(1.03); }
.video-card-thumb { width: 100%; aspect-ratio: 9/16; object-fit: cover; display: block; transition: opacity 0.2s; }
.video-card:hover .video-card-thumb { opacity: 0.85; }
.video-card-overlay { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 16px; background: linear-gradient(transparent 40%, rgba(0,0,0,0.85) 100%); }
.video-card-play { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 48px; height: 48px; background: rgba(203,0,0,0.9); border-radius: 50%; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; }
.video-card:hover .video-card-play { opacity: 1; }
.video-card-play::after { content: ''; border-left: 14px solid #fff; border-top: 8px solid transparent; border-bottom: 8px solid transparent; margin-left: 3px; }
.video-card-title { font-family: var(--display); font-size: 14px; font-weight: 700; color: #fff; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.video-card-meta { font-family: var(--mono); font-size: 10px; color: rgba(255,255,255,0.5); margin-top: 6px; }
.video-card-duration { position: absolute; top: 10px; right: 10px; background: rgba(0,0,0,0.7); color: #fff; font-family: var(--mono); font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 4px; }
@media(max-width:768px) { .video-card { width: 180px; } }

/* Video Player Modal */
.video-modal { position: fixed; inset: 0; z-index: 600; background: rgba(0,0,0,0.95); display: none; align-items: center; justify-content: center; flex-direction: column; }
.video-modal.open { display: flex; }
.video-modal-close { position: absolute; top: 20px; right: 24px; background: none; border: none; color: #fff; font-size: 28px; cursor: pointer; z-index: 2; padding: 8px; }
.video-modal-close:hover { color: var(--red); }
.video-modal iframe { width: 100%; max-width: 400px; aspect-ratio: 9/16; border: none; border-radius: 10px; }
.video-modal-title { color: #fff; font-family: var(--display); font-size: 18px; font-weight: 700; max-width: 400px; text-align: center; margin-top: 16px; line-height: 1.3; padding: 0 24px; }
.video-modal-nav { display: flex; gap: 16px; margin-top: 16px; }
.video-modal-nav button { background: none; border: 1px solid rgba(255,255,255,0.2); color: #fff; width: 44px; height: 44px; border-radius: 50%; cursor: pointer; font-size: 18px; transition: all 0.2s; }
.video-modal-nav button:hover { border-color: #fff; }
.video-modal-counter { font-family: var(--mono); font-size: 11px; color: rgba(255,255,255,0.3); margin-top: 12px; }

/* Mobile video modal */
@media(max-width:768px) {
  .video-modal iframe { max-width: 100%; width: calc(100% - 48px); border-radius: 14px; }
  .video-modal-title { font-size: 16px; max-width: 100%; }
  .video-modal-nav { display: none; }
  .video-modal-title { display: none; }
  .video-modal-counter { display: none; }
  .video-modal-close { top: 12px; right: 16px; font-size: 24px; }
}

/* Gesture guide overlay */
.video-gesture-guide { position: fixed; inset: 0; z-index: 610; background: rgba(0,0,0,0.8); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 40px; opacity: 0; animation: gestureIn 0.4s ease forwards; pointer-events: auto; }
@keyframes gestureIn { to { opacity: 1; } }
.gesture-hint { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.gesture-arrow { font-size: 28px; color: #fff; }
.gesture-arrow.up { animation: gestureUp 1.2s ease-in-out infinite; }
.gesture-arrow.down { animation: gestureDown 1.2s ease-in-out infinite; }
@keyframes gestureUp { 0%,100% { transform: translateY(0); opacity: 0.4; } 50% { transform: translateY(-14px); opacity: 1; } }
@keyframes gestureDown { 0%,100% { transform: translateY(0); opacity: 0.4; } 50% { transform: translateY(14px); opacity: 1; } }
.gesture-label { font-family: var(--mono); font-size: 12px; color: rgba(255,255,255,0.6); }
.gesture-tap { font-family: var(--mono); font-size: 11px; color: rgba(255,255,255,0.35); margin-top: 20px; }


/* === TEMPORARY: Hide author everywhere except opinion ===
   To restore: delete this entire block */
.meta-author,
.meta-author + .meta-sep { display: none; }
body.tag-opinion .meta-author,
body.tag-opinion .meta-author + .meta-sep { display: inline; }
.opinion-author, .opinion-avatar { display: revert; }
/* === END TEMPORARY AUTHOR HIDE === */


/* === MEMBER FEATURES: Bookmarks, History, Follow Tags === */
.bookmark-btn { display: flex; align-items: center; gap: 5px; background: none; border: 1px solid var(--border); padding: 6px 12px; border-radius: 4px; color: var(--text-muted); cursor: pointer; font-family: var(--mono); font-size: 11px; font-weight: 600; transition: all 0.2s; }
.bookmark-btn:hover { border-color: var(--red); color: var(--red); }
.bookmark-btn.bookmarked { border-color: var(--red); color: var(--red); }
.bookmark-btn.bookmarked .bookmark-icon path { fill: var(--red); }
.bookmark-label { font-size: 11px; }
.share-btn.share-btn-bookmark.bookmarked { border-color: var(--red); color: var(--red); }
.share-btn.share-btn-bookmark.bookmarked svg path { fill: var(--red); }

.card-bookmark { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,0.6); border: none; color: #fff; width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; opacity: 0; transition: all 0.2s; z-index: 2; backdrop-filter: blur(4px); }
.story-card:hover .card-bookmark { opacity: 1; }
.card-bookmark:hover { background: rgba(203,0,0,0.8); }
.card-bookmark.bookmarked { opacity: 1; background: rgba(203,0,0,0.8); }
.card-bookmark.bookmarked svg path { fill: #fff; }
.story-card-image { position: relative; }
.tag-article-image { position: relative; }
.tag-featured-image { position: relative; }
.tag-article:hover .card-bookmark, .tag-featured:hover .card-bookmark { opacity: 1; }

/* Member Profile Page */
.member-page { max-width: 1200px; margin: 0 auto; padding: 36px 24px; }
.member-header { margin-bottom: 36px; }
.member-greeting { font-family: var(--display); font-size: clamp(24px, 3vw, 32px); font-weight: 900; margin-bottom: 4px; }
.member-email { font-family: var(--mono); font-size: 12px; color: var(--text-muted); }

.member-tabs { display: flex; gap: 4px; margin-bottom: 28px; border-bottom: 1px solid var(--border); }
.member-tab { background: none; border: none; font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--text-muted); padding: 12px 20px; cursor: pointer; border-bottom: 2px solid transparent; transition: all 0.15s; }
.member-tab:hover { color: var(--text); }
.member-tab.active { color: var(--red); border-bottom-color: var(--red); }
.member-tab-count { font-size: 10px; color: var(--text-faint); margin-left: 6px; }

.member-panel { display: none; }
.member-panel.active { display: block; }

.member-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.member-card { border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: border-color 0.2s; }
.member-card:hover { border-color: var(--text-faint); }
.member-card-image { aspect-ratio: 16/9; overflow: hidden; position: relative; }
.member-card-image img { width: 100%; height: 100%; object-fit: cover; }
.member-card-body { padding: 14px 16px; }
.member-card-tag { font-family: var(--mono); font-size: 9px; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 6px; }
.member-card-title { font-family: var(--display); font-size: 16px; font-weight: 800; line-height: 1.3; margin-bottom: 6px; }
.member-card-title a { color: var(--text); text-decoration: none; }
.member-card-title a:hover { color: var(--red); }
.member-card-meta { font-family: var(--mono); font-size: 10px; color: var(--text-faint); }
.member-card-remove { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,0.6); border: none; color: #fff; width: 28px; height: 28px; border-radius: 50%; cursor: pointer; font-size: 14px; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; }
.member-card:hover .member-card-remove { opacity: 1; }
.member-card-remove:hover { background: rgba(203,0,0,0.8); }

.member-empty { text-align: center; padding: 120px 24px; display: flex; flex-direction: column; align-items: center; width: 100%; grid-column: 1 / -1; }
.member-grid { width: 100%; }
.member-empty-icon { color: var(--text-faint); opacity: 0.3; margin-bottom: 20px; }
.member-empty-title { font-family: var(--display); font-size: 18px; font-weight: 800; color: var(--text-muted); margin-bottom: 8px; }
.member-empty-desc { font-family: var(--mono); font-size: 12px; color: var(--text-faint); line-height: 1.6; max-width: 300px; }

.follow-tags-header { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 28px; }
.follow-tags-icon { color: var(--text-faint); flex-shrink: 0; margin-top: 2px; }
.follow-tags-title { font-family: var(--display); font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.follow-tags-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.follow-tag { padding: 10px 20px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--text-muted); cursor: pointer; transition: all 0.15s; background: none; }
.follow-tag:hover { border-color: var(--text-faint); color: var(--text); }
.follow-tag.followed { border-color: var(--red); color: var(--red); background: rgba(203,0,0,0.05); }
.follow-tags-desc { font-family: var(--mono); font-size: 11px; color: var(--text-faint); line-height: 1.6; }

/* ============ Personalized "For You" Section - Premium Dark ============ */
.for-you-section { background: #0a0a0c; border-radius: 12px; padding: 40px; margin: 28px 0; position: relative; overflow: hidden; }
.for-you-section::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--red); }

.for-you-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 32px; gap: 20px; flex-wrap: wrap; }
.for-you-top-left { display: flex; flex-direction: column; gap: 6px; }
.for-you-eyebrow { font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--red); letter-spacing: 0.12em; text-transform: uppercase; display: flex; align-items: center; gap: 8px; }
.for-you-eyebrow::before { content: ''; width: 20px; height: 1px; background: var(--red); }
.for-you-title { font-family: var(--display); font-size: clamp(26px, 3vw, 32px); font-weight: 900; color: #fff; letter-spacing: -0.02em; line-height: 1; }
.for-you-sub { font-family: var(--mono); font-size: 11px; color: #999; margin-top: 4px; }
.for-you-sub strong { color: var(--red); font-weight: 700; }

.for-you-top-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.for-you-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.for-you-chip { font-family: var(--mono); font-size: 9px; font-weight: 700; color: var(--red); background: rgba(203,0,0,0.12); padding: 5px 10px; border-radius: 3px; text-transform: uppercase; letter-spacing: 0.06em; }
.for-you-manage { font-family: var(--mono); font-size: 11px; font-weight: 600; color: #999; text-decoration: none; padding: 8px 14px; border: 1px solid #222; border-radius: 4px; transition: all 0.15s; }
.for-you-manage:hover { border-color: var(--red); color: var(--red); }

.for-you-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 24px; }
.fy-card { cursor: pointer; }
.fy-card a { text-decoration: none; color: inherit; }
.fy-card img { width: 100%; object-fit: cover; border-radius: 6px; transition: opacity 0.2s; }
.fy-card:hover img { opacity: 0.85; }
.fy-card-img-wrap { position: relative; margin-bottom: 14px; }
.fy-card-img-wrap .card-bookmark { top: 8px; right: 8px; }
.fy-card-big img { aspect-ratio: 16/10; }
.fy-card-small img { aspect-ratio: 16/10; }
.fy-card-tag { font-family: var(--mono); font-size: 9px; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 6px; }
.fy-card-big .fy-card-title { font-family: var(--display); font-size: 22px; font-weight: 800; color: #fff; line-height: 1.2; margin-bottom: 8px; letter-spacing: -0.01em; }
.fy-card-small .fy-card-title { font-family: var(--display); font-size: 16px; font-weight: 700; color: #fff; line-height: 1.3; margin-bottom: 6px; letter-spacing: -0.01em; }
.fy-card:hover .fy-card-title { color: var(--red); }
.fy-card-excerpt { font-family: var(--body); font-size: 13px; color: #999; line-height: 1.5; margin-bottom: 8px; }
.fy-meta { font-family: var(--mono); font-size: 9px; color: #555; }
.fy-meta strong { color: #777; font-weight: 700; }

.fy-right { display: flex; flex-direction: column; gap: 16px; }
.fy-mini { display: flex; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid #1a1a1a; }
.fy-mini:last-child { border-bottom: none; padding-bottom: 0; }
.fy-mini a { display: flex; gap: 12px; text-decoration: none; color: inherit; width: 100%; }
.fy-mini img { width: 80px; height: 60px; object-fit: cover; border-radius: 4px; flex-shrink: 0; transition: opacity 0.2s; }
.fy-mini:hover img { opacity: 0.85; }
.fy-mini-body { flex: 1; min-width: 0; }
.fy-mini-tag { font-family: var(--mono); font-size: 8px; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 3px; }
.fy-mini-title { font-family: var(--display); font-size: 13px; font-weight: 700; color: #fff; line-height: 1.3; margin-bottom: 4px; }
.fy-mini:hover .fy-mini-title { color: var(--red); }
.fy-mini-time { font-family: var(--mono); font-size: 9px; color: #555; }

@media (max-width: 900px) {
  .for-you-section { border-radius: 0; padding: 28px 0; }
  .for-you-grid { grid-template-columns: 1fr; gap: 20px; }
  .for-you-top, .for-you-grid { padding: 0 20px; }
  .for-you-top-right { width: 100%; justify-content: space-between; }
}



/* Notification dropdown */

/* Profile page notifications panel */
/* Two-channel intro section */
.notif-intro { padding-bottom: 24px; margin-bottom: 24px; border-bottom: 1px solid var(--border); }
.notif-intro-title { font-family: var(--display); font-size: 18px; font-weight: 800; margin-bottom: 6px; }
.notif-intro-desc { font-family: var(--mono); font-size: 11px; color: var(--text-faint); line-height: 1.6; margin: 0; max-width: 560px; }

/* Notification channel blocks */
.notif-channel { margin-bottom: 28px; }
.notif-channel-header { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 16px; }
.notif-channel-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.notif-channel-icon-bell { background: rgba(42,122,42,0.08); color: #2a7a2a; }
.notif-channel-icon-push { background: rgba(203,0,0,0.08); color: var(--red); }
.notif-channel-info { flex: 1; min-width: 0; }
.notif-channel-title { font-family: var(--display); font-size: 16px; font-weight: 800; margin-bottom: 4px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.notif-channel-badge-always { font-family: var(--mono); font-size: 9px; font-weight: 700; color: #2a7a2a; background: rgba(42,122,42,0.1); padding: 3px 8px; border-radius: 3px; text-transform: uppercase; letter-spacing: 0.06em; }
.notif-channel-desc { font-family: var(--mono); font-size: 11px; color: var(--text-faint); line-height: 1.6; margin: 0; max-width: 560px; }


.notif-settings-header { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 28px; }
.notif-settings-icon { color: var(--text-faint); flex-shrink: 0; margin-top: 2px; }
.notif-settings-title { font-family: var(--display); font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.notif-settings-desc { font-family: var(--mono); font-size: 11px; color: var(--text-faint); line-height: 1.6; margin: 0; max-width: 500px; }

.notif-status-card { border: 1px solid var(--border); border-radius: 8px; padding: 20px; margin-bottom: 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.notif-status-info { flex: 1; min-width: 200px; }
.notif-status-label { font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.notif-status-value { font-family: var(--display); font-size: 16px; font-weight: 700; }
.notif-status-value.enabled { color: #2a7a2a; }
.notif-status-value.blocked { color: var(--red); }
.notif-status-value.disabled { color: var(--text-muted); }
.notif-status-badge { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.notif-action-btn { background: var(--red); color: #fff; border: none; padding: 12px 20px; font-family: var(--mono); font-size: 11px; font-weight: 700; border-radius: 4px; cursor: pointer; }
.notif-action-btn:hover { background: #a00; }
.notif-action-btn.secondary { background: none; color: var(--text); border: 1px solid var(--border); }
.notif-action-btn.secondary:hover { border-color: var(--text-faint); }

.notif-help { background: rgba(203,0,0,0.03); border: 1px solid rgba(203,0,0,0.15); border-radius: 8px; padding: 20px; }
.notif-help-title { font-family: var(--display); font-size: 14px; font-weight: 800; margin-bottom: 12px; }
.notif-help-steps { font-family: var(--mono); font-size: 11px; color: var(--text-muted); line-height: 1.8; }
.notif-help-steps ol { padding-left: 20px; margin: 0; }
.notif-help-steps li { margin-bottom: 4px; }
.notif-help-steps strong { color: var(--text); }


.notif-section { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border); }
.notif-section-title { font-family: var(--display); font-size: 16px; font-weight: 800; margin-bottom: 4px; }
.notif-section-desc { font-family: var(--mono); font-size: 11px; color: var(--text-faint); line-height: 1.6; margin-bottom: 16px; }

.notif-category-list { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.notif-category-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--border); }
.notif-category-row:last-child { border-bottom: none; }
.notif-category-name { font-family: var(--display); font-size: 14px; font-weight: 700; }
.notif-category-row.muted .notif-category-name { color: var(--text-faint); }

.notif-toggle-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; cursor: pointer; }
.notif-toggle-label { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--text); }
.notif-toggle { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.notif-toggle input { opacity: 0; width: 0; height: 0; }
.notif-toggle-slider { position: absolute; cursor: pointer; inset: 0; background: var(--border); border-radius: 24px; transition: background 0.2s; }
.notif-toggle-slider::before { content: ''; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px; background: #fff; border-radius: 50%; transition: transform 0.2s; }
.notif-toggle input:checked + .notif-toggle-slider { background: var(--red); }
.notif-toggle input:checked + .notif-toggle-slider::before { transform: translateX(20px); }

.notif-quiet-row { border: 1px solid var(--border); border-radius: 8px; padding: 18px; }
.notif-quiet-times { display: flex; gap: 16px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); }
.notif-quiet-field { flex: 1; }
.notif-quiet-field label { display: block; font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 6px; }
.notif-quiet-field select { width: 100%; padding: 10px 12px; background: var(--bg); border: 1px solid var(--border); color: var(--text); font-family: var(--mono); font-size: 13px; border-radius: 4px; cursor: pointer; }
.notif-quiet-field select:focus { border-color: var(--red); outline: none; }

.notif-status-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); margin-left: 6px; opacity: 0; transition: opacity 0.2s; }
.notif-status-dot.show { opacity: 1; }

.notif-dropdown-wrap { position: relative; }
.notif-dropdown-wrap .notif-bell { position: relative; }
.notif-dot { position: absolute; top: 4px; right: 4px; width: 8px; height: 8px; background: var(--red); border-radius: 50%; border: 2px solid var(--bg); }
.notif-dropdown { position: absolute; top: 100%; right: auto; left: 0; margin-top: 8px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 8px; width: 360px; max-height: 480px; padding: 0; opacity: 0; visibility: hidden; transform: translateY(-4px); transition: all 0.15s ease; z-index: 100; box-shadow: 0 4px 16px rgba(0,0,0,0.1); overflow: hidden; display: flex; flex-direction: column; }
@media (min-width: 769px) {
  .notif-dropdown.mobile-right { right: 0; left: auto; }
}
.notif-dropdown.open { opacity: 1; visibility: visible; transform: translateY(0); }
.notif-dropdown-header { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.notif-dropdown-title { font-family: var(--display); font-size: 14px; font-weight: 800; color: var(--text); }
.notif-dropdown-clear { background: none; border: none; font-family: var(--mono); font-size: 10px; font-weight: 600; color: var(--red); cursor: pointer; padding: 4px; }
.notif-dropdown-clear:hover { text-decoration: underline; }
.notif-dropdown-list { overflow-y: auto; flex: 1; }
.notif-dropdown-empty { text-align: center; padding: 40px 20px; font-family: var(--mono); font-size: 11px; color: var(--text-faint); }
.notif-item { display: flex; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background 0.1s; text-decoration: none; color: inherit; }
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--bg-alt2); }
.notif-item.unread { background: rgba(203,0,0,0.03); position: relative; }
.notif-item.unread::before { content: ''; position: absolute; left: 6px; top: 50%; transform: translateY(-50%); width: 4px; height: 4px; background: var(--red); border-radius: 50%; }
.notif-item-img { width: 48px; height: 48px; object-fit: cover; border-radius: 4px; flex-shrink: 0; background: var(--bg-alt2); }
.notif-item-body { flex: 1; min-width: 0; }
.notif-item-tag { font-family: var(--mono); font-size: 8px; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 2px; }
.notif-item-title { font-family: var(--display); font-size: 13px; font-weight: 700; color: var(--text); line-height: 1.3; margin-bottom: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.notif-item-time { font-family: var(--mono); font-size: 9px; color: var(--text-faint); }

.notif-dropdown-footer { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--border); font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--text-muted); text-decoration: none; background: var(--bg-alt); flex-shrink: 0; transition: color 0.15s, background 0.15s; }
.notif-dropdown-footer:hover { color: var(--red); background: var(--bg-alt2); }
.notif-dropdown-footer svg { opacity: 0.7; transition: opacity 0.15s; }
.notif-dropdown-footer:hover svg { opacity: 1; }

/* User menu dropdown */
.nav-member-actions { display: flex; align-items: center; gap: 6px; }
.nav-search-btn { background: none; border: none; color: var(--text-muted); cursor: pointer; padding: 6px; display: flex; align-items: center; transition: color 0.2s; }
.nav-search-btn:hover { color: var(--text); }
.user-menu { position: relative; }
.user-menu-btn { background: none; border: none; color: var(--text-muted); cursor: pointer; padding: 6px; display: flex; align-items: center; transition: color 0.2s; }
.user-menu-btn:hover { color: var(--text); }
.user-dropdown { position: absolute; top: 100%; right: 0; margin-top: 8px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 8px; min-width: 160px; padding: 6px; opacity: 0; visibility: hidden; transform: translateY(-4px); transition: all 0.15s ease; z-index: 100; box-shadow: 0 4px 16px rgba(0,0,0,0.1); }
.user-menu:hover .user-dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.user-dropdown-item { display: block; padding: 10px 14px; font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--text-muted); text-decoration: none; border-radius: 4px; transition: all 0.1s; cursor: pointer; }
.user-dropdown-item:hover { background: var(--bg-alt2); color: var(--text); }
.user-dropdown-sep { height: 1px; background: var(--border); margin: 4px 8px; }
.user-dropdown-logout { color: var(--red); }
.user-dropdown-logout:hover { background: rgba(203,0,0,0.05); color: var(--red); }


/* Auth Prompt Modal */
.auth-prompt-modal { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; transition: opacity 0.2s; }
.auth-prompt-modal.show { opacity: 1; pointer-events: auto; }
.auth-prompt-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(4px); }
.auth-prompt-box { position: relative; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: 40px 32px; max-width: 420px; width: calc(100% - 48px); text-align: center; transform: scale(0.95); transition: transform 0.2s; box-shadow: 0 12px 40px rgba(0,0,0,0.3); }
.auth-prompt-modal.show .auth-prompt-box { transform: scale(1); }
.auth-prompt-close { position: absolute; top: 16px; right: 16px; background: none; border: none; color: var(--text-muted); font-size: 18px; cursor: pointer; padding: 4px 8px; line-height: 1; }
.auth-prompt-close:hover { color: var(--text); }
.auth-prompt-icon { font-size: 32px; margin-bottom: 16px; }
.auth-prompt-title { font-family: var(--display); font-size: 22px; font-weight: 800; margin-bottom: 10px; color: var(--text); }
.auth-prompt-desc { font-family: var(--mono); font-size: 12px; color: var(--text-muted); line-height: 1.6; margin-bottom: 28px; }
.auth-prompt-actions { display: flex; flex-direction: column; gap: 8px; }
.auth-prompt-btn-primary { background: var(--red); color: #fff; border: none; padding: 14px 24px; font-family: var(--mono); font-size: 12px; font-weight: 700; cursor: pointer; border-radius: 6px; letter-spacing: 0.04em; }
.auth-prompt-btn-primary:hover { background: #a00; }
.auth-prompt-btn-secondary { background: none; color: var(--text-muted); border: 1px solid var(--border); padding: 12px 24px; font-family: var(--mono); font-size: 11px; font-weight: 600; cursor: pointer; border-radius: 6px; }
.auth-prompt-btn-secondary:hover { border-color: var(--text-muted); color: var(--text); }

/* Search */
.notif-bell { background: none; border: none; color: var(--text-muted); cursor: pointer; padding: 6px; transition: color 0.2s; display: flex; align-items: center; position: relative; }
@media (hover: hover) { .notif-bell:hover { color: var(--red); } }
.notif-bell.subscribed::after { content: ''; position: absolute; top: 6px; right: 6px; width: 6px; height: 6px; background: var(--red); border-radius: 50%; }
.search-toggle { background: none; border: none; color: var(--text-muted); cursor: pointer; padding: 6px; transition: color 0.2s; display: flex; align-items: center; }
.search-toggle:hover { color: var(--text); }
.search-toggle.mob { display: none; }
@media (max-width: 768px) { .search-toggle.dsk { display: none; } .search-toggle.mob { display: flex; } }

.search-overlay { position: fixed; inset: 0; z-index: 500; background: var(--overlay-bg); backdrop-filter: blur(20px); opacity: 0; pointer-events: none; transition: opacity 0.25s ease; display: flex; flex-direction: column; }
.search-overlay.open { opacity: 1; pointer-events: auto; }
.search-overlay-inner { max-width: 680px; width: 100%; margin: 0 auto; padding: 0 24px; display: flex; flex-direction: column; height: 100%; }

.search-header { padding: 24px 0; display: flex; align-items: center; gap: 16px; border-bottom: 1px solid var(--border); }
.search-input-wrap { flex: 1; display: flex; align-items: center; gap: 12px; background: var(--bg-alt2); border: 2px solid var(--border); padding: 0 16px; border-radius: 8px; transition: border-color 0.2s; }
.search-input-wrap:focus-within { border-color: var(--red); }
.search-icon { color: var(--text-muted); flex-shrink: 0; }
.search-input { flex: 1; background: none; border: none; color: var(--text); font-family: var(--body); font-size: 17px; padding: 14px 0; outline: none; }
.search-input::placeholder { color: var(--text-faint); }
.search-kbd { font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--text-faint); background: var(--bg); border: 1px solid var(--border); border-radius: 4px; padding: 2px 6px; flex-shrink: 0; }
.search-close { background: none; border: none; color: var(--text-muted); font-family: var(--mono); font-size: 12px; font-weight: 700; cursor: pointer; padding: 8px 12px; transition: color 0.15s; flex-shrink: 0; }
.search-close:hover { color: var(--text); }

.search-results { flex: 1; overflow-y: auto; padding: 16px 0; }
.search-empty { text-align: center; padding: 60px 0; }
.search-empty-icon { font-size: 36px; margin-bottom: 12px; }
.search-empty-text { font-family: var(--mono); font-size: 13px; color: var(--text-faint); }
.search-shortcuts { display: flex; justify-content: center; gap: 16px; margin-top: 20px; }
.search-shortcut { font-family: var(--mono); font-size: 11px; color: var(--text-ghost); display: flex; align-items: center; gap: 4px; }
.search-shortcut kbd { font-family: var(--mono); font-size: 10px; color: var(--text-faint); background: var(--bg); border: 1px solid var(--border); border-radius: 3px; padding: 1px 5px; }

.search-result { display: flex; gap: 16px; padding: 14px 12px; border-radius: 8px; cursor: pointer; transition: background 0.15s; text-decoration: none; color: var(--text); align-items: flex-start; }
.search-result:hover, .search-result.active { background: var(--bg-alt2); }
.search-result-img { width: 80px; height: 56px; border-radius: 4px; object-fit: cover; flex-shrink: 0; background: var(--border); }
.search-result-body { flex: 1; min-width: 0; }
.search-result-tag { font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 4px; }
.search-result-title { font-family: var(--display); font-size: 16px; font-weight: 800; line-height: 1.3; letter-spacing: -0.01em; margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.search-result-meta { font-family: var(--mono); font-size: 11px; color: var(--text-faint); }

.search-no-results { text-align: center; padding: 40px 0; font-family: var(--mono); font-size: 13px; color: var(--text-faint); }
.search-loading { text-align: center; padding: 40px 0; font-family: var(--mono); font-size: 13px; color: var(--text-faint); }
.search-result-count { font-family: var(--mono); font-size: 11px; color: var(--text-ghost); margin-bottom: 12px; padding: 0 12px; }

.site-footer { border-top: 1px solid var(--border-subtle); padding: 52px 24px; background: var(--bg-alt2); transition: background 0.35s; position: relative; overflow: hidden; }
.footer-statue { position: absolute; bottom: 0; left: max(24px, calc(50% - 600px)); height: 400px; width: auto; opacity: 0.15; pointer-events: none; z-index: 0; }
.footer-inner { position: relative; z-index: 1; }
.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2.2fr 1fr 1fr 1fr; gap: 40px; }
.footer-desc { font-size: 14px; color: var(--text-muted); line-height: 1.75; max-width: 320px; margin-top: 16px; }
.footer-social { display: flex; gap: 10px; margin-top: 22px; }
.social-icon { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 6px; background: var(--social-bg); border: 1px solid var(--social-border); font-size: 11px; color: var(--text-faint); font-family: var(--mono); cursor: pointer; transition: all 0.2s; }
.social-icon:hover { color: var(--text); border-color: var(--text-muted); }
.footer-col { }
.footer-heading { font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 18px; }
.footer-col a, .footer-link { display: block; font-size: 13px; color: var(--text-muted); margin-bottom: 12px; cursor: pointer; transition: color 0.2s; text-decoration: none; }
.footer-col a:hover, .footer-link:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid var(--border-subtle); margin-top: 44px; padding-top: 24px; display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: var(--text-ghost); font-family: var(--mono); flex-wrap: wrap; gap: 12px; }
.footer-bottom-controls { display: flex; align-items: center; gap: 12px; }
.lang-picker-footer .lang-dropdown-up { top: auto; bottom: 100%; margin-bottom: 4px; }

/* Theme toggle */
.theme-toggle { display: flex; align-items: center; gap: 6px; background: var(--bg-alt); border: 1px solid var(--border-light); border-radius: 20px; padding: 5px 12px 5px 8px; cursor: pointer; font-size: 13px; color: var(--text-muted); font-family: var(--mono); font-weight: 600; transition: all 0.25s; }
.theme-toggle:hover { border-color: var(--text-muted); color: var(--text); }
.theme-icon { font-size: 16px; line-height: 1; }
.theme-label { font-size: 11px; }

/* ============ RESPONSIVE ============ */
@media (max-width: 960px) {
  .top-strip { grid-template-columns: 1fr; }
  .main-sidebar { grid-template-columns: 1fr; }
  .main-story { grid-template-columns: 1fr; }
  .main-story-image { display: none; }
  .opinion-grid { grid-template-columns: 1fr; }
  .category-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 768px) {
  .dsk { display: none !important; }
  .hamburger { display: flex; }
  .section-nav { display: none; }
  .masthead-tagline { display: none; }
  .masthead { position: sticky; top: 0; z-index: 110; padding: 0 16px; }
  .masthead .masthead-inner { height: 56px; display: flex; align-items: center; }
  .masthead .masthead-row { width: 100%; }
  .masthead-row { justify-content: space-between; }
  .masthead-left { display: none; }
  .masthead-right { width: auto; }
  .masthead .site-logo .logo-wordmark { display: none; }
  .masthead .site-logo .logo-icon-img { height: 36px; }
  /* Mobile-optimized notification dropdown — force full-width */
  .notif-dropdown,
  .notif-dropdown.mobile-right { position: fixed !important; left: 8px !important; right: 8px !important; top: 64px !important; width: auto !important; max-height: calc(100vh - 80px) !important; }
}
@media (max-width: 480px) {
  .category-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}

/* ============ TAG PAGE ============ */
.tag-header { padding: 48px 0 32px; border-bottom: 2px solid var(--red); text-align: left; overflow: hidden; }
.tag-header-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; position: relative; }
.tag-header-content { position: relative; z-index: 1; flex: 1; }
.tag-page-title { font-family: var(--display); font-size: clamp(32px, 4vw, 48px); font-weight: 900; letter-spacing: -0.02em; line-height: 1.1; color: var(--text); display: block; padding: 0; margin: 0; border-radius: 0; background: none; text-transform: none; }
.tag-watermark { height: 180px; width: auto; opacity: 0.5; flex-shrink: 0; pointer-events: none; user-select: none; margin-left: 24px; }
.tag-lg { font-size: 14px; padding: 5px 14px; }
.tag-description { font-size: 16px; color: var(--text-secondary); max-width: 600px; margin-top: 12px; line-height: 1.6; text-align: left; }
.tag-count { font-size: 12px; color: var(--text-faint); font-family: var(--mono); margin-top: 8px; }

/* Tag featured */
.tag-featured { padding: 36px 0; border-bottom: 1px solid var(--border-subtle); }
.tag-featured-inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 36px; align-items: center; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.tag-featured-image { display: block; border-radius: 8px; overflow: hidden; aspect-ratio: 16/9; }
.tag-featured-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; display: block; }
.tag-featured-image:hover img { transform: scale(1.03); }
.tag-featured-title { font-size: clamp(24px, 3vw, 34px); font-weight: 900; line-height: 1.15; margin: 12px 0 14px; font-family: var(--display); letter-spacing: -0.02em; }
.tag-featured-title a { color: var(--text); transition: color 0.2s; text-decoration: none; }
.tag-featured-title a:hover { color: var(--red); }
.tag-featured-excerpt { font-size: 15px; line-height: 1.65; color: var(--text-secondary); margin-bottom: 14px; }
.meta-avatar { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; vertical-align: middle; margin-right: 6px; }
.meta-reading { color: var(--text-faint); }

/* Tag body (articles + sidebar) */
.tag-body { padding: 36px 0; }
.tag-body-inner { display: grid; grid-template-columns: 1fr 320px; gap: 36px; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.tag-article { display: grid; grid-template-columns: 1fr 200px; gap: 20px; padding: 24px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; transition: background 0.15s; }
.tag-article:hover { background: var(--row-hover); }
.tag-article:last-child { border-bottom: none; }
.tag-article-title { font-size: 19px; font-weight: 800; line-height: 1.25; margin: 8px 0; font-family: var(--display); }
.tag-article-title a { color: var(--text); transition: color 0.2s; text-decoration: none; }
.tag-article-title a:hover { color: var(--red); }
.tag-article-excerpt { font-size: 14px; line-height: 1.6; color: var(--text-secondary); margin: 0 0 10px; }
.tag-article-image { display: block; border-radius: 6px; overflow: hidden; aspect-ratio: 4/3; align-self: start; }
.tag-article-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; display: block; }
.tag-article:hover .tag-article-image img { transform: scale(1.04); }

/* Sidebar tags */
.sidebar-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.sidebar-tag-link { display: inline-block; padding: 6px 14px; border-radius: 5px; font-size: 12px; font-family: var(--mono); font-weight: 600; background: var(--surface-border); color: var(--text-muted); transition: all 0.2s; text-decoration: none; }
.sidebar-tag-link:hover { background: var(--red); color: #fff; }

/* Sidebar tag pill colors applied dynamically via JS */
.sidebar-tag-link:hover { background: var(--red) !important; color: #fff !important; }

/* Pagination */
.pagination { display: flex; align-items: center; justify-content: center; gap: 16px; padding: 40px 0; font-family: var(--mono); font-size: 13px; color: var(--text-muted); }
.pagination-btn { display: inline-block; padding: 10px 24px; border: 1px solid var(--border-light); border-radius: 6px; font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--text-muted); transition: all 0.2s; text-decoration: none; }
.pagination-btn:hover { border-color: var(--red); color: var(--red); }
.pagination-info { font-size: 12px; color: var(--text-faint); }

/* ============ POST PAGE ============ */
.post-header { padding: 40px 0 0; border-bottom: none; }
.post-header-inner { max-width: 720px; margin: 0 auto; padding: 0 24px 32px; border-bottom: 1px solid var(--border-subtle); }

/* Breadcrumb */
.post-breadcrumb { font-size: 12px; font-family: var(--mono); color: var(--text-faint); margin-bottom: 16px; }
.post-breadcrumb a { color: var(--text-muted); transition: color 0.2s; text-decoration: none; }
.post-breadcrumb a:hover { color: var(--red); }
.breadcrumb-sep { margin: 0 6px; color: var(--text-ghost); }

/* Title & deck */
.post-title { font-size: clamp(32px, 4.5vw, 50px); font-weight: 900; line-height: 1.08; font-family: var(--display); letter-spacing: -0.03em; margin: 14px 0 0; }
.post-deck { font-size: 20px; line-height: 1.5; color: var(--text-secondary); margin: 18px 0 0; font-family: var(--body); }

/* Meta bar */
.post-meta-bar { display: flex; align-items: center; justify-content: space-between; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border-subtle); gap: 16px; flex-wrap: wrap; }
.post-meta-left { display: flex; align-items: center; gap: 12px; }
.post-author-avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.post-author-name { font-weight: 700; font-family: var(--mono); font-size: 14px; color: var(--text); display: block; text-decoration: none; }
.post-author-name:hover { color: var(--red); }
.post-author-avatar-link { text-decoration: none; display: block; flex-shrink: 0; }
.post-meta-details { font-size: 12px; color: var(--text-muted); font-family: var(--mono); margin-top: 2px; }
.post-updated { color: var(--text-faint); }

/* Share */
.post-share { display: flex; gap: 8px; }
.share-btn { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--border); background: none; color: var(--text-muted); font-size: 13px; font-family: var(--mono); font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s; text-decoration: none; }
.share-btn:hover { border-color: var(--red); color: var(--red); }

/* Feature image */
.post-feature-image { max-width: 960px; margin: 0 auto; padding: 32px 24px 0; }
.post-feature-image img { width: 100%; border-radius: 8px; }
.post-feature-image figcaption { font-size: 12px; color: var(--text-faint); font-family: var(--mono); margin-top: 10px; text-align: center; }

/* Post body + sidebar layout */
.post-body-wrap { max-width: 860px; margin: 0 auto; padding: 40px 24px; }
.post-body-inner { display: grid; grid-template-columns: 1fr 60px; gap: 40px; position: relative; overflow: visible; }
.post-body-content { min-width: 0; }

/* Content */
.post-content { font-size: 18px; line-height: 1.78; }
.post-content .kg-width-wide { max-width: 960px; margin-left: calc((720px - 960px) / 2); margin-right: calc((720px - 960px) / 2); }
.post-content .kg-width-full { max-width: none; margin-left: calc((720px - 100vw) / 2); margin-right: calc((720px - 100vw) / 2); width: 100vw; }
.post-content .kg-width-wide img, .post-content .kg-width-full img { width: 100%; }
.post-content .kg-image-card img, .post-content .kg-gallery-image img { border-radius: 6px; }
.post-content .kg-bookmark-card { border: 1px solid var(--border-subtle); border-radius: 8px; overflow: hidden; }
.post-content .kg-bookmark-container { display: flex; text-decoration: none; color: var(--text); }
.post-content .kg-bookmark-content { padding: 20px; flex: 1; }
.post-content .kg-bookmark-title { font-weight: 700; font-family: var(--display); font-size: 16px; }
.post-content .kg-bookmark-description { font-size: 14px; color: var(--text-secondary); margin-top: 6px; }
.post-content .kg-bookmark-metadata { font-size: 12px; color: var(--text-muted); font-family: var(--mono); margin-top: 10px; }
.post-content .kg-bookmark-thumbnail { width: 200px; flex-shrink: 0; }
.post-content .kg-bookmark-thumbnail img { width: 100%; height: 100%; object-fit: cover; }
.post-content h2 { font-family: var(--display); font-size: 28px; font-weight: 800; margin: 40px 0 16px; letter-spacing: -0.02em; }
.post-content h3 { font-family: var(--display); font-size: 22px; font-weight: 700; margin: 32px 0 12px; }
.post-content p { margin-bottom: 22px; }
.post-content a { color: var(--red); text-decoration: underline; text-underline-offset: 3px; }
.post-content a:hover { text-decoration-color: var(--red-hover); }
.post-content a.tag { text-decoration: none; }
.post-content img { border-radius: 6px; margin: 28px 0; }
.post-content blockquote { border-left: 3px solid var(--red); padding: 4px 0 4px 24px; margin: 28px 0; font-style: italic; color: var(--text-secondary); font-size: 20px; line-height: 1.6; }
.post-content ul, .post-content ol { margin: 0 0 22px 24px; }
.post-content li { margin-bottom: 8px; }
.post-content figure { margin: 28px 0; }
.post-content figcaption { font-size: 13px; color: var(--text-faint); font-family: var(--mono); margin-top: 8px; }
.post-content hr { border: none; border-top: 1px solid var(--border-subtle); margin: 40px 0; }
.post-content pre { background: var(--bg-alt2); border: 1px solid var(--border-subtle); border-radius: 6px; padding: 20px; overflow-x: auto; font-size: 14px; line-height: 1.6; margin: 24px 0; }

/* Post tags */
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 40px 0; }
.post-tag { display: inline-block; padding: 5px 14px; border-radius: 5px; font-size: 12px; font-family: var(--mono); font-weight: 600; background: var(--surface-border); color: var(--text-muted); transition: all 0.2s; text-decoration: none; }
.post-tag:hover { background: var(--red); color: #fff; }

/* Author card */
.post-author-card { display: flex; gap: 20px; padding: 28px; border-radius: 10px; border: 1px solid var(--card-border); background: var(--card-bg); margin: 36px 0; }
article .post-author-card { display: none; }
body.tag-opinion article .post-author-card { display: flex; }
.author-card-avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.author-card-name { font-weight: 800; font-family: var(--display); font-size: 18px; color: var(--text); display: block; margin-bottom: 4px; text-decoration: none; }
.author-card-name:hover { color: var(--red); }
.author-card-bio { font-size: 14px; color: var(--text-secondary); line-height: 1.55; margin-bottom: 6px; }
.author-card-link { font-size: 12px; color: var(--red); font-family: var(--mono); }

/* Post inline newsletter */
.post-newsletter { margin: 40px 0; padding: 32px; border-radius: 10px; border: 1px solid var(--surface-border); background: var(--bg-alt); position: relative; overflow: hidden; }
.post-newsletter .newsletter-title { font-size: 20px; }
.post-newsletter .newsletter-desc { font-size: 14px; margin-bottom: 18px; }
.post-newsletter-form { display: flex; gap: 10px; }
.post-newsletter-form .newsletter-input { flex: 1; margin-bottom: 0; padding: 12px 16px; font-size: 14px; min-width: 0; width: auto; display: inline-block; }
.post-newsletter-form .newsletter-btn { white-space: nowrap; padding: 12px 28px; font-size: 13px; flex-shrink: 0; width: auto; display: inline-block; }

/* Post sidebar (sticky share) */
.post-sidebar { position: sticky; top: 120px; align-self: start; overflow: visible; }
.post-sidebar-share { display: flex; flex-direction: column; gap: 8px; }

/* Related section */
.related-section { margin-top: 20px; }

/* ============ RESPONSIVE: TAG & POST ============ */
@media (max-width: 960px) {
  .tag-featured-inner { grid-template-columns: 1fr; }
  .tag-body-inner { grid-template-columns: 1fr; }
  .tag-article { grid-template-columns: 1fr 160px; }
  .post-body-inner { grid-template-columns: 1fr; }
  .post-sidebar { display: none; }
  .post-content .kg-width-wide { max-width: 100%; margin-left: 0; margin-right: 0; }
  .post-content .kg-width-full { margin-left: -24px; margin-right: -24px; width: calc(100% + 48px); }
}
@media (max-width: 768px) {
  .tag-article { grid-template-columns: 1fr; }
  .tag-article-image { display: none; }
  .tag-watermark { display: none; }
  .post-meta-bar { flex-direction: column; align-items: flex-start; }
  .post-newsletter-form { flex-direction: column; }
}
@media (max-width: 480px) {
  .post-author-card { flex-direction: column; text-align: center; align-items: center; }
}

/* ============ Image Lightbox ============ */
.post-content .kg-image,
.post-content .kg-gallery-image img,
.post-content figure img {
  cursor: zoom-in;
  transition: opacity 0.15s;
}
.post-content .kg-image:hover,
.post-content .kg-gallery-image img:hover,
.post-content figure img:hover {
  opacity: 0.92;
}

.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.95);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.lightbox-overlay.open {
  display: flex;
  opacity: 1;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  z-index: 2;
}
.lightbox-close:hover {
  background: rgba(255,255,255,0.15);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  z-index: 2;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.15); }
.lightbox-nav-prev { left: 24px; }
.lightbox-nav-next { right: 24px; }
.lightbox-nav[disabled] { opacity: 0.25; cursor: default; pointer-events: none; }

.lightbox-content {
  position: relative;
  max-width: 95vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox-image {
  max-width: 95vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
  cursor: zoom-out;
}
.lightbox-caption {
  font-family: var(--mono);
  font-size: 12px;
  color: rgba(255,255,255,0.7);
  margin-top: 16px;
  max-width: 80vw;
  text-align: center;
  line-height: 1.5;
}
.lightbox-counter {
  position: absolute;
  top: 20px;
  left: 20px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.1em;
  padding: 6px 12px;
  background: rgba(255,255,255,0.05);
  border-radius: 4px;
}

@media (max-width: 700px) {
  .lightbox-nav { width: 40px; height: 40px; }
  .lightbox-nav-prev { left: 8px; }
  .lightbox-nav-next { right: 8px; }
  .lightbox-close { top: 12px; right: 12px; width: 40px; height: 40px; }
  .lightbox-counter { top: 12px; left: 12px; font-size: 10px; }
}


}
/* ============ Gallery: Hero + Thumbnails (Option C) ============ */
/* Hide Ghost's default gallery layout — we replace it */
.post-content .kg-gallery-card,
.post-content .kg-gallery-container {
  display: block !important;
  max-width: none !important;
  margin: 28px 0 !important;
}
.post-content .kg-gallery-row { display: none !important; }

.bp-gallery {
  margin: 28px 0;
}
.bp-gallery-hero {
  position: relative;
  cursor: zoom-in;
  border-radius: 6px;
  overflow: hidden;
  background: #0a0a0c;
  margin-bottom: 8px;
  height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.post-content .bp-gallery-hero img,
.bp-gallery-hero img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  margin: 0 !important;
  border-radius: 0 !important;
  transition: opacity 0.15s;
}
.bp-gallery-hero:hover img { opacity: 0.92; }
.bp-gallery-hero-counter {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0,0,0,0.72);
  color: #fff;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 6px 10px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  backdrop-filter: blur(4px);
}

.bp-gallery-thumbs-wrap {
  position: relative;
}
.bp-gallery-thumbs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
  scrollbar-width: none;
  user-select: none;
  cursor: grab;
}
.bp-gallery-thumbs.dragging { cursor: grabbing; }
.bp-gallery-thumbs::-webkit-scrollbar { display: none; }

.bp-gallery-thumbs-wrap::before,
.bp-gallery-thumbs-wrap::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 2px;
  width: 40px;
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.2s;
}
.bp-gallery-thumbs-wrap::before {
  left: 0;
  background: linear-gradient(to right, var(--bg) 0%, rgba(250,249,245,0) 100%);
}
.bp-gallery-thumbs-wrap::after {
  right: 0;
  background: linear-gradient(to left, var(--bg) 0%, rgba(250,249,245,0) 100%);
}
.bp-gallery-thumbs-wrap.at-start::before { opacity: 0; }
.bp-gallery-thumbs-wrap.at-end::after { opacity: 0; }

.bp-gallery-thumb-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(20,20,22,0.9);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: all 0.15s;
  box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}
.bp-gallery-thumb-arrow:hover { background: var(--red); }
.bp-gallery-thumb-arrow[disabled] { opacity: 0; pointer-events: none; }
.bp-gallery-thumb-arrow-prev { left: 6px; }
.bp-gallery-thumb-arrow-next { right: 6px; }

.bp-gallery-thumb {
  flex: 0 0 auto;
  width: 88px;
  height: 72px;
  cursor: pointer;
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-alt2);
  position: relative;
  transition: all 0.15s;
  border: 2px solid transparent;
}
.post-content .bp-gallery-thumb img,
.bp-gallery-thumb img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  display: block !important;
  margin: 0 !important;
  border-radius: 0 !important;
  transition: opacity 0.15s;
}
.bp-gallery-thumb.active { border-color: var(--red); }
.bp-gallery-thumb:hover img { opacity: 0.85; }

@media (max-width: 700px) {
  .bp-gallery-hero { height: 320px; }
  .bp-gallery-thumb { width: 72px; height: 60px; }
}

/* ============ Ad Placements ============ */
.bp-ad { display: none; }
.bp-ad.active { display: block; }

/* Desktop article ad (overflows sidebar into right margin) */
.bp-ad-sidebar { width: 220px; border-radius: 6px; overflow: hidden; position: relative; margin-top: 20px; display: none; }
.bp-ad-sidebar a { display: block; text-decoration: none; }
.bp-ad-sidebar img { width: 100%; display: block; border-radius: 6px; transition: opacity 0.2s; }
.bp-ad-sidebar a:hover img { opacity: 0.92; }
.bp-ad-sidebar-label { font-family: var(--mono); font-size: 8px; font-weight: 600; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.1em; text-align: right; margin-top: 6px; opacity: 0.5; }
@media (min-width: 1520px) {
  .bp-ad-sidebar.active { display: block; }
}

/* Homepage strip ad */
.bp-ad-homepage { margin: 32px 0; border-radius: 8px; overflow: hidden; position: relative; }
.bp-ad-homepage a { display: block; text-decoration: none; }
.bp-ad-homepage img { width: 100%; display: block; height: 200px; object-fit: cover; border-radius: 8px; transition: opacity 0.2s; }
.bp-ad-homepage a:hover img { opacity: 0.92; }
.bp-ad-homepage-label { position: absolute; top: 10px; right: 12px; font-family: var(--mono); font-size: 8px; font-weight: 600; color: rgba(255,255,255,0.5); text-transform: uppercase; letter-spacing: 0.1em; background: rgba(0,0,0,0.3); padding: 3px 8px; border-radius: 3px; backdrop-filter: blur(4px); }

@media (max-width: 768px) {
  .bp-ad-homepage img { height: 200px; }
  .bp-ad-homepage { margin: 24px 0; border-radius: 0; }
  .bp-ad-homepage img { border-radius: 0; }
}

/* Article ad (shows on all screens where sidebar ad is hidden) */
.bp-ad-article { display: none !important; }
@media (max-width: 1519px) {
  .bp-ad-article.active { display: block !important; margin: 24px 0; border-radius: 6px; overflow: hidden; position: relative; }
  .bp-ad-article a { display: block; text-decoration: none; }
  .bp-ad-article img { width: 100%; display: block; height: 200px; object-fit: cover; border-radius: 6px; transition: opacity 0.2s; }
  .bp-ad-article a:hover img { opacity: 0.92; }
  .bp-ad-article-label { position: absolute; top: 8px; right: 10px; font-family: var(--mono); font-size: 8px; font-weight: 600; color: rgba(255,255,255,0.5); text-transform: uppercase; letter-spacing: 0.1em; background: rgba(0,0,0,0.3); padding: 3px 8px; border-radius: 3px; backdrop-filter: blur(4px); }
}
@media (max-width: 768px) {
  .bp-ad-article.active { margin: 0; border-radius: 0; }
  .bp-ad-article img { border-radius: 0; }
  .post-newsletter { margin-bottom: 48px; }
  .post-body-wrap { padding-bottom: 0; }
}
