rx-single.css

I’ll build this as a full advanced assets/css/rx-single.css for WordPress single posts: layout, typography, medical article readability, TOC, author box, related posts, comments, responsive design, print mode, dark mode, and accessibility.

My dear friend, use this as your advanced RX Theme single post CSS file:

assets/css/rx-single.css

/*!
Theme Name: RX Theme
File: assets/css/rx-single.css
Description: Advanced single post/article styling for RX Theme.
Author: RxHarun
Version: 1.0.0
*/

/* =========================================================
   RX SINGLE POST CSS
   ========================================================= */

/* ---------------------------------------------------------
   01. Single Page Root Variables
--------------------------------------------------------- */

:root {
  --rx-single-bg: var(--rx-color-bg, #ffffff);
  --rx-single-surface: var(--rx-color-surface, #ffffff);
  --rx-single-soft: var(--rx-color-soft, #f8fafc);
  --rx-single-muted-bg: var(--rx-color-muted-bg, #f1f5f9);

  --rx-single-text: var(--rx-color-text, #0f172a);
  --rx-single-text-soft: var(--rx-color-text-soft, #334155);
  --rx-single-muted: var(--rx-color-muted, #64748b);
  --rx-single-light: var(--rx-color-light, #94a3b8);

  --rx-single-primary: var(--rx-color-primary, #0f766e);
  --rx-single-primary-hover: var(--rx-color-primary-hover, #115e59);
  --rx-single-secondary: var(--rx-color-secondary, #0369a1);
  --rx-single-accent: var(--rx-color-accent, #f59e0b);
  --rx-single-danger: var(--rx-color-danger, #dc2626);
  --rx-single-success: var(--rx-color-success, #16a34a);
  --rx-single-warning: var(--rx-color-warning, #d97706);
  --rx-single-info: var(--rx-color-info, #0284c7);

  --rx-single-border: var(--rx-color-border, #e2e8f0);
  --rx-single-border-strong: var(--rx-color-border-strong, #cbd5e1);

  --rx-single-radius-xs: 4px;
  --rx-single-radius-sm: 8px;
  --rx-single-radius-md: 12px;
  --rx-single-radius-lg: 18px;
  --rx-single-radius-xl: 24px;
  --rx-single-radius-full: 999px;

  --rx-single-shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --rx-single-shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --rx-single-shadow-lg: 0 18px 48px rgba(15, 23, 42, 0.12);

  --rx-single-font-body: var(--rx-font-body, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
  --rx-single-font-heading: var(--rx-font-heading, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
  --rx-single-font-code: var(--rx-font-code, "SFMono-Regular", Consolas, "Liberation Mono", monospace);

  --rx-single-container: 1180px;
  --rx-single-content: 780px;
  --rx-single-sidebar: 340px;

  --rx-single-gap: clamp(1.25rem, 3vw, 2.5rem);
  --rx-single-section-gap: clamp(2rem, 5vw, 4rem);

  --rx-single-line-height: 1.78;
  --rx-single-heading-line-height: 1.25;

  --rx-single-transition: 180ms ease;
}

/* ---------------------------------------------------------
   02. Single Page Wrapper
--------------------------------------------------------- */

.rx-single-page,
.single .site-main,
.single-post .site-main {
  background: var(--rx-single-bg);
  color: var(--rx-single-text);
  font-family: var(--rx-single-font-body);
}

.rx-single-wrap {
  width: min(100% - 32px, var(--rx-single-container));
  margin-inline: auto;
  padding-block: clamp(1.5rem, 4vw, 3.5rem);
}

.rx-single-layout {
  display: grid;
  grid-template-columns: minmax(0, var(--rx-single-content)) minmax(280px, var(--rx-single-sidebar));
  gap: var(--rx-single-gap);
  align-items: start;
}

.rx-single-main {
  min-width: 0;
}

.rx-single-sidebar {
  min-width: 0;
  position: sticky;
  top: calc(var(--rx-sticky-offset, 80px) + 1rem);
}

.rx-single-fullwidth .rx-single-layout,
.rx-single-no-sidebar .rx-single-layout {
  display: block;
}

.rx-single-fullwidth .rx-single-main,
.rx-single-no-sidebar .rx-single-main {
  max-width: var(--rx-single-content);
  margin-inline: auto;
}

/* ---------------------------------------------------------
   03. Article Card
--------------------------------------------------------- */

.rx-single-article {
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
  box-shadow: var(--rx-single-shadow-sm);
  overflow: hidden;
}

.rx-single-inner {
  padding: clamp(1.25rem, 4vw, 3rem);
}

.rx-single-article:hover {
  box-shadow: var(--rx-single-shadow-md);
  transition: box-shadow var(--rx-single-transition);
}

/* ---------------------------------------------------------
   04. Breadcrumbs
--------------------------------------------------------- */

.rx-breadcrumbs,
.rank-math-breadcrumb,
.yoast-breadcrumb {
  margin-bottom: 1rem;
  font-size: 0.875rem;
  color: var(--rx-single-muted);
}

.rx-breadcrumbs a,
.rank-math-breadcrumb a,
.yoast-breadcrumb a {
  color: var(--rx-single-secondary);
  text-decoration: none;
}

.rx-breadcrumbs a:hover,
.rank-math-breadcrumb a:hover,
.yoast-breadcrumb a:hover {
  color: var(--rx-single-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------------------------------------------------------
   05. Category Pills
--------------------------------------------------------- */

.rx-single-cats,
.rx-post-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.rx-single-cats a,
.rx-post-categories a,
.single .cat-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 30px;
  padding: 0.35rem 0.75rem;
  background: color-mix(in srgb, var(--rx-single-primary) 9%, transparent);
  color: var(--rx-single-primary);
  border: 1px solid color-mix(in srgb, var(--rx-single-primary) 22%, transparent);
  border-radius: var(--rx-single-radius-full);
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}

.rx-single-cats a:hover,
.rx-post-categories a:hover,
.single .cat-links a:hover {
  background: var(--rx-single-primary);
  color: #ffffff;
  border-color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   06. Single Header
--------------------------------------------------------- */

.rx-single-header {
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
}

.rx-single-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  color: var(--rx-single-primary);
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.rx-single-title,
.single .entry-title {
  margin: 0;
  color: var(--rx-single-text);
  font-family: var(--rx-single-font-heading);
  font-size: clamp(2rem, 5vw, 3.85rem);
  font-weight: 850;
  line-height: 1.08;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.rx-single-subtitle,
.rx-single-excerpt,
.single .entry-summary {
  margin-top: 1rem;
  color: var(--rx-single-text-soft);
  font-size: clamp(1.0625rem, 2vw, 1.25rem);
  line-height: 1.75;
}

.rx-single-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
  align-items: center;
  margin-top: 1.25rem;
  color: var(--rx-single-muted);
  font-size: 0.9375rem;
}

.rx-single-meta a {
  color: inherit;
  text-decoration: none;
}

.rx-single-meta a:hover {
  color: var(--rx-single-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.rx-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.rx-meta-separator {
  width: 4px;
  height: 4px;
  background: var(--rx-single-light);
  border-radius: 50%;
}

/* ---------------------------------------------------------
   07. Author Mini Row
--------------------------------------------------------- */

.rx-single-author-mini {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin-top: 1.25rem;
}

.rx-single-author-mini img,
.rx-author-avatar img,
.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
}

.rx-single-author-mini-name {
  color: var(--rx-single-text);
  font-weight: 800;
}

.rx-single-author-mini-role {
  color: var(--rx-single-muted);
  font-size: 0.875rem;
}

/* ---------------------------------------------------------
   08. Featured Image
--------------------------------------------------------- */

.rx-single-featured {
  margin: 0;
  overflow: hidden;
  background: var(--rx-single-muted-bg);
  border-radius: var(--rx-single-radius-xl);
}

.rx-single-article > .rx-single-featured {
  border-radius: 0;
}

.rx-single-featured img,
.single .post-thumbnail img,
.single .wp-post-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.rx-single-featured.is-cropped img {
  aspect-ratio: 16 / 9;
}

.rx-single-featured figcaption,
.wp-caption-text {
  padding: 0.75rem 1rem;
  color: var(--rx-single-muted);
  font-size: 0.875rem;
  line-height: 1.5;
  text-align: center;
}

/* ---------------------------------------------------------
   09. Article Content Typography
--------------------------------------------------------- */

.rx-single-content,
.single .entry-content {
  color: var(--rx-single-text);
  font-size: clamp(1rem, 1.7vw, 1.0875rem);
  line-height: var(--rx-single-line-height);
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.rx-single-content > *:first-child,
.single .entry-content > *:first-child {
  margin-top: 0;
}

.rx-single-content > *:last-child,
.single .entry-content > *:last-child {
  margin-bottom: 0;
}

.rx-single-content p,
.single .entry-content p {
  margin: 1.15rem 0;
}

.rx-single-content strong,
.single .entry-content strong {
  color: var(--rx-single-text);
  font-weight: 800;
}

.rx-single-content em,
.single .entry-content em {
  color: var(--rx-single-text-soft);
}

.rx-single-content small {
  font-size: 0.875em;
  color: var(--rx-single-muted);
}

.rx-single-content mark {
  padding: 0.1em 0.25em;
  background: color-mix(in srgb, var(--rx-single-accent) 28%, transparent);
  color: var(--rx-single-text);
  border-radius: 0.2em;
}

.rx-single-content a,
.single .entry-content a {
  color: var(--rx-single-secondary);
  font-weight: 650;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.rx-single-content a:hover,
.single .entry-content a:hover {
  color: var(--rx-single-primary);
  text-decoration-thickness: 2px;
}

.rx-single-content a:focus-visible,
.single .entry-content a:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--rx-single-primary) 35%, transparent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------------------------------------------------------
   10. Headings Inside Content
--------------------------------------------------------- */

.rx-single-content h1,
.rx-single-content h2,
.rx-single-content h3,
.rx-single-content h4,
.rx-single-content h5,
.rx-single-content h6,
.single .entry-content h1,
.single .entry-content h2,
.single .entry-content h3,
.single .entry-content h4,
.single .entry-content h5,
.single .entry-content h6 {
  margin: 2.25em 0 0.75em;
  color: var(--rx-single-text);
  font-family: var(--rx-single-font-heading);
  font-weight: 850;
  line-height: var(--rx-single-heading-line-height);
  letter-spacing: -0.025em;
  scroll-margin-top: calc(var(--rx-sticky-offset, 80px) + 1.5rem);
  text-wrap: balance;
}

.rx-single-content h2,
.single .entry-content h2 {
  position: relative;
  padding-top: 0.4rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--rx-single-border);
  font-size: clamp(1.55rem, 3vw, 2.25rem);
}

.rx-single-content h2::before,
.single .entry-content h2::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 72px;
  height: 3px;
  background: linear-gradient(90deg, var(--rx-single-primary), var(--rx-single-secondary));
  border-radius: var(--rx-single-radius-full);
}

.rx-single-content h3,
.single .entry-content h3 {
  font-size: clamp(1.3rem, 2.4vw, 1.75rem);
}

.rx-single-content h4,
.single .entry-content h4 {
  font-size: clamp(1.15rem, 2vw, 1.35rem);
}

.rx-single-content h5,
.single .entry-content h5 {
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.rx-single-content h6,
.single .entry-content h6 {
  font-size: 0.95rem;
  color: var(--rx-single-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ---------------------------------------------------------
   11. Lists
--------------------------------------------------------- */

.rx-single-content ul,
.rx-single-content ol,
.single .entry-content ul,
.single .entry-content ol {
  margin: 1.15rem 0 1.15rem 1.35rem;
  padding: 0;
}

.rx-single-content li,
.single .entry-content li {
  margin: 0.45rem 0;
  padding-left: 0.25rem;
}

.rx-single-content li::marker,
.single .entry-content li::marker {
  color: var(--rx-single-primary);
  font-weight: 800;
}

.rx-single-content ul ul,
.rx-single-content ol ol,
.rx-single-content ul ol,
.rx-single-content ol ul {
  margin-top: 0.45rem;
  margin-bottom: 0.45rem;
}

/* Advanced medical list style */
.rx-medical-list,
.rx-check-list,
.rx-warning-list {
  margin-left: 0 !important;
  list-style: none;
}

.rx-medical-list li,
.rx-check-list li,
.rx-warning-list li {
  position: relative;
  padding-left: 2rem;
}

.rx-medical-list li::before,
.rx-check-list li::before,
.rx-warning-list li::before {
  position: absolute;
  left: 0;
  top: 0.1em;
  display: inline-grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 900;
}

.rx-check-list li::before {
  content: "✓";
  background: color-mix(in srgb, var(--rx-single-success) 12%, transparent);
  color: var(--rx-single-success);
}

.rx-warning-list li::before {
  content: "!";
  background: color-mix(in srgb, var(--rx-single-warning) 14%, transparent);
  color: var(--rx-single-warning);
}

.rx-medical-list li::before {
  content: "+";
  background: color-mix(in srgb, var(--rx-single-primary) 12%, transparent);
  color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   12. Blockquotes
--------------------------------------------------------- */

.rx-single-content blockquote,
.single .entry-content blockquote,
.wp-block-quote {
  position: relative;
  margin: 2rem 0;
  padding: 1.35rem 1.5rem 1.35rem 1.75rem;
  background: color-mix(in srgb, var(--rx-single-primary) 6%, var(--rx-single-surface));
  border: 1px solid color-mix(in srgb, var(--rx-single-primary) 18%, transparent);
  border-left: 5px solid var(--rx-single-primary);
  border-radius: var(--rx-single-radius-lg);
  color: var(--rx-single-text-soft);
  font-size: 1.05em;
  line-height: 1.75;
}

.rx-single-content blockquote p,
.single .entry-content blockquote p {
  margin: 0.75rem 0;
}

.rx-single-content blockquote cite,
.single .entry-content blockquote cite {
  display: block;
  margin-top: 0.75rem;
  color: var(--rx-single-muted);
  font-size: 0.9rem;
  font-style: normal;
  font-weight: 700;
}

/* ---------------------------------------------------------
   13. Code, Pre, Keyboard
--------------------------------------------------------- */

.rx-single-content code,
.single .entry-content code {
  padding: 0.15em 0.35em;
  background: var(--rx-single-muted-bg);
  color: #be123c;
  border: 1px solid var(--rx-single-border);
  border-radius: 5px;
  font-family: var(--rx-single-font-code);
  font-size: 0.9em;
}

.rx-single-content pre,
.single .entry-content pre,
.wp-block-code {
  margin: 1.5rem 0;
  padding: 1.25rem;
  overflow-x: auto;
  background: #0f172a;
  color: #e2e8f0;
  border-radius: var(--rx-single-radius-lg);
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-single-content pre code,
.single .entry-content pre code {
  padding: 0;
  background: transparent;
  color: inherit;
  border: 0;
}

.rx-single-content kbd {
  display: inline-block;
  padding: 0.15em 0.45em;
  background: var(--rx-single-text);
  color: var(--rx-single-bg);
  border-radius: 5px;
  font-family: var(--rx-single-font-code);
  font-size: 0.85em;
}

/* ---------------------------------------------------------
   14. Tables
--------------------------------------------------------- */

.rx-single-content table,
.single .entry-content table {
  width: 100%;
  margin: 1.75rem 0;
  border-collapse: collapse;
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-md);
  overflow: hidden;
  font-size: 0.95rem;
}

.rx-single-content table th,
.rx-single-content table td,
.single .entry-content table th,
.single .entry-content table td {
  padding: 0.85rem 1rem;
  border: 1px solid var(--rx-single-border);
  text-align: left;
  vertical-align: top;
}

.rx-single-content table th,
.single .entry-content table th {
  background: var(--rx-single-muted-bg);
  color: var(--rx-single-text);
  font-weight: 800;
}

.rx-single-content table tr:nth-child(even) td,
.single .entry-content table tr:nth-child(even) td {
  background: color-mix(in srgb, var(--rx-single-muted-bg) 55%, transparent);
}

.rx-table-scroll {
  width: 100%;
  overflow-x: auto;
  margin: 1.75rem 0;
  border-radius: var(--rx-single-radius-md);
}

.rx-table-scroll table {
  margin: 0;
  min-width: 680px;
}

/* ---------------------------------------------------------
   15. Images, Gallery, Figure
--------------------------------------------------------- */

.rx-single-content img,
.single .entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--rx-single-radius-md);
}

.rx-single-content figure,
.single .entry-content figure {
  margin: 1.75rem 0;
}

.rx-single-content figcaption,
.single .entry-content figcaption {
  margin-top: 0.6rem;
  color: var(--rx-single-muted);
  font-size: 0.875rem;
  line-height: 1.55;
  text-align: center;
}

.rx-single-content .wp-block-image img,
.single .entry-content .wp-block-image img {
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-single-content .wp-block-gallery,
.single .entry-content .wp-block-gallery {
  gap: 1rem;
}

/* ---------------------------------------------------------
   16. WordPress Alignments
--------------------------------------------------------- */

.rx-single-content .alignleft,
.single .entry-content .alignleft {
  float: left;
  margin: 0.4rem 1.25rem 1rem 0;
}

.rx-single-content .alignright,
.single .entry-content .alignright {
  float: right;
  margin: 0.4rem 0 1rem 1.25rem;
}

.rx-single-content .aligncenter,
.single .entry-content .aligncenter {
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.rx-single-content .alignwide,
.single .entry-content .alignwide {
  width: min(100vw - 32px, 960px);
  max-width: none;
  margin-left: 50%;
  transform: translateX(-50%);
}

.rx-single-content .alignfull,
.single .entry-content .alignfull {
  width: 100vw;
  max-width: none;
  margin-left: 50%;
  transform: translateX(-50%);
}

/* ---------------------------------------------------------
   17. WordPress Blocks
--------------------------------------------------------- */

.wp-block-separator {
  margin: 2.5rem auto;
  border: 0;
  border-top: 1px solid var(--rx-single-border);
}

.wp-block-separator.is-style-wide {
  width: 100%;
}

.wp-block-separator.is-style-dots {
  border: 0;
  color: var(--rx-single-muted);
}

.wp-block-pullquote {
  margin: 2rem 0;
  padding: 1.5rem;
  border-top: 4px solid var(--rx-single-primary);
  border-bottom: 4px solid var(--rx-single-primary);
  color: var(--rx-single-text-soft);
}

.wp-block-button .wp-block-button__link,
.rx-single-content .button,
.rx-single-content .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.75rem 1.15rem;
  background: var(--rx-single-primary);
  color: #ffffff;
  border-radius: var(--rx-single-radius-full);
  font-weight: 800;
  text-decoration: none;
  box-shadow: var(--rx-single-shadow-sm);
}

.wp-block-button .wp-block-button__link:hover,
.rx-single-content .button:hover,
.rx-single-content .btn:hover {
  background: var(--rx-single-primary-hover);
  color: #ffffff;
  text-decoration: none;
}

.wp-block-file {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  padding: 1rem;
  background: var(--rx-single-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-md);
}

.wp-block-file .wp-block-file__button {
  background: var(--rx-single-primary);
  color: #ffffff;
  border-radius: var(--rx-single-radius-full);
  font-weight: 800;
}

/* ---------------------------------------------------------
   18. Medical Article Special Boxes
--------------------------------------------------------- */

.rx-note,
.rx-tip,
.rx-alert,
.rx-warning,
.rx-danger,
.rx-success,
.rx-info,
.rx-medical-summary,
.rx-clinical-note {
  position: relative;
  margin: 1.75rem 0;
  padding: 1.15rem 1.25rem;
  border: 1px solid var(--rx-single-border);
  border-left-width: 5px;
  border-radius: var(--rx-single-radius-lg);
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-note > :first-child,
.rx-tip > :first-child,
.rx-alert > :first-child,
.rx-warning > :first-child,
.rx-danger > :first-child,
.rx-success > :first-child,
.rx-info > :first-child,
.rx-medical-summary > :first-child,
.rx-clinical-note > :first-child {
  margin-top: 0;
}

.rx-note > :last-child,
.rx-tip > :last-child,
.rx-alert > :last-child,
.rx-warning > :last-child,
.rx-danger > :last-child,
.rx-success > :last-child,
.rx-info > :last-child,
.rx-medical-summary > :last-child,
.rx-clinical-note > :last-child {
  margin-bottom: 0;
}

.rx-note {
  background: color-mix(in srgb, var(--rx-single-secondary) 6%, var(--rx-single-surface));
  border-left-color: var(--rx-single-secondary);
}

.rx-tip,
.rx-success {
  background: color-mix(in srgb, var(--rx-single-success) 7%, var(--rx-single-surface));
  border-left-color: var(--rx-single-success);
}

.rx-warning,
.rx-alert {
  background: color-mix(in srgb, var(--rx-single-warning) 8%, var(--rx-single-surface));
  border-left-color: var(--rx-single-warning);
}

.rx-danger {
  background: color-mix(in srgb, var(--rx-single-danger) 7%, var(--rx-single-surface));
  border-left-color: var(--rx-single-danger);
}

.rx-info,
.rx-clinical-note {
  background: color-mix(in srgb, var(--rx-single-info) 7%, var(--rx-single-surface));
  border-left-color: var(--rx-single-info);
}

.rx-medical-summary {
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--rx-single-primary) 8%, var(--rx-single-surface)),
    color-mix(in srgb, var(--rx-single-secondary) 6%, var(--rx-single-surface))
  );
  border-left-color: var(--rx-single-primary);
}

.rx-box-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.5rem;
  color: var(--rx-single-text);
  font-weight: 850;
}

/* ---------------------------------------------------------
   19. Key Takeaways Box
--------------------------------------------------------- */

.rx-key-takeaways {
  margin: 2rem 0;
  padding: 1.5rem;
  background: var(--rx-single-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
}

.rx-key-takeaways-title {
  margin: 0 0 1rem;
  color: var(--rx-single-text);
  font-size: 1.25rem;
  font-weight: 850;
}

.rx-key-takeaways ul {
  margin-left: 0 !important;
  list-style: none;
}

.rx-key-takeaways li {
  position: relative;
  padding-left: 2rem;
}

.rx-key-takeaways li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0.08em;
  display: inline-grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
  background: var(--rx-single-primary);
  color: #ffffff;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 900;
}

/* ---------------------------------------------------------
   20. Table of Contents
--------------------------------------------------------- */

.rx-toc {
  margin: 1.5rem 0 2rem;
  padding: 1.25rem;
  background: var(--rx-single-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
}

.rx-toc-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 0.85rem;
  color: var(--rx-single-text);
  font-size: 1rem;
  font-weight: 850;
}

.rx-toc-list,
.rx-toc ol,
.rx-toc ul {
  margin: 0 !important;
  padding: 0;
  list-style: none;
}

.rx-toc li {
  margin: 0;
  padding: 0;
}

.rx-toc a {
  display: flex;
  gap: 0.6rem;
  padding: 0.55rem 0;
  color: var(--rx-single-text-soft);
  border-bottom: 1px dashed var(--rx-single-border);
  font-size: 0.9375rem;
  font-weight: 650;
  line-height: 1.45;
  text-decoration: none;
}

.rx-toc a:hover {
  color: var(--rx-single-primary);
}

.rx-toc li:last-child a {
  border-bottom: 0;
}

.rx-toc .toc-level-3 a,
.rx-toc .rx-toc-level-3 a {
  padding-left: 1rem;
  font-size: 0.9rem;
}

.rx-toc .toc-level-4 a,
.rx-toc .rx-toc-level-4 a {
  padding-left: 2rem;
  font-size: 0.875rem;
}

/* ---------------------------------------------------------
   21. Sidebar Widgets
--------------------------------------------------------- */

.rx-single-sidebar .widget,
.rx-single-widget {
  margin-bottom: 1.25rem;
  padding: 1.25rem;
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-single-sidebar .widget-title,
.rx-single-widget-title {
  margin: 0 0 1rem;
  color: var(--rx-single-text);
  font-size: 1.05rem;
  font-weight: 850;
  line-height: 1.3;
}

.rx-single-sidebar ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rx-single-sidebar li {
  margin: 0;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--rx-single-border);
}

.rx-single-sidebar li:last-child {
  border-bottom: 0;
}

.rx-single-sidebar a {
  color: var(--rx-single-text-soft);
  font-weight: 650;
  text-decoration: none;
}

.rx-single-sidebar a:hover {
  color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   22. Sticky Sidebar TOC
--------------------------------------------------------- */

.rx-sidebar-toc {
  max-height: calc(100vh - var(--rx-sticky-offset, 80px) - 2rem);
  overflow-y: auto;
  scrollbar-width: thin;
}

.rx-sidebar-toc::-webkit-scrollbar {
  width: 8px;
}

.rx-sidebar-toc::-webkit-scrollbar-thumb {
  background: var(--rx-single-border-strong);
  border-radius: var(--rx-single-radius-full);
}

/* ---------------------------------------------------------
   23. Tags
--------------------------------------------------------- */

.rx-single-tags,
.single .tags-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rx-single-border);
}

.rx-single-tags-title {
  flex-basis: 100%;
  color: var(--rx-single-text);
  font-weight: 850;
}

.rx-single-tags a,
.single .tags-links a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0.35rem 0.75rem;
  background: var(--rx-single-soft);
  color: var(--rx-single-text-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-full);
  font-size: 0.8125rem;
  font-weight: 750;
  text-decoration: none;
}

.rx-single-tags a:hover,
.single .tags-links a:hover {
  background: var(--rx-single-primary);
  color: #ffffff;
  border-color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   24. Share Buttons
--------------------------------------------------------- */

.rx-share {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  margin-top: 1.5rem;
}

.rx-share-title {
  color: var(--rx-single-text);
  font-weight: 850;
}

.rx-share a,
.rx-share button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 0.85rem;
  background: var(--rx-single-soft);
  color: var(--rx-single-text-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-full);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.rx-share a:hover,
.rx-share button:hover {
  background: var(--rx-single-primary);
  color: #ffffff;
  border-color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   25. Author Box
--------------------------------------------------------- */

.rx-author-box {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1rem;
  margin-top: 2rem;
  padding: 1.5rem;
  background: var(--rx-single-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
}

.rx-author-box-avatar img {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  object-fit: cover;
}

.rx-author-box-title {
  margin: 0 0 0.35rem;
  color: var(--rx-single-text);
  font-size: 1.2rem;
  font-weight: 850;
}

.rx-author-box-bio {
  margin: 0;
  color: var(--rx-single-text-soft);
  font-size: 0.95rem;
  line-height: 1.7;
}

.rx-author-box-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.rx-author-box-links a {
  color: var(--rx-single-primary);
  font-size: 0.875rem;
  font-weight: 800;
  text-decoration: none;
}

.rx-author-box-links a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------------------------------------------------------
   26. Post Navigation
--------------------------------------------------------- */

.rx-post-nav,
.post-navigation {
  margin-top: 2rem;
}

.rx-post-nav-links,
.post-navigation .nav-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.rx-post-nav a,
.post-navigation a {
  display: block;
  min-height: 110px;
  padding: 1.25rem;
  background: var(--rx-single-surface);
  color: var(--rx-single-text);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
  text-decoration: none;
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-post-nav a:hover,
.post-navigation a:hover {
  border-color: color-mix(in srgb, var(--rx-single-primary) 45%, var(--rx-single-border));
  box-shadow: var(--rx-single-shadow-md);
}

.rx-post-nav-label,
.nav-subtitle {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--rx-single-muted);
  font-size: 0.8125rem;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.rx-post-nav-title,
.nav-title {
  display: block;
  color: var(--rx-single-text);
  font-weight: 850;
  line-height: 1.4;
}

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

/* ---------------------------------------------------------
   27. Related Posts
--------------------------------------------------------- */

.rx-related-posts {
  margin-top: var(--rx-single-section-gap);
}

.rx-section-title {
  margin: 0 0 1.25rem;
  color: var(--rx-single-text);
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 850;
  line-height: 1.25;
  letter-spacing: -0.025em;
}

.rx-related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.rx-related-card {
  overflow: hidden;
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
  box-shadow: var(--rx-single-shadow-sm);
}

.rx-related-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--rx-single-shadow-md);
  transition: transform var(--rx-single-transition), box-shadow var(--rx-single-transition);
}

.rx-related-thumb {
  display: block;
  background: var(--rx-single-muted-bg);
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.rx-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rx-related-body {
  padding: 1rem;
}

.rx-related-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 850;
  line-height: 1.4;
}

.rx-related-title a {
  color: var(--rx-single-text);
  text-decoration: none;
}

.rx-related-title a:hover {
  color: var(--rx-single-primary);
}

.rx-related-meta {
  margin-top: 0.6rem;
  color: var(--rx-single-muted);
  font-size: 0.8125rem;
}

/* ---------------------------------------------------------
   28. Comments
--------------------------------------------------------- */

.rx-comments,
.comments-area {
  margin-top: var(--rx-single-section-gap);
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-xl);
  box-shadow: var(--rx-single-shadow-sm);
}

.comments-title,
.comment-reply-title {
  margin: 0 0 1.25rem;
  color: var(--rx-single-text);
  font-size: clamp(1.35rem, 3vw, 1.8rem);
  font-weight: 850;
}

.comment-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.comment-list .children {
  margin: 1rem 0 0 2rem;
  padding: 0;
  list-style: none;
}

.comment-body {
  margin-bottom: 1rem;
  padding: 1.1rem;
  background: var(--rx-single-soft);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-lg);
}

.comment-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 0.75rem;
  color: var(--rx-single-muted);
  font-size: 0.875rem;
}

.comment-author {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--rx-single-text);
  font-weight: 850;
}

.comment-author .avatar {
  width: 42px;
  height: 42px;
}

.comment-content {
  color: var(--rx-single-text-soft);
  line-height: 1.7;
}

.reply a,
.comment-reply-link {
  display: inline-flex;
  margin-top: 0.75rem;
  color: var(--rx-single-primary);
  font-size: 0.875rem;
  font-weight: 850;
  text-decoration: none;
}

.reply a:hover,
.comment-reply-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------------------------------------------------------
   29. Comment Form
--------------------------------------------------------- */

.comment-form {
  display: grid;
  gap: 1rem;
}

.comment-form label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--rx-single-text);
  font-weight: 800;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  min-height: 46px;
  padding: 0.75rem 0.9rem;
  background: var(--rx-single-bg);
  color: var(--rx-single-text);
  border: 1px solid var(--rx-single-border-strong);
  border-radius: var(--rx-single-radius-md);
  font: inherit;
  outline: none;
}

.comment-form textarea {
  min-height: 160px;
  resize: vertical;
}

.comment-form input:focus,
.comment-form textarea:focus {
  border-color: var(--rx-single-primary);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--rx-single-primary) 16%, transparent);
}

.form-submit .submit,
.comment-form input[type="submit"] {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 46px;
  padding: 0.75rem 1.4rem;
  background: var(--rx-single-primary);
  color: #ffffff;
  border: 0;
  border-radius: var(--rx-single-radius-full);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.form-submit .submit:hover,
.comment-form input[type="submit"]:hover {
  background: var(--rx-single-primary-hover);
}

/* ---------------------------------------------------------
   30. Pagination Inside Single Post
--------------------------------------------------------- */

.page-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rx-single-border);
  font-weight: 850;
}

.page-links a,
.page-links .post-page-numbers {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  height: 38px;
  padding: 0 0.75rem;
  background: var(--rx-single-soft);
  color: var(--rx-single-text);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-full);
  text-decoration: none;
}

.page-links .current,
.page-links a:hover {
  background: var(--rx-single-primary);
  color: #ffffff;
  border-color: var(--rx-single-primary);
}

/* ---------------------------------------------------------
   31. Reading Progress Bar
--------------------------------------------------------- */

.rx-reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: var(--rx-reading-progress, 0%);
  height: 4px;
  background: linear-gradient(90deg, var(--rx-single-primary), var(--rx-single-secondary), var(--rx-single-accent));
  transform-origin: left center;
}

/* ---------------------------------------------------------
   32. Floating Action Buttons
--------------------------------------------------------- */

.rx-floating-actions {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 50;
  display: grid;
  gap: 0.6rem;
}

.rx-floating-actions a,
.rx-floating-actions button,
.rx-back-to-top {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  background: var(--rx-single-primary);
  color: #ffffff;
  border: 0;
  border-radius: 50%;
  box-shadow: var(--rx-single-shadow-md);
  text-decoration: none;
  cursor: pointer;
}

.rx-floating-actions a:hover,
.rx-floating-actions button:hover,
.rx-back-to-top:hover {
  background: var(--rx-single-primary-hover);
  transform: translateY(-2px);
}

/* ---------------------------------------------------------
   33. Ads / Disclaimer Areas
--------------------------------------------------------- */

.rx-single-ad,
.rx-medical-disclaimer,
.rx-editorial-disclaimer {
  margin: 1.75rem 0;
  padding: 1rem;
  background: var(--rx-single-soft);
  border: 1px dashed var(--rx-single-border-strong);
  border-radius: var(--rx-single-radius-lg);
  color: var(--rx-single-muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

.rx-single-ad {
  display: grid;
  place-items: center;
  min-height: 110px;
  text-align: center;
}

.rx-disclaimer-title {
  margin: 0 0 0.45rem;
  color: var(--rx-single-text);
  font-weight: 850;
}

/* ---------------------------------------------------------
   34. Medical Schema Visual Helpers
--------------------------------------------------------- */

.rx-reviewed-by,
.rx-fact-checked,
.rx-last-updated {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  padding: 0.45rem 0.75rem;
  background: color-mix(in srgb, var(--rx-single-success) 9%, transparent);
  color: var(--rx-single-success);
  border: 1px solid color-mix(in srgb, var(--rx-single-success) 24%, transparent);
  border-radius: var(--rx-single-radius-full);
  font-size: 0.8125rem;
  font-weight: 850;
}

.rx-last-updated {
  background: color-mix(in srgb, var(--rx-single-info) 9%, transparent);
  color: var(--rx-single-info);
  border-color: color-mix(in srgb, var(--rx-single-info) 24%, transparent);
}

/* ---------------------------------------------------------
   35. FAQ Block
--------------------------------------------------------- */

.rx-faq {
  margin: 2rem 0;
}

.rx-faq-item {
  margin-bottom: 0.75rem;
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-lg);
  overflow: hidden;
}

.rx-faq-question {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 1rem 1.15rem;
  background: var(--rx-single-soft);
  color: var(--rx-single-text);
  border: 0;
  font: inherit;
  font-weight: 850;
  text-align: left;
  cursor: pointer;
}

.rx-faq-answer {
  padding: 1rem 1.15rem;
  color: var(--rx-single-text-soft);
  line-height: 1.75;
}

/* Native details FAQ */
.rx-single-content details,
.single .entry-content details {
  margin: 1rem 0;
  background: var(--rx-single-surface);
  border: 1px solid var(--rx-single-border);
  border-radius: var(--rx-single-radius-lg);
  overflow: hidden;
}

.rx-single-content summary,
.single .entry-content summary {
  padding: 1rem 1.15rem;
  background: var(--rx-single-soft);
  color: var(--rx-single-text);
  font-weight: 850;
  cursor: pointer;
}

.rx-single-content details > *:not(summary),
.single .entry-content details > *:not(summary) {
  padding-inline: 1.15rem;
}

/* ---------------------------------------------------------
   36. Forms Inside Article
--------------------------------------------------------- */

.rx-single-content input,
.rx-single-content select,
.rx-single-content textarea {
  max-width: 100%;
  padding: 0.75rem 0.9rem;
  background: var(--rx-single-bg);
  color: var(--rx-single-text);
  border: 1px solid var(--rx-single-border-strong);
  border-radius: var(--rx-single-radius-md);
  font: inherit;
}

.rx-single-content input:focus,
.rx-single-content select:focus,
.rx-single-content textarea:focus {
  outline: none;
  border-color: var(--rx-single-primary);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--rx-single-primary) 16%, transparent);
}

/* ---------------------------------------------------------
   37. Search Box Widget
--------------------------------------------------------- */

.rx-single-sidebar .search-form,
.rx-search-form {
  display: flex;
  gap: 0.5rem;
}

.rx-single-sidebar .search-field,
.rx-search-field {
  min-width: 0;
  flex: 1;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--rx-single-border-strong);
  border-radius: var(--rx-single-radius-full);
  font: inherit;
}

.rx-single-sidebar .search-submit,
.rx-search-submit {
  padding: 0.75rem 1rem;
  background: var(--rx-single-primary);
  color: #ffffff;
  border: 0;
  border-radius: var(--rx-single-radius-full);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

/* ---------------------------------------------------------
   38. Accessibility Helpers
--------------------------------------------------------- */

.rx-sr-only,
.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.rx-sr-only:focus,
.screen-reader-text:focus {
  position: fixed !important;
  top: 1rem;
  left: 1rem;
  z-index: 100000;
  width: auto;
  height: auto;
  padding: 0.75rem 1rem;
  background: var(--rx-single-primary);
  color: #ffffff;
  border-radius: var(--rx-single-radius-md);
  clip-path: none;
  white-space: normal;
}

.rx-focus-ring:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--rx-single-primary) 35%, transparent);
  outline-offset: 3px;
}

/* ---------------------------------------------------------
   39. Utility Classes
--------------------------------------------------------- */

.rx-text-center {
  text-align: center;
}

.rx-text-muted {
  color: var(--rx-single-muted);
}

.rx-mt-0 {
  margin-top: 0 !important;
}

.rx-mb-0 {
  margin-bottom: 0 !important;
}

.rx-rounded {
  border-radius: var(--rx-single-radius-lg);
}

.rx-shadow {
  box-shadow: var(--rx-single-shadow-md);
}

.rx-border {
  border: 1px solid var(--rx-single-border);
}

.rx-soft-bg {
  background: var(--rx-single-soft);
}

.rx-hidden {
  display: none !important;
}

/* ---------------------------------------------------------
   40. Dark Mode Support
--------------------------------------------------------- */

[data-theme="dark"] {
  --rx-single-bg: #020617;
  --rx-single-surface: #0f172a;
  --rx-single-soft: #111827;
  --rx-single-muted-bg: #1e293b;

  --rx-single-text: #f8fafc;
  --rx-single-text-soft: #dbeafe;
  --rx-single-muted: #94a3b8;
  --rx-single-light: #64748b;

  --rx-single-border: #1e293b;
  --rx-single-border-strong: #334155;

  --rx-single-primary: #2dd4bf;
  --rx-single-primary-hover: #14b8a6;
  --rx-single-secondary: #38bdf8;
}

@media (prefers-color-scheme: dark) {
  body.rx-auto-dark {
    --rx-single-bg: #020617;
    --rx-single-surface: #0f172a;
    --rx-single-soft: #111827;
    --rx-single-muted-bg: #1e293b;

    --rx-single-text: #f8fafc;
    --rx-single-text-soft: #dbeafe;
    --rx-single-muted: #94a3b8;
    --rx-single-light: #64748b;

    --rx-single-border: #1e293b;
    --rx-single-border-strong: #334155;

    --rx-single-primary: #2dd4bf;
    --rx-single-primary-hover: #14b8a6;
    --rx-single-secondary: #38bdf8;
  }
}

/* ---------------------------------------------------------
   41. Reduced Motion
--------------------------------------------------------- */

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

/* ---------------------------------------------------------
   42. Responsive: Tablet
--------------------------------------------------------- */

@media (max-width: 1024px) {
  .rx-single-layout {
    grid-template-columns: 1fr;
  }

  .rx-single-sidebar {
    position: static;
  }

  .rx-related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rx-single-content .alignwide,
  .single .entry-content .alignwide {
    width: 100%;
    margin-left: 0;
    transform: none;
  }
}

/* ---------------------------------------------------------
   43. Responsive: Mobile
--------------------------------------------------------- */

@media (max-width: 700px) {
  .rx-single-wrap {
    width: min(100% - 20px, var(--rx-single-container));
    padding-block: 1rem 2rem;
  }

  .rx-single-inner {
    padding: 1rem;
  }

  .rx-single-article,
  .rx-comments,
  .rx-single-sidebar .widget,
  .rx-single-widget {
    border-radius: var(--rx-single-radius-lg);
  }

  .rx-single-title,
  .single .entry-title {
    font-size: clamp(1.8rem, 9vw, 2.6rem);
  }

  .rx-single-meta {
    display: grid;
    gap: 0.5rem;
  }

  .rx-meta-separator {
    display: none;
  }

  .rx-author-box {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .rx-author-box-avatar img {
    margin-inline: auto;
  }

  .rx-post-nav-links,
  .post-navigation .nav-links,
  .rx-related-grid {
    grid-template-columns: 1fr;
  }

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

  .comment-list .children {
    margin-left: 1rem;
  }

  .rx-floating-actions {
    right: 0.75rem;
    bottom: 0.75rem;
  }

  .rx-floating-actions a,
  .rx-floating-actions button,
  .rx-back-to-top {
    width: 42px;
    height: 42px;
  }

  .rx-single-content .alignleft,
  .rx-single-content .alignright,
  .single .entry-content .alignleft,
  .single .entry-content .alignright {
    float: none;
    display: block;
    margin: 1rem auto;
  }

  .rx-single-content .alignfull,
  .single .entry-content .alignfull {
    width: calc(100% + 2rem);
    margin-left: -1rem;
    transform: none;
  }
}

/* ---------------------------------------------------------
   44. Extra Small Devices
--------------------------------------------------------- */

@media (max-width: 420px) {
  .rx-single-content,
  .single .entry-content {
    font-size: 1rem;
  }

  .rx-single-content table th,
  .rx-single-content table td,
  .single .entry-content table th,
  .single .entry-content table td {
    padding: 0.65rem;
  }

  .rx-share a,
  .rx-share button {
    width: 38px;
    padding: 0;
  }
}

/* ---------------------------------------------------------
   45. Print Style
--------------------------------------------------------- */

@media print {
  :root {
    --rx-single-bg: #ffffff;
    --rx-single-surface: #ffffff;
    --rx-single-soft: #ffffff;
    --rx-single-text: #000000;
    --rx-single-text-soft: #111111;
    --rx-single-muted: #444444;
    --rx-single-border: #cccccc;
  }

  body {
    background: #ffffff !important;
    color: #000000 !important;
  }

  .rx-single-wrap {
    width: 100%;
    padding: 0;
  }

  .rx-single-layout {
    display: block;
  }

  .rx-single-article,
  .rx-comments,
  .rx-single-sidebar .widget,
  .rx-single-widget {
    border: 0;
    box-shadow: none;
  }

  .rx-single-inner {
    padding: 0;
  }

  .rx-single-sidebar,
  .rx-share,
  .rx-floating-actions,
  .rx-back-to-top,
  .rx-reading-progress,
  .rx-single-ad,
  .comments-area,
  .rx-related-posts,
  .post-navigation,
  .rx-post-nav {
    display: none !important;
  }

  .rx-single-content a,
  .single .entry-content a {
    color: #000000;
    text-decoration: underline;
  }

  .rx-single-content a[href]::after,
  .single .entry-content a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
    color: #444444;
  }

  .rx-single-content h2,
  .single .entry-content h2 {
    page-break-after: avoid;
  }

  .rx-single-content img,
  .single .entry-content img {
    max-width: 100% !important;
    box-shadow: none !important;
  }
}

For functions.php, enqueue it like this:

function rx_theme_single_assets() {
    if ( is_single() ) {
        wp_enqueue_style(
            'rx-single',
            get_template_directory_uri() . '/assets/css/rx-single.css',
            array(),
            wp_get_theme()->get( 'Version' )
        );
    }
}
add_action( 'wp_enqueue_scripts', 'rx_theme_single_assets' );

This file is safe as your advanced single post CSS base. Later you can split it into smaller files like:

assets/css/single/
├── single-layout.css
├── single-content.css
├── single-sidebar.css
├── single-comments.css
├── single-responsive.css
└── single-print.css

Leave a Reply

Your email address will not be published. Required fields are marked *