/*
Theme Name: Custom Premium Minimalist
Theme URI: https://example.com/custom-premium-theme
Author: Custom Premium Developer
Author URI: https://example.com
Description: An ultra-fast, mobile-first, Core Web Vitals optimized, AdSense and Google Discover friendly WordPress theme with native automatic dark mode and zero jQuery dependency.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: premium-custom
Tags: blog, custom-colors, custom-menu, custom-logo, featured-images, layout-builder, schema-seo, discover-optimized, ad-optimized, speed-focused
Requires PHP: 8.0
Requires at least: 6.0
*/

/* ==========================================================================
   1. CRITICAL DESIGN SYSTEM VARIABLES
   ========================================================================== */
:root {
  --primary-color: #111827;
  --secondary-color: #111827;
  --bg-color: #f8fafc;
  --card-bg: #ffffff;
  --text-main: #334155;
  --text-title: #0f172a;
  --border-color: #e2e8f0;
  
  --font-sans: "Inter", sans-serif;
  --font-mono: "Space Grotesk", monospace;
  --max-content-width: 680px;
  --max-site-width: 1200px;
  
  --radius-button: 8px;
  --radius-image: 12px;
  --gap-paragraph: 1.5rem;
}

/* Light / Dark Mode preferences */
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    --bg-color: #0b0f19;
    --card-bg: #151f32;
    --text-main: #94a3b8;
    --text-title: #f8fafc;
    --border-color: #1e293b;
  }
}

:root[data-theme="dark"] {
  --bg-color: #0b0f19;
  --card-bg: #151f32;
  --text-main: #94a3b8;
  --text-title: #f8fafc;
  --border-color: #1e293b;
}

/* ==========================================================================
   2. CORE WEB VITALS OPTIMIZATIONS (RESET & BASE STYLES)
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: var(--body-font-size, 16px);
  line-height: 1.625;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Zero CLS for Ad Slots */
.ad-slot-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--border-color);
  border: 1px dashed #94a3b8;
  border-radius: 8px;
  margin: var(--gap-paragraph) 0;
  overflow: hidden;
  position: relative;
  min-height: 90px;
}

/* Prevent image layout shift - explicit aspect ratio loading */
img {
  max-width: 100%;
  height: auto;
  display: block;
  content-visibility: auto;
}

/* Keyboard Accessibility Focus */
*:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}

/* Accessible Screen Reader Only Text */
.screen-reader-text {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* Minimalist Loading Progress Indicator */
.reading-progress-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: transparent;
  z-index: 9999;
}
.reading-progress-bar {
  height: 100%;
  background-color: var(--primary-color);
  width: 0%;
  transition: width 0.1s ease-out;
}

/* ==========================================================================
   3. GLOBAL CONTAINER
   Everything (header, content, ads) shares this same max-width so nothing
   ever stretches full-bleed edge-to-edge on desktop.
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--max-site-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* ==========================================================================
   4. SITE HEADER
   ========================================================================== */
.site-header {
  background-color: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
}

.header-main {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 36px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.site-branding {
  flex-shrink: 0;
}
.site-branding .site-title {
  margin: 0;
  font-size: 22px;
}
.site-branding .site-title a {
  color: var(--text-title);
  text-decoration: none;
  font-weight: 800;
}
.site-branding img {
  max-height: var(--logo-height, 48px);
  width: auto;
}

.main-navigation {
  flex-grow: 0;
  min-width: 0;
  display: flex;
  justify-content: flex-start;
  overflow-x: auto;
  scrollbar-width: none;
}
@media (min-width: 783px) {
  .main-navigation {
    margin-left: auto;
  }
}
.main-navigation::-webkit-scrollbar {
  display: none;
}
.main-navigation ul {
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: clamp(12px, 1.6vw, 28px);
  margin: 0;
  padding: 0;
}
.main-navigation ul li {
  flex-shrink: 0;
}
.main-navigation ul a {
  color: var(--text-main);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
}
.main-navigation ul a:hover {
  color: var(--primary-color);
}
.main-navigation ul ul {
  list-style: none;
  margin: 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.icon-btn-toggle {
  background: none;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-main);
  cursor: pointer;
}

.hamburger-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}
.hamburger-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background-color: var(--text-title);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.hamburger-toggle.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-toggle.is-active span:nth-child(2) { opacity: 0; }
.hamburger-toggle.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile header/menu behaviour */
@media (max-width: 782px) {
  .hamburger-toggle {
    display: flex;
  }
  .main-navigation {
    display: none;
    width: 100%;
    order: 3;
  }
  .main-navigation.is-active {
    display: block;
  }
  #primary-menu-list,
  .main-navigation ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 12px 0;
  }
  #primary-menu-list a,
  .main-navigation ul a {
    display: block;
    padding: 10px 0;
    width: 100%;
    border-bottom: 1px solid var(--border-color);
  }
  .header-main {
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 10px;
  }
  .site-branding {
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
  }
  .site-branding .site-title a {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .header-actions {
    flex-shrink: 0;
  }
}

/* ==========================================================================
   5. AD WRAPPER
   Real ad units (AdX / Ad Manager) should be placed inside .ad-container so
   they always line up with the header/content width and never render
   full-bleed edge-to-edge on desktop.
   ========================================================================== */
.ad-container {
  width: 100%;
  max-width: var(--max-site-width);
  margin: var(--gap-paragraph) auto;
  padding-left: 20px;
  padding-right: 20px;
  text-align: center;
}

@media (min-width: 992px) {
  /* Inset ads 20% from each side on desktop, same rail as the header */
  .ad-container {
    padding-left: calc(20% + 20px);
    padding-right: calc(20% + 20px);
  }
}

.ad-container .ad-slot-placeholder,
.ad-container ins.adsbygoogle,
.ad-container > div {
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.ad-label {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-main);
  margin: 0 0 6px;
}
.ad-container > .ad-label:last-child {
  margin: 6px 0 0;
}

/* Reserve space so the layout doesn't jump while AdX is still fetching a
   creative (this is what actually protects your CLS/speed score — the ad
   can take as long as it needs to load without shifting anything below it) */
.ad-slot-reserved {
  min-height: 100px;
  position: relative;
}
@media (min-width: 600px) {
  .ad-slot-reserved {
    min-height: 250px;
  }
}

/* Small, centered, blinking "Ad" placeholder — shown while waiting for the
   real ad creative to load, then hidden automatically once it renders */
.ad-loading-indicator {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-main);
  pointer-events: none;
  animation: ad-blink 1.3s ease-in-out infinite;
}
@keyframes ad-blink {
  0%, 100% { opacity: 0.15; }
  50% { opacity: 0.65; }
}
.ad-slot-reserved.ad-is-loaded .ad-loading-indicator {
  display: none;
}

/* Ads stay compact/full-width on mobile for fast loading, no 20% inset there */
@media (max-width: 991px) {
  .ad-container {
    padding-left: 12px;
    padding-right: 12px;
    margin: 1.1rem auto;
  }
}

/* ==========================================================================
   6. TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-title);
  font-family: var(--font-sans);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
}

.single-title.entry-title {
  font-size: calc(clamp(28px, 4vw, 42px) * var(--heading-scale, 1));
  font-weight: 800;
  line-height: 1.15;
  margin: 0.4em 0 0.5em;
}

.section-title {
  font-size: calc(22px * var(--heading-scale, 1));
  font-weight: 800;
  border-left: 4px solid var(--primary-color);
  padding-left: 10px;
  margin-bottom: 1.2rem;
}

.card-title {
  font-size: calc(17px * var(--heading-scale, 1));
  line-height: 1.4;
  font-weight: 700;
  margin: 0.5em 0;
}
.card-title a {
  color: var(--text-title);
  text-decoration: none;
}
.card-title a:hover {
  color: var(--primary-color);
}

.faq-main-heading {
  font-size: 19px;
  font-weight: 800;
}

.article-body.entry-content {
  font-size: 17px;
  line-height: 1.75;
  color: var(--text-main);
}
.article-body.entry-content p {
  margin: 0 0 var(--gap-paragraph);
}
.article-body.entry-content h2 {
  font-size: calc(26px * var(--heading-scale, 1));
  margin-top: 1.6em;
}
.article-body.entry-content h3 {
  font-size: calc(21px * var(--heading-scale, 1));
  margin-top: 1.4em;
}
.article-body.entry-content a {
  color: var(--primary-color);
  text-decoration: underline;
  text-decoration-color: var(--border-color);
  text-underline-offset: 3px;
}
.article-body.entry-content ul,
.article-body.entry-content ol {
  margin: 0 0 var(--gap-paragraph);
  padding-left: 1.4em;
}
.article-body.entry-content blockquote {
  margin: var(--gap-paragraph) 0;
  padding: 0.8em 1.2em;
  border-left: 4px solid var(--primary-color);
  background: var(--card-bg);
  font-style: italic;
  color: var(--text-title);
}

.single-meta {
  font-size: 13px;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* ==========================================================================
   7. HOMEPAGE / CONTENT LAYOUT
   ========================================================================== */
.site-main-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 40px;
  padding-top: 2rem;
  padding-bottom: 3rem;
  align-items: start;
}

.main-content-flow {
  min-width: 0;
}

/* Featured post */
.featured-post-card {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 24px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  overflow: hidden;
  margin-bottom: 2.2rem;
}
.featured-img-container {
  min-height: 220px;
}
.featured-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.featured-card-content {
  padding: 20px 24px 20px 4px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.featured-card-content h2 {
  font-size: clamp(20px, 2.6vw, 28px);
  margin: 0 0 10px;
}
.featured-card-content h2 a {
  color: var(--text-title);
  text-decoration: none;
}
.featured-card-content .meta-description {
  font-size: 14px;
  color: var(--text-main);
  margin: 0 0 12px;
}
.featured-card-content .card-meta {
  font-size: 13px;
  color: var(--text-main);
  display: flex;
  gap: 8px;
}

/* Post grid */
.posts-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
  margin-bottom: 2rem;
}

.story-grid-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.card-thumbnail-box img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.card-text-container {
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.card-excerpt p {
  font-size: 14px;
  color: var(--text-main);
  margin: 0 0 12px;
  flex-grow: 1;
}
.card-footer-meta {
  font-size: 12px;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* List layout variant — stacked rows, small thumbnail on the side */
.posts-list-grid.layout-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.posts-list-grid.layout-list .story-grid-card {
  flex-direction: row;
  align-items: stretch;
}
.posts-list-grid.layout-list .card-thumbnail-box {
  flex-shrink: 0;
  width: 140px;
}
.posts-list-grid.layout-list .card-thumbnail-box img {
  height: 100%;
  aspect-ratio: 1 / 1;
}
.posts-list-grid.layout-list .card-text-container {
  padding: 12px 16px;
  justify-content: center;
}
.posts-list-grid.layout-list .card-excerpt {
  display: none;
}
@media (max-width: 560px) {
  .posts-list-grid.layout-list .card-thumbnail-box {
    width: 90px;
  }
  .posts-list-grid.layout-list .card-title {
    font-size: 14px;
  }
}

/* Pagination */
.pagination-container,
.classic-pagination {
  text-align: center;
  margin-top: 1rem;
}
.btn.btn-primary {
  background: var(--primary-color);
  color: #fff;
  border: none;
  padding: 11px 28px;
  border-radius: var(--radius-button);
  font-weight: 700;
  cursor: pointer;
  font-size: 14px;
}
.classic-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  margin: 0 3px;
  border-radius: var(--radius-button);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  text-decoration: none;
  font-size: 14px;
}
.classic-pagination .page-numbers.current {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
}

/* Sidebar */
.site-sidebar-sticky {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.site-sidebar-sticky .widget {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  padding: 18px;
}
.widget-title {
  font-size: 16px;
  font-weight: 800;
  margin: 0 0 12px;
}
.search-form-ajax {
  position: relative;
}
.search-field {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-button);
  background: var(--bg-color);
  color: var(--text-main);
  font-size: 14px;
}
.trending-list-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.trending-list-links a {
  color: var(--text-title);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}
.trending-list-links a:hover {
  color: var(--primary-color);
}
.trending-meta {
  display: block;
  font-size: 12px;
  color: var(--text-main);
  margin-top: 2px;
}
.site-sidebar-sticky ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-sidebar-sticky li {
  padding: 7px 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 14px;
}
.site-sidebar-sticky li:last-child {
  border-bottom: none;
}
.site-sidebar-sticky li a {
  color: var(--text-main);
  text-decoration: none;
}
.site-sidebar-sticky li a:hover {
  color: var(--primary-color);
}

@media (max-width: 900px) {
  .site-main-layout {
    grid-template-columns: 1fr;
  }
  .featured-post-card {
    grid-template-columns: 1fr;
  }
  .featured-card-content {
    padding: 16px;
  }
}

/* ==========================================================================
   8. FOOTER
   ========================================================================== */
.site-footer {
  background-color: var(--card-bg);
  border-top: 1px solid var(--border-color);
  margin-top: 3rem;
}

.footer-grid-columns {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  padding-top: 3rem;
  padding-bottom: 2.5rem;
}

.footer-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-title);
  margin: 0 0 14px;
}

.footer-desc {
  font-size: 14px;
  color: var(--text-main);
  line-height: 1.6;
  margin: 0 0 16px;
}

.footer-widget-item ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-widget-item ul li a,
.footer-widget-item .menu li a {
  color: var(--text-main);
  text-decoration: none;
  font-size: 14px;
}
.footer-widget-item ul li a:hover,
.footer-widget-item .menu li a:hover {
  color: var(--primary-color);
}
.footer-widget-item .menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-social-icons {
  display: flex;
  gap: 10px;
}
.footer-social-icons a {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  color: var(--text-main);
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
}
.footer-social-icons a:hover {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.footer-newsletter-form {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}
.footer-newsletter-form input[type="email"] {
  flex-grow: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-button);
  background: var(--bg-color);
  color: var(--text-main);
  font-size: 13px;
}
.footer-newsletter-form .submit-btn {
  background: var(--primary-color);
  color: #fff;
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius-button);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  flex-shrink: 0;
}

.site-footer-bottom {
  border-top: 1px solid var(--border-color);
}
.footer-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 16px;
  padding-bottom: 16px;
  font-size: 13px;
  color: var(--text-main);
}
.footer-bottom-inner p {
  margin: 0;
}

#back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--primary-color);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.2s ease;
}

@media (max-width: 900px) {
  .footer-grid-columns {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 560px) {
  .footer-grid-columns {
    grid-template-columns: 1fr;
  }
  .footer-bottom-inner {
    flex-direction: column;
    text-align: center;
  }
}

/* ==========================================================================
   9. RECOMMENDED READING
   ========================================================================== */
.related-posts-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}
.related-posts-section h3 {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 1.2rem;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.related-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  overflow: hidden;
}
.related-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}
.related-card h4 {
  font-size: 15px;
  line-height: 1.4;
  margin: 0;
  padding: 12px 14px 16px;
}
.related-card h4 a {
  color: var(--text-title);
  text-decoration: none;
}
.related-card h4 a:hover {
  color: var(--primary-color);
}

/* ==========================================================================
   10. COMMENTS
   ========================================================================== */
.comments-area {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}
.comments-title {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 1.4rem;
}
.comment-list {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
}
.comment-list .comment {
  display: flex;
  gap: 14px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border-color);
}
.comment-list .comment:first-child {
  padding-top: 0;
}
.comment-list .avatar {
  border-radius: 50%;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
}
.comment-body .comment-author {
  font-weight: 700;
  color: var(--text-title);
  font-size: 14px;
}
.comment-body .comment-author .says {
  display: none;
}
.comment-body .comment-metadata {
  font-size: 12px;
  margin-bottom: 8px;
}
.comment-body .comment-metadata a {
  color: var(--text-main);
  text-decoration: none;
}
.comment-body p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-main);
  margin: 0;
}
.comment-list ol.children {
  list-style: none;
  margin: 0;
  padding-left: 36px;
}

.comment-form-ajax-container {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  padding: 22px;
}
.comment-form-ajax-container p {
  margin: 0 0 14px;
}
.comment-form-ajax-container label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-title);
}
.comment-form-ajax-container input[type="text"],
.comment-form-ajax-container input[type="email"],
.comment-form-ajax-container input[type="url"],
.comment-form-ajax-container textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-button);
  background: var(--bg-color);
  color: var(--text-main);
  font-size: 14px;
  font-family: inherit;
}
.comment-form-ajax-container textarea {
  min-height: 120px;
  resize: vertical;
}
.comment-form-ajax-container .comment-form-cookies-consent {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.comment-form-ajax-container .comment-form-cookies-consent input {
  width: auto;
}

/* ==========================================================================
   11. FOOTER WIDGET AREAS (editable via Appearance > Widgets)
   ========================================================================== */
.footer-widget-item .widget {
  margin-bottom: 20px;
}
.footer-widget-item .widget:last-child {
  margin-bottom: 0;
}
.footer-widget-item .widget-title {
  font-size: 15px;
  margin-bottom: 12px;
}

/* Dark mode: force links to white everywhere (overrides pasted/inline
   colors that would otherwise still show as blue) */
:root[data-theme="dark"] .article-body.entry-content a,
:root[data-theme="dark"] .article-body.entry-content a span,
:root[data-theme="dark"] .article-body.entry-content a strong,
:root[data-theme="dark"] .breadcrumb-nav a,
:root[data-theme="dark"] .single-meta a,
:root[data-theme="dark"] .author-info a,
:root[data-theme="dark"] .comment-body a,
:root[data-theme="dark"] .card-title a,
:root[data-theme="dark"] .related-card a,
:root[data-theme="dark"] .site-sidebar-sticky a,
:root[data-theme="dark"] .footer-widget-item a {
  color: #ffffff !important;
  text-decoration-color: rgba(255, 255, 255, 0.45) !important;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] .article-body.entry-content a,
  :root[data-theme="auto"] .article-body.entry-content a span,
  :root[data-theme="auto"] .article-body.entry-content a strong,
  :root[data-theme="auto"] .breadcrumb-nav a,
  :root[data-theme="auto"] .single-meta a,
  :root[data-theme="auto"] .author-info a,
  :root[data-theme="auto"] .comment-body a,
  :root[data-theme="auto"] .card-title a,
  :root[data-theme="auto"] .related-card a,
  :root[data-theme="auto"] .site-sidebar-sticky a,
  :root[data-theme="auto"] .footer-widget-item a {
    color: #ffffff !important;
    text-decoration-color: rgba(255, 255, 255, 0.45) !important;
  }
}

/* ==========================================================================
   12. AUTHOR BOX
   ========================================================================== */
.author-bio-box {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 2.4rem;
  padding: 20px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
}
.author-avatar img {
  border-radius: 50%;
  display: block;
  width: 64px;
  height: 64px;
}
.author-info h4 {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 800;
  color: var(--text-title);
}
.author-info p {
  margin: 0;
  font-size: 14px;
  color: var(--text-main);
  line-height: 1.5;
}

/* ==========================================================================
   13. PREV / NEXT POST NAVIGATION
   ========================================================================== */
.post-navigation-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 1.6rem;
}
.post-navigation-split .nav-prev,
.post-navigation-split .nav-next {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-image);
  padding: 16px 18px;
  display: flex;
}
.post-navigation-split .nav-next {
  text-align: right;
  justify-content: flex-end;
}
.post-navigation-split a {
  color: var(--text-title);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
}
.post-navigation-split a:hover {
  color: var(--primary-color);
}
@media (max-width: 640px) {
  .post-navigation-split {
    grid-template-columns: 1fr;
  }
  .post-navigation-split .nav-next {
    text-align: left;
    justify-content: flex-start;
  }
}

/* ==================== CUSTOM USER CSS ==================== */
/* Add custom CSS variables or overrides here */
.breadcrumb-nav {
  font-size: 12px;
}
.card-category-list,
.category-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--primary-color);
  margin-bottom: 6px;
}
.card-category-list a {
  color: var(--primary-color);
  text-decoration: none;
}
.card-category-list a:hover {
  text-decoration: underline;
}
