/**
 * Word Count Official - Warm Cream Paper & Hand-Crafted Editorial Public Stylesheet
 */

:root {
  --theme-primary: #2563eb;
  --theme-primary-hover: #1d4ed8;
  --theme-primary-subtle: rgba(37, 99, 235, 0.08);

  --bg-page: #f7f3ea;
  --bg-surface: #fffdf9;
  --bg-subtle: #f2ece0;
  --bg-elevated: #ffffff;

  --text-main: #292524;
  --text-secondary: #44403c;
  --text-muted: #57534e;
  --text-faint: #78716c;

  --marker-amber: rgba(245, 158, 11, 0.28);

  --border-color: rgba(41, 37, 36, 0.2);
  --border-subtle: rgba(41, 37, 36, 0.12);
  --border-dashed: rgba(41, 37, 36, 0.24);
  --border-focus: #2563eb;

  --shadow-paper-sm: 2px 2px 0 rgba(41, 37, 36, 0.06);
  --shadow-paper: 0 2px 6px rgba(41, 37, 36, 0.06), 3px 4px 0 rgba(41, 37, 36, 0.06);
  --shadow-paper-hover: 0 4px 10px rgba(41, 37, 36, 0.08), 4px 5px 0 rgba(41, 37, 36, 0.09);

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Fraunces", "Playfair Display", "Charter", Georgia, serif;
  --font-serif: "Fraunces", "Charter", Georgia, Cambria, "Times New Roman", Times, serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --radius-square: 2px;

  --container-max: 1180px;
  --reading-max: 760px;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
  overflow-x: clip;
  background-color: var(--bg-page);
}

body {
  background-color: var(--bg-page);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: clip;
  position: relative;
}

/* Subtle organic paper-grain texture over warm cream paper (GPU-friendly stipple) */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(41, 37, 36, 0.032) 1px, transparent 0);
  background-size: 6px 6px;
}

/* Font family modifier classes applied to <body> */
body.font-serif { font-family: var(--font-serif); }
body.font-mono { font-family: var(--font-mono); }
body.font-sans { font-family: var(--font-sans); }

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

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

/* Admin Quick Access Bar */
.admin-bar {
  background: var(--bg-subtle);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 0.42rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dashed var(--border-dashed);
  position: relative;
  z-index: 60;
}
.admin-bar a {
  color: var(--theme-primary);
  font-weight: 600;
}
.admin-bar a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Header (Sticky Warm Paper Masthead + Hand-Drawn Wavy Rule) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  background-color: var(--bg-page);
}

.header-container {
  max-width: var(--container-max);
  width: 100%;
  margin: 0 auto;
  padding: 0.8rem 1.5rem 0.7rem;
  min-height: 4.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.wco-header-wave {
  display: block;
  width: 100%;
  height: 9px;
  pointer-events: none;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1 1 auto;
}
.brand-logo-mark {
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: var(--radius-square);
  background-color: #2563eb;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.22rem;
  font-weight: 700;
  line-height: 1;
  flex-shrink: 0;
  border: 1px solid #1d4ed8;
}
.brand-logo {
  max-height: 2.4rem;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}
.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.brand-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-main);
  line-height: 1.15;
}
.brand-tagline {
  font-size: 0.71rem;
  color: var(--text-muted);
  font-weight: 400;
  line-height: 1.3;
  margin-top: 0.12rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

/* Navigation in crisp small caps */
.nav-menu {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 0.35rem;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 0.94rem;
  font-weight: 500;
  font-variant-caps: all-small-caps;
  letter-spacing: 0.055em;
  color: var(--text-secondary);
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-square);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.nav-link:hover {
  color: var(--theme-primary);
}
.nav-link.active {
  color: var(--theme-primary);
  font-weight: 600;
  border-bottom-color: var(--theme-primary);
}

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

.header-signin-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.84rem;
  font-weight: 600;
  color: #ffffff;
  background-color: #2563eb;
  border: 1px solid #1d4ed8;
  padding: 0.45rem 1.05rem;
  border-radius: var(--radius-square);
  white-space: nowrap;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.header-signin-btn:hover {
  background-color: var(--theme-primary-hover);
  border-color: var(--theme-primary-hover);
  color: #ffffff;
}

.wco-replay-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 44px;
  padding: 0 14px;
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid rgba(41, 37, 36, 0.28);
  border-radius: var(--radius-square);
  box-shadow: var(--shadow-paper-sm);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.1;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}
.wco-replay-btn:hover {
  border-color: var(--theme-primary);
  color: var(--theme-primary);
  background: #ffffff;
}
.wco-replay-btn:focus-visible {
  outline: 2px solid var(--theme-primary);
  outline-offset: 2px;
}
.wco-replay-mobile-btn {
  width: 100%;
  margin-top: 0.55rem;
}

.search-toggle-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 2.35rem;
  height: 2.35rem;
  border-radius: var(--radius-square);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.search-toggle-btn:hover {
  color: var(--theme-primary);
  border-color: var(--theme-primary);
}

.mobile-menu-toggle {
  display: none;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  color: var(--text-main);
  cursor: pointer;
  padding: 0;
}

/* Search Dropdown / Drawer */
.header-search-box {
  display: none;
  background: var(--bg-surface);
  border-top: 1px dashed var(--border-dashed);
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 1.5rem;
}
.header-search-box.open {
  display: block;
}
.header-search-form {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  gap: 0.6rem;
}
.header-search-input {
  flex: 1;
  padding: 0.62rem 0.9rem;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.9375rem;
  outline: none;
  transition: border-color 0.15s ease;
}
.header-search-input:focus {
  border-color: var(--theme-primary);
}
.header-search-submit {
  background: var(--theme-primary);
  color: #ffffff;
  border: 1px solid var(--theme-primary);
  padding: 0.58rem 1.25rem;
  border-radius: var(--radius-square);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.15s ease;
}
.header-search-submit:hover {
  background: var(--theme-primary-hover);
}

/* Layout container */
.site-content {
  position: relative;
  z-index: 1;
  flex: 1;
  max-width: var(--container-max);
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4.25rem;
}

.content-grid {
  display: grid;
  grid-template-columns: 1.12fr 300px;
  gap: 2.5rem;
  align-items: start;
}

.content-full {
  max-width: var(--reading-max);
  margin: 0 auto;
}

.content-wide {
  max-width: 1020px;
  margin: 0 auto;
}

/* Editorial Hero (Archived Helper Class) */
.hero-lead {
  border-bottom: 1px dashed var(--border-dashed);
  padding-bottom: 2.25rem;
  margin-bottom: 2.25rem;
}
.hero-lead-badge {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.85rem;
  color: var(--theme-primary);
  margin-bottom: 0.45rem;
}
.hero-lead-title {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--text-main);
  margin-bottom: 1rem;
}
.hero-lead-title a:hover {
  color: var(--theme-primary);
}
.hero-lead-excerpt {
  font-size: 1.075rem;
  line-height: 1.65;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}
.hero-lead-image {
  border-radius: var(--radius-square);
  overflow: hidden;
  margin-top: 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-paper);
}
.hero-lead-image img {
  width: 100%;
  max-height: 440px;
  object-fit: cover;
}

/* Post Cards & Grid */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.65rem;
}

.posts-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.post-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  box-shadow: var(--shadow-paper);
  overflow: hidden;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}
.post-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-paper-hover);
  border-color: var(--theme-primary);
}

.card-img-wrap {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-body {
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-category {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--theme-primary);
  margin-bottom: 0.45rem;
}
.card-category a:hover {
  text-decoration: underline;
}

.card-title {
  font-family: var(--font-display);
  font-size: 1.24rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
  color: var(--text-main);
  margin-bottom: 0.6rem;
}
.card-title a:hover {
  color: var(--theme-primary);
}

.card-excerpt {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1rem;
  flex: 1;
}

.post-meta-unboxed {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.meta-dot {
  font-weight: 600;
  color: var(--text-faint);
}
.meta-author {
  color: var(--text-secondary);
  font-weight: 600;
}

/* Single Post & Page Paper Index Card View */
.single-article {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 2.35rem 2.5rem;
  box-shadow: var(--shadow-paper);
}

.breadcrumbs {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1.15rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.breadcrumbs a:hover {
  color: var(--theme-primary);
  text-decoration: underline;
}

.article-header {
  border-bottom: 1px dashed var(--border-dashed);
  padding-bottom: 1.4rem;
  margin-bottom: 1.85rem;
}
.article-category {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--theme-primary);
  margin-bottom: 0.5rem;
}
.article-title {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.025em;
  color: var(--text-main);
  margin-bottom: 0.85rem;
}
.article-lead {
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  font-style: normal;
}
.article-featured-image {
  margin: 1.5rem 0 2rem;
  border-radius: var(--radius-square);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

/* Article Typography */
.article-body {
  font-size: 1.02rem;
  line-height: 1.78;
  color: var(--text-secondary);
}
.article-body p {
  margin-bottom: 1.35rem;
}
.article-body h2 {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text-main);
  margin-top: 2.15rem;
  margin-bottom: 0.85rem;
  line-height: 1.28;
}
.article-body h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-main);
  margin-top: 1.65rem;
  margin-bottom: 0.65rem;
  line-height: 1.32;
}
.article-body h4 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-main);
  margin-top: 1.4rem;
  margin-bottom: 0.5rem;
}
.article-body ul, .article-body ol {
  margin-left: 1.6rem;
  margin-bottom: 1.4rem;
}
.article-body li {
  margin-bottom: 0.35rem;
}
.article-body blockquote {
  border-left: 3px solid var(--theme-primary);
  padding: 0.85rem 1.25rem;
  margin: 1.75rem 0;
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--text-secondary);
  background: var(--bg-subtle);
  border-radius: var(--radius-square);
}
.article-body blockquote p:last-child {
  margin-bottom: 0;
}
.article-body pre {
  background-color: #292524;
  color: #f7f3ea;
  padding: 1.25rem;
  border-radius: var(--radius-square);
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.55;
  margin: 1.75rem 0;
}
.article-body code:not(pre code) {
  background: var(--bg-subtle);
  color: var(--theme-primary);
  padding: 0.15rem 0.38rem;
  border-radius: var(--radius-square);
  font-family: var(--font-mono);
  font-size: 0.86em;
  border: 1px solid var(--border-subtle);
}
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.75rem 0;
  font-size: 0.9375rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
}
.article-body th, .article-body td {
  padding: 0.72rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  text-align: left;
}
.article-body th {
  background-color: var(--bg-subtle);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  color: var(--text-main);
  border-bottom: 1px dashed var(--border-dashed);
}
.article-body hr {
  border: 0;
  border-top: 1px dashed var(--border-dashed);
  margin: 2.25rem 0;
}
.article-body a {
  color: var(--theme-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.article-body a:hover {
  color: var(--theme-primary-hover);
}

/* Post Tags list */
.article-tags-wrap {
  margin-top: 2rem;
  padding-top: 1.35rem;
  border-top: 1px dashed var(--border-dashed);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.875rem;
}
.tag-label {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  font-weight: 600;
  margin-right: 0.25rem;
}
.article-tag-item {
  color: var(--text-secondary);
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-square);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 500;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.article-tag-item:hover {
  color: var(--theme-primary);
  border-color: var(--theme-primary);
}

/* Author Box */
.author-card {
  margin-top: 2.25rem;
  padding: 1.4rem;
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  display: flex;
  gap: 1.15rem;
  align-items: center;
}
.author-avatar {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: var(--radius-square);
  background: var(--theme-primary);
  color: #ffffff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.author-info h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}
.author-info p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Sidebar Widgets */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}
.widget {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 1.4rem;
  box-shadow: var(--shadow-paper-sm);
}
.widget-title {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.96rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.95rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px dashed var(--border-dashed);
  display: block;
}
.widget-search-form {
  display: flex;
  gap: 0.45rem;
}
.widget-search-input {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.8rem;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.875rem;
  outline: none;
  transition: border-color 0.15s ease;
}
.widget-search-input:focus {
  border-color: var(--theme-primary);
}
.widget-search-btn {
  background: var(--theme-primary);
  color: #ffffff;
  border: 1px solid var(--theme-primary-hover);
  padding: 0 0.9rem;
  border-radius: var(--radius-square);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s ease;
}
.widget-search-btn:hover {
  background: var(--theme-primary-hover);
}
.widget-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.widget-list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.875rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px dashed var(--border-subtle);
}
.widget-list-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.widget-list-item a {
  color: var(--text-secondary);
  transition: color 0.15s ease;
}
.widget-list-item a:hover {
  color: var(--theme-primary);
}
.widget-count {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
.recent-post-link {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.5rem 0;
  border-bottom: 1px dashed var(--border-subtle);
}
.recent-post-link:last-child {
  border-bottom: none;
}
.recent-post-title {
  font-family: var(--font-display);
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.35;
}
.recent-post-title:hover {
  color: var(--theme-primary);
}
.recent-post-date {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  margin-top: 2.75rem;
}
.page-btn {
  padding: 0.52rem 1.1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  color: var(--text-main);
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: var(--shadow-paper-sm);
  transition: border-color 0.15s ease, color 0.15s ease;
}
.page-btn:hover:not(.disabled) {
  border-color: var(--theme-primary);
  color: var(--theme-primary);
}
.page-btn.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.page-info {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
  padding: 0 0.5rem;
}

/* Archive & Search Page Header */
.archive-header {
  border-bottom: 1px dashed var(--border-dashed);
  padding-bottom: 1.4rem;
  margin-bottom: 2rem;
}
.archive-eyebrow {
  display: inline-block;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--theme-primary);
  margin-bottom: 0.35rem;
}
.archive-title {
  font-family: var(--font-display);
  font-size: 2.15rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--text-main);
  margin-bottom: 0.5rem;
  line-height: 1.15;
}
.archive-desc {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 640px;
}
.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.search-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 1.35rem;
  box-shadow: var(--shadow-paper-sm);
  transition: border-color 0.15s ease;
}
.search-item:hover {
  border-color: var(--theme-primary);
}
.search-item-type {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--theme-primary);
  margin-bottom: 0.25rem;
}
.search-item-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.search-item-title a:hover {
  color: var(--theme-primary);
}
.search-snippet {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
}
.search-snippet mark {
  background-color: var(--marker-amber);
  color: var(--text-main);
  font-weight: 600;
  padding: 0 0.22rem;
}

/* Footer (Warm Cream Paper + Dashed Rule + Editorial Colophon) */
.site-footer {
  position: relative;
  z-index: 1;
  width: 100%;
  margin-top: auto;
  background: var(--bg-page);
  border-top: 1px dashed var(--border-dashed);
  padding: 1.75rem 1.5rem 2rem;
}
.footer-container {
  max-width: var(--container-max);
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem 2.5rem;
  text-align: left;
}
.footer-brand-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.footer-copy-main {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.4;
}
.footer-copy-tagline {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}
.footer-colophon-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.45rem;
}
.footer-copy-colophon {
  margin-top: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.78rem;
  color: var(--text-faint);
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 1.45rem;
  list-style: none;
  flex-shrink: 0;
  padding-top: 0.1rem;
}
.footer-nav a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 500;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.footer-nav a:hover {
  color: var(--theme-primary);
  border-bottom-color: var(--theme-primary);
}

/* Login Page Container with Shared Header & Footer */
.login-page-main {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1rem;
}

/* Responsive Navigation & Layout */
@media (max-width: 1024px) {
  .header-container {
    padding: 0.7rem 1rem 0.6rem;
    gap: 0.75rem;
  }
  .brand-logo-mark {
    width: 34px;
    height: 34px;
    min-width: 34px;
    font-size: 1.05rem;
  }
  .brand-title {
    font-size: 1.02rem;
  }
  .brand-tagline {
    font-size: 0.67rem;
  }
  .nav-menu {
    gap: 0.1rem;
  }
  .nav-link {
    font-size: 0.82rem;
    padding: 0.3rem 0.38rem;
  }
  .wco-replay-header-btn {
    padding: 0 10px;
    font-size: 0.75rem;
  }
  .header-signin-btn {
    font-size: 0.8125rem;
    padding: 0.42rem 0.88rem;
  }
}

@media (max-width: 880px) {
  .content-grid {
    grid-template-columns: 1fr;
  }
  .sidebar {
    margin-top: 1.5rem;
  }
  .hero-lead-title {
    font-size: 2rem;
  }
  .article-title {
    font-size: 1.75rem;
  }
  .single-article {
    padding: 1.5rem;
  }
}

@media (max-width: 767px) {
  .nav-menu,
  .wco-replay-header-btn {
    display: none;
  }
  .mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

/* =========================================================
 * Pluggable Tool Pages & Directory
 * ========================================================= */
.tool-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.tool-breadcrumbs a:hover {
  color: var(--theme-primary);
  text-decoration: underline;
}
.tool-subtitle {
  font-size: 1.03rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  line-height: 1.6;
}
.tool-intro-body {
  margin-bottom: 1.5rem;
}
.tool-widget-shell {
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-top: 3px solid var(--theme-primary);
  border-radius: var(--radius-square);
  padding: 1.5rem;
  margin: 1.5rem 0 2rem;
}
.tool-outro-body {
  margin-top: 1.75rem;
}

/* Shared Tool Controls (Crisp Square Corners - Zero Pills) */
.tool-textarea,
.tool-input,
.tool-select {
  width: 100%;
  background: #ffffff;
  color: var(--text-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 0.72rem 0.9rem;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.15s ease;
}
.tool-select {
  width: auto;
  padding: 0.5rem 0.8rem;
  font-size: 0.875rem;
}
.tool-textarea:focus,
.tool-input:focus,
.tool-select:focus {
  outline: none;
  border-color: var(--border-focus);
}
.tool-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.5rem 0.95rem;
  border-radius: var(--radius-square);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--border-color);
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  font-family: inherit;
}
.tool-btn-primary {
  background: var(--theme-primary);
  border-color: var(--theme-primary-hover);
  color: #ffffff;
}
.tool-btn-primary:hover {
  background: var(--theme-primary-hover);
  border-color: var(--theme-primary-hover);
}
.tool-btn-secondary {
  background: var(--bg-surface);
  border-color: var(--border-color);
  color: var(--text-main);
}
.tool-btn-secondary:hover {
  border-color: var(--theme-primary);
  color: var(--theme-primary);
  background: #ffffff;
}
.tool-btn-danger {
  background: var(--bg-surface);
  color: #b91c1c;
  border-color: rgba(185, 28, 28, 0.32);
}
.tool-btn-danger:hover {
  background: #fef2f2;
  border-color: #dc2626;
}

/* Tool FAQ Accordion */
.tool-faq-section {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px dashed var(--border-dashed);
}
.tool-faq-heading {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  margin-bottom: 1.15rem;
  letter-spacing: -0.015em;
  color: var(--text-main);
}
.tool-faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.tool-faq-item {
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 0.9rem 1.15rem;
}
.tool-faq-question {
  font-weight: 600;
  font-size: 0.975rem;
  cursor: pointer;
  color: var(--text-main);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.tool-faq-question::-webkit-details-marker {
  display: none;
}
.tool-faq-question::after {
  content: '+';
  font-family: var(--font-mono);
  font-size: 1.15rem;
  color: var(--theme-primary);
  font-weight: 600;
}
.tool-faq-item[open] .tool-faq-question::after {
  content: '−';
}
.tool-faq-answer {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px dashed var(--border-dashed);
  font-size: 0.925rem;
  color: var(--text-secondary);
  line-height: 1.62;
}

/* Tools Directory Grid (Asymmetric Index Cards) */
.tools-directory-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.45rem;
  align-items: stretch;
}
.tool-directory-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-top: 3px solid var(--text-main);
  border-radius: var(--radius-square);
  box-shadow: var(--shadow-paper);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}
.tool-directory-card:first-child {
  border-top-color: var(--theme-primary);
}
.tool-directory-card:hover {
  transform: translateY(-2px);
  border-color: var(--theme-primary);
  box-shadow: var(--shadow-paper-hover);
}
.tool-directory-category {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--theme-primary);
}
.tool-directory-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.28;
}
.tool-directory-title a:hover {
  color: var(--theme-primary);
}
.tool-directory-desc {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.55;
  flex: 1;
}
.tool-directory-footer {
  padding-top: 0.75rem;
  border-top: 1px dashed var(--border-dashed);
}
.tool-directory-link {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--theme-primary);
}
.tool-directory-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* =========================================================
 * Ads & Monetization Slots + Admin-Only Previews
 * ========================================================= */
.lumina-ad-slot {
  margin: 1.5rem 0;
  text-align: center;
  overflow: hidden;
  max-width: 100%;
}
.lumina-ad-slot > * {
  max-width: 100%;
}
.lumina-ad-slot.lumina-ad-top {
  margin-top: 0;
  margin-bottom: 1.5rem;
}
.lumina-ad-slot.lumina-ad-incontent {
  margin: 1.75rem 0;
}
.lumina-ad-slot.lumina-ad-sidebar,
.lumina-ad-preview.lumina-ad-sidebar {
  margin: 0;
}
.lumina-ad-widget {
  padding: 1rem;
}
.lumina-ad-footer-wrap {
  position: relative;
  z-index: 1;
  max-width: var(--container-max);
  margin: 0 auto 2rem;
  padding: 0 1.5rem;
  width: 100%;
}
.lumina-ad-footer-wrap .lumina-ad-slot,
.lumina-ad-footer-wrap .lumina-ad-preview {
  margin: 0;
}
.lumina-ad-preview {
  margin: 1.5rem 0;
  padding: 1rem 1.25rem;
  border: 1.5px dashed rgba(37, 99, 235, 0.4);
  border-radius: var(--radius-square);
  background: var(--bg-subtle);
  color: var(--text-secondary);
  text-align: center;
}
.lumina-ad-preview.lumina-ad-top {
  margin-top: 0;
  margin-bottom: 1.5rem;
}
.lumina-ad-preview-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}
.lumina-ad-preview-meta {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* =========================================================
 * Threaded Comments & Contact Form
 * ========================================================= */
.hidden {
  display: none !important;
}
.lumina-hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}
.public-alert {
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-square);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}
.public-alert-success {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #86efac;
}
.public-alert-error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}
.public-contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.public-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 640px) {
  .public-form-row {
    grid-template-columns: 1fr;
  }
}
.public-form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.public-form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}
.public-form-input,
.public-form-textarea {
  width: 100%;
  background: #ffffff;
  color: var(--text-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 0.68rem 0.88rem;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.15s ease;
}
.public-form-input:focus,
.public-form-textarea:focus {
  outline: none;
  border-color: var(--border-focus);
}
.public-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.68rem 1.5rem;
  border-radius: var(--radius-square);
  background: var(--theme-primary);
  color: #ffffff;
  border: 1px solid var(--theme-primary-hover);
  font-family: inherit;
  font-size: 0.925rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease;
}
.public-submit-btn:hover {
  background: var(--theme-primary-hover);
}
.comments-section {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px dashed var(--border-dashed);
}
.comments-section-header {
  margin-bottom: 1.25rem;
}
.comments-heading {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text-main);
}
.comments-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 2rem;
}
.comment-card {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  background: var(--bg-page);
  padding: 1.1rem 1.25rem;
}
.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.55rem;
}
.comment-author-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.comment-author-name {
  font-weight: 600;
  color: var(--text-main);
}
a.comment-author-name:hover {
  color: var(--theme-primary);
  text-decoration: underline;
}
.comment-date {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}
.comment-reply-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  padding: 0.28rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  white-space: nowrap;
}
.comment-reply-btn:hover {
  border-color: var(--theme-primary);
  color: var(--theme-primary);
}
.comment-body {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
}
.comment-children {
  margin-left: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.comment-children-capped {
  margin-left: 0;
}
@media (max-width: 640px) {
  .comment-children {
    margin-left: 1rem;
  }
}
.comments-empty {
  color: var(--text-muted);
  font-size: 0.925rem;
  margin-bottom: 1.75rem;
}
.comment-form-wrap {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-square);
  background: var(--bg-page);
  padding: 1.5rem;
}
.comment-form-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.comment-form-note {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-bottom: 1.1rem;
}
.replying-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 0.95rem;
  border: 1px dashed var(--theme-primary);
  border-radius: var(--radius-square);
  background: var(--bg-surface);
  font-size: 0.85rem;
  margin-bottom: 1rem;
}
.reply-cancel-btn {
  background: none;
  border: none;
  color: var(--theme-primary);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}
.reply-cancel-btn:hover {
  text-decoration: underline;
}

/* =========================================================
 * Responsive Enhancements, Slide-In Drawer & Overflow Safety
 * ========================================================= */
.mobile-drawer-backdrop,
.mobile-drawer {
  display: none;
}

.post-card-horizontal {
  flex-direction: row;
  align-items: stretch;
}
.post-card-horizontal .card-img-wrap {
  width: 240px;
  flex-shrink: 0;
  aspect-ratio: 16 / 10;
  border-bottom: none;
  border-right: 1px solid var(--border-subtle);
}

.post-prev-next-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px dashed var(--border-dashed);
}

.content-grid-sidebar-left {
  grid-template-columns: 300px 1fr;
}

.landing-page-title {
  font-size: clamp(1.75rem, 6vw, 2.65rem);
}

.table-wrapper {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1.75rem 0;
}
.table-wrapper table {
  margin: 0;
}

.embed-wrapper {
  margin: 1.75rem 0;
}
.embed-wrapper figcaption {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
}
.embed-responsive {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius-square);
  background: #292524;
}
.embed-responsive iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.main-column,
.sidebar,
.widget,
.single-article,
.article-body,
.card-body,
.tool-directory-card,
.search-item {
  min-width: 0;
  max-width: 100%;
}
.article-title,
.archive-title,
.card-title,
.article-body,
.tool-subtitle,
.search-item-title,
.breadcrumbs {
  overflow-wrap: anywhere;
  word-break: break-word;
}
.article-body img,
.article-body video,
.article-body svg,
.article-body iframe {
  max-width: 100%;
}

@media (max-width: 880px) {
  .content-grid,
  .content-grid-sidebar-left {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }
}

@media (max-width: 767px) {
  .mobile-drawer-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.35);
    z-index: 98;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
  }
  .mobile-drawer-backdrop.open {
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-drawer {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    position: fixed;
    top: 0;
    right: 0;
    left: auto;
    bottom: 0;
    width: min(320px, 86vw);
    background: var(--bg-surface);
    z-index: 99;
    padding: 1rem 1.25rem 2rem;
    overflow-y: auto;
    border-left: 1px solid var(--border-color);
    box-shadow: -4px 0 18px rgba(41, 37, 36, 0.14);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.25s ease;
  }
  .mobile-drawer.open {
    transform: translateX(0);
    visibility: visible;
  }
  .mobile-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 0.75rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px dashed var(--border-dashed);
  }
  .mobile-drawer-title {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-main);
  }
  .mobile-drawer-close {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    border-radius: var(--radius-square);
    border: 1px solid var(--border-color);
    background: var(--bg-page);
    color: var(--text-main);
    font-size: 1.5rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
  }
  .mobile-drawer-search {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
  }
  .mobile-drawer .nav-link {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-height: 48px;
    font-size: 1.05rem;
    font-variant-caps: normal;
    letter-spacing: 0.01em;
    padding: 0.5rem 0.25rem;
    border-bottom: 1px dashed var(--border-subtle);
  }
  .mobile-drawer .nav-link.active {
    border-bottom-color: var(--theme-primary);
  }
  .mobile-drawer-auth {
    margin-top: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0.65rem 1.25rem;
    border-radius: var(--radius-square);
    background: var(--theme-primary);
    border: 1px solid var(--theme-primary-hover);
    color: #ffffff;
    font-weight: 600;
    font-size: 0.95rem;
  }

  .header-container {
    padding: 0.65rem 0.9rem 0.55rem;
    min-height: 3.75rem;
    gap: 0.5rem;
  }
  .brand-wrapper {
    gap: 0.55rem;
    min-width: 0;
    flex: 1 1 auto;
  }
  .brand-logo-mark {
    width: 34px;
    height: 34px;
    min-width: 34px;
    font-size: 1.05rem;
  }
  .brand-title {
    font-size: 0.98rem;
    line-height: 1.18;
  }
  .brand-tagline {
    display: block;
    font-size: 0.67rem;
    line-height: 1.25;
  }
  .header-right {
    gap: 0.4rem;
    flex-shrink: 0;
  }
  .header-actions {
    gap: 0.4rem;
    flex-shrink: 0;
  }
  .header-signin-btn {
    min-height: 38px;
    padding: 0 0.8rem;
    font-size: 0.8125rem;
  }
  .search-toggle-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
  }
  .mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    padding: 0;
    line-height: 1;
  }
  .header-search-box {
    padding: 0.75rem 16px;
  }
  .site-content {
    padding: 1.5rem 12px 2.5rem;
  }
  .lumina-ad-footer-wrap {
    padding: 0 12px;
  }
  .site-footer {
    padding: 1.35rem 1rem 1.75rem;
  }
  .footer-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.95rem;
    text-align: left;
  }
  .footer-nav {
    justify-content: flex-start;
    gap: 0.45rem 1.25rem;
  }

  /* Responsive Typography */
  .article-title {
    font-size: clamp(1.55rem, 6vw, 2.2rem);
  }
  .archive-title {
    font-size: clamp(1.45rem, 5.5vw, 2rem);
  }
  .hero-lead-title {
    font-size: clamp(1.65rem, 6vw, 2.2rem);
  }
  .article-body {
    font-size: 1rem;
    line-height: 1.75;
  }
  .article-body h2 {
    font-size: clamp(1.3rem, 4.5vw, 1.6rem);
  }
  .article-body h3 {
    font-size: clamp(1.12rem, 3.8vw, 1.3rem);
  }
  .article-body > table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Inputs >=16px & Touch Targets >=44px */
  .header-search-input,
  .widget-search-input,
  .tool-textarea,
  .tool-input,
  .tool-select,
  .public-form-input,
  .public-form-textarea {
    font-size: 1rem;
    min-height: 44px;
    min-width: 0;
  }
  .header-search-submit,
  .widget-search-btn,
  .tool-btn,
  .page-btn,
  .comment-reply-btn,
  .reply-cancel-btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .tool-btn {
    padding: 0.6rem 0.95rem;
  }
  .page-btn {
    padding: 0.55rem 1.05rem;
  }
  .comment-reply-btn {
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
  }
  .public-submit-btn {
    width: 100%;
    min-height: 48px;
    font-size: 1rem;
  }
  .tool-faq-question {
    min-height: 44px;
    padding: 0.2rem 0;
  }
  .tool-directory-link,
  .widget-list-item a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
  .article-tag-item {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
  }
  .pagination {
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 2rem;
  }
}

@media (max-width: 640px) {
  .admin-bar {
    padding: 0.45rem 14px;
    flex-wrap: wrap;
    gap: 0.35rem 0.75rem;
  }
  .single-article {
    padding: 1.25rem 1rem;
  }
  .single-article.tool-article {
    padding: 1.2rem 0.95rem;
  }
  .tool-widget-shell {
    padding: 0.95rem;
    margin: 1.15rem 0 1.5rem;
  }
  .widget {
    padding: 1.2rem 1rem;
  }
  .posts-grid,
  .tools-directory-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
  .post-card-horizontal {
    flex-direction: column;
  }
  .post-card-horizontal .card-img-wrap {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-right: none;
    border-bottom: 1px solid var(--border-subtle);
  }
  .post-prev-next-nav {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .post-prev-next-nav > div:last-child {
    text-align: left !important;
  }
  .author-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.15rem;
  }
  .comment-form-wrap {
    padding: 1.15rem 1rem;
  }
  .footer-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    font-size: 0.875rem;
  }
}

/* =========================================================
 * Homepage Asymmetric Editorial Hero, Index Card & Ledger
 * ========================================================= */
.site-content-home {
  padding-top: 2.25rem;
}

.wco-hero-section {
  max-width: 1020px;
  margin: 0 auto 2.35rem;
  padding: 0.5rem 0 1.65rem;
  border-bottom: 1px dashed var(--border-dashed);
}

.wco-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(190px, 0.55fr);
  gap: 1.5rem 2.5rem;
  align-items: center;
}

.wco-hero-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 1rem;
}

.wco-hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.45rem, 5.4vw, 4rem);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.028em;
  color: var(--text-main);
}

.wco-hero-accent-wrap {
  position: relative;
  display: inline-block;
  padding-bottom: 0.14em;
}

.wco-hero-accent {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  color: #2563eb;
}

.wco-hero-underline {
  position: absolute;
  left: -2%;
  bottom: 0;
  width: 104%;
  height: 14px;
  pointer-events: none;
}

.wco-hero-subtitle {
  font-size: clamp(1rem, 1.55vw, 1.15rem);
  line-height: 1.62;
  color: var(--text-muted);
  max-width: 590px;
}

/* Single flat warm amber marker-highlight stroke on hero word */
.wco-marker-highlight {
  background-color: var(--marker-amber);
  color: var(--text-main);
  padding: 0.04em 0.24em;
  border-radius: 2px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.wco-hero-points {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.45rem;
  margin-top: 0.35rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--border-subtle);
}

.wco-hero-point {
  position: relative;
  padding-left: 0.95rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.wco-hero-point::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 6px;
  height: 6px;
  background: var(--theme-primary);
}

/* Rotated circular rubber-stamp badge */
.wco-hero-aside {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-right: 0.75rem;
}

.wco-browser-stamp {
  width: 138px;
  height: 138px;
  border-radius: 50%;
  border: 2px solid rgba(37, 99, 235, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  transform: rotate(-8deg);
  color: #2563eb;
  background: rgba(255, 253, 249, 0.6);
  user-select: none;
}

.wco-browser-stamp-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1px dashed rgba(37, 99, 235, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.35;
}

.home-main-stack {
  max-width: 1020px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2.35rem;
}

/* Index card feel for the main counter panel (slight paper rotation on wide desktop) */
.home-tool-panel {
  padding: 1.85rem;
  border-top: 3px solid var(--theme-primary);
  box-shadow: 0 3px 8px rgba(41, 37, 36, 0.07), 4px 5px 0 rgba(41, 37, 36, 0.06);
}

@media (min-width: 960px) {
  .home-tool-panel {
    transform: rotate(-0.45deg);
    margin-right: 1.25rem;
  }
  .home-guide-card {
    margin-left: 2.5rem;
  }
  .home-faq-card {
    margin-right: 1.5rem;
  }
}

.home-guide-card,
.home-faq-card {
  padding: 2rem 2.25rem;
}

.home-guide-card h2:first-child {
  margin-top: 0;
}

/* Hand-crafted circled numbers for How to Use headings */
.home-guide-body {
  counter-reset: guide-step;
}

.home-guide-body h2,
.home-guide-body h3 {
  counter-increment: guide-step;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.home-guide-body h2::before,
.home-guide-body h3::before {
  content: counter(guide-step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--theme-primary);
  color: var(--theme-primary);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  background: var(--bg-page);
}

.wco-more-tools-section {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.wco-section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding-bottom: 0.55rem;
  border-bottom: 1px dashed var(--border-dashed);
}

.wco-section-title {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.015em;
}

.wco-more-tools-grid {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 1.4rem;
}

@media (max-width: 767px) {
  .site-content-home {
    padding-top: 1.35rem;
  }
  .wco-hero-section {
    padding: 0 0 1.25rem;
    margin-bottom: 1.35rem;
  }
  .wco-hero-grid {
    grid-template-columns: 1fr;
    gap: 1.1rem;
  }
  .wco-hero-aside {
    justify-content: flex-start;
    padding-right: 0;
  }
  .wco-browser-stamp {
    width: 110px;
    height: 110px;
    transform: rotate(-6deg);
  }
  .wco-browser-stamp-inner {
    font-size: 0.64rem;
    padding: 0.55rem;
  }
  .home-main-stack {
    gap: 1.5rem;
  }
  .home-tool-panel {
    padding: 1rem;
    transform: none;
    margin-right: 0;
  }
  .home-guide-card,
  .home-faq-card {
    padding: 1.35rem 1.15rem;
    margin-left: 0;
    margin-right: 0;
  }
  .wco-more-tools-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}
