/* ==========================================================================
   Overp Ghost Theme — Screen Stylesheet
   Matches overp.tn & app.overp.tn visual identity
   ========================================================================== */

:root {
  /* Brand Blue Palette */
  --brand-50:  #eff6ff;
  --brand-100: #dbeafe;
  --brand-200: #bfdbfe;
  --brand-300: #93c5fd;
  --brand-400: #60a5fa;
  --brand-500: #3b82f6;
  --brand-600: #2563eb;
  --brand-700: #1d4ed8;
  --brand-800: #1e40af;
  --brand-900: #1e3a8a;

  /* Accent Colors */
  --accent-emerald: #10b981;
  --accent-emerald-bg: #ecfdf5;
  --accent-orange:  #f37821;

  /* Light Mode Tokens */
  --bg-canvas: #ffffff;
  --bg-subtle: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-hover: #ffffff;
  --bg-header: rgba(255, 255, 255, 0.88);
  --border-color: #e2e8f0;
  --border-subtle: #f1f5f9;
  --border-hover: #cbd5e1;
  --text-heading: #0f172a;
  --text-body: #475569;
  --text-muted: #64748b;
  --text-inverse: #ffffff;
  --code-bg: #f1f5f9;
  --code-color: #0f172a;
  --cta-bg: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --grid-line: rgba(15, 23, 42, 0.04);
}

html.dark {
  /* Dark Mode Tokens */
  --bg-canvas: #020617;
  --bg-subtle: #0b1329;
  --bg-card: #0f172a;
  --bg-card-hover: #172033;
  --bg-header: rgba(2, 6, 23, 0.85);
  --border-color: #1e293b;
  --border-subtle: #1e293b;
  --border-hover: #334155;
  --text-heading: #f8fafc;
  --text-body: #94a3b8;
  --text-muted: #64748b;
  --text-inverse: #020617;
  --code-bg: #0f172a;
  --code-color: #93c5fd;
  --cta-bg: linear-gradient(135deg, #0b1329 0%, #172554 100%);
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
  --grid-line: rgba(255, 255, 255, 0.04);
}

/* ==========================================================================
   Base & Reset
   ========================================================================== */

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

html {
  font-family: var(--gh-font-body, 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
  scroll-behavior: smooth;
  color-scheme: light dark;
}

body {
  font-family: var(--gh-font-body, 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
  background-color: var(--bg-canvas);
  color: var(--text-body);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color 0.2s ease, color 0.2s ease;
}

h1, h2, h3, h4, h5, h6, .hero-title, .article-title {
  font-family: var(--gh-font-heading, var(--gh-font-body, 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif));
}

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

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

.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.site-main {
  flex-grow: 1;
}

.container {
  max-width: 80rem; /* 1280px */
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

@media (min-width: 640px) {
  .container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

.bg-grid {
  background-image:
    linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--bg-header);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4.25rem; /* 68px */
}

.brand-logo-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--text-heading);
}

.brand-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.15rem 0.45rem;
  border-radius: 9999px;
  background-color: var(--brand-50);
  color: var(--brand-600);
  border: 1px solid var(--brand-200);
}

html.dark .brand-badge {
  background-color: rgba(30, 58, 138, 0.4);
  color: var(--brand-300);
  border-color: rgba(96, 165, 250, 0.3);
}

.nav-desktop {
  display: none;
  align-items: center;
  gap: 1.75rem;
}

@media (min-width: 860px) {
  .nav-desktop {
    display: flex;
  }
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-body);
  position: relative;
  padding: 0.25rem 0;
  transition: color 0.15s ease;
}

.nav-link:hover, .nav-link.nav-current {
  color: var(--text-heading);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background-color: var(--brand-600);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.nav-link:hover::after, .nav-link.nav-current::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn-icon {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-body);
  padding: 0.5rem;
  border-radius: 0.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.btn-icon:hover {
  background-color: var(--bg-subtle);
  color: var(--text-heading);
}

.btn-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.btn-login {
  display: none;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-body);
  padding: 0.5rem 0.75rem;
  transition: color 0.15s ease;
}

@media (min-width: 640px) {
  .btn-login {
    display: inline-flex;
  }
}

.btn-login:hover {
  color: var(--text-heading);
}

.btn-app {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--brand-600);
  color: #ffffff !important;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow-sm);
  transition: background-color 0.15s ease, transform 0.1s ease;
}

.btn-app:hover {
  background-color: var(--brand-700);
}

.btn-mobile-toggle {
  display: flex;
}

@media (min-width: 860px) {
  .btn-mobile-toggle {
    display: none;
  }
}

.mobile-menu-drawer {
  display: none;
  flex-direction: column;
  background-color: var(--bg-canvas);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 1.5rem 1.5rem;
  gap: 0.75rem;
}

.mobile-menu-drawer.open {
  display: flex;
}

.mobile-menu-drawer .nav-link {
  font-size: 1rem;
  padding: 0.5rem 0;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.blog-hero {
  position: relative;
  border-bottom: 1px solid var(--border-color);
  background-color: var(--bg-canvas);
  padding: 3.5rem 0 4.5rem;
  overflow: hidden;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background-color: var(--bg-subtle);
  color: var(--text-heading);
  border: 1px solid var(--border-color);
  margin-bottom: 1.25rem;
}

.pulse-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 9999px;
  background-color: var(--accent-emerald);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.hero-title {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  max-width: 48rem;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .hero-title {
    font-size: 3rem;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 3.5rem;
  }
}

.hero-subtitle {
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text-body);
  max-width: 42rem;
}

/* ==========================================================================
   Featured Post Banner
   ========================================================================== */

.featured-post-banner {
  margin-top: -2rem;
  margin-bottom: 3.5rem;
}

.featured-card {
  display: grid;
  grid-template-columns: 1fr;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

@media (min-width: 900px) {
  .featured-card {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

.featured-card:hover {
  transform: translateY(-3px);
  border-color: var(--brand-400);
  box-shadow: var(--shadow-lg);
}

.featured-img-wrap {
  position: relative;
  min-height: 260px;
  background-color: var(--bg-subtle);
  overflow: hidden;
}

.featured-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.featured-card:hover .featured-img-wrap img {
  transform: scale(1.03);
}

.featured-content {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

@media (min-width: 640px) {
  .featured-content {
    padding: 2.5rem;
  }
}

/* ==========================================================================
   Post Grid & Post Card
   ========================================================================== */

.posts-section {
  padding: 3.5rem 0 5rem;
}

.posts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 640px) {
  .posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .posts-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.post-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0.875rem;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.post-card:hover {
  transform: translateY(-4px);
  border-color: var(--brand-300);
  box-shadow: var(--shadow-lg);
}

.post-card-img-link {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  background-color: var(--bg-subtle);
  overflow: hidden;
}

.post-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.post-card-img-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 50%, #020617 100%);
  color: #ffffff;
  padding: 1.5rem;
}

.post-card-img-fallback svg {
  width: 2.25rem;
  height: 2.25rem;
  opacity: 0.95;
}

.post-card-img-fallback span {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.9;
}

.post-card:hover .post-card-img {
  transform: scale(1.04);
}

.post-card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.post-card-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--brand-600);
  margin-bottom: 0.65rem;
}

html.dark .post-card-tag {
  color: var(--brand-400);
}

.post-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-heading);
  margin-bottom: 0.75rem;
  transition: color 0.15s ease;
}

.post-card-title a:hover {
  color: var(--brand-600);
}

html.dark .post-card-title a:hover {
  color: var(--brand-400);
}

.post-card-excerpt {
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--text-body);
  margin-bottom: 1.25rem;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.85rem;
  margin-top: auto;
}

.post-card-author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  color: var(--text-heading);
}

.post-card-avatar {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 9999px;
  object-fit: cover;
}

.author-initial-avatar {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 9999px;
  background-color: var(--brand-600);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.725rem;
  font-weight: 700;
  text-transform: uppercase;
  flex-shrink: 0;
}

.author-initial-avatar.large {
  width: 2.25rem;
  height: 2.25rem;
  font-size: 0.95rem;
}

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.pagination-wrapper {
  margin-top: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.pagination-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.15rem;
  font-size: 0.875rem;
  font-weight: 600;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-heading);
  border-radius: 0.5rem;
  transition: all 0.15s ease;
}

.pagination-btn:hover {
  background-color: var(--bg-subtle);
  border-color: var(--border-hover);
}

.pagination-page-number {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ==========================================================================
   Single Post & Page Layout
   ========================================================================== */

.article-header {
  padding: 3rem 0 2rem;
  max-width: 48rem; /* 768px */
  margin: 0 auto;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.breadcrumbs a:hover {
  color: var(--brand-600);
}

.article-title {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  margin-bottom: 1.25rem;
}

@media (min-width: 768px) {
  .article-title {
    font-size: 3rem;
  }
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  padding-bottom: 1.75rem;
  border-bottom: 1px solid var(--border-color);
}

.article-author-info {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text-heading);
  font-weight: 600;
}

.article-author-avatar {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 9999px;
  object-fit: cover;
}

.article-feature-img {
  max-width: 58rem;
  margin: 1.5rem auto 3rem;
  border-radius: 0.875rem;
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

.article-feature-img img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

/* ==========================================================================
   Prose / Article Content (.gh-content)
   ========================================================================== */

.gh-content {
  max-width: 46rem; /* Comfortable reading measure ~736px */
  margin: 0 auto;
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--text-body);
}

.gh-content p {
  margin-bottom: 1.6rem;
}

.gh-content h1,
.gh-content h2,
.gh-content h3,
.gh-content h4 {
  color: var(--text-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.gh-content h2 {
  font-size: 1.75rem;
  line-height: 1.3;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.5rem;
}

.gh-content h3 {
  font-size: 1.35rem;
  line-height: 1.35;
}

.gh-content h4 {
  font-size: 1.15rem;
}

.gh-content a {
  color: var(--brand-600);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
}

html.dark .gh-content a {
  color: var(--brand-400);
}

.gh-content strong {
  color: var(--text-heading);
  font-weight: 600;
}

.gh-content ul,
.gh-content ol {
  margin-bottom: 1.6rem;
  padding-left: 1.75rem;
}

.gh-content li {
  margin-bottom: 0.5rem;
}

.gh-content blockquote {
  border-left: 4px solid var(--brand-600);
  padding: 0.75rem 0 0.75rem 1.25rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--text-heading);
  background-color: var(--bg-subtle);
  border-radius: 0 0.5rem 0.5rem 0;
}

.gh-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
  background-color: var(--code-bg);
  color: var(--code-color);
  padding: 0.2em 0.4em;
  border-radius: 0.35rem;
  border: 1px solid var(--border-color);
}

.gh-content pre {
  background-color: #0b1329;
  color: #f8fafc;
  padding: 1.25rem;
  border-radius: 0.65rem;
  overflow-x: auto;
  margin: 2rem 0;
  border: 1px solid var(--border-color);
}

.gh-content pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
  border: none;
}

.gh-content hr {
  border: 0;
  height: 1px;
  background-color: var(--border-color);
  margin: 3rem 0;
}

.gh-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.95rem;
}

.gh-content th,
.gh-content td {
  border: 1px solid var(--border-color);
  padding: 0.75rem 1rem;
  text-align: left;
}

.gh-content th {
  background-color: var(--bg-subtle);
  color: var(--text-heading);
  font-weight: 600;
}

/* Ghost Cards & Gallery */
.kg-card {
  margin: 2rem 0;
}

.kg-width-wide {
  position: relative;
  width: 75vw;
  min-width: 100%;
  margin-left: calc(50% - 37.5vw);
  margin-right: calc(50% - 37.5vw);
  transform: translateX(0);
}

.kg-width-full {
  position: relative;
  width: 100vw;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}

.kg-image-card img {
  border-radius: 0.5rem;
  margin: 0 auto;
}

.kg-card figcaption {
  font-size: 0.8rem;
  text-align: center;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.kg-bookmark-card {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.kg-bookmark-container {
  display: flex;
  text-decoration: none !important;
  color: var(--text-body) !important;
}

.kg-bookmark-content {
  flex-grow: 1;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.kg-bookmark-title {
  color: var(--text-heading);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 0.5rem;
}

.kg-bookmark-description {
  font-size: 0.825rem;
  line-height: 1.5;
  color: var(--text-body);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kg-bookmark-thumbnail {
  position: relative;
  min-width: 30%;
  max-height: 100%;
}

.kg-bookmark-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kg-callout-card {
  display: flex;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 0.65rem;
  border: 1px solid var(--border-color);
  background-color: var(--bg-subtle);
  margin: 2rem 0;
}

/* ==========================================================================
   Article Footer & Social Share
   ========================================================================== */

.article-footer {
  max-width: 46rem;
  margin: 3.5rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.tag-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 0.5rem;
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-heading);
  transition: all 0.15s ease;
}

.tag-badge:hover {
  border-color: var(--brand-400);
  color: var(--brand-600);
}

.share-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--bg-subtle);
  padding: 1rem 1.25rem;
  border-radius: 0.75rem;
  border: 1px solid var(--border-color);
  margin-bottom: 3.5rem;
}

.share-bar-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-heading);
}

.share-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: 0.375rem;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
}

.share-btn:hover {
  background-color: var(--bg-canvas);
  color: var(--text-heading);
  border-color: var(--border-hover);
}

/* ==========================================================================
   Bottom ERP Conversion CTA Box
   ========================================================================== */

.erp-cta-box {
  background: var(--cta-bg);
  border: 1px solid var(--brand-200);
  border-radius: 1rem;
  padding: 2.5rem 2rem;
  margin: 4rem auto 0;
  max-width: 52rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

html.dark .erp-cta-box {
  border-color: rgba(59, 130, 246, 0.25);
}

.erp-cta-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.725rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background-color: rgba(37, 99, 235, 0.1);
  color: var(--brand-600);
  border: 1px solid rgba(37, 99, 235, 0.2);
  margin-bottom: 1rem;
}

html.dark .erp-cta-badge {
  color: var(--brand-300);
  background-color: rgba(59, 130, 246, 0.15);
}

.erp-cta-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-heading);
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.erp-cta-subtitle {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-body);
  max-width: 36rem;
  margin: 0 auto 1.75rem;
}

.erp-cta-actions {
  display: flex;
  flex-direction: column;
  sm-flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

@media (min-width: 540px) {
  .erp-cta-actions {
    flex-direction: row;
  }
}

.btn-cta-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background-color: var(--brand-600);
  color: #ffffff !important;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow-sm);
  transition: background-color 0.15s ease, transform 0.1s ease;
  width: 100%;
}

@media (min-width: 540px) {
  .btn-cta-primary {
    width: auto;
  }
}

.btn-cta-primary:hover {
  background-color: var(--brand-700);
}

.btn-cta-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-heading);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  transition: all 0.15s ease;
  width: 100%;
}

@media (min-width: 540px) {
  .btn-cta-secondary {
    width: auto;
  }
}

.btn-cta-secondary:hover {
  background-color: var(--bg-subtle);
  border-color: var(--border-hover);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--border-color);
  background-color: var(--bg-subtle);
  padding: 4rem 0 2.5rem;
  margin-top: 5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 3.5rem;
}

@media (min-width: 640px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer-brand-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-heading);
  margin-bottom: 1rem;
}

.footer-brand-desc {
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--text-body);
  max-width: 22rem;
  margin-bottom: 1.25rem;
}

.footer-badge-compliance {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-col-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-heading);
  margin-bottom: 1.25rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-body);
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--text-heading);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

@media (min-width: 640px) {
  .footer-bottom {
    flex-direction: row;
  }
}

.footer-bottom-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.footer-bottom-links a:hover {
  color: var(--text-heading);
}
