/*
 * TrailPost v4 — Glossier-inspired Editorial Magazine Theme
 * Version: 4.0.0
 * Author: RSOC Platform Team
 * License: GPL v2
 *
 * Design reference: glossier.cmsmasters.studio
 * Clean, minimal, sans-serif, flat cards, hover-only shadows,
 * white/light-gray backgrounds, primary colour used sparingly.
 *
 * Table of Contents:
 *  1.  CSS Custom Properties
 *  2.  Reset & Base
 *  3.  Typography
 *  4.  Layout & Container
 *  5.  Skip Link
 *  6.  Reading Progress Bar
 *  7.  Top Bar & Ticker
 *  8.  Header & Navigation
 *  9.  Search Overlay
 * 10.  Mobile Navigation (Drawer)
 * 11.  Hero Section
 * 12.  Section Headers
 * 13.  Card — Standard
 * 14.  Card — Featured / Overlay
 * 15.  Card — Horizontal
 * 16.  Card — Video
 * 17.  Card — Mini (Trending)
 * 18.  Card — Related
 * 19.  Homepage Sections
 * 20.  Single Post — Article Header
 * 21.  Single Post — Breadcrumbs
 * 22.  Single Post — Content Body
 * 23.  Single Post — Drop Cap
 * 24.  Single Post — Content Typography
 * 25.  Single Post — Table of Contents
 * 26.  Single Post — Social Share
 * 27.  Single Post — Inline Newsletter
 * 28.  Single Post — Tags
 * 29.  Single Post — Author Bio
 * 30.  Single Post — Post Navigation
 * 31.  Single Post — Related Posts
 * 32.  Single Post — Comments
 * 33.  Sidebar
 * 34.  Archive Page
 * 35.  Search Page
 * 36.  404 Page
 * 37.  Page Template
 * 38.  Pagination
 * 39.  Back-to-Top
 * 40.  Footer
 * 41.  Ad Zones
 * 42.  WordPress Core Overrides
 * 43.  Focus & Accessibility
 * 44.  Reduced Motion
 * 45.  High Contrast
 * 46.  Print Styles
 * 47.  Responsive — 1024px
 * 48.  Responsive — 768px / 480px / 375px
 * 49.  Dark Mode
 * 50.  PHP Template Class Aliases (49 missing selectors)
 */


/* ==========================================================================
   1. CSS Custom Properties
   ========================================================================== */

:root {
  /* Identity — overridden per-site via inline style from functions.php */
  --tp-primary: #E8443A;
  --tp-primary-rgb: 232, 68, 58;

  /* Neutrals (shared across all skins) */
  --tp-secondary: #1f1f1f;
  --tp-text: #3e3e3e;
  --tp-text-light: #666666;
  --tp-text-muted: #6B7280;
  --tp-bg: #f5f5f5;
  --tp-bg-alt: #ffffff;
  --tp-border: #e8e8e8;
  --tp-border-light: #f0f0f0;

  /* Typography */
  --tp-font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --tp-font-heading: 'Gloock', Georgia, serif;
  --tp-font-body: 'PT Serif', Georgia, serif;
  --tp-font-ui: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  --tp-font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Sizes */
  --tp-fs-xs: 0.6875rem;
  --tp-fs-sm: 0.8125rem;
  --tp-fs-base: 1rem;
  --tp-fs-md: 1.125rem;
  --tp-fs-lg: 1.25rem;
  --tp-fs-xl: 1.5rem;
  --tp-fs-2xl: 2rem;
  --tp-fs-3xl: 2.25rem;
  --tp-fs-4xl: 2.625rem;
  --tp-fs-hero: clamp(2rem, 4vw + 1rem, 3rem);

  /* Spacing */
  --tp-container: 1280px;
  --tp-pad: 30px;
  --tp-gap: 24px;
  --tp-gap-sm: 16px;
  --tp-gap-lg: 32px;
  --tp-section-gap: 80px;

  /* Shapes */
  --tp-radius: 6px;
  --tp-radius-md: 12px;
  --tp-radius-pill: 30px;

  /* Shadows (minimal — Glossier style) */
  --tp-shadow: none;
  --tp-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.08);
  --tp-shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.12);

  /* Transitions */
  --tp-ease: 0.3s ease-in-out;
  --tp-ease-fast: 0.2s ease-in-out;
  --tp-spring: 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Z-index */
  --tp-z-ticker: 10;
  --tp-z-header: 100;
  --tp-z-drawer: 1000;
  --tp-z-overlay: 1100;
  --tp-z-top: 9999;
}


/* ==========================================================================
   2. Reset & Base
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 80px;
}

body {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  line-height: 1.6;
  color: var(--tp-text);
  background-color: var(--tp-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--tp-ease);
}

ul,
ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

::selection {
  background-color: rgba(var(--tp-primary-rgb), 0.15);
  color: var(--tp-secondary);
}

::-moz-selection {
  background-color: rgba(var(--tp-primary-rgb), 0.15);
  color: var(--tp-secondary);
}


/* ==========================================================================
   3. Typography
   ========================================================================== */

/* Display headings — Gloock serif, regular weight */
h1, h4, h5 {
  font-family: 'Gloock', Georgia, serif;
  font-weight: 400;
  color: var(--tp-secondary);
  letter-spacing: 0;
  text-transform: none;
}

/* UI headings — Poppins sans-serif, semi-bold */
h2, h3, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  color: var(--tp-secondary);
  letter-spacing: 0;
  text-transform: none;
}

h1 { font-size: clamp(36px, 5vw + 12px, 62px); line-height: 1.1; }
h2 { font-size: 22px; line-height: 1.5; }
h3 { font-size: 20px; line-height: 1.4; }
h4 { font-size: clamp(20px, 2vw + 6px, 26px); line-height: 1.3; }
h5 { font-size: 18px; line-height: 1.35; }
h6 { font-size: 14px; line-height: 1.45; text-transform: uppercase; letter-spacing: 1px; }

p {
  margin-bottom: 1.25em;
}

p:last-child {
  margin-bottom: 0;
}

strong, b {
  font-weight: 700;
}

em, i {
  font-style: italic;
}

blockquote {
  border-left: 3px solid var(--tp-primary);
  padding: 16px 24px;
  margin: 24px 0;
  font-size: var(--tp-fs-md);
  font-style: italic;
  color: var(--tp-text-muted);
  background: var(--tp-bg-alt);
}

blockquote p:last-child {
  margin-bottom: 0;
}

code, kbd {
  font-family: var(--tp-font-mono);
  font-size: 0.875em;
  background: var(--tp-border-light);
  padding: 2px 6px;
  border-radius: var(--tp-radius);
}

pre {
  font-family: var(--tp-font-mono);
  font-size: 0.875em;
  background: var(--tp-secondary);
  color: #E5E5E5;
  padding: 20px 24px;
  border-radius: var(--tp-radius-md);
  overflow-x: auto;
  margin: 24px 0;
  line-height: 1.7;
}

pre code {
  background: none;
  padding: 0;
  color: inherit;
}

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

/* UI elements — always sans-serif */
.tp-badge, .tp-meta, .tp-nav__list a, .tp-subscribe-btn,
.tp-ticker__label, .tp-section__more, .tp-footer__heading,
.tp-breadcrumbs, .tp-pagination, .tp-back-to-top,
.tp-search-form, .tp-toc, .tp-share, .tp-tags,
button, input, select, textarea {
  font-family: var(--tp-font-ui);
}

/* Input/form pill radius */
input[type="text"], input[type="email"], input[type="search"],
input[type="url"], input[type="password"], textarea, select {
  border-radius: var(--tp-radius-pill);
}


/* ==========================================================================
   4. Layout & Container
   ========================================================================== */

.tp-container {
  max-width: var(--tp-container);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--tp-pad);
  padding-right: var(--tp-pad);
}

.tp-main {
  min-height: 60vh;
}

.tp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

.tp-content-area {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: var(--tp-gap-lg);
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}

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

.tp-content-area--left .tp-content-area__sidebar {
  order: -1;
}

.tp-content-area--none .tp-content-area__sidebar {
  display: none;
}

.tp-content-area--none {
  grid-template-columns: 1fr;
}

.tp-content-area__main {
  min-width: 0;
}


/* ==========================================================================
   5. Skip Link
   ========================================================================== */

.tp-skip-link {
  position: absolute;
  top: -100%;
  left: 8px;
  z-index: calc(var(--tp-z-top) + 1);
  padding: 8px 16px;
  background: var(--tp-primary);
  color: #fff;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  border-radius: 0 0 var(--tp-radius-md) var(--tp-radius-md);
  transition: top var(--tp-ease);
}

.tp-skip-link:focus {
  top: 0;
  clip: auto;
  clip-path: none;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
}


/* ==========================================================================
   6. Reading Progress Bar
   ========================================================================== */

.tp-reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  z-index: var(--tp-z-top);
  pointer-events: none;
  background: transparent;
}

.tp-reading-progress__bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--tp-primary), rgba(var(--tp-primary-rgb), 0.7));
  transition: width 0.1s linear;
  will-change: width;
}


/* ==========================================================================
   7. Top Bar & Ticker
   ========================================================================== */

.tp-topbar {
  display: none;                     /* hidden — Glossier has no ticker */
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  overflow: hidden;
  position: relative;
  z-index: var(--tp-z-ticker);
  font-size: 12px;
  padding: 6px 0;
}

.tp-topbar__container {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}

.tp-ticker {
  display: flex;
  align-items: center;
  height: 36px;
  gap: 12px;
  overflow: hidden;
}

.tp-ticker__label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  font-size: var(--tp-fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--tp-primary);
  color: #fff;
  padding: 3px 10px;
  border-radius: var(--tp-radius-pill);
  white-space: nowrap;
}

.tp-ticker__dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #fff;
  border-radius: 50%;
  animation: tp-pulse 1.5s ease-in-out infinite;
}

@keyframes tp-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.tp-ticker__track {
  flex: 1;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

.tp-ticker__list {
  display: flex;
  gap: 40px;
  animation: tp-ticker-scroll 45s linear infinite;
  white-space: nowrap;
}

.tp-ticker__list:hover,
.tp-ticker__list:focus-within {
  animation-play-state: paused;
}

@keyframes tp-ticker-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.tp-ticker__item {
  flex-shrink: 0;
}

.tp-ticker__link {
  font-size: var(--tp-fs-xs);
  color: rgba(255, 255, 255, 0.8);
  transition: color var(--tp-ease-fast);
}

.tp-ticker__link:hover {
  color: #fff;
}


/* ==========================================================================
   8. Header & Navigation
   ========================================================================== */

/* Solid white header — sits above the hero in normal flow */
.tp-site-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--tp-z-header);
  background: #fff;
  border-bottom: 1px solid var(--tp-border);
}

.tp-header {
  background: #fff;
  border-bottom: none;
  transition: box-shadow var(--tp-ease);
}

/* When scrolled: add subtle shadow */
.tp-header.tp-header--scrolled {
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
}

.tp-header__inner {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
  display: flex;
  align-items: center;
  height: 70px;
  gap: 20px;
}

.tp-header__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.tp-logo__link,
.tp-logo a {
  font-family: 'Gloock', Georgia, serif;
  font-size: 38px;
  font-weight: 400;
  letter-spacing: normal;
  color: var(--tp-secondary);
  text-decoration: none;
  line-height: 1;
}

.tp-header--scrolled .tp-logo__link,
.tp-header--scrolled .tp-logo a {
  color: var(--tp-secondary);
}

.tp-logo img {
  max-height: 40px;
  width: auto;
}

.tp-logo__name {
  font-family: var(--tp-font-heading);
  font-size: 24px;
  font-weight: 400;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1;
}

.tp-header__tagline {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  margin: 0;
  display: none;
}

/* Navigation */
.tp-nav {
  flex: 1;
  display: flex;
  justify-content: center;
}

.tp-nav__list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tp-nav__list > li {
  position: relative;
}

.tp-nav__list > li > a {
  display: block;
  padding: 8px 14px;
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--tp-secondary);
  position: relative;
  transition: color var(--tp-ease);
}

.tp-nav__list > li > a:hover,
.tp-nav__list > li.current-menu-item > a {
  color: var(--tp-primary);
}

.tp-nav__list > li > a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 14px;
  right: 14px;
  height: 2px;
  background: var(--tp-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--tp-ease);
}

.tp-nav__list > li > a:hover,
.tp-nav__list > li.current-menu-item > a,
.tp-nav__list > li.current-menu-ancestor > a {
  color: var(--tp-secondary);
}

.tp-nav__list > li > a:hover::after,
.tp-nav__list > li.current-menu-item > a::after {
  transform: scaleX(1);
}

/* Dropdown / Sub-menu */
.tp-nav__list .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: var(--tp-bg-alt);
  border: 1px solid var(--tp-border-light);
  border-radius: var(--tp-radius-md);
  box-shadow: var(--tp-shadow-hover);
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity var(--tp-ease), transform var(--tp-ease), visibility var(--tp-ease);
  z-index: 10;
}

.tp-nav__list > li:hover > .sub-menu,
.tp-nav__list > li:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.tp-nav__list .sub-menu li a {
  display: block;
  padding: 8px 20px;
  font-size: var(--tp-fs-sm);
  font-weight: 400;
  color: var(--tp-text);
  text-transform: none;
  letter-spacing: 0;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast);
}

.tp-nav__list .sub-menu li a:hover {
  color: var(--tp-primary);
  background: var(--tp-border-light);
}

/* Header Actions */
.tp-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.tp-header__social {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tp-header__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  color: var(--tp-text-light);
  border-radius: 50%;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast);
}

.tp-header__social-link:hover {
  color: var(--tp-primary);
  background: rgba(var(--tp-primary-rgb), 0.08);
}

.tp-header__social-link svg {
  width: 16px;
  height: 16px;
}

/* Dark Mode Toggle */
.tp-dark-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--tp-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast);
}

.tp-dark-toggle:hover {
  background: var(--tp-bg);
  color: var(--tp-primary);
}

.tp-dark-toggle__sun {
  display: block;
}

.tp-dark-toggle__moon {
  display: none;
}

[data-theme="dark"] .tp-dark-toggle__sun {
  display: none;
}

[data-theme="dark"] .tp-dark-toggle__moon {
  display: block;
}

/* Search Toggle */
.tp-search-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--tp-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast);
}

.tp-search-toggle:hover {
  background: var(--tp-bg);
  color: var(--tp-primary);
}

/* Subscribe Button — dark outlined pill */
.tp-subscribe-btn {
  background: transparent;
  color: var(--tp-secondary);
  border: 2px solid var(--tp-secondary);
  border-radius: 30px;
  padding: 10px 22px;
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.3s ease;
}

.tp-subscribe-btn:hover {
  background: var(--tp-secondary);
  color: #fff;
}

/* Hamburger — always visible (Glossier pattern: hamburger on far left) */
.tp-hamburger {
  display: flex;              /* always visible, not just mobile */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  gap: 5px;
  padding: 0;
  order: -1;                  /* push to far left in flex layout */
  flex-shrink: 0;
}

.tp-hamburger__line {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--tp-secondary);
  border-radius: 1px;
  transition: transform var(--tp-ease), opacity var(--tp-ease);
}

.tp-hamburger[aria-expanded="true"] .tp-hamburger__line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.tp-hamburger[aria-expanded="true"] .tp-hamburger__line:nth-child(2) {
  opacity: 0;
}

.tp-hamburger[aria-expanded="true"] .tp-hamburger__line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}


/* ==========================================================================
   9. Search Overlay
   ========================================================================== */

.tp-search-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--tp-z-overlay);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--tp-ease), visibility var(--tp-ease);
}

.tp-search-overlay[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
}

.tp-search-overlay__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
}

.tp-search-overlay__inner {
  position: relative;
  z-index: 1;
  width: 90%;
  max-width: 640px;
}

.tp-search-overlay__close {
  position: absolute;
  top: -56px;
  right: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--tp-ease-fast);
}

.tp-search-overlay__close:hover {
  color: #fff;
}

/* Search form inside overlay */
.tp-search-overlay .tp-search-form {
  display: flex;
  border-bottom: 2px solid rgba(255, 255, 255, 0.3);
}

.tp-search-overlay .tp-search-form__input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: var(--tp-fs-3xl);
  font-weight: 300;
  padding: 16px 0;
}

.tp-search-overlay .tp-search-form__input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.tp-search-overlay .tp-search-form__btn {
  color: rgba(255, 255, 255, 0.6);
  padding: 0 8px;
  transition: color var(--tp-ease-fast);
}

.tp-search-overlay .tp-search-form__btn:hover {
  color: #fff;
}


/* ==========================================================================
   10. Mobile Navigation (Drawer)
   ========================================================================== */

body.tp-nav-open {
  overflow: hidden;
}

.tp-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  height: 100dvh;
  background: var(--tp-bg-alt);
  z-index: var(--tp-z-drawer);
  transform: translateX(100%);
  transition: transform var(--tp-ease);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 24px;
  padding-top: env(safe-area-inset-top, 24px);
}

.tp-drawer.tp-drawer--open {
  transform: translateX(0);
}

.tp-drawer__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: calc(var(--tp-z-drawer) - 1);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--tp-ease), visibility var(--tp-ease);
}

.tp-drawer__backdrop.tp-drawer__backdrop--visible {
  opacity: 1;
  visibility: visible;
}


/* ==========================================================================
   11. Hero Section
   ========================================================================== */

.tp-hero {
  position: relative;
  width: 100%;
  min-height: 75vh;
  max-height: 720px;
  overflow: hidden;
}

.tp-hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.tp-hero__image {
  width: 100%;
  height: 100%;
}

.tp-hero__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-hero__image--kenburns img {
  animation: tp-kenburns 20s ease-in-out infinite alternate;
}

@keyframes tp-kenburns {
  0% { transform: scale(1); }
  100% { transform: scale(1.06); }
}

.tp-hero__image--gradient {
  display: flex;
  align-items: center;
  justify-content: center;
}

.tp-hero__placeholder-icon {
  opacity: 0.3;
}

.tp-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.1) 40%, transparent 70%);
}

.tp-hero__inner {
  position: relative;
  z-index: 2;
}

.tp-hero__content {
  position: absolute;
  bottom: 60px;
  left: 0;
  right: 0;
  z-index: 2;
  max-width: 700px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tp-hero__cat {
  display: inline-flex;
  align-self: flex-start;
  padding: 4px 14px;
  font-size: var(--tp-fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  background: var(--tp-primary);
  border-radius: var(--tp-radius-pill);
  transition: background var(--tp-ease);
}

.tp-hero__cat:hover {
  background: rgba(var(--tp-primary-rgb), 0.85);
}

.tp-badge--hero {
  background: #FF4444;
  color: #fff;
  border-radius: 30px;
  padding: 3px 12px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  display: inline-block;
  margin-bottom: 16px;
  text-decoration: none;
}

.tp-hero__title {
  font-family: 'Gloock', Georgia, serif;
  font-size: 62px;
  font-weight: 400;
  line-height: 1.1;
  color: #fff;
  max-width: 700px;
  margin: 0 0 16px;
  letter-spacing: 0;
}

.tp-hero__title a {
  color: inherit;
  text-decoration: none;
}

.tp-hero__title a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.tp-hero__excerpt {
  font-size: var(--tp-fs-base);
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.tp-hero__meta {
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tp-hero__meta-sep {
  color: rgba(255,255,255,0.4);
}

.tp-hero__author {
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.tp-hero__author img {
  display: none;  /* Glossier: no avatar in hero */
}

.tp-hero__author-name {
  font-weight: 600;
  color: #fff;
}

/* HIDE elements that Glossier doesn't have */
.tp-hero__excerpt { display: none; }
.tp-hero__cta { display: none; }
.tp-hero__meta img { display: none; }
.tp-hero__reading-time { display: none; }
.tp-hero-cards { display: none; }  /* hide the 4-card strip below hero */

.tp-hero__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 600;
  font-family: var(--tp-font-ui);
  text-transform: none;
  letter-spacing: 0;
  color: #fff;
  background: var(--tp-primary);
  border-radius: var(--tp-radius-pill);
  transition: background var(--tp-ease), transform var(--tp-ease);
  align-self: flex-start;
  margin-top: 4px;
}

.tp-hero__cta:hover {
  background: var(--tp-secondary);
  transform: translateY(-1px);
}

/* Trending sidebar in hero */
.tp-hero__trending {
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: var(--tp-radius-md);
  padding: 20px;
  align-self: end;
}

.tp-hero__trending-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--tp-fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 16px;
}

.tp-hero__trending-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: trending;
}

.tp-hero__trending-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.tp-hero__trending-number {
  flex-shrink: 0;
  font-size: var(--tp-fs-xl);
  font-weight: 800;
  color: rgba(var(--tp-primary-rgb), 0.6);
  line-height: 1;
  min-width: 28px;
}

.tp-hero__trending-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.tp-hero__trending-cat {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--tp-primary);
}

.tp-hero__trending-link {
  font-size: var(--tp-fs-sm);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
  transition: color var(--tp-ease-fast);
}

.tp-hero__trending-link:hover {
  color: #fff;
}


/* ==========================================================================
   12. Section Headers
   ========================================================================== */

.tp-section {
  margin-bottom: var(--tp-section-gap);
}

.tp-section__title {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--tp-secondary);
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 2rem;
}

.tp-section__link {
  float: right;
  font-size: var(--tp-fs-sm);
  font-weight: 500;
  color: var(--tp-text-muted);
  transition: color var(--tp-ease-fast);
}

.tp-section__link:hover {
  color: var(--tp-primary);
}


/* ==========================================================================
   13. Card — Standard
   ========================================================================== */

.tp-card {
  background: var(--tp-bg-alt);
  border-radius: var(--tp-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--tp-ease), box-shadow var(--tp-ease);
}

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

.tp-card__image-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
}

.tp-card__image-wrap .tp-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  z-index: 2;
}

.tp-card__image-link {
  display: block;
  width: 100%;
  height: 100%;
}

.tp-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--tp-ease);
}

.tp-card:hover .tp-card__image {
  transform: scale(1.03);
}

.tp-card__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.tp-card__placeholder-icon {
  opacity: 0.6;
}

.tp-card__cat {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 3px 10px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  background: var(--tp-primary);
  border-radius: var(--tp-radius-pill);
  z-index: 1;
  transition: background var(--tp-ease-fast);
}

.tp-card__cat:hover {
  background: var(--tp-secondary);
}

.tp-card__cat--small {
  position: static;
  display: inline-block;
  margin-bottom: 8px;
}

.tp-card__body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.tp-card__title {
  font-family: 'Poppins', sans-serif;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--tp-secondary);
  margin: 0 0 10px;
}

.tp-card__title a {
  color: inherit;
  text-decoration: none;
}

.tp-card__title a:hover {
  color: var(--tp-primary);
}

.tp-card__excerpt {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.tp-card__excerpt--full {
  -webkit-line-clamp: 4;
}

.tp-card__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  margin-top: auto;
  padding-top: 8px;
}

.tp-card__author {
  display: flex;
  align-items: center;
  gap: 6px;
}

.tp-card__author img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.tp-card__reading-time {
  margin-left: auto;
}


/* ==========================================================================
   14. Card — Featured / Overlay
   ========================================================================== */

.tp-card--featured,
.tp-card--overlay {
  position: relative;
  min-height: 320px;
  aspect-ratio: auto;
  display: flex;
  align-items: flex-end;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-card--featured .tp-card__image-wrap,
.tp-card--overlay .tp-card__image-wrap {
  position: absolute;
  inset: 0;
  aspect-ratio: auto;
}

.tp-card--featured .tp-card__image,
.tp-card--overlay .tp-card__image {
  height: 100%;
}

.tp-card--featured .tp-card__body,
.tp-card--overlay .tp-card__body {
  position: relative;
  z-index: 1;
  padding: 24px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 100%);
  width: 100%;
}

.tp-card--featured .tp-card__title a,
.tp-card--overlay .tp-card__title a {
  color: #fff;
}

.tp-card--featured .tp-card__title a:hover,
.tp-card--overlay .tp-card__title a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.tp-card--featured .tp-card__excerpt,
.tp-card--overlay .tp-card__excerpt {
  color: rgba(255, 255, 255, 0.8);
}

.tp-card--featured .tp-card__meta,
.tp-card--overlay .tp-card__meta {
  color: rgba(255, 255, 255, 0.7);
}

/* Featured first in grid — span full width */
.tp-card--featured-first {
  grid-column: 1 / -1;
}

.tp-card--featured-first .tp-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.tp-card--featured-first .tp-card__image-wrap {
  aspect-ratio: auto;
  height: 100%;
}

.tp-card--featured-first .tp-card__body {
  padding: 24px;
  justify-content: center;
}


/* ==========================================================================
   15. Card — Horizontal
   ========================================================================== */

.tp-card--search,
.tp-card--horizontal {
  display: grid;
  grid-template-columns: 2fr 3fr;
  flex-direction: row;
}

.tp-card--search .tp-card__image-wrap,
.tp-card--horizontal .tp-card__image-wrap {
  aspect-ratio: auto;
  height: 100%;
  min-height: 160px;
}

.tp-card--search .tp-card__image-wrap--search {
  min-height: 120px;
}

.tp-card--search .tp-card__body,
.tp-card--horizontal .tp-card__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.tp-card--search .tp-card__body--search {
  padding: 16px 20px;
}


/* ==========================================================================
   16. Card — Video
   ========================================================================== */

.tp-card--video .tp-card__image-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.tp-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: transform var(--tp-ease), box-shadow var(--tp-ease);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.tp-play svg {
  margin-left: 3px;
  color: var(--tp-primary);
}

.tp-card--video:hover .tp-play {
  transform: translate(-50%, -50%) scale(1.08);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}


/* ==========================================================================
   17. Card — Mini (Trending)
   ========================================================================== */

.tp-card--mini {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: transparent;
  padding: 12px 0;
  border-bottom: 1px solid var(--tp-border-light);
}

.tp-card--mini:last-child {
  border-bottom: none;
}

.tp-card--mini:hover {
  transform: none;
  box-shadow: none;
}

.tp-card--mini__number,
.tp-card__number {
  flex-shrink: 0;
  font-size: var(--tp-fs-2xl);
  font-weight: 800;
  color: var(--tp-border);
  line-height: 1;
  min-width: 32px;
}

.tp-card--mini__cat {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--tp-primary);
}

.tp-card--mini__title {
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  color: var(--tp-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-card--mini__title:hover {
  color: var(--tp-primary);
}

/* Card overlay gradient (featured/overlay cards) */
.tp-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.3) 50%,
    transparent 100%
  );
  z-index: 1;
}


/* ==========================================================================
   18. Card — Related
   ========================================================================== */

.tp-card--related {
  background: var(--tp-bg-alt);
}

.tp-card--related .tp-card__image-wrap {
  aspect-ratio: 16 / 10;
}

.tp-card--related .tp-card__body {
  padding: 12px;
}

.tp-card--related .tp-card__title {
  font-size: var(--tp-fs-base);
  -webkit-line-clamp: 2;
}


/* ==========================================================================
   19. Homepage Sections
   ========================================================================== */

/* Editor's Picks */
.tp-picks {
  max-width: var(--tp-container);
  margin: 0 auto var(--tp-section-gap);
  padding: 0 var(--tp-pad);
}

.tp-picks__header {
  margin-bottom: var(--tp-gap);
}

.tp-picks__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

/* Don't Miss Out */
.tp-dontmiss {
  max-width: var(--tp-container);
  margin: 0 auto var(--tp-section-gap);
  padding: 0 var(--tp-pad);
}

.tp-dontmiss__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--tp-gap);
}

.tp-dontmiss__item {
  background: var(--tp-bg-alt);
  border-radius: var(--tp-radius);
  padding: 24px;
  text-align: center;
  transition: transform var(--tp-ease), box-shadow var(--tp-ease);
}

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

.tp-dontmiss__icon {
  color: var(--tp-primary);
  margin-bottom: 12px;
}

.tp-dontmiss__label {
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--tp-secondary);
  margin-bottom: 4px;
}

.tp-dontmiss__count {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
}

/* Video Grid */
.tp-video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

/* Newsletter CTA */
.tp-newsletter-cta {
  background: var(--tp-bg-alt);
  padding: 80px 30px;
  text-align: center;
  margin-bottom: var(--tp-section-gap);
}

.tp-newsletter-cta__title,
.tp-newsletter-cta h2 {
  font-family: var(--tp-font-heading);
  font-size: 36px;
  font-weight: 400;
  color: var(--tp-secondary);
  margin-bottom: 8px;
}

.tp-newsletter-cta__text {
  font-size: var(--tp-fs-base);
  color: var(--tp-text-muted);
  margin-bottom: 24px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.tp-newsletter-cta__form {
  display: flex;
  max-width: 440px;
  margin: 0 auto;
  border-radius: var(--tp-radius-pill);
  overflow: hidden;
  background: var(--tp-bg);
  border: 1px solid var(--tp-border);
}

.tp-newsletter-cta__input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--tp-text);
  padding: 14px 20px;
  font-size: var(--tp-fs-sm);
  outline: none;
}

.tp-newsletter-cta__input::placeholder {
  color: var(--tp-text-light);
}

.tp-newsletter-cta__btn {
  padding: 14px 28px;
  background: var(--tp-primary);
  color: #fff;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border: none;
  cursor: pointer;
  transition: background var(--tp-ease);
}

.tp-newsletter-cta__btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.85);
}

/* Instagram Grid */
.tp-instagram-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0;
  margin-bottom: var(--tp-section-gap);
}

.tp-instagram-grid__item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.tp-instagram-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--tp-ease);
}

.tp-instagram-grid__item:hover img {
  transform: scale(1.05);
}

/* Empty state */
.tp-empty {
  text-align: center;
  padding: 60px 20px;
}

.tp-empty--inline {
  padding: 40px 20px;
}

.tp-empty__icon {
  color: var(--tp-border);
  margin-bottom: 16px;
}

.tp-empty__title {
  font-size: var(--tp-fs-lg);
  margin-bottom: 8px;
}

.tp-empty__text {
  font-size: var(--tp-fs-base);
  color: var(--tp-text-muted);
  max-width: 480px;
  margin: 0 auto 24px;
}


/* ==========================================================================
   20. Single Post — Article Header
   ========================================================================== */

.tp-single {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}

.tp-single__header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto var(--tp-gap-lg);
}

.tp-single__cat {
  display: inline-block;
  padding: 4px 14px;
  font-size: var(--tp-fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  background: var(--tp-primary);
  border-radius: var(--tp-radius-pill);
  margin-bottom: 16px;
  transition: background var(--tp-ease-fast);
}

.tp-single__cat:hover {
  background: var(--tp-secondary);
}

.tp-single__title {
  font-family: var(--tp-font-heading);
  font-size: clamp(28px, 4vw + 10px, 48px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
}

.tp-single__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-muted);
}

.tp-single__meta-author {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tp-single__meta-author img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

.tp-single__meta-author a {
  font-weight: 600;
  color: var(--tp-secondary);
}

.tp-single__meta-author a:hover {
  color: var(--tp-primary);
}

.tp-single__meta-sep {
  color: var(--tp-border);
}

/* Featured Image */
.tp-single__featured {
  margin-bottom: var(--tp-gap-lg);
  position: relative;
}

.tp-single__featured img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.tp-single__featured figcaption {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  text-align: center;
  padding-top: 8px;
}

/* Placeholder for no featured image */
.tp-single__placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--tp-gap-lg);
}


/* ==========================================================================
   21. Single Post — Breadcrumbs
   ========================================================================== */

.tp-breadcrumbs {
  max-width: var(--tp-container);
  margin: 16px auto;
  padding: 0 var(--tp-pad);
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
}

.tp-breadcrumbs__list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
}

.tp-breadcrumbs__item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tp-breadcrumbs__link {
  color: var(--tp-text-muted);
  transition: color var(--tp-ease-fast);
}

.tp-breadcrumbs__link:hover {
  color: var(--tp-primary);
}

.tp-breadcrumbs__separator {
  color: var(--tp-border);
}


/* ==========================================================================
   22. Single Post — Content Body
   ========================================================================== */

.tp-single__content-area {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--tp-gap-lg);
  max-width: 1000px;
  margin: 0 auto;
}

.tp-single__body-wrap {
  max-width: 800px;
  min-width: 0;
}

.tp-single__body {
  font-family: var(--tp-font-body);
  font-size: 18px;
  line-height: 1.6;
  color: var(--tp-text);
  overflow-x: hidden;
}

.tp-single__body p {
  margin-bottom: 1.5em;
}

.tp-single__body a {
  color: var(--tp-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--tp-ease-fast);
}

.tp-single__body a:hover {
  color: var(--tp-secondary);
}


/* ==========================================================================
   23. Single Post — Drop Cap
   ========================================================================== */

.tp-single__body > p:first-of-type::first-letter {
  float: left;
  font-size: 3.5em;
  font-weight: 800;
  line-height: 0.8;
  margin-right: 8px;
  margin-top: 6px;
  color: var(--tp-primary);
}


/* ==========================================================================
   24. Single Post — Content Typography
   ========================================================================== */

.tp-single__body h2 {
  font-family: var(--tp-font-heading);
  font-size: clamp(24px, 3vw + 8px, 36px);
  font-weight: 400;
  margin: 2em 0 0.75em;
  padding-bottom: 0;
  border-bottom: none;
}

.tp-single__body h3 {
  font-family: var(--tp-font-heading);
  font-size: clamp(20px, 2vw + 6px, 26px);
  font-weight: 400;
  margin: 1.5em 0 0.5em;
}

.tp-single__body h4 {
  font-size: var(--tp-fs-md);
  font-weight: 700;
  margin: 1.5em 0 0.5em;
}

.tp-single__body ul,
.tp-single__body ol {
  margin: 0 0 1.5em;
  padding-left: 24px;
}

.tp-single__body ul {
  list-style: disc;
}

.tp-single__body ul li::marker {
  color: var(--tp-primary);
}

.tp-single__body ol {
  list-style: decimal;
}

.tp-single__body ol li::marker {
  color: var(--tp-primary);
  font-weight: 600;
}

.tp-single__body li {
  margin-bottom: 0.5em;
}

.tp-single__body blockquote {
  font-family: var(--tp-font-body);
  font-size: 22px;
  font-style: italic;
  border-left: 3px solid var(--tp-primary);
  background: transparent;
  padding: 1.5rem 2rem;
  margin: 1.5em 0;
  color: var(--tp-text-muted);
  border-radius: 0;
}

.tp-single__body code {
  font-family: var(--tp-font-mono);
  font-size: 0.875em;
  background: var(--tp-border-light);
  padding: 2px 6px;
  border-radius: var(--tp-radius);
  color: var(--tp-primary);
}

.tp-single__body pre {
  background: var(--tp-secondary);
  color: #E5E5E5;
  padding: 20px 24px;
  border-radius: var(--tp-radius-md);
  overflow-x: auto;
  margin: 1.5em 0;
  line-height: 1.7;
}

.tp-single__body pre code {
  background: none;
  padding: 0;
  color: inherit;
}

.tp-single__body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5em 0;
  font-size: var(--tp-fs-sm);
}

.tp-single__body thead {
  background: var(--tp-secondary);
  color: #fff;
}

.tp-single__body th,
.tp-single__body td {
  padding: 10px 14px;
  text-align: left;
  border: 1px solid var(--tp-border);
}

.tp-single__body th {
  font-weight: 600;
}

.tp-single__body tbody tr:nth-child(even) {
  background: var(--tp-bg);
}

.tp-single__body figure {
  margin: 1.5em 0;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-single__body figure img {
  width: 100%;
  height: auto;
}

.tp-single__body figcaption {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  text-align: center;
  padding-top: 8px;
}

.tp-single__body hr {
  border: none;
  height: 2px;
  width: 60px;
  background: var(--tp-primary);
  margin: 2em auto;
}

/* Collapse empty elements so they don't create huge whitespace */
.tp-single__body p:empty,
.tp-single__body div:empty,
.tp-single__body figure:empty,
.tp-single__body h1:empty,
.tp-single__body h2:empty,
.tp-single__body h3:empty,
.tp-single__body h4:empty {
  display: none;
}

/* Handle paragraphs containing only whitespace or <br> */
.tp-single__body p:has(> br:only-child),
.tp-single__body p:has(> img[src=""]) {
  display: none;
}

/* Figures/images with no valid src collapse */
.tp-single__body figure:not(:has(img[src])),
.tp-single__body figure img[src=""],
.tp-single__body img[src=""] {
  display: none;
}

/* Tables with only a header row (no tbody content) collapse */
.tp-single__body table:not(:has(tbody tr)) {
  display: none;
}


/* ==========================================================================
   25. Single Post — Table of Contents
   ========================================================================== */

.tp-toc {
  background: var(--tp-bg);
  border: 1px solid var(--tp-border-light);
  border-radius: var(--tp-radius-md);
  padding: 20px;
  margin-bottom: var(--tp-gap-lg);
}

.tp-toc__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--tp-secondary);
  padding: 0;
}

.tp-toc__icon {
  transition: transform var(--tp-ease);
}

.tp-toc__toggle[aria-expanded="false"] .tp-toc__icon {
  transform: rotate(-90deg);
}

.tp-toc__nav {
  margin-top: 16px;
}

.tp-toc__nav ol {
  list-style: decimal;
  padding-left: 20px;
  margin: 0;
}

.tp-toc__nav li {
  margin-bottom: 6px;
}

.tp-toc__nav a {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-muted);
  text-decoration: none;
  transition: color var(--tp-ease-fast);
  display: block;
  padding: 2px 0;
}

.tp-toc__nav a:hover,
.tp-toc__nav a.tp-toc--active {
  color: var(--tp-primary);
}

.tp-toc__nav a.tp-toc--active {
  font-weight: 600;
}


/* ==========================================================================
   26. Single Post — Social Share
   ========================================================================== */

/* Inline horizontal share row (base) */
.tp-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin: 32px 0;
  padding: 20px 0;
  border-top: 1px solid var(--tp-border);
  border-bottom: 1px solid var(--tp-border);
}

.tp-share__label {
  font-family: var(--tp-font-ui);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--tp-secondary);
  margin-right: 8px;
}

/* Floating sidebar (desktop) */
.tp-share--sidebar {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-self: start;
  border: none;
  margin: 0;
  padding: 0;
}

.tp-share__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--tp-text-muted);
  background: var(--tp-bg);
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast), transform var(--tp-ease-fast);
}

.tp-share__btn:hover {
  transform: translateY(-2px);
}

.tp-share__btn--facebook:hover {
  background: #1877F2;
  color: #fff;
}

.tp-share__btn--twitter:hover {
  background: #1DA1F2;
  color: #fff;
}

.tp-share__btn--linkedin:hover {
  background: #0A66C2;
  color: #fff;
}

.tp-share__btn--email:hover {
  background: var(--tp-text-muted);
  color: #fff;
}

.tp-share__btn--pinterest:hover {
  background: #E60023;
  color: #fff;
}

.tp-share__btn--whatsapp:hover {
  background: #25D366;
  color: #fff;
}

.tp-share__btn--copy:hover {
  background: var(--tp-secondary);
  color: #fff;
}

.tp-share__btn svg {
  width: 18px;
  height: 18px;
}

/* Mobile bottom bar */
.tp-share--mobile {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: var(--tp-z-drawer);
  background: var(--tp-bg-alt);
  border-top: 1px solid var(--tp-border-light);
  padding: 8px 0;
  padding-bottom: env(safe-area-inset-bottom, 8px);
  display: none;
  justify-content: center;
  gap: 12px;
}


/* ==========================================================================
   27. Single Post — Inline Newsletter
   ========================================================================== */

.tp-inline-newsletter {
  background: var(--tp-secondary);
  color: #fff;
  border-radius: var(--tp-radius-md);
  padding: 40px;
  text-align: center;
  margin: 2em 0;
}

.tp-inline-newsletter__title {
  font-size: var(--tp-fs-xl);
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}

.tp-inline-newsletter__text {
  font-size: var(--tp-fs-sm);
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
}

.tp-inline-newsletter__form {
  display: flex;
  max-width: 400px;
  margin: 0 auto;
  border-radius: var(--tp-radius-pill);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
}

.tp-inline-newsletter__input {
  flex: 1;
  border: none;
  background: transparent;
  color: #fff;
  padding: 12px 18px;
  font-size: var(--tp-fs-sm);
  outline: none;
}

.tp-inline-newsletter__input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.tp-inline-newsletter__btn {
  padding: 12px 20px;
  background: var(--tp-primary);
  color: #fff;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background var(--tp-ease);
}

.tp-inline-newsletter__btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.85);
}


/* ==========================================================================
   28. Single Post — Tags
   ========================================================================== */

.tp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: var(--tp-gap-lg) 0;
  padding-top: var(--tp-gap);
  border-top: 1px solid var(--tp-border-light);
}

.tp-tags a {
  display: inline-block;
  padding: 4px 14px;
  font-size: var(--tp-fs-xs);
  font-weight: 500;
  color: var(--tp-text-muted);
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius-pill);
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast), border-color var(--tp-ease-fast);
}

.tp-tags a:hover {
  color: #fff;
  background: var(--tp-primary);
  border-color: var(--tp-primary);
}


/* ==========================================================================
   29. Single Post — Author Bio
   ========================================================================== */

.tp-author-bio {
  display: flex;
  gap: 20px;
  padding: var(--tp-gap) 0;
  border-top: 1px solid var(--tp-border-light);
  border-bottom: 1px solid var(--tp-border-light);
  margin: var(--tp-gap-lg) 0;
}

.tp-author-bio__avatar {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
}

.tp-author-bio__avatar img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.tp-author-bio__initial {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  color: #fff;
  font-family: var(--tp-font-heading);
  font-size: 36px;
  font-weight: 400;
  line-height: 1;
  user-select: none;
}

/* Reusable letter-fallback avatar circle (inline in meta rows) */
.tp-avatar-initial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #fff;
  font-family: var(--tp-font-heading);
  font-weight: 400;
  line-height: 1;
  vertical-align: middle;
  flex-shrink: 0;
  user-select: none;
}

.tp-author-bio__content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tp-author-bio__label {
  font-size: var(--tp-fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--tp-text-light);
}

.tp-author-bio__name {
  font-size: var(--tp-fs-lg);
  font-weight: 700;
  margin: 0;
}

.tp-author-bio__name a {
  color: var(--tp-secondary);
  transition: color var(--tp-ease-fast);
}

.tp-author-bio__name a:hover {
  color: var(--tp-primary);
}

.tp-author-bio__desc {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-muted);
  line-height: 1.6;
  margin: 0;
}

.tp-author-bio__all-posts {
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  color: var(--tp-primary);
  margin-top: 4px;
  transition: color var(--tp-ease-fast);
}

.tp-author-bio__all-posts:hover {
  color: var(--tp-secondary);
}


/* ==========================================================================
   30. Single Post — Post Navigation
   ========================================================================== */

.tp-post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--tp-gap);
  margin: var(--tp-gap-lg) 0;
}

.tp-post-nav__item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px;
  background: var(--tp-bg);
  border-radius: var(--tp-radius);
  border: 1px solid transparent;
  transition: border-color var(--tp-ease);
}

.tp-post-nav__item:hover {
  border-color: var(--tp-primary);
}

.tp-post-nav__item--next {
  text-align: right;
}

.tp-post-nav__label {
  font-size: var(--tp-fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--tp-text-light);
}

.tp-post-nav__title {
  font-size: var(--tp-fs-base);
  font-weight: 600;
  color: var(--tp-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-post-nav__thumb {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-post-nav__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/* ==========================================================================
   31. Single Post — Related Posts
   ========================================================================== */

.tp-related {
  margin: var(--tp-section-gap) 0;
}


/* ==========================================================================
   32. Single Post — Comments
   ========================================================================== */

.tp-comments {
  margin-top: var(--tp-section-gap);
}

.tp-comments-area__title {
  font-size: var(--tp-fs-lg);
  font-weight: 700;
  margin-bottom: var(--tp-gap);
}

.tp-comments-area__list {
  list-style: none;
  padding: 0;
}

.tp-comments-area__list .comment {
  padding: var(--tp-gap) 0;
  border-bottom: 1px solid var(--tp-border-light);
}

.tp-comments-area__list .comment .comment-body {
  display: flex;
  gap: 16px;
}

.tp-comments-area__list .comment .comment-body .comment-author img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

.tp-comments-area__list .comment .comment-body .comment-author .fn {
  font-weight: 600;
  color: var(--tp-secondary);
}

.tp-comments-area__list .comment .comment-body .comment-meta {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  margin-bottom: 8px;
}

.tp-comments-area__list .comment .comment-body .comment-content {
  font-size: var(--tp-fs-sm);
  line-height: 1.6;
  color: var(--tp-text);
}

.tp-comments-area__list .comment .comment-body .reply a {
  font-size: var(--tp-fs-xs);
  font-weight: 600;
  color: var(--tp-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: color var(--tp-ease-fast);
}

.tp-comments-area__list .comment .comment-body .reply a:hover {
  color: var(--tp-secondary);
}

.tp-comments-area__list .children {
  margin-left: 40px;
  padding: 0;
  list-style: none;
  border-left: 2px solid var(--tp-border-light);
  padding-left: 20px;
}

.tp-comments-area__closed {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-light);
  font-style: italic;
}

/* Comment Form */
.tp-comment-form {
  margin-top: var(--tp-gap-lg);
}

.tp-comment-form label {
  display: block;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  color: var(--tp-secondary);
  margin-bottom: 4px;
}

.tp-comment-form input[type="text"],
.tp-comment-form input[type="email"],
.tp-comment-form input[type="url"] {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  font-size: var(--tp-fs-sm);
  color: var(--tp-text);
  background: var(--tp-bg-alt);
  transition: border-color var(--tp-ease-fast);
  margin-bottom: 16px;
}

.tp-comment-form input[type="text"]:focus,
.tp-comment-form input[type="email"]:focus,
.tp-comment-form input[type="url"]:focus,
.tp-comment-form__textarea:focus {
  border-color: var(--tp-primary);
  outline: none;
}

.tp-comment-form__textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  font-size: var(--tp-fs-sm);
  color: var(--tp-text);
  background: var(--tp-bg-alt);
  resize: vertical;
  min-height: 120px;
  transition: border-color var(--tp-ease-fast);
}

.tp-comment-form .form-submit input[type="submit"] {
  display: inline-flex;
  align-items: center;
  padding: 10px 28px;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #fff;
  background: var(--tp-primary);
  border: none;
  border-radius: var(--tp-radius-pill);
  cursor: pointer;
  transition: background var(--tp-ease), transform var(--tp-ease);
}

.tp-comment-form .form-submit input[type="submit"]:hover {
  background: var(--tp-secondary);
  transform: translateY(-1px);
}


/* ==========================================================================
   33. Sidebar
   ========================================================================== */

.tp-sidebar {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tp-content-area__sidebar {
  min-width: 0;
}

.tp-widget {
  background: var(--tp-bg-alt);
  border-radius: var(--tp-radius-md);
  padding: 20px;
}

.tp-widget--ad {
  background: transparent;
  padding: 0;
}

.tp-widget__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--tp-secondary);
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--tp-primary);
}

.tp-widget__title-icon {
  flex-shrink: 0;
  color: var(--tp-primary);
  opacity: 0.85;
}

/* Recent Posts widget */
.tp-recent {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tp-recent__item {
  margin: 0;
  padding: 0;
}

.tp-recent__link {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  text-decoration: none;
  padding: 6px;
  margin: -6px;
  border-radius: var(--tp-radius);
  transition: background-color var(--tp-ease-fast);
}

.tp-recent__link:hover {
  background-color: var(--tp-bg);
}

.tp-recent__thumb {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: var(--tp-radius);
  overflow: hidden;
  position: relative;
}

.tp-recent__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--tp-ease);
}

.tp-recent__link:hover .tp-recent__img {
  transform: scale(1.05);
}

.tp-recent__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: var(--tp-fs-lg);
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
}

.tp-recent__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tp-recent__title {
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  color: var(--tp-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color var(--tp-ease-fast);
}

.tp-recent__link:hover .tp-recent__title {
  color: var(--tp-primary);
}

.tp-recent__date {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
}

/* Browse Topics (Category Pills) */
.tp-topics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tp-topics__pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  font-size: var(--tp-fs-xs);
  font-weight: 500;
  color: var(--tp-text);
  background: var(--tp-bg);
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius-pill);
  text-decoration: none;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast), border-color var(--tp-ease-fast);
  white-space: nowrap;
}

.tp-topics__pill:hover {
  background: var(--tp-primary);
  color: #fff;
  border-color: var(--tp-primary);
}

.tp-topics__pill:hover .tp-topics__count {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.tp-topics__pill--empty {
  opacity: 0.5;
  pointer-events: none;
  border-style: dashed;
}

.tp-topics__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  font-size: 10px;
  font-weight: 600;
  color: var(--tp-text-light);
  background: var(--tp-border-light);
  border-radius: var(--tp-radius-pill);
  transition: background var(--tp-ease-fast), color var(--tp-ease-fast);
  line-height: 1;
}

/* Newsletter widget */
.tp-widget--newsletter {
  background: var(--tp-secondary);
  color: #fff;
}

.tp-newsletter {
  background: var(--tp-secondary);
  color: #fff;
  padding: 72px 30px;
  text-align: center;
  margin: var(--tp-section-gap) 0;
}

.tp-newsletter__inner {
  max-width: 620px;
  margin: 0 auto;
  padding: 0;
}

.tp-newsletter__header {
  margin-bottom: 16px;
}

.tp-newsletter__icon {
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 16px;
  display: flex;
  justify-content: center;
}

.tp-newsletter__title {
  font-family: var(--tp-font-heading);
  font-size: 36px;
  font-weight: 400;
  line-height: 1.2;
  color: #fff;
  margin: 0 0 12px;
}

.tp-newsletter__desc,
.tp-newsletter__text {
  font-family: var(--tp-font-body);
  font-size: 16px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.75);
  margin: 0 0 24px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.tp-newsletter__field {
  display: flex;
  gap: 0;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-newsletter__input {
  flex: 1;
  padding: 10px 14px;
  border: none;
  font-size: var(--tp-fs-sm);
  color: var(--tp-text);
  background: #fff;
  outline: none;
  min-width: 0;
}

.tp-newsletter__input::placeholder {
  color: var(--tp-text-light);
}

.tp-newsletter__input:focus {
  box-shadow: inset 0 0 0 2px var(--tp-primary);
}

.tp-newsletter__btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 10px 16px;
  background: var(--tp-primary);
  color: #fff;
  border: none;
  font-size: var(--tp-fs-xs);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--tp-ease);
  white-space: nowrap;
}

.tp-newsletter__btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.85);
}

.tp-newsletter__privacy {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.6);
  margin: 8px 0 0;
  line-height: 1.5;
}

.tp-newsletter__privacy a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 2px;
}


/* ==========================================================================
   34. Archive Page
   ========================================================================== */

.tp-archive__header {
  margin-bottom: var(--tp-gap-lg);
}

.tp-archive__banner {
  background: var(--tp-secondary);
  color: #fff;
  border-radius: var(--tp-radius-md);
  padding: 40px;
  text-align: center;
}

.tp-archive__banner-inner {
  max-width: 600px;
  margin: 0 auto;
}

.tp-archive__title {
  font-size: var(--tp-fs-3xl);
  font-weight: 800;
  color: #fff;
  margin: 0 0 8px;
}

.tp-archive__desc {
  font-size: var(--tp-fs-base);
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 8px;
}

.tp-archive__desc p {
  margin: 0;
}

.tp-archive__count {
  font-size: var(--tp-fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.5);
}


/* ==========================================================================
   35. Search Page
   ========================================================================== */

.tp-search-results__header {
  margin-bottom: var(--tp-gap-lg);
}

.tp-search-results__title {
  font-size: var(--tp-fs-3xl);
  font-weight: 800;
  margin: 0 0 4px;
}

.tp-search-results__title span {
  color: var(--tp-primary);
}

.tp-search-results__count {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-muted);
  margin: 0;
}

.tp-search-results__list {
  display: flex;
  flex-direction: column;
  gap: var(--tp-gap);
}

/* Search form */
.tp-search-form {
  display: flex;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius-pill);
  overflow: hidden;
  background: var(--tp-bg-alt);
  transition: border-color var(--tp-ease-fast);
}

.tp-search-form:focus-within {
  border-color: var(--tp-primary);
}

.tp-search-form__input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 18px;
  font-size: var(--tp-fs-sm);
  color: var(--tp-text);
  outline: none;
}

.tp-search-form__input::placeholder {
  color: var(--tp-text-light);
}

.tp-search-form__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  color: var(--tp-text-muted);
  transition: color var(--tp-ease-fast);
}

.tp-search-form__btn:hover {
  color: var(--tp-primary);
}


/* ==========================================================================
   36. 404 Page
   ========================================================================== */

.tp-404 {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: var(--tp-section-gap) var(--tp-pad);
}

.tp-404__content {
  text-align: center;
  margin-bottom: var(--tp-section-gap);
}

.tp-404__code {
  display: block;
  font-size: clamp(80px, 15vw, 160px);
  font-weight: 900;
  line-height: 1;
  color: var(--tp-border-light);
  letter-spacing: -0.04em;
}

.tp-404__title {
  font-size: var(--tp-fs-3xl);
  font-weight: 800;
  margin: 16px 0;
}

.tp-404__text {
  font-size: var(--tp-fs-base);
  color: var(--tp-text-muted);
  max-width: 480px;
  margin: 0 auto 24px;
}

.tp-404__search {
  max-width: 400px;
  margin: 0 auto 16px;
}

.tp-404__home {
  display: inline-flex;
  align-items: center;
  padding: 10px 24px;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #fff;
  background: var(--tp-primary);
  border-radius: var(--tp-radius-pill);
  transition: background var(--tp-ease), transform var(--tp-ease);
}

.tp-404__home:hover {
  background: var(--tp-secondary);
  transform: translateY(-1px);
}

.tp-404__suggestions {
  margin-top: var(--tp-section-gap);
}

.tp-404__suggestions-title {
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--tp-secondary);
  margin-bottom: var(--tp-gap);
  padding-bottom: 12px;
  border-bottom: 2px solid var(--tp-primary);
  display: inline-block;
}

.tp-404__suggestions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}


/* ==========================================================================
   37. Page Template
   ========================================================================== */

.tp-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}

.tp-page__hero {
  position: relative;
  margin: 0 calc(var(--tp-pad) * -1) var(--tp-gap-lg);
  max-width: none;
  width: calc(100% + var(--tp-pad) * 2);
  aspect-ratio: 21 / 9;
  overflow: hidden;
}

.tp-page__hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-page__hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
}

.tp-page__hero-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 32px;
  z-index: 1;
}

.tp-page__title--hero {
  color: #fff;
  font-size: var(--tp-fs-3xl);
  margin: 0;
}

.tp-page__header {
  margin-bottom: var(--tp-gap-lg);
}

.tp-page__title {
  font-size: var(--tp-fs-3xl);
  font-weight: 800;
  margin: 0;
}

.tp-page__body {
  font-size: var(--tp-fs-base);
  line-height: 1.75;
  color: var(--tp-text);
}

.tp-page__body p {
  margin-bottom: 1.5em;
}

.tp-page-links {
  display: flex;
  gap: 8px;
  padding-top: var(--tp-gap);
}

.tp-page-links__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--tp-border);
  border-radius: 50%;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
}


/* ==========================================================================
   38. Pagination
   ========================================================================== */

.tp-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: var(--tp-section-gap);
}

.tp-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 8px;
  font-size: var(--tp-fs-sm);
  font-weight: 500;
  color: var(--tp-text-muted);
  border: 1px solid var(--tp-border);
  border-radius: 50%;
  transition: color var(--tp-ease-fast), background var(--tp-ease-fast), border-color var(--tp-ease-fast);
}

.tp-pagination .page-numbers:hover {
  color: var(--tp-secondary);
  border-color: var(--tp-secondary);
}

.tp-pagination .page-numbers.current {
  background: var(--tp-primary);
  color: #fff;
  border-color: var(--tp-primary);
  font-weight: 700;
}

.tp-pagination .page-numbers.dots {
  border: none;
  color: var(--tp-text-light);
}

.tp-pagination .page-numbers.prev,
.tp-pagination .page-numbers.next {
  font-size: var(--tp-fs-lg);
  border: none;
  color: var(--tp-text);
}

.tp-pagination .page-numbers.prev:hover,
.tp-pagination .page-numbers.next:hover {
  color: var(--tp-primary);
}


/* ==========================================================================
   39. Back-to-Top
   ========================================================================== */

.tp-back-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tp-primary);
  color: #fff;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  z-index: var(--tp-z-ticker);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity var(--tp-ease), visibility var(--tp-ease), transform var(--tp-ease), background var(--tp-ease);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.tp-back-to-top:not([hidden]) {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.tp-back-to-top:hover {
  background: var(--tp-secondary);
  transform: translateY(-2px);
}


/* ==========================================================================
   40. Footer
   ========================================================================== */

.tp-footer {
  background: var(--tp-secondary);
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
  padding: 60px 0 30px;
  border-top: none;
  margin-top: var(--tp-section-gap);
}

.tp-footer__widgets {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--tp-gap-lg);
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 48px var(--tp-pad);
}

.tp-footer__logo {
  margin-bottom: 16px;
}

.tp-footer__logo img,
.tp-footer__logo-img {
  max-height: 36px;
  filter: brightness(0) invert(1);
}

.tp-footer__logo-text {
  font-family: var(--tp-font-heading);
  font-size: var(--tp-fs-xl);
  font-weight: 400;
  color: #fff;
  letter-spacing: -0.03em;
}

.tp-footer__description {
  font-size: var(--tp-fs-sm);
  line-height: 1.6;
  margin: 0 0 16px;
}

.tp-footer__social {
  display: flex;
  gap: 8px;
}

.tp-footer__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.5);
  transition: background var(--tp-ease-fast), color var(--tp-ease-fast);
}

.tp-footer__social-link:hover {
  background: var(--tp-primary);
  color: #fff;
}

.tp-footer__social-link svg {
  width: 16px;
  height: 16px;
}

/* Footer widget titles */
.tp-footer-widget__title {
  font-family: var(--tp-font-ui);
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  margin: 0 0 20px;
}

/* Footer category list */
.tp-footer__cat-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tp-footer__cat-list a {
  font-size: var(--tp-fs-sm);
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  justify-content: space-between;
  transition: color var(--tp-ease-fast), padding-left var(--tp-ease-fast);
}

.tp-footer__cat-list a:hover {
  color: #fff;
  padding-left: 4px;
}

.tp-footer__cat-count {
  font-size: var(--tp-fs-xs);
  opacity: 0.5;
}

/* Footer recent posts */
.tp-footer__recent-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tp-footer__recent-item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.tp-footer__recent-thumb {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-footer__recent-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-footer__recent-info {
  flex: 1;
  min-width: 0;
}

.tp-footer__recent-title {
  font-size: var(--tp-fs-sm);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
  transition: color var(--tp-ease-fast);
}

.tp-footer__recent-title:hover {
  color: #fff;
}

.tp-footer__recent-date {
  font-size: var(--tp-fs-xs);
  color: rgba(255, 255, 255, 0.4);
  display: block;
  margin-top: 2px;
}

/* Footer newsletter */
.tp-footer__newsletter-text {
  font-size: var(--tp-fs-sm);
  line-height: 1.6;
  margin: 0 0 12px;
}

.tp-footer__newsletter-form {
  display: flex;
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-footer__newsletter-input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: var(--tp-fs-sm);
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  outline: none;
  min-width: 0;
}

.tp-footer__newsletter-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.tp-footer__newsletter-btn {
  padding: 10px 16px;
  background: var(--tp-primary);
  color: #fff;
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background var(--tp-ease);
  white-space: nowrap;
}

.tp-footer__newsletter-btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.85);
}

/* Footer tagline */
.tp-footer__tagline {
  text-align: left;
  padding: 0;
  font-size: var(--tp-fs-sm);
  color: rgba(255, 255, 255, 0.5);
}

/* Footer bottom bar */
.tp-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tp-footer__bottom-container {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 20px var(--tp-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.tp-footer__copyright {
  font-size: var(--tp-fs-xs);
  color: rgba(255, 255, 255, 0.4);
  margin: 0;
}

.tp-footer__nav-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.tp-footer__nav-list a {
  font-size: var(--tp-fs-xs);
  color: rgba(255, 255, 255, 0.4);
  transition: color var(--tp-ease-fast);
}

.tp-footer__nav-list a:hover {
  color: #fff;
}

/* Footer Glossier overrides — centered single-column */
.tp-footer__grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}
.tp-footer__col { display: none; }
.tp-footer__col--brand { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.tp-footer__logo-img { filter: brightness(0) invert(1); }
.tp-footer__site-name { font-family: var(--tp-font-heading); font-size: 28px; color: #fff; }
.tp-footer__social { display: flex; justify-content: center; gap: 20px; }
.tp-footer__social-link { color: rgba(255,255,255,0.6); }
.tp-footer__social-link:hover { color: #fff; }
.tp-footer__heading { display: none; }
.tp-footer__menu { display: none; }
.tp-footer__col--newsletter { display: none; }
.tp-footer__bottom { border-top: 1px solid rgba(255,255,255,0.1); }
.tp-footer__copyright { color: rgba(255,255,255,0.4); font-size: 12px; }
.tp-footer__legal-menu { display: flex; justify-content: center; flex-wrap: wrap; gap: 24px; }
.tp-footer__legal-menu a { color: rgba(255,255,255,0.5); font-size: 13px; }
.tp-footer__nav { display: flex; justify-content: center; }


/* ==========================================================================
   41. Ad Zones
   ========================================================================== */

.ad-zone {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 90px;
  margin: var(--tp-gap) 0;
}

.ad-zone[data-size="300x250"] {
  min-height: 250px;
  max-width: 300px;
}

.ad-zone[data-size="300x600"] {
  min-height: 600px;
  max-width: 300px;
}

.ad-zone[data-size="728x90"] {
  min-height: 90px;
  max-width: 728px;
  margin-left: auto;
  margin-right: auto;
}

.ad-zone[data-size="320x50"] {
  min-height: 50px;
  max-width: 320px;
}

.ad-zone[data-size="responsive"] {
  min-height: 90px;
  width: 100%;
}

.ad-mobile-only {
  display: none;
}

.ad-sticky {
  position: sticky;
  top: 90px;
}


/* ==========================================================================
   42. WordPress Core Overrides
   ========================================================================== */

.wp-block-image,
.wp-block-gallery,
.wp-block-video,
.wp-block-audio,
.wp-block-embed {
  margin: 1.5em 0;
}

.wp-block-image img {
  border-radius: var(--tp-radius);
}

.alignwide {
  max-width: calc(var(--tp-container) - var(--tp-pad) * 2);
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.alignfull {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(-50vw + 50%);
}

.aligncenter {
  text-align: center;
}

.alignleft {
  float: left;
  margin-right: 1.5em;
  margin-bottom: 1em;
}

.alignright {
  float: right;
  margin-left: 1.5em;
  margin-bottom: 1em;
}

.wp-caption {
  max-width: 100%;
}

.wp-caption-text {
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
  text-align: center;
  margin-top: 8px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--tp-gap-sm);
  margin: 1.5em 0;
}

.gallery-item {
  margin: 0;
}

.gallery-item img {
  border-radius: var(--tp-radius);
}

.wp-block-separator {
  border: none;
  height: 2px;
  width: 60px;
  background: var(--tp-primary);
  margin: 2em auto;
}


/* ==========================================================================
   43. Focus & Accessibility
   ========================================================================== */

:focus-visible {
  outline: 2px solid var(--tp-primary);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--tp-primary);
  outline-offset: 2px;
}


/* ==========================================================================
   44. Reduced Motion
   ========================================================================== */

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

  .tp-hero__image--kenburns img {
    animation: none !important;
  }

  .tp-ticker__list {
    animation: none !important;
    overflow-x: auto;
  }

  .tp-card:hover {
    transform: none;
  }

  .tp-card:hover .tp-card__image {
    transform: none;
  }
}


/* ==========================================================================
   45. High Contrast
   ========================================================================== */

@media (prefers-contrast: high) {
  :root {
    --tp-border: #999;
    --tp-border-light: #999;
    --tp-text: #000;
    --tp-text-muted: #333;
  }

  .tp-card {
    border: 2px solid var(--tp-border);
  }

  .tp-nav__list > li > a::after {
    height: 3px;
  }

  .tp-widget {
    border: 2px solid var(--tp-border);
  }

  .tp-footer__bottom {
    border-top-width: 2px;
  }

  .tp-toc {
    border-width: 2px;
  }
}


/* ==========================================================================
   46. Print Styles
   ========================================================================== */

@media print {
  .tp-topbar,
  .tp-header,
  .tp-site-header,
  .tp-search-overlay,
  .tp-drawer,
  .tp-share,
  .tp-share--sidebar,
  .tp-share--mobile,
  .tp-back-to-top,
  .tp-footer,
  .tp-sidebar,
  .tp-content-area__sidebar,
  .tp-reading-progress,
  .tp-toc,
  .tp-tags,
  .tp-post-nav,
  .tp-related,
  .tp-comments,
  .tp-pagination,
  .tp-hero__trending,
  .tp-hero__cta,
  .ad-zone,
  .tp-newsletter-cta,
  .tp-widget--ad,
  .tp-widget--newsletter,
  .tp-hamburger,
  .tp-search-toggle,
  .tp-dark-toggle,
  .tp-skip-link,
  .tp-inline-newsletter,
  .tp-404__search,
  .tp-404__home {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 12pt;
    line-height: 1.6;
  }

  .tp-single__body {
    max-width: 100%;
  }

  .tp-single__content-area {
    display: block;
  }

  .tp-content-area {
    display: block;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
    color: #666;
    word-break: break-all;
  }

  a[href^="#"]::after,
  a[href^="javascript:"]::after {
    content: "";
  }

  .tp-hero {
    min-height: auto;
    page-break-inside: avoid;
  }

  .tp-card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ccc;
  }

  img {
    max-width: 100% !important;
  }
}


/* ==========================================================================
   47. Responsive — 1024px (Tablet Landscape)
   ========================================================================== */

@media (max-width: 1024px) {

  /* Typography — tablet */
  .tp-hero__title { font-size: 44px; line-height: 1.15; }
  .tp-logo__link, .tp-logo a { font-size: 30px; }
  .tp-card__title { font-size: 20px; }

  /* Grid fallback to 2-col */
  .tp-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tp-picks__grid {
    grid-template-columns: 1fr;
  }

  .tp-latest__grid,
  .tp-video__grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

  .tp-404__suggestions-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Content area — hide sidebar */
  .tp-content-area {
    grid-template-columns: 1fr;
  }

  .tp-content-area--left {
    grid-template-columns: 1fr;
  }

  .tp-content-area__sidebar {
    display: none;
  }

  /* Hamburger already visible at all sizes; hide desktop nav on mobile */
  .tp-nav {
    display: none;
  }

  .tp-subscribe-btn {
    display: none;
  }

  .tp-header__social {
    display: none;
  }

  /* Hero: single column */
  .tp-hero__inner {
    grid-template-columns: 1fr;
  }

  .tp-hero__trending {
    display: none;
  }

  /* Footer: 2-col */
  .tp-footer__widgets {
    grid-template-columns: 1fr 1fr;
  }

  /* Featured first: single col */
  .tp-card--featured-first .tp-card {
    grid-template-columns: 1fr;
  }

  .tp-single__content-area {
    grid-template-columns: 1fr;
  }

  .tp-share--sidebar {
    display: none;
  }

  .tp-share--mobile {
    display: flex;
  }

  /* Instagram: 4 items */
  .tp-instagram-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}


/* ==========================================================================
   48. Responsive — 768px / 480px / 375px
   ========================================================================== */

/* --- 768px (Tablet Portrait) --- */
@media (max-width: 768px) {

  :root {
    --tp-pad: 20px;
    --tp-gap: 20px;
    --tp-section-gap: 40px;
  }

  .tp-card__title { font-size: 20px; }
  .tp-section__title { font-size: 24px; }

  .tp-grid {
    grid-template-columns: 1fr;
  }

  .tp-picks__grid {
    grid-template-columns: 1fr;
  }

  .tp-dontmiss__grid {
    grid-template-columns: 1fr 1fr;
  }

  .tp-video-grid {
    grid-template-columns: 1fr;
  }

  .tp-404__suggestions-grid {
    grid-template-columns: 1fr;
  }

  .tp-hero {
    height: clamp(280px, 60vw, 400px);
    min-height: auto;
  }

  .tp-hero__inner {
    padding-bottom: 32px;
  }

  .tp-hero__title {
    font-size: clamp(1.25rem, 5vw, 2rem);
  }

  .tp-hero__excerpt {
    display: none;
  }

  .tp-hero__cta {
    padding: 0.5rem 1.25rem;
    font-size: 12px;
  }

  /* Cards — search card goes to single col */
  .tp-card--search,
  .tp-card--horizontal {
    grid-template-columns: 1fr;
  }

  .tp-card--search .tp-card__image-wrap,
  .tp-card--horizontal .tp-card__image-wrap {
    aspect-ratio: 16 / 10;
    min-height: auto;
  }

  /* Post navigation stacks */
  .tp-post-nav {
    grid-template-columns: 1fr;
  }

  .tp-post-nav__item--next {
    text-align: left;
  }

  /* Footer: 1-col stacked */
  .tp-footer__widgets {
    grid-template-columns: 1fr;
    gap: var(--tp-gap);
  }

  .tp-footer__bottom-container {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }

  /* Instagram: 3 items */
  .tp-instagram-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* Archive banner */
  .tp-archive__banner {
    padding: 24px;
  }

  .tp-archive__title {
    font-size: var(--tp-fs-2xl);
  }

  /* Single post adjustments */
  .tp-single__title {
    font-size: var(--tp-fs-2xl);
  }

  .tp-single__body-wrap {
    max-width: 100%;
  }

  /* Author bio stacks */
  .tp-author-bio {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  /* Mobile ad zone */
  .ad-mobile-only {
    display: flex;
  }

  /* Header tagline visible */
  .tp-header__tagline {
    display: none;
  }

  /* Page hero */
  .tp-page__hero {
    aspect-ratio: 16 / 9;
  }
}

/* --- 480px (Mobile) --- */
@media (max-width: 480px) {

  :root {
    --tp-pad: 16px;
    --tp-gap: 16px;
    --tp-section-gap: 32px;
  }

  body { font-size: 16px; }

  /* Typography — mobile (Glossier parity) */
  .tp-hero__title { font-size: 32px; line-height: 1.2; max-width: 100%; }
  .tp-logo__link, .tp-logo a { font-size: 24px; }
  .tp-nav { display: none; }
  .tp-card__title { font-size: 18px; }
  .tp-badge { font-size: 11px; padding: 2px 10px; }
  .tp-subscribe-btn { padding: 8px 16px; font-size: 13px; }
  .tp-section__title { font-size: 13px; }

  h1, .tp-archive__title, .tp-search-results__title {
    font-size: var(--tp-fs-2xl);
  }

  h2 {
    font-size: var(--tp-fs-xl);
  }

  .tp-hero {
    min-height: 300px;
  }

  .tp-hero__meta {
    flex-wrap: wrap;
    font-size: 11px;
    gap: 8px;
  }

  .tp-hero__cta {
    padding: 8px 18px;
    font-size: var(--tp-fs-xs);
  }

  .tp-404__code {
    font-size: 80px;
  }

  .tp-single__title {
    font-size: var(--tp-fs-xl);
  }

  .tp-single__body > p:first-of-type::first-letter {
    font-size: 2.5em;
  }

  .tp-dontmiss__grid {
    grid-template-columns: 1fr;
  }

  .tp-newsletter-cta {
    padding: 40px 16px;
  }

  .tp-newsletter-cta__title {
    font-size: var(--tp-fs-2xl);
  }

  .tp-newsletter-cta__form {
    flex-direction: column;
    border-radius: var(--tp-radius-md);
  }

  .tp-newsletter-cta__btn {
    border-radius: 0;
  }

  /* Card compact adjustments */
  .tp-card__body {
    padding: 12px;
  }

  .tp-card__excerpt {
    display: none;
  }

  /* Page template */
  .tp-page__hero-content {
    padding: 20px;
  }

  .tp-page__title--hero {
    font-size: var(--tp-fs-2xl);
  }

  /* Comment form fields */
  .tp-comments-area__list .children {
    margin-left: 16px;
    padding-left: 12px;
  }
}

/* --- 375px (Small Phone) --- */
@media (max-width: 375px) {

  :root {
    --tp-pad: 12px;
  }

  .tp-hero__title { font-size: 1.25rem; }
  .tp-section__title { font-size: 20px; }

  .tp-hero {
    height: 220px;
    min-height: auto;
  }

  .tp-hero__inner {
    padding-bottom: 24px;
  }

  .tp-hero__cat {
    font-size: 9px;
    padding: 2px 10px;
  }

  .tp-header__container {
    height: 56px;
  }

  .tp-logo__name {
    font-size: var(--tp-fs-lg);
  }

  .tp-ticker {
    height: 32px;
  }

  .tp-ticker__label {
    font-size: 10px;
    padding: 2px 8px;
  }

  .tp-card__meta {
    font-size: 10px;
  }

  .tp-archive__banner {
    padding: 16px;
  }

  .tp-footer__widgets {
    padding: 32px var(--tp-pad);
  }
}


/* ==========================================================================
   50. PHP Template Class Aliases
   --------------------------------------------------------------------------
   The v4 PHP templates output BEM class names that differ slightly from the
   original CSS selectors. These 49 rules close every gap so that every HTML
   element emitted by header.php, footer.php, index.php and template-parts/
   receives correct styling.  Do NOT delete — they are the glue between the
   PHP layer and the design system.
   ========================================================================== */

/* ---------- Category 1: Critical Layout Containers ---------------------- */

.tp-topbar__inner {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
  display: flex;
  align-items: center;
  gap: 12px;
}

.tp-header__inner {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 20px;
}

.tp-footer__grid {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 48px var(--tp-pad);
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr 1.2fr;
  gap: var(--tp-gap-lg);
}

.tp-footer__bottom-inner {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 20px var(--tp-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.tp-latest__inner,
.tp-video__inner,
.tp-picks__inner,
.tp-trending__inner,
.tp-dontmiss__inner {
  max-width: var(--tp-container);
  margin: 0 auto;
  padding: 0 var(--tp-pad);
}

.tp-newsletter__inner {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
  padding: 0 var(--tp-pad);
}

/* ---------- Category 2: Footer ------------------------------------------ */

.tp-footer__col {
  min-width: 0;
}

.tp-footer__col--brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.tp-footer__col--newsletter {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.tp-footer__heading {
  font-family: var(--tp-font-ui);
  font-size: var(--tp-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  margin-bottom: 1rem;
}

.tp-footer__menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.tp-footer__menu a {
  color: rgba(255, 255, 255, 0.5);
  font-size: var(--tp-fs-sm);
  transition: color var(--tp-ease-fast);
}

.tp-footer__menu a:hover {
  color: #fff;
}

.tp-footer__legal-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.tp-footer__legal-menu li {
  line-height: 1;
}

.tp-footer__legal-menu a {
  color: rgba(255, 255, 255, 0.4);
  font-size: var(--tp-fs-xs);
  transition: color var(--tp-ease-fast);
}

.tp-footer__legal-menu a:hover {
  color: #fff;
}

.tp-footer__nav {
  display: flex;
  align-items: center;
}

.tp-footer__site-name {
  font-family: var(--tp-font-heading);
  font-size: var(--tp-fs-xl);
  font-weight: 400;
  color: #fff;
  text-decoration: none;
}

.tp-footer__social {
  display: flex;
  gap: 0.75rem;
}

/* ---------- Category 3: Trending Section -------------------------------- */

.tp-trending {
  padding: 32px 0;
  background: var(--tp-bg-alt);
  border-top: 1px solid var(--tp-border);
  border-bottom: 1px solid var(--tp-border);
  margin-bottom: var(--tp-section-gap);
}

.tp-trending__swiper {
  overflow: hidden;
}

.tp-trending__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.tp-trending__number {
  font-size: var(--tp-fs-2xl);
  font-weight: 800;
  color: var(--tp-border);
  min-width: 32px;
  line-height: 1;
  flex-shrink: 0;
}

.tp-trending__body {
  flex: 1;
  min-width: 0;
}

.tp-trending__cat {
  font-size: 10px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--tp-primary);
  margin-bottom: 4px;
}

.tp-trending__title {
  font-size: var(--tp-fs-sm);
  font-weight: 600;
  color: var(--tp-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color var(--tp-ease-fast);
}

.tp-trending__title:hover {
  color: var(--tp-primary);
}

.tp-trending__icon {
  display: inline;
  vertical-align: middle;
  margin-right: 0.25rem;
}

/* ---------- Category 4: Card Meta --------------------------------------- */

.tp-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--tp-fs-xs);
  color: var(--tp-text-light);
}

.tp-meta__author {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.tp-meta__author img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.tp-meta__date {
  color: var(--tp-text-light);
}

.tp-meta__sep {
  opacity: 0.4;
}

/* ---------- Category 5: Badge ------------------------------------------- */

.tp-badge {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 3px 12px;
  border-radius: 30px;
  background: var(--tp-primary);
  color: #fff;
  display: inline-block;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.tp-badge:hover {
  opacity: 0.9;
  color: #fff;
}

.tp-badge--featured {
  background: rgba(255, 255, 255, 0.2);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

/* ---------- Category 6: Section Header Row ------------------------------ */

.tp-section__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.tp-section__more {
  font-family: var(--tp-font-ui);
  font-size: 13px;
  font-weight: 500;
  color: var(--tp-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
  border: 1.5px solid var(--tp-secondary);
  border-radius: 50px;
  padding: 8px 20px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.tp-section__more:hover {
  background: var(--tp-secondary);
  color: #fff;
}

.tp-section__more svg { display: none; } /* hide arrow icon — Glossier uses text only */

/* ---------- Category 7: Latest / Video Grids ---------------------------- */

.tp-latest {
  padding: var(--tp-section-gap) 0;
}

.tp-latest__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

.tp-video {
  padding: var(--tp-section-gap) 0;
}

.tp-video__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

/* ---------- Category 8: Picks Sub-Grid ---------------------------------- */

.tp-picks__primary {
  grid-column: span 2;
  grid-row: span 2;
}

.tp-picks__secondary {
  display: flex;
  flex-direction: column;
  gap: var(--tp-gap);
}

/* ---------- Category 9: Don't Miss Out Boxes ---------------------------- */

.tp-dontmiss__box {
  text-align: center;
  padding: 2rem;
  background: var(--tp-bg-alt);
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  transition: background var(--tp-ease), color var(--tp-ease), border-color var(--tp-ease);
}

.tp-dontmiss__box:hover {
  background: var(--tp-primary);
  color: #fff;
  border-color: var(--tp-primary);
}

.tp-dontmiss__box:hover .tp-dontmiss__label,
.tp-dontmiss__box:hover .tp-dontmiss__desc,
.tp-dontmiss__box:hover .tp-dontmiss__icon {
  color: #fff;
}

.tp-dontmiss__desc {
  font-size: var(--tp-fs-sm);
  color: var(--tp-text-light);
}

.tp-dontmiss__box h4 { font-family: var(--tp-font-heading); font-size: 21px; font-weight: 400; }
.tp-dontmiss__box a { font-family: var(--tp-font-ui); font-size: 12px; text-transform: uppercase; letter-spacing: 1px; color: var(--tp-primary); font-weight: 600; }

/* ---------- Category 10: Newsletter Form -------------------------------- */

.tp-newsletter__text {
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--tp-fs-base);
  margin-bottom: 1.5rem;
}

.tp-newsletter__form {
  display: flex;
  max-width: 480px;
  margin: 0 auto;
}

.tp-newsletter__form-row {
  display: flex;
  width: 100%;
}

/* ---------- Category 11: Ticker Content --------------------------------- */

.tp-ticker__content {
  display: flex;
  gap: 0;
  white-space: nowrap;
  animation: tp-ticker-scroll 50s linear infinite;
}

.tp-ticker__content:hover,
.tp-ticker__content:focus-within {
  animation-play-state: paused;
}

.tp-ticker__sep {
  margin: 0 1rem;
  opacity: 0.3;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- Category 12: Mobile Drawer ---------------------------------- */

.tp-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  width: 300px;
  max-width: 85vw;
  height: 100%;
  background: var(--tp-bg-alt);
  padding: 4rem 1.5rem 2rem;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform var(--tp-ease);
}

.tp-drawer[aria-hidden="false"] .tp-drawer__panel {
  transform: translateX(0);
}

.tp-drawer__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--tp-secondary);
}

.tp-drawer__nav {
  display: flex;
  flex-direction: column;
}

.tp-drawer__nav .tp-nav__list {
  display: flex;
  flex-direction: column;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}

.tp-drawer__nav .tp-nav__list a {
  display: block;
  padding: 0.875rem 0;
  text-transform: none;
  border-bottom: 1px solid var(--tp-border-light);
  color: var(--tp-secondary);
  font-size: var(--tp-fs-base);
  text-decoration: none;
  transition: color var(--tp-ease-fast);
}

.tp-drawer__nav .tp-nav__list a:hover {
  color: var(--tp-primary);
}

/* ---------- Category 13: Hero Secondary Meta ---------------------------- */

.tp-hero__date {
  color: rgba(255, 255, 255, 0.65);
  font-size: var(--tp-fs-sm);
}

.tp-hero__reading-time {
  color: rgba(255, 255, 255, 0.65);
  font-size: var(--tp-fs-sm);
}

.tp-hero__date::before,
.tp-hero__reading-time::before {
  content: "\00B7";
  margin: 0 0.5rem;
}

/* ---------- Section 50: Responsive overrides (768px) -------------------- */

@media (max-width: 768px) {
  .tp-footer__grid {
    grid-template-columns: 1fr;
    gap: var(--tp-gap-lg);
    padding: 32px var(--tp-pad);
  }

  .tp-footer__bottom-inner {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }

  .tp-footer__legal-menu {
    justify-content: center;
    gap: 1rem;
  }

  .tp-footer__nav {
    justify-content: center;
  }

  .tp-latest__grid,
  .tp-video__grid {
    grid-template-columns: 1fr;
  }

  .tp-picks__primary {
    grid-column: span 1;
    grid-row: span 1;
  }

  .tp-trending__item {
    min-width: 240px;
  }

  .tp-section__header {
    flex-direction: column;
    gap: 0.5rem;
  }

  .tp-header__inner {
    height: 56px;
  }

  .tp-newsletter__form {
    flex-direction: column;
  }

  .tp-newsletter__form-row {
    flex-direction: column;
  }

  .tp-dontmiss__box {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .tp-footer__grid {
    padding: 24px var(--tp-pad);
  }

  .tp-trending__number {
    font-size: var(--tp-fs-xl);
  }

  .tp-trending__title {
    font-size: var(--tp-fs-xs);
  }
}


/* ==========================================================================
   Scroll Reveal
   ========================================================================== */

.tp-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.tp-reveal--visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .tp-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}


/* ==========================================================================
   52. Hero Bottom Cards Strip (Glossier match)
   ========================================================================== */

.tp-hero-cards {
  background: var(--tp-bg-alt);
  border-bottom: 1px solid var(--tp-border-light);
}

.tp-hero-cards__inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.tp-hero-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 24px;
  border-right: 1px solid var(--tp-border-light);
  text-decoration: none;
  color: var(--tp-text);
  transition: background var(--tp-ease);
}

.tp-hero-card:last-child {
  border-right: none;
}

.tp-hero-card:hover {
  background: var(--tp-bg);
}

.tp-hero-card__image {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
}

.tp-hero-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-hero-card__placeholder {
  width: 100%;
  height: 100%;
  border-radius: 8px;
}

.tp-hero-card__title {
  font-family: var(--tp-font-heading);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.35;
  color: var(--tp-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0 0 4px;
}

.tp-hero-card__cat {
  font-family: var(--tp-font-ui);
  font-size: 11px;
  color: var(--tp-text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@media (max-width: 1024px) {
  .tp-hero-cards__inner {
    grid-template-columns: repeat(2, 1fr);
  }
  .tp-hero-card:nth-child(2) {
    border-right: none;
  }
}

@media (max-width: 768px) {
  .tp-hero-cards {
    display: none;
  }
}


/* ==========================================================================
   53. Latest Stories — Asymmetric Grid (Glossier match)
   ========================================================================== */

.tp-latest__row--top {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}

.tp-latest__row--featured {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--tp-gap);
  margin-top: var(--tp-gap);
}

.tp-latest__row--featured .tp-card--featured {
  min-height: 400px;
  border-radius: var(--tp-radius);
}

.tp-latest__stack {
  display: flex;
  flex-direction: column;
  gap: var(--tp-gap);
}

.tp-card--horizontal-sm {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  align-items: start;
}

.tp-card__image-wrap--sm {
  border-radius: var(--tp-radius);
  overflow: hidden;
  aspect-ratio: 1;
}

.tp-card__image-wrap--sm img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-card--horizontal-sm .tp-card__title {
  font-size: 16px;
}

@media (max-width: 768px) {
  .tp-latest__row--top {
    grid-template-columns: 1fr;
  }
  .tp-latest__row--featured {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   54. Editor's Picks — Grid + Writers Sidebar (Glossier match)
   ========================================================================== */

.tp-picks__layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--tp-gap-lg);
  align-items: start;
}

.tp-picks__cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--tp-gap);
}

.tp-picks__writers {
  background: var(--tp-bg);
  border-radius: var(--tp-radius-md);
  padding: 24px;
}

.tp-picks__writers-title {
  font-family: var(--tp-font-ui);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--tp-secondary);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--tp-border);
}

.tp-picks__writers-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tp-writer-card {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--tp-text);
  padding: 8px 0;
  border-bottom: 1px solid var(--tp-border-light);
  transition: color var(--tp-ease);
}

.tp-writer-card:last-child {
  border-bottom: none;
}

.tp-writer-card:hover {
  color: var(--tp-primary);
}

.tp-writer-card__avatar img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.tp-writer-card__title {
  font-family: var(--tp-font-heading);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.3;
  color: var(--tp-secondary);
  margin: 0 0 2px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-writer-card__author {
  font-family: var(--tp-font-ui);
  font-size: 11px;
  color: var(--tp-text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@media (max-width: 1024px) {
  .tp-picks__layout {
    grid-template-columns: 1fr;
  }
  .tp-picks__writers {
    display: none;
  }
}

@media (max-width: 768px) {
  .tp-picks__cards {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   55. Watch Now — Dark Section (Glossier match)
   ========================================================================== */

.tp-video {
  background: #1a1a1a;
  color: #fff;
  padding: var(--tp-section-gap) 0;
}

.tp-section__title--dark {
  color: #fff;
}

.tp-section__more--dark {
  color: rgba(255, 255, 255, 0.6);
}

.tp-section__more--dark:hover {
  color: #fff;
}

.tp-video__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  grid-template-rows: 1fr 1fr;
  gap: var(--tp-gap);
}

.tp-video-card--main {
  grid-row: span 2;
}

.tp-video-card__image {
  position: relative;
  border-radius: var(--tp-radius-md);
  overflow: hidden;
  aspect-ratio: 16 / 10;
}

.tp-video-card--main .tp-video-card__image {
  aspect-ratio: auto;
  height: 100%;
}

.tp-video-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-video-card__placeholder {
  width: 100%;
  height: 100%;
}

.tp-video-card__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 56px;
  height: 56px;
  background: var(--tp-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--tp-ease), box-shadow var(--tp-ease);
}

.tp-video-card:hover .tp-video-card__play {
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 8px 24px rgba(255, 68, 68, 0.4);
}

.tp-video-card__play svg {
  margin-left: 3px;
}

.tp-video-card__cat {
  font-family: var(--tp-font-ui);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--tp-primary);
  margin-bottom: 4px;
  display: block;
}

.tp-video-card__title {
  font-family: var(--tp-font-heading);
  font-weight: 400;
  line-height: 1.3;
  margin: 0;
}

.tp-video-card--main .tp-video-card__title {
  font-size: 20px;
}

.tp-video-card--side .tp-video-card__title {
  font-size: 15px;
}

.tp-video-card__title a {
  color: #fff;
  text-decoration: none;
}

.tp-video-card__title a:hover {
  color: var(--tp-primary);
}

.tp-video-card__body {
  padding: 12px 0 0;
}

@media (max-width: 768px) {
  .tp-video__grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .tp-video-card--main {
    grid-row: span 1;
  }
  .tp-video-card--main .tp-video-card__image {
    aspect-ratio: 16 / 10;
    height: auto;
  }
}


/* ==========================================================================
   49. Dark Mode
   ========================================================================== */

[data-theme="dark"] {
  --tp-secondary: #E5E5E5;
  --tp-text: #D4D4D4;
  --tp-text-light: #737373;
  --tp-text-muted: #9CA3AF;
  --tp-bg: #0A0A0A;
  --tp-bg-alt: #171717;
  --tp-border: #262626;
  --tp-border-light: #1C1C1C;
  --tp-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.3);
  --tp-shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.4);
  color-scheme: dark;
}

/* Header dark overrides */
[data-theme="dark"] .tp-header {
  background: #0A0A0A;
  border-bottom-color: var(--tp-border);
}

[data-theme="dark"] .tp-header.tp-header--scrolled {
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .tp-logo__name {
  color: #fff;
}

[data-theme="dark"] .tp-hamburger__line {
  background: #E5E5E5;
}

[data-theme="dark"] .tp-dark-toggle:hover {
  background: var(--tp-border);
}

[data-theme="dark"] .tp-search-toggle:hover {
  background: var(--tp-border);
}

/* Card dark overrides */
[data-theme="dark"] .tp-card {
  background: var(--tp-bg-alt);
}

[data-theme="dark"] .tp-card__title a {
  color: #E5E5E5;
}

[data-theme="dark"] .tp-card__title a:hover {
  color: var(--tp-primary);
}

/* Dropdown dark */
[data-theme="dark"] .tp-nav__list .sub-menu {
  background: #171717;
  border-color: var(--tp-border);
}

[data-theme="dark"] .tp-nav__list .sub-menu li a:hover {
  background: var(--tp-border);
}

/* Sidebar dark */
[data-theme="dark"] .tp-widget {
  background: var(--tp-bg-alt);
}

[data-theme="dark"] .tp-widget--newsletter {
  background: #262626;
}

[data-theme="dark"] .tp-newsletter__input {
  background: #0A0A0A;
  color: #D4D4D4;
}

[data-theme="dark"] .tp-recent__link:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .tp-topics__pill {
  background: var(--tp-border);
  border-color: #404040;
  color: #D4D4D4;
}

[data-theme="dark"] .tp-topics__count {
  background: rgba(255, 255, 255, 0.08);
  color: var(--tp-text-light);
}

/* Single post dark */
[data-theme="dark"] .tp-single__body code {
  background: var(--tp-border);
}

[data-theme="dark"] .tp-single__body blockquote {
  background: var(--tp-bg-alt);
  border-left-color: var(--tp-primary);
}

[data-theme="dark"] .tp-single__body thead {
  background: #262626;
  color: #E5E5E5;
}

[data-theme="dark"] .tp-single__body tbody tr:nth-child(even) {
  background: var(--tp-bg-alt);
}

[data-theme="dark"] .tp-single__body table th,
[data-theme="dark"] .tp-single__body table td {
  border-color: var(--tp-border);
}

/* TOC dark */
[data-theme="dark"] .tp-toc {
  background: var(--tp-bg-alt);
  border-color: var(--tp-border);
}

/* Tags dark */
[data-theme="dark"] .tp-tags a {
  border-color: var(--tp-border);
  color: #9CA3AF;
}

[data-theme="dark"] .tp-tags a:hover {
  color: #fff;
}

/* Author bio dark */
[data-theme="dark"] .tp-author-bio {
  border-color: var(--tp-border);
}

[data-theme="dark"] .tp-author-bio__name a {
  color: #E5E5E5;
}

/* Post nav dark */
[data-theme="dark"] .tp-post-nav__item {
  background: var(--tp-bg-alt);
}

[data-theme="dark"] .tp-post-nav__title {
  color: #E5E5E5;
}

/* Comments dark */
[data-theme="dark"] .tp-comments-area__list .comment {
  border-bottom-color: var(--tp-border);
}

[data-theme="dark"] .tp-comments-area__list .children {
  border-left-color: var(--tp-border);
}

[data-theme="dark"] .tp-comment-form input[type="text"],
[data-theme="dark"] .tp-comment-form input[type="email"],
[data-theme="dark"] .tp-comment-form input[type="url"],
[data-theme="dark"] .tp-comment-form__textarea {
  background: #0A0A0A;
  color: #D4D4D4;
  border-color: var(--tp-border);
}

/* Share buttons dark */
[data-theme="dark"] .tp-share__btn {
  background: var(--tp-bg-alt);
}

/* Search form dark */
[data-theme="dark"] .tp-search-form {
  border-color: var(--tp-border);
  background: var(--tp-bg-alt);
}

[data-theme="dark"] .tp-search-form__input {
  color: #D4D4D4;
}

/* Pagination dark */
[data-theme="dark"] .tp-pagination .page-numbers {
  border-color: var(--tp-border);
  color: #9CA3AF;
}

[data-theme="dark"] .tp-pagination .page-numbers:hover {
  color: #fff;
  border-color: #fff;
}

/* Footer dark — already dark, minor adjustments */
[data-theme="dark"] .tp-footer {
  background: #0A0A0A;
}

[data-theme="dark"] .tp-footer__bottom {
  border-top-color: rgba(255, 255, 255, 0.06);
}

/* Footer newsletter input dark */
[data-theme="dark"] .tp-footer__newsletter-input {
  background: #171717;
  color: #D4D4D4;
}

/* Archive banner dark */
[data-theme="dark"] .tp-archive__banner {
  background: #171717;
}

/* Newsletter CTA dark */
[data-theme="dark"] .tp-newsletter-cta {
  background: #171717;
}

/* 404 dark */
[data-theme="dark"] .tp-404__code {
  color: var(--tp-border);
}

/* Hero scrim: stronger in dark mode for contrast */
[data-theme="dark"] .tp-hero__overlay {
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.85) 0%,
    rgba(0, 0, 0, 0.6) 30%,
    rgba(0, 0, 0, 0.25) 60%,
    transparent 100%
  );
}

/* Back to top dark */
[data-theme="dark"] .tp-back-to-top {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* Inline newsletter dark */
[data-theme="dark"] .tp-inline-newsletter {
  background: #171717;
}

/* Page hero dark */
[data-theme="dark"] .tp-page__hero-overlay {
  background: linear-gradient(to top, rgba(0, 0, 0, 0.75), transparent);
}

/* --- Section 50 dark mode overrides --- */

/* Trending dark */
[data-theme="dark"] .tp-trending {
  background: var(--tp-bg-alt);
  border-top-color: var(--tp-border);
  border-bottom-color: var(--tp-border);
}

[data-theme="dark"] .tp-trending__number {
  color: var(--tp-border);
}

[data-theme="dark"] .tp-trending__title {
  color: #E5E5E5;
}

/* Don't-miss dark */
[data-theme="dark"] .tp-dontmiss__box {
  background: var(--tp-bg-alt);
  border-color: var(--tp-border);
}

[data-theme="dark"] .tp-dontmiss__desc {
  color: var(--tp-text-light);
}

/* Meta dark */
[data-theme="dark"] .tp-meta {
  color: var(--tp-text-light);
}

[data-theme="dark"] .tp-meta__date {
  color: var(--tp-text-light);
}

/* Drawer dark */
[data-theme="dark"] .tp-drawer__panel {
  background: #171717;
}

[data-theme="dark"] .tp-drawer__close {
  color: #E5E5E5;
}

[data-theme="dark"] .tp-drawer__nav .tp-nav__list a {
  color: #D4D4D4;
  border-bottom-color: var(--tp-border);
}

[data-theme="dark"] .tp-drawer__nav .tp-nav__list a:hover {
  color: var(--tp-primary);
}

/* Badge dark — primary bg stays; featured variant adjusts */
[data-theme="dark"] .tp-badge--featured {
  background: rgba(255, 255, 255, 0.12);
}

/* Footer heading dark (footer already dark, but ensure consistency) */
[data-theme="dark"] .tp-footer__heading {
  color: #E5E5E5;
}


/* ==========================================================================
   51. Scroll-Reveal Animations
   ========================================================================== */

.tp-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.tp-reveal--visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .tp-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}


/* ==========================================================================
   52. Featured Article + Trending Sidebar (Glossier 3-column)
   ========================================================================== */

.tp-featured-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr 0.8fr;
  gap: 40px;
  padding-top: 60px;
  padding-bottom: 60px;
  align-items: start;
}
.tp-featured__text { display: flex; flex-direction: column; justify-content: center; }
.tp-featured__text h2 {
  font-family: 'Gloock', Georgia, serif;
  font-size: 36px;
  font-weight: 400;
  line-height: 1.3;
  color: var(--tp-secondary);
  margin: 0 0 12px;
}
.tp-featured__text h2 a { color: inherit; text-decoration: none; }
.tp-featured__text h2 a:hover { color: var(--tp-primary); }
.tp-featured__meta {
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}
.tp-featured__excerpt {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  line-height: 1.6;
  color: var(--tp-text);
  margin: 0;
}
.tp-featured__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.tp-trending-sidebar {
  border-left: 1px solid var(--tp-border);
  padding-left: 30px;
}
.tp-trending-sidebar__title {
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--tp-secondary);
  border-bottom: 3px solid var(--tp-primary);
  padding-bottom: 10px;
  margin-bottom: 20px;
}
.tp-trending-sidebar__item {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  align-items: flex-start;
}
.tp-trending-sidebar__number {
  font-family: var(--tp-font-heading);
  font-size: 36px;
  font-weight: 400;
  color: #e0e0e0;
  line-height: 1;
  min-width: 40px;
}
.tp-trending-sidebar__cat {
  font-family: var(--tp-font-ui);
  font-size: 10px;
  text-transform: uppercase;
  color: #999;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 4px;
}
.tp-trending-sidebar__content h4,
.tp-trending-sidebar h3 {
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--tp-secondary);
  margin: 0;
}
.tp-trending-sidebar__content h4 a { color: inherit; text-decoration: none; }
.tp-trending-sidebar__content h4 a:hover { color: var(--tp-primary); }


/* ==========================================================================
   53. Responsive — Glossier Overrides
   ========================================================================== */

@media (max-width: 1024px) {
  .tp-hero__title { font-size: 34px; }
  .tp-hero { min-height: 65vh; }
  .tp-featured-layout { grid-template-columns: 1fr 1fr; gap: 24px; }
  .tp-trending-sidebar { grid-column: 1 / -1; border-left: none; padding-left: 0; border-top: 1px solid var(--tp-border); padding-top: 24px; }
  .tp-latest__row--top, .tp-latest__grid { grid-template-columns: repeat(2, 1fr); }
  .tp-picks__layout { grid-template-columns: 1fr; }
  .tp-dontmiss__grid { grid-template-columns: repeat(2, 1fr); }
  .tp-section__title { font-size: 28px; }
}

@media (max-width: 767px) {
  .tp-hero { min-height: 55vh; }
  .tp-hero__title { font-size: 28px; line-height: 1.2; }
  .tp-hero__content { bottom: 24px; }
  .tp-featured-layout { grid-template-columns: 1fr; gap: 20px; }
  .tp-latest__row--top, .tp-latest__grid { grid-template-columns: 1fr; }
  .tp-dontmiss__grid { grid-template-columns: 1fr; }
  .tp-section__title { font-size: 24px; }
  .tp-footer__legal-menu { flex-direction: column; gap: 12px; }
}

@media (min-width: 1440px) {
  .tp-hero__title { font-size: 48px; }
  .tp-section__title { font-size: 36px; }
  .tp-featured__text h2 { font-size: 38px; }
}

/* ==========================================================================
   Podcasts Section (NEW)
   ========================================================================== */
.tp-podcasts {
  padding: var(--tp-section-gap) 0;
  background: var(--tp-secondary);
  color: #fff;
}
.tp-podcasts .tp-section__title { color: #fff; }
.tp-podcasts .tp-section__more {
  color: rgba(255,255,255,0.7);
  border-color: rgba(255,255,255,0.3);
}
.tp-podcasts .tp-section__more:hover {
  background: #fff;
  color: var(--tp-secondary);
}
.tp-podcasts__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--tp-gap);
}
.tp-card--podcast {
  background: transparent;
  border-radius: 0;
  box-shadow: none;
}
.tp-card--podcast .tp-card__image-wrap {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--tp-radius-md);
  overflow: hidden;
}
.tp-card--podcast .tp-card__image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.tp-card--podcast:hover .tp-card__image-wrap img {
  transform: scale(1.05);
}
.tp-card__play--podcast {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  background: var(--tp-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}
.tp-card--podcast:hover .tp-card__play--podcast {
  transform: translate(-50%, -50%) scale(1.1);
}
.tp-card--podcast .tp-card__body { padding: 12px 0 0; }
.tp-card--podcast .tp-card__title {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: #fff;
  margin: 0;
}
.tp-card--podcast .tp-card__title a { color: #fff; text-decoration: none; }
.tp-card--podcast .tp-card__cat-small {
  font-family: 'Poppins', sans-serif;
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--tp-primary);
  display: block;
  margin-bottom: 4px;
}

/* ==========================================================================
   Recommended Section (NEW)
   ========================================================================== */
.tp-recommended {
  padding: var(--tp-section-gap) 0;
  background: var(--tp-bg-alt);
}
.tp-recommended__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tp-gap);
}
.tp-recommended .tp-card__image-wrap {
  border-radius: 12px;
  overflow: hidden;
}
.tp-recommended .tp-card__title { font-size: 18px; }

/* ==========================================================================
   Instagram Feed (NEW)
   ========================================================================== */
.tp-instagram { width: 100%; }
.tp-instagram__grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0;
}
.tp-instagram__item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  display: block;
}
.tp-instagram__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.tp-instagram__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.tp-instagram__item:hover img { transform: scale(1.05); }
.tp-instagram__item:hover .tp-instagram__overlay { opacity: 1; }

/* ==========================================================================
   Drawer Enhancements (NEW)
   ========================================================================== */
.tp-drawer__search {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--tp-border);
}
.tp-drawer__search-input {
  width: 100%;
  padding: 12px 20px;
  border: 1.5px solid var(--tp-border);
  border-radius: 30px;
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  outline: none;
}
.tp-drawer__search-input:focus { border-color: var(--tp-primary); }
.tp-drawer__section {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--tp-border);
}
.tp-drawer__heading {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--tp-text-light);
  margin-bottom: 16px;
}
.tp-drawer__categories {
  list-style: none;
  padding: 0;
  margin: 0;
}
.tp-drawer__categories li { margin-bottom: 12px; }
.tp-drawer__categories a {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  color: var(--tp-text);
  text-decoration: none;
}
.tp-drawer__categories a:hover { color: var(--tp-primary); }
.tp-drawer__social {
  display: flex;
  gap: 12px;
}
.tp-drawer__social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1.5px solid var(--tp-border);
  border-radius: 50%;
  color: var(--tp-text);
  transition: all 0.3s ease;
}
.tp-drawer__social a:hover {
  background: var(--tp-primary);
  border-color: var(--tp-primary);
  color: #fff;
}

/* Responsive for new sections */
@media (max-width: 1024px) {
  .tp-podcasts__grid { grid-template-columns: repeat(2, 1fr); }
  .tp-recommended__grid { grid-template-columns: repeat(2, 1fr); }
  .tp-instagram__grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 480px) {
  .tp-podcasts__grid { grid-template-columns: 1fr; }
  .tp-recommended__grid { grid-template-columns: 1fr; }
  .tp-instagram__grid { grid-template-columns: repeat(2, 1fr); }
}

/* ==========================================================================
   Newsletter Forms — unified pill design (v4.7.7)
   Overrides earlier .tp-newsletter and .tp-inline-newsletter form rules.
   ========================================================================== */

/* ---------- Home section newsletter (section-newsletter.php) ------------- */

.tp-newsletter__form {
  display: block;
  max-width: 560px;
  margin: 0 auto;
}

.tp-newsletter__form-row {
  display: flex;
  align-items: stretch;
  width: 100%;
  background: #fff;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
  padding: 6px 6px 6px 8px;
  gap: 0;
}

.tp-newsletter__form-row:focus-within {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25),
              0 0 0 2px var(--tp-primary);
}

.tp-newsletter__input,
.tp-newsletter__form-row .tp-newsletter__input {
  flex: 1 1 0;
  min-width: 0;
  width: 100%;
  padding: 14px 20px;
  border: none;
  outline: none;
  background: transparent;
  color: var(--tp-text);
  font-family: var(--tp-font-body);
  font-size: 16px;
  line-height: 1.4;
  box-shadow: none;
}

.tp-newsletter__input::placeholder {
  color: #9ca3af;
  opacity: 1;
}

.tp-newsletter__input:focus {
  box-shadow: none;
}

.tp-newsletter__form-row .tp-newsletter__btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border: none;
  border-radius: 999px;
  background: var(--tp-primary);
  color: #fff;
  font-family: var(--tp-font-ui);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-transform: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.tp-newsletter__form-row .tp-newsletter__btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.9);
  transform: none;
}

.tp-newsletter__form-row .tp-newsletter__btn:active {
  transform: translateY(1px);
}

.tp-newsletter__privacy {
  font-size: 12px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.55);
  margin: 16px 0 0;
}

/* ---------- Inline article newsletter (inline-newsletter.php) ------------ */

.tp-inline-newsletter {
  background: var(--tp-secondary);
  color: #fff;
  border-radius: 16px;
  padding: 48px 32px;
  text-align: center;
  margin: 48px 0;
}

.tp-inline-newsletter__title {
  font-family: var(--tp-font-heading);
  font-size: 28px;
  font-weight: 400;
  line-height: 1.2;
  color: #fff;
  margin: 0 0 10px;
}

.tp-inline-newsletter__text {
  font-family: var(--tp-font-body);
  font-size: 15px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
  margin: 0 auto 24px;
  max-width: 440px;
}

.tp-inline-newsletter__form {
  display: block;
  max-width: 480px;
  margin: 0 auto;
  background: transparent;
  border-radius: 0;
  overflow: visible;
}

.tp-inline-newsletter__field {
  display: flex;
  align-items: stretch;
  width: 100%;
  background: #fff;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  padding: 6px 6px 6px 8px;
  gap: 0;
}

.tp-inline-newsletter__field:focus-within {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3),
              0 0 0 2px var(--tp-primary);
}

.tp-inline-newsletter__input,
.tp-inline-newsletter__field .tp-inline-newsletter__input {
  flex: 1 1 0;
  min-width: 0;
  width: 100%;
  padding: 13px 20px;
  border: none;
  outline: none;
  background: transparent;
  color: var(--tp-text);
  font-family: var(--tp-font-body);
  font-size: 15px;
  line-height: 1.4;
  box-shadow: none;
}

.tp-inline-newsletter__input::placeholder {
  color: #9ca3af;
  opacity: 1;
}

.tp-inline-newsletter__field .tp-inline-newsletter__btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 26px;
  border: none;
  border-radius: 999px;
  background: var(--tp-primary);
  color: #fff;
  font-family: var(--tp-font-ui);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-transform: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.tp-inline-newsletter__field .tp-inline-newsletter__btn:hover {
  background: rgba(var(--tp-primary-rgb), 0.9);
}

.tp-inline-newsletter__field .tp-inline-newsletter__btn:active {
  transform: translateY(1px);
}

/* ---------- Mobile: stack input + button vertically --------------------- */

@media (max-width: 560px) {
  .tp-newsletter__form-row,
  .tp-inline-newsletter__field {
    flex-direction: column;
    background: transparent;
    box-shadow: none;
    padding: 0;
    gap: 10px;
    border-radius: 0;
    overflow: visible;
  }

  .tp-newsletter__form-row:focus-within,
  .tp-inline-newsletter__field:focus-within {
    box-shadow: none;
  }

  .tp-newsletter__form-row .tp-newsletter__input,
  .tp-inline-newsletter__field .tp-inline-newsletter__input {
    width: 100%;
    padding: 14px 20px;
    background: #fff;
    border-radius: 999px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
  }

  .tp-newsletter__form-row .tp-newsletter__btn,
  .tp-inline-newsletter__field .tp-inline-newsletter__btn {
    width: 100%;
    padding: 14px 28px;
  }

  .tp-inline-newsletter {
    padding: 36px 20px;
  }

  .tp-inline-newsletter__title {
    font-size: 24px;
  }
}

/* ---------- Dark mode tweaks -------------------------------------------- */

[data-theme="dark"] .tp-newsletter__form-row,
[data-theme="dark"] .tp-inline-newsletter__field {
  background: #fff;
}

[data-theme="dark"] .tp-newsletter__input,
[data-theme="dark"] .tp-inline-newsletter__input {
  color: #1a1a1a;
}

/* ==========================================================================
   Latest Stories — Glossier 1:1 layout (v4.7.8)
   Scoped under .tp-stories to avoid collision with legacy .tp-latest__row--* rules.
   ========================================================================== */

.tp-stories {
  padding: 80px 0;
}

/* Hide any legacy rows if they somehow render alongside new markup. */
.tp-stories .tp-latest__row,
.tp-stories .tp-section__header {
  display: none;
}

/* ---------- Header row + divider ---------------------------------------- */

.tp-stories__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin: 0 0 24px;
}

.tp-stories__title {
  font-family: var(--tp-font-heading);
  font-weight: 400;
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--tp-secondary);
  margin: 0;
}

.tp-stories__more {
  font-family: var(--tp-font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--tp-secondary);
  text-decoration: none;
  text-transform: none;
  letter-spacing: 0;
  border: none;
  padding: 0 0 4px;
  background: none;
  border-radius: 0;
  position: relative;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.tp-stories__more::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
}

.tp-stories__more:hover {
  color: var(--tp-primary);
  background: none;
}

.tp-stories__more svg {
  display: none;
}

.tp-stories__divider {
  height: 2px;
  background: var(--tp-secondary);
  border: 0;
  margin: 0 0 48px;
  opacity: 1;
}

/* ---------- 3-column grid ------------------------------------------------ */

.tp-stories__grid {
  display: grid;
  grid-template-columns: 1fr 1.75fr 1fr;
  gap: 40px;
  align-items: start;
}

.tp-stories__side {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

/* ---------- Side cards --------------------------------------------------- */

.tp-stories__card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}

.tp-stories__card-image {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f5f5f5);
}

.tp-stories__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.tp-stories__card:hover .tp-stories__card-image img {
  transform: scale(1.04);
}

.tp-stories__card-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

.tp-stories__card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0 4px;
}

.tp-stories__card-cat {
  font-family: var(--tp-font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--tp-secondary);
  text-decoration: none;
  background: none;
  padding: 0;
  border: none;
  border-radius: 0;
  line-height: 1;
  align-self: flex-start;
  transition: color 0.2s ease;
}

.tp-stories__card-cat:hover {
  color: var(--tp-primary);
  background: none;
}

.tp-stories__card-title {
  font-family: var(--tp-font-heading);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-stories__card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-stories__card-title a:hover {
  color: var(--tp-primary);
}

/* ---------- Featured (center) card -------------------------------------- */

.tp-stories__feature {
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-align: center;
  align-items: center;
}

.tp-stories__feature-image {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 20px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f5f5f5);
}

.tp-stories__feature-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.tp-stories__feature:hover .tp-stories__feature-image img {
  transform: scale(1.03);
}

.tp-stories__feature-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

.tp-stories__feature-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 8px 8% 0;
  max-width: 100%;
}

.tp-stories__feature-badge {
  display: inline-block;
  background: var(--tp-primary);
  color: #fff;
  font-family: var(--tp-font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  padding: 7px 18px;
  border-radius: 999px;
  text-decoration: none;
  line-height: 1;
  transition: background 0.2s ease;
}

.tp-stories__feature-badge:hover {
  background: rgba(var(--tp-primary-rgb), 0.9);
  color: #fff;
}

.tp-stories__feature-title {
  font-family: var(--tp-font-heading);
  font-weight: 700;
  font-size: clamp(28px, 2.6vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.005em;
  color: var(--tp-secondary);
  margin: 0;
}

.tp-stories__feature-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-stories__feature-title a:hover {
  color: var(--tp-primary);
}

.tp-stories__feature-excerpt {
  font-family: var(--tp-font-body);
  font-size: 16px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.6);
  margin: 0;
  max-width: 92%;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- Meta row (clock + date + by author) ------------------------- */

.tp-stories__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--tp-font-body);
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
  margin-top: 4px;
}

.tp-stories__meta--feature {
  justify-content: center;
  margin-top: 4px;
}

.tp-stories__clock {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(0, 0, 0, 0.45);
}

.tp-stories__date {
  color: rgba(0, 0, 0, 0.55);
  font-weight: 400;
}

.tp-stories__by {
  color: rgba(0, 0, 0, 0.55);
  font-weight: 400;
}

.tp-stories__by strong {
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--tp-secondary);
  margin-left: 2px;
}

/* ---------- Responsive --------------------------------------------------- */

@media (max-width: 1200px) {
  .tp-stories__grid {
    gap: 32px;
  }
  .tp-stories__side {
    gap: 40px;
  }
}

@media (max-width: 1024px) {
  .tp-stories__grid {
    grid-template-columns: 1fr 1fr;
  }
  .tp-stories__feature {
    grid-column: 1 / -1;
    order: -1;
  }
  .tp-stories__feature-image {
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .tp-stories {
    padding: 56px 0;
  }
  .tp-stories__header {
    align-items: flex-end;
  }
  .tp-stories__title {
    font-size: clamp(32px, 9vw, 44px);
  }
  .tp-stories__divider {
    margin-bottom: 32px;
  }
  .tp-stories__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .tp-stories__side {
    gap: 40px;
  }
  .tp-stories__feature {
    order: 0;
  }
  .tp-stories__feature-title {
    font-size: clamp(26px, 6vw, 32px);
  }
  .tp-stories__feature-body {
    padding-left: 0;
    padding-right: 0;
  }
}

@media (max-width: 480px) {
  .tp-stories__card-title {
    font-size: 19px;
  }
  .tp-stories__meta {
    font-size: 12px;
  }
}

/* ---------- Dark mode --------------------------------------------------- */

[data-theme="dark"] .tp-stories__title,
[data-theme="dark"] .tp-stories__more,
[data-theme="dark"] .tp-stories__card-title,
[data-theme="dark"] .tp-stories__card-title a,
[data-theme="dark"] .tp-stories__feature-title,
[data-theme="dark"] .tp-stories__feature-title a,
[data-theme="dark"] .tp-stories__card-cat,
[data-theme="dark"] .tp-stories__by strong {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-stories__divider {
  background: #f5f5f5;
}

[data-theme="dark"] .tp-stories__feature-excerpt,
[data-theme="dark"] .tp-stories__meta,
[data-theme="dark"] .tp-stories__date,
[data-theme="dark"] .tp-stories__by,
[data-theme="dark"] .tp-stories__clock {
  color: rgba(255, 255, 255, 0.6);
}

/* ==========================================================================
   Hero — Glossier 1:1 layout (v4.7.9)
   Scoped under .tp-hero--glossier; overrides legacy .tp-hero__content rules.
   Header (.tp-header) stays solid white per prior user decision.
   ========================================================================== */

.tp-hero--glossier {
  position: relative;
  width: 100%;
  height: 800px;
  min-height: 800px;
  max-height: 800px;
  overflow: hidden;
  isolation: isolate;
}

.tp-hero--glossier .tp-hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
  transform: scale(1.02);
  transition: transform 1.6s ease;
}

.tp-hero--glossier:hover .tp-hero__bg {
  transform: scale(1.05);
}

/* Single directional scrim — very light, matches Glossier's clean look.
   Only darkens the left side slightly for text legibility; right side clear. */
.tp-hero--glossier .tp-hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg, rgba(0, 0, 0, 0.42) 0%, rgba(0, 0, 0, 0.22) 38%, rgba(0, 0, 0, 0) 72%);
  pointer-events: none;
}

.tp-hero--glossier .tp-hero__wrap {
  position: relative;
  z-index: 2;
  height: 100%;
  min-height: inherit;
  display: flex;
  align-items: flex-end;           /* content anchors to bottom, per Glossier */
  padding-top: 100px;
  padding-bottom: 60px;             /* pulls content 60px off the bottom edge */
  padding-left: 0;                  /* zero out tp-container gutter for pixel-exact x=320 match */
  padding-right: 0;
}

.tp-hero--glossier .tp-hero__content {
  position: static;
  inset: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 15px;                         /* pill → title gap (exact Glossier) */
  max-width: 680px;                  /* exact Glossier title width */
  width: 100%;
  bottom: auto;
  left: auto;
  right: auto;
  margin: 0;
}

/* Red pill badge — exact Glossier spec: 3px 12px / 30px radius / Poppins 12/500/1px */
.tp-hero--glossier .tp-hero__pill {
  display: inline-block;
  padding: 3px 12px;
  background: #FF4444;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  border-radius: 30px;
  text-decoration: none;
  margin: 0;
  transition: background 0.2s ease;
  box-shadow: none;
}

.tp-hero--glossier .tp-hero__pill:hover {
  background: #e63939;
  transform: none;
}

/* Serif title — exact Glossier spec: Gloock 62px / 400 / 1.1 / normal tracking */
.tp-hero--glossier .tp-hero__title {
  font-family: 'Gloock', Georgia, serif;
  font-weight: 400;                  /* Gloock is a single-weight font */
  font-size: 62px;
  line-height: 1.1;
  letter-spacing: normal;
  color: #fff;
  margin: 0;
  max-width: 680px;                  /* exact Glossier title width */
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.35);
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: manual;
}

.tp-hero--glossier .tp-hero__title a {
  color: inherit;
  text-decoration: none;
  background: none;
}

.tp-hero--glossier .tp-hero__title a:hover {
  color: inherit;
  text-decoration: none;
  opacity: 0.92;
}

/* Meta row — exact Glossier spec: PT Serif 18px / 400 / gap 15px */
.tp-hero--glossier .tp-hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 15px;
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
  text-transform: none;
  letter-spacing: normal;
  margin: 25px 0 0;                  /* 15 (gap) + 25 (margin) = 40px title→meta */
}

.tp-hero--glossier .tp-hero__clock {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(255, 255, 255, 0.7);
  width: 16px;
  height: 16px;
  margin-right: -8px;                /* tighten gap to icon+date grouping */
}

.tp-hero--glossier .tp-hero__date {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
  font-size: 18px;
}

.tp-hero--glossier .tp-hero__by {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  color: rgba(255, 255, 255, 0.75);
  margin-left: 0;
  padding-left: 0;
  position: relative;
  text-transform: none;
  font-weight: 400;
  font-size: 18px;
}

.tp-hero--glossier .tp-hero__by::before {
  content: none;                      /* Glossier uses plain gap, no dot */
}

.tp-hero--glossier .tp-hero__by strong {
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-size: 14px;
}

/* Neutralize legacy rules that show up with .tp-hero but not .tp-hero--glossier */
.tp-hero--glossier .tp-badge--hero,
.tp-hero--glossier .tp-hero__cat,
.tp-hero--glossier .tp-hero__meta-sep,
.tp-hero--glossier .tp-hero__excerpt,
.tp-hero--glossier .tp-hero__cta,
.tp-hero--glossier .tp-hero__author,
.tp-hero--glossier .tp-hero__reading-time {
  display: none;
}

/* ---------- Responsive --------------------------------------------------- */

@media (max-width: 1024px) {
  .tp-hero--glossier {
    height: 680px;
    min-height: 680px;
    max-height: 680px;
  }
  .tp-hero--glossier .tp-hero__title {
    font-size: 52px;
    max-width: min(100%, 580px);
  }
  .tp-hero--glossier .tp-hero__content {
    max-width: min(100%, 580px);
  }
  .tp-hero--glossier .tp-hero__meta,
  .tp-hero--glossier .tp-hero__date,
  .tp-hero--glossier .tp-hero__by {
    font-size: 16px;
  }
}

@media (max-width: 768px) {
  .tp-hero--glossier {
    height: auto;
    min-height: 560px;
    max-height: none;
  }
  .tp-hero--glossier .tp-hero__wrap {
    align-items: flex-end;
    padding-top: 80px;
    padding-bottom: 40px;
    padding-left: 20px;              /* reinstate side gutter on mobile so content doesn't touch edge */
    padding-right: 20px;
  }
  .tp-hero--glossier .tp-hero__scrim {
    background:
      linear-gradient(180deg, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.05) 30%, rgba(0, 0, 0, 0.55) 75%, rgba(0, 0, 0, 0.75) 100%);
  }
  .tp-hero--glossier .tp-hero__content {
    gap: 14px;
    max-width: 100%;
  }
  .tp-hero--glossier .tp-hero__title {
    font-size: 42px;
    line-height: 1.1;
    max-width: 100%;
  }
  .tp-hero--glossier .tp-hero__meta {
    margin-top: 18px;
    gap: 12px;
    font-size: 15px;
  }
  .tp-hero--glossier .tp-hero__date,
  .tp-hero--glossier .tp-hero__by {
    font-size: 15px;
  }
  .tp-hero--glossier .tp-hero__by strong {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .tp-hero--glossier {
    min-height: 480px;
  }
  .tp-hero--glossier .tp-hero__title {
    font-size: 34px;
  }
  .tp-hero--glossier .tp-hero__meta {
    font-size: 14px;
  }
  .tp-hero--glossier .tp-hero__date,
  .tp-hero--glossier .tp-hero__by {
    font-size: 14px;
  }
}

/* ==========================================================================
   Trending — Glossier 1:1 layout (v4.8.3)
   4-card edge-to-edge strip below hero.  Each card: text-left / thumb-right.
   Measurements taken from glossier.cmsmasters.studio via Playwright.
   ========================================================================== */

.tp-trending--glossier {
  padding: 40px 10px;
  background: transparent;
}

/* Neutralize every legacy .tp-trending__* rule that still shoots into our DOM. */
.tp-trending--glossier .tp-trending__inner,
.tp-trending--glossier .tp-section__title,
.tp-trending--glossier .tp-trending__icon,
.tp-trending--glossier .tp-trending__swiper,
.tp-trending--glossier .swiper-wrapper,
.tp-trending--glossier .tp-trending__number {
  all: unset;
  display: none !important;
}

.tp-trending--glossier .tp-trending__row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 60px;
  align-items: stretch;
  width: 100%;
  max-width: 1900px;
  margin: 0 auto;
}

/* Each card: [body | thumbnail] — text left, image right */
.tp-trending--glossier .tp-trending__card {
  display: grid;
  grid-template-columns: 1fr 80px;
  gap: 20px;
  align-items: center;
  min-height: 80px;
  background: transparent;
  padding: 0;
  border: none;
  box-shadow: none;
  position: relative;
  transition: opacity 0.2s ease;
}

.tp-trending--glossier .tp-trending__card:hover {
  opacity: 0.78;
}

/* Reset the inherited legacy .tp-trending__item styles */
.tp-trending--glossier .tp-trending__card::before,
.tp-trending--glossier .tp-trending__card::after {
  content: none;
}

/* Text column — title on top, author on bottom */
.tp-trending--glossier .tp-trending__body {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-self: stretch;
  min-height: 80px;
  padding: 2px 0;
  overflow: hidden;
}

/* Title — Gloock 18px/400/1.35 (exact Glossier) */
.tp-trending--glossier .tp-trending__title {
  font-family: 'Gloock', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: normal;
  color: var(--tp-secondary);
  margin: 0;
  padding: 0;
  text-transform: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tp-trending--glossier .tp-trending__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  background: none;
  padding: 0;
  border: none;
}

.tp-trending--glossier .tp-trending__title a:hover {
  color: var(--tp-primary);
  background: none;
}

/* "by AUTHORNAME" — Poppins 12px/500, 1px tracking, uppercase */
.tp-trending--glossier .tp-trending__by {
  display: inline-block;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--tp-secondary);
  margin: 0;
  padding: 0;
}

.tp-trending--glossier .tp-trending__by a {
  color: inherit;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
  background: none;
}

.tp-trending--glossier .tp-trending__by a:hover {
  color: var(--tp-primary);
}

/* Thumbnail — 80×80 rounded square, image on the right */
.tp-trending--glossier .tp-trending__thumb {
  display: block;
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
  flex-shrink: 0;
  justify-self: end;
  position: relative;
  box-shadow: none;
  transform: none;
}

.tp-trending--glossier .tp-trending__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.tp-trending--glossier .tp-trending__card:hover .tp-trending__thumb img {
  transform: scale(1.04);
}

.tp-trending--glossier .tp-trending__thumb-placeholder {
  display: block;
  width: 100%;
  height: 100%;
}

/* ---------- Responsive cascade ----------------------------------------- */

@media (max-width: 1440px) {
  .tp-trending--glossier .tp-trending__row {
    gap: 40px;
    padding: 0 20px;
  }
}

@media (max-width: 1200px) {
  .tp-trending--glossier {
    padding: 32px 20px;
  }
  .tp-trending--glossier .tp-trending__row {
    gap: 28px;
  }
  .tp-trending--glossier .tp-trending__title {
    font-size: 17px;
  }
}

@media (max-width: 1024px) {
  .tp-trending--glossier .tp-trending__row {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px 40px;
  }
}

@media (max-width: 640px) {
  .tp-trending--glossier {
    padding: 24px 16px;
  }
  .tp-trending--glossier .tp-trending__row {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .tp-trending--glossier .tp-trending__card {
    grid-template-columns: 1fr 72px;
    gap: 16px;
    min-height: 72px;
  }
  .tp-trending--glossier .tp-trending__body {
    min-height: 72px;
  }
  .tp-trending--glossier .tp-trending__thumb {
    width: 72px;
    height: 72px;
  }
  .tp-trending--glossier .tp-trending__title {
    font-size: 16px;
  }
}

/* ---------- Dark mode --------------------------------------------------- */

[data-theme="dark"] .tp-trending--glossier .tp-trending__title,
[data-theme="dark"] .tp-trending--glossier .tp-trending__title a,
[data-theme="dark"] .tp-trending--glossier .tp-trending__by,
[data-theme="dark"] .tp-trending--glossier .tp-trending__by a {
  color: #f5f5f5;
}

/* ==========================================================================
   Editors — Featured Article + Trending Sidebar (Glossier 1:1 — v4.8.4)
   Measurements extracted via Playwright from glossier.cmsmasters.studio
   ========================================================================== */

.tp-editors {
  padding: 60px 0 70px;
  background: var(--tp-bg);
}

.tp-editors__wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Main grid: featured/cards area (2fr) + trending sidebar (1fr)  */
.tp-editors__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 40px;
  align-items: start;
}

/* ---------- Main column (left) ------------------------------------------ */

.tp-editors__main {
  display: flex;
  flex-direction: column;
  gap: 40px;
  min-width: 0;
}

/* Featured hero article — text left, big image right */
.tp-editors__hero {
  display: grid;
  grid-template-columns: minmax(0, 325px) minmax(0, 1fr);
  gap: 30px;
  align-items: start;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}

.tp-editors__hero-text {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}

.tp-editors__hero-badges {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

/* Red pill — identical spec to the hero pill (3px 12px, 30px radius, Poppins 12/500/1px) */
.tp-editors__pill {
  display: inline-block;
  padding: 3px 12px;
  background: #FF4444;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  border-radius: 30px;
  text-decoration: none;
  transition: background 0.2s ease;
}

.tp-editors__pill:hover {
  background: #e63939;
}

/* Lock icon + "FOR SUBSCRIBERS" label — Poppins 12/500/1px uppercase */
.tp-editors__lock {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(31, 31, 31, 0.65);
}

.tp-editors__lock svg {
  flex: 0 0 auto;
  stroke: currentColor;
}

/* Featured title — Gloock 36px/400/1.2 */
.tp-editors__hero-title {
  font-family: 'Gloock', Georgia, serif;
  font-size: 36px;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: normal;
  color: var(--tp-secondary);
  margin: 0;
}

.tp-editors__hero-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  background: none;
}

.tp-editors__hero-title a:hover {
  color: var(--tp-primary);
}

/* Meta row — Poppins 12/500, clock + date + by AUTHOR */
.tp-editors__hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: normal;
  color: rgba(31, 31, 31, 0.65);
  margin: 0;
}

.tp-editors__clock {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(31, 31, 31, 0.55);
  margin-right: -6px;
}

.tp-editors__hero-meta time,
.tp-editors__hero-meta .tp-editors__by {
  color: rgba(31, 31, 31, 0.65);
  font-weight: 500;
  text-transform: none;
}

.tp-editors__hero-meta .tp-editors__by a {
  color: var(--tp-secondary);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
}

.tp-editors__hero-meta .tp-editors__by a:hover {
  color: var(--tp-primary);
}

/* Excerpt — PT Serif 18px/1.6 — 3-line clamp */
.tp-editors__hero-excerpt {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(31, 31, 31, 0.75);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Featured hero image — large 4:3-ish, border-radius 30px */
.tp-editors__hero-image {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 30px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
}

.tp-editors__hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.tp-editors__hero:hover .tp-editors__hero-image img {
  transform: scale(1.02);
}

.tp-editors__hero-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

/* ---------- Secondary cards (3-col row under hero) --------------------- */

.tp-editors__cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
}

.tp-editors__card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
}

.tp-editors__card-image {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
}

.tp-editors__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.tp-editors__card:hover .tp-editors__card-image img {
  transform: scale(1.04);
}

.tp-editors__card-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

.tp-editors__card-title {
  font-family: 'Poppins', sans-serif;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-editors__card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-editors__card-title a:hover {
  color: var(--tp-primary);
}

.tp-editors__card-excerpt {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  color: rgba(31, 31, 31, 0.7);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-editors__card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(31, 31, 31, 0.65);
  margin-top: auto;
}

.tp-editors__card-by a {
  color: var(--tp-secondary);
  text-decoration: none;
  font-weight: 500;
}

.tp-editors__card-by a:hover {
  color: var(--tp-primary);
}

.tp-editors__card-comments {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: rgba(31, 31, 31, 0.55);
}

.tp-editors__card-comments svg {
  stroke: currentColor;
  flex: 0 0 auto;
}

/* ---------- Trending sidebar (right) ------------------------------------ */

.tp-editors__side {
  background: #fff;
  border-radius: 20px;
  padding: 28px 26px 24px;
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 90px;
}

.tp-editors__side-title {
  font-family: 'Poppins', sans-serif;
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--tp-secondary);
  margin: 0 0 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--tp-primary);
  width: fit-content;
}

.tp-editors__side-list {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: tp-editors-trend;
}

.tp-editors__side-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 14px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.tp-editors__side-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.tp-editors__side-item:first-child {
  padding-top: 4px;
}

.tp-editors__side-num {
  font-family: 'Gloock', Georgia, serif;
  font-size: 48px;
  font-weight: 400;
  line-height: 0.9;
  color: rgba(0, 0, 0, 0.18);
  text-align: left;
  user-select: none;
}

.tp-editors__side-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  padding-top: 4px;
}

.tp-editors__side-item-title {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-editors__side-item-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-editors__side-item-title a:hover {
  color: var(--tp-primary);
}

.tp-editors__side-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-family: 'Poppins', sans-serif;
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: rgba(31, 31, 31, 0.55);
}

.tp-editors__side-cat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.tp-editors__side-cat a {
  color: var(--tp-secondary);
  text-decoration: none;
  font-weight: 600;
}

.tp-editors__side-cat a:hover {
  color: var(--tp-primary);
}

.tp-editors__side-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: rgba(31, 31, 31, 0.45);
}

.tp-editors__side-stat svg {
  stroke: currentColor;
  flex: 0 0 auto;
}

/* ---------- Responsive cascade ----------------------------------------- */

@media (max-width: 1200px) {
  .tp-editors__grid {
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 32px;
  }
  .tp-editors__hero {
    grid-template-columns: minmax(0, 290px) minmax(0, 1fr);
    gap: 24px;
  }
  .tp-editors__hero-title {
    font-size: 30px;
  }
}

@media (max-width: 1024px) {
  .tp-editors__grid {
    grid-template-columns: 1fr;
  }
  .tp-editors__side {
    position: static;
  }
  .tp-editors__hero-title {
    font-size: 32px;
  }
}

@media (max-width: 768px) {
  .tp-editors {
    padding: 40px 0 50px;
  }
  .tp-editors__hero {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .tp-editors__hero-image {
    aspect-ratio: 16 / 10;
    order: -1;
  }
  .tp-editors__cards {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .tp-editors__hero-title {
    font-size: 28px;
  }
  .tp-editors__side-num {
    font-size: 40px;
  }
}

@media (max-width: 480px) {
  .tp-editors__hero-title {
    font-size: 26px;
  }
  .tp-editors__hero-excerpt {
    font-size: 16px;
  }
  .tp-editors__card-title {
    font-size: 17px;
  }
}

/* ---------- Dark mode --------------------------------------------------- */

[data-theme="dark"] .tp-editors__hero-title,
[data-theme="dark"] .tp-editors__hero-title a,
[data-theme="dark"] .tp-editors__card-title,
[data-theme="dark"] .tp-editors__card-title a,
[data-theme="dark"] .tp-editors__side-title,
[data-theme="dark"] .tp-editors__side-item-title,
[data-theme="dark"] .tp-editors__side-item-title a,
[data-theme="dark"] .tp-editors__card-by a,
[data-theme="dark"] .tp-editors__side-cat a {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-editors__lock,
[data-theme="dark"] .tp-editors__hero-meta,
[data-theme="dark"] .tp-editors__hero-meta time,
[data-theme="dark"] .tp-editors__hero-excerpt,
[data-theme="dark"] .tp-editors__card-excerpt,
[data-theme="dark"] .tp-editors__card-meta,
[data-theme="dark"] .tp-editors__side-meta,
[data-theme="dark"] .tp-editors__side-stat {
  color: rgba(255, 255, 255, 0.65);
}

[data-theme="dark"] .tp-editors__side {
  background: #1a1a1a;
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .tp-editors__side-num {
  color: rgba(255, 255, 255, 0.18);
}

/* ==========================================================================
   Featured Banner — Full-width immersive (Glossier 1:1 — v4.8.5)
   Edge-to-edge 620px-tall banner with bg image + centered bottom content.
   ========================================================================== */

.tp-banner {
  position: relative;
  width: 100%;
  height: 620px;
  min-height: 620px;
  max-height: 620px;
  overflow: hidden;
  isolation: isolate;
  margin: 40px 0 0;
}

.tp-banner__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
  transform: scale(1.02);
  transition: transform 1.6s ease;
}

.tp-banner:hover .tp-banner__bg {
  transform: scale(1.05);
}

/* Subtle bottom-weighted scrim so white text stays readable
   without darkening the whole image. */
.tp-banner__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0) 35%, rgba(0, 0, 0, 0.25) 70%, rgba(0, 0, 0, 0.55) 100%);
  pointer-events: none;
}

.tp-banner__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: flex-end;                /* content anchored to the bottom */
  justify-content: center;              /* horizontally centered */
  padding: 40px 20px 50px;              /* 50px from bottom, like Glossier's ~30px + some breathing */
}

.tp-banner__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
  max-width: 1000px;
}

/* ---------- Pill (exact Glossier spec: 3px 12px / 30px radius / Poppins 12/500/1px) */
.tp-banner__pill {
  display: inline-block;
  padding: 3px 12px;
  background: #FF4444;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  border-radius: 30px;
  text-decoration: none;
  margin: 0;
  transition: background 0.2s ease;
}

.tp-banner__pill:hover {
  background: #e63939;
  color: #fff;
}

/* ---------- Title — Gloock 48px/400/55.2px line-height (exact Glossier) */
.tp-banner__title {
  font-family: 'Gloock', Georgia, serif;
  font-size: 48px;
  font-weight: 400;
  line-height: 55.2px;          /* ≈ 1.15 */
  letter-spacing: normal;
  color: #fff;
  margin: 0;
  max-width: 900px;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
  overflow-wrap: break-word;
}

.tp-banner__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-banner__title a:hover {
  color: inherit;
  opacity: 0.92;
}

/* ---------- Meta row — Poppins 12/500 translucent white */
.tp-banner__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px 18px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: normal;
  color: rgba(255, 255, 255, 0.85);
  margin: 4px 0 0;
}

.tp-banner__meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.85);
  position: relative;
}

/* Subtle dot separator between meta items */
.tp-banner__meta-item + .tp-banner__meta-item::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  margin-right: 12px;
}

.tp-banner__meta svg {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(255, 255, 255, 0.75);
}

.tp-banner__meta time {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
}

/* ---------- Responsive cascade ----------------------------------------- */

@media (max-width: 1024px) {
  .tp-banner {
    height: 520px;
    min-height: 520px;
    max-height: 520px;
  }
  .tp-banner__title {
    font-size: 40px;
    line-height: 1.15;
    max-width: 760px;
  }
}

@media (max-width: 768px) {
  .tp-banner {
    height: 420px;
    min-height: 420px;
    max-height: 420px;
    margin-top: 24px;
  }
  .tp-banner__inner {
    padding: 32px 20px 36px;
  }
  .tp-banner__content {
    gap: 16px;
  }
  .tp-banner__title {
    font-size: 30px;
    line-height: 1.2;
  }
  .tp-banner__meta {
    font-size: 11px;
  }
  .tp-banner__meta-item + .tp-banner__meta-item::before {
    margin-right: 8px;
  }
}

@media (max-width: 480px) {
  .tp-banner {
    height: 360px;
    min-height: 360px;
    max-height: 360px;
  }
  .tp-banner__title {
    font-size: 24px;
  }
  .tp-banner__meta {
    gap: 6px 12px;
  }
  /* On phones, stack meta items without dots for legibility */
  .tp-banner__meta-item + .tp-banner__meta-item::before {
    display: none;
  }
}

/* ==========================================================================
   Editor's Picks — Glossier 1:1 redesign (v4.8.6)
   Scoped under .tp-picks--glossier to avoid colliding with legacy .tp-picks rules.
   Header + divider  |  2x2 card grid + "OUR WRITERS" sidebar.
   ========================================================================== */

.tp-picks--glossier {
  padding: 80px 0;
}

/* Neutralize legacy children that would otherwise leak through */
.tp-picks--glossier .tp-section__header,
.tp-picks--glossier .tp-section__title,
.tp-picks--glossier .tp-section__more,
.tp-picks--glossier .tp-picks__layout,
.tp-picks--glossier .tp-picks__primary,
.tp-picks--glossier .tp-picks__grid--legacy {
  all: unset;
  display: none !important;
}

/* ---------- Header + divider -------------------------------------------- */

.tp-picks--glossier .tp-picks__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin: 0 0 24px;
}

.tp-picks--glossier .tp-picks__title {
  font-family: var(--tp-font-heading);
  font-weight: 400;
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--tp-secondary);
  margin: 0;
  padding: 0;
  border: none;
  text-transform: none;
}

.tp-picks--glossier .tp-picks__more {
  font-family: var(--tp-font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--tp-secondary);
  text-decoration: none;
  text-transform: none;
  letter-spacing: 0;
  border: none;
  padding: 0 0 4px;
  background: none;
  position: relative;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.tp-picks--glossier .tp-picks__more::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
}

.tp-picks--glossier .tp-picks__more:hover {
  color: var(--tp-primary);
}

.tp-picks--glossier .tp-picks__divider {
  height: 2px;
  background: var(--tp-secondary);
  border: 0;
  margin: 0 0 48px;
  opacity: 1;
}

/* ---------- 2-col layout: cards + sidebar -------------------------------- */

.tp-picks--glossier .tp-picks__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 40px;
  align-items: start;
}

/* ---------- 2x2 card grid ----------------------------------------------- */

.tp-picks--glossier .tp-picks__cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: auto auto;
  gap: 40px 30px;
}

.tp-picks--glossier .tp-picks__card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: transparent;
  padding: 0;
  margin: 0;
  border: none;
  box-shadow: none;
}

.tp-picks--glossier .tp-picks__card-image {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
}

.tp-picks--glossier .tp-picks__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.tp-picks--glossier .tp-picks__card:hover .tp-picks__card-image img {
  transform: scale(1.03);
}

.tp-picks--glossier .tp-picks__card-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

.tp-picks--glossier .tp-picks__card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 4px;
}

.tp-picks--glossier .tp-picks__card-cat {
  font-family: var(--tp-font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--tp-secondary);
  text-decoration: none;
  line-height: 1;
  align-self: flex-start;
  background: none;
  padding: 0;
  border: 0;
  border-radius: 0;
  margin: 2px 0 0;
  transition: color 0.2s ease;
}

.tp-picks--glossier .tp-picks__card-cat:hover {
  color: var(--tp-primary);
  background: none;
}

.tp-picks--glossier .tp-picks__card-title {
  font-family: var(--tp-font-heading);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-picks--glossier .tp-picks__card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  background: none;
}

.tp-picks--glossier .tp-picks__card-title a:hover {
  color: var(--tp-primary);
}

.tp-picks--glossier .tp-picks__card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--tp-font-body);
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
  margin: 4px 0 0;
}

.tp-picks--glossier .tp-picks__clock {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(0, 0, 0, 0.45);
}

.tp-picks--glossier .tp-picks__card-date {
  color: rgba(0, 0, 0, 0.55);
  font-weight: 400;
}

.tp-picks--glossier .tp-picks__card-by {
  color: rgba(0, 0, 0, 0.55);
  font-weight: 400;
}

.tp-picks--glossier .tp-picks__card-by strong {
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--tp-secondary);
  text-transform: uppercase;
  margin-left: 2px;
  font-size: 11px;
}

/* ---------- Our Writers sidebar ----------------------------------------- */

.tp-picks--glossier .tp-picks__writers {
  background: #fff;
  border-radius: 20px;
  padding: 28px 28px 18px;
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 90px;
}

.tp-picks--glossier .tp-picks__writers-title {
  font-family: var(--tp-font-body);
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--tp-secondary);
  margin: 0 0 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--tp-primary);
  width: fit-content;
}

.tp-picks--glossier .tp-picks__writers-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tp-picks--glossier .tp-picks__writer {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.07);
}

.tp-picks--glossier .tp-picks__writer:last-child {
  border-bottom: none;
  padding-bottom: 4px;
}

.tp-picks--glossier .tp-picks__writer:first-child {
  padding-top: 4px;
}

.tp-picks--glossier .tp-picks__writer-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: transparent;
  padding: 3px;
  border: 2px solid var(--tp-primary);
  box-sizing: border-box;
  text-decoration: none;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.tp-picks--glossier .tp-picks__writer-avatar:hover {
  transform: scale(1.05);
}

/* Tighten the avatar initial circle we inherit from tp_author_avatar() */
.tp-picks--glossier .tp-picks__writer-avatar .tp-avatar-initial {
  width: 100% !important;
  height: 100% !important;
  font-size: 18px !important;
  font-family: var(--tp-font-heading);
  border-radius: 50%;
}

.tp-picks--glossier .tp-picks__writer-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.tp-picks--glossier .tp-picks__writer-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.tp-picks--glossier .tp-picks__writer-title {
  font-family: var(--tp-font-heading);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-picks--glossier .tp-picks__writer-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.tp-picks--glossier .tp-picks__writer-title a:hover {
  color: var(--tp-primary);
}

.tp-picks--glossier .tp-picks__writer-by {
  font-family: var(--tp-font-body);
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.6px;
  color: rgba(0, 0, 0, 0.55);
  text-transform: none;
}

.tp-picks--glossier .tp-picks__writer-by a {
  color: var(--tp-secondary);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  font-size: 11px;
  margin-left: 2px;
}

.tp-picks--glossier .tp-picks__writer-by a:hover {
  color: var(--tp-primary);
}

/* ---------- Responsive cascade ----------------------------------------- */

@media (max-width: 1200px) {
  .tp-picks--glossier .tp-picks__grid {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 32px;
  }
}

@media (max-width: 1024px) {
  .tp-picks--glossier .tp-picks__grid {
    grid-template-columns: 1fr;
  }
  .tp-picks--glossier .tp-picks__writers {
    position: static;
  }
}

@media (max-width: 768px) {
  .tp-picks--glossier {
    padding: 56px 0;
  }
  .tp-picks--glossier .tp-picks__title {
    font-size: clamp(32px, 9vw, 44px);
  }
  .tp-picks--glossier .tp-picks__divider {
    margin-bottom: 32px;
  }
  .tp-picks--glossier .tp-picks__cards {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .tp-picks--glossier .tp-picks__card-title {
    font-size: 19px;
  }
  .tp-picks--glossier .tp-picks__card-meta {
    font-size: 12px;
  }
}

/* ---------- Dark mode --------------------------------------------------- */

[data-theme="dark"] .tp-picks--glossier .tp-picks__title,
[data-theme="dark"] .tp-picks--glossier .tp-picks__more,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-title,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-title a,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-cat,
[data-theme="dark"] .tp-picks--glossier .tp-picks__writers-title,
[data-theme="dark"] .tp-picks--glossier .tp-picks__writer-title,
[data-theme="dark"] .tp-picks--glossier .tp-picks__writer-title a,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-by strong {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-picks--glossier .tp-picks__divider {
  background: #f5f5f5;
}

[data-theme="dark"] .tp-picks--glossier .tp-picks__card-meta,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-date,
[data-theme="dark"] .tp-picks--glossier .tp-picks__card-by,
[data-theme="dark"] .tp-picks--glossier .tp-picks__writer-by,
[data-theme="dark"] .tp-picks--glossier .tp-picks__clock {
  color: rgba(255, 255, 255, 0.6);
}

[data-theme="dark"] .tp-picks--glossier .tp-picks__writers {
  background: #1a1a1a;
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .tp-picks--glossier .tp-picks__writer {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   Promo Card — horizontal split banner (v4.8.8)
   Contained card with white content on left + full-bleed image on right.
   Placed between Latest Stories and Editor's Picks.
   ========================================================================== */

.tp-promo {
  padding: 40px 0 0;
}

.tp-promo__wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

.tp-promo__card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  background: #fff;
  border-radius: 40px;
  overflow: hidden;
  box-shadow: 0 4px 40px rgba(0, 0, 0, 0.06);
  min-height: 520px;
  margin: 0;
  padding: 0;
  border: none;
}

/* ---------- Left: content ---------------------------------------------- */

.tp-promo__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 70px 80px;
  gap: 22px;
  min-width: 0;
}

.tp-promo__badges {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 4px;
}

/* Red pill — identical spec to all other Glossier pills */
.tp-promo__pill {
  display: inline-block;
  padding: 3px 12px;
  background: #FF4444;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  border-radius: 30px;
  text-decoration: none;
  transition: background 0.2s ease;
}

.tp-promo__pill:hover {
  background: #e63939;
  color: #fff;
}

/* Big serif title — Gloock 48px on dark text (not white, because bg is white) */
.tp-promo__title {
  font-family: 'Gloock', Georgia, serif;
  font-size: clamp(32px, 3.2vw, 52px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: normal;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-promo__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  background: none;
}

.tp-promo__title a:hover {
  color: var(--tp-primary);
}

/* Excerpt — PT Serif, muted gray */
.tp-promo__excerpt {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(31, 31, 31, 0.62);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Author + stats meta row */
.tp-promo__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 22px;
  margin-top: 14px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: rgba(31, 31, 31, 0.55);
}

.tp-promo__author {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--tp-secondary);
}

.tp-promo__author:hover .tp-promo__author-name {
  color: var(--tp-primary);
}

/* Scope the inherited initial-avatar to 40px */
.tp-promo__author .tp-avatar-initial {
  width: 40px !important;
  height: 40px !important;
  font-size: 15px !important;
  border-radius: 50%;
  font-family: var(--tp-font-heading);
  border: 2px solid var(--tp-primary);
  box-sizing: border-box;
}

.tp-promo__author-name {
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--tp-secondary);
  transition: color 0.2s ease;
}

.tp-promo__stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(31, 31, 31, 0.55);
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0.2px;
}

.tp-promo__stat--comments {
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 11px;
}

.tp-promo__stat svg {
  flex: 0 0 auto;
  stroke: currentColor;
  color: rgba(31, 31, 31, 0.4);
}

/* ---------- Right: full-bleed image ------------------------------------ */

.tp-promo__image {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 520px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
}

.tp-promo__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.8s ease;
}

.tp-promo__card:hover .tp-promo__image img {
  transform: scale(1.03);
}

.tp-promo__image-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

/* ---------- Responsive cascade ----------------------------------------- */

@media (max-width: 1200px) {
  .tp-promo__body {
    padding: 56px 60px;
    gap: 18px;
  }
  .tp-promo__title {
    font-size: clamp(28px, 3vw, 44px);
  }
}

@media (max-width: 1024px) {
  .tp-promo__card {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    min-height: 440px;
  }
  .tp-promo__image {
    min-height: 440px;
  }
  .tp-promo__body {
    padding: 48px 48px;
  }
}

@media (max-width: 768px) {
  .tp-promo {
    padding-top: 24px;
  }
  .tp-promo__card {
    grid-template-columns: 1fr;
    border-radius: 28px;
    min-height: auto;
  }
  .tp-promo__image {
    min-height: 0;
    height: 280px;
    order: -1;
  }
  .tp-promo__body {
    padding: 32px 28px 36px;
    gap: 14px;
  }
  .tp-promo__title {
    font-size: 26px;
    line-height: 1.2;
  }
  .tp-promo__excerpt {
    font-size: 15px;
  }
  .tp-promo__meta {
    gap: 14px 18px;
  }
  .tp-promo__author .tp-avatar-initial {
    width: 36px !important;
    height: 36px !important;
    font-size: 13px !important;
  }
  .tp-promo__author-name {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .tp-promo__wrap {
    padding: 0 12px;
  }
  .tp-promo__card {
    border-radius: 22px;
  }
  .tp-promo__body {
    padding: 28px 22px 32px;
  }
  .tp-promo__title {
    font-size: 22px;
  }
  .tp-promo__image {
    height: 220px;
  }
}

/* ---------- Dark mode --------------------------------------------------- */

[data-theme="dark"] .tp-promo__card {
  background: #1a1a1a;
  box-shadow: 0 4px 40px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .tp-promo__title,
[data-theme="dark"] .tp-promo__title a,
[data-theme="dark"] .tp-promo__author-name {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-promo__excerpt,
[data-theme="dark"] .tp-promo__meta,
[data-theme="dark"] .tp-promo__stat {
  color: rgba(255, 255, 255, 0.65);
}

[data-theme="dark"] .tp-promo__stat svg {
  color: rgba(255, 255, 255, 0.4);
}

/* ==========================================================================
   Recommended — 3×4 horizontal mini-card grid (Glossier 1:1 — v4.8.9)
   ========================================================================== */

.tp-recommended--glossier {
  padding: 80px 0;
}

/* Neutralize legacy .tp-recommended__grid inherited from older CSS */
.tp-recommended--glossier .tp-section__header {
  display: none !important;
}

.tp-recommended--glossier .tp-recommended__wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header row: huge serif title + View More link + divider */
.tp-recommended--glossier .tp-recommended__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin: 0 0 24px;
}

.tp-recommended--glossier .tp-recommended__title {
  font-family: var(--tp-font-heading);
  font-weight: 400;
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--tp-secondary);
  margin: 0;
}

.tp-recommended--glossier .tp-recommended__more {
  font-family: var(--tp-font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--tp-secondary);
  text-decoration: none;
  letter-spacing: 0;
  text-transform: none;
  border: none;
  padding: 0 0 4px;
  background: none;
  position: relative;
  white-space: nowrap;
}

.tp-recommended--glossier .tp-recommended__more::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
}

.tp-recommended--glossier .tp-recommended__more:hover {
  color: var(--tp-primary);
}

.tp-recommended--glossier .tp-recommended__divider {
  height: 2px;
  background: var(--tp-secondary);
  border: 0;
  margin: 0 0 48px;
  opacity: 1;
}

/* 3-col × 4-row grid of horizontal mini cards */
.tp-recommended--glossier .tp-recommended__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 48px;
}

/* Each mini card: [ 100px image | title + date ] */
.tp-recommended--glossier .tp-recommended__card {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  background: transparent;
  padding: 0;
  margin: 0;
  border: none;
  box-shadow: none;
}

.tp-recommended--glossier .tp-recommended__card-image {
  display: block;
  position: relative;
  width: 100px;
  height: 100px;
  border-radius: 16px;
  overflow: hidden;
  background: var(--tp-bg-alt, #f0f0f0);
  flex-shrink: 0;
}

.tp-recommended--glossier .tp-recommended__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.tp-recommended--glossier .tp-recommended__card:hover .tp-recommended__card-image img {
  transform: scale(1.05);
}

.tp-recommended--glossier .tp-recommended__card-placeholder {
  position: absolute;
  inset: 0;
  display: block;
}

.tp-recommended--glossier .tp-recommended__card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.tp-recommended--glossier .tp-recommended__card-title {
  font-family: var(--tp-font-heading);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--tp-secondary);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-recommended--glossier .tp-recommended__card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  background: none;
}

.tp-recommended--glossier .tp-recommended__card-title a:hover {
  color: var(--tp-primary);
}

.tp-recommended--glossier .tp-recommended__card-date {
  font-family: var(--tp-font-body);
  font-size: 13px;
  font-weight: 400;
  color: rgba(0, 0, 0, 0.55);
  line-height: 1;
  letter-spacing: 0;
  text-transform: none;
}

/* Responsive */
@media (max-width: 1024px) {
  .tp-recommended--glossier .tp-recommended__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 32px;
  }
}

@media (max-width: 640px) {
  .tp-recommended--glossier {
    padding: 56px 0;
  }
  .tp-recommended--glossier .tp-recommended__title {
    font-size: clamp(32px, 9vw, 44px);
  }
  .tp-recommended--glossier .tp-recommended__divider {
    margin-bottom: 32px;
  }
  .tp-recommended--glossier .tp-recommended__grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .tp-recommended--glossier .tp-recommended__card {
    grid-template-columns: 80px minmax(0, 1fr);
    gap: 14px;
  }
  .tp-recommended--glossier .tp-recommended__card-image {
    width: 80px;
    height: 80px;
    border-radius: 12px;
  }
  .tp-recommended--glossier .tp-recommended__card-title {
    font-size: 16px;
  }
}

/* Dark mode */
[data-theme="dark"] .tp-recommended--glossier .tp-recommended__title,
[data-theme="dark"] .tp-recommended--glossier .tp-recommended__more,
[data-theme="dark"] .tp-recommended--glossier .tp-recommended__card-title,
[data-theme="dark"] .tp-recommended--glossier .tp-recommended__card-title a {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-recommended--glossier .tp-recommended__divider {
  background: #f5f5f5;
}

[data-theme="dark"] .tp-recommended--glossier .tp-recommended__card-date {
  color: rgba(255, 255, 255, 0.55);
}

/* ==========================================================================
   Footer — Glossier 1:1 centered layout (v4.8.9)
   ========================================================================== */

.tp-footer--glossier {
  background: #141414;
  color: rgba(255, 255, 255, 0.8);
  padding: 80px 20px 40px;
  border-top: none;
  margin-top: 0;
}

/* Neutralize legacy .tp-footer__grid etc */
.tp-footer--glossier .tp-footer__grid,
.tp-footer--glossier .tp-footer__col,
.tp-footer--glossier .tp-footer__bottom {
  all: unset;
  display: none !important;
}

.tp-footer--glossier .tp-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 30px;
}

/* Centered brand/logo */
.tp-footer--glossier .tp-footer__brand {
  display: flex;
  justify-content: center;
  margin: 0;
}

.tp-footer--glossier .tp-footer__logo-link,
.tp-footer--glossier .tp-footer__wordmark {
  display: inline-block;
  font-family: 'Gloock', Georgia, serif;
  font-size: 56px;
  font-weight: 400;
  line-height: 1;
  color: #fff;
  text-decoration: none;
  letter-spacing: normal;
  text-transform: none;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
}

.tp-footer--glossier .tp-footer__logo-img {
  max-height: 60px;
  width: auto;
  filter: brightness(0) invert(1);
}

/* Social icons — circular outlined */
.tp-footer--glossier .tp-footer__social {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
  margin: 0;
}

.tp-footer--glossier .tp-footer__social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  color: #fff;
  text-decoration: none;
  transition: all 0.2s ease;
  background: transparent;
}

.tp-footer--glossier .tp-footer__social-link:hover {
  background: #fff;
  color: #141414;
  border-color: #fff;
  transform: translateY(-2px);
}

.tp-footer--glossier .tp-footer__social-link svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: currentColor;
}

/* Category menu row */
.tp-footer--glossier .tp-footer__menu-nav {
  margin: 4px 0 0;
}

.tp-footer--glossier .tp-footer__menu-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px 32px;
}

.tp-footer--glossier .tp-footer__menu-list li,
.tp-footer--glossier .tp-footer__menu-item {
  margin: 0;
  padding: 0;
}

.tp-footer--glossier .tp-footer__menu-list a {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.2s ease;
  padding: 4px 0;
}

.tp-footer--glossier .tp-footer__menu-list a:hover {
  color: #fff;
}

/* Divider */
.tp-footer--glossier .tp-footer__divider {
  width: 100%;
  max-width: 1200px;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  border: 0;
  margin: 30px 0 0;
  opacity: 1;
}

/* Copyright */
.tp-footer--glossier .tp-footer__copyright {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
  padding: 20px 0 0;
  letter-spacing: 0.3px;
}

/* Responsive footer */
@media (max-width: 768px) {
  .tp-footer--glossier {
    padding: 56px 20px 32px;
  }
  .tp-footer--glossier .tp-footer__logo-link,
  .tp-footer--glossier .tp-footer__wordmark {
    font-size: 42px;
  }
  .tp-footer--glossier .tp-footer__menu-list {
    gap: 10px 20px;
  }
  .tp-footer--glossier .tp-footer__menu-list a {
    font-size: 11px;
    letter-spacing: 1.2px;
  }
}

/* Back-to-top button — red circular (bottom-right) */
.tp-back-to-top {
  position: fixed;
  right: 28px;
  bottom: 28px;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #ff4444;
  color: #fff;
  border: none;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  z-index: 9990;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, background 0.2s ease;
}

.tp-back-to-top[hidden] {
  display: none;
}

.tp-back-to-top:hover {
  background: #e63939;
  transform: translateY(-2px);
}

/* ==========================================================================
   Single Post — Glossier 1:1 article typography (v4.8.9)
   Matches glossier.cmsmasters.studio/main/is-shopping-second-hand-still-a-sustainable-option/
   Title: Gloock 62px/400/68.2px — dark color on white bg
   Body:  PT Serif 18px/400/1.6
   Lead:  PT Serif 21px/400/italic (first paragraph)
   H2/H3: Gloock 36px/400
   Blockquote: Poppins 28px/400/italic with left indent + decorative mark
   Pull quote: dedicated alt style
   ========================================================================== */

.tp-single {
  padding-top: 40px;
}

/* ---- Article header (breadcrumb + badge + title + meta) ---------------- */

.tp-single__header {
  max-width: 915px;
  margin: 0 auto 30px;
  padding: 0 20px;
  text-align: left;
}

.tp-single__title {
  font-family: 'Gloock', Georgia, serif !important;
  font-size: clamp(36px, 5vw, 62px) !important;
  font-weight: 400 !important;
  line-height: 1.1 !important;
  letter-spacing: normal !important;
  color: var(--tp-secondary) !important;
  margin: 20px 0 24px !important;
  text-align: left !important;
}

.tp-single__meta {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.6px;
  color: rgba(0, 0, 0, 0.6);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  text-transform: none;
  justify-content: flex-start !important;
}

.tp-single__meta-author a {
  color: var(--tp-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  text-decoration: none;
}

/* ---- Featured image ---------------------------------------------------- */

.tp-single__featured {
  max-width: 1280px;
  margin: 0 auto 48px;
  padding: 0 20px;
}

.tp-single__featured img,
.tp-single__featured-img {
  width: 100%;
  height: auto;
  border-radius: 24px;
  display: block;
}

.tp-single__caption {
  max-width: 915px;
  margin: 14px auto 0;
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
  text-align: center;
  padding: 0 20px;
}

/* ---- Article body (the content wrapper) ------------------------------- */

.tp-single__body {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.7;
  color: #1f1f1f;
}

/* Paragraphs */
.tp-single__body p {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.7;
  color: #1f1f1f;
  margin: 0 0 24px;
}

/* Lead paragraph — italic 21px (matches Glossier first paragraph) */
.tp-single__body > p:first-of-type {
  font-size: 21px;
  font-style: italic;
  line-height: 1.55;
  color: rgba(0, 0, 0, 0.82);
  margin-bottom: 32px;
}

/* Headings inside article body */
.tp-single__body h2,
.tp-single__body h3,
.tp-single__body h4 {
  font-family: 'Gloock', Georgia, serif;
  font-weight: 400;
  line-height: 1.2;
  color: var(--tp-secondary);
  margin: 44px 0 20px;
  letter-spacing: normal;
  text-transform: none;
}

.tp-single__body h2 { font-size: 42px; }
.tp-single__body h3 { font-size: 36px; }
.tp-single__body h4 { font-size: 28px; }

/* Links */
.tp-single__body a {
  color: var(--tp-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: opacity 0.2s ease;
}

.tp-single__body a:hover {
  opacity: 0.75;
}

/* Bold / strong */
.tp-single__body strong,
.tp-single__body b {
  font-weight: 700;
  color: #1f1f1f;
}

/* Lists */
.tp-single__body ul,
.tp-single__body ol {
  margin: 0 0 24px;
  padding-left: 28px;
  font-family: 'PT Serif', Georgia, serif;
  font-size: 18px;
  line-height: 1.7;
}

.tp-single__body li {
  margin-bottom: 10px;
}

/* ---- Blockquote / pull quote (Glossier signature treatment) ------------ */

.tp-single__body blockquote {
  margin: 40px 0 40px 50px;      /* indented from left */
  padding: 12px 0 12px 30px;
  border: none;
  border-left: 3px solid var(--tp-primary);
  background: none;
  font-family: 'Poppins', sans-serif;
  font-size: 28px;
  font-weight: 400;
  font-style: italic;
  line-height: 1.4;
  color: var(--tp-secondary);
  text-align: left;
  position: relative;
  max-width: 660px;
}

.tp-single__body blockquote p {
  font-family: inherit;
  font-size: inherit;
  font-style: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0 0 12px;
}

.tp-single__body blockquote p:last-child {
  margin-bottom: 0;
}

.tp-single__body blockquote cite {
  display: block;
  margin-top: 14px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 600;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(0, 0, 0, 0.55);
}

/* WordPress pull-quote block (alternative pull-quote style) */
.tp-single__body .wp-block-pullquote,
.tp-single__body .wp-block-quote.is-style-large {
  margin: 48px auto;
  padding: 30px 0;
  max-width: 720px;
  border: none;
  border-top: 2px solid var(--tp-primary);
  border-bottom: 2px solid var(--tp-primary);
  text-align: center;
  background: none;
  font-family: 'Poppins', sans-serif;
  font-size: 30px;
  font-style: italic;
  font-weight: 400;
  line-height: 1.4;
  color: var(--tp-secondary);
}

.tp-single__body .wp-block-pullquote p,
.tp-single__body .wp-block-quote.is-style-large p {
  font-family: inherit;
  font-size: inherit;
  font-style: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0 0 14px;
}

.tp-single__body .wp-block-pullquote cite,
.tp-single__body .wp-block-quote cite {
  display: block;
  margin-top: 14px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 600;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(0, 0, 0, 0.55);
}

/* ---- Inline images / figures ------------------------------------------ */

.tp-single__body figure,
.tp-single__body .wp-block-image {
  margin: 40px 0;
}

.tp-single__body figure img,
.tp-single__body .wp-block-image img {
  width: 100%;
  height: auto;
  border-radius: 20px;
  display: block;
}

.tp-single__body figcaption,
.tp-single__body .wp-element-caption {
  margin-top: 12px;
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
  text-align: center;
  line-height: 1.5;
}

/* Wide images break out of the narrow column */
.tp-single__body .alignwide,
.tp-single__body .wp-block-image.alignwide {
  margin-left: calc(50% - 47vw);
  margin-right: calc(50% - 47vw);
  max-width: 94vw;
}

.tp-single__body .alignfull,
.tp-single__body .wp-block-image.alignfull {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  max-width: 100vw;
}

/* ---- Inline code / preformatted --------------------------------------- */

.tp-single__body code {
  background: rgba(0, 0, 0, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'SF Mono', Menlo, monospace;
  font-size: 0.92em;
  color: #c73e3e;
}

.tp-single__body pre {
  background: #1a1a1a;
  color: #f0f0f0;
  padding: 20px 24px;
  border-radius: 12px;
  overflow-x: auto;
  font-family: 'SF Mono', Menlo, monospace;
  font-size: 14px;
  line-height: 1.6;
  margin: 30px 0;
}

.tp-single__body pre code {
  background: none;
  padding: 0;
  color: inherit;
}

/* ---- HR separator ------------------------------------------------------ */

.tp-single__body hr {
  border: 0;
  border-top: 1px solid rgba(0, 0, 0, 0.12);
  margin: 40px 0;
}

/* ---- Responsive -------------------------------------------------------- */

@media (max-width: 768px) {
  .tp-single__title {
    font-size: clamp(28px, 8vw, 42px) !important;
    margin-bottom: 18px !important;
  }
  .tp-single__body {
    font-size: 17px;
    line-height: 1.65;
  }
  .tp-single__body p {
    font-size: 17px;
  }
  .tp-single__body > p:first-of-type {
    font-size: 19px;
  }
  .tp-single__body h2 { font-size: 32px; }
  .tp-single__body h3 { font-size: 26px; }
  .tp-single__body h4 { font-size: 22px; }
  .tp-single__body blockquote {
    font-size: 22px;
    margin: 28px 0;
    padding: 8px 0 8px 20px;
    max-width: 100%;
  }
  .tp-single__body .wp-block-pullquote,
  .tp-single__body .wp-block-quote.is-style-large {
    font-size: 22px;
    padding: 20px 0;
  }
}

/* ---- Dark mode --------------------------------------------------------- */

[data-theme="dark"] .tp-single__title {
  color: #f5f5f5 !important;
}

[data-theme="dark"] .tp-single__body,
[data-theme="dark"] .tp-single__body p,
[data-theme="dark"] .tp-single__body h2,
[data-theme="dark"] .tp-single__body h3,
[data-theme="dark"] .tp-single__body h4,
[data-theme="dark"] .tp-single__body strong,
[data-theme="dark"] .tp-single__body blockquote,
[data-theme="dark"] .tp-single__body .wp-block-pullquote {
  color: #e8e8e8;
}

[data-theme="dark"] .tp-single__body > p:first-of-type {
  color: rgba(255, 255, 255, 0.82);
}

[data-theme="dark"] .tp-single__body code {
  background: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   Single Post — Glossier FULL HERO overlay (v4.9.0)
   Measured from glossier.cmsmasters.studio/main/best-christmas-gift-for-fashion-lovers/
   Hero: 1900×796 with featured image as bg, all text white overlaid
   H1:   Gloock 62px/400, white, x=320 (container left)
   Lead: PT Serif 21px italic, white, x=320, w≤768
   ========================================================================== */

.tp-single--glossier {
  padding-top: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  max-width: none !important;
  margin: 0 0 80px !important;
  background: #fff;
}

/* Kill legacy .tp-single__header and .tp-single__featured — replaced by hero */
.tp-single--glossier .tp-single__header,
.tp-single--glossier .tp-single__featured,
.tp-single--glossier .tp-single__placeholder,
.tp-single--glossier > .tp-breadcrumbs {
  display: none !important;
}

/* ---- Full-width hero section ----------------------------------------- */
/* CSS breakout: forces the hero to span 100vw regardless of parent max-width.
   margin-left: calc(50% - 50vw) centers a 100vw element inside any parent. */

.tp-single--glossier .tp-single__hero,
.tp-single--glossier .tp-single__authorbar {
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

.tp-single__hero {
  position: relative;
  min-height: 780px;
  max-height: 820px;
  overflow: hidden;
  isolation: isolate;
  padding: 0;
  border-radius: 0 !important;
}

.tp-single__hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
}

/* Dark scrim — strongest at bottom-left where title sits */
.tp-single__hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(115deg, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0.42) 35%, rgba(0, 0, 0, 0.18) 60%, rgba(0, 0, 0, 0) 82%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0) 35%, rgba(0, 0, 0, 0.25) 100%);
  pointer-events: none;
}

.tp-single__hero-wrap {
  position: relative;
  z-index: 2;
  height: 100%;
  min-height: inherit;
  display: flex;
  align-items: flex-end;
  padding-top: 100px;
  padding-bottom: 110px;
  padding-left: 0;
  padding-right: 0;
}

.tp-single__hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 18px;
  max-width: 820px;
  width: 100%;
}

/* Top meta row: pill + date + views, all inline */
.tp-single__hero-topmeta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: 0.6px;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 0 6px;
}

.tp-single__hero-pill {
  display: inline-block;
  padding: 3px 12px;
  background: #FF4444;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 18px;
  border-radius: 30px;
  text-decoration: none;
  transition: background 0.2s ease;
}

.tp-single__hero-pill:hover {
  background: #e63939;
  color: #fff;
}

.tp-single__hero-date {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
  letter-spacing: normal;
  text-transform: none;
  font-size: 12px;
}

.tp-single__hero-stat {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: rgba(255, 255, 255, 0.75);
  font-weight: 500;
  font-size: 12px;
}

.tp-single__hero-stat svg {
  stroke: currentColor;
  flex: 0 0 auto;
}

/* H1 title — Gloock 62px/400 white — exact Glossier spec */
.tp-single--glossier .tp-single__title {
  font-family: 'Gloock', Georgia, serif !important;
  font-size: clamp(38px, 5.5vw, 62px) !important;
  font-weight: 400 !important;
  line-height: 1.1 !important;
  letter-spacing: normal !important;
  color: #fff !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: left !important;
  max-width: 820px;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}

/* Lead paragraph inside hero — PT Serif 21px italic white */
.tp-single__hero-lead {
  font-family: 'PT Serif', Georgia, serif;
  font-size: 21px;
  font-weight: 400;
  font-style: italic;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  margin: 6px 0 0;
  max-width: 760px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* ---- Author bar (white strip below hero) ----------------------------- */

.tp-single__authorbar {
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  padding: 24px 0;
  margin: 0;
}

.tp-single__authorbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.tp-single__authorbar-author {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--tp-secondary);
}

.tp-single__authorbar-author .tp-avatar-initial {
  width: 48px !important;
  height: 48px !important;
  font-size: 18px !important;
  border-radius: 50%;
  font-family: var(--tp-font-heading);
  border: 2px solid var(--tp-primary);
  box-sizing: border-box;
}

.tp-single__authorbar-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tp-single__authorbar-label {
  font-family: 'Poppins', sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(0, 0, 0, 0.5);
}

.tp-single__authorbar-name {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--tp-secondary);
}

.tp-single__authorbar-read {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.4px;
  color: rgba(0, 0, 0, 0.55);
}

.tp-single__authorbar-read svg {
  stroke: currentColor;
  flex: 0 0 auto;
  color: rgba(0, 0, 0, 0.45);
}

/* ---- Responsive ------------------------------------------------------- */

@media (max-width: 1024px) {
  .tp-single__hero {
    min-height: 620px;
    max-height: 700px;
  }
  .tp-single__hero-wrap {
    padding-top: 80px;
    padding-bottom: 80px;
  }
  .tp-single--glossier .tp-single__title {
    font-size: clamp(34px, 6vw, 52px) !important;
  }
  .tp-single__hero-lead {
    font-size: 19px;
  }
}

@media (max-width: 768px) {
  .tp-single__hero {
    min-height: 520px;
    max-height: none;
    height: auto;
  }
  .tp-single__hero-wrap {
    padding-top: 60px;
    padding-bottom: 60px;
    padding-left: 20px;
    padding-right: 20px;
  }
  .tp-single--glossier .tp-single__title {
    font-size: clamp(28px, 8vw, 42px) !important;
  }
  .tp-single__hero-lead {
    font-size: 16px;
  }
  .tp-single__hero-topmeta {
    gap: 12px 18px;
  }
  .tp-single__authorbar {
    padding: 18px 0;
  }
  .tp-single__authorbar-inner {
    flex-wrap: wrap;
    gap: 12px;
  }
  .tp-single__authorbar-name {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .tp-single__hero {
    min-height: 440px;
  }
  .tp-single--glossier .tp-single__title {
    font-size: 28px !important;
  }
  .tp-single__hero-lead {
    font-size: 15px;
  }
}

/* ---- Dark mode -------------------------------------------------------- */

[data-theme="dark"] .tp-single__authorbar {
  background: #141414;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .tp-single__authorbar-name {
  color: #f5f5f5;
}

[data-theme="dark"] .tp-single__authorbar-label,
[data-theme="dark"] .tp-single__authorbar-read {
  color: rgba(255, 255, 255, 0.6);
}

/* ----- Post-body layout: constrain non-hero children inside the now-
   full-width article wrapper (.tp-single--glossier has no max-width). */

.tp-single--glossier .tp-inline-newsletter,
.tp-single--glossier .tp-tags,
.tp-single--glossier .tp-share,
.tp-single--glossier .tp-author-bio,
.tp-single--glossier .tp-post-nav,
.tp-single--glossier .tp-related,
.tp-single--glossier .tp-comments-wrap,
.tp-single--glossier .tp-page-links {
  max-width: 1280px;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 20px;
  padding-right: 20px;
  box-sizing: border-box;
}

/* Force tp-single__body container above 760px inner width */
.tp-single--glossier .tp-single__body {
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
  padding: 48px 20px 0;
}

/* ==========================================================================
   v4.9.0 Hotfix — Mobile drawer clickability + header/footer spacing
   ==========================================================================
   Addresses three regressions reported on aidperspective.com (2026-04-13):
   1. Mobile drawer unclickable — .tp-drawer__panel (Category 12, line ~4964)
      applies its own transform + absolute positioning that conflicts with
      the main .tp-drawer sliding rule, producing a broken stacking context
      where clicks fall through to the backdrop. Neutralize the panel so it
      becomes a plain pass-through block inside the already-sliding drawer.
   2. Footer white band — #rsoc-mobile-anchor sits in flow after </footer>
      with min-height + margin, reserving ~90-130px of blank space even when
      empty. Collapse when empty; make the populated mobile variant fixed so
      it floats without stealing flow space.
   3. Header/page edge gap — html had no explicit background, letting the
      viewport system color bleed through at top/bottom on some devices.
   ========================================================================== */

/* --- Fix 3: page background extends to all viewport edges ------------------ */
html {
  background-color: var(--tp-bg);
}

/* --- Fix 1: neutralize conflicting .tp-drawer__panel rules ----------------- */
/* The drawer container itself handles the slide-in via .tp-drawer--open.
   The panel must be a plain inner block so nothing intercepts clicks. */
.tp-drawer .tp-drawer__panel {
  position: static;
  top: auto;
  right: auto;
  width: 100%;
  max-width: none;
  height: auto;
  min-height: 100%;
  transform: none;
  background: transparent;
  padding: 0;
  pointer-events: auto;
}

/* Reset the legacy [aria-hidden="false"] transform so it never fires. */
.tp-drawer[aria-hidden="false"] .tp-drawer__panel {
  transform: none;
}

/* Guarantee interactive elements inside the open drawer accept clicks. */
.tp-drawer.tp-drawer--open,
.tp-drawer.tp-drawer--open .tp-drawer__panel,
.tp-drawer.tp-drawer--open .tp-drawer__nav,
.tp-drawer.tp-drawer--open .tp-drawer__categories,
.tp-drawer.tp-drawer--open .tp-drawer__social,
.tp-drawer.tp-drawer--open .tp-drawer__close,
.tp-drawer.tp-drawer--open .tp-drawer__search {
  pointer-events: auto;
}

/* Close button must render ABOVE drawer content so it stays tappable. */
.tp-drawer .tp-drawer__close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
}

/* When the drawer is open, the search overlay must never cover it. The
   overlay lives above the drawer in the z-stack (--tp-z-overlay > --tp-z-drawer);
   if it's accidentally left open, demote it while nav is open. */
body.tp-nav-open .tp-search-overlay {
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
}

/* ========================================================================
   v4.9.3 Hotfix — Drawer backdrop containing-block trap
   -----------------------------------------------------------------------
   Root cause discovered via Playwright inspection: the theme renders
   <div class="tp-drawer__backdrop"> INSIDE <div class="tp-drawer">. The
   drawer has `transform: translateX(...)` (for its slide animation), which
   creates a new containing block for position:fixed descendants. That
   traps the backdrop's `inset: 0` inside the 300px drawer rect instead of
   the full viewport — the backdrop then sits ON TOP of the menu panel and
   intercepts every click via document.elementFromPoint().

   Fix: neutralize the broken in-drawer backdrop (pointer-events: none +
   transparent) and render the darkening overlay via body::before, which
   lives outside any transformed containing block and correctly covers the
   viewport. Close interactions still work via the hamburger re-tap, the
   in-drawer close button, and the Escape keyboard shortcut.
   ======================================================================== */

.tp-drawer .tp-drawer__backdrop,
.tp-drawer .tp-drawer__backdrop.tp-drawer__backdrop--visible {
  pointer-events: none !important;
  background: transparent !important;
  /* keep the element in the DOM — just make it inert visually and
     non-interactive. JS still reads classList for legacy open/close state. */
}

/* Real dimming overlay — lives outside any transform containing block. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: calc(var(--tp-z-drawer) - 1);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--tp-ease), visibility var(--tp-ease);
  pointer-events: none;
}

body.tp-nav-open::before {
  opacity: 1;
  visibility: visible;
}

/* --- Fix 2: collapse empty ad zones and un-stick the mobile anchor --------- */
/* Any ad zone with no injected content collapses to zero height.
   Covers BOTH the theme's .ad-zone class AND the rsoc-ad-zones mu-plugin's
   .rsoc-ad-zone / .shared-ad-zone classes. The mu-plugin sets inline
   style="min-height:90px" on every container, so !important is required
   to override the inline declaration. Specific IDs listed explicitly for
   belt-and-suspenders against future class-naming drift. */
.ad-zone:empty,
.rsoc-ad-zone:empty,
.shared-ad-zone:empty,
.shared-ad-zone-wrap:empty,
#rsoc-header-leaderboard:empty,
#rsoc-below-title:empty,
#rsoc-in-feed-1:empty,
#rsoc-in-feed-2:empty,
#rsoc-below-article:empty,
#rsoc-sidebar-widget:empty,
#rsoc-sidebar-sticky:empty,
#rsoc-mobile-anchor:empty {
  display: none !important;
  min-height: 0 !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  overflow: hidden !important;
}

/* The mobile anchor lives after </footer>; float it so it never occupies
   document flow space, and only render it on mobile where it's intended. */
#rsoc-mobile-anchor {
  display: none;
}

@media (max-width: 768px) {
  #rsoc-mobile-anchor {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0;
    padding: 0;
    min-height: 0;
    z-index: var(--tp-z-header);
    padding-bottom: env(safe-area-inset-bottom, 0);
    background: transparent;
    pointer-events: none;
  }
  #rsoc-mobile-anchor:not(:empty) {
    pointer-events: auto;
    background: #fff;
    box-shadow: 0 -1px 6px rgba(0, 0, 0, 0.08);
  }
  /* Reserve space at bottom of main so fixed anchor doesn't cover content. */
  #rsoc-mobile-anchor:not(:empty) ~ * {
    /* noop, but placeholder for future siblings */
  }
}

/* Footer should sit flush against the mobile anchor without extra bottom gap. */
.tp-footer {
  margin-bottom: 0;
}

/* ========================================================================
   v4.9.5 Hotfix — Duplicate chrome + mobile consent overlay
   ------------------------------------------------------------------------
   Problem 1: The fleet-wide rsoc-dark-mode.php mu-plugin renders a floating
   dark-mode toggle (#rsoc-dark-mode-toggle) on every site. TrailPost has its
   OWN .tp-dark-toggle already mounted inside the header actions, so the
   fleet plugin's toggle becomes a visible duplicate pinned to the top-right
   corner. Hide the fleet plugin's button whenever TrailPost is active —
   the theme's toggle wins because it lives inside the header chrome where
   users expect it.
   Problem 2: The fleet-wide #rsoc-cookie-consent bar has z-index 99999 and
   spans the full viewport width; the mobile drawer lives at z-index 1000.
   When the drawer opens the consent bar still paints on top, covering
   menu items and the CATEGORIES block. Hide the consent bar (visually +
   non-interactively) while the drawer is open; restore it when drawer
   closes via the existing body.tp-nav-open class toggle in main.js.
   ======================================================================== */

/* Hide fleet-wide dark-mode toggle — TrailPost has one in the header */
.wp-theme-TrailPost #rsoc-dark-mode-toggle,
body.wp-theme-TrailPost .rsoc-dm-toggle {
  display: none !important;
}

/* Hide cookie consent while the mobile drawer is open */
body.tp-nav-open #rsoc-cookie-consent,
body.tp-nav-open .rsoc-cookie-consent,
body.tp-nav-open .rsoc-consent,
body.tp-nav-open .shared-consent-bar {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

/* ========================================================================
   v4.9.6 — Dual logo variants (light + dark mode)
   ------------------------------------------------------------------------
   The TrailPost header is white in light mode and slate-900 in dark mode,
   so a single wordmark can't read on both. tp_render_site_logo() renders
   up to two <img> nodes — `tp-logo__img--light` and `tp-logo__img--dark`
   — and we toggle visibility purely in CSS. When a site only provides
   the light variant we keep the old brightness-invert fallback so we
   don't regress existing sites that haven't generated a dark logo yet.
   ======================================================================== */

/* Default (light theme): show light variant only. */
.tp-logo__img--light,
.tp-footer__logo-img--native-dark,
.tp-footer__logo-img--inverted {
  display: block;
}

.tp-logo__img--dark {
  display: none;
}

/* Dark theme: swap header logo; footer already uses dark variant natively. */
[data-theme="dark"] .tp-logo__img--light {
  display: none;
}

[data-theme="dark"] .tp-logo__img--dark {
  display: block;
}

/* Footer: when only the light logo is available, keep the legacy invert filter
   (white silhouette on dark footer). When the dark variant is present we show
   it as-is (native white-text logo, no filter needed). */
.tp-footer__logo-img--inverted {
  filter: brightness(0) invert(1);
}

.tp-footer__logo-img--native-dark {
  filter: none;
}

/* Fallback: when no dark-variant logo is uploaded, invert the light one on the
   fly so dark-mode users still see the wordmark. */
[data-theme="dark"] .custom-logo-link:not(:has(.tp-logo__img--dark)) .tp-logo__img--light {
  display: block;
  filter: brightness(0) invert(1);
}

/* ========================================================================
   v4.9.6b — Dark-mode header chrome
   ------------------------------------------------------------------------
   The fleet-wide rsoc-dark-mode.php flips <html data-theme="dark"> and
   repaints body/cards via generic --tp-* token overrides, but the theme's
   own .tp-site-header / .tp-header rules pin `background: #fff` with
   specificity 0,1,0 — no data-theme selector ever beats them. That left
   the header bright white in dark mode, which made the dark-variant
   wordmark (white text on transparent) paint white-on-white.
   Target the header chrome explicitly so it swaps to the dark surface
   color, and flip nav text to the dark-mode muted token at the same
   specificity tier.
   ======================================================================== */

[data-theme="dark"] .tp-site-header,
[data-theme="dark"] .tp-header {
  background: var(--tp-secondary, #0f172a);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .tp-nav__list a,
[data-theme="dark"] .tp-nav a,
[data-theme="dark"] .tp-logo__link {
  color: rgba(255, 255, 255, 0.9);
}

[data-theme="dark"] .tp-nav__list a:hover,
[data-theme="dark"] .tp-nav a:hover {
  color: var(--tp-primary);
}

/* Icon buttons (search, dark toggle, hamburger) need a bright stroke too */
[data-theme="dark"] .tp-search-toggle,
[data-theme="dark"] .tp-dark-toggle,
[data-theme="dark"] .tp-hamburger__line {
  color: rgba(255, 255, 255, 0.9);
}
[data-theme="dark"] .tp-hamburger__line {
  background: rgba(255, 255, 255, 0.9);
}

/* Subscribe button keeps its primary fill but with a slightly lighter outline
   so it doesn't look sunken against the dark header. */
[data-theme="dark"] .tp-subscribe-btn {
  border-color: var(--tp-primary);
}

