/*
Theme Name: Baseline
Theme URI: https://modern-wordpress.pro
Author: Modern WordPress
Author URI: https://modern-wordpress.pro
Description: A high-assurance, Google Antigravity-inspired block theme with dark and light mode architecture and zero legacy chod.
Version: 0.6.1
Requires at least: 6.5
Tested up to: 7.1.5
Requires PHP: 8.2
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mwp_baseline
*/

/* Antigravity Micro-Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  tab-size: 4;
  scroll-behavior: smooth;
  background-color: var(--wp--preset--color--base, #111111);
  color-scheme: dark light;
}

body {
  margin: 0;
  line-height: 1.65;
  background-color: var(--wp--preset--color--base, #111111);
  color: var(--wp--preset--color--contrast, #ffffff);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.2s ease, color 0.2s ease;
}

ul, menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Layout Variables */
:root {
  --mwp-header-height: 4.5rem;
}

body.admin-bar {
  --mwp-header-height: calc(4.5rem + 32px);
}

@media screen and (max-width: 782px) {
  body.admin-bar {
    --mwp-header-height: calc(4.5rem + 46px);
  }
}

/* ==========================================================================
   Dark / Light Mode Dynamic Variable Inversion
   ========================================================================== */

/* Light Mode: Automatic via OS preference when not explicitly dark */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --wp--preset--color--base: #ffffff;
    --wp--preset--color--surface: #ffffff;
    --wp--preset--color--surface-elevated: #f0f0f0;
    --wp--preset--color--surface-highest: #e5e5e5;
    --wp--preset--color--divider: rgba(0, 0, 0, 0.08);
    --wp--preset--color--contrast: #171717;
    --wp--preset--color--contrast-secondary: #525252;
    --wp--preset--color--muted: #737373;
    --wp--preset--color--accent: #171717;
    --wp--preset--color--accent-hover: #404040;
    --wp--preset--color--accent-glow: rgba(0, 0, 0, 0.08);
  }
}

/* Explicit Light Mode Override */
:root[data-theme="light"] {
  --wp--preset--color--base: #ffffff;
  --wp--preset--color--surface: #ffffff;
  --wp--preset--color--surface-elevated: #f0f0f0;
  --wp--preset--color--surface-highest: #e5e5e5;
  --wp--preset--color--divider: rgba(0, 0, 0, 0.08);
  --wp--preset--color--contrast: #171717;
  --wp--preset--color--contrast-secondary: #525252;
  --wp--preset--color--muted: #737373;
  --wp--preset--color--accent: #171717;
  --wp--preset--color--accent-hover: #404040;
  --wp--preset--color--accent-glow: rgba(0, 0, 0, 0.08);
}

/* Explicit Dark Mode Override */
:root[data-theme="dark"] {
  --wp--preset--color--base: #111111;
  --wp--preset--color--surface: #181818;
  --wp--preset--color--surface-elevated: #222222;
  --wp--preset--color--surface-highest: #2a2a2a;
  --wp--preset--color--divider: rgba(255, 255, 255, 0.08);
  --wp--preset--color--contrast: #ffffff;
  --wp--preset--color--contrast-secondary: #a3a3a3;
  --wp--preset--color--muted: #737373;
  --wp--preset--color--accent: #ffffff;
  --wp--preset--color--accent-hover: #e5e5e5;
  --wp--preset--color--accent-glow: rgba(255, 255, 255, 0.15);
}

/* Normal Weight Headings Invariant (h1, h2) */
h1,
h2,
.h1,
.h2,
h1.wp-block-heading,
h2.wp-block-heading,
.wp-block-post-title,
.wp-block-post-title a,
.wp-block-query-title,
.wp-block-site-title,
.wp-block-site-title a {
  font-weight: 400 !important;
}

/* Link Aesthetics */
a {
  color: var(--wp--preset--color--accent, #ffffff);
  text-decoration: none;
  transition: color 0.15s ease, opacity 0.15s ease;
}

a:not(.wp-block-button__link):not(.wp-element-button):hover {
  color: var(--wp--preset--color--accent-hover, #e5e5e5);
  text-decoration: none;
}

/* WCAG 2.2 AA High-Visibility Focus Ring */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--wp--preset--color--accent, #ffffff) !important;
  outline-offset: 3px !important;
}

/* Accessible Skip Link */
.skip-link {
  position: absolute;
  top: -9999px;
  left: 1.5rem;
  z-index: 100000;
  padding: 0.75rem 1.5rem;
  background: var(--wp--preset--color--surface-elevated, #222222);
  color: var(--wp--preset--color--contrast, #ffffff);
  border: 1px solid var(--wp--preset--color--accent, #ffffff);
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.875rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.skip-link:focus {
  top: 1.5rem;
}

/* Antigravity Frosted Glass Header */
header.wp-block-template-part,
.wp-block-template-part:has(.site-header-frosted),
.site-header-frosted {
  position: sticky;
  top: 0;
  z-index: 999;
  width: 100%;
}

.site-header-frosted {
  background: rgba(17, 17, 17, 0.82) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: none !important;
  transition: background-color 0.2s ease;
}

:root[data-theme="light"] .site-header-frosted {
  background: rgba(255, 255, 255, 0.85) !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .site-header-frosted {
    background: rgba(255, 255, 255, 0.85) !important;
  }
}

/* Admin bar sticky offset */
body.admin-bar header.wp-block-template-part,
body.admin-bar .wp-block-template-part:has(.site-header-frosted),
body.admin-bar .site-header-frosted {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar header.wp-block-template-part,
  body.admin-bar .wp-block-template-part:has(.site-header-frosted),
  body.admin-bar .site-header-frosted {
    top: 46px;
  }
}

/* Header Favicon Home Link & Dynamic Brand Logo */
.site-header-frosted .wp-block-image,
.site-header-frosted .wp-block-site-logo {
  margin: 0;
  display: inline-flex;
  align-items: center;
}

.site-header-frosted .wp-block-image a,
.site-header-frosted .wp-block-site-logo a {
  display: inline-flex;
  align-items: center;
  line-height: 1;
}

.site-header-frosted .wp-block-image img,
.site-header-frosted .wp-block-site-logo img {
  border-radius: 6px;
  object-fit: cover;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.site-header-frosted .wp-block-image a:hover img,
.site-header-frosted .wp-block-site-logo a:hover img {
  transform: scale(1.06);
  opacity: 0.9;
}

/* ==========================================================================
   Header Logo Backgroundless Adaptivity & Kinetic Inversion
   ========================================================================== */

/* Background elimination: strictly suppress rounded background path in the frosted header */
.site-header-frosted .wp-block-site-logo .site-logo-bg,
.site-header-frosted .custom-logo .site-logo-bg,
.site-header-frosted .site-logo-svg #Path,
.site-header-frosted .site-logo-svg .site-logo-bg,
.site-header-frosted .site-logo-svg path[id="Path"] {
  display: none !important;
  opacity: 0 !important;
  fill: none !important;
}

/* Logo mark dynamic colour: defaults to contrast variable (white in dark mode, dark in light mode) */
.site-header-frosted .wp-block-site-logo .site-logo-hooks,
.site-header-frosted .custom-logo .site-logo-hooks,
.site-header-frosted .site-logo-svg #three_hooks {
  fill: var(--wp--preset--color--contrast, #ffffff) !important;
  transition: fill 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

:root[data-theme="light"] .site-header-frosted .wp-block-site-logo .site-logo-hooks,
:root[data-theme="light"] .site-header-frosted .custom-logo .site-logo-hooks,
:root[data-theme="light"] .site-header-frosted .site-logo-svg #three_hooks {
  fill: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .site-header-frosted .wp-block-site-logo .site-logo-hooks,
  :root:not([data-theme="dark"]) .site-header-frosted .custom-logo .site-logo-hooks,
  :root:not([data-theme="dark"]) .site-header-frosted .site-logo-svg #three_hooks {
    fill: #171717 !important;
  }
}

:root[data-theme="dark"] .site-header-frosted .wp-block-site-logo .site-logo-hooks,
:root[data-theme="dark"] .site-header-frosted .custom-logo .site-logo-hooks,
:root[data-theme="dark"] .site-header-frosted .site-logo-svg #three_hooks {
  fill: #ffffff !important;
}

/* Light logo variant element hidden by default (dark mode active) */
.site-header-frosted .site-logo-light {
  display: none !important;
}

/* When light mode is active and light logo variant exists */
:root[data-theme="light"] .site-header-frosted .has-light-variant {
  display: none !important;
}

:root[data-theme="light"] .site-header-frosted .site-logo-light {
  display: inline-block !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .site-header-frosted .has-light-variant {
    display: none !important;
  }
  :root:not([data-theme="dark"]) .site-header-frosted .site-logo-light {
    display: inline-block !important;
  }
}

:root[data-theme="dark"] .site-header-frosted .has-light-variant {
  display: inline-block !important;
}

:root[data-theme="dark"] .site-header-frosted .site-logo-light {
  display: none !important;
}

/* Auto-inversion filter for primary logo on light mode (strictly for raster images, preserving SVG fills) */
:root[data-theme="light"] .site-header-frosted .site-logo-invert-on-light.site-logo-img,
:root[data-theme="light"] .site-header-frosted .site-logo-invert-on-light img {
  filter: invert(1);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .site-header-frosted .site-logo-invert-on-light.site-logo-img,
  :root:not([data-theme="dark"]) .site-header-frosted .site-logo-invert-on-light img {
    filter: invert(1);
  }
}

:root[data-theme="dark"] .site-header-frosted .site-logo-invert-on-light.site-logo-img,
:root[data-theme="dark"] .site-header-frosted .site-logo-invert-on-light img {
  filter: none !important;
}

/* Header logo dimensions & spring hover dynamics */
.site-header-frosted .wp-block-site-logo svg,
.site-header-frosted .wp-block-site-logo .custom-logo {
  display: block;
  width: 35px;
  height: 35px;
  vertical-align: middle;
  transform-origin: 50% 50%;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.3s ease;
}

.site-header-frosted .wp-block-site-logo a:hover svg,
.site-header-frosted .wp-block-site-logo a:hover .custom-logo {
  transform: scale(1.12) rotate(-8deg);
  filter: drop-shadow(0 0 10px var(--wp--preset--color--accent-glow, rgba(255, 255, 255, 0.25)));
}

.site-header-frosted .wp-block-site-logo a:active svg,
.site-header-frosted .wp-block-site-logo a:active .custom-logo {
  transform: scale(0.95);
}

/* Theme Toggle Trigger Animation: 360-degree kinetic flip */
@keyframes logoThemeFlip {
  0% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(180deg) scale(0.8);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

.site-logo-theme-flip {
  animation: logoThemeFlip 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards !important;
}

@media (prefers-reduced-motion: reduce) {
  .site-logo-theme-flip {
    animation: none !important;
  }
  .site-header-frosted .wp-block-site-logo svg,
  .site-header-frosted .wp-block-site-logo .custom-logo {
    transition: none !important;
  }
}

/* Standardised Below-The-Fold Layout Architecture */
main#main-content {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

main#main-content > .wp-block-group:last-child {
  flex: 1 0 auto;
}

.error404 main#main-content .hero-glow-container,
main#main-content:has(.hero-glow-container:only-child) .hero-glow-container {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Homepage Viewport-Stretched Hero Section */
.home main#main-content {
  margin-top: 0 !important;
}

.home main#main-content .hero-glow-container,
.hero-glow-container--viewport {
  min-height: calc(100vh - var(--mwp-header-height, 4.5rem));
  min-height: calc(100dvh - var(--mwp-header-height, 4.5rem));
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-start !important;
  align-items: center !important;
  box-sizing: border-box !important;
  padding-top: 3.5rem !important;
  padding-bottom: var(--mwp-header-height, 4.5rem) !important;
  margin-top: 0 !important;
}

.home main#main-content .hero-glow-container > .alignwide,
.hero-glow-container--viewport > .alignwide {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
}

.hero-glow-container .badge-pill {
  margin: 0 auto !important;
  display: inline-flex !important;
}

.wp-block-site-tagline {
  cursor: pointer;
  user-select: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.wp-block-site-tagline:hover {
  opacity: 0.82;
}

.wp-block-site-tagline:active {
  transform: scale(0.99);
}

.wp-block-site-tagline:focus-visible {
  outline: 2px solid var(--wp--preset--color--accent, currentColor);
  outline-offset: 4px;
  border-radius: 4px;
}

.hero-glow-container .wp-block-site-tagline {
  margin-top: 2rem !important;
  margin-bottom: 2rem !important;
  text-align: center !important;
  min-height: 2.2em;
  box-sizing: border-box;
}

@media (max-width: 640px) {
  .hero-glow-container .wp-block-site-tagline {
    min-height: 3.3em;
  }
}

/* Blog Posts Scroll Destination Offset */
#blog-posts,
.baseline-blog-posts-section,
.wp-block-query {
  scroll-margin-top: calc(70px + 1.5rem);
}

/* Atmospheric Hero Radial Glow */
.hero-glow-container {
  position: relative;
  overflow: hidden;
  background: radial-gradient(ellipse 70% 50% at 50% -10%, rgba(255, 255, 255, 0.08), rgba(17, 17, 17, 0) 75%);
  transition: background 0.3s ease;
  border-bottom: none !important;
}

:root[data-theme="light"] .hero-glow-container {
  background: radial-gradient(ellipse 70% 50% at 50% -10%, rgba(0, 0, 0, 0.04), rgba(255, 255, 255, 0) 75%) !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .hero-glow-container {
    background: radial-gradient(ellipse 70% 50% at 50% -10%, rgba(0, 0, 0, 0.04), rgba(255, 255, 255, 0) 75%) !important;
  }
}

/* Hero Card Component */
.hero-card {
  position: relative;
  background-color: var(--wp--preset--color--surface, #181818);
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
  border-radius: 20px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.hero-card:hover {
  border-color: var(--wp--preset--color--accent, #ffffff);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25), 0 0 25px var(--wp--preset--color--accent-glow, rgba(255, 255, 255, 0.1));
}

.hero-card-image img {
  transition: transform 0.25s ease;
}

.hero-card:hover .hero-card-image img {
  transform: scale(1.02);
}

@media (max-width: 781px) {
  .hero-card {
    padding: 1.5rem 1.25rem !important;
  }
}

/* Hero Telemetry Bar */
.hero-telemetry-bar {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
  align-items: center;
  justify-content: space-between;
}

a.hero-card {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-sizing: border-box;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

a.hero-card:hover {
  transform: translateY(-2px);
}

a.hero-card:focus-visible {
  outline: 2px solid var(--wp--preset--color--primary, #15868F);
  outline-offset: 4px;
}

/* Front Page Content Card Excerpt 4-Line Clamp */
body.home .hero-card__excerpt,
body.home .antigravity-card .wp-block-post-excerpt p {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 640px) {
  .hero-telemetry-bar {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 1.25rem !important;
    padding: 1.25rem !important;
  }
}

.diagnostic-terminal {
  overflow-x: auto;
  font-family: var(--wp--preset--font-family--google-sans-code) !important;
  font-size: 0.8125rem !important;
  line-height: 1.65 !important;
}

/* Antigravity Card Grid Matrix */
.antigravity-card {
  position: relative;
  background: var(--wp--preset--color--surface, #181818) !important;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08)) !important;
  border-radius: 16px !important;
  padding: 1.25rem 1.75rem !important;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease !important;
  display: flex;
  flex-direction: column;
  justifyContent: space-between;
  cursor: pointer;
}

.antigravity-card:hover {
  transform: translateY(-2px);
  border-color: var(--wp--preset--color--accent, #ffffff) !important;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25), 0 0 20px var(--wp--preset--color--accent-glow, rgba(255, 255, 255, 0.1));
}

.antigravity-card:hover .wp-block-post-title a {
  color: var(--wp--preset--color--accent, #ffffff) !important;
}

/* Stretched Link: whole card clicks through to post content */
.antigravity-card .wp-block-post-title a::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
}

/* Allow taxonomy tags/categories to remain independently clickable */
.antigravity-card .wp-block-post-terms a {
  position: relative;
  z-index: 2;
}

.antigravity-card .wp-block-post-date time {
  position: relative;
  z-index: 2;
  color: #B0B0B0 !important;
}

.antigravity-card .wp-block-post-excerpt p {
  margin: 0 !important;
}

/* Full-Width List Card Architecture */
.antigravity-card--full-width {
  width: 100% !important;
  max-width: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: space-between !important;
  gap: 0.75rem !important;
}

.antigravity-card--full-width .antigravity-card__content {
  width: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  gap: 0.25rem !important;
}

/* Card Featured Image Base & Shared Rules */
.antigravity-card--full-width .wp-block-post-featured-image,
.antigravity-card--full-width .antigravity-card__media {
  margin: 0 !important;
  padding: 0 !important;
  position: relative !important;
  z-index: 2;
  overflow: hidden !important;
  border-radius: 12px !important;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08)) !important;
  background: rgba(255, 255, 255, 0.03);
}

.antigravity-card--full-width .wp-block-post-featured-image a {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  line-height: 0 !important;
}

.antigravity-card--full-width .wp-block-post-featured-image img,
.antigravity-card--full-width .antigravity-card__media img {
  object-fit: cover !important;
  object-position: center !important;
  border-radius: 11px !important;
  display: block !important;
  margin: 0 !important;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.antigravity-card:hover .wp-block-post-featured-image img,
.antigravity-card:hover .antigravity-card__media img {
  transform: scale(1.05);
}

/* Card Featured Image Split Layout: Above sm (min-width: 641px) - Landscape Image, Same 180px Height */
@media (min-width: 641px) {
  .antigravity-card--full-width:has(.antigravity-card__media),
  .antigravity-card--full-width:has(.wp-block-post-featured-image) {
    flex-direction: row !important;
    align-items: center !important;
    gap: clamp(1.25rem, 2.5vw, 2rem) !important;
  }

  ul.wp-block-post-template:not(.is-layout-grid) > li:nth-child(even) .antigravity-card--full-width:has(.antigravity-card__media),
  ul.wp-block-post-template:not(.is-layout-grid) > li:nth-child(even) .antigravity-card--full-width:has(.wp-block-post-featured-image) {
    flex-direction: row-reverse !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image,
  .antigravity-card--full-width .antigravity-card__media {
    flex: 0 0 320px !important;
    width: 320px !important;
    max-width: 320px !important;
    height: 180px !important;
    max-height: 180px !important;
    aspect-ratio: 16 / 9 !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image a {
    max-height: 180px !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image img,
  .antigravity-card--full-width .antigravity-card__media img {
    width: 320px !important;
    height: 180px !important;
    max-width: 320px !important;
    max-height: 180px !important;
    aspect-ratio: 16 / 9 !important;
  }
}

/* Responsive adjustment for mobile screens: At or below sm (max-width: 640px) */
@media (max-width: 640px) {
  .antigravity-card--full-width:has(.antigravity-card__media),
  .antigravity-card--full-width:has(.wp-block-post-featured-image),
  ul.wp-block-post-template:not(.is-layout-grid) > li .antigravity-card--full-width,
  ul.wp-block-post-template:not(.is-layout-grid) > li:nth-child(even) .antigravity-card--full-width:has(.antigravity-card__media),
  ul.wp-block-post-template:not(.is-layout-grid) > li:nth-child(even) .antigravity-card--full-width:has(.wp-block-post-featured-image),
  .antigravity-card--full-width {
    flex-direction: column-reverse !important;
    align-items: stretch !important;
    gap: 1.25rem !important;
    padding: 1.25rem !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image,
  .antigravity-card--full-width .antigravity-card__media {
    flex: 0 0 180px !important;
    width: 100% !important;
    max-width: 180px !important;
    height: 180px !important;
    max-height: 180px !important;
    aspect-ratio: 1 / 1 !important;
    align-self: center !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image a {
    max-height: 180px !important;
  }

  .antigravity-card--full-width .wp-block-post-featured-image img,
  .antigravity-card--full-width .antigravity-card__media img {
    width: 180px !important;
    height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    aspect-ratio: 1 / 1 !important;
  }
}

@media (max-width: 480px) {
  .antigravity-card--full-width {
    padding: 1.25rem 1rem !important;
  }
}

ul.wp-block-post-template:not(.is-layout-grid) {
  display: flex !important;
  flex-direction: column !important;
  gap: 1.5rem !important;
  width: 100% !important;
  padding-left: 0 !important;
  margin: 0 !important;
  list-style: none !important;
}

ul.wp-block-post-template:not(.is-layout-grid) > li {
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

:root[data-theme="light"] .antigravity-card {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .antigravity-card {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  }
}

/* Pill Badges */
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.3125rem 0.75rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--wp--preset--color--contrast, #ffffff);
  width: fit-content;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

a.badge-pill:hover {
  text-decoration: none;
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.1);
  color: var(--wp--preset--color--contrast, #ffffff);
}

a.badge-pill:focus-visible {
  outline: 2px solid var(--wp--preset--color--primary, #15868F);
  outline-offset: 2px;
}

:root[data-theme="light"] .badge-pill {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  color: var(--wp--preset--color--contrast, #171717);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .badge-pill {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.1);
    color: var(--wp--preset--color--contrast, #171717);
  }
}

.badge-pill--green {
  color: #e5e5e5;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
}

:root[data-theme="light"] .badge-pill--green {
  color: #333333;
  border-color: rgba(0, 0, 0, 0.2);
  background: rgba(0, 0, 0, 0.05);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .badge-pill--green {
    color: #333333;
    border-color: rgba(0, 0, 0, 0.2);
    background: rgba(0, 0, 0, 0.05);
  }
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: currentColor;
  box-shadow: 0 0 8px currentColor;
}

/* ==========================================================================
   Subtle Modern Looking Glass UI Buttons
   Break brutalist linkages: Translucent frosted glass, subtle luminous borders,
   diffused ambient refraction, and fluid micro-kinetics.
   ========================================================================== */

/* Modern Primary Glass Pill Button */
.wp-block-button:not(.is-style-outline) > .wp-block-button__link,
.wp-block-button:not(.is-style-outline) > .wp-element-button,
*:not(.is-style-outline) > .wp-element-button:not(.is-style-outline),
button.wp-block-search__button {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.05) 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  border-radius: 9999px !important;
  backdrop-filter: blur(16px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(16px) saturate(180%) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.3), 0 4px 20px -2px rgba(0, 0, 0, 0.35), 0 0 12px 0 rgba(255, 255, 255, 0.05) !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
  cursor: pointer;
  user-select: none;
}

.wp-block-button:not(.is-style-outline) > .wp-block-button__link:hover,
.wp-block-button:not(.is-style-outline) > .wp-element-button:hover,
*:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):hover,
button.wp-block-search__button:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.24) 0%, rgba(255, 255, 255, 0.09) 100%) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.38) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.5), 0 8px 24px -2px rgba(0, 0, 0, 0.4), 0 0 20px 0 rgba(255, 255, 255, 0.12) !important;
  transform: translateY(-1.5px) !important;
}

.wp-block-button:not(.is-style-outline) > .wp-block-button__link:active,
.wp-block-button:not(.is-style-outline) > .wp-element-button:active,
*:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):active,
button.wp-block-search__button:active {
  transform: translateY(0) scale(0.98) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.15), 0 2px 8px -1px rgba(0, 0, 0, 0.3) !important;
}

:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-block-button__link,
:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-element-button,
:root[data-theme="light"] *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline),
:root[data-theme="light"] button.wp-block-search__button {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
  color: #111111 !important;
  border: 1px solid rgba(0, 0, 0, 0.12) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
}

:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-block-button__link:hover,
:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-element-button:hover,
:root[data-theme="light"] *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):hover,
:root[data-theme="light"] button.wp-block-search__button:hover {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
  color: #111111 !important;
  border-color: rgba(0, 0, 0, 0.22) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 8px 24px -2px rgba(0, 0, 0, 0.1) !important;
  transform: translateY(-1.5px) !important;
}

:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-block-button__link:active,
:root[data-theme="light"] .wp-block-button:not(.is-style-outline) > .wp-element-button:active,
:root[data-theme="light"] *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):active,
:root[data-theme="light"] button.wp-block-search__button:active {
  transform: translateY(0) scale(0.98) !important;
  box-shadow: inset 0 1px 0 0 rgba(0, 0, 0, 0.05), 0 2px 8px -1px rgba(0, 0, 0, 0.06) !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-block-button__link,
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-element-button,
  :root:not([data-theme="dark"]) *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline),
  :root:not([data-theme="dark"]) button.wp-block-search__button {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
    color: #111111 !important;
    border: 1px solid rgba(0, 0, 0, 0.12) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
  }
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-block-button__link:hover,
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-element-button:hover,
  :root:not([data-theme="dark"]) *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):hover,
  :root:not([data-theme="dark"]) button.wp-block-search__button:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
    color: #111111 !important;
    border-color: rgba(0, 0, 0, 0.22) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 8px 24px -2px rgba(0, 0, 0, 0.1) !important;
    transform: translateY(-1.5px) !important;
  }
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-block-button__link:active,
  :root:not([data-theme="dark"]) .wp-block-button:not(.is-style-outline) > .wp-element-button:active,
  :root:not([data-theme="dark"]) *:not(.is-style-outline) > .wp-element-button:not(.is-style-outline):active,
  :root:not([data-theme="dark"]) button.wp-block-search__button:active {
    transform: translateY(0) scale(0.98) !important;
    box-shadow: inset 0 1px 0 0 rgba(0, 0, 0, 0.05), 0 2px 8px -1px rgba(0, 0, 0, 0.06) !important;
  }
}

/* Modern Outline Glass Pill Button */
.wp-block-button.is-style-outline .wp-block-button__link,
.wp-block-button.is-style-outline .wp-element-button,
.is-style-outline > .wp-element-button,
.wp-element-button.is-style-outline {
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: rgba(255, 255, 255, 0.92) !important;
  background: rgba(255, 255, 255, 0.03) !important;
  border-radius: 9999px !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12) !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.wp-block-button.is-style-outline .wp-block-button__link:hover,
.wp-block-button.is-style-outline .wp-element-button:hover,
.is-style-outline > .wp-element-button:hover,
.wp-element-button.is-style-outline:hover {
  border-color: rgba(255, 255, 255, 0.35) !important;
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.09) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25), 0 4px 16px rgba(0, 0, 0, 0.25) !important;
  transform: translateY(-1.5px) !important;
}

:root[data-theme="light"] .wp-block-button.is-style-outline .wp-block-button__link,
:root[data-theme="light"] .wp-block-button.is-style-outline .wp-element-button,
:root[data-theme="light"] .is-style-outline > .wp-element-button,
:root[data-theme="light"] .wp-element-button.is-style-outline {
  border-color: rgba(0, 0, 0, 0.12) !important;
  color: #171717 !important;
  background: rgba(0, 0, 0, 0.02) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8) !important;
}

:root[data-theme="light"] .wp-block-button.is-style-outline .wp-block-button__link:hover,
:root[data-theme="light"] .wp-block-button.is-style-outline .wp-element-button:hover,
:root[data-theme="light"] .is-style-outline > .wp-element-button:hover,
:root[data-theme="light"] .wp-element-button.is-style-outline:hover {
  border-color: rgba(0, 0, 0, 0.22) !important;
  color: #000000 !important;
  background: rgba(0, 0, 0, 0.06) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 16px rgba(0, 0, 0, 0.06) !important;
  transform: translateY(-1.5px) !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-block-button.is-style-outline .wp-block-button__link,
  :root:not([data-theme="dark"]) .wp-block-button.is-style-outline .wp-element-button,
  :root:not([data-theme="dark"]) .is-style-outline > .wp-element-button,
  :root:not([data-theme="dark"]) .wp-element-button.is-style-outline {
    border-color: rgba(0, 0, 0, 0.12) !important;
    color: #171717 !important;
    background: rgba(0, 0, 0, 0.02) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8) !important;
  }

  :root:not([data-theme="dark"]) .wp-block-button.is-style-outline .wp-block-button__link:hover,
  :root:not([data-theme="dark"]) .wp-block-button.is-style-outline .wp-element-button:hover,
  :root:not([data-theme="dark"]) .is-style-outline > .wp-element-button:hover,
  :root:not([data-theme="dark"]) .wp-element-button.is-style-outline:hover {
    border-color: rgba(0, 0, 0, 0.22) !important;
    color: #000000 !important;
    background: rgba(0, 0, 0, 0.06) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 16px rgba(0, 0, 0, 0.06) !important;
    transform: translateY(-1.5px) !important;
  }
}

/* Single Blog Post Navigation Links (Previous / All / Next) */
.single-post-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.single-post-navigation .post-navigation-link-previous,
.single-post-navigation .single-post-navigation__all,
.single-post-navigation .post-navigation-link-next {
  flex: 1 1 0%;
  margin: 0;
  padding: 0;
}

.single-post-navigation .post-navigation-link-previous {
  text-align: left;
}

.single-post-navigation .single-post-navigation__all {
  text-align: center;
}

.single-post-navigation .post-navigation-link-next {
  text-align: right;
  display: flex;
  justify-content: flex-end;
}

.single-post-navigation a {
  display: inline-flex;
  align-items: center;
  font-family: var(--wp--preset--font-family--google-sans-flex);
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--wp--preset--color--contrast, #ffffff);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--wp--preset--color--divider, rgba(255, 255, 255, 0.2));
  min-height: 44px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.single-post-navigation a:hover {
  color: var(--wp--preset--color--accent-hover, #e5e5e5);
  text-decoration-color: currentColor;
}

:root[data-theme="light"] .single-post-navigation a {
  color: var(--wp--preset--color--contrast, #171717);
  text-decoration-color: var(--wp--preset--color--divider, rgba(0, 0, 0, 0.2));
}

:root[data-theme="light"] .single-post-navigation a:hover {
  color: var(--wp--preset--color--accent-hover, #404040);
  text-decoration-color: currentColor;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .single-post-navigation a {
    color: var(--wp--preset--color--contrast, #171717);
    text-decoration-color: var(--wp--preset--color--divider, rgba(0, 0, 0, 0.2));
  }

  :root:not([data-theme="dark"]) .single-post-navigation a:hover {
    color: var(--wp--preset--color--accent-hover, #404040);
    text-decoration-color: currentColor;
  }
}

/* Theme Toggle Button (WCAG 44x44px Touch Target) */
.theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.2), 0 2px 8px rgba(0, 0, 0, 0.15);
  color: var(--wp--preset--color--contrast, #ffffff);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.theme-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.32);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.35), 0 4px 14px rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

:root[data-theme="light"] .theme-toggle-btn {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8), 0 2px 8px rgba(0, 0, 0, 0.04);
  color: #171717;
}

:root[data-theme="light"] .theme-toggle-btn:hover {
  background: rgba(0, 0, 0, 0.08);
  border-color: rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 14px rgba(0, 0, 0, 0.06);
  transform: translateY(-1px);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .theme-toggle-btn {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8), 0 2px 8px rgba(0, 0, 0, 0.04);
    color: #171717;
  }
  :root:not([data-theme="dark"]) .theme-toggle-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    border-color: rgba(0, 0, 0, 0.2);
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 14px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
  }
}

/* Code Snippet Polish */
pre.wp-block-code {
  background: var(--wp--preset--color--surface, #181818) !important;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08)) !important;
  border-radius: 12px !important;
}

:root[data-theme="light"] pre.wp-block-code {
  background: #f0f0f0 !important;
  color: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) pre.wp-block-code {
    background: #f0f0f0 !important;
    color: #171717 !important;
  }
}

/* Post Featured Image (Center Aligned, 320px Max Height Cover) */
.wp-block-post-featured-image,
.wp-block-post-featured-image.aligncenter,
.aligncenter.wp-block-post-featured-image {
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center !important;
  max-height: 320px !important;
  overflow: hidden !important;
  border-radius: 4px;
}

.wp-block-post-featured-image a {
  display: block;
  width: 100%;
  max-height: 320px !important;
  overflow: hidden;
  border-radius: 4px;
}

.wp-block-post-featured-image img,
.wp-block-post-featured-image.aligncenter img,
.aligncenter.wp-block-post-featured-image img {
  display: block !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  height: 320px !important;
  max-height: 320px !important;
  object-fit: cover !important;
  object-position: center !important;
  border-radius: 4px;
}

/* ==========================================================================
   Responsive Tables & Lighthouse Report Architecture
   ========================================================================== */
.wp-block-table {
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-top: 1.75rem;
  margin-bottom: 2.25rem;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
  border-radius: 12px;
  background-color: var(--wp--preset--color--surface, #181818);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.wp-block-table table {
  border-collapse: collapse;
  width: 100%;
  min-width: 680px;
  text-align: left;
  font-size: 0.875rem;
  line-height: 1.5;
  margin: 0;
  border: none !important;
}

.wp-block-table.has-fixed-layout table,
.wp-block-table table.has-fixed-layout {
  table-layout: auto !important;
  width: 100%;
}

.wp-block-table thead {
  border-bottom: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.12)) !important;
  border-top: none !important;
}

.wp-block-table th {
  background-color: var(--wp--preset--color--surface-elevated, #222222);
  color: var(--wp--preset--color--contrast, #ffffff);
  font-family: var(--wp--preset--font-family--google-sans-flex);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.875rem 1rem !important;
  border: none !important;
  border-bottom: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.12)) !important;
  white-space: nowrap;
}

.wp-block-table td {
  padding: 0.875rem 1rem !important;
  color: var(--wp--preset--color--contrast, #ffffff);
  border: none !important;
  border-bottom: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.06)) !important;
  vertical-align: middle;
}

.wp-block-table tbody tr:last-child td {
  border-bottom: none !important;
}

/* Striped Table Rows (Overrides WP Core's hardcoded #f0f0f0 white-on-white bug) */
.wp-block-table.is-style-stripes {
  border-collapse: collapse;
  border-spacing: 0;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08)) !important;
}

.wp-block-table.is-style-stripes tbody tr:nth-child(odd) {
  background-color: var(--wp--preset--color--surface-elevated, #222222) !important;
}

.wp-block-table.is-style-stripes tbody tr:nth-child(even) {
  background-color: var(--wp--preset--color--surface, #181818) !important;
}

.wp-block-table tbody tr:hover td {
  background-color: var(--wp--preset--color--surface-highest, #2a2a2a) !important;
}

/* Code elements inside tables */
.wp-block-table code {
  font-family: var(--wp--preset--font-family--google-sans-code) !important;
  font-size: 0.8125rem !important;
  padding: 0.2rem 0.45rem !important;
  border-radius: 4px;
  background-color: var(--wp--preset--color--surface-highest, #2a2a2a);
  color: var(--wp--preset--color--contrast, #ffffff);
  word-break: break-all;
}

/* Scrollbar refinement for horizontal overflow */
.wp-block-table::-webkit-scrollbar {
  height: 6px;
}
.wp-block-table::-webkit-scrollbar-track {
  background: var(--wp--preset--color--surface, #181818);
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}
.wp-block-table::-webkit-scrollbar-thumb {
  background: var(--wp--preset--color--divider, rgba(255, 255, 255, 0.18));
  border-radius: 9999px;
}
.wp-block-table::-webkit-scrollbar-thumb:hover {
  background: var(--wp--preset--color--accent-hover, rgba(255, 255, 255, 0.3));
}

/* Lighthouse Score Badges & Status Indicators */
.lh-score-group {
  display: inline-flex;
  flex-direction: column;
  gap: 0.35rem;
}

.lh-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  min-width: 2.25rem;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  font-family: var(--wp--preset--font-family--google-sans-flex);
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  width: fit-content;
}

.lh-score--good {
  background-color: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.35);
  color: #4ade80;
}

.lh-score--average {
  background-color: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.lh-score--poor {
  background-color: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.35);
  color: #f87171;
}

.lh-pass {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  background-color: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #4ade80;
  font-family: var(--wp--preset--font-family--google-sans-flex);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.lh-metric-value {
  font-family: var(--wp--preset--font-family--google-sans-code);
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--wp--preset--color--contrast, #ffffff);
}

/* Inline Alert Callout */
.mwp-alert-callout {
  border-left: 4px solid var(--wp--preset--color--accent, #15868F) !important;
  background: rgba(21, 134, 143, 0.08);
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

:root[data-theme="light"] .mwp-alert-callout {
  background: rgba(21, 134, 143, 0.06);
  border-left-color: #15868F !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

/* Light Mode Overrides */
:root[data-theme="light"] .wp-block-table {
  background-color: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

:root[data-theme="light"] .wp-block-table th {
  background-color: #f8fafc;
  color: #171717;
  border-bottom-color: rgba(0, 0, 0, 0.08) !important;
}

:root[data-theme="light"] .wp-block-table td {
  color: #171717;
  border-bottom-color: rgba(0, 0, 0, 0.06) !important;
}

:root[data-theme="light"] .wp-block-table.is-style-stripes {
  border-color: rgba(0, 0, 0, 0.08) !important;
}

:root[data-theme="light"] .wp-block-table.is-style-stripes tbody tr:nth-child(odd) {
  background-color: #f8fafc !important;
}

:root[data-theme="light"] .wp-block-table.is-style-stripes tbody tr:nth-child(even) {
  background-color: #ffffff !important;
}

:root[data-theme="light"] .wp-block-table tbody tr:hover td {
  background-color: #f1f5f9 !important;
}

:root[data-theme="light"] .wp-block-table code {
  background-color: #f1f5f9;
  color: #171717;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

:root[data-theme="light"] .wp-block-table::-webkit-scrollbar-track {
  background: #ffffff;
}

:root[data-theme="light"] .wp-block-table::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
}

:root[data-theme="light"] .lh-score--good {
  background-color: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.3);
  color: #15803d;
}

:root[data-theme="light"] .lh-score--average {
  background-color: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
  color: #b45309;
}

:root[data-theme="light"] .lh-score--poor {
  background-color: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.3);
  color: #b91c1c;
}

:root[data-theme="light"] .lh-pass {
  background-color: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.3);
  color: #15803d;
}

:root[data-theme="light"] .lh-metric-value {
  color: #171717;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-block-table {
    background-color: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  }

  :root:not([data-theme="dark"]) .wp-block-table th {
    background-color: #f8fafc;
    color: #171717;
    border-bottom-color: rgba(0, 0, 0, 0.08) !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table td {
    color: #171717;
    border-bottom-color: rgba(0, 0, 0, 0.06) !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table.is-style-stripes {
    border-color: rgba(0, 0, 0, 0.08) !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table.is-style-stripes tbody tr:nth-child(odd) {
    background-color: #f8fafc !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table.is-style-stripes tbody tr:nth-child(even) {
    background-color: #ffffff !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table tbody tr:hover td {
    background-color: #f1f5f9 !important;
  }

  :root:not([data-theme="dark"]) .wp-block-table code {
    background-color: #f1f5f9;
    color: #171717;
    border: 1px solid rgba(0, 0, 0, 0.08);
  }

  :root:not([data-theme="dark"]) .wp-block-table::-webkit-scrollbar-track {
    background: #ffffff;
  }

  :root:not([data-theme="dark"]) .wp-block-table::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
  }

  :root:not([data-theme="dark"]) .lh-score--good {
    background-color: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.3);
    color: #15803d;
  }

  :root:not([data-theme="dark"]) .lh-score--average {
    background-color: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.3);
    color: #b45309;
  }

  :root:not([data-theme="dark"]) .lh-score--poor {
    background-color: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.3);
    color: #b91c1c;
  }

  :root:not([data-theme="dark"]) .lh-pass {
    background-color: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #15803d;
  }

  :root:not([data-theme="dark"]) .lh-metric-value {
    color: #171717;
  }
}

/* ==========================================================================
   Tag Cloud & Badge Architecture
   ========================================================================== */
.wp-block-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.625rem;
  align-items: center;
  margin: 1.5rem 0;
  line-height: 1.4;
}

.wp-block-tag-cloud a {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  background-color: var(--wp--preset--color--surface-elevated, #222222);
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
  color: var(--wp--preset--color--contrast, #ffffff);
  text-decoration: none;
  font-size: 0.875rem !important;
  font-weight: 500;
  transition: all 0.15s ease;
}

.wp-block-tag-cloud a:hover {
  background-color: var(--wp--preset--color--surface-highest, #2a2a2a);
  border-color: var(--wp--preset--color--muted, #737373);
  color: var(--wp--preset--color--accent, #ffffff);
}

.wp-block-tag-cloud a .tag-link-count {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.1rem 0.45rem;
  border-radius: 9999px;
  background: var(--wp--preset--color--surface-highest, #2a2a2a);
  color: var(--wp--preset--color--contrast-secondary, #a3a3a3);
}

:root[data-theme="light"] .wp-block-tag-cloud a {
  background-color: var(--wp--preset--color--surface, #ffffff);
  border-color: var(--wp--preset--color--divider, rgba(0, 0, 0, 0.08));
  color: var(--wp--preset--color--contrast, #171717);
}

:root[data-theme="light"] .wp-block-tag-cloud a:hover {
  background-color: var(--wp--preset--color--surface-elevated, #f0f0f0);
  border-color: var(--wp--preset--color--muted, #737373);
}

:root[data-theme="light"] .wp-block-tag-cloud a .tag-link-count {
  background: var(--wp--preset--color--surface-elevated, #f0f0f0);
  color: var(--wp--preset--color--contrast-secondary, #525252);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-block-tag-cloud a {
    background-color: var(--wp--preset--color--surface, #ffffff);
    border-color: var(--wp--preset--color--divider, rgba(0, 0, 0, 0.08));
    color: var(--wp--preset--color--contrast, #171717);
  }

  :root:not([data-theme="dark"]) .wp-block-tag-cloud a:hover {
    background-color: var(--wp--preset--color--surface-elevated, #f0f0f0);
    border-color: var(--wp--preset--color--muted, #737373);
  }

  :root:not([data-theme="dark"]) .wp-block-tag-cloud a .tag-link-count {
    background: var(--wp--preset--color--surface-elevated, #f0f0f0);
    color: var(--wp--preset--color--contrast-secondary, #525252);
  }
}

/* Footer Heading Links & Spacing */
footer .wp-block-heading {
  margin-top: 0;
  margin-bottom: 0.75rem;
}

footer .wp-block-heading a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease;
}

footer .wp-block-heading a:hover {
  color: var(--wp--preset--color--accent-hover, #e5e5e5);
  text-decoration: none;
}

/* Footer & List-Style Tag Cloud Architecture */
footer .wp-block-tag-cloud,
.wp-block-tag-cloud.is-style-list {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  margin: 0;
  line-height: 1.65;
}

footer .wp-block-tag-cloud a,
.wp-block-tag-cloud.is-style-list a,
footer .wp-block-categories-list a {
  display: inline-block;
  min-height: 24px;
  line-height: 24px;
  padding: 3px 0;
  border: none;
  border-radius: 0;
  background: transparent !important;
  color: var(--wp--preset--color--contrast, #ffffff);
  font-size: 0.8125rem !important;
  font-weight: 400;
  margin: 0;
  transition: color 0.15s ease;
}

footer .wp-block-tag-cloud a:hover,
.wp-block-tag-cloud.is-style-list a:hover {
  background: transparent !important;
  border: none;
  color: var(--wp--preset--color--accent-hover, #e5e5e5);
  text-decoration: none;
}

:root[data-theme="light"] footer .wp-block-tag-cloud a,
:root[data-theme="light"] .wp-block-tag-cloud.is-style-list a {
  background: transparent !important;
  border: none;
  color: var(--wp--preset--color--contrast, #171717);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) footer .wp-block-tag-cloud a,
  :root:not([data-theme="dark"]) .wp-block-tag-cloud.is-style-list a {
    background: transparent !important;
    border: none;
    color: var(--wp--preset--color--contrast, #171717);
  }
}

/* Footer Categories List Alignment */
footer .wp-block-categories {
  font-size: 0.8125rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

footer .wp-block-categories li {
  line-height: 1.65;
  margin: 0;
}

footer .wp-block-categories li a {
  color: var(--wp--preset--color--contrast, #ffffff);
  text-decoration: none;
  transition: color 0.15s ease;
}

footer .wp-block-categories li a:hover {
  color: var(--wp--preset--color--accent-hover, #e5e5e5);
  text-decoration: none;
}

:root[data-theme="light"] footer .wp-block-categories li a {
  color: var(--wp--preset--color--contrast, #171717);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) footer .wp-block-categories li a {
    color: var(--wp--preset--color--contrast, #171717);
  }
}

/* Zero Dividers & Underlines Reset */
footer.wp-block-group {
  border-top: none !important;
}

hr,
.wp-block-separator {
  display: none !important;
  border: none !important;
  height: 0 !important;
}

.wp-block-navigation-item a,
.wp-block-navigation__container a {
  text-decoration: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}

/* ==========================================================================
   Action Dialog Modal Architecture (Invariant 23 & Settings Suite)
   ========================================================================== */

body.mwp-action-dialog-open {
  overflow: hidden;
}

.mwp-action-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.mwp-action-dialog-backdrop {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: mwpFadeIn 0.2s ease-out;
}

.mwp-action-dialog-frame {
  position: relative;
  width: 100%;
  max-width: 480px;
  background-color: var(--wp--preset--color--surface, #181818);
  color: var(--wp--preset--color--contrast, #ffffff);
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.12));
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  animation: mwpScaleUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

:root[data-theme="dark"] .mwp-action-dialog-frame {
  background-color: #181818;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
}

:root[data-theme="light"] .mwp-action-dialog-frame {
  background-color: #ffffff;
  color: #171717;
  border-color: rgba(0, 0, 0, 0.1);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-action-dialog-frame {
    background-color: #ffffff;
    color: #171717;
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  }
}

/* Dialog Header */
.mwp-action-dialog-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.1));
}

:root[data-theme="dark"] .mwp-action-dialog-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

:root[data-theme="light"] .mwp-action-dialog-header {
  border-bottom-color: rgba(0, 0, 0, 0.08);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-action-dialog-header {
    border-bottom-color: rgba(0, 0, 0, 0.08);
  }
}

.mwp-action-dialog-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background-color: rgba(21, 134, 143, 0.15);
  color: var(--wp--preset--color--primary, #15868F);
  border-radius: 8px;
  flex-shrink: 0;
}

.mwp-action-dialog-title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 600;
  flex-grow: 1;
  letter-spacing: -0.01em;
}

.mwp-action-dialog-close-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: 0;
  background: transparent;
  color: var(--wp--preset--color--muted, #a3a3a3);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.mwp-action-dialog-close-btn:hover {
  color: var(--wp--preset--color--contrast, #ffffff);
  background-color: rgba(255, 255, 255, 0.08);
}

:root[data-theme="light"] .mwp-action-dialog-close-btn:hover {
  color: #171717;
  background-color: rgba(0, 0, 0, 0.05);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-action-dialog-close-btn:hover {
    color: #171717;
    background-color: rgba(0, 0, 0, 0.05);
  }
}

.mwp-action-dialog-body {
  padding: 1.25rem 1.5rem;
  max-height: calc(85vh - 120px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Settings Sections */
.mwp-settings-section {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mwp-settings-section:not(:last-child) {
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
}

:root[data-theme="dark"] .mwp-settings-section:not(:last-child) {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

:root[data-theme="light"] .mwp-settings-section:not(:last-child) {
  border-bottom-color: rgba(0, 0, 0, 0.06);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-settings-section:not(:last-child) {
    border-bottom-color: rgba(0, 0, 0, 0.06);
  }
}

.mwp-settings-heading {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.mwp-settings-subtext {
  margin: 0.2rem 0 0;
  font-size: 0.8125rem;
  color: var(--wp--preset--color--muted, #a3a3a3);
}

:root[data-theme="light"] .mwp-settings-subtext {
  color: #737373;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-settings-subtext {
    color: #737373;
  }
}

/* Theme Segmented Switcher */
.mwp-theme-segmented-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 4px;
  background-color: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
  border-radius: 10px;
}

:root[data-theme="dark"] .mwp-theme-segmented-control {
  background-color: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
}

:root[data-theme="light"] .mwp-theme-segmented-control {
  background-color: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.08);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-theme-segmented-control {
    background-color: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.08);
  }
}

.mwp-theme-choice-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0 0.75rem;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--wp--preset--color--muted, #a3a3a3);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.mwp-theme-choice-btn:hover {
  color: var(--wp--preset--color--contrast, #ffffff);
  background: rgba(255, 255, 255, 0.05);
}

:root[data-theme="light"] .mwp-theme-choice-btn:hover {
  color: #171717;
  background: rgba(0, 0, 0, 0.04);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-theme-choice-btn:hover {
    color: #171717;
    background: rgba(0, 0, 0, 0.04);
  }
}

/* Glass Active Choice Segment */
.mwp-theme-choice-btn.is-active {
  background: rgba(255, 255, 255, 0.14) !important;
  color: #ffffff !important;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.3), 0 2px 8px rgba(0, 0, 0, 0.25) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

:root[data-theme="light"] .mwp-theme-choice-btn.is-active {
  background: rgba(0, 0, 0, 0.08) !important;
  color: #111111 !important;
  border-color: rgba(0, 0, 0, 0.16) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 2px 8px rgba(0, 0, 0, 0.05) !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-theme-choice-btn.is-active {
    background: rgba(0, 0, 0, 0.08) !important;
    color: #111111 !important;
    border-color: rgba(0, 0, 0, 0.16) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 2px 8px rgba(0, 0, 0, 0.05) !important;
  }
}

/* Locale Grid */
.mwp-settings-locale-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
}

.mwp-settings-locale-card {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.5rem 0.75rem;
  min-height: 44px;
  border-radius: 8px;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.1));
  background-color: rgba(255, 255, 255, 0.02);
  color: var(--wp--preset--color--contrast, #ffffff);
  text-decoration: none;
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.mwp-settings-locale-card:hover {
  border-color: var(--wp--preset--color--primary, #15868F);
  background-color: rgba(21, 134, 143, 0.08);
}

:root[data-theme="dark"] .mwp-settings-locale-card {
  border-color: rgba(255, 255, 255, 0.1);
  background-color: rgba(255, 255, 255, 0.02);
  color: #ffffff;
}

:root[data-theme="light"] .mwp-settings-locale-card {
  border-color: rgba(0, 0, 0, 0.08);
  background-color: rgba(0, 0, 0, 0.02);
  color: #171717;
}

:root[data-theme="light"] .mwp-settings-locale-card:hover {
  border-color: var(--wp--preset--color--primary, #15868F);
  background-color: rgba(21, 134, 143, 0.06);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-settings-locale-card {
    border-color: rgba(0, 0, 0, 0.08);
    background-color: rgba(0, 0, 0, 0.02);
    color: #171717;
  }
  :root:not([data-theme="dark"]) .mwp-settings-locale-card:hover {
    border-color: var(--wp--preset--color--primary, #15868F);
    background-color: rgba(21, 134, 143, 0.06);
  }
}

.mwp-settings-locale-card.is-active {
  border-color: var(--wp--preset--color--primary, #15868F);
  background-color: rgba(21, 134, 143, 0.15);
  font-weight: 600;
}

.mwp-settings-flag-img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(0, 0, 0, 0.15);
}

.mwp-settings-flag-emoji {
  font-size: 1.125rem;
  line-height: 1;
}

.mwp-settings-locale-name {
  flex-grow: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mwp-settings-current-badge {
  font-size: 0.6875rem;
  padding: 2px 6px;
  border-radius: 4px;
  background-color: var(--wp--preset--color--primary, #15868F);
  color: #ffffff;
  font-weight: 600;
}

/* Share Section in Settings */
.mwp-settings-share-box {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mwp-settings-dialog-frame .mwp-share-copy-input {
  background-color: rgba(255, 255, 255, 0.05);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

:root[data-theme="light"] .mwp-settings-dialog-frame .mwp-share-copy-input {
  background-color: rgba(0, 0, 0, 0.04);
  color: #171717;
  border-color: rgba(0, 0, 0, 0.12);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-settings-dialog-frame .mwp-share-copy-input {
    background-color: rgba(0, 0, 0, 0.04);
    color: #171717;
    border-color: rgba(0, 0, 0, 0.12);
  }
}

.mwp-settings-open-share-suite-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 44px;
  padding: 0.625rem 1rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.04) 100%) !important;
  color: #ffffff !important;
  font-size: 0.875rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25), 0 4px 16px -2px rgba(0, 0, 0, 0.3) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.mwp-settings-open-share-suite-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.08) 100%) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.4), 0 6px 20px -2px rgba(255, 255, 255, 0.1) !important;
  transform: translateY(-1.5px) !important;
  color: #ffffff !important;
}

.mwp-settings-open-share-suite-btn:active {
  transform: translateY(0) scale(0.99) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.15), 0 2px 6px -1px rgba(0, 0, 0, 0.3) !important;
}

:root[data-theme="light"] .mwp-settings-open-share-suite-btn {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
  color: #171717 !important;
  border: 1px solid rgba(0, 0, 0, 0.12) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
}

:root[data-theme="light"] .mwp-settings-open-share-suite-btn:hover {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
  border-color: rgba(0, 0, 0, 0.22) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
  transform: translateY(-1.5px) !important;
  color: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .mwp-settings-open-share-suite-btn {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
    color: #171717 !important;
    border: 1px solid rgba(0, 0, 0, 0.12) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
  }
  :root:not([data-theme="dark"]) .mwp-settings-open-share-suite-btn:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
    border-color: rgba(0, 0, 0, 0.22) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
    transform: translateY(-1.5px) !important;
    color: #171717 !important;
  }
}

/* Mobile Bottom Sheet Layout */
@media (max-width: 640px) {
  .mwp-action-dialog-overlay {
    padding: 0;
    align-items: flex-end;
  }

  .mwp-action-dialog-frame {
    max-width: 100%;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    max-height: 90vh;
    animation: mwpSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .mwp-action-dialog-footer.mwp-mobile-only {
    display: block;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.1));
  }

  :root[data-theme="dark"] .mwp-action-dialog-footer.mwp-mobile-only {
    border-top-color: rgba(255, 255, 255, 0.1);
  }

  :root[data-theme="light"] .mwp-action-dialog-footer.mwp-mobile-only {
    border-top-color: rgba(0, 0, 0, 0.08);
  }

  @media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) .mwp-action-dialog-footer.mwp-mobile-only {
      border-top-color: rgba(0, 0, 0, 0.08);
    }
  }

  .mwp-action-dialog-dismiss-btn {
    width: 100%;
    min-height: 44px;
    background-color: rgba(255, 255, 255, 0.08);
    color: var(--wp--preset--color--contrast, #ffffff);
    border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.15));
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
  }

  :root[data-theme="dark"] .mwp-action-dialog-dismiss-btn {
    background-color: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.15);
  }

  :root[data-theme="light"] .mwp-action-dialog-dismiss-btn {
    background-color: rgba(0, 0, 0, 0.05);
    color: #171717;
    border-color: rgba(0, 0, 0, 0.12);
  }

  @media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) .mwp-action-dialog-dismiss-btn {
      background-color: rgba(0, 0, 0, 0.05);
      color: #171717;
      border-color: rgba(0, 0, 0, 0.12);
    }
  }
}

@media (min-width: 641px) {
  .mwp-action-dialog-footer.mwp-mobile-only {
    display: none;
  }
}

@media (max-width: 640px) {
  .site-header-frosted,
  main#main-content > .wp-block-group.alignwide,
  main#main-content > .alignwide {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
}

/* ==========================================================================
   Shared Plugin Button Glass Overrides (Baseline Theme Isolation)
   Explicitly breaks brutalist ink borders and offset drop shadows.
   ========================================================================== */


/* Share Suite Trigger Buttons in Baseline */
.wp-theme-mwp_baseline .mwp-share-trigger-btn {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.04) 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 9999px !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25), 0 4px 16px -2px rgba(0, 0, 0, 0.3) !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.wp-theme-mwp_baseline .mwp-share-trigger-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.08) 100%) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.4), 0 6px 20px -2px rgba(255, 255, 255, 0.1) !important;
  transform: translateY(-1.5px) !important;
}

.wp-theme-mwp_baseline .mwp-share-trigger-btn:active {
  transform: translateY(0) scale(0.99) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12), 0 2px 6px -1px rgba(0, 0, 0, 0.3) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-trigger-btn {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
  color: #171717 !important;
  border: 1px solid rgba(0, 0, 0, 0.16) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-trigger-btn:hover {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
  border-color: rgba(0, 0, 0, 0.28) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
  color: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-trigger-btn {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
    color: #171717 !important;
    border: 1px solid rgba(0, 0, 0, 0.16) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
  }

  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-trigger-btn:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
    border-color: rgba(0, 0, 0, 0.28) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
    color: #171717 !important;
  }
}

/* EPUB CTA Button in Baseline */
.wp-theme-mwp_baseline .epub-btn-cta {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.04) 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 9999px !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25), 0 4px 16px -2px rgba(0, 0, 0, 0.3) !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.wp-theme-mwp_baseline .epub-btn-cta:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.08) 100%) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.4), 0 6px 20px -2px rgba(255, 255, 255, 0.1) !important;
  transform: translateY(-1.5px) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .epub-btn-cta {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
  color: #171717 !important;
  border-color: rgba(0, 0, 0, 0.16) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .epub-btn-cta:hover {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
  border-color: rgba(0, 0, 0, 0.28) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
  color: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .epub-btn-cta {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.02) 100%) !important;
    color: #171717 !important;
    border-color: rgba(0, 0, 0, 0.16) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 4px 16px -2px rgba(0, 0, 0, 0.06) !important;
  }

  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .epub-btn-cta:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.04) 100%) !important;
    border-color: rgba(0, 0, 0, 0.28) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 20px -2px rgba(0, 0, 0, 0.1) !important;
    color: #171717 !important;
  }
}

/* Copy Link and Channel Buttons in Baseline */
.wp-theme-mwp_baseline .mwp-share-copy-btn,
.mwp-settings-dialog-frame .mwp-share-copy-btn {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.06) 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  border-radius: 8px !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25) !important;
  transition: all 0.2s ease !important;
}

.wp-theme-mwp_baseline .mwp-share-copy-btn:hover,
.mwp-settings-dialog-frame .mwp-share-copy-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.1) 100%) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.4), 0 4px 12px rgba(0, 0, 0, 0.2) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-copy-btn,
:root[data-theme="light"] .mwp-settings-dialog-frame .mwp-share-copy-btn,
:root[data-theme="light"] .mwp-share-dialog .mwp-share-copy-btn {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.08) 0%, rgba(0, 0, 0, 0.03) 100%) !important;
  color: #171717 !important;
  border: 1px solid rgba(0, 0, 0, 0.18) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 2px 6px rgba(0, 0, 0, 0.05) !important;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-copy-btn:hover,
:root[data-theme="light"] .mwp-settings-dialog-frame .mwp-share-copy-btn:hover,
:root[data-theme="light"] .mwp-share-dialog .mwp-share-copy-btn:hover {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.14) 0%, rgba(0, 0, 0, 0.06) 100%) !important;
  border-color: rgba(0, 0, 0, 0.28) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 12px rgba(0, 0, 0, 0.1) !important;
  color: #171717 !important;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-copy-btn,
  :root:not([data-theme="dark"]) .mwp-settings-dialog-frame .mwp-share-copy-btn,
  :root:not([data-theme="dark"]) .mwp-share-dialog .mwp-share-copy-btn {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.08) 0%, rgba(0, 0, 0, 0.03) 100%) !important;
    color: #171717 !important;
    border: 1px solid rgba(0, 0, 0, 0.18) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.9), 0 2px 6px rgba(0, 0, 0, 0.05) !important;
  }

  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-copy-btn:hover,
  :root:not([data-theme="dark"]) .mwp-settings-dialog-frame .mwp-share-copy-btn:hover,
  :root:not([data-theme="dark"]) .mwp-share-dialog .mwp-share-copy-btn:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.14) 0%, rgba(0, 0, 0, 0.06) 100%) !important;
    border-color: rgba(0, 0, 0, 0.28) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    color: #171717 !important;
  }
}

.wp-theme-mwp_baseline .mwp-share-copy-btn.copied,
.mwp-settings-dialog-frame .mwp-share-copy-btn.copied {
  background: #16a34a !important;
  color: #ffffff !important;
  border-color: #15803d !important;
}

.wp-theme-mwp_baseline .mwp-share-channel-btn {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.1);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.wp-theme-mwp_baseline .mwp-share-channel-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.25), 0 6px 18px rgba(0, 0, 0, 0.25);
  transform: translateY(-2px);
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-channel-btn {
  border-color: rgba(0, 0, 0, 0.14);
  background: rgba(0, 0, 0, 0.03);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8);
  color: #171717;
}

:root[data-theme="light"] .wp-theme-mwp_baseline .mwp-share-channel-btn:hover {
  background: rgba(0, 0, 0, 0.07);
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 18px rgba(0, 0, 0, 0.06);
  color: #171717;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-channel-btn {
    border-color: rgba(0, 0, 0, 0.14);
    background: rgba(0, 0, 0, 0.03);
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8);
    color: #171717;
  }

  :root:not([data-theme="dark"]) .wp-theme-mwp_baseline .mwp-share-channel-btn:hover {
    background: rgba(0, 0, 0, 0.07);
    border-color: rgba(0, 0, 0, 0.24);
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 1), 0 6px 18px rgba(0, 0, 0, 0.06);
    color: #171717;
  }
}

@keyframes mwpFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes mwpScaleUp {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes mwpSlideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* Modern Flash Ident Hero Stage */
.mwp-flash-hero {
  width: 100%;
  height: 250px;
  min-height: 250px;
  max-height: 250px;
  border-radius: 16px;
  overflow: hidden;
  background-color: #000000;
  border: 1px solid var(--wp--preset--color--divider, rgba(255, 255, 255, 0.08));
  box-sizing: border-box;
}

.mwp-flash-hero .flash-stage,
.mwp-flash-hero .flash-ident {
  width: 100% !important;
  height: 250px !important;
  min-height: 250px !important;
  max-height: 250px !important;
}

/* Reduced Motion Override */
@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;
  }
}
