/* ==========================
   DESIGN TOKENS
========================== */

:root {
  --bg-page: #e6edf5;
  --bg-shell: #f9fafb;
  --bg-card: #ffffff;
  --bg-soft: #eef4ff;

  --brand-teal: #0f766e;
  --brand-teal-dark: #115e59;
  --brand-accent: #22c55e;
  --brand-navy: #0f172a;

  --text-main: #111827;
  --text-muted: #6b7280;
  --text-soft: #9ca3af;

  --border-soft: #d1d5db;

  --shadow-soft: 0 14px 40px rgba(15, 23, 42, 0.06);
  --shadow-card: 0 10px 30px rgba(15, 23, 42, 0.05);
}

/* ==========================
   RESET & BASE TYPOGRAPHY
========================== */

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

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-main);
  background: radial-gradient(circle at top, #f9fafb 0, var(--bg-page) 55%, #dbe4f3 100%);
}

/* Links */

a {
  color: var(--brand-teal);
  text-decoration: none;
}

a:hover,
a:focus {
  text-decoration: underline;
}

/* Images */

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

/* Global headings */

h1,
h2,
h3,
h4 {
  color: #111111;
  font-weight: 600;
}

/* Default text */

p,
li {
  color: #222222;
}

/* Placeholder visibility */

input::placeholder,
textarea::placeholder {
  color: #555555;
}

/* ==========================
   ARTICLE PAGES
========================== */

.article-page main {
  padding: 2.5rem 1.25rem 3rem;
}

.article-shell-inner {
  max-width: 1120px;
  margin: 0 auto;
  background-color: var(--bg-shell);
  border-radius: 1.25rem;
  padding: 1.75rem 1.75rem 2.25rem;
  box-shadow: var(--shadow-card);
}

/* Breadcrumb */

.breadcrumb {
  font-size: 0.85rem;
  color: var(--text-soft);
  margin-bottom: 0.75rem;
}

.breadcrumb a {
  color: #4b5563;
}

.breadcrumb a:hover {
  color: var(--text-main);
}

/* Article Header */

.article-header {
  margin-bottom: 1.75rem;
}

.article-label {
  display: inline-flex;
  padding: 0.1rem 0.6rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  border-radius: 999px;
  background-color: #e0f2fe;
  color: #0369a1;
  margin-bottom: 0.35rem;
}

.article-title {
  font-size: 1.9rem;
  line-height: 1.2;
  margin: 0 0 0.35rem;
  color: var(--brand-navy);
}

.subtitle {
  margin: 0 0 0.75rem;
  color: #4b5563;
}

.article-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.article-meta-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.7rem;
  border-radius: 999px;
  font-size: 0.78rem;
  background-color: #e5f3f1;
  color: var(--brand-teal);
}

.article-meta-updated {
  background-color: #f3f4f6;
  color: #374151;
}

/* Main Layout Grid */

.article-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.4fr) minmax(0, 1fr);
  gap: 2.25rem;
}

.article-main {
  min-width: 0;
}

.article-main p {
  margin: 0 0 1rem;
}

/* Aside */

.article-aside {
  min-width: 0;
}

.article-aside-card {
  background-color: var(--bg-card);
  border-radius: 0.9rem;
  box-shadow: var(--shadow-card);
  padding: 1rem 1.1rem;
  margin-bottom: 1rem;
}

.article-aside-card h3 {
  margin: 0 0 0.6rem;
  font-size: 0.98rem;
  color: var(--text-main);
}

.article-aside-card ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.article-aside-card li {
  font-size: 0.9rem;
  color: #4b5563;
  margin-bottom: 0.25rem;
}

/* Back link */

.article-back {
  margin-top: 0.75rem;
}

.article-back a {
  font-size: 0.9rem;
}

/* Responsive layout */

@media (max-width: 900px) {
  .article-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .article-page main {
    padding: 1.75rem 1.1rem 2.5rem;
  }

  .article-shell-inner {
    padding: 1.4rem 1.3rem 2rem;
  }

  .article-title {
    font-size: 1.6rem;
  }
}

/* ==========================
   TOC
========================== */

.toc {
  background-color: var(--bg-card);
  border-radius: 0.9rem;
  padding: 1rem 1.25rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
  margin: 1.3rem 0;
}

.toc h2 {
  margin: 0 0 0.6rem;
  font-size: 0.98rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  color: var(--text-muted);
}

.toc ol {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.92rem;
}

.toc li {
  margin-bottom: 0.25rem;
}

/* ==========================
   CALLOUTS / NOTES
========================== */

.callout,
.note,
.warning,
.danger,
.callout.info {
  border-radius: 0.9rem;
  padding: 0.85rem 1rem;
  margin: 1rem 0;
  font-size: 0.94rem;
}

.callout {
  background-color: #ecfeff;
  border-left: 4px solid #06b6d4;
}

.callout.info {
  background-color: #eff6ff;
  border-left-color: #2563eb;
}

.callout.danger,
.danger {
  background-color: #fef2f2;
  border-left: 4px solid #b91c1c;
}

.callout.warning,
.warning {
  background-color: #fffbeb;
  border-left: 4px solid #d97706;
}

.note {
  background-color: #f3f4f6;
  border-left: 4px solid #6b7280;
}

/* ==========================
   CHECKLISTS
========================== */

.checklist {
  list-style: none;
  padding-left: 0;
  margin: 0 0 1rem;
}

.checklist li {
  position: relative;
  padding-left: 1.4rem;
  margin-bottom: 0.35rem;
}

.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0.1rem;
  font-size: 0.82rem;
  color: #16a34a;
}

/* ==========================
   BUTTONS
========================== */

.tool-btn,
.search-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.7rem 1.2rem;
  margin: 0.3rem 0;
  border-radius: 999px;
  background-color: var(--brand-teal);
  color: #f9fafb;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

.tool-btn:hover,
.search-button:hover {
  background-color: var(--brand-teal-dark);
  text-decoration: none;
}

.search-button .chevron {
  font-size: 1.1rem;
  line-height: 1;
}

/* Optional back-to-top */

.back-to-top {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  background-color: rgba(15, 23, 42, 0.86);
  color: #f9fafb;
  font-size: 0.85rem;
  text-decoration: none;
  z-index: 40;
}

.back-to-top:hover {
  background-color: rgba(15, 23, 42, 0.96);
}

/* ==========================
   AFFILIATE BOX
========================== */

.affiliate-box {
  background-color: #fefce8;
  border-radius: 0.9rem;
  padding: 1rem 1.1rem;
  margin: 1.25rem 0;
  border: 1px solid #facc15;
}

.affiliate-box h3 {
  margin: 0 0 0.6rem;
  font-size: 1rem;
  color: #854d0e;
}

.affiliate-box ul {
  margin: 0 0 0.5rem;
  padding-left: 1.1rem;
}

.affiliate-box p {
  margin: 0;
  font-size: 0.88rem;
  color: #78350f;
}

/* ==========================
   RELATED LINKS
========================== */

.related-links {
  margin: 1.8rem 0 0.5rem;
  padding-top: 0.4rem;
  border-top: 1px solid #e5e7eb;
}

.related-links h3 {
  margin: 0 0 0.6rem;
  font-size: 1rem;
}

.related-links ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.related-links li {
  margin-bottom: 0.35rem;
}

/* ==========================
   TABLES
========================== */

table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.75rem 0 1.25rem;
  font-size: 0.92rem;
}

table th,
table td {
  border: 1px solid #e5e7eb;
  padding: 0.45rem 0.6rem;
  text-align: left;
}

table th {
  background-color: #f3f4f6;
  font-weight: 600;
}

/* ==========================
   HOMEPAGE SHELL
========================== */

.home-page {
  background: transparent;
}

.shell {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.75rem 1.25rem 3rem;
}

.shell-inner {
  max-width: 1120px;
  margin: 0 auto;
}

/* ==========================
   HEADER / BRAND STRIP
========================== */

.site-header {
  margin-bottom: 2.1rem;
}

/* Brand pill layout */
.brand {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* keeps brand text next to logo */
  gap: 0.75rem;
  padding: 0.9rem 1.4rem;
  background-color: var(--bg-card);
  border-radius: 999px;
  box-shadow: var(--shadow-soft);
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

/* Article images */
.article-image {
  display: block;
  max-width: 700px;
  width: 100%;
  margin: 1.5rem auto;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  object-fit: cover;
}


/* Left: mark + text */

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 20%, #a7f3d0 0, var(--brand-teal) 45%, #0f172a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.brand-icon {
  font-size: 1.5rem;
  color: #f9fafb;
  transform: translateY(1px);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

/* FORCE brand text to stay close to logo */
.brand {
  justify-content: flex-start;  /* stay aligned left */
}

.brand-mark {
  margin-right: 0.6rem;  /* gentle spacing */
}

.brand-text {
  margin-left: 0 !important;
  flex: 0 0 auto;  /* prevents auto spacing */
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* ensures full header aligns left */
}

.brand-name {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--brand-navy);
}

.brand-name-soft {
  font-weight: 500;
  color: var(--brand-teal);
}

.brand-tagline {
  font-size: 0.9rem;
  color: #64748b;
}

/* Right: chip */

.nav-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.85rem;
  border-radius: 999px;
  background-color: #f1f5f9;
  border: 1px solid #e2e8f0;
  font-size: 0.88rem;
  color: #475569;
}

.nav-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background-color: var(--brand-accent);
}

/* Mobile */

@media (max-width: 640px) {
  .brand {
    flex-direction: column;
    align-items: flex-start;
    padding: 0.8rem 1.1rem;
    border-radius: 1.1rem;
  }

  .nav-chip {
    margin-left: 48px;
  }
}

/* ==========================
   HERO SECTION (MAIN PAGE POP)
========================== */

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(0, 1.1fr);
  gap: 2rem;
  align-items: flex-start;
  margin-bottom: 2.75rem;

  background: radial-gradient(circle at top left, #ecfeff 0, #e0f2fe 45%, #fdfdfd 100%);
  border-radius: 1.5rem;
  padding: 1.7rem 1.8rem;
  box-shadow: var(--shadow-soft);
}

.hero-main {
  min-width: 0;
}

/* pill */

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  background-color: rgba(239, 246, 255, 0.9);
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
  color: #1f2937;
}

.badge {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #1d4ed8;
}

/* title + subtitle */

.hero-title {
  font-size: 2.2rem;
  line-height: 1.15;
  margin: 0 0 0.5rem;
  color: var(--brand-navy);
}

.hero-title .highlight {
  color: var(--brand-teal);
}

.hero-subtitle {
  margin: 0 0 1.1rem;
  font-size: 0.98rem;
  color: var(--text-muted);
}

/* Search row */

.search-shell {
  display: flex;
  align-items: stretch;
  max-width: 540px;
  border-radius: 999px;
  border: 1px solid var(--border-soft);
  background-color: var(--bg-card);
  padding: 0.15rem 0.15rem 0.15rem 0.75rem;
  margin-bottom: 0.9rem;
}

.search-icon {
  font-size: 1rem;
  margin-right: 0.4rem;
  color: var(--text-soft);
  display: flex;
  align-items: center;
}

.search-input {
  flex: 1;
  border: none;
  font-size: 0.95rem;
  padding: 0.45rem 0.5rem;
  outline: none;
  min-width: 0;
  background: transparent;
}

/* Hero hints */

.hero-hints {
  margin-bottom: 1rem;
}

.hero-hints span {
  display: inline-block;
  padding: 0.25rem 0.7rem;
  margin: 0 0.25rem 0.35rem 0;
  font-size: 0.86rem;
  border-radius: 999px;
  background-color: #d9f9f4;
  color: #065f46;
}

/* Bulleted info */

.hero-list {
  list-style: none;
  padding-left: 0;
  margin: 0.6rem 0 0;
}

.hero-list li {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
  font-size: 0.95rem;
  color: #374151;
}

.hero-bullet {
  width: 6px;
  margin-top: 0.55rem;
  height: 6px;
  border-radius: 999px;
  background-color: var(--brand-teal);
  flex-shrink: 0;
}

/* Right column / aside */

.hero-aside {
  background-color: var(--bg-card);
  border-radius: 1.2rem;
  padding: 1.1rem 1.2rem;
  border: 1px solid #d9e2f2;
  box-shadow: var(--shadow-card);
}

.hero-aside-title {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.hero-aside-sub {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin: 0 0 0.9rem;
}

/* Metrics */

.hero-metrics {
  margin-top: 0.3rem;
}

.metrics-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.metric {
  min-width: 120px;
}

.metric-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-soft);
}

.metric-value {
  font-size: 1.2rem;
  font-weight: 650;
  color: var(--text-main);
}

.metric-sub {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ==========================
   SECTIONS / CATEGORY CARDS
========================== */

.section {
  margin-bottom: 2.6rem;
}

.section-header {
  margin-bottom: 0.9rem;
}

.section-title {
  font-size: 1.35rem;
  margin: 0 0 0.2rem;
  color: var(--brand-navy);
}

.section-subtitle {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Category cards */

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}

.category-card {
  background-color: var(--bg-card);
  border-radius: 1rem;
  padding: 1rem 1.1rem;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: var(--shadow-card);
}

.category-card h3 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
  color: var(--brand-navy);
}

.category-card p {
  margin: 0 0 0.6rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.category-links {
  font-size: 0.9rem;
}

.category-links a {
  display: inline-block;
  margin: 0.15rem 0.35rem 0.15rem 0;
  color: var(--brand-teal);
}

/* Featured + article list */

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.1fr);
  gap: 1.5rem;
}

.article-featured {
  background-color: var(--bg-card);
  border-radius: 0.9rem;
  padding: 1rem 1.1rem;
  box-shadow: var(--shadow-card);
}

.article-featured-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.article-featured-title {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
}

.article-featured-excerpt {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.8rem;
}

.article-meta-badge {
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  background-color: #ecfeff;
  color: var(--brand-teal);
}

.article-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.article-side-item {
  margin-bottom: 0.5rem;
}

.article-side-link {
  display: block;
  font-size: 0.9rem;
}

.article-side-head {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-soft);
  margin-bottom: 0.4rem;
}

/* ==========================
   FOOTER
========================== */

.site-footer {
  border-top: 1px solid #cbd5e1;
  margin-top: 2.5rem;
}

.site-footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.1rem 1.25rem 2rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ==========================
   RESPONSIVE TWEAKS
========================== */

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .article-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .shell {
    padding: 1.75rem 1rem 2.5rem;
  }
}

@media (max-width: 640px) {
  .search-shell {
    flex-direction: column;
    border-radius: 0.9rem;
  }

  .search-button {
    justify-content: center;
    width: 100%;
  }
}

/* Article page header layout */
.article-header {
  max-width: 720px;
  margin: 2.5rem auto 1.5rem;
  padding: 0 1.5rem;
}

.article-header .back-link {
  display: inline-block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  text-decoration: none;
  color: #4b5563;
}

.article-header .back-link:hover {
  text-decoration: underline;
}

.article-header h1 {
  margin: 0 0 0.4rem;
  font-size: 1.9rem;
  line-height: 1.25;
}

.article-header .article-subtitle {
  margin: 0;
  font-size: 1rem;
  color: #6b7280;
}
.image-caption {
  text-align: center;
  font-size: 0.9rem;
  color: #666;
  margin-top: -0.5rem;
  margin-bottom: 1.5rem;
  font-style: italic;
}

/* =======================
   Article List Styling
   ======================= */
.article-section {
  margin: 2rem 0;
}

.article-section h2 {
  font-size: 1.4rem;
  margin-bottom: 0.8rem;
}

.article-list li {
  margin-bottom: 0.5rem;
}

.article-list a {
  color: #0056d6;
  text-decoration: none;
}

.article-list a:hover {
  text-decoration: underline;
}

