/* ===== Custom Properties ===== */
:root {
  --color-primary: #1a56db;
  --color-primary-dark: #1e40af;
  --color-navy: #0d1b3e;
  --color-green: #0d7a3e;
  --color-green-light: #e6f4ed;
  --color-text: #1f2937;
  --color-text-light: #6b7280;
  --color-bg: #ffffff;
  --color-bg-alt: #f8f9fa;
  --color-border: #e5e7eb;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: Georgia, "Times New Roman", Times, serif;
  --container: 1200px;
  --radius: 8px;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font-sans); color: var(--color-text); background: var(--color-bg); line-height: 1.6; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
ul, ol { list-style: none; }
img { max-width: 100%; display: block; }

/* ===== Layout ===== */
.container { max-width: var(--container); margin: 0 auto; padding: 0 1.5rem; }

/* ===== Header ===== */
.site-header {
  background: var(--color-navy);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.5px;
}
.logo-mark {
  width: 1.7rem;
  height: 1.7rem;
  flex-shrink: 0;
}
.logo-text { line-height: 1; }
.logo:hover { text-decoration: none; opacity: 0.9; }
.nav-menu { display: flex; align-items: center; gap: 0.25rem; }
.nav-link {
  color: rgba(255,255,255,0.85);
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
  font-weight: 500;
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.nav-link:hover { color: #fff; text-decoration: none; }

/* ===== Dropdown ===== */
.nav-dropdown { position: relative; }
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 10px 40px rgba(0,0,0,0.15);
  padding: 1.25rem;
  min-width: 420px;
  margin-top: 0.5rem;
}
.nav-dropdown:hover .dropdown-menu { display: block; }
.dropdown-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
}
.dropdown-item {
  color: var(--color-text);
  padding: 0.5rem 0.75rem;
  border-radius: 4px;
  font-size: 0.9rem;
  white-space: nowrap;
}
.dropdown-item:hover {
  background: var(--color-bg-alt);
  color: var(--color-primary);
  text-decoration: none;
}

/* ===== Hamburger ===== */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  transition: 0.3s;
}

/* ===== Hero ===== */
.hero {
  background: var(--color-navy);
  color: #fff;
  padding: 4rem 0;
}
.hero-category {
  display: inline-block;
  color: rgba(255,255,255,0.7);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}
.hero-category:hover { color: #fff; text-decoration: none; }
.hero h1 { font-size: 2.5rem; line-height: 1.2; margin-bottom: 1rem; max-width: 800px; }
.hero h1 a { color: #fff; }
.hero h1 a:hover { text-decoration: underline; }
.hero-summary {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.8);
  max-width: 700px;
  margin-bottom: 1.5rem;
  line-height: 1.7;
}
.hero-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: rgba(255,255,255,0.6);
  font-size: 0.9rem;
}

/* ===== Sections ===== */
.section { padding: 3rem 0; }
.section-alt { background: var(--color-bg-alt); }
.section-title {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--color-navy);
}
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}
.section-header .section-title { margin-bottom: 0; }
.section-link {
  font-size: 0.9rem;
  font-weight: 600;
}

/* ===== Article Grid ===== */
.article-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

/* ===== Article Card ===== */
.article-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s;
}
.article-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-size: 0.8rem;
}
.card-category {
  color: var(--color-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.card-category:hover { text-decoration: none; opacity: 0.8; }
.card-date { color: var(--color-text-light); }
.card-title {
  font-size: 1.1rem;
  line-height: 1.35;
  margin-bottom: 0.75rem;
}
.card-title a { color: var(--color-text); }
.card-title a:hover { color: var(--color-primary); text-decoration: none; }
.card-summary {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1rem;
}
.card-footer {
  display: flex;
  align-items: center;
}

/* ===== Source Badge ===== */
.source-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--color-green-light);
  color: var(--color-green);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
}
.source-badge::before {
  content: "\2713";
  font-weight: 700;
}

/* ===== Article Page ===== */
.article-header {
  background: var(--color-navy);
  color: #fff;
  padding: 3rem 0;
}
.article-category {
  display: inline-block;
  color: rgba(255,255,255,0.7);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}
.article-category:hover { color: #fff; text-decoration: none; }
.article-header h1 {
  font-size: 2.25rem;
  line-height: 1.25;
  max-width: 800px;
  margin-bottom: 1rem;
}
.article-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: rgba(255,255,255,0.6);
  font-size: 0.9rem;
}
.article-body-wrap {
  max-width: 800px;
  padding-top: 2.5rem;
  padding-bottom: 3rem;
}
.article-body {
  font-family: var(--font-serif);
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--color-text);
}
.article-body p { margin-bottom: 1.5rem; }

/* ===== Agreement Box ===== */
.agreement-box {
  background: #eef4ff;
  border-left: 4px solid var(--color-green);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.75rem 2rem;
  margin: 2.5rem 0;
}
.agreement-box h2 {
  font-size: 1.15rem;
  color: var(--color-navy);
  margin-bottom: 1rem;
}
.agreement-box ul { list-style: none; }
.agreement-box li {
  padding: 0.5rem 0;
  padding-left: 1.75rem;
  position: relative;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--color-text);
}
.agreement-box li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--color-green);
  font-weight: 700;
}
.agreement-box li + li {
  border-top: 1px solid rgba(0,0,0,0.06);
}

/* ===== Spin Section ===== */
.spin-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin: 2rem 0;
}
.spin-box {
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
}
.spin-box h3 {
  font-size: 1rem;
  margin-bottom: 0.75rem;
}
.spin-box ul { list-style: none; }
.spin-box li {
  padding: 0.4rem 0;
  padding-left: 1.25rem;
  position: relative;
  font-size: 0.9rem;
  line-height: 1.5;
}
.spin-box li::before {
  position: absolute;
  left: 0;
  font-weight: 700;
}
.spin-left {
  background: #eef2ff;
  border-left: 4px solid #3b82f6;
}
.spin-left h3 { color: #1e40af; }
.spin-left li::before { content: "\25CF"; color: #3b82f6; font-size: 0.6rem; top: 0.65rem; }
.spin-right {
  background: #fef2f2;
  border-left: 4px solid #ef4444;
}
.spin-right h3 { color: #991b1b; }
.spin-right li::before { content: "\25CF"; color: #ef4444; font-size: 0.6rem; top: 0.65rem; }

/* ===== Surprise Box ===== */
.surprise-box {
  background: #fffbeb;
  border-left: 4px solid #f59e0b;
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.5rem 2rem;
  margin: 2rem 0;
}
.surprise-box h2 {
  font-size: 1.1rem;
  color: #92400e;
  margin-bottom: 0.75rem;
}
.surprise-box ul { list-style: none; }
.surprise-box li {
  padding: 0.4rem 0;
  padding-left: 1.5rem;
  position: relative;
  font-size: 0.9rem;
  line-height: 1.5;
}
.surprise-box li::before {
  content: "!";
  position: absolute;
  left: 0;
  color: #f59e0b;
  font-weight: 800;
}

@media (max-width: 600px) {
  .spin-section { grid-template-columns: 1fr; }
}

/* ===== Sources Section ===== */
.sources-section {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
}
.sources-section h2 {
  font-size: 1.15rem;
  margin-bottom: 1rem;
  color: var(--color-navy);
}
.sources-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--color-border);
}
.sources-list a { font-weight: 600; }
.source-date { color: var(--color-text-light); font-size: 0.85rem; }

/* ===== Category Page ===== */
.category-header {
  background: var(--color-navy);
  color: #fff;
  padding: 3rem 0;
}
.category-header h1 { font-size: 2rem; margin-bottom: 0.5rem; }
.category-description {
  color: rgba(255,255,255,0.75);
  font-size: 1.05rem;
  max-width: 600px;
}
.category-page .article-grid { padding: 2.5rem 0 3rem; }
.no-articles {
  color: var(--color-text-light);
  font-size: 1.1rem;
  padding: 3rem 0;
}

/* ===== About Page ===== */
.about-page { padding: 3rem 0; }
.about-page h1 {
  font-size: 2rem;
  color: var(--color-navy);
  margin-bottom: 1.5rem;
}
.about-content { max-width: 720px; }
.about-content .lead {
  font-size: 1.2rem;
  color: var(--color-text-light);
  line-height: 1.7;
  margin-bottom: 2rem;
}
.about-content h2 {
  font-size: 1.35rem;
  color: var(--color-navy);
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}
.about-content h3 {
  font-size: 1.1rem;
  color: var(--color-navy);
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}
.about-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
}
.about-content ol {
  list-style: decimal;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.about-content ol li {
  margin-bottom: 0.75rem;
  line-height: 1.6;
}
.about-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}
.about-category-link {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  padding: 0.4rem 0.9rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}
.about-category-link:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
  text-decoration: none;
}

/* ===== Footer ===== */
.site-footer {
  background: var(--color-navy);
  color: rgba(255,255,255,0.75);
  padding: 3rem 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.5fr;
  gap: 2rem;
  padding-bottom: 2.5rem;
}
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.5rem;
}
.footer-logo-mark {
  width: 1.45rem;
  height: 1.45rem;
  flex-shrink: 0;
}
.footer-logo:hover { text-decoration: none; }
.footer-col h4 {
  color: #fff;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}
.footer-topics ul {
  columns: 2;
  gap: 0;
}
.footer-topics li { margin-bottom: 0.4rem; }
.footer-topics a {
  color: rgba(255,255,255,0.65);
  font-size: 0.85rem;
}
.footer-topics a:hover { color: #fff; }
.footer-about p {
  font-size: 0.85rem;
  line-height: 1.6;
  margin-bottom: 0.75rem;
}
.footer-about a {
  color: rgba(255,255,255,0.85);
  font-weight: 600;
  font-size: 0.85rem;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 1.25rem 0;
}
.footer-bottom p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .article-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .footer-about { grid-column: 1 / -1; }
  .dropdown-grid { grid-template-columns: repeat(2, 1fr); }
  .dropdown-menu { min-width: 300px; }
  .hero h1 { font-size: 2rem; }
}

@media (max-width: 600px) {
  .article-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .hero { padding: 2.5rem 0; }
  .hero h1 { font-size: 1.6rem; }
  .hero-summary { font-size: 1rem; }
  .article-header h1 { font-size: 1.6rem; }
  .article-body { font-size: 1rem; }
  .agreement-box { padding: 1.25rem 1.5rem; }

  /* Mobile nav */
  .nav-toggle { display: flex; }
  .nav-menu {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--color-navy);
    flex-direction: column;
    padding: 1rem;
    border-top: 1px solid rgba(255,255,255,0.1);
  }
  .nav-menu.nav-open { display: flex; }
  .nav-link { padding: 0.75rem 1rem; width: 100%; }
  .nav-dropdown { width: 100%; }
  .dropdown-menu {
    position: static;
    transform: none;
    box-shadow: none;
    margin-top: 0;
    min-width: 0;
    background: rgba(255,255,255,0.05);
    border-radius: 4px;
  }
  .dropdown-grid { grid-template-columns: 1fr 1fr; }
  .dropdown-item { color: rgba(255,255,255,0.75); }
  .dropdown-item:hover { background: rgba(255,255,255,0.1); color: #fff; }
  .nav-dropdown:hover .dropdown-menu { display: none; }
  .nav-dropdown.open .dropdown-menu { display: block; }
}
