/* =====================================================
   SOCIETAL NEWS — style.css
   Dark mode · Mobile-first · SEO-ready
   ===================================================== */

/* ─── TOKENS ─── */
:root {
  --bg:          #1a1a1a;
  --bg-card:     #242424;
  --bg-header:   #111111;
  --bg-footer:   #0a0a0a;
  --border:      rgba(255,255,255,0.08);
  --border-card: rgba(255,255,255,0.07);

  --text:        #e8e8e8;
  --text-mid:    #a8a8a8;
  --text-muted:  #666666;
  --text-card:   #1a1a1a;   /* for white cards if any */

  --accent:      #e63030;
  --accent-dk:   #b52222;
  --white:       #ffffff;

  --font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --radius:  6px;
  --radius-lg: 10px;
  --shadow-card: 0 2px 12px rgba(0,0,0,0.45);
  --shadow-card-hover: 0 6px 24px rgba(0,0,0,0.65);
  --max-w: 1200px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

a:hover {
  color: #d3d3d3 !important;
}

/* ─── LAYOUT ─── */
.container {
  padding: 1rem;
  max-width: var(--max-w);
  margin: 0 auto;
}

/* =====================================================
   HEADER / NAV
   ===================================================== */
header {
  background: var(--bg-header);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 10px rgba(0,0,0,0.5);
}

.header-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: center;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--white);
}

nav {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}

nav a {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-mid);
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius);
  transition: background 0.18s, color 0.18s;
}

nav a:hover {
  background: rgba(255,255,255,0.07);
  color: var(--white) !important;
}

/* Shop pill */
nav a[href="/store.html"] {
  background: var(--accent);
  color: var(--white) !important;
  padding: 0.35rem 0.85rem;
}
nav a[href="/store.html"]:hover {
  background: var(--accent-dk) !important;
  color: var(--white) !important;
}

/* ─── Dropdown ─── */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.35rem 0.65rem;
  color: var(--text-mid);
  font-family: var(--font);
  text-decoration: none;
  display: inline-block;
  border-radius: var(--radius);
  transition: background 0.18s, color 0.18s;
}

.dropdown-toggle:hover {
  background: rgba(255,255,255,0.07);
  color: var(--white);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: #1e1e1e;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.35rem 0;
  min-width: 220px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.6);
  z-index: 1000;
  pointer-events: none;
}

.dropdown.open .dropdown-menu {
  display: block;
  pointer-events: auto;
}

.dropdown-menu a {
  display: block;
  padding: 0.6rem 1rem;
  font-weight: 500;
  font-size: 0.85rem;
  white-space: nowrap;
  color: var(--text-mid);
  border-bottom: 1px solid var(--border);
  transition: background 0.15s, color 0.15s;
}

.dropdown-menu a:last-child {
  border-bottom: none;
}

.dropdown-menu a:hover {
  background: rgba(255,255,255,0.06);
  color: var(--white) !important;
}

/* =====================================================
   HERO SECTIONS
   ===================================================== */
.hero {
  background-color: var(--bg);
  text-align: center;
  padding: 3rem 1rem;
  background-image:
    radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%),
    url('/assets/you-live-here.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.6);
}

/* Shared hero base for category pages */
.ru-hero, .sn-hero, .gc-hero, .ai-hero, .me-hero {
  background-color: var(--bg);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: var(--max-w);
  margin: 0 auto;
  box-shadow: 0 4px 20px rgba(0,0,0,0.6);
  padding: 1rem;
}

.ru-hero { background-image: radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%), url('/assets/russia-ukraine-war-profile.png'); }
.sn-hero { background-image: radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%), url('/assets/societal-news-background.png'); }
.gc-hero { background-image: radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%), url('/assets/images/geopolitics-profile-01.png'); }
.ai-hero { background-image: radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%), url('/assets/images/ai-data-center.png'); }
.me-hero { background-image: radial-gradient(circle, transparent 60%, rgba(0,0,0,0.5) 100%), url('/assets/images/markets-profile.webp'); }

.hero h1 {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  color: var(--white);
  text-shadow: 0 2px 8px rgba(0,0,0,0.7);
}

.hero p {
  font-size: 1rem;
  margin-bottom: 1.25rem;
  max-width: 35ch;
  margin-left: auto;
  margin-right: auto;
  color: var(--text);
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--white);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  font-weight: 600;
  transition: background 0.18s;
}
.btn:hover { background: var(--accent-dk); }

/* =====================================================
   NEWS CARDS (original .news-card)
   Used on: index, about, kai-tutor pages
   ===================================================== */
.featured-news {
  padding: 1rem;
}

.featured-news h2 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.news-card {
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.22s, transform 0.22s;
  color: var(--text);
}

.news-card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.news-card h3 {
  font-size: 1.05rem;
  padding: 0.75rem;
  color: var(--text);
  line-height: 1.4;
}

/* =====================================================
   SN NEWS CARDS (sn-news-card)
   Used on: news/, category pages, kai-tutor
   ===================================================== */
.sn-news-page {
  padding-top: 1rem;
}

.sn-news-section {
  margin-bottom: 1.5rem;
}

.sn-news-section h2 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.sn-news-section h2 a,
.sn-news-section a h2 {
  color: var(--text);
}

/* Section link wrapper (h2 inside <a>) */
.sn-news-section > a {
  display: inline-block;
  margin-bottom: 1rem;
}

.sn-news-section > a:hover h2,
.sn-news-section > a:hover {
  color: var(--accent) !important;
}

.sn-news-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.sn-news-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius);
  overflow: hidden;
  min-width: 140px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.22s, transform 0.22s;
}

.sn-news-card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.sn-news-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: opacity 0.2s;
}

.sn-news-card:hover img {
  opacity: 0.9;
}

.sn-news-card h3 {
  font-size: 0.92rem;
  line-height: 1.4;
  padding: 0.65rem 0.75rem 0.75rem;
  color: var(--text);
}

.sn-news-card a {
  text-decoration: none;
  color: var(--text);
  display: block;
}

.sn-news-card a:hover {
  color: var(--text) !important;
}

/* =====================================================
   CONTENT PAGES (article pages)
   ===================================================== */
.content-section {
  padding: 2rem 1rem;
  border-top: 3px solid #c0392b;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.35);
  color: #111111;
}

.content-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--text);
  line-height: 1.3;
}

.content-image {
  width: 100%;
  height: auto !important;
  max-width: 100%;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  display: block;
}

.content-section p,
.content-section br,
.content-section h2,
.content-section h3,
.content-section li,
.content-section small,
.content-section em,
.content-section strong,
.content-section a,
.content-section time {
  color: #111111;
}

.content-section p {
  font-size: 1rem;
  line-height: 1.75;
  margin-bottom: 1rem;
  color: #111111;
}

/* Article h2 headings */
.content-section h2 {
  color: var(--text);
  font-size: 1.35rem;
  margin: 1.5rem 0 0.5rem;
}

/* =====================================================
   AD / BANNER STRIP
   ===================================================== */
.ad-wrap {
  width: 100%;
  display: block;
  clear: both;
  margin: 10px 0;
  padding: 1rem;
}

.ad-wrap a { display: block; }

.ad-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  height: 90px;
  max-height: 90px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 25px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.5), 0 6px 20px rgba(0,0,0,0.4);
  background: #111;
}

.ad-inner img {
  max-width: 100%;
  height: auto;
  max-height: 90px;
  object-fit: contain;
  border-radius: 25px;
}

/* =====================================================
   SOCIAL FOLLOW BLOCK
   ===================================================== */
.social-follow-block {
  text-align: center;
  max-width: var(--max-w);
  margin: 0.5rem auto 1rem;
  padding: 1rem;
}

.social-follow-block .news-card {
  display: inline-block;
  text-align: center;
  padding: 1.25rem 1.5rem;
  width: 100%;
  max-width: 420px;
}

.social-follow-block p {
  font-weight: 600;
  line-height: 2;
}

.social-follow-block small {
  font-weight: 400;
  color: var(--text-mid);
}

/* =====================================================
   FOOTER
   ===================================================== */
footer {
  background: var(--bg-footer);
  color: var(--text-mid);
  padding: 2rem 1rem;
  border-top: 1px solid var(--border);
}

.footer-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  text-align: center;
}

.footer-content p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.social-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.social-links a {
  color: var(--text-mid);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
  transition: color 0.18s, border-color 0.18s;
}

.social-links a:hover {
  color: var(--white) !important;
  border-bottom-color: var(--accent);
}

/* =====================================================
   MOBILE — max 480px
   ===================================================== */
@media (max-width: 480px) {

  .hero {
    width: 100%;
    height: auto;
    aspect-ratio: 6/3;
    padding: 2rem 1rem;
  }

  .hero h1 { font-size: 1.5rem; }
  .hero p  { font-size: 0.95rem; }

  .content-section { padding: 1.25rem 0.85rem; }
  .content-title   { font-size: 1.6rem; }

  .container       { max-width: 100%; padding: 0.75rem; }

  .sn-news-card h3 {
    font-size: 0.85rem;
    padding: 0.5rem;
    line-height: 1.3;
  }
}

/* =====================================================
   TABLET — min 768px
   ===================================================== */
@media (min-width: 768px) {

  .header-content {
    flex-direction: row;
    justify-content: space-between;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }

  nav { justify-content: flex-end; }

  .hero {
    aspect-ratio: 32/9;
    padding: 3rem 2rem;
  }

  .hero h1 { font-size: 2.2rem; }

  .news-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

  .footer-content {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }

  .sn-news-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

}

/* =====================================================
   DESKTOP — min 1024px
   ===================================================== */
@media (min-width: 1024px) {

  .hero {
    padding: 6rem 2rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    height: auto;
    aspect-ratio: 32/9;
  }

  .hero h1 { font-size: 2.6rem; }
  .hero p  { font-size: 1.2rem; }

  .sn-news-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
  }

  .sn-news-section h2 { font-size: 1.6rem; }

}