/* ============================================================
   ENTRE CLINICA PSICANALITICA - Blog Public Styles
   Design: Editorial Magazine - Psyche.co Inspired
   Paleta: Fundo claro, verde profundo, dourado suave
   Fontes: Playfair Display (display), Inter (corpo)
   ============================================================ */

/* === CSS Custom Properties === */
:root {
  /* Cores de superficie */
  --bg-primary: #F5F2ED;
  --bg-secondary: #ECE6DD;
  --bg-card: #FFFCF7;
  --bg-hover: #F1EBE1;
  --bg-dark: #2F3E3A;

  /* Cores de texto */
  --text-primary: #1A1A1A;
  --text-secondary: #4A4A4A;
  --text-muted: #8A8A8A;
  --text-light: #B0B0B0;
  --text-inverse: #FAFAF7;

  /* Marca */
  --brand: #2F3E3A;
  --brand-light: #5A6B63;
  --brand-soft: #3F5F57;
  --accent: #C4A882;
  --accent-light: #DCC6A5;
  --accent-hover: #B8996F;

  /* Bordas */
  --border: #E5E2DC;
  --border-light: #EEECE7;
  --border-dark: #D0CCC4;

  /* Sombras */
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.10);

  /* Layout */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --transition: 0.25s ease;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --header-h: 64px;
  --max-w: 1200px;
  --max-w-narrow: 720px;
}


/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
}

body.blog-public {
  font-family: var(--font-sans);
  font-weight: 400;
  color: var(--text-primary);
  background:
    radial-gradient(circle at top left, rgba(196, 168, 130, 0.18), transparent 28%),
    radial-gradient(circle at top right, rgba(90, 107, 99, 0.12), transparent 24%),
    linear-gradient(180deg, #f8f4ee 0%, var(--bg-primary) 28%, #f1ebe2 100%);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

a {
  color: var(--brand);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--accent-hover); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}


/* === Acessibilidade === */
.skip-link {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden; white-space: nowrap; z-index: 100;
}
.skip-link:focus {
  left: 1rem; top: 1rem; width: auto; height: auto; overflow: visible; white-space: normal;
  background: var(--bg-dark); color: var(--text-inverse); border: 1px solid var(--border);
  padding: 0.75rem 1rem; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em;
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}


/* ============================================================
   HEADER
   ============================================================ */
.blog-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(245, 242, 237, 0.88);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid rgba(63, 95, 87, 0.08);
  transition: all var(--transition);
}
.blog-header.scrolled {
  background: rgba(245, 242, 237, 0.95);
  box-shadow: 0 10px 28px rgba(47, 62, 58, 0.08);
}

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}

.header-logo img {
  height: 36px; width: auto;
}

.header-nav {
  display: flex; gap: 2.25rem; align-items: center;
}

.nav-link {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-secondary);
  position: relative;
  padding-bottom: 2px;
  font-weight: 500;
  transition: color var(--transition);
}
.nav-link::after {
  content: '';
  position: absolute; bottom: -4px; left: 0; right: 0;
  height: 1.5px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition);
}
.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
}
.nav-link:hover::after, .nav-link.active::after {
  transform: scaleX(1);
}

/* Header actions */
.header-actions { display: flex; align-items: center; gap: 0.5rem; }

.search-toggle, .mobile-menu-toggle {
  background: none; border: none; cursor: pointer;
  color: var(--text-secondary); padding: 8px;
  transition: color var(--transition);
  display: flex; align-items: center;
}
.search-toggle:hover, .mobile-menu-toggle:hover { color: var(--text-primary); }

/* Mobile menu toggle */
.mobile-menu-toggle {
  display: none; flex-direction: column; gap: 5px; padding: 10px;
}
.mobile-menu-toggle span {
  display: block; width: 20px; height: 1.5px;
  background: var(--text-primary);
  transition: all 0.3s;
}
.mobile-menu-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-menu-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-menu-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Search overlay */
.search-overlay {
  position: absolute; top: 100%; left: 0; right: 0;
  background: rgba(255, 252, 247, 0.96);
  padding: 1.5rem 2rem;
  transform: translateY(-8px); opacity: 0; pointer-events: none;
  transition: all 0.2s;
  border-bottom: 1px solid rgba(63, 95, 87, 0.1);
  box-shadow: var(--shadow-md);
}
.search-overlay.active {
  transform: translateY(0); opacity: 1; pointer-events: all;
}
.search-overlay-form {
  max-width: 560px; margin: 0 auto; display: flex; gap: 0.75rem; align-items: center;
}
.search-overlay-input {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.875rem 1.25rem;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  outline: none;
  transition: border-color var(--transition);
}
.search-overlay-input:focus { border-color: var(--brand); }
.search-overlay-input::placeholder { color: var(--text-light); }
.search-overlay-submit {
  background: var(--brand); border: none; border-radius: var(--radius-md);
  padding: 0.8rem; cursor: pointer; color: var(--text-inverse);
  transition: background var(--transition);
  display: flex; align-items: center;
}
.search-overlay-submit:hover { background: var(--brand-light); }
.search-overlay-close {
  background: none; border: none; color: var(--text-muted); font-size: 1.5rem;
  cursor: pointer; padding: 0.5rem; line-height: 1;
}

/* Mobile menu */
.mobile-menu {
  display: none; position: absolute; top: 100%; left: 0; right: 0;
  background: rgba(255, 252, 247, 0.98);
  border-top: 1px solid rgba(63, 95, 87, 0.08);
  padding: 1rem 2rem 1.5rem;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
}
.mobile-menu.active { display: flex; }
.mobile-menu-link {
  display: block; padding: 0.75rem 0; color: var(--text-secondary);
  font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.12em;
  border-bottom: 1px solid var(--border-light);
  font-weight: 500;
  transition: color var(--transition);
}
.mobile-menu-link:hover { color: var(--text-primary); }
.mobile-search-form { margin-top: 1rem; }
.mobile-search-input {
  width: 100%; background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 0.75rem 1rem;
  color: var(--text-primary); font-size: 0.9rem; outline: none;
}
.mobile-search-input:focus { border-color: var(--brand); }
.mobile-search-input::placeholder { color: var(--text-light); }


/* ============================================================
   HERO / BANNER
   ============================================================ */
.blog-hero {
  padding: calc(var(--header-h) + 3.5rem) 2rem 3.5rem;
  text-align: center;
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.82), rgba(245, 242, 237, 0.96)),
    radial-gradient(circle at top center, rgba(196, 168, 130, 0.16), transparent 55%);
  border-bottom: 1px solid rgba(63, 95, 87, 0.08);
  position: relative;
  overflow: hidden;
}
.blog-hero::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(47, 62, 58, 0.18), transparent);
}

.hero-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--accent-hover);
  margin-bottom: 1.25rem;
  font-weight: 500;
  display: flex; align-items: center; justify-content: center; gap: 1rem;
}
.hero-label::before, .hero-label::after {
  content: ''; width: 32px; height: 1px; background: var(--accent); opacity: 0.6;
}

.hero-title {
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.gradient-text {
  background: linear-gradient(135deg, var(--brand-soft), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
}

.hero-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  font-weight: 300;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.8;
}


/* ============================================================
   CATEGORIES BAR
   ============================================================ */
.categories-bar {
  background: linear-gradient(180deg, rgba(255, 252, 247, 0.64), rgba(245, 242, 237, 0.92));
  border-bottom: 1px solid rgba(63, 95, 87, 0.08);
  padding: 1rem 0;
}
.categories-scroll {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.cat-pill {
  padding: 0.4rem 1.1rem;
  border-radius: 100px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  background: rgba(255, 252, 247, 0.72);
  cursor: pointer;
  font-weight: 500;
  transition: all var(--transition);
}
.cat-pill:hover, .cat-pill.active {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--text-inverse);
  box-shadow: 0 10px 24px rgba(47, 62, 58, 0.14);
}


/* ============================================================
   FEATURED POST (HERO article - Psyche style)
   ============================================================ */
.featured-section {
  padding: 1.5rem 0 2rem;
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.52), rgba(236, 230, 221, 0.64)),
    radial-gradient(circle at left center, rgba(196, 168, 130, 0.1), transparent 30%);
  border-bottom: 1px solid var(--border);
}
.featured-post {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  min-height: 420px;
  background: rgba(255, 252, 247, 0.78);
  border: 1px solid rgba(63, 95, 87, 0.1);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(47, 62, 58, 0.08);
}
.featured-image {
  position: relative;
  overflow: hidden;
  background: var(--bg-secondary);
}
.featured-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.featured-post:hover .featured-image img {
  transform: scale(1.03);
}
.featured-placeholder {
  width: 100%; height: 100%;
  background: var(--bg-secondary);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-light);
}
.featured-content {
  padding: 3rem 3rem 3rem 3.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.58), rgba(245, 242, 237, 0.94)),
    radial-gradient(circle at top right, rgba(196, 168, 130, 0.1), transparent 34%);
}
.featured-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.post-category {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent-hover);
  font-weight: 600;
  transition: color var(--transition);
}
.post-category:hover { color: var(--brand); }

.post-reading {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.featured-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.25;
  margin-bottom: 1rem;
}
.featured-title a {
  color: var(--text-primary);
  transition: color var(--transition);
}
.featured-title a:hover { color: var(--brand-light); }

.featured-excerpt {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}
.featured-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.featured-link {
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brand);
  transition: color var(--transition);
}
.featured-link:hover { color: var(--accent-hover); }

/* Author mini */
.post-author-mini {
  display: inline-flex;
  align-items: center;
  gap: 0.62rem;
  min-width: 0;
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.author-avatar-sm {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(47, 62, 58, 0.96), rgba(90, 107, 99, 0.88));
  color: var(--text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  flex-shrink: 0;
  overflow: hidden;
  border: 1.5px solid rgba(255, 252, 247, 0.94);
  box-shadow: 0 6px 14px rgba(47, 62, 58, 0.12);
}
.author-avatar-sm img,
.author-avatar-lg img,
.post-author-chip-avatar img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  border-radius: inherit !important;
  display: block;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: auto;
}
.post-date {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.post-author-name {
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-weight: 500;
}
.author-name {
  font-weight: 600;
  color: var(--text-primary);
  display: block;
  font-size: 0.84rem;
}
.author-date {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.08rem;
}


/* ============================================================
   SECTION TITLES
   ============================================================ */
.section-title {
  font-size: 1.1rem;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--text-primary);
  display: inline-block;
  box-shadow: 0 10px 0 -9px rgba(196, 168, 130, 0.9);
}

.posts-section {
  padding: 4rem 0;
  background:
    linear-gradient(180deg, rgba(245, 242, 237, 0.55), rgba(255, 252, 247, 0.42) 18%, rgba(245, 242, 237, 0.86) 100%);
}


/* ============================================================
   POST CARDS / GRID (Psyche.co style)
   ============================================================ */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem 2rem;
  margin-bottom: 3rem;
}

.post-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 252, 247, 0.74);
  border: 1px solid rgba(63, 95, 87, 0.08);
  border-radius: 24px;
  padding: 0.9rem;
  box-shadow: 0 14px 30px rgba(47, 62, 58, 0.05);
  transition: all var(--transition);
}
.post-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(47, 62, 58, 0.08);
  border-color: rgba(63, 95, 87, 0.14);
}

.post-card-image {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  margin-bottom: 0.95rem;
  display: block;
  border-radius: 16px;
}
.post-card-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.post-card:hover .post-card-image img {
  transform: scale(1.04);
}
.post-card-placeholder {
  width: 100%; height: 100%;
  background: var(--bg-secondary);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-light);
}

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

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.post-card-title {
  font-size: 1.15rem;
  line-height: 1.35;
  margin-bottom: 0.6rem;
  font-family: var(--font-display);
  font-weight: 400;
}
.post-card-title a {
  color: var(--text-primary);
  transition: color var(--transition);
}
.post-card-title a:hover { color: var(--brand-light); }

.post-card-excerpt {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 1rem;
}

.post-card-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.65rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--border-light);
  font-size: 0.75rem;
}
.post-author-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.58rem;
  min-width: 0;
  flex: 1 1 auto;
}
.post-author-chip-avatar {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  overflow: hidden;
  flex: 0 0 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(47, 62, 58, 0.96), rgba(90, 107, 99, 0.88));
  color: var(--text-inverse);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  border: 1.5px solid rgba(255, 252, 247, 0.94);
  box-shadow: 0 5px 12px rgba(47, 62, 58, 0.11);
}
.post-author-chip-name {
  font-size: 0.84rem;
  color: var(--text-primary);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Small card variant (for related posts) */
.post-card-sm .post-card-image {
  aspect-ratio: 16/10;
  margin-bottom: 0.75rem;
}
.post-card-sm .post-card-title {
  font-size: 1rem;
}


/* ============================================================
   CATEGORY PAGE
   ============================================================ */
.category-hero {
  padding: 2.5rem 0 2rem;
  text-align: center;
  border-bottom: 1px solid rgba(63, 95, 87, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.78), rgba(245, 242, 237, 0.95)),
    radial-gradient(circle at top center, rgba(196, 168, 130, 0.12), transparent 48%);
}
.category-count {
  margin-top: 0.75rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}


/* ============================================================
   SEARCH PAGE
   ============================================================ */
.search-form-main {
  display: flex;
  gap: 0.75rem;
  max-width: 520px;
  margin: 1.25rem auto 0;
}
.search-input-main {
  flex: 1;
  padding: 0.75rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-family: var(--font-sans);
  background: var(--bg-card);
  color: var(--text-primary);
  outline: none;
  transition: border-color var(--transition);
}
.search-input-main:focus { border-color: var(--brand); }
.search-input-main::placeholder { color: var(--text-light); }
.search-btn-main {
  padding: 0.75rem 1.5rem;
  background: var(--brand);
  color: var(--text-inverse);
  border: none;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition);
}
.search-btn-main:hover { background: var(--brand-light); }


/* ============================================================
   SINGLE POST (Article page - Psyche editorial style)
   ============================================================ */
.single-post {
  padding: 2rem 0 4rem;
}
.single-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 4rem;
  align-items: start;
}
.single-main {
  max-width: var(--max-w-narrow);
}

/* Single header */
.single-header { margin-bottom: 2rem; }
.single-meta {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1rem;
}
.single-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--text-primary);
}
.single-excerpt {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 1.5rem;
  font-family: var(--font-display);
  font-style: italic;
}
.single-author-date {
  padding-bottom: 1.2rem;
  border-bottom: 1px solid var(--border);
}

/* Featured image */
.single-featured-image {
  margin-bottom: 2.5rem;
  overflow: hidden;
}
.single-featured-image img {
  width: 100%; height: auto;
  aspect-ratio: 21/9;
  object-fit: cover;
}

/* Post content */
.post-content {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-primary);
}
.post-content h2 {
  font-size: 1.5rem;
  margin: 2.5rem 0 1rem;
  color: var(--text-primary);
}
.post-content h3 {
  font-size: 1.25rem;
  margin: 2rem 0 0.75rem;
  color: var(--text-primary);
}
.post-content p {
  margin-bottom: 1.5rem;
}
.post-content a {
  color: var(--brand);
  border-bottom: 1px solid var(--border);
  transition: border-color var(--transition);
}
.post-content a:hover { border-color: var(--brand); }
.post-content blockquote {
  margin: 2rem 0;
  padding: 1.5rem 2rem;
  border-left: 3px solid var(--accent);
  background: var(--bg-secondary);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--text-primary);
  line-height: 1.7;
}
.post-content ul, .post-content ol {
  margin: 1rem 0 1.5rem 1.5rem;
}
.post-content li {
  margin-bottom: 0.5rem;
}
.post-content li::marker {
  color: var(--accent);
}
.post-content strong {
  font-weight: 600;
  color: var(--text-primary);
}
.post-content em {
  font-style: italic;
}
.post-content img {
  margin: 2rem 0;
}

/* Tags */
.post-tags {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin: 2rem 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}
.tag-link {
  padding: 0.35rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.72rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
  transition: all var(--transition);
}
.tag-link:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--text-inverse);
}

/* Share section */
.share-section {
  margin: 2.5rem 0;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.share-title {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-weight: 600;
}

/* Share buttons */
.share-buttons {
  display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center;
}
.share-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}
.share-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}
.share-whatsapp:hover { background: #25D366; color: #fff; border-color: #25D366; }
.share-facebook:hover { background: #1877F2; color: #fff; border-color: #1877F2; }
.share-linkedin:hover { background: #0A66C2; color: #fff; border-color: #0A66C2; }
.share-twitter:hover { background: #000; color: #fff; border-color: #000; }
.share-telegram:hover { background: #0088cc; color: #fff; border-color: #0088cc; }
.share-copy:hover { background: var(--brand); color: var(--text-inverse); border-color: var(--brand); }

/* Author box */
.author-box {
  display: flex; gap: 1.2rem; align-items: center;
  background: linear-gradient(180deg, rgba(255, 252, 247, 0.86), rgba(236, 230, 221, 0.8));
  border: 1px solid rgba(63, 95, 87, 0.1);
  padding: 1.6rem;
  margin: 2.5rem 0;
  border-radius: 20px;
  box-shadow: 0 12px 28px rgba(47, 62, 58, 0.05);
}
.author-avatar-lg {
  width: 62px;
  height: 62px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(47, 62, 58, 0.96), rgba(90, 107, 99, 0.88));
  color: var(--text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  font-weight: 700;
  flex-shrink: 0;
  overflow: hidden;
  border: 2px solid rgba(255, 252, 247, 0.92);
  box-shadow: 0 10px 22px rgba(47, 62, 58, 0.12);
}
.author-info { flex: 1; }
.author-box-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}
.author-box-bio {
  font-size: 0.88rem; color: var(--text-secondary); line-height: 1.7;
}

/* Related section */
.related-section {
  margin-top: 3rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
}
.related-title {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 600;
  margin-bottom: 2rem;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}


/* ============================================================
   SIDEBAR
   ============================================================ */
.single-sidebar {
  position: sticky;
  top: calc(var(--header-h) + 2rem);
}
.sidebar-widget {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-light);
}
.sidebar-widget:last-child { border-bottom: none; }

.widget-title {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 600;
  margin-bottom: 1.25rem;
  color: var(--text-primary);
}

/* Sidebar search */
.sidebar-search-form {
  display: flex; gap: 0.5rem;
}
.sidebar-search-input {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.6rem 0.875rem;
  color: var(--text-primary);
  font-size: 0.85rem;
  outline: none;
  font-family: var(--font-sans);
}
.sidebar-search-input:focus { border-color: var(--brand); }
.sidebar-search-input::placeholder { color: var(--text-light); }
.sidebar-search-btn {
  background: var(--brand); border: none; border-radius: var(--radius-md);
  padding: 0.6rem 0.7rem; cursor: pointer; color: var(--text-inverse);
  display: flex; align-items: center;
  transition: background var(--transition);
}
.sidebar-search-btn:hover { background: var(--brand-light); }

/* Sidebar posts list */
.sidebar-posts { display: flex; flex-direction: column; }
.sidebar-post-item {
  display: flex; gap: 0.75rem; align-items: flex-start;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--transition);
}
.sidebar-post-item:last-child { border-bottom: none; }
.sidebar-post-item:hover { color: var(--brand-light); }

.sidebar-post-num {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--border-dark);
  font-weight: 400;
  line-height: 1;
  flex-shrink: 0;
  min-width: 28px;
}
.sidebar-post-title {
  font-size: 0.82rem;
  line-height: 1.45;
  display: block;
  font-weight: 500;
}
.sidebar-post-date {
  font-size: 0.68rem;
  color: var(--text-muted);
  display: block;
  margin-top: 0.2rem;
}

/* Sidebar categories */
.sidebar-categories { display: flex; flex-direction: column; }
.sidebar-cat-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-secondary);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color var(--transition);
}
.sidebar-cat-item:last-child { border-bottom: none; }
.sidebar-cat-item:hover { color: var(--text-primary); }
.sidebar-cat-count {
  font-size: 0.7rem;
  color: var(--text-muted);
  background: var(--bg-secondary);
  padding: 0.15rem 0.5rem;
  border-radius: 100px;
}

/* Sidebar CTA */
.sidebar-cta {
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-soft) 100%);
  color: var(--text-inverse);
  padding: 2rem;
  text-align: center;
  border-radius: 24px;
  box-shadow: 0 20px 44px rgba(47, 62, 58, 0.18);
}
.sidebar-cta h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--text-inverse);
}
.sidebar-cta p {
  font-size: 0.85rem;
  opacity: 0.85;
  margin-bottom: 1.25rem;
  line-height: 1.6;
}
.sidebar-cta-btn {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  background: var(--accent);
  color: var(--bg-dark);
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: background var(--transition);
}
.sidebar-cta-btn:hover { background: var(--accent-light); color: var(--bg-dark); }


/* ============================================================
   CTA SECTION (Newsletter / WhatsApp)
   ============================================================ */
.cta-section {
  padding: 4.5rem 0;
  background:
    linear-gradient(180deg, rgba(196, 168, 130, 0.08), rgba(47, 62, 58, 0.06)),
    linear-gradient(180deg, rgba(245, 242, 237, 0.9), rgba(236, 230, 221, 0.92));
  border-top: 1px solid rgba(63, 95, 87, 0.08);
}
.cta-card {
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
  padding: 3rem 2.5rem;
  border-radius: 32px;
  background:
    radial-gradient(circle at top right, rgba(220, 198, 165, 0.18), transparent 32%),
    linear-gradient(135deg, rgba(47, 62, 58, 0.98), rgba(63, 95, 87, 0.92) 58%, rgba(90, 107, 99, 0.88) 100%);
  color: var(--text-inverse);
  box-shadow: 0 28px 60px rgba(47, 62, 58, 0.18);
  position: relative;
  overflow: hidden;
}
.cta-card::before {
  content: '';
  position: absolute;
  width: 220px;
  height: 220px;
  top: -110px;
  right: -80px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(220, 198, 165, 0.18), rgba(220, 198, 165, 0));
  pointer-events: none;
}
.cta-title {
  font-size: 1.6rem;
  margin-bottom: 0.75rem;
  color: var(--text-inverse);
}
.cta-text {
  color: rgba(245, 242, 237, 0.82);
  margin: 0 auto 1.5rem;
  max-width: 48ch;
  line-height: 1.7;
}
.cta-btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: rgba(255, 252, 247, 0.96);
  color: var(--bg-dark);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}
.cta-btn:hover {
  background: var(--accent);
  color: var(--bg-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}


/* ============================================================
   BREADCRUMBS
   ============================================================ */
.breadcrumbs {
  padding: 0;
  margin: 0;
}
.breadcrumbs ol {
  display: flex;
  gap: 0.5rem;
  list-style: none;
  font-size: 0.72rem;
  color: var(--text-muted);
}
.breadcrumb-item a { color: var(--text-muted); }
.breadcrumb-item a:hover { color: var(--brand); }
.breadcrumb-item + .breadcrumb-item::before {
  content: '/';
  margin-right: 0.5rem;
  color: var(--text-light);
}
.breadcrumb-item.active { color: var(--text-secondary); }


/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  padding: 2rem 0 3rem;
  flex-wrap: wrap;
}
.pagination-link {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 38px; height: 38px;
  padding: 0 0.7rem;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 0.8rem;
  text-decoration: none;
  transition: all var(--transition);
}
.pagination-link:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--text-inverse);
}
.pagination-link.active {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--text-inverse);
  font-weight: 600;
}
.pagination-link.prev, .pagination-link.next {
  font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em;
  font-weight: 500;
}
.pagination-dots {
  display: inline-flex; align-items: center; color: var(--text-light); padding: 0 0.25rem;
}


/* ============================================================
   EMPTY / 404
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-muted);
}
.empty-state svg { margin-bottom: 1.5rem; color: var(--text-light); }
.empty-state h3 {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}
.empty-state p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.error-page {
  padding: calc(var(--header-h) + 4rem) 2rem 5rem;
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.error-content {
  text-align: center;
  margin-bottom: 3rem;
}
.error-code {
  font-size: 6rem;
  font-family: var(--font-display);
  color: var(--border);
  line-height: 1;
  margin-bottom: 1rem;
  display: block;
}
.error-title {
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
}
.error-text {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  max-width: 460px;
}
.error-actions {
  display: flex; align-items: center; gap: 1.5rem; justify-content: center;
}
.error-link {
  font-size: 0.82rem;
  color: var(--text-muted);
}
.error-link:hover { color: var(--brand); }

.error-suggestions {
  max-width: 900px;
  margin: 0 auto;
}


/* ============================================================
   FOOTER (Psyche style - clean, minimal)
   ============================================================ */
.blog-footer {
  background: linear-gradient(180deg, #31423d 0%, #2f3e3a 100%);
  color: rgba(250,250,247,0.7);
  padding: 3.5rem 2rem 2rem;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2.5rem;
}
.footer-brand img {
  height: 32px; margin-bottom: 1rem;
  filter: brightness(2) saturate(0.5);
}
.footer-tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.92rem;
  color: rgba(250,250,247,0.5);
}
.footer-links h4 {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(250,250,247,0.4);
  margin-bottom: 1.25rem;
  font-weight: 600;
}
.footer-links a {
  display: block;
  color: rgba(250,250,247,0.65);
  font-size: 0.82rem;
  padding: 0.3rem 0;
  transition: color var(--transition);
}
.footer-links a:hover { color: rgba(250,250,247,1); }

.footer-bottom {
  max-width: var(--max-w);
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid rgba(250,250,247,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  color: rgba(250,250,247,0.35);
}
.footer-credit strong {
  color: var(--accent);
  font-weight: 500;
}


/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

[data-animate] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
[data-animate].animated {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger */
.posts-grid [data-animate]:nth-child(1) { transition-delay: 0s; }
.posts-grid [data-animate]:nth-child(2) { transition-delay: 0.08s; }
.posts-grid [data-animate]:nth-child(3) { transition-delay: 0.16s; }
.posts-grid [data-animate]:nth-child(4) { transition-delay: 0.24s; }
.posts-grid [data-animate]:nth-child(5) { transition-delay: 0.32s; }
.posts-grid [data-animate]:nth-child(6) { transition-delay: 0.40s; }
.posts-grid [data-animate]:nth-child(7) { transition-delay: 0.48s; }
.posts-grid [data-animate]:nth-child(8) { transition-delay: 0.56s; }
.posts-grid [data-animate]:nth-child(9) { transition-delay: 0.64s; }


/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .single-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .single-sidebar { position: static; }
  .single-main { max-width: 100%; }
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
  .featured-post { grid-template-columns: 1fr; }
  .featured-image { min-height: 300px; }
  .featured-content { padding: 2rem; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .cta-card { padding: 2.5rem 2rem; }
}

@media (max-width: 768px) {
  :root { --header-h: 56px; }

  .header-nav { display: none; }
  .mobile-menu-toggle { display: flex; }

  .blog-hero {
    padding: calc(var(--header-h) + 2.5rem) 1.5rem 2.5rem;
  }
  .hero-title { font-size: clamp(1.6rem, 6vw, 2.2rem); }

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

  .single-title { font-size: clamp(1.5rem, 5vw, 2rem); }
  .single-featured-image img { aspect-ratio: 16/9; }

  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  .footer-bottom { flex-direction: column; gap: 0.5rem; text-align: center; }

  .container { padding: 0 1.25rem; }

  .author-box { flex-direction: column; text-align: center; align-items: center; }
  .featured-footer,
  .post-card-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .post-card { padding: 0.85rem; border-radius: 20px; }
  .post-card-image { border-radius: 16px; }

  .categories-scroll { justify-content: flex-start; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 0.5rem; }

  .search-form-main { flex-direction: column; }
}

@media (max-width: 480px) {
  .header-inner { padding: 0 1rem; }
  .header-logo img { height: 28px; }
  .post-card-title { font-size: 1.05rem; }
  .featured-title { font-size: 1.4rem; }
  .featured-content { padding: 1.5rem; }
  .cta-card { padding: 2rem 1.25rem; border-radius: 24px; }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
