/*
Theme Name: CitySaver Central
Theme URI: https://citysavercentral.org
Author: City Saver
Author URI: https://city-saver.org
Description: Library and vision hub for the CitySaver ecosystem — resources, writings, and vision for building stronger city communities.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: citysaver-central
Tags: blog, community, city, library, editorial
*/

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

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

:root {
  --navy-50: #f0f3f9;
  --navy-100: #dce3f0;
  --navy-200: #b8c8e2;
  --navy-400: #5e7fb5;
  --navy-600: #2d4578;
  --navy-700: #1e3460;
  --navy-800: #172a4d;
  --navy-900: #101d38;
  --navy-950: #0a1226;

  --gold-50: #fdf9ef;
  --gold-100: #fbf0d4;
  --gold-200: #f6dea4;
  --gold-300: #f0c76b;
  --gold-400: #e6a934;
  --gold-500: #d4982a;
  --gold-600: #b97a1e;

  --ink-50: #f7f8fa;
  --ink-100: #eef0f4;
  --ink-200: #dde1e9;
  --ink-300: #c0c7d4;
  --ink-400: #8d97a8;
  --ink-500: #5e687a;
  --ink-600: #404a5c;
  --ink-700: #2c3445;
  --ink-800: #1c2230;
  --ink-900: #0f1320;

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-pill: 999px;
  --shadow-card: 0 1px 3px rgba(10, 18, 38, 0.04), 0 4px 14px rgba(10, 18, 38, 0.06);
  --shadow-card-hover: 0 4px 10px rgba(10, 18, 38, 0.05), 0 14px 30px rgba(10, 18, 38, 0.09);
  --shadow-sm: 0 1px 2px rgba(10, 18, 38, 0.05);

  --motion-duration-fast: 160ms;
  --motion-duration-med: 280ms;
  --motion-easing-out: cubic-bezier(0.2, 0, 0, 1);
  --motion-easing-standard: cubic-bezier(0.4, 0, 0.2, 1);

  --max-width: 1200px;
}

:focus-visible {
  outline: 2px solid var(--gold-500);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--ink-800);
  background: var(--ink-50);
  line-height: 1.6;
}

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

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

h1, h2, h3, h4, h5, h6 {
  line-height: 1.25;
  font-weight: 700;
  color: var(--navy-900);
}

ul, ol {
  list-style: none;
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}

/* ========================================
   UTILITIES
   ======================================== */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 56px 0;
}

.section--alt {
  background: #f3f6f9;
}

.section--white {
  background: #fff;
}

.section__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 12px;
}

.section__title {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--navy-900);
}

.section__subtitle {
  font-size: 0.95rem;
  color: var(--ink-500);
  max-width: 46rem;
  margin-top: 6px;
}

.section__link {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy-600);
  transition: color 0.15s;
}

.section__link:hover {
  color: var(--gold-500);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 0.875rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  text-decoration: none;
  line-height: 1;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--gold {
  background: var(--gold-400);
  color: var(--navy-900);
}

.btn--gold:hover {
  background: var(--gold-500);
}

.btn--navy {
  background: var(--navy-800);
  color: #fff;
}

.btn--navy:hover {
  background: var(--navy-900);
}

.btn--outline {
  background: #fff;
  color: var(--navy-800);
  border: 1.5px solid var(--navy-200);
}

.btn--outline:hover {
  background: var(--navy-50);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.16);
}

.btn--sm {
  padding: 7px 14px;
  font-size: 0.8125rem;
}

/* ========================================
   BADGES
   ======================================== */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.6875rem;
  font-weight: 600;
}

.badge--category {
  background: var(--ink-50);
  color: var(--ink-600);
  border: 1px solid var(--ink-200);
}

.badge--category:hover {
  color: var(--navy-800);
  border-color: var(--ink-300);
}

.badge--gold {
  background: var(--gold-100);
  color: var(--gold-600);
}

/* ========================================
   HEADER / NAV
   ======================================== */

.site-header {
  background: #fff;
  border-bottom: 1px solid var(--ink-200);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 24px;
  position: relative;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.site-logo img {
  width: 38px;
  height: 38px;
  border-radius: 50%;
}

.site-logo__textwrap {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.site-logo__text {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--navy-900);
}

.site-logo__text span {
  color: var(--gold-500);
}

.site-logo__line2 {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--ink-500);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.main-nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.main-nav a {
  display: inline-block;
  padding: 6px 14px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-600);
  border-radius: var(--radius-md);
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}

.main-nav a:hover,
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a {
  background: var(--navy-50);
  color: var(--navy-900);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* Mobile hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle svg {
  width: 24px;
  height: 24px;
  color: var(--navy-800);
}

/* ========================================
   HERO (front page)
   ======================================== */

.hero {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #fff;
  padding: 72px 0;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -40px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: var(--gold-400);
  opacity: 0.06;
}

.hero .container {
  position: relative;
}

.hero__content {
  max-width: 640px;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 16px;
}

.hero__title {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 12px;
}

.hero__title em {
  font-style: normal;
  color: var(--gold-400);
}

.hero__subtitle {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--gold-300);
  margin-bottom: 16px;
}

.hero__desc {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--navy-200);
  margin-bottom: 28px;
  max-width: 560px;
}

.hero__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.hero__note {
  margin-top: 18px;
  font-size: 0.875rem;
}

.hero__note a {
  color: var(--navy-200);
  font-weight: 600;
  transition: color 0.15s;
}

.hero__note a:hover {
  color: var(--gold-300);
}

/* ========================================
   PAGE HEADER (pages, archives, search, 404)
   ======================================== */

.page-header {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #fff;
  padding: 44px 0;
  position: relative;
  overflow: hidden;
}

.page-header::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -40px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: var(--gold-400);
  opacity: 0.06;
}

.page-header .container {
  position: relative;
}

.page-header__eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 8px;
}

.page-header__title {
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
}

.page-header__desc {
  margin-top: 10px;
  font-size: 1rem;
  color: var(--navy-200);
  max-width: 46rem;
}

/* ========================================
   POST CARDS
   ======================================== */

.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.post-grid--two {
  grid-template-columns: repeat(2, 1fr);
}

.post-card {
  background: #fff;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.post-card:hover {
  box-shadow: var(--shadow-card-hover);
  border-color: var(--navy-200);
  transform: translateY(-1px);
}

.post-card__thumb-link {
  display: block;
}

.post-card__thumb {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: var(--ink-100);
}

.post-card__thumb--placeholder {
  height: 180px;
  background:
    linear-gradient(135deg, var(--navy-800) 0%, var(--navy-600) 60%, var(--gold-600) 160%);
  position: relative;
}

.post-card__thumb--placeholder::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--cs-central-watermark, none);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 72px 72px;
  opacity: 0.18;
}

.post-card__body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.post-card__category {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold-600);
  margin-bottom: 8px;
}

.post-card__category a {
  color: inherit;
}

.post-card__category a:hover {
  color: var(--gold-500);
}

.post-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 8px;
  line-height: 1.4;
}

.post-card__title a {
  color: inherit;
  transition: color 0.15s;
}

.post-card__title a:hover {
  color: var(--navy-600);
}

.post-card__excerpt {
  font-size: 0.875rem;
  color: var(--ink-500);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 14px;
}

.post-card__meta {
  margin-top: auto;
  font-size: 0.75rem;
  color: var(--ink-400);
}

/* Featured (large) variant */
.post-card--featured {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
}

.post-card--featured .post-card__thumb,
.post-card--featured .post-card__thumb--placeholder {
  height: 100%;
  min-height: 300px;
}

.post-card--featured .post-card__body {
  padding: 32px;
  justify-content: center;
}

.post-card--featured .post-card__title {
  font-size: 1.6rem;
  line-height: 1.25;
}

.post-card--featured .post-card__excerpt {
  font-size: 0.95rem;
  -webkit-line-clamp: 4;
}

.post-feature-wrap {
  margin-bottom: 24px;
}

/* ========================================
   VALUE CARDS ("What is CitySaver?")
   ======================================== */

.value-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.value-card {
  background: #fff;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
}

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

.value-card__icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--gold-100);
  color: var(--gold-600);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.value-card__icon svg {
  width: 22px;
  height: 22px;
}

.value-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.value-card__desc {
  font-size: 0.875rem;
  color: var(--ink-500);
  line-height: 1.65;
}

/* ========================================
   CATEGORY CARDS ("Explore the library")
   ======================================== */

.cat-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.cat-card {
  background: #fff;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.2s;
  display: block;
}

.cat-card:hover {
  box-shadow: var(--shadow-card);
  border-color: var(--navy-200);
  transform: translateY(-1px);
}

.cat-card__title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.cat-card__count {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--ink-500);
  background: var(--ink-50);
  border: 1px solid var(--ink-200);
  border-radius: 100px;
  padding: 1px 8px;
  flex-shrink: 0;
}

.cat-card__desc {
  font-size: 0.8125rem;
  color: var(--ink-500);
  line-height: 1.55;
}

/* ========================================
   PANELS (Liberty / final CTA)
   ======================================== */

.panel {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-700) 100%);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 44px 40px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

.panel::after {
  content: "";
  position: absolute;
  right: -50px;
  bottom: -70px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: var(--gold-400);
  opacity: 0.08;
}

.panel__content {
  max-width: 620px;
  position: relative;
}

.panel__eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 8px;
}

.panel__title {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 10px;
}

.panel__desc {
  font-size: 0.95rem;
  color: var(--navy-200);
  line-height: 1.7;
}

.panel__actions {
  position: relative;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* ========================================
   CITYSAVIOR BRIDGE
   ======================================== */

.bridge {
  background: linear-gradient(135deg, var(--navy-950) 0%, var(--navy-800) 100%);
  color: #fff;
  padding: 56px 0;
}

.bridge .container {
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}

.bridge__icon {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  flex-shrink: 0;
}

.bridge__content {
  flex: 1;
  min-width: 260px;
}

.bridge__subtitle {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 6px;
}

.bridge__title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 10px;
}

.bridge__desc {
  font-size: 0.95rem;
  color: var(--navy-200);
  line-height: 1.7;
  max-width: 620px;
}

.bridge__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* ========================================
   ENTRY CONTENT (pages + posts)
   ======================================== */

.entry {
  padding: 48px 0 64px;
}

.entry-content {
  max-width: 760px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--ink-700);
}

.entry-content > * + * {
  margin-top: 1.2em;
}

.entry-content h2 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-top: 2em;
  padding-top: 0.6em;
}

.entry-content h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-top: 1.6em;
}

.entry-content a {
  color: var(--navy-600);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--navy-200);
  text-underline-offset: 3px;
  transition: color 0.15s;
}

.entry-content a:hover {
  color: var(--gold-600);
}

.entry-content ul,
.entry-content ol {
  padding-left: 1.4em;
}

.entry-content ul {
  list-style: disc;
}

.entry-content ol {
  list-style: decimal;
}

.entry-content li + li {
  margin-top: 0.4em;
}

.entry-content blockquote,
.entry-content .wp-block-quote {
  border-left: 3px solid var(--gold-400);
  background: var(--gold-50);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 18px 24px;
  font-size: 1.05rem;
  color: var(--navy-800);
}

.entry-content blockquote cite {
  display: block;
  margin-top: 8px;
  font-size: 0.85rem;
  font-style: normal;
  color: var(--ink-500);
}

.entry-content img,
.entry-content .wp-block-image img {
  border-radius: var(--radius-lg);
}

.entry-content figcaption {
  font-size: 0.8125rem;
  color: var(--ink-400);
  text-align: center;
  margin-top: 8px;
}

.entry-content hr,
.entry-content .wp-block-separator {
  border: none;
  border-top: 1px solid var(--ink-200);
  margin: 2.4em auto;
  max-width: 200px;
}

.entry-content .wp-block-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.entry-content .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 0.875rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  border: none;
  background: var(--gold-400);
  color: var(--navy-900);
  text-decoration: none;
  line-height: 1;
  transition: background 0.15s, transform 0.1s;
}

.entry-content .wp-block-button__link:hover {
  background: var(--gold-500);
  transform: translateY(-1px);
  color: var(--navy-900);
}

.entry-content .is-style-outline .wp-block-button__link {
  background: #fff;
  color: var(--navy-800);
  border: 1.5px solid var(--navy-200);
}

.entry-content .is-style-outline .wp-block-button__link:hover {
  background: var(--navy-50);
}

.entry-content .wp-block-columns {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.entry-content .wp-block-column {
  flex: 1;
  min-width: 220px;
}

/* "Card" styled group blocks in seeded/authored content */
.entry-content .cs-card {
  background: #fff;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px;
}

.entry-content .cs-card > * + * {
  margin-top: 0.7em;
}

.entry-content .cs-card h3 {
  margin-top: 0;
  font-size: 1.05rem;
}

.entry-content .cs-card ul,
.entry-content .cs-card ol {
  font-size: 0.95rem;
}

/* ========================================
   SINGLE POST
   ======================================== */

.single-hero {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #fff;
  padding: 52px 0;
  position: relative;
  overflow: hidden;
}

.single-hero::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -40px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: var(--gold-400);
  opacity: 0.06;
}

.single-hero .container {
  position: relative;
  max-width: 860px;
}

.single-hero__category {
  margin-bottom: 14px;
}

.single-hero__category a {
  display: inline-flex;
  align-items: center;
  padding: 3px 12px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--gold-300);
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  transition: background 0.15s;
}

.single-hero__category a:hover {
  background: rgba(255, 255, 255, 0.18);
}

.single-hero__title {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  margin-bottom: 12px;
}

.single-hero__subtitle {
  font-size: 1.1rem;
  color: var(--navy-200);
  line-height: 1.6;
  max-width: 44rem;
  margin-bottom: 18px;
}

.single-hero__meta {
  font-size: 0.85rem;
  color: var(--navy-200);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.single-hero__meta a {
  color: inherit;
  font-weight: 600;
}

.single-hero__meta a:hover {
  color: var(--gold-300);
}

.single-figure {
  max-width: 860px;
  margin: -28px auto 0;
  padding: 0 24px;
  position: relative;
}

.single-figure--page {
  margin-top: 0;
  margin-bottom: 32px;
}

.single-figure img {
  width: 100%;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--ink-200);
}

.single-body {
  padding: 44px 0 24px;
}

/* Prev / next navigation */
.post-nav {
  max-width: 760px;
  margin: 40px auto 0;
}

.post-nav .nav-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.post-nav .nav-previous a,
.post-nav .nav-next a {
  display: block;
  background: #fff;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy-800);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, border-color 0.2s;
  height: 100%;
}

.post-nav .nav-previous a:hover,
.post-nav .nav-next a:hover {
  box-shadow: var(--shadow-card);
  border-color: var(--navy-200);
}

.post-nav .nav-next {
  text-align: right;
}

.post-nav .nav-subtitle {
  display: block;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold-600);
  margin-bottom: 4px;
}

/* Related posts + bottom CTA */
.related-posts {
  padding: 48px 0;
}

.single-cta {
  padding: 0 0 64px;
}

.single-cta__card {
  max-width: 760px;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-700) 100%);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.single-cta__title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.single-cta__desc {
  font-size: 0.875rem;
  color: var(--navy-200);
}

/* ========================================
   ARCHIVE / INDEX / SEARCH / 404
   ======================================== */

.archive-body {
  padding: 44px 0 64px;
}

.archive-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.archive-cats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.archive-cats a {
  display: inline-flex;
  align-items: center;
  padding: 5px 14px;
  border-radius: 100px;
  background: #fff;
  border: 1px solid var(--ink-200);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-600);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.archive-cats a:hover,
.archive-cats a.is-active {
  background: var(--navy-800);
  border-color: var(--navy-800);
  color: #fff;
}

.search-form {
  display: flex;
  gap: 8px;
  max-width: 420px;
  flex: 1;
}

.search-form input[type="search"] {
  flex: 1;
  min-width: 0;
  padding: 9px 14px;
  font-size: 0.875rem;
  font-family: inherit;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-md);
  background: #fff;
  color: var(--ink-800);
}

.search-form input[type="search"]:focus {
  outline: 2px solid var(--gold-500);
  outline-offset: 1px;
  border-color: transparent;
}

.empty-state {
  background: #fff;
  border: 1px dashed var(--ink-300);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
  color: var(--ink-500);
}

.empty-state__title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 8px;
}

.empty-state .search-form {
  margin: 20px auto 0;
}

/* Pagination */
.pagination {
  margin-top: 36px;
}

.pagination .nav-links {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}

.pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid var(--ink-200);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink-600);
  transition: background 0.15s, color 0.15s;
}

.pagination .page-numbers:hover {
  background: var(--navy-50);
  color: var(--navy-900);
}

.pagination .page-numbers.current {
  background: var(--navy-800);
  border-color: var(--navy-800);
  color: #fff;
}

.pagination .page-numbers.dots {
  border: none;
  background: none;
}

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

.cs-footer {
  background: var(--navy-900);
  color: rgba(255, 255, 255, 0.85);
  padding: clamp(2.5rem, 5vw, 4rem) 0 1.5rem;
  margin-top: 0;
}

.cs-footer .container {
  max-width: var(--max-width);
}

.cs-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.cs-footer__brand-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: #fff;
  font-weight: 700;
  margin-bottom: 0.85rem;
}

.cs-footer__brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.cs-footer__brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  border-radius: 50%;
}

.cs-footer__brand-name {
  font-size: 1.05rem;
}

.cs-footer__tagline {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
  max-width: 32ch;
  line-height: 1.55;
  margin: 0 0 0.85rem;
}

.cs-footer__co {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
}

.cs-footer__co-link {
  color: var(--gold-400);
  font-weight: 600;
  text-decoration: none;
}

.cs-footer__co-link:hover {
  color: var(--gold-300);
  text-decoration: underline;
}

.cs-footer__col-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.85rem;
}

.cs-footer__col-title--spaced {
  margin-top: 1.4rem;
}

.cs-footer__links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.cs-footer__links a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-size: 0.92rem;
  transition: color var(--motion-duration-fast) var(--motion-easing-standard);
}

.cs-footer__links a:hover {
  color: var(--gold-400);
}

.cs-footer__bottom {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  align-items: flex-start;
  justify-content: space-between;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cs-footer__copy {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
  margin: 0;
}

.cs-footer__contact {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
}

.cs-footer__contact a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
}

.cs-footer__contact a:hover {
  color: var(--gold-400);
  text-decoration: underline;
}

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

@media (min-width: 640px) {
  .cs-footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .cs-footer__bottom {
    flex-direction: row;
    align-items: center;
  }
}

@media (min-width: 960px) {
  .cs-footer__grid {
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
  }
}

@media (max-width: 1024px) {
  .post-grid,
  .value-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .cat-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 1100px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--ink-200);
    padding: 16px 24px;
    box-shadow: var(--shadow-card);
  }

  .main-nav.open {
    display: block;
  }

  .main-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .main-nav a {
    display: block;
    padding: 10px 0;
    border-radius: 0;
  }

  .main-nav a:hover,
  .main-nav .current-menu-item > a,
  .main-nav .current_page_item > a {
    background: none;
  }

  .nav-toggle {
    display: block;
  }
}

@media (max-width: 768px) {
  .header-actions .btn {
    padding: 8px 12px;
    font-size: 0.75rem;
  }

  .site-logo__line2 {
    display: none;
  }

  .post-grid,
  .post-grid--two,
  .value-cards {
    grid-template-columns: 1fr;
  }

  .post-card--featured {
    grid-template-columns: 1fr;
  }

  .post-card--featured .post-card__thumb,
  .post-card--featured .post-card__thumb--placeholder {
    min-height: 200px;
    height: 200px;
  }

  .post-card--featured .post-card__body {
    padding: 24px 20px;
  }

  .hero__title {
    font-size: 2rem;
  }

  .single-hero__title {
    font-size: 1.7rem;
  }

  .panel {
    padding: 32px 24px;
  }

  .post-nav .nav-links {
    grid-template-columns: 1fr;
  }

  .post-nav .nav-next {
    text-align: left;
  }

  .single-cta__card {
    padding: 24px;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 40px 0;
  }

  .hero {
    padding: 48px 0;
  }

  .hero__desc {
    font-size: 0.95rem;
  }

  .cat-cards {
    grid-template-columns: 1fr;
  }

  .archive-tools {
    flex-direction: column;
    align-items: stretch;
  }

  .search-form {
    max-width: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }

  .btn:hover,
  .post-card:hover,
  .value-card:hover,
  .cat-card:hover {
    transform: none;
  }
}
