/*
Theme Name: Small Business Theme Template
Theme URI: 
Author: Rothirsch Tech. GmbH
Author URI: https://www.rothirsch.tech
Description: A premium, professional WordPress theme for small businesses featuring glass morphism design, luxury color schemes, 10 selectable font sets via the Customizer, premium animations, and sophisticated UI components. Includes 9 stunning color schemes with automatic dark mode, 9 landing page layouts, and modern responsive design that creates an expensive, high-end appearance while remaining accessible for small businesses.
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 8.1
Version: 2.6.67
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rtsb-theme
Domain Path: /languages
Tags: modern, business, premium, luxury, gradient, animated, glass-morphism, professional, responsive, typography, dark-mode, translation-ready
*/

/* CSS Custom Properties for WCAG-Compliant Theme */
:root {
  /* Native controls (date pickers, scrollbars, selects) follow the page's scheme. */
  color-scheme: light;
  --border-radius: 8px;
  --border-radius-sm: 6px;
  --border-radius-lg: 12px;
  --border-radius-xl: 16px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  
  /* Advanced Spacing Scale */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  
  /* Typography Scale */
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
  --font-size-5xl: 3rem;
  --font-size-6xl: 3.75rem;

  /* Font Families (overridden by dynamic font set CSS) */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Space Grotesk', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Playfair Display', Georgia, serif;

  /* Typographic tuning (overridden per font set + dark mode) */
  --font-size-adjust: 1;
  --font-body-letter-spacing: normal;
  --font-body-word-spacing: normal;

  /* Line Heights */
  --line-height-tight: 1.25;
  --line-height-snug: 1.375;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.625;
  --line-height-loose: 2;
  
  /* Letter Spacing */
  --letter-spacing-tight: -0.025em;
  --letter-spacing-normal: 0;
  --letter-spacing-wide: 0.025em;
  --letter-spacing-wider: 0.05em;
  --letter-spacing-widest: 0.1em;
  
  /* Advanced Spacing System */
  --section-padding: var(--space-4xl);
  --content-max-width: 1200px;
  --content-narrow: 800px;
  --content-wide: 1400px;
  
  /* Responsive Breakpoints */
  --breakpoint-sm: 640px;
  --breakpoint-md: 768px;
  --breakpoint-lg: 1024px;
  --breakpoint-xl: 1280px;
  --breakpoint-2xl: 1536px;
}

/* Color scheme variables are generated dynamically via inc/color-generator.php
   and output in <head> by rtsb_theme_dynamic_css(). */

/* Dark mode global overrides */
@media (prefers-color-scheme: dark) {
  :root { color-scheme: dark; }

  /* Force light text in dark mode */
  :root h1, :root h2, :root h3, :root h4, :root h5, :root h6,
  body h1, body h2, body h3, body h4, body h5, body h6,
  body .entry-content, body .content-card, body .entry-title,
  body .hero-title, body .hero-subtitle,
  body .contact-focus h2, body .contact-focus h3,
  body .services-focus h2, body .services-focus h3,
  body .content-minimal h1, body .content-minimal h2, body .content-minimal h3,
  body .content-card-minimal h2, body .content-card-minimal h3,
  body .content-timeline h2 {
    color: #fafafa !important;
  }

  body .entry-content p, body .content-card p, body p,
  body .contact-focus p, body .services-focus p,
  body .content-minimal p, body .hero-content p,
  body .content-card-minimal p,
  body span, body div {
    color: #e4e4e7 !important;
  }

  body .entry-meta,
  body .entry-meta time,
  body .entry-meta span {
    color: #c4c4cc !important;
  }

  body .excerpt-content,
  body .excerpt-content p {
    color: #e4e4e7 !important;
  }

  /* Preserve proper button text colors — override the broad span/div rule */
  body .read-more-link,
  body .cta-phone-link,
  body .btn,
  body button[type="submit"],
  body input[type="submit"] {
    color: var(--text-on-accent) !important;
  }

  /* Let the secure-login plugin manage its own colors */
  body .secure-login-container .button-primary,
  body .secure-login-container .tab-button.active {
    color: var(--button-color-font) !important;
  }

  /* Secure-login notice boxes use light bg + dark text from the plugin.
     The broad `body div` override above flips text to light, destroying
     contrast. Restore the plugin's intended dark text for each notice. */
  body .secure-login-container .activation-notice,
  body .secure-login-container .activation-notice * {
    color: var(--info-text, #0c5460) !important;
  }
  body .secure-login-container .success-message,
  body .secure-login-container .success-message * {
    color: var(--success-text, #155724) !important;
  }
  body .secure-login-container .validation-message,
  body .secure-login-container .validation-message * {
    color: var(--error-text, #721c24) !important;
  }
  /* .error-message was the one notice type missing from this list — the
     login-failed / throttle box rendered light gray on light pink (~1.3:1). */
  body .secure-login-container .error-message,
  body .secure-login-container .error-message * {
    color: var(--error-text, #721c24) !important;
  }
  body .secure-login-container .activation-info,
  body .secure-login-container .activation-info * {
    color: var(--warning-text, #856404) !important;
  }

  /* The span/div rule above also hits labels inside filled buttons, tags and
     badges, which then read light-on-light. Button labels follow their
     button; brand fills take the fill's text colour. */
  body a[class*="button"] span,
  body a[class*="cta"] span,
  body button span {
    color: inherit !important;
  }

  body .site-header__cta,
  body .site-header__cta *,
  body .tf-price-tag,
  body .storefront-tag--accent {
    color: var(--text-on-primary-fill, #ffffff) !important;
  }

  body .rtsb-team__initial,
  body .rtsb-feed__media-empty {
    color: var(--page-ink, var(--text-primary)) !important;
  }

  /* Hero CTA and contact buttons sit on dark gradient backgrounds — keep white */
  body .cta-button,
  body .hero-phone-link,
  body .hero-email-link {
    color: #ffffff !important;
  }

}

/* WP Secure Login plugin variable bridge
   Defined on the container element to inherit final color-scheme values */
.secure-login-container {
  --button-color: var(--primary-fill, var(--primary-color));
  --button-color-hover: var(--secondary-color);
  --button-color-active: var(--secondary-color);
  --button-color-font: var(--text-on-primary-fill, var(--text-on-primary));
  --button-color-font-hover: var(--text-on-secondary);
  --button-color-font-active: var(--text-on-secondary);
  --text-color: var(--text-primary);
  --h2-color: var(--text-primary);
  --form-bg: var(--white);
  --form-text: var(--text-primary);
  --another-shade: var(--gray-50);
  --border-color: var(--gray-200);
  --link-color: var(--accent-color);
  --link-color-hover: var(--primary-color);
  --shadow-color: var(--shadow-sm);
  --bg-color: var(--white);
}

@media (prefers-color-scheme: dark) {
  .secure-login-container {
    --form-bg: var(--gray-200);
    --bg-color: var(--gray-100);
    --another-shade: var(--gray-100);
    --border-color: var(--gray-300);
    --shadow-color: rgba(0, 0, 0, 0.3);
  }
}

html {
  box-sizing: border-box;
  scroll-behavior: smooth;
  overflow-x: hidden;
  font-size: calc(100% * var(--font-size-adjust, 1));
}

*, *:before, *:after {
  box-sizing: inherit;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--gray-50);
  color: var(--text-primary);
  line-height: var(--line-height-relaxed);
  font-size: var(--font-size-lg);
  font-weight: 400;
  letter-spacing: var(--font-body-letter-spacing, normal);
  word-spacing: var(--font-body-word-spacing, normal);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Global heading styles with premium typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
  margin: 0 0 var(--space-lg) 0;
}

/* Hero and display headings use Playfair Display for elegance */
.hero-title,
.display-heading,
h1.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: var(--letter-spacing-tight);
}

/* Typography scale for headings */
h1 { 
  font-size: var(--font-size-5xl); 
  font-weight: 700;
}

h2 { 
  font-size: var(--font-size-4xl); 
  font-weight: 600;
}

h3 { 
  font-size: var(--font-size-3xl); 
  font-weight: 600;
}

h4 { 
  font-size: var(--font-size-2xl); 
  font-weight: 500;
}

h5 { 
  font-size: var(--font-size-xl); 
  font-weight: 500;
}

h6 { 
  font-size: var(--font-size-lg); 
  font-weight: 500;
}

/* Respect user's motion preferences */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* =============================================================================
   Cookie Consent Banner Styles
   ============================================================================= */

/* Cookie Banner - Base Styles */
.bcc-banner {
  position: fixed;
  left: 0; 
  right: 0; 
  bottom: 0;
  z-index: 99999;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--gray-200);
  padding: var(--space-lg);
  box-shadow: var(--shadow-lg);
  font-family: var(--font-body);
  transition: var(--transition);
}

.bcc-banner .bcc-content {
  max-width: var(--content-max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-lg);
  align-items: center;
}

.bcc-banner .bcc-content > div:first-child {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.bcc-banner .bcc-badgelike {
  display: inline-block;
  padding: var(--space-xs) var(--space-sm);
  background: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  border-radius: var(--border-radius-sm);
  font-size: var(--font-size-sm);
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.bcc-banner span {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: var(--line-height-relaxed);
}

.bcc-banner .bcc-actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

/* Cookie Banner Buttons */
.bcc-btn {
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--border-radius);
  border: 2px solid transparent;
  cursor: pointer;
  font-family: inherit;
  font-size: var(--font-size-sm);
  font-weight: 500;
  transition: var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.bcc-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.bcc-btn:active {
  transform: translateY(0);
}

.bcc-btn-primary {
  background: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  border-color: var(--primary-color);
}

.bcc-btn-primary:hover {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
}

.bcc-btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border-color: var(--gray-200);
}

.bcc-btn-secondary:hover {
  background: var(--gray-100);
  color: var(--text-primary);
}

.bcc-btn:not(.bcc-btn-primary):not(.bcc-btn-secondary) {
  background: transparent;
  color: var(--text-muted);
  text-decoration: underline;
}

.bcc-btn:not(.bcc-btn-primary):not(.bcc-btn-secondary):hover {
  color: var(--text-secondary);
}

/* Cookie Modal/Panel */
.bcc-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  display: none;
  z-index: 100000;
  padding: var(--space-lg);
}

.bcc-modal {
  background: var(--white);
  color: var(--text-primary);
  max-width: 600px;
  margin: 10vh auto;
  border-radius: var(--border-radius-lg);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-lg);
  position: relative;
}

.bcc-modal h3 {
  margin: 0 0 var(--space-lg) 0;
  color: var(--text-primary);
  font-family: var(--font-display);
  font-size: var(--font-size-2xl);
  font-weight: 600;
}

/* Cookie Toggles */
.bcc-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-lg) 0;
  border-bottom: 1px solid var(--gray-200);
}

.bcc-toggle:last-of-type {
  border-bottom: none;
}

.bcc-toggle > div {
  flex: 1;
  margin-right: var(--space-lg);
}

.bcc-toggle strong {
  display: block;
  color: var(--text-primary);
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.bcc-toggle small {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  line-height: var(--line-height-relaxed);
}

.bcc-toggle label {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

.bcc-toggle input[type="checkbox"] {
  width: 20px;
  height: 20px;
  border: 2px solid var(--gray-300);
  border-radius: var(--border-radius-sm);
  background: var(--white);
  cursor: pointer;
  transition: var(--transition);
}

.bcc-toggle input[type="checkbox"]:checked {
  background: var(--primary-fill, var(--primary-color));
  border-color: var(--primary-color);
}

.bcc-toggle input[type="checkbox"]:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Modal Actions */
.bcc-modal > div:last-child {
  margin-top: var(--space-xl);
  display: flex;
  gap: var(--space-sm);
  justify-content: flex-end;
}

/* Manage Link */
.bcc-manage-link {
  background: none;
  border: none;
  color: var(--text-muted);
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.bcc-manage-link:hover {
  color: var(--text-secondary);
}

/* Responsive Design */
@media (max-width: 768px) {
  .bcc-banner .bcc-content {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }
  
  .bcc-banner .bcc-actions {
    justify-content: center;
  }
  
  .bcc-modal {
    margin: 5vh auto;
    padding: var(--space-lg);
    max-width: calc(100vw - 2rem);
  }
  
  .bcc-toggle {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }
  
  .bcc-toggle > div {
    margin-right: 0;
  }
  
  .bcc-modal > div:last-child {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .bcc-banner .bcc-actions {
    flex-direction: column;
  }
  
  .bcc-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Accessible Header Styling */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 1rem 2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 1000;
  margin-bottom: 2rem;
}

/* Hide hamburger menu on desktop */
.hamburger-menu {
  display: none;
}

.site-branding h1 {
  margin: 0;
  font-weight: 700;
  font-size: 1.75rem;
  color: var(--primary-color);
  letter-spacing: -0.01em;
}

.site-branding h1 a {
  color: var(--primary-color);
  text-decoration: none;
}

.site-branding h1 a:hover {
  color: var(--accent-color);
}

.site-branding p {
  margin: 0.25rem 0 0 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Custom logo styling with fixed height */
.custom-logo-link {
  display: block;
  line-height: 1;
}

.site-header .custom-logo {
  height: 60px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  /* Per-mode halo so the logo stays visible whether it is light or dark.
     Light mode: dark outline rescues white/light logos. */
  filter: drop-shadow(0 0 1.5px rgba(0, 0, 0, 0.5)) drop-shadow(0 0 3px rgba(0, 0, 0, 0.25));
}

@media (prefers-color-scheme: dark) {
  /* Dark mode: light outline rescues dark logos. */
  .site-header .custom-logo {
    filter: drop-shadow(0 0 1.5px rgba(255, 255, 255, 0.55)) drop-shadow(0 0 3px rgba(255, 255, 255, 0.3));
  }
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 0.5rem;
}

.site-nav li {
  margin: 0;
}

.site-nav a {
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 500;
  font-size: 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius);
  transition: var(--transition);
  border: 2px solid transparent;
  display: block;
}

.site-nav a:hover {
  background: var(--gray-100);
  color: var(--accent-color);
}

.site-nav a:focus {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-color);
}

/* Accessible Main Content Area */
.site-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Premium Hero Section with Gradients and Modern Design */
.hero-section,
.hero-minimal,
.hero-services,
.hero-contact,
.hero-portfolio,
.hero-corporate,
.hero-storefront,
.hero-magazine,
.hero-about {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 50%, var(--accent-fill, var(--accent-color)) 100%);
  color: var(--text-on-primary-fill, var(--text-on-primary));
  padding: var(--space-4xl) 0;
  text-align: center;
  margin: 0 0 var(--space-3xl) 0;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

/* Add subtle animated background pattern */
.hero-section::before,
.hero-minimal::before,
.hero-services::before,
.hero-contact::before,
.hero-portfolio::before,
.hero-corporate::before,
.hero-storefront::before,
.hero-magazine::before,
.hero-about::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 25% 25%, rgba(255, 255, 255, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
  animation: float 6s ease-in-out infinite;
  pointer-events: none;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(1deg); }
}

/* Customizer hero background photo, rendered as a real <img> by
   rtsb_theme_hero_background() (t1619) so the browser can find it in the
   HTML, prioritise it and pick a viewport-sized candidate from srcset.
   The wrapper sits at z-index -1 inside the hero's stacking context
   (isolation: isolate, set by the dynamic CSS): above the section's own
   background, below the content and the ::before/::after decorations —
   the same paint order the former CSS background had. ::after is the
   40 % dark overlay that used to be the gradient layer of that background. */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg__img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  object-fit: cover;
  object-position: center;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}


.hero-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  position: relative;
  z-index: 1;
  animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-title {
  font-family: var(--font-display);
  font-size: var(--font-size-6xl);
  font-weight: 600;
  margin: 0 0 var(--space-lg) 0;
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
  text-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
  animation: fadeInUp 0.8s ease-out 0.2s both;
  color: #ffffff;
}

.hero-subtitle {
  font-family: var(--font-body);
  font-size: var(--font-size-xl);
  margin: 0 0 var(--space-xl) 0;
  font-weight: 400;
  line-height: var(--line-height-relaxed);
  letter-spacing: var(--letter-spacing-wide);
  opacity: 0.95;
  animation: fadeInUp 0.8s ease-out 0.4s both;
  color: #ffffff;
}

.hero-subtitle-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.25em;
  text-decoration-thickness: 1px;
  transition: var(--transition);
}

.hero-subtitle-link:hover {
  text-decoration-thickness: 2px;
  text-underline-offset: 0.125em;
}

.hero-subtitle-link:focus {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 4px;
  border-radius: 4px;
}

.hero-phone,
.hero-email {
  font-size: var(--font-size-lg);
  margin: var(--space-lg) 0 0 0;
  font-weight: 500;
  animation: fadeInUp 0.8s ease-out 0.6s both;
  color: #ffffff;
}

.hero-phone-link,
.hero-email-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: inherit;
  text-decoration: none;
  padding: var(--space-lg) var(--space-xl);
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--border-radius-lg);
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(20px);
  font-weight: 600;
  letter-spacing: var(--letter-spacing-wide);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15), 0 4px 10px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.hero-phone-link::before,
.hero-email-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.hero-phone-link:hover::before,
.hero-email-link:hover::before {
  left: 100%;
}

.hero-phone-link:hover,
.hero-email-link:hover {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2), 0 8px 15px rgba(0, 0, 0, 0.15);
}

.hero-phone-link:focus,
.hero-email-link:focus {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 4px;
  border-radius: var(--border-radius-lg);
}

.hero-phone-link .rtsb-icon,
.hero-email-link .rtsb-icon {
  opacity: 0.9;
  margin-right: 0.25rem;
}

@media (max-width: 768px) {
  .hero-phone,
  .hero-email {
    font-size: 1rem;
  }
  
  .hero-phone-link,
  .hero-email-link {
    padding: 0.625rem 1.25rem;
    font-size: 0.9rem;
  }
}

/* Premium Glass Morphism Content Cards */
.content-card {
  background: var(--white);
  backdrop-filter: blur(20px);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-lg);
  padding: var(--space-2xl);
  margin-bottom: var(--space-2xl);
  transition: var(--transition);
  border-left: 4px solid var(--accent-color);
  position: relative;
  overflow: hidden;
  animation: slideInUp 0.6s ease-out;
}

.content-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gray-300), transparent);
  opacity: 0.6;
}

.content-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-8px) scale(1.02);
  border-color: var(--gray-300);
}

.content-card:focus-within {
  box-shadow: var(--focus-ring), var(--shadow-lg);
  transform: translateY(-4px);
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/*
 * Customizer preview only (body.customizer-preview is added solely inside the
 * Customizer preview iframe, never on the live site).
 *
 * WordPress anchors the selective-refresh edit pencil to the partial's nearest
 * positioned ancestor. The legal/contact partials are not positioned, so the
 * pencil anchored to the .content-card (position:relative) and the button's
 * ~30px left offset pushed it off the left edge of the preview, where it got
 * clipped. Making each partial container position:relative re-anchors the
 * pencil into the card's own left padding, where it is fully visible. We also
 * keep the card overflow visible as a safety net for the rounded corners.
 */
body.customizer-preview .content-card {
  overflow: visible;
}
body.customizer-preview .about-page,
body.customizer-preview .impressum-page,
body.customizer-preview .privacy-page,
body.customizer-preview .agb-page,
body.customizer-preview .contact-page .contact-address,
body.customizer-preview .contact-page .contact-phone,
body.customizer-preview .contact-page .contact-email,
body.customizer-preview .contact-page .contact-map {
  position: relative;
}

/*
 * Same re-anchoring for the per-layout content-section / metric partials
 * (.rtsb-sec{N}-title/-body, .rtsb-met{N}-number/-label). These hook classes
 * are sprinkled across every landing-page template, so positioning them here
 * keeps the edit pencil inside the element on whichever layout is active.
 */
body.customizer-preview .rtsb-sec1-title,
body.customizer-preview .rtsb-sec2-title,
body.customizer-preview .rtsb-sec3-title,
body.customizer-preview .rtsb-sec1-body,
body.customizer-preview .rtsb-sec2-body,
body.customizer-preview .rtsb-sec3-body,
body.customizer-preview .rtsb-met1-number,
body.customizer-preview .rtsb-met2-number,
body.customizer-preview .rtsb-met3-number,
body.customizer-preview .rtsb-met1-label,
body.customizer-preview .rtsb-met2-label,
body.customizer-preview .rtsb-met3-label {
  position: relative;
}
body.customizer-preview .metrics-section,
body.customizer-preview .metrics-container,
body.customizer-preview .person-metrics,
body.customizer-preview .tf-pricing,
body.customizer-preview .content-section {
  overflow: visible;
}

/*
 * Hero eyebrow site-name pencil (.rtsb-site-name) — anchor it inside its own
 * box so the edit shortcut stays on the name text on every layout. .hero-section
 * is already position:relative via the hero-background inline style, so its own
 * background-image pencil needs no extra rule here.
 */
body.customizer-preview .rtsb-site-name {
  position: relative;
}

.content-card {
  color: var(--text-primary);
}

.content-card h1,
.content-card h2,
.content-card h3,
.content-card h4,
.content-card h5,
.content-card h6 {
  margin-top: 0;
  margin-bottom: var(--space-lg);
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--text-primary);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
}

.content-card h1 { font-size: var(--font-size-4xl); }
.content-card h2 { font-size: var(--font-size-3xl); }
.content-card h3 { font-size: var(--font-size-2xl); }
.content-card h4 { font-size: var(--font-size-xl); }
.content-card h5 { font-size: var(--font-size-lg); }
.content-card h6 { font-size: var(--font-size-base); }

.content-card p {
  margin-bottom: var(--space-lg);
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
  color: var(--text-secondary);
  letter-spacing: var(--letter-spacing-normal);
}

.content-card strong {
  color: var(--text-primary);
  font-weight: 700;
}

.content-card em {
  color: var(--text-secondary);
  font-style: italic;
}

.content-card ul,
.content-card ol {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.content-card li {
  margin-bottom: 0.5rem;
}

.entry-header h1, 
.entry-header h2 {
  margin-top: 0;
  margin-bottom: 1rem;
  font-weight: 700;
  font-size: 2rem;
  color: var(--text-primary);
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.entry-content {
  color: var(--text-primary);
}

.entry-content p {
  margin-bottom: 1.5rem;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 1.5rem 0 1rem 0;
}

.entry-content h1:first-child,
.entry-content h2:first-child,
.entry-content h3:first-child,
.entry-content h4:first-child,
.entry-content h5:first-child,
.entry-content h6:first-child {
  margin-top: 0;
}

.entry-content strong {
  color: var(--text-primary);
  font-weight: 700;
}

.entry-content em {
  color: var(--text-secondary);
  font-style: italic;
}

.entry-content ul,
.entry-content ol {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.entry-content li {
  margin-bottom: 0.5rem;
}

.entry-content blockquote {
  border-left: 4px solid var(--accent-color);
  margin-left: 0;
  padding-left: 1.5rem;
  color: var(--text-secondary);
  font-style: italic;
}

.entry-meta {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-weight: 400;
}

/* Accessible Link Styling */
a {
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 0.125em;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-color);
  text-decoration-thickness: 2px;
}

a:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Accessible Blog Post List - Responsive Grid Layout */
.post-list {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  grid-auto-rows: 1fr;
  align-items: stretch;
}

/* Tablet - 2 columns */
@media (min-width: 768px) {
  .post-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop - 3 columns */
@media (min-width: 1200px) {
  .post-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.post-list > article {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 2rem;
  margin-bottom: 0;
  transition: var(--transition);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.post-list > article:hover {
  box-shadow: var(--shadow-md);
}

.post-list > article:focus-within {
  box-shadow: var(--focus-ring), var(--shadow-md);
}

/* Premium Button Styles with Glass Morphism */
.btn, 
button[type="submit"], 
input[type="submit"] {
  background: linear-gradient(135deg, var(--accent-fill, var(--accent-color)) 0%, var(--primary-fill, var(--primary-color)) 100%);
  color: var(--text-on-accent);
  border: 2px solid rgba(255, 255, 255, 0.2);
  padding: var(--space-lg) var(--space-xl);
  border-radius: var(--border-radius-lg);
  font-weight: 600;
  font-size: var(--font-size-base);
  font-family: var(--font-body);
  letter-spacing: var(--letter-spacing-wide);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  display: inline-block;
  min-height: 44px;
  min-width: 44px;
  box-shadow: 
    0 8px 25px rgba(0, 0, 0, 0.15), 
    0 4px 10px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
}

.btn::before, 
button[type="submit"]::before, 
input[type="submit"]::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
  /* Decoration only: where a button loses overflow: hidden, the sweep rests
     beside it and must not take the clicks of its neighbour. */
  pointer-events: none;
}

.btn:hover::before,
button[type="submit"]:hover::before,
input[type="submit"]:hover::before {
  left: 100%;
}

.btn:hover,
button[type="submit"]:hover,
input[type="submit"]:hover {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  border-color: rgba(255, 255, 255, 0.4);
  color: var(--text-on-primary-fill, var(--text-on-primary));
  transform: translateY(-2px) scale(1.05);
  box-shadow: 
    0 15px 35px rgba(0, 0, 0, 0.2), 
    0 8px 15px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.btn:focus,
button[type="submit"]:focus,
input[type="submit"]:focus {
  outline: none;
  box-shadow: var(--focus-ring), 
    0 8px 25px rgba(0, 0, 0, 0.15), 
    0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Premium Button Variants */
.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  border: 2px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(20px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
}

/* =============================================================================
   Comments — Discussion list & comment form
   ============================================================================= */

.comments-area {
  max-width: 768px;
  margin: var(--space-3xl) auto 0;
  padding-top: var(--space-2xl);
  border-top: 1px solid var(--gray-200);
}

.comments-title,
.comment-reply-title {
  font-size: var(--font-size-2xl);
  margin-bottom: var(--space-xl);
}

/* --- Threaded comment list --- */
.comment-list {
  list-style: none;
  margin: 0 0 var(--space-2xl) 0;
  padding: 0;
}

.comment-list .comment {
  margin-bottom: var(--space-lg);
}

/* Nested replies: indent + connecting rail so threads stay readable at scale */
.comment-list .children {
  list-style: none;
  margin: var(--space-lg) 0 0 0;
  padding-left: var(--space-lg);
  border-left: 2px solid var(--gray-200);
}

@media (min-width: 768px) {
  .comment-list .children {
    padding-left: var(--space-xl);
  }
}

.comment-body {
  position: relative;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
  transition: var(--transition);
}

.comment-body:hover {
  box-shadow: var(--shadow-md);
}

/* Author header: avatar + name + date on one tidy row */
.comment-author {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 600;
  color: var(--text-primary);
}

.comment-author .avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  object-fit: cover;
}

.comment-author .fn {
  font-style: normal;
}

.comment-author .says {
  display: none;
}

.comment-metadata {
  margin: var(--space-xs) 0 var(--space-sm) 0;
  font-size: var(--font-size-sm);
}

.comment-metadata a {
  color: var(--text-muted);
  text-decoration: none;
}

.comment-metadata a:hover {
  color: var(--accent-color);
}

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

.comment-content p:last-child {
  margin-bottom: 0;
}

/* Highlight the post author so readers can spot official replies in a busy thread */
.comment-list .bypostauthor > .comment-body {
  border-color: var(--accent-color);
  border-left-width: 4px;
}

.comment-awaiting-moderation {
  display: inline-block;
  margin-top: var(--space-sm);
  font-size: var(--font-size-sm);
  font-style: italic;
  color: var(--text-muted);
}

/* Reply link as a compact, unobtrusive action */
.comment-body .reply {
  margin-top: var(--space-sm);
}

.comment-reply-link {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--accent-color);
  border: 1px solid var(--gray-300);
  border-radius: var(--border-radius-sm);
  text-decoration: none;
  transition: var(--transition);
}

.comment-reply-link:hover {
  color: var(--text-on-accent);
  background: var(--accent-color);
  border-color: var(--accent-color);
}

/* --- Pagination for long discussions --- */
.comments-pagination,
.comment-navigation {
  margin-bottom: var(--space-2xl);
}

.comments-pagination .page-numbers {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  margin: 0 0.15rem;
  border-radius: var(--border-radius-sm);
  border: 1px solid var(--gray-300);
  color: var(--text-primary);
  text-decoration: none;
  transition: var(--transition);
}

.comments-pagination .page-numbers.current,
.comments-pagination .page-numbers:hover {
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--text-on-accent);
}

.no-comments {
  color: var(--text-muted);
  font-style: italic;
}

/* --- Comment form (the "Schreibe einen Kommentar" card) --- */
.comment-respond {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-md);
  padding: var(--space-2xl);
}

.comment-list .comment .comment-respond {
  margin-top: var(--space-lg);
}

.comment-form {
  margin: 0;
}

.logged-in-as,
.comment-notes {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-lg);
}

/* Stack label above field instead of WP's default inline float */
.comment-form p {
  display: flex;
  flex-direction: column;
  margin-bottom: var(--space-lg);
}

.comment-form label {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  box-sizing: border-box;
  background: var(--white);
  color: var(--text-primary);
  border: 1px solid var(--gray-300);
  border-radius: var(--border-radius);
  padding: 12px 16px;
  font-size: var(--font-size-base);
  font-family: inherit;
  transition: var(--transition);
}

.comment-form textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.6;
}

.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: var(--focus-ring);
}

.comment-form input::placeholder,
.comment-form textarea::placeholder {
  color: var(--text-muted);
}

/* Author/email/url side by side on wide screens, stacked on mobile */
@media (min-width: 640px) {
  .comment-form-author,
  .comment-form-email,
  .comment-form-url {
    display: inline-flex;
    width: calc(50% - var(--space-sm));
    vertical-align: top;
  }

  .comment-form-author,
  .comment-form-url {
    margin-right: var(--space-md);
  }
}

.comment-form .form-submit {
  margin-bottom: 0;
}

/* ========== MOBILE-FIRST RESPONSIVE DESIGN ========== */

/* Large Tablets and Small Desktops */
@media (max-width: 1024px) {
  .hero-title {
    font-size: var(--font-size-5xl);
  }
  
  .services-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-xl);
    padding: 0 var(--space-md);
  }
  
  .content-card {
    padding: var(--space-xl);
  }
}

/* Tablets - Professional Layout */
@media (max-width: 768px) {
  :root {
    --space-4xl: 2rem;
    --section-padding: 1rem;
  }
  
  body {
    font-size: var(--font-size-base);
    margin: 0;
    padding: 0;
    width: 100%;
  }
  
  /* Compact professional header */
  .site-header {
    padding: var(--space-sm) var(--space-xs);
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-sm);
    min-height: 60px;
    width: 100%;
    box-sizing: border-box;
  }
  
  .site-branding h1 {
    font-size: var(--font-size-lg);
    margin: 0;
  }
  
  /* Horizontal navigation on tablets */
  .site-nav ul {
    gap: var(--space-xs);
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  
  .site-nav a {
    padding: var(--space-xs) var(--space-sm);
    font-size: var(--font-size-xs);
  }
  
  .hero-title {
    font-size: var(--font-size-4xl);
    line-height: 1.1;
    margin-bottom: var(--space-md);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-lg);
  }
  
  .hero-section,
  .hero-minimal,
  .hero-services,
  .hero-contact,
  .hero-portfolio,
  .hero-corporate,
  .hero-storefront,
  .hero-magazine,
  .hero-about {
    padding: var(--space-xl) var(--space-sm);
    min-height: 60vh;
    margin-bottom: var(--space-md);
  }
  
  .hero-content {
    padding: 0 var(--space-sm);
    max-width: none;
  }
  
  .content-card {
    padding: var(--space-lg) var(--space-sm);
    margin: 0 0 var(--space-md) 0;
    border-radius: var(--border-radius-sm);
  }
  
  .services-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
    padding: 0 var(--space-sm);
  }
  
  .site-main {
    padding: 0;
    width: 100%;
  }
}

/* Mobile Phones - Professional Full-Screen Layout */
@media (max-width: 640px) {
  :root {
    --space-4xl: 1rem;
    --section-padding: 0;
  }
  
  /* Full-screen mobile setup */
  html, body {
    margin: 0;
    padding: 0;
    width: 100vw;
    overflow-x: hidden;
    font-size: var(--font-size-sm);
    position: relative;
    left: 0;
  }
  
  /* Force all elements to break out of container constraints */
  body * {
    max-width: none !important;
  }
  
  /* Ensure no WordPress theme containers interfere */
  .wp-site-blocks,
  .alignwide,
  .alignfull,
  .wp-block-group,
  .entry-content {
    max-width: 100vw !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  
  /* Ultra-compact professional mobile header */
  .site-header {
    padding: var(--space-sm) var(--space-xs);
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs);
    min-height: auto;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    box-sizing: border-box;
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
    left: 0;
  }
  
  /* Hamburger menu button */
  .hamburger-menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
  }
  
  .hamburger-line {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    margin: 2px 0;
    transition: 0.3s ease;
    border-radius: 3px;
  }
  
  /* Hamburger animation when active */
  .hamburger-menu.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  
  .hamburger-menu.active .hamburger-line:nth-child(2) {
    opacity: 0;
  }
  
  .hamburger-menu.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }
  
  /* Add spacing after sticky header */
  .site-header + * {
    margin-top: var(--space-xl) !important;
    padding-top: var(--space-lg) !important;
  }
  
  .site-branding {
    text-align: center;
    padding: var(--space-sm) 0;
  }
  
  .site-branding h1 {
    font-size: var(--font-size-lg);
    margin: 0;
    font-weight: 600;
  }
  
  /* Mobile navigation - hidden by default */
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-lg);
    z-index: 999;
  }
  
  /* Show navigation when hamburger is active */
  .site-nav.active {
    display: block;
  }
  
  .site-nav ul {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: var(--space-sm);
    margin: 0;
  }
  
  .site-nav li {
    border-bottom: 1px solid var(--gray-100);
  }
  
  .site-nav li:last-child {
    border-bottom: none;
  }
  
  .site-nav a {
    display: block;
    padding: var(--space-md) var(--space-sm);
    font-size: var(--font-size-base);
    text-align: left;
    color: var(--text-primary);
    text-decoration: none;
    transition: background-color 0.2s ease;
    border-radius: 0;
    border: none;
    background: transparent;
    font-weight: 500;
  }
  
  .site-nav a:hover,
  .site-nav a:focus {
    background: var(--gray-50);
    color: var(--accent-color);
  }
  
  .site-nav a:hover,
  .site-nav a:focus {
    background: var(--accent-color);
    color: var(--text-on-accent);
  }
  
  /* Full-viewport hero sections */
  .hero-section,
  .hero-minimal,
  .hero-services,
  .hero-contact,
  .hero-portfolio,
  .hero-corporate,
  .hero-storefront,
  .hero-magazine,
  .hero-about {
    width: 100vw;
    margin: 0;
    margin-left: calc(-50vw + 50%);
    padding: var(--space-2xl) var(--space-sm);
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    position: relative;
    left: 0;
  }
  
  .hero-content {
    width: 100%;
    padding: 0;
    text-align: center;
  }
  
  .hero-title {
    font-size: var(--font-size-4xl);
    line-height: 1.1;
    margin-bottom: var(--space-md);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    padding: 0;
    font-weight: 700;
  }
  
  .hero-subtitle {
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-xl);
    line-height: 1.4;
    padding: 0;
    opacity: 0.95;
  }
  
  /* Full-width professional content sections */
  .site-main {
    width: 100vw;
    margin: 0;
    margin-left: calc(-50vw + 50%);
    padding: 0;
    padding-top: var(--space-2xl);
    box-sizing: border-box;
    position: relative;
    left: 0;
  }
  
  .content-section,
  .services-focus,
  .contact-focus,
  .content-minimal {
    width: 100vw;
    margin: 0;
    margin-left: calc(-50vw + 50%);
    padding: var(--space-lg) 0;
    box-sizing: border-box;
    position: relative;
    left: 0;
  }
  
  /* Full-width content cards */
  .content-card {
    width: 100vw;
    padding: var(--space-xl) var(--space-md) var(--space-xl) var(--space-md);
    margin: 0;
    margin-left: calc(-50vw + 50%);
    border-radius: 0;
    border-left: 4px solid var(--accent-color);
    border-bottom: 1px solid var(--gray-200);
    box-sizing: border-box;
    background: var(--white);
    position: relative;
    left: 0;
    box-shadow: var(--shadow-sm);
  }
  
  .content-card h1,
  .content-card h2 {
    font-size: var(--font-size-2xl);
    line-height: 1.2;
    margin-bottom: var(--space-sm);
  }
  
  .content-card h3 {
    font-size: var(--font-size-xl);
    margin-bottom: var(--space-sm);
  }
  
  .content-card p {
    margin-bottom: var(--space-sm);
    line-height: 1.5;
  }
  
  /* Mobile-optimized buttons */
  .hero-phone-link,
  .hero-email-link {
    padding: var(--space-sm) var(--space-lg);
    font-size: var(--font-size-sm);
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  
  .btn, 
  button[type="submit"], 
  input[type="submit"] {
    padding: var(--space-sm) var(--space-lg);
    font-size: var(--font-size-sm);
    min-height: 48px;
    width: 100%;
    margin-bottom: var(--space-sm);
  }
  
  /* Full-width mobile services grid */
  .services-grid {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .service-card {
    padding: var(--space-lg) var(--space-sm);
    margin: 0 var(--space-xs) var(--space-md) var(--space-xs);
    border-radius: var(--border-radius-lg);
    border-left: 4px solid var(--accent-color);
    border-bottom: 1px solid var(--gray-200);
    width: calc(100% - var(--space-sm));
    box-sizing: border-box;
    background: var(--white);
    box-shadow: var(--shadow-sm);
  }
  
  .service-card h3 {
    font-size: var(--font-size-2xl);
    margin-bottom: var(--space-sm);
    text-align: left;
  }
  
  .service-card p {
    text-align: left;
    line-height: 1.5;
  }
  
  /* Full-width mobile site layout */
  .site-main {
    padding: 0;
    max-width: none;
    margin: 0;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
  }
  
  /* Full-width mobile contact layout */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .contact-info {
    order: 2;
    padding: var(--space-lg) var(--space-sm);
    background: transparent;
    border-radius: 0;
  }
  
  .contact-content {
    order: 1;
    padding: var(--space-lg) var(--space-sm);
    margin-bottom: 0;
    border-bottom: 1px solid var(--gray-200);
  }
  
  .contact-method {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-sm);
    background: var(--gray-50);
    border-radius: var(--border-radius-lg);
    border-left: 4px solid var(--accent-color);
    margin: 0 var(--space-xs) var(--space-xs) var(--space-xs);
    min-height: 60px;
    width: calc(100% - var(--space-sm));
    box-sizing: border-box;
    box-shadow: var(--shadow-sm);
  }
  
  .contact-icon {
    font-size: var(--font-size-lg);
    flex-shrink: 0;
  }
  
  .contact-link {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
    flex: 1;
    padding: var(--space-xs) 0;
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  
  .contact-link:hover,
  .contact-link:focus {
    color: var(--primary-color);
    text-decoration: underline;
  }
  
  .contact-address {
    line-height: 1.4;
  }
  
  /* Full-width mobile CTA */
  .contact-cta {
    text-align: center;
    background: var(--gray-50);
    border-radius: var(--border-radius-lg);
    border-left: 4px solid var(--accent-color);
    padding: var(--space-xl) var(--space-sm);
    margin: var(--space-md) var(--space-xs);
    width: calc(100% - var(--space-sm));
    box-sizing: border-box;
    box-shadow: var(--shadow-sm);
  }
  
  .cta-phone-link,
  .hero-phone-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    margin: var(--space-sm) 0 0;
    padding: var(--space-md) var(--space-lg);
  }
  
  /* Disable animations on mobile for better performance */
  .hero-section::before,
  .hero-minimal::before,
  .hero-services::before,
  .hero-contact::before,
  .hero-portfolio::before,
  .hero-corporate::before,
  .hero-storefront::before,
  .hero-magazine::before,
  .hero-about::before {
    animation: none;
  }
  
  /* Remove transform effects on mobile for better performance */
  .content-card:hover,
  .service-card:hover {
    transform: none;
  }
  
  /* Full-width mobile sections */
  .content-section {
    padding: var(--space-md) 0;
    width: 100%;
    margin: 0;
  }
  
  .services-focus {
    padding: var(--space-md) 0;
    width: 100%;
    margin: 0;
  }
  
  .contact-focus {
    padding: var(--space-md) 0;
    width: 100%;
    margin: 0;
  }
  
  /* Full-width minimal layout */
  .content-minimal {
    padding: var(--space-md) 0;
    width: 100%;
    margin: 0;
  }
  
  .content-card-minimal {
    padding: var(--space-lg) var(--space-sm);
  }
  
  /* Ensure no horizontal scrolling */
  .wp-site-blocks,
  .wp-block-group,
  .entry-content {
    max-width: 100vw;
    overflow-x: hidden;
  }
  
  /* Mobile typography refinements */
  .hero-title {
    font-size: clamp(2rem, 8vw, 3.5rem);
    line-height: 1.1;
  }
  
  .hero-subtitle {
    font-size: clamp(1rem, 4vw, 1.25rem);
  }
  
  /* Professional mobile spacing */
  .content-section > *,
  .services-focus > *,
  .contact-focus > *,
  .content-minimal > * {
    padding-left: var(--space-sm);
    padding-right: var(--space-sm);
  }
  
  /* Remove any remaining margins that create white space */
  .site-main,
  .site-main > *,
  .entry-content,
  .post-content {
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
  }
  
  .content-card-minimal h1,
  .content-card-minimal h2 {
    font-size: var(--font-size-3xl);
    line-height: 1.1;
    margin-bottom: var(--space-md);
  }
  
  /* Mobile typography improvements */
  .services-focus h2,
  .contact-focus h2 {
    font-size: var(--font-size-xl);
    text-align: center;
    margin-bottom: var(--space-lg);
    padding: 0 var(--space-xs);
  }
  
  /* Mobile navigation improvements */
  .site-nav ul {
    padding: 0 var(--space-xs);
  }
  
  .site-nav a {
    display: block;
    text-align: center;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  /* Full-width mobile header */
  .site-header {
    position: sticky;
    top: 0;
    background: var(--white);
    backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid var(--gray-200);
    margin: 0;
    padding: var(--space-sm);
    box-shadow: var(--shadow-sm);
    width: 100%;
    box-sizing: border-box;
  }
  
  /* Ensure navigation links are properly styled on mobile */
  .site-nav a {
    background: var(--gray-50);
    color: var(--text-primary);
    border: 1px solid var(--gray-200);
    margin-bottom: var(--space-xs);
    border-radius: var(--border-radius);
  }
  
  .site-nav a:hover,
  .site-nav a:focus {
    background: var(--gray-100);
    color: var(--primary-color);
    border-color: var(--primary-color);
  }
  
  /* Force full width utilization */
  .hero-content,
  .services-grid,
  .contact-grid,
  .content-section {
    width: 100%;
    box-sizing: border-box;
  }
  
  /* Mobile-optimized spacing for better screen usage */
  body {
    margin: 0;
    padding: 0;
  }
  
  .site-main {
    margin: 0;
    padding: 0;
  }
  
  /* Touch-friendly improvements */
  a, button, .hero-phone-link, .hero-email-link, .contact-link {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  }
  
  /* Mobile scrolling improvements */
  html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Prevent horizontal scroll */
  html, body {
    overflow-x: hidden;
    width: 100%;
  }
}

/* Extra small screens - Maximum space utilization */
@media (max-width: 480px) {
  .hero-title {
    font-size: var(--font-size-2xl);
    padding: 0 var(--space-sm);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-sm);
    padding: 0 var(--space-sm);
  }
  
  .content-card,
  .service-card,
  .content-card-minimal {
    margin: 0;
    padding: var(--space-md) var(--space-sm);
    border-radius: 0;
    width: 100%;
  }
  
  .contact-cta {
    margin: 0;
    padding: var(--space-lg) var(--space-sm);
    width: 100%;
    border-radius: 0;
  }
  
  /* Ultra-compact hero sections for tiny screens */
  .hero-section,
  .hero-minimal,
  .hero-services,
  .hero-contact,
  .hero-portfolio,
  .hero-corporate,
  .hero-storefront,
  .hero-magazine,
  .hero-about {
    padding: var(--space-lg) 0;
    min-height: 60vh;
  }
  
  .hero-content {
    padding: 0 var(--space-sm);
  }
  
  /* Tighter header on smallest screens */
  .site-header {
    padding: var(--space-xs) var(--space-sm);
  }
  
  .site-nav ul {
    gap: var(--space-xs);
  }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .hero-section::before,
  .hero-minimal::before,
  .hero-services::before,
  .hero-contact::before,
  .hero-portfolio::before,
  .hero-corporate::before,
  .hero-storefront::before,
  .hero-magazine::before,
  .hero-about::before {
    animation: none !important;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.75rem;
  }
  
  .entry-header h1, 
  .entry-header h2 {
    font-size: 1.5rem;
  }
  
  .content-card {
    padding: 1rem;
  }
}

/* Accessible Footer Styling */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  text-align: center;
  padding: 3rem 0 2rem 0;
  color: var(--text-primary);
  margin-top: 4rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.footer-content p {
  font-size: 1rem;
  margin-bottom: 2rem;
  font-weight: 400;
}

.footer-content p.footer-credit {
  font-size: 0.85rem;
  margin-top: -1.25rem;
  margin-bottom: 2rem;
  color: var(--text-secondary);
}

.footer-content p.footer-credit a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-content p.footer-credit a:hover {
  color: var(--primary-color);
}

/* Social profile links (Customizer > Page Content): a row of text links. */
.footer-content p.footer-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.5rem;
  margin-bottom: 2rem;
}

.site-footer--columns .footer-social,
.site-footer--contact .footer-social {
  justify-content: flex-start;
}

.footer-social__link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-social__link:hover {
  color: var(--primary-color);
}

.footer-navigation {
  margin-bottom: 2rem;
}

.footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-menu li {
  margin: 0;
}

.footer-menu a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 0.125em;
  font-size: 1rem;
  font-weight: 400;
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius);
  transition: var(--transition);
  display: inline-block;
  min-height: 44px;
  min-width: 44px;
}

.footer-menu a:hover {
  background: var(--gray-100);
  text-decoration-thickness: 2px;
}

.footer-menu a:focus {
  outline: 2px solid var(--text-primary);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Footer workspace panel — logged-in users get the footer links grouped
   (content, shop, account & tools, legal, more) under headed columns
   (inc/footer-workspace.php). Visitors keep the flat .footer-menu row.
   The footer variants in css/chrome/ only adjust where the panel sits. */
.footer-workspace {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 1.5rem 2rem;
  text-align: left;
  margin-bottom: 2rem;
}

.footer-workspace__group {
  min-width: 0;
}

.footer-workspace__title {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 0.5rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--page-rule, var(--gray-200));
  font-family: var(--page-display, var(--font-heading));
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--page-muted, var(--text-secondary));
}

.footer-workspace__title .rtsb-icon {
  font-size: 1rem;
  color: var(--page-accent, var(--accent-color));
}

.footer-workspace .footer-menu {
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0;
}

.footer-workspace .footer-menu li {
  width: 100%;
}

.footer-workspace .footer-menu a {
  display: block;
  width: 100%;
  padding: 0.35rem 0;
  min-height: 0;
  min-width: 0;
  color: inherit;
  text-decoration: none;
  border-radius: 0;
}

.footer-workspace .footer-menu a:hover {
  background: transparent;
  color: var(--page-accent, var(--accent-color));
  text-decoration: underline;
}

@media (max-width: 640px) {
  .footer-workspace {
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem 1.5rem;
  }
}

@media (max-width: 400px) {
  .footer-workspace {
    grid-template-columns: 1fr;
  }
}

/* Footer menu items styled as CTAs (cta-button / cta-primary / cta-secondary
   classes assigned in the WP menu admin) inherit hero-context colors that
   render white-on-white in the light footer. Force readable colors for any
   such link inside .footer-menu. */
.site-footer .footer-menu a,
.site-footer .footer-menu a.cta-button,
.site-footer .footer-menu a.cta-primary,
.site-footer .footer-menu a.cta-secondary,
.site-footer .footer-menu a.cta-button.cta-primary,
.site-footer .footer-menu a.cta-button.cta-secondary {
  color: var(--text-primary) !important;
}

.site-footer .footer-menu a.cta-button,
.site-footer .footer-menu a.cta-primary,
.site-footer .footer-menu a.cta-secondary,
.site-footer .footer-menu a.cta-button.cta-primary,
.site-footer .footer-menu a.cta-button.cta-secondary {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary, #ffffff)) !important;
  border: 1px solid var(--primary-color) !important;
  text-decoration: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  padding: 0.6rem 1.25rem !important;
  min-width: auto !important;
  font-size: 0.95rem;
}

.site-footer .footer-menu a.cta-button:hover,
.site-footer .footer-menu a.cta-primary:hover,
.site-footer .footer-menu a.cta-secondary:hover,
.site-footer .footer-menu a.cta-button.cta-primary:hover,
.site-footer .footer-menu a.cta-button.cta-secondary:hover {
  background: var(--secondary-color, var(--primary-hover)) !important;
  border-color: var(--secondary-color, var(--primary-hover)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary, #ffffff)) !important;
  transform: none !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12) !important;
}

/* Contact page styling */
.contact-page p {
  margin-bottom: 1em;
}
.contact-map {
  margin-top: 1.5em;
}
.contact-map iframe {
  width: 100%;
  height: 300px;
  border: none;
  display: block;
}

/* Contact people (rtsb_theme_contact_people_html): cards with a round picture
   or the initials, one column on phones, more where there is room. Colours are
   palette tokens only; the !important on colour beats the broad dark-mode
   `body span/div/p` overrides at the top of this file. */
.contact-people {
  margin: 2em 0 0;
}

.contact-people .contact-people__heading {
  margin: 0 0 1rem;
  font-size: 1.25rem;
}

.contact-people .contact-people__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact-people .contact-person {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  min-width: 0;
  margin: 0;
  padding: 1rem;
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  background: var(--white);
  list-style: none;
}

.contact-people .contact-person::before,
.contact-people .contact-person::marker {
  content: none;
}

.contact-people .contact-person__photo {
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  max-width: none;
  margin: 0;
  border-radius: 50%;
  object-fit: cover;
}

.contact-people .contact-person__photo--initials {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-color);
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.02em;
}

body .contact-people .contact-person__photo--initials {
  color: var(--text-on-accent) !important;
}

.contact-people .contact-person__body {
  flex: 1 1 auto;
  min-width: 0;
}

body .contact-people .contact-person__name {
  margin: 0;
  font-weight: 600;
  line-height: 1.3;
  overflow-wrap: anywhere;
  color: var(--text-primary) !important;
}

body .contact-people .contact-person__role {
  margin: 0.15rem 0 0;
  font-size: 0.9rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
  color: var(--text-secondary) !important;
}

/* Four classes: the companion-page rule for links on the contact page
   (body[class*="layout-"] .entry-content.contact-page a) underlines the whole
   link, icon included; here only the text carries the line. */
.contact-people .contact-people__list .contact-person a.contact-person__link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  font-size: 0.95rem;
  color: var(--text-primary);
  text-decoration: none;
}

.contact-people .contact-person__role + a.contact-person__link,
.contact-people .contact-person__name + a.contact-person__link {
  margin-top: 0.25rem;
}

.contact-people a.contact-person__link .rtsb-icon {
  color: var(--accent-color);
}

body .contact-people a.contact-person__link .contact-person__link-text {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--text-primary) !important;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.contact-people a.contact-person__link:hover .contact-person__link-text,
.contact-people a.contact-person__link:focus-visible .contact-person__link-text {
  text-decoration-thickness: 2px;
}

.contact-people a.contact-person__link:focus-visible {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
  border-radius: var(--border-radius);
}

/* Address navigation link styling */
.address-navigation-link {
  display: inline-block;
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 0.125em;
  transition: var(--transition);
  font-weight: 500;
  line-height: 1.6;
}

.address-navigation-link:hover {
  color: var(--primary-color);
  text-decoration-thickness: 2px;
}

.address-navigation-link:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Add navigation icon using CSS */
.address-navigation-link::after {
  content: "📍";
  font-size: 0.875em;
  opacity: 0.8;
}

@media (max-width: 768px) {
  .address-navigation-link {
    font-size: 1rem;
    padding: 0.25rem 0;
  }
}

/* Impressum page styling */
.impressum-page p {
  margin-bottom: 1em;
}

.button, .wp-block-button__link {
  background-color: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  padding: 10px 20px;
  border: none;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border-radius: 3px;
}

.button:hover, .wp-block-button__link:hover {
  background-color: var(--secondary-color);
}

/* =============================================================================
   Cookie Consent Banner - Dark Mode
   ============================================================================= */

/* Base Dark Mode for Cookie Banner */
@media (prefers-color-scheme: dark) {
  .bcc-banner {
    background: color-mix(in srgb, var(--gray-100) 96%, transparent);
    border-top: 1px solid var(--gray-300);
  }
  
  .bcc-banner span {
    color: var(--text-secondary);
  }
  
  .bcc-modal {
    background: var(--gray-100);
    color: var(--text-primary);
  }
  
  .bcc-modal h3 {
    color: var(--text-primary);
  }
  
  .bcc-toggle {
    border-bottom: 1px solid var(--gray-300);
  }
  
  .bcc-toggle strong {
    color: var(--text-primary);
  }
  
  .bcc-toggle small {
    color: var(--text-muted);
  }
  
  .bcc-toggle label {
    color: var(--text-secondary);
  }
  
  .bcc-toggle input[type="checkbox"] {
    background: var(--gray-200);
    border-color: var(--gray-300);
  }
  
  .bcc-btn-secondary {
    border-color: var(--gray-300);
    color: var(--text-secondary);
  }
  
  .bcc-btn-secondary:hover {
    background: var(--gray-200);
    color: var(--text-primary);
  }
  
  .bcc-manage-link {
    color: var(--text-muted);
  }
  
  .bcc-manage-link:hover {
    color: var(--text-secondary);
  }
  
  .bcc-backdrop {
    background: rgba(0, 0, 0, 0.8);
  }
}

/* ========== POST TEMPLATES ========== */

/* Single post content wrapper */
.post-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

/* Constrain single product page to match post width */
body.single-product div.product {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.5rem;
  box-sizing: border-box;
}

/* Product page: full-width summary below media showcase */
body.single-product .post-media-showcase {
  margin-bottom: 1.5rem;
}
body.single-product div.product div.summary {
  float: none;
  width: 100%;
  clear: both;
}
body.single-product div.product div.images {
  display: none;
}

/* Product name above the pictures (rtsb_product_page_title) */
body.single-product div.product .rtsb-product-heading {
  font-size: clamp(1.6rem, 5vw, 2.2rem);
  line-height: 1.2;
  margin: 0 0 1rem;
  overflow-wrap: anywhere;
}

/* --- Single Product Summary Styling --- */
body.single-product div.product div.summary .product_title {
  display: none;
}

body.single-product div.product div.summary .price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-color);
  margin-bottom: 1.25rem;
  display: block;
}

body.single-product div.product div.summary .price del {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 1.1rem;
  margin-right: 0.5rem;
}

body.single-product div.product div.summary .price ins {
  text-decoration: none;
}

body.single-product div.product div.summary .woocommerce-product-details__short-description {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

body.single-product div.product div.summary .woocommerce-product-rating {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Add to cart form */
body.single-product div.product div.summary form.cart {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.5rem 0;
  padding: 1.5rem 0;
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
}

/* Subscription products: stack form vertically when billing toggle / domain field present */
body.single-product div.product div.summary form.cart:has(.wm-billing-toggle),
body.single-product div.product div.summary form.cart:has(.wm-uid-field) {
  flex-direction: column;
  align-items: stretch;
  text-align: center;
}

body.single-product div.product div.summary form.cart:has(.wm-billing-toggle) .quantity,
body.single-product div.product div.summary form.cart:has(.wm-uid-field) .quantity {
  align-self: center;
}

body.single-product div.product div.summary form.cart:has(.wm-billing-toggle) .single_add_to_cart_button,
body.single-product div.product div.summary form.cart:has(.wm-uid-field) .single_add_to_cart_button {
  align-self: center;
}

/* Woo-Merchants UID/domain field: plugin CSS uses --form-bg/--input-bg/
   --form-text/--input-color/--border-color which aren't defined on
   product pages, causing the select to fall back to white bg with
   inherited light text (invisible in dark mode). Bridge the vars. */
.wm-uid-field,
.wm-billing-toggle {
  --form-bg: var(--white);
  --input-bg: var(--white);
  --form-text: var(--text-primary);
  --input-color: var(--text-primary);
  --text-color: var(--text-primary);
  --border-color: var(--gray-300);
}

/* WooCommerce sort-order dropdown: the native select otherwise inherits the light
   page text on a white box in dark mode (invisible). Keep it a light control with
   dark text, like the theme's other form inputs. */
.woocommerce-ordering select.orderby {
  background-color: var(--white, #ffffff) !important;
  color: var(--text-primary, #1a1a1a) !important;
  border: 1px solid var(--gray-300, #d0d0d0) !important;
  border-radius: var(--border-radius, 8px);
  padding: 10px 14px;
}
.woocommerce-ordering select.orderby option {
  background-color: var(--white, #ffffff);
  color: var(--text-primary, #1a1a1a);
}

/* Variable-product variation dropdown ("Größe", "Teilnehmer", …): same
   invisible-control trap as the sort dropdown above. The bare dark-mode
   `select { color: var(--text-primary) }` rule flips the text light while
   the select's background loses to a transparent rule — on a client whose
   surfaces stay light that yields white text on a white card, and the
   customer sees no dropdown at all even though it is in the DOM (reported
   on juliagiulina). Pin it to a light control with dark text in every
   mode, matching the ordering dropdown. Literals, not tokens: the tokens
   are exactly what breaks in the mismatched client state. */
.woocommerce div.product form.cart .variations select {
  background-color: #ffffff !important;
  color: #1a1a1a !important;
  -webkit-text-fill-color: #1a1a1a !important;
  border: 1px solid var(--gray-300, #d0d0d0) !important;
  border-radius: var(--border-radius, 8px);
  padding: 10px 14px;
}
.woocommerce div.product form.cart .variations select option {
  background: #ffffff !important;
  color: #1a1a1a !important;
}
/* The row label sits on the card surface, so it follows the page tokens —
   with a hard fallback for clients that resolve none. */
.woocommerce div.product form.cart table.variations th.label,
.woocommerce div.product form.cart table.variations td.label,
.woocommerce div.product form.cart table.variations th.label label {
  color: var(--text-color, var(--text-primary, #1a1a1a));
}
.woocommerce div.product form.cart .reset_variations {
  color: var(--link-color, #941c2f) !important;
}

body.single-product div.product div.summary form.cart .quantity {
  display: flex;
  align-items: center;
}

body.single-product div.product div.summary form.cart .quantity .qty,
body.single-product .quantity .qty,
.woocommerce .quantity .qty {
  width: 70px;
  padding: 0.625rem 0.5rem;
  border: 1px solid var(--gray-300);
  border-radius: var(--border-radius);
  text-align: center;
  font-size: 1rem;
  background: var(--gray-100) !important;
  color: var(--text-primary) !important;
}

body.single-product div.product div.summary form.cart .single_add_to_cart_button {
  background: var(--accent-color);
  color: var(--text-on-accent);
  border: none;
  padding: 0.75rem 2rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  /* WooCommerce sets overflow: visible on .button; without the clip the
     hover sweep lies over the quantity field to the left. */
  overflow: hidden;
}

body.single-product div.product div.summary form.cart .single_add_to_cart_button:hover {
  background: var(--primary-fill, var(--primary-color));
  transform: translateY(-1px);
}

/* Reassurance lines under the order button (inc/product-page.php) */
body.single-product div.product .rtsb-product-assurance {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
  display: grid;
  gap: 0.35rem;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

body.single-product div.product .rtsb-product-assurance li {
  position: relative;
  margin: 0;
  padding-left: 1.5rem;
}

body.single-product div.product .rtsb-product-assurance li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  font-weight: 700;
  color: var(--accent-color);
}

/* Help line directly after the order button (inc/product-page.php). It takes
   a row of its own in every form: beside quantity and button, in the stacked
   subscription form and in the options form. The colours carry !important
   because the dark-mode overrides at the top of this file repaint every p. */
body.single-product div.product div.summary form.cart:has(.rtsb-product-help) {
  flex-wrap: wrap;
}

/* On phones every submit button is 100% wide and used to shrink beside the
   quantity. With the wrap it would take a row of its own: keep it beside. */
@media (max-width: 640px) {
  body.single-product div.product div.summary form.cart:has(> .rtsb-product-help):not(:has(.wm-billing-toggle, .wm-uid-field)) > .single_add_to_cart_button {
    flex: 1 1 0;
  }
}

body.single-product div.product form.cart .rtsb-product-help {
  flex: none;
  width: 100%;
  margin: 0;
  /* the root size is smaller on phones: never below 14px */
  font-size: max(0.95rem, 14px);
  line-height: 1.5;
  color: var(--text-secondary) !important;
  overflow-wrap: anywhere;
}

body.single-product div.product form.cart .rtsb-product-help a.rtsb-product-help__link {
  color: var(--accent-color) !important;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

body.single-product div.product form.cart .rtsb-product-help a.rtsb-product-help__link:hover,
body.single-product div.product form.cart .rtsb-product-help a.rtsb-product-help__link:focus-visible {
  color: var(--text-primary) !important;
}

/* The header is sticky: a jump to the order form must not land under it. */
body.single-product .rtsb-order-anchor {
  display: block;
  scroll-margin-top: 6rem;
}

/* Closing block after the description: price, button, how to ask */
body.single-product div.product .rtsb-product-closing {
  clear: both;
  margin: 2.5rem 0;
  padding: 1.5rem;
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  background: var(--gray-50);
  text-align: center;
}

body.single-product div.product .rtsb-product-closing p {
  margin: 0;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__name {
  font-weight: 600;
  font-size: 1.15rem;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__price {
  margin-top: 0.25rem;
  font-size: 1.05rem;
}

body.single-product div.product .rtsb-product-closing a.rtsb-product-closing__button {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.75rem 2rem;
  border-radius: var(--border-radius);
  background: var(--accent-color);
  color: var(--text-on-accent) !important;
  font-weight: 600;
  text-decoration: none;
}

body.single-product div.product .rtsb-product-closing a.rtsb-product-closing__button:hover,
body.single-product div.product .rtsb-product-closing a.rtsb-product-closing__button:focus-visible {
  background: var(--primary-fill, var(--primary-color));
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__contact {
  margin-top: 1rem;
  font-size: 0.95rem;
  overflow-wrap: anywhere;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__contact:first-child {
  margin-top: 0;
}

/* Buy bar: name, price and button while the order form is out of view
   (js/product-buy-bar.js). Sits below the header (1000) and above the page;
   the floating buttons dock above it through --rtsb-dock. */
.rtsb-buy-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 0.6rem clamp(1rem, 4vw, 2rem);
  padding-bottom: calc(0.6rem + env(safe-area-inset-bottom, 0px));
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  box-shadow: 0 -8px 30px -18px rgba(0, 0, 0, 0.45);
}

.rtsb-buy-bar[hidden] {
  display: none;
}

.rtsb-buy-bar.is-visible {
  animation: rtsb-buy-bar-in 220ms ease-out;
}

@keyframes rtsb-buy-bar-in {
  from { transform: translateY(100%); }
  to { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .rtsb-buy-bar.is-visible {
    animation: none;
  }
}

.rtsb-buy-bar .rtsb-buy-bar__text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.rtsb-buy-bar .rtsb-buy-bar__name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--text-primary);
}

.rtsb-buy-bar .rtsb-buy-bar__price {
  font-size: 0.9rem;
}

.rtsb-buy-bar .rtsb-buy-bar__button {
  flex: 0 0 auto;
  padding: 0.7rem 1.25rem;
  border: 0;
  border-radius: var(--border-radius);
  background: var(--accent-color);
  color: var(--text-on-accent);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.rtsb-buy-bar .rtsb-buy-bar__button:hover,
.rtsb-buy-bar .rtsb-buy-bar__button:focus-visible {
  background: var(--primary-fill, var(--primary-color));
}

body:has(.rtsb-buy-bar.is-visible) {
  --rtsb-dock: var(--rtsb-buy-bar-h, 64px);
  padding-bottom: var(--rtsb-buy-bar-h, 64px);
}

/* Line under the price: price per kilogram and the owner's own note */
body.single-product div.product .rtsb-product-price-note {
  margin: -0.5rem 0 1rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* A subscription tied to a domain is ordered once: no quantity box */
body.single-product div.product div.summary form.cart:has(.wm-uid-field) .quantity {
  display: none;
}

/* Options as buttons (js/product-options.js). The list stays in the form for
   WooCommerce and screen readers, the buttons are what a thumb hits. */
body.single-product div.product form.variations_form .rtsb-options__select {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

body.single-product div.product form.variations_form table.variations,
body.single-product div.product form.variations_form table.variations tbody,
body.single-product div.product form.variations_form table.variations tr,
body.single-product div.product form.variations_form table.variations th,
body.single-product div.product form.variations_form table.variations td {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  text-align: left;
}

body.single-product div.product form.variations_form table.variations th {
  margin-bottom: 0.4rem;
  font-weight: 600;
}

body.single-product div.product form.variations_form table.variations tr {
  margin-bottom: 1rem;
}

body.single-product div.product form.variations_form,
body.single-product div.product form.variations_form .single_variation_wrap {
  flex-direction: column;
  align-items: stretch;
}

body.single-product div.product form.variations_form .woocommerce-variation-add-to-cart {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}

.rtsb-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.rtsb-options .rtsb-options__button {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  min-height: 44px;
  padding: 0.5rem 0.9rem;
  border: 2px solid var(--gray-300);
  border-radius: var(--border-radius);
  background: var(--white);
  color: var(--text-primary);
  font: inherit;
  line-height: 1.25;
  text-align: left;
  cursor: pointer;
}

.rtsb-options .rtsb-options__button .rtsb-options__name {
  font-weight: 600;
}

.rtsb-options .rtsb-options__button .rtsb-options__price {
  font-size: 0.85rem;
}

.rtsb-options .rtsb-options__button.is-active {
  border-color: var(--accent-color);
  box-shadow: inset 0 0 0 1px var(--accent-color);
}

.rtsb-options .rtsb-options__button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  text-decoration: line-through;
}

.rtsb-options .rtsb-options__button:focus-visible {
  outline: 3px solid var(--focus-color, var(--accent-color));
  outline-offset: 2px;
}

/* Description, further details and questions as stacked sections, not tabs */
body.single-product div.product .rtsb-product-sections {
  clear: both;
  padding-top: 2rem;
}

body.single-product div.product .rtsb-product-section + .rtsb-product-section {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--gray-200);
}

body.single-product div.product .rtsb-product-faq__item {
  border-bottom: 1px solid var(--gray-200);
}

body.single-product div.product .rtsb-product-faq__q {
  position: relative;
  padding: 0.9rem 2rem 0.9rem 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

body.single-product div.product .rtsb-product-faq__q::-webkit-details-marker {
  display: none;
}

body.single-product div.product .rtsb-product-faq__q::after {
  content: "+";
  position: absolute;
  right: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3rem;
  font-weight: 400;
}

body.single-product div.product .rtsb-product-faq__item[open] .rtsb-product-faq__q::after {
  content: "\2212";
}

body.single-product div.product .rtsb-product-faq__q:focus-visible {
  outline: 3px solid var(--focus-color, var(--accent-color));
  outline-offset: 2px;
}

body.single-product div.product .rtsb-product-faq__a {
  padding: 0 0 1rem;
}

body.single-product div.product .rtsb-product-faq__a > :last-child {
  margin-bottom: 0;
}

/* A face and a name beside the contact line of the closing block */
body.single-product div.product .rtsb-product-closing .rtsb-product-closing__person {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 1.25rem;
  text-align: left;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__person:first-child {
  margin-top: 0;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__photo {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__person .rtsb-product-closing__contact {
  margin-top: 0;
}

body.single-product div.product .rtsb-product-closing .rtsb-product-closing__person-name {
  display: block;
}

/* Product meta (SKU, categories, tags) */
body.single-product div.product div.summary .product_meta {
  margin-top: 1.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 2;
}

body.single-product div.product div.summary .product_meta > span {
  display: block;
}

body.single-product div.product div.summary .product_meta a {
  color: var(--accent-color);
  text-decoration: none;
  transition: var(--transition);
}

body.single-product div.product div.summary .product_meta a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

/* ========== PRODUCT ARCHIVE GRID & CARDS ========== */

/* Product grid layout — matches .post-list breakpoints */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: 1fr;
  grid-auto-rows: 1fr;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

@media (min-width: 768px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1200px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Remove WooCommerce clearfix pseudo-elements — they become grid items */
.woocommerce ul.products::before,
.woocommerce ul.products::after {
  display: none !important;
  content: none !important;
}

/* Override WooCommerce inline/default widths on product list items */
.woocommerce ul.products li.product {
  width: auto !important;
  float: none !important;
  margin: 0 !important;
}

/* Product card — matches .post-list > article */
.rtsb-product-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: var(--transition);
  height: 100%;
}

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

/* Product link — fills the card above the action area */
.rtsb-product-link {
  display: flex;
  flex-direction: column;
  flex: 1;
  text-decoration: none;
  color: inherit;
}

.rtsb-product-link:hover,
.rtsb-product-link:focus {
  text-decoration: none;
  color: inherit;
}

/* Product image area */
.rtsb-product-image {
  width: 100%;
  height: 220px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--gray-50) 0%, var(--gray-200) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Missing image placeholder icon */
.rtsb-product-image:empty::before {
  content: "\1F6D2";
  font-size: 3rem;
  opacity: 0.25;
}

.rtsb-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Product title — reserve 2 lines */
.rtsb-product-title {
  padding: 0.75rem 1rem 0;
  margin: 0;
  font-size: var(--font-size-lg);
  font-weight: 700;
  line-height: 1.4;
  min-height: 2.8em;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
  word-break: break-word;
}

.rtsb-product-link:hover .rtsb-product-title {
  color: var(--accent-color);
}

/* Product price */
.rtsb-product-price {
  display: block;
  padding: 0 1rem 0.5rem;
  font-weight: 600;
  font-size: var(--font-size-base);
  color: var(--accent-color);
}

/* Product excerpt — reserve 4 lines */
.rtsb-product-excerpt {
  padding: 0.75rem 1rem 0;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  line-height: 1.5;
  min-height: 6em;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
}

/* Add to cart action area — pushed to bottom */
.rtsb-product-action {
  margin-top: auto;
  padding: 0 1rem 1rem;
  text-align: center;
}

.rtsb-product-action .button,
.rtsb-product-action a.button {
  display: inline-block;
  width: 100%;
  background: var(--accent-color);
  color: var(--text-on-accent);
  padding: 0.5rem 1rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: var(--font-size-sm);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  text-align: center;
  box-sizing: border-box;
}

.rtsb-product-action .button:hover,
.rtsb-product-action a.button:hover {
  background: var(--primary-fill, var(--primary-color));
  transform: translateY(-1px);
}

/* Coming-soon ("Demnächst verfügbar") reuses the button look but is a
   non-clickable <span>, so it misses the a.button rule above and inherits the
   card's light text (unreadable on the accent bg). Give it the same accent
   background + dark text, slightly muted to read as disabled. */
.rtsb-product-action .wf-coming-soon-label,
.wf-coming-soon-label.button {
  display: inline-block;
  width: 100%;
  box-sizing: border-box;
  padding: 0.5rem 1rem;
  border: none;
  border-radius: var(--border-radius, 8px);
  background: var(--accent-color, #e6a9bf);
  color: var(--text-on-accent, #141318) !important;
  font-weight: 600;
  font-size: var(--font-size-sm);
  text-align: center;
  cursor: default;
  opacity: 0.85;
}

/* Focus styles for accessibility */
.rtsb-product-link:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
  border-radius: var(--border-radius);
}

.rtsb-product-action .button:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

/* Responsive: smaller image on mobile */
@media (max-width: 600px) {
  .rtsb-product-image {
    height: 180px;
  }
}

/* Phones: name, what it is and what it costs come before the pictures, so the
   first screen answers the three questions of someone who just arrived. The
   summary dissolves into the product column and its two lines move up; the
   order form stays below the pictures. */
@media (max-width: 600px) {
  body.single-product div.product {
    display: flex;
    flex-direction: column;
  }
  body.single-product div.product div.summary {
    display: contents;
  }
  body.single-product div.product .rtsb-product-heading {
    order: -3;
    margin-bottom: 0.5rem;
  }
  body.single-product div.product div.summary .woocommerce-product-details__short-description {
    order: -2;
    margin: 0 0 0.5rem;
    padding: 0;
    border: 0;
  }
  body.single-product div.product div.summary .woocommerce-product-details__short-description > :last-child {
    margin-bottom: 0;
  }
  body.single-product div.product div.summary .price {
    order: -1;
    margin: 0 0 1rem;
  }
  body.single-product div.product div.summary .rtsb-product-price-note {
    order: -1;
    margin: -0.75rem 0 1rem;
  }
  body.single-product div.product .wf-action-bar {
    margin-bottom: 0.75rem;
  }
  body.single-product .woocommerce-breadcrumb {
    margin-bottom: 0.75rem;
  }
}

body.single-product div.product .woocommerce-tabs {
  clear: both;
  padding-top: 2rem;
}

/* Woo-Merchants dashboard — adapt to theme colors */
.wm-dashboard-tile {
  background-color: var(--white) !important;
  color: var(--text-primary);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
}

.wm-dashboard-tile h3 {
  color: var(--text-primary);
}

.wm-tile-merchant-active {
  background-color: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-accent);
}

.wm-tile-merchant-active h3 {
  color: var(--text-on-accent);
}

/* Woo-Merchants registration form steps */
.wm-merchant-registration .wf-form-nav li,
.wf-form-nav li {
  background-color: var(--gray-200);
  color: var(--text-primary);
}

.wm-merchant-registration .wf-form-nav li.active,
.wf-form-nav li.active {
  background-color: var(--accent-color);
  color: var(--text-on-accent);
}

/* Woo-Merchants form inputs */
.wm-merchant-dashboard-content input,
.wm-merchant-dashboard-content select,
.wm-merchant-dashboard-content textarea {
  background-color: var(--gray-50);
  color: var(--text-primary);
  border: 1px solid var(--gray-300);
  border-radius: var(--border-radius);
}

.wm-merchant-dashboard-content table {
  color: var(--text-primary);
}

/* Product-edit overview controls (e.g. "Meine Produkte" selector).
   forms.css ships a literal `white` background that stays white in dark mode;
   re-style with theme vars so the dropdown is readable in both schemes. */
.wf_edit_products_overview select,
.wf_edit_products_overview input[type="text"],
.wf-product-edit-popup select,
.wf-product-edit-popup input[type="text"] {
  background-color: var(--white);
  color: var(--text-primary);
  border: 1px solid var(--gray-300);
  border-radius: var(--border-radius);
}

.wf_edit_products_overview select option,
.wf-product-edit-popup select option {
  background-color: var(--white);
  color: var(--text-primary);
}

.wf_edit_products_overview select:focus,
.wf-product-edit-popup select:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: var(--focus-ring);
}

/* Woo-Merchants buttons */
.wm-merchant-dashboard-content button,
.wm-merchant-dashboard-content .button {
  background: var(--accent-color);
  color: var(--text-on-accent);
  border: none;
  border-radius: var(--border-radius);
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: var(--transition);
}

.wm-merchant-dashboard-content button:hover,
.wm-merchant-dashboard-content .button:hover {
  background: var(--primary-fill, var(--primary-color));
}

/* Woo-Merchants Stripe Connect notice */
.wm-stripe-notice {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px;
  margin: 10px 0;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  background: var(--bg-secondary);
}

.wm-stripe-notice-logo {
  flex-shrink: 0;
}

.wm-stripe-notice-text {
  color: var(--text-primary);
}

.wm-stripe-notice-text span {
  color: var(--text-secondary);
}

/* Woo-Merchants filter/order containers */
.wm-payouts,
.wm-merchant-orders,
.wm-shipping-classes,
.wm-warehouses {
  color: var(--text-primary);
}

.wm-dashboard-row {
  gap: 0.5rem;
}

/* Woo-Merchants assign shipping/warehouse tables — prevent select/label overlap */
.wm-assign-shipping-class-table,
.wm-assign-warehouse-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0.5rem 0.25rem;
}

.wm-assign-shipping-class-table th,
.wm-assign-warehouse-table th {
  width: 50%;
  padding-right: 1rem;
  font-weight: 600;
  white-space: normal;
  overflow-wrap: anywhere;
}

.wm-assign-shipping-class-table td,
.wm-assign-warehouse-table td {
  width: 50%;
}

/* Override plugin's `position: relative; right: 25px` which causes overlap */
.wm-assign-shipping-class-table select,
.wm-assign-warehouse-table select {
  position: static;
  right: auto;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* Woo-Merchants new shipping class popup — fix cell bg/text contrast.
   Plugin CSS uses `var(--another-shade, var(--bg-color, white))` and
   `var(--text-color, inherit)` on table cells, but these vars aren't
   defined in this scope, so cells fall back to white bg while inheriting
   light `--text-primary` from the popup wrapper. Bridge the variables. */
.wm-merchant-dashboard-content,
.wm-new-shipping-class-popup,
.wm-shipping-classes-popup,
[class*="popup-wm-new-shipping"] {
  --another-shade: var(--gray-50);
  --bg-color: var(--white);
  --text-color: var(--text-primary);
  --input-bg: var(--white);
  --input-color: var(--text-primary);
  --border-color: var(--gray-300);
}

/* Ensure all inputs inside the new-shipping-class form have readable
   contrast and consistent styling (name field + numeric entry rows) */
.wm-shipping-class-table input[type="text"],
.wm-shipping-class-table input[type="number"] {
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.5rem 0.75rem !important;
  box-sizing: border-box;
}

/* Plugin removes the border on the first-row Name input — restore it */
.wm-shipping-class-table tr:first-child input[type="text"] {
  border: 1px solid var(--gray-300) !important;
}

/* "Add Line" action label — make it visible as a link-style action */
.wm-shipping-class-table .wm-class-add-line {
  color: var(--accent-color);
  font-weight: 600;
  text-decoration: underline;
}

.wm-shipping-class-table .wm-class-add-line:hover {
  color: var(--primary-color);
}

/* Trash icon for delete row — ensure visible on themed background */
.wm-shipping-class-table .wm-shipping-delete .dashicons {
  color: var(--error-color);
}

/* Woo-Merchants Invoice Management */
.wm-invoice-management {
  color: var(--text-primary);
}

.wm-invoice-toggle-section {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.wm-toggle-label {
  color: var(--text-primary);
}

.wm-toggle-slider {
  background-color: var(--gray-300) !important;
}

input:checked + .wm-toggle-slider {
  background-color: var(--accent-color) !important;
}

.wm-invoice-settings label {
  color: var(--text-primary);
  font-weight: 600;
}

.wm-invoice-settings input[type="text"],
.wm-invoice-settings textarea {
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.5rem 0.75rem !important;
  box-sizing: border-box;
}

.wm-invoice-field-desc {
  color: var(--text-secondary) !important;
  font-size: var(--font-size-xs);
}

.wm-invoice-notice-info {
  background-color: rgba(var(--accent-color-rgb, 33,150,243), 0.08) !important;
  border-color: rgba(var(--accent-color-rgb, 33,150,243), 0.25) !important;
  color: var(--text-primary) !important;
}

.wm-invoice-list h4 {
  color: var(--text-primary);
}

.wm-invoice-table {
  border-collapse: collapse;
  width: 100%;
}

.wm-invoice-table th {
  background-color: var(--gray-100) !important;
  color: var(--text-primary) !important;
  border-color: var(--gray-200) !important;
  font-weight: 600;
}

.wm-invoice-table td {
  color: var(--text-primary) !important;
  border-color: var(--gray-200) !important;
}

.wm-invoice-table tr:nth-child(even) td {
  background-color: var(--gray-50);
}

.wm-invoice-table .button {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.35rem 0.75rem !important;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.wm-invoice-table .button:hover {
  opacity: 0.85;
}

.wm-invoice-bulk-operations {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.4rem 1rem !important;
  font-weight: 600;
  transition: var(--transition);
}

.wm-invoice-bulk-operations:hover {
  opacity: 0.85;
}

.wm-invoice-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.wm-bulk-download-controls select {
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.35rem 0.5rem;
}

.wm-bulk-download-controls select option {
  background-color: var(--white);
  color: var(--text-primary);
}

.wm-bulk-download-btn {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  border-radius: var(--border-radius-sm) !important;
  padding: 0.4rem 1rem !important;
  font-weight: 600;
  transition: var(--transition);
}

.wm-bulk-download-btn:hover {
  opacity: 0.85;
}

.invoice-status {
  font-weight: 600;
  border-radius: var(--border-radius-sm) !important;
}

.invoice-status-draft {
  background-color: rgba(255, 193, 7, 0.15) !important;
  color: #ffc107 !important;
}

.invoice-status-sent {
  background-color: rgba(40, 167, 69, 0.15) !important;
  color: #66bb6a !important;
}

.invoice-status-paid {
  background-color: rgba(0, 188, 212, 0.15) !important;
  color: #4dd0e1 !important;
}

/* Post articles styling */
.post-list > article,
.post-content > article {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius);
  margin-bottom: 0;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Single post content keeps margin for spacing */
.post-content > article {
  margin-bottom: 2rem;
}

.post-list > article:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

/* Entry title styling */
.entry-title {
  margin: 0 0 1rem 0;
  font-weight: 700;
  line-height: 1.2;
}

.entry-title a {
  color: var(--text-primary);
  text-decoration: none;
  transition: var(--transition);
}

.entry-title a:hover {
  color: var(--accent-color);
}

/* Clickable card styling */
.clickable-card {
  cursor: pointer;
  position: relative;
}

.card-link {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.card-link:hover,
.card-link:focus {
  text-decoration: none;
  color: inherit;
}

/* Remove default link styles inside card */
.card-link .entry-title {
  color: var(--text-primary);
  font-size: 1.25rem;
  line-height: 1.3;
  min-height: 2.6em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
  word-break: break-word;
}

.card-link:hover .entry-title {
  color: var(--accent-color);
}

/* Read more link styling - now as span inside clickable card */
.clickable-card .read-more-link {
  display: inline-block;
  background: var(--accent-color);
  color: var(--text-on-accent);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 0.875rem;
  margin-top: 1rem;
  transition: var(--transition);
}

/* Hover effect for entire card */
.clickable-card:hover .read-more-link {
  background: var(--primary-fill, var(--primary-color));
  transform: translateY(-1px);
}

/* Focus styles for accessibility */
.card-link:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
  border-radius: var(--border-radius);
}

/* Excerpt content spacing */
.excerpt-content {
  margin: 1rem 0;
}

/* Fix layout for cards without featured images */
.clickable-card .card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  flex: 1;
}

.clickable-card .entry-header {
  flex-shrink: 0;
}

.clickable-card .entry-meta {
  flex-shrink: 0;
  margin-bottom: 1rem;
}

.clickable-card .post-thumbnail {
  flex-shrink: 0;
  margin-bottom: 1rem;
}

.clickable-card .post-thumbnail img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--border-radius);
}

.clickable-card .post-thumbnail-placeholder {
  width: 100%;
  height: 220px;
  background: linear-gradient(135deg, var(--gray-100) 0%, var(--gray-200) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius);
}

.clickable-card .post-thumbnail-placeholder::before {
  content: "\1F4F7";
  font-size: 3rem;
  opacity: 0.3;
}

.clickable-card .excerpt-content {
  flex-grow: 1;
  margin: 0 0 1rem 0;
  font-size: 0.9rem;
  line-height: 1.5;
  min-height: 6em;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
}

.clickable-card .excerpt-content p {
  margin: 0;
  display: inline;
}

.clickable-card .read-more-link {
  margin-top: auto;
  align-self: stretch;
  text-align: center;
  width: 100%;
  box-sizing: border-box;
}

/* Entry meta styling */
.entry-meta {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.entry-meta .author,
.entry-meta .categories {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.entry-meta a {
  color: var(--accent-color);
  text-decoration: none;
  transition: var(--transition);
}

.entry-meta a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

/* Entry content styling */
.entry-content {
  line-height: 1.7;
  font-size: 1.1rem;
}

.entry-content p {
  margin-bottom: 1.5rem;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-primary);
}

.entry-content h1 { font-size: 2.5rem; }
.entry-content h2 { font-size: 2rem; }
.entry-content h3 { font-size: 1.5rem; }
.entry-content h4 { font-size: 1.25rem; }
.entry-content h5 { font-size: 1.125rem; }
.entry-content h6 { font-size: 1rem; }

.entry-content ul,
.entry-content ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.entry-content li {
  margin-bottom: 0.5rem;
}

.entry-content blockquote {
  border-left: 4px solid var(--accent-color);
  margin: 1.5rem 0;
  padding: 1rem 1.5rem;
  background: var(--gray-50);
  color: var(--text-muted);
  font-style: italic;
}

.entry-content code {
  background: var(--gray-100);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
}

.entry-content pre {
  background: var(--gray-100);
  padding: 1rem;
  border-radius: var(--border-radius);
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.entry-content pre code {
  background: none;
  padding: 0;
}

/* Entry footer styling */
.entry-footer {
  border-top: 1px solid var(--gray-200);
  padding-top: 1.5rem;
  margin-top: 2rem;
}

.entry-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.entry-tags .tags-title {
  font-weight: 600;
  color: var(--text-muted);
  margin-right: 0.5rem;
}

.entry-tags a {
  background: var(--gray-100);
  color: var(--text-secondary);
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  text-decoration: none;
  font-size: 0.875rem;
  transition: var(--transition);
}

.entry-tags a:hover {
  background: var(--accent-color);
  color: var(--text-on-accent);
}

/* Page links for paginated content */
.page-links {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--gray-200);
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.page-links a {
  background: var(--accent-color);
  color: var(--text-on-accent);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  transition: var(--transition);
}

.page-links a:hover {
  background: var(--primary-fill, var(--primary-color));
}

/* Responsive design for posts */
@media (max-width: 768px) {
  .post-content {
    padding: 1rem;
  }
  
  .post-list > article,
  .post-content > article {
    padding: 1.5rem;
  }
  
  .entry-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .entry-content {
    font-size: 1rem;
  }
  
  .entry-content h1 { font-size: 2rem; }
  .entry-content h2 { font-size: 1.75rem; }
  .entry-content h3 { font-size: 1.5rem; }
}

/* Continue reading link styling */
.entry-content a[href*="continue-reading"] {
  display: inline-block;
  background: var(--accent-color);
  color: var(--text-on-accent);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 600;
  margin-top: 1rem;
  transition: var(--transition);
}

.entry-content a[href*="continue-reading"]:hover {
  background: var(--primary-fill, var(--primary-color));
  transform: translateY(-1px);
}

/* ========== IMAGE GALLERY STYLING ========== */

/* Post image gallery */
.post-image-gallery {
  margin: 2rem 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  justify-items: center;
}

.post-image-item {
  margin: 0;
  background: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.post-image-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.post-image-item a {
  display: block;
  text-decoration: none;
  border: none;
  outline: none;
}

.post-image-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  transition: var(--transition);
}

.post-image-item:hover img {
  transform: scale(1.05);
}

.post-image-item figcaption {
  padding: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
  background: var(--gray-50);
}

/* Single image in gallery */
.post-image-gallery .post-image-item:only-child {
  max-width: 600px;
  width: 100%;
  grid-column: 1 / -1;
}

.post-image-gallery .post-image-item:only-child img {
  height: auto;
  max-height: 400px;
  object-fit: contain;
}

/* ========== MEDIA SHOWCASE ========== */

.post-media-showcase {
  margin: 0 0 2rem 0;
}

.post-media-main {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--border-radius);
}

/* Sale badge, pinned to the showcase image. WooCommerce's default absolute
   position resolved against div.product and landed on the Share/Edit action
   bar above the gallery. */
.post-media-main span.onsale {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  min-height: 0;
  min-width: 0;
  margin: 0;
  padding: 6px 14px;
  border-radius: 999px;
  line-height: 1.4;
  font-weight: 600;
  background: var(--accent-color, #941c2f);
  color: var(--text-on-accent, #ffffff);
}

.post-media-main-item {
  display: none;
}

.post-media-main-item.active {
  display: block;
}

.post-media-main-item img {
  width: 100%;
  height: auto;
  display: block;
}

/* A tall picture (a phone screenshot, a portrait photo) must not take more
   than the screen: it is shown whole inside the frame, and a tap opens it
   large (js/lightbox.js). */
.post-media-main-item > img {
  max-height: min(65vh, 640px);
  object-fit: contain;
  background: var(--gray-100);
  cursor: zoom-in;
}

.post-media-main-item > img:focus-visible {
  outline: 3px solid var(--focus-color, var(--accent-color));
  outline-offset: -3px;
}

.post-media-main-item video {
  width: 100%;
  max-height: min(65vh, 500px);
  display: block;
}

/* A showcase with several pictures or videos keeps ONE height: the stage has
   a fixed shape and every item is shown whole inside it. Without this the
   page below jumped with every slide of the slideshow, because a portrait
   video, a square picture and a wide screenshot are all of different height. */
.post-media-main:has(.post-media-main-item + .post-media-main-item) {
  aspect-ratio: 16 / 10;
  max-height: min(65vh, 640px);
  background: var(--gray-100);
}

.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item.active {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item > img,
.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item video {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  background: none;
}

/* A video sits in a figure (wp-block-video): the figure takes the stage's
   size, or the video inside keeps its own height and is cut off below. */
.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item > figure,
.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item > .wp-video {
  width: 100%;
  height: 100%;
  margin: 0;
}

.post-media-main:has(.post-media-main-item + .post-media-main-item) .post-media-main-item audio {
  width: min(100% - 2rem, 32rem);
}

@media (max-width: 768px) {
  .post-media-main:has(.post-media-main-item + .post-media-main-item) {
    aspect-ratio: 1 / 1;
    max-height: 70vh;
  }
}

.post-media-thumbnails {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin;
  scrollbar-color: var(--gray-300) transparent;
}
.post-media-thumbnails::-webkit-scrollbar {
  height: 8px;
}
.post-media-thumbnails::-webkit-scrollbar-track {
  background: transparent;
}
.post-media-thumbnails::-webkit-scrollbar-thumb {
  background: var(--gray-300);
  border-radius: 4px;
}
.post-media-thumbnails::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted, #999);
}

/* Prev/next arrows overlaid on the main image — click switches images */
/* Picture counter: there is more than one picture */
.post-media-main .post-media-counter {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #ffffff !important;
  font-size: 0.8rem;
  line-height: 1.6;
  pointer-events: none;
}

.post-media-main .post-media-counter span {
  color: inherit !important;
}

.post-media-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s, background 0.2s;
}
.post-media-arrow--prev {
  left: 12px;
}
.post-media-arrow--next {
  right: 12px;
}
.post-media-main:hover .post-media-arrow,
.post-media-main:focus-within .post-media-arrow {
  opacity: 1;
}
.post-media-arrow:hover {
  background: rgba(0, 0, 0, 0.7);
}
.post-media-arrow::before {
  content: '';
  width: 11px;
  height: 11px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
}
.post-media-arrow--prev::before {
  transform: rotate(135deg);
  margin-left: 4px;
}
.post-media-arrow--next::before {
  transform: rotate(-45deg);
  margin-right: 4px;
}
@media (hover: none) {
  .post-media-arrow {
    opacity: 1;
  }
}

.post-media-thumb {
  flex: 0 0 160px;
  height: 90px;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s;
  border: 2px solid transparent;
  padding: 0;
  background: none;
}

.post-media-thumb.active {
  opacity: 1;
  border-color: var(--primary, #0073aa);
}

.post-media-thumb:hover {
  opacity: 1;
}

.post-media-thumbnails .post-media-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  margin: 0;
  border-radius: 0;
  box-shadow: none;
}

.post-media-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Audio thumbnail — no frame, show a centred music glyph */
.post-media-thumb--audio {
  position: relative;
  background: var(--gray-200, rgba(0, 0, 0, 0.06));
}
.post-media-thumb--audio::after {
  content: '\266B';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary, #333);
  font-size: 1.8rem;
}

/* Audio main item — centre the player on a calm panel */
.post-media-audio {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  padding: 2rem 1rem;
  background: var(--gray-100, rgba(0, 0, 0, 0.04));
}
.post-media-audio audio {
  width: 100%;
  max-width: 520px;
}

.entry-content video {
  max-width: 100%;
}

@media (max-width: 768px) {
  .post-media-main-item img {
    width: 100%;
    height: auto;
  }
  .post-media-main-item video {
    max-height: 280px;
  }
  .post-media-thumb {
    flex: 0 0 120px;
    height: 68px;
  }
  .post-media-arrow {
    width: 38px;
    height: 38px;
  }
}

@media (max-width: 480px) {
  .post-media-main-item img {
    width: 100%;
    height: auto;
  }
  .post-media-thumb {
    flex: 0 0 100px;
    height: 56px;
  }
}

/* ========== GENERAL IMAGE STYLING ========== */

/* WordPress standard image classes */
.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  margin: 1rem 0;
}

/* WordPress image alignments */
.entry-content .aligncenter {
  display: block;
  margin: 1.5rem auto;
  text-align: center;
}

.entry-content .alignleft {
  float: left;
  margin: 0 1.5rem 1rem 0;
}

.entry-content .alignright {
  float: right;
  margin: 0 0 1rem 1.5rem;
}

.entry-content .alignnone {
  margin: 1rem 0;
}

/* WordPress captions */
.entry-content .wp-caption {
  max-width: 100%;
  margin: 1rem 0;
  text-align: center;
}

.entry-content .wp-caption img {
  margin: 0;
  display: block;
}

.entry-content .wp-caption-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0.5rem 0 0 0;
  padding: 0.5rem;
  background: var(--gray-50);
  border-radius: 0 0 var(--border-radius) var(--border-radius);
}

/* WordPress galleries */
.entry-content .wp-block-gallery {
  margin: 2rem 0;
}

.entry-content .wp-block-gallery .wp-block-image {
  margin: 0;
}

.entry-content .wp-block-gallery .wp-block-image img {
  margin: 0;
  border-radius: var(--border-radius);
}

/* Featured image */
.entry-content .post-thumbnail {
  margin: 0 0 2rem 0;
  text-align: center;
}

.entry-content .post-thumbnail img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-md);
}

/* ========== RESPONSIVE IMAGE STYLING ========== */

@media (max-width: 768px) {
  .post-image-gallery {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .post-image-item img {
    height: 250px;
  }
  
  .post-image-gallery .post-image-item:only-child img {
    height: auto;
    max-height: 300px;
  }
  
  .entry-content .alignleft,
  .entry-content .alignright {
    float: none;
    margin: 1rem auto;
    display: block;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .post-image-gallery {
    margin: 1rem 0;
  }
  
  .post-image-item img {
    height: 200px;
  }
  
  .post-image-item figcaption {
    padding: 0.75rem;
  }
}

/* ========== LIGHTBOX STYLING ========== */

.rtsb-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rtsb-lightbox-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(2px);
}

.rtsb-lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10000;
}

.rtsb-lightbox-image {
  max-width: 100%;
  max-height: 80vh;
  width: auto;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
  object-fit: contain;
}

.rtsb-lightbox-caption {
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 1rem;
  border-radius: var(--border-radius);
  margin-top: 1rem;
  text-align: center;
  max-width: 100%;
  font-size: 0.9rem;
}

/* A gallery video plays in the same overlay as a picture */
.rtsb-lightbox-video {
  /* important: the phone rule "body * { max-width: none !important }" would
     otherwise let a portrait video grow wider than the screen */
  max-width: 94vw !important;
  max-height: 88vh;
  max-height: 88dvh;
  width: auto;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
  background: #000;
}

/* The arrows lie above picture and video: the video comes later in the
   markup and would cover them */
.rtsb-lightbox-prev,
.rtsb-lightbox-next {
  z-index: 2;
}

/* Up to tablet width a picture is held inside the screen (the phone rule
   "body * { max-width: none !important }" let a landscape picture grow wider
   than the screen), and the arrows are pinned to the screen edges like the
   close button, so they cannot end up outside the visible area. */
@media (max-width: 768px) {
  .rtsb-lightbox-image {
    max-width: 94vw !important;
  }

  .rtsb-lightbox .rtsb-lightbox-prev,
  .rtsb-lightbox .rtsb-lightbox-next {
    position: fixed;
    background: rgba(0, 0, 0, 0.6);
  }

  .rtsb-lightbox .rtsb-lightbox-prev {
    left: calc(8px + env(safe-area-inset-left, 0px));
  }

  .rtsb-lightbox .rtsb-lightbox-next {
    right: calc(8px + env(safe-area-inset-right, 0px));
  }
}

.rtsb-lightbox-video[hidden],
.rtsb-lightbox-image[hidden] {
  display: none;
}

/* The back-to-top button would float over the open picture */
body.rtsb-lightbox-open .rt-to-top {
  visibility: hidden;
}

/* No title, no empty black box under the picture */
.rtsb-lightbox-caption:empty {
  display: none;
}

/* The close button is pinned to the corner of the screen, not to the picture:
   beside a tall picture it used to end up above the visible area on phones,
   and its dark disc vanished on a dark photo. White on every picture. */
.rtsb-lightbox-close {
  position: fixed;
  top: calc(12px + env(safe-area-inset-top, 0px));
  right: calc(12px + env(safe-area-inset-right, 0px));
  z-index: 10001;
  background: #ffffff;
  color: #111111 !important;
  border: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.rtsb-lightbox-close:hover,
.rtsb-lightbox-close:focus-visible {
  background: #e6e6e6;
}

.rtsb-lightbox-prev,
.rtsb-lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.rtsb-lightbox-prev {
  left: -60px;
}

.rtsb-lightbox-next {
  right: -60px;
}

.rtsb-lightbox-prev:hover,
.rtsb-lightbox-next:hover {
  background: rgba(0, 0, 0, 0.7);
  transform: translateY(-50%) scale(1.1);
}

.rtsb-lightbox-open {
  overflow: hidden;
}

/* Responsive lightbox */
@media (max-width: 768px) {
  .rtsb-lightbox-content {
    max-width: 95%;
    max-height: 95%;
  }
  
  .rtsb-lightbox-image {
    max-height: 84vh;
    /* the visible height: the address bar of a phone browser is not part of it */
    max-height: 84dvh;
  }
  
  .rtsb-lightbox-prev,
  .rtsb-lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
  
  .rtsb-lightbox-prev {
    left: -45px;
  }
  
  .rtsb-lightbox-next {
    right: -45px;
  }
}

@media (max-width: 480px) {
  .rtsb-lightbox-prev {
    left: 10px;
  }
  
  .rtsb-lightbox-next {
    right: 10px;
  }

}

/* Plugin Popup Styling - Fix for post-to-wordpress plugin popups
   The plugin renders edit forms inside fixed-position modal overlays
   (#popup-wf_post_edit with position:fixed; height:100%; overflow:auto).
   Override to render inline so the whole page scrolls normally. */

/* The plugin's inline <style> sets:
     #popup-wf_post_edit { position:fixed; top:0; left:0;
       width:100%; height:100%; overflow:auto; z-index:100;
       padding-top:50px; background-color:rgba(0,0,0,0.2); }
   Override each property to put the element back in normal flow. */
#popup-wf_post_edit,
#popup-wf_product_edit,
#popup-wf_event_edit,
#popup-wf_place_edit {
  position: static !important;
  height: auto !important;
  overflow: visible !important;
  background-color: var(--gray-50, #f9fafb) !important;
  background: var(--gray-50, #f9fafb) !important;
  padding-top: var(--space-lg, 1.5rem) !important;
  padding-bottom: var(--space-lg, 1.5rem) !important;
  z-index: 1 !important;
}

/* On the edit-posts page the body gets class "has-edit-posts" (via
   rtsb_theme_body_classes).  Constrain the footer to the same max-width
   as .site-main so it never extends beyond the content area. */
.has-edit-posts .site-footer {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

/* Content box inside the popup */
[class^="popup-contents-wf_"] {
  font-family: var(--font-body) !important;
  color: var(--text-primary) !important;
  background: var(--white) !important;
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  overflow: visible !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 20px !important;
  border-radius: var(--border-radius, 8px) !important;
}

/* Make the editor inside the popup auto-expand like on create-post */
#popup-wf_post_edit .wp-editor-area,
#popup-wf_product_edit .wp-editor-area,
#popup-wf_event_edit .wp-editor-area,
#popup-wf_place_edit .wp-editor-area {
  height: auto !important;
  min-height: 300px !important;
}

#popup-wf_post_edit .mce-edit-area,
#popup-wf_post_edit .mce-edit-area iframe,
#popup-wf_product_edit .mce-edit-area,
#popup-wf_product_edit .mce-edit-area iframe,
#popup-wf_event_edit .mce-edit-area,
#popup-wf_event_edit .mce-edit-area iframe,
#popup-wf_place_edit .mce-edit-area,
#popup-wf_place_edit .mce-edit-area iframe {
  height: auto !important;
  min-height: 300px !important;
}

/* Hide the bottom filler spacer */
.wf-popup .wf-popup-end-filler {
  display: none !important;
}

div[class*="popup-wf_"] *,
.popup-wf_post_edit *,
.popup-wf_product_edit *,
.popup-wf_event_edit *,
.popup-wf_place_edit *,
#popup-wf_post_edit *,
#popup-wf_product_edit *,
#popup-wf_event_edit *,
#popup-wf_place_edit * {
  font-family: inherit !important;
}
/* Restore Phosphor icon fonts in edit popups (the wildcard above overrides font-family) */
.popup-wf_place_edit .ph, #popup-wf_post_edit .ph, #popup-wf_product_edit .ph, #popup-wf_event_edit .ph, #popup-wf_place_edit .ph {
  font-family: "Phosphor" !important;
}
.popup-wf_place_edit .ph-fill, #popup-wf_post_edit .ph-fill, #popup-wf_product_edit .ph-fill, #popup-wf_event_edit .ph-fill, #popup-wf_place_edit .ph-fill {
  font-family: "Phosphor-Fill" !important;
}
.popup-wf_place_edit .ph-duotone, #popup-wf_post_edit .ph-duotone, #popup-wf_product_edit .ph-duotone, #popup-wf_event_edit .ph-duotone, #popup-wf_place_edit .ph-duotone {
  font-family: "Phosphor-Duotone" !important;
}
.popup-wf_place_edit .ph-light, #popup-wf_post_edit .ph-light, #popup-wf_product_edit .ph-light, #popup-wf_event_edit .ph-light, #popup-wf_place_edit .ph-light {
  font-family: "Phosphor-Light" !important;
}
.popup-wf_place_edit .ph-thin, #popup-wf_post_edit .ph-thin, #popup-wf_product_edit .ph-thin, #popup-wf_event_edit .ph-thin, #popup-wf_place_edit .ph-thin {
  font-family: "Phosphor-Thin" !important;
}

/* Plugin form styling within popups */
div[class*="popup-wf_"] .wf-form-form,
.popup-wf_post_edit .wf-form-form,
.popup-wf_product_edit .wf-form-form,
.popup-wf_event_edit .wf-form-form,
.popup-wf_place_edit .wf-form-form,
#popup-wf_post_edit .wf-form-form,
#popup-wf_product_edit .wf-form-form,
#popup-wf_event_edit .wf-form-form,
#popup-wf_place_edit .wf-form-form {
  background: var(--white) !important;
  color: var(--text-primary) !important;
  border-radius: var(--border-radius) !important;
  padding: 20px !important;
}

/* Force override any popup background colors */
div[class*="popup-wf_"] .wf-form-form,
div[class*="popup-wf_"] .wf-form,
div[class*="popup-wf_"] .wf-fieldset,
div[class*="popup-wf_"] fieldset {
  background-color: var(--white) !important;
  background: var(--white) !important;
}

.popup-wf_post_edit .wf-input input,
.popup-wf_post_edit .wf-input textarea,
.popup-wf_post_edit .wf-input select,
.popup-wf_product_edit .wf-input input,
.popup-wf_product_edit .wf-input textarea,
.popup-wf_product_edit .wf-input select,
.popup-wf_event_edit .wf-input input,
.popup-wf_event_edit .wf-input textarea,
.popup-wf_event_edit .wf-input select,
.popup-wf_place_edit .wf-input input,
.popup-wf_place_edit .wf-input textarea,
.popup-wf_place_edit .wf-input select {
  background: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius);
  padding: 12px 16px;
  font-size: 16px;
  font-family: inherit !important;
  transition: var(--transition);
}

.popup-wf_post_edit .wf-input input:focus,
.popup-wf_post_edit .wf-input textarea:focus,
.popup-wf_post_edit .wf-input select:focus,
.popup-wf_product_edit .wf-input input:focus,
.popup-wf_product_edit .wf-input textarea:focus,
.popup-wf_product_edit .wf-input select:focus,
.popup-wf_event_edit .wf-input input:focus,
.popup-wf_event_edit .wf-input textarea:focus,
.popup-wf_event_edit .wf-input select:focus,
.popup-wf_place_edit .wf-input input:focus,
.popup-wf_place_edit .wf-input textarea:focus,
.popup-wf_place_edit .wf-input select:focus {
  outline: none;
  border-color: var(--accent-color) !important;
  box-shadow: var(--focus-ring);
}

.popup-wf_post_edit .wf-input label,
.popup-wf_product_edit .wf-input label,
.popup-wf_event_edit .wf-input label,
.popup-wf_place_edit .wf-input label {
  color: var(--text-primary) !important;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 8px;
  display: block;
}

.popup-wf_post_edit .action-button,
.popup-wf_product_edit .action-button,
.popup-wf_event_edit .action-button,
.popup-wf_place_edit .action-button {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  border: none !important;
  border-radius: var(--border-radius);
  padding: 12px 24px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit !important;
}

.popup-wf_post_edit .action-button:hover,
.popup-wf_product_edit .action-button:hover,
.popup-wf_event_edit .action-button:hover,
.popup-wf_place_edit .action-button:hover {
  background: var(--accent-color) !important;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* WordPress editor styling within popups */
.popup-wf_post_edit .wp-editor-container,
.popup-wf_product_edit .wp-editor-container,
.popup-wf_event_edit .wp-editor-container,
.popup-wf_place_edit .wp-editor-container {
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius);
  overflow: hidden;
}

.popup-wf_post_edit .wp-editor-area,
.popup-wf_product_edit .wp-editor-area,
.popup-wf_event_edit .wp-editor-area,
.popup-wf_place_edit .wp-editor-area {
  background: var(--white) !important;
  color: var(--text-primary) !important;
  font-family: inherit !important;
}

/* Additional aggressive override for plugin popup styling */
body div[class*="popup"]:not([class*="rtsb-lightbox"]) {
  background: var(--white) !important;
  color: var(--text-primary) !important;
}

body div[class*="popup"]:not([class*="rtsb-lightbox"]) * {
  font-family: var(--font-body) !important;
}

/* Target the popup content container more specifically */
body [class*="popup-wf_"] > div:first-child {
  background: var(--white) !important;
  color: var(--text-primary) !important;
}

/* Override any dark backgrounds in the popup */
body [class*="popup-wf_"] div,
body [class*="popup-wf_"] form,
body [class*="popup-wf_"] fieldset {
  background: var(--white) !important;
  color: var(--text-primary) !important;
}

/* Force white background on all popup elements */
[class*="popup-wf_"] {
  background-color: var(--white) !important;
  background-image: none !important;
  background: var(--white) !important;
}

[class*="popup-wf_"] > * {
  background-color: var(--white) !important;
  background: var(--white) !important;
}

/* Target the specific plugin form classes (standard form only, not progress form) */
.wf-form-form.wf-standard-form,
.wf-standard-form {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  font-family: var(--font-body) !important;
}

/* Target all elements within the standard form */
.wf-form-form.wf-standard-form *,
.wf-standard-form * {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  font-family: inherit !important;
}

/* Specific targeting for standard form sections */
.wf-standard-form .wf-fieldset,
.wf-standard-form fieldset {
  background: var(--white) !important;
  background-color: var(--white) !important;
  border: none !important;
}

/* Form inputs within the standard form */
.wf-standard-form input,
.wf-standard-form textarea,
.wf-standard-form select {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  padding: 12px 16px !important;
  font-size: 16px !important;
  font-family: inherit !important;
}

/* Form labels */
.wf-standard-form label {
  color: var(--text-primary) !important;
  font-weight: 600 !important;
  font-family: inherit !important;
}

/* Form buttons */
.wf-standard-form .action-button,
.wf-standard-form button {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  border: none !important;
  border-radius: var(--border-radius) !important;
  padding: 12px 24px !important;
  font-weight: 600 !important;
  font-family: inherit !important;
  cursor: pointer !important;
}

/* Default page container */
.default-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Theme-aware select elements */
.default-page select,
.wf-form select {
    background-color: var(--form-bg, var(--white, #1a1a2e)) !important;
    color: var(--form-text, var(--text-primary, #e0e0e0)) !important;
    border: 1px solid rgba(128, 128, 128, 0.3);
    padding: 8px 12px;
    border-radius: 4px;
}

@media (prefers-color-scheme: dark) {
    .default-page select,
    .wf-form select {
        background-color: #2a2a3e !important;
        color: #e0e0e0 !important;
    }
}

/* Widen the default page container when it holds an edit overview */
.default-page:has([class*="wf_edit_"][class*="_overview"]) {
    max-width: 1200px;
}

/* Edit form popup: remove top gap */
.popup-contents-wf_product_edit,
.popup-contents-wf_event_edit {
    padding-top: 0 !important;
}

/* Close button: sticky at top right so it's always visible */
.popup-close-wf_product_edit,
.popup-close-wf_event_edit {
    position: sticky !important;
    top: 0;
    z-index: 10;
    text-align: right;
}

/* Standard form (edit product): full-width stacked layout */
.wf-standard-form .wf-label {
    width: 100% !important;
    float: none !important;
    margin-bottom: 5px;
}

.wf-standard-form .wf-input {
    width: 100% !important;
    float: none !important;
}

.wf-standard-form .wf-field,
.wf-standard-form .wf-form,
.wf-standard-form .wf-form-form,
.wf-standard-form fieldset.wf-fieldset {
    max-width: 100% !important;
    box-sizing: border-box !important;
}

.wf-standard-form .wf-input input[type="text"],
.wf-standard-form .wf-input input[type="number"],
.wf-standard-form .wf-input input[type="url"],
.wf-standard-form .wf-input textarea,
.wf-standard-form .wf-input select {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

@media (orientation: portrait) {
    .default-page:has([class*="wf_edit_"][class*="_overview"]) {
        max-width: 100%;
        padding: 5px;
    }

    [class*="wf_edit_"][class*="_overview"] {
        max-width: 100%;
    }

    .default-page {
        padding-left: 5px !important;
        padding-right: 5px !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    article,
    .site-main {
        max-width: 100% !important;
        width: 100% !important;
        padding-left: 5px !important;
        padding-right: 5px !important;
        box-sizing: border-box !important;
    }

    .wf-image-gallery-container {
        max-width: 100% !important;
        overflow-x: auto;
    }

    /* Clip action buttons that overflow in portrait */
    .wf-edit-table tr td:last-child {
        overflow: hidden !important;
    }
}

/* Progress form — no background box, styled buttons */
.wf-progress-form fieldset.wf-fieldset {
  border: none !important;
  background: transparent !important;
}

.wf-progress-form .action-button,
.wf-progress-form .action-buttons button[type="button"],
.wf-progress-form .next,
.wf-progress-form .previous {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  border: 2px solid var(--primary-color) !important;
  border-radius: 25px !important;
  padding: 10px 24px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
}

.wf-progress-form .action-button:hover,
.wf-progress-form .action-buttons button[type="button"]:hover,
.wf-progress-form .next:hover,
.wf-progress-form .previous:hover {
  background: var(--secondary-color) !important;
  border-color: var(--secondary-color) !important;
  color: var(--text-on-secondary) !important;
}

/* Publish / Save-as-draft buttons — use the site's primary colour instead of
   the plugin's hard-coded pink. Publish = solid primary, draft = outlined.
   `body` prefix beats the plugin's `.wf-*-submit-class !important` rules. */
body .wf-product-submit-class,
body .wf-event-submit-class,
body .wf-post-submit-class,
body .wf-place-submit-class,
body .wf-stream-submit-class {
  background-color: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  border-color: var(--primary-color) !important;
}
body .wf-product-submit-class:hover,
body .wf-event-submit-class:hover,
body .wf-post-submit-class:hover,
body .wf-place-submit-class:hover,
body .wf-stream-submit-class:hover {
  background-color: var(--secondary-color) !important;
  border-color: var(--secondary-color) !important;
  color: var(--text-on-secondary) !important;
}
body #wf-product-submit-draft,
body #wf-event-submit-draft,
body #wf-post-submit-draft,
body #wf-place-submit-draft,
body #wf-stream-submit-draft {
  color: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
}
body #wf-product-submit-draft:hover,
body #wf-event-submit-draft:hover,
body #wf-post-submit-draft:hover,
body #wf-place-submit-draft:hover,
body #wf-stream-submit-draft:hover {
  background-color: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
}

/* WordPress editor Visual/Code tabs in progress form */
.wf-progress-form .wp-switch-editor {
  background: var(--gray-200) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  padding: 6px 12px !important;
}

.wf-progress-form .wp-switch-editor.switch-tmce:focus,
.wf-progress-form .wp-switch-editor.switch-html:focus,
.wf-progress-form .html-active .wp-switch-editor.switch-html,
.wf-progress-form .tmce-active .wp-switch-editor.switch-tmce {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
}

.wf-progress-form .condition {
  background: transparent !important;
  color: var(--accent-color) !important;
  border: 2px solid var(--accent-color) !important;
  border-radius: 99em !important;
  padding: 10px 20px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
}

.wf-progress-form .condition:hover {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
}

.wf-progress-form .condition-active {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border-color: var(--accent-color) !important;
}

/* WordPress Editor styling within plugin forms */
.wf-standard-form .wp-editor-tools,
.wp-editor-tools {
  background: var(--gray-100) !important;
  background-color: var(--gray-100) !important;
  border: 1px solid var(--gray-300) !important;
  border-bottom: none !important;
}

.wf-standard-form .wp-editor-container {
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  overflow: hidden !important;
  background: var(--white) !important;
}

.wf-standard-form .wp-editor-area {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  font-family: inherit !important;
  border: none !important;
}

/* WordPress editor toolbar buttons */
.wp-editor-tools .wp-media-buttons .button,
.wp-editor-tools .wp-switch-editor,
.wp-editor-tools button {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  font-family: inherit !important;
}

.wp-editor-tools .wp-media-buttons .button:hover,
.wp-editor-tools .wp-switch-editor:hover,
.wp-editor-tools button:hover {
  background: var(--gray-100) !important;
  background-color: var(--gray-100) !important;
}

/* Active editor tab */
.wp-editor-tools .wp-switch-editor.switch-html,
.wp-editor-tools .wp-switch-editor.switch-tmce {
  background: var(--gray-100) !important;
  background-color: var(--gray-100) !important;
}

.wp-editor-tools .wp-switch-editor.switch-html.active,
.wp-editor-tools .wp-switch-editor.switch-tmce.active {
  background: var(--white) !important;
  background-color: var(--white) !important;
  color: var(--primary-color) !important;
}

/* TinyMCE editor iframe content */
.wf-standard-form .mce-content-body {
  background: var(--white) !important;
  color: var(--text-primary) !important;
  font-family: inherit !important;
}

/* WordPress Editor Icons - Ensure dashicons are loaded and visible */
.wp-editor-tools .wp-media-buttons .button:before,
.wp-editor-tools .button:before {
  font-family: dashicons !important;
  speak: never;
  font-style: normal;
  font-weight: normal;
  font-variant: normal;
  text-transform: none;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Specific WordPress editor button icons */
.wp-editor-tools .wp-media-buttons .insert-media:before {
  content: "\f104" !important;
}

/* Import WordPress dashicons from WordPress admin */
@import url('/wp-includes/css/dashicons.min.css');

/* Fallback dashicons font loading */
@font-face {
  font-family: 'dashicons';
  src: url('/wp-includes/fonts/dashicons.woff2') format('woff2'),
       url('/wp-includes/fonts/dashicons.woff') format('woff'),
       url('/wp-includes/fonts/dashicons.ttf') format('truetype'),
       url('/wp-includes/fonts/dashicons.svg#dashicons') format('svg');
  font-weight: normal;
  font-style: normal;
}

/* TinyMCE toolbar button icons */
.mce-btn button {
  font-family: 'tinymce', Arial !important;
  position: relative !important;
}

/* TinyMCE specific icon fixes - use clear text/symbol labels */
.mce-i-bold:before { content: "B" !important; font-weight: bold !important; font-family: serif !important; }
.mce-i-italic:before { content: "I" !important; font-style: italic !important; font-family: serif !important; }
.mce-i-underline:before { content: "U" !important; text-decoration: underline !important; font-family: serif !important; }
.mce-i-strikethrough:before { content: "S" !important; text-decoration: line-through !important; font-family: serif !important; }
.mce-i-bullist:before { content: "•" !important; }
.mce-i-numlist:before { content: "1." !important; }
.mce-i-blockquote:before { content: "\201C" !important; font-size: 1.3em !important; }
.mce-i-hr:before { content: "—" !important; }
.mce-i-wp_more:before { content: "···" !important; }
.mce-i-undo:before { content: "↶" !important; }
.mce-i-redo:before { content: "↷" !important; }
.mce-i-link:before { content: "🔗" !important; }
.mce-i-unlink:before { content: "🔗\0338" !important; }
.mce-i-alignleft:before { content: "☰" !important; }
.mce-i-aligncenter:before { content: "☰" !important; text-align: center !important; }
.mce-i-alignright:before { content: "☰" !important; text-align: right !important; }
.mce-i-fullscreen:before { content: "⛶" !important; }
.mce-i-wp_adv:before { content: "⌨" !important; }
.mce-i-wp_help:before { content: "?" !important; }
.mce-i-spellchecker:before { content: "✓" !important; }

/* Fix WordPress editor toolbar button display */
.wp-editor-tools .wp-media-buttons .button,
.wp-editor-tools .button {
  display: inline-block !important;
  vertical-align: top !important;
  text-decoration: none !important;
  font-size: 13px !important;
  line-height: 26px !important;
  height: 28px !important;
  margin: 0 !important;
  padding: 0 10px 1px !important;
  cursor: pointer !important;
  border-width: 1px !important;
  border-style: solid !important;
  border-radius: 3px !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
}

.wp-editor-tools .wp-media-buttons .insert-media {
  background: var(--white) !important;
  border-color: var(--gray-300) !important;
  color: var(--text-primary) !important;
  padding-left: 30px !important;
  position: relative !important;
}

.wp-editor-tools .wp-media-buttons .insert-media:before {
  position: absolute !important;
  left: 8px !important;
  top: 2px !important;
  font-size: 16px !important;
  color: var(--text-primary) !important;
}

/* Additional TinyMCE toolbar styling */
.mce-toolbar .mce-btn,
.mce-toolbar .mce-btn button {
  background: var(--white) !important;
  border: 0.5px solid var(--gray-200) !important;
  color: var(--text-primary) !important;
  font-size: 13px !important;
  line-height: 1 !important;
  min-width: 28px !important;
  min-height: 28px !important;
  margin: 1px !important;
}

.mce-toolbar .mce-btn:hover,
.mce-toolbar .mce-btn button:hover {
  background: var(--gray-100) !important;
  border-color: var(--gray-300) !important;
}

.mce-toolbar .mce-btn.mce-active,
.mce-toolbar .mce-btn.mce-active button {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  border-color: var(--primary-color) !important;
}

/* Ensure TinyMCE container has proper background */
.mce-tinymce,
.mce-panel {
  background: var(--white) !important;
  border: 0.5px solid var(--gray-200) !important;
}

.mce-toolbar-grp {
  background: var(--gray-50) !important;
  border-bottom: 0.5px solid var(--gray-200) !important;
  padding: 4px !important;
}

/* Make sure all TinyMCE elements inherit theme styling */
.mce-container,
.mce-container *,
.mce-widget,
.mce-widget * {
  font-family: inherit !important;
}

/* Specific fix for empty icon buttons - add text fallbacks */
.mce-btn[aria-label="Bold"] button:empty:after { content: "B"; font-weight: bold; }
.mce-btn[aria-label="Italic"] button:empty:after { content: "I"; font-style: italic; }
.mce-btn[aria-label="Underline"] button:empty:after { content: "U"; text-decoration: underline; }
.mce-btn[aria-label="Bulleted list"] button:empty:after { content: "•"; }
.mce-btn[aria-label="Numbered list"] button:empty:after { content: "1."; }
.mce-btn[aria-label="Blockquote"] button:empty:after { content: '"'; }
.mce-btn[aria-label="Insert/edit link"] button:empty:after { content: "🔗"; }
.mce-btn[aria-label="Remove link"] button:empty:after { content: "⚠"; }

/* ========== Edit Posts Overview (wf_edit_posts shortcode) ========== */

.wf_edit_posts_overview {
  overflow: visible;
  max-height: none;
  height: auto;
}

.wf_edit_posts_overview .wf-post-hidden-editor-container {
  display: none !important;
  height: 0 !important;
  overflow: hidden !important;
}

.wf_edit_posts_overview .wf-edit-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0 var(--space-sm);
  background: transparent;
  border: none;
}

.wf_edit_posts_overview .wf-edit-table tr {
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
}

.wf_edit_posts_overview .wf-edit-table td {
  padding: var(--space-sm) var(--space-md);
  vertical-align: middle;
  border: none;
  color: var(--text-primary);
}

.wf_edit_posts_overview .wf-edit-table td a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
}

.wf_edit_posts_overview .wf-edit-table td a:hover {
  color: var(--accent-color);
}

.wf_edit_posts_overview .wf-edit-table td img {
  border-radius: var(--border-radius-sm);
  object-fit: cover;
}

.wf_edit_posts_overview .wf-edit-post,
.wf_edit_posts_overview .wf-delete-post {
  cursor: pointer;
  font-size: 1.25rem;
  padding: var(--space-xs) var(--space-sm);
}

.wf_edit_posts_overview .wf-edit-post {
  color: var(--primary-color);
}

.wf_edit_posts_overview .wf-edit-post::before {
  content: "\270F";
  font-style: normal;
}

.wf_edit_posts_overview .wf-delete-post {
  color: var(--error-color);
}

.wf_edit_posts_overview .wf-delete-post::before {
  content: "\1F5D1";
  font-style: normal;
}

.wf_edit_posts_overview .wf-pagination-panel {
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: var(--space-xs) var(--space-sm);
}

.wf_edit_posts_overview .wf-pagination-btn {
  color: var(--text-primary);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: var(--space-xs) var(--space-sm);
}

.wf_edit_posts_overview .wf-pagination-btn:hover {
  color: var(--accent-color);
}

.wf_edit_posts_overview .wf-pagination-btn i::before {
  font-family: inherit;
  font-style: normal;
  font-size: 1.25rem;
}

.wf_edit_posts_overview .wf-pagination-btn i.ph-caret-left::before {
  content: "\276E";
}

.wf_edit_posts_overview .wf-pagination-btn i.ph-caret-right::before {
  content: "\276F";
}

.wf_edit_posts_overview .wf-pagination-panel label {
  color: var(--text-secondary);
}

.wf_edit_posts_overview .wf-edit-no-element {
  background: var(--white);
  color: var(--text-muted);
  border-radius: var(--border-radius);
  padding: var(--space-xl);
  text-align: center;
}

/* ========== LANDING PAGE LAYOUTS ========== */

/* ---------- Icon System (Phosphor font) ---------- */

.rtsb-icon {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
  line-height: 1;
}

.rtsb-icon--sm { font-size: 16px; }
.rtsb-icon--md { font-size: 20px; }
.rtsb-icon--lg { font-size: 28px; }
.rtsb-icon--xl { font-size: 40px; }
.rtsb-icon--2xl { font-size: 56px; }

/* ---------- Section Dividers ---------- */

.divider-angle {
  height: 60px;
  background: var(--gray-50);
  clip-path: polygon(0 0, 100% 100%, 0 100%);
  margin-top: -60px;
  position: relative;
  z-index: 2;
}

.divider-dot {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl) 0;
}

.divider-dot::before,
.divider-dot::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-200);
}

.divider-dot::before {
  margin-right: var(--space-lg);
}

.divider-dot::after {
  margin-left: var(--space-lg);
}

.divider-gradient {
  height: 3px;
  max-width: 600px;
  margin: 0 auto;
  background: linear-gradient(90deg, transparent, var(--accent-fill, var(--accent-color)), transparent);
}

.divider-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl) var(--space-lg);
}

.divider-rule::before,
.divider-rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-200);
}

.divider-rule span {
  width: 10px;
  height: 10px;
  background: var(--accent-color);
  transform: rotate(45deg);
  margin: 0 var(--space-md);
  flex-shrink: 0;
}

.divider-wave {
  margin-top: -30px;
  position: relative;
  z-index: 2;
  line-height: 0;
}

.divider-wave svg {
  display: block;
  width: 100%;
  height: 60px;
}

/* ---------- Default Layout — "Full Featured & Versatile" ---------- */

.hero-default {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  clip-path: polygon(0 0, 100% 0, 100% 85%, 0 100%);
  padding-bottom: calc(var(--space-4xl) + 60px);
  text-align: left;
}

.hero-default::before {
  background-image:
    radial-gradient(circle at 25% 25%, rgba(255, 255, 255, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
  animation: float 6s ease-in-out infinite;
}

.hero-dot-overlay {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 20px 20px;
  pointer-events: none;
  z-index: 0;
}

.hero-deco-circle {
  position: absolute;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  top: -80px;
  right: -60px;
  pointer-events: none;
  z-index: 0;
}

.hero-content--left {
  text-align: left;
  max-width: 700px;
  margin: 0 auto 0 clamp(2rem, 8vw, 8rem);
}

.hero-eyebrow {
  display: inline-block;
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: var(--letter-spacing-widest);
  text-transform: uppercase;
  opacity: 0.8;
  margin-bottom: var(--space-md);
  padding: var(--space-xs) var(--space-md);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--border-radius);
}

/* Timeline content section */
.content-timeline {
  position: relative;
  max-width: 900px;
  margin: var(--space-3xl) auto;
  padding: var(--space-2xl) var(--space-lg);
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-fill, var(--accent-color)), var(--gray-200));
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  width: 45%;
  margin-bottom: var(--space-2xl);
}

.timeline-item--left {
  margin-right: auto;
  padding-right: var(--space-xl);
}

.timeline-item--right {
  margin-left: auto;
  padding-left: var(--space-xl);
}

.content-card--accent-top {
  border-left: none;
  border-top: 3px solid var(--accent-color);
}

/* Default metrics highlight line */
.metrics-default--highlight {
  position: relative;
}

.metrics-default--highlight::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
}

/* ---------- Minimal Layout — "Clean & Restrained" ---------- */

.hero-minimal {
  background: var(--primary-fill, var(--primary-color));
  min-height: 50vh;
}

.hero-minimal::before {
  display: none;
}

.hero-minimal .hero-title {
  font-weight: 400;
}

.content-minimal {
  max-width: 640px;
  margin: 0 auto;
  padding: var(--space-3xl) var(--space-lg);
  text-align: center;
}

.content-card-minimal {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: var(--space-2xl) 0;
  color: var(--text-primary);
}

.content-card-minimal h2 {
  font-size: var(--font-size-3xl);
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
}

.content-card-minimal p {
  color: var(--text-secondary);
  line-height: var(--line-height-relaxed);
  font-size: var(--font-size-lg);
}

/* Minimal metrics — understated inline */
.metrics-minimal {
  background: var(--gray-50);
  color: var(--text-primary);
  border-top: 1px solid var(--gray-200);
}

.metrics-inline .metric-item {
  border-top: 2px solid var(--gray-200);
  padding-top: var(--space-lg);
}

.metrics-minimal .metric-number {
  font-size: 2rem;
  color: var(--primary-color);
  background: none;
  -webkit-text-fill-color: unset;
}

.metrics-minimal .metric-label {
  color: var(--text-secondary);
  opacity: 1;
  font-size: var(--font-size-sm);
}

/* ---------- Services Layout — "Structured & Professional" ---------- */

.hero-services {
  background: linear-gradient(180deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  min-height: 40vh;
  align-items: flex-end;
  padding-bottom: var(--space-3xl);
}

.hero-content--bottom {
  max-width: 700px;
  margin: auto auto 0 auto;
}

.hero-badge {
  display: inline-block;
  font-size: var(--font-size-xs);
  font-weight: 600;
  letter-spacing: var(--letter-spacing-widest);
  text-transform: uppercase;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  padding: var(--space-xs) var(--space-lg);
  border-radius: 9999px;
  margin-bottom: var(--space-lg);
  backdrop-filter: blur(8px);
}

.services-focus {
  padding: var(--space-3xl) var(--space-lg);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-2xl);
  max-width: 1200px;
  margin: 0 auto var(--space-3xl) auto;
}

.service-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-md);
  padding: var(--space-3xl) var(--space-2xl) var(--space-2xl);
  text-align: left;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.service-card--numbered {
  border-left: none;
  border-top: none;
}

.service-ordinal {
  position: absolute;
  top: -0.25rem;
  right: var(--space-lg);
  font-size: 5rem;
  font-weight: 800;
  color: var(--gray-100);
  line-height: 1;
  pointer-events: none;
  font-family: var(--font-heading);
}

.service-card--numbered h3 {
  position: relative;
  color: var(--primary-color);
  font-size: var(--font-size-2xl);
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: var(--letter-spacing-tight);
  margin-bottom: var(--space-sm);
  padding-bottom: var(--space-sm);
}

.service-card--numbered h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--accent-color);
  border-radius: 2px;
}

.service-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-6px);
}

.contact-cta {
  text-align: center;
  background: var(--gray-50);
  border-radius: var(--border-radius);
  padding: 2rem;
  margin-top: 3rem;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.cta-phone-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  padding: 1rem 2rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  transition: var(--transition);
}

.cta-phone-link:hover {
  background: var(--accent-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* Services metrics with vertical dividers */
.metrics-services {
  background: var(--primary-fill, var(--primary-color));
  color: white;
}

.metrics-services-dividers {
  position: relative;
}

.metrics-services-dividers .metric-item {
  position: relative;
}

.metrics-services-dividers .metric-item + .metric-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 15%;
  bottom: 15%;
  width: 1px;
  background: rgba(255, 255, 255, 0.2);
}

/* ---------- Contact Layout — "Warm & Approachable" ---------- */

.hero-contact {
  background: radial-gradient(ellipse at center, var(--accent-fill, var(--accent-color)) 0%, var(--primary-fill, var(--primary-color)) 100%);
  padding-bottom: 0;
  margin-bottom: 0;
}

.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  z-index: 2;
  line-height: 0;
}

.hero-wave svg {
  width: 100%;
  height: 80px;
  display: block;
}

.contact-focus {
  padding: var(--space-3xl) var(--space-lg);
  max-width: 1200px;
  margin: 0 auto;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3xl);
  align-items: start;
}

.contact-info--styled {
  background: var(--gray-50);
  border-radius: var(--border-radius-xl);
  padding: var(--space-2xl);
}

.contact-info h2 {
  color: var(--primary-color);
  margin-bottom: var(--space-xl);
  text-align: center;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.contact-method {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: var(--white);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.contact-method--hover:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-md);
}

.contact-icon {
  flex-shrink: 0;
  color: var(--accent-color);
}

.contact-link {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition);
}

.contact-link:hover {
  color: var(--primary-color);
}

.contact-address {
  line-height: 1.5;
  color: var(--text-secondary);
}

.contact-content--styled {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-sm);
  padding: var(--space-2xl);
}

.contact-content--styled h3 {
  color: var(--primary-color);
  margin-bottom: var(--space-md);
}

/* Contact metrics elliptical clip */
.metrics-contact {
  background: linear-gradient(135deg, var(--accent-fill, var(--accent-color)) 0%, var(--primary-fill, var(--primary-color)) 100%);
  color: white;
}

.metrics-contact--clip {
  clip-path: ellipse(75% 100% at 50% 100%);
  padding-top: var(--space-4xl);
}

/* ---------- Startup Layout — "Bold & Dynamic" ---------- */

.hero-startup {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 50%, var(--accent-fill, var(--accent-color)) 100%);
  padding: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  width: 100vw;
  margin: 0;
  margin-left: calc(-50vw + 50%);
  margin-top: 0;
}

/* Geometric background decorations */
.hero-geo-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.geo-circle {
  position: absolute;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.08);
}

.geo-circle--1 {
  width: 400px;
  height: 400px;
  top: -100px;
  right: -80px;
  animation: float 8s ease-in-out infinite;
}

.geo-circle--2 {
  width: 250px;
  height: 250px;
  bottom: -60px;
  left: -40px;
  animation: float 6s ease-in-out infinite reverse;
}

.geo-line {
  position: absolute;
  background: rgba(255, 255, 255, 0.05);
}

.geo-line--1 {
  width: 200px;
  height: 2px;
  top: 30%;
  right: 5%;
  transform: rotate(-20deg);
}

.geo-line--2 {
  width: 150px;
  height: 2px;
  bottom: 25%;
  left: 8%;
  transform: rotate(15deg);
}

.hero-startup-content {
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 800px;
  width: 100%;
  padding: 0 2rem;
  z-index: 3;
  position: relative;
  text-align: center;
}

.hero-startup-text {
  color: white;
  text-align: center;
}

.hero-startup-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, #ffffff 0%, #e0e7ff 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6), 0 4px 40px rgba(0, 0, 0, 0.4);
  position: relative;
  z-index: 4;
}

.hero-startup-subtitle {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  opacity: 0.95;
  line-height: 1.6;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.5), 0 2px 20px rgba(0, 0, 0, 0.3);
  position: relative;
  z-index: 4;
}

.hero-startup-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  position: relative;
  z-index: 4;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.875rem 2rem;
  border-radius: var(--border-radius-lg);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition);
  border: 2px solid transparent;
  text-align: center;
  min-width: 140px;
}

.cta-primary {
  background: var(--primary-fill, var(--primary-color));
  color: #ffffff;
  border-color: var(--primary-color);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
}

.cta-primary:hover {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
}

.cta-secondary {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(10px);
}

.cta-secondary:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.startup-features {
  padding: 5rem 2rem;
  background: linear-gradient(180deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  width: 100vw;
  margin: 0;
  margin-left: calc(-50vw + 50%);
}

.features-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.feature-card {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--border-radius-xl);
  padding: 2.5rem;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-fill, var(--accent-color)), var(--primary-fill, var(--primary-color)));
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.95);
}

@media (prefers-color-scheme: dark) {
  .feature-card {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  }

  .feature-card:hover {
    background: rgba(0, 0, 0, 0.65);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  }

  .feature-card::before {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
  }
}

.feature-icon {
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: center;
  color: var(--text-primary);
}

.feature-card h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.feature-card p {
  color: var(--text-secondary);
  line-height: 1.6;
}

@media (prefers-color-scheme: dark) {
  .feature-icon {
    color: #ffffff;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  }

  .feature-card h3 {
    color: #ffffff !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  }

  .feature-card p {
    color: rgba(255, 255, 255, 0.95) !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  }
}

/* Startup metrics with pulsing live indicator */
.startup-metrics {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 50%, var(--accent-fill, var(--accent-color)) 100%);
  padding: 4rem 2rem;
  color: white;
  width: 100vw;
  margin: 0;
  margin-left: calc(-50vw + 50%);
}

.metric-live-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34d399;
  margin-right: var(--space-sm);
  vertical-align: middle;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

.metrics-container {
  max-width: 800px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  text-align: center;
}

.metric-item {
  padding: 1.5rem;
}

.metric-number {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #ffffff 0%, #e0e7ff 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.metric-label {
  font-size: 1rem;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* ---------- Metrics Section — Shared Styles ---------- */

.metrics-section {
  padding: 4rem 2rem;
  width: 100vw;
  margin: 0;
  margin-left: calc(-50vw + 50%);
}

.metrics-default {
  background: linear-gradient(135deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 50%, var(--accent-fill, var(--accent-color)) 100%);
  color: white;
}

.metrics-section .metrics-container {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 3rem;
  text-align: center;
}

.metrics-section .metric-item {
  padding: 1.5rem;
}

.metrics-section .metric-number {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.1;
}

.metrics-section .metric-label {
  font-size: 1rem;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
}

/* Gradient text for default, services, and contact */
.metrics-default .metric-number,
.metrics-services .metric-number,
.metrics-contact .metric-number {
  background: linear-gradient(135deg, #ffffff 0%, rgba(255, 255, 255, 0.8) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: none;
}

/* ---------- Portfolio Layout — "Creative & Visual" ---------- */

.hero-portfolio {
  background: linear-gradient(160deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  min-height: 70vh;
}

.hero-portfolio::after {
  content: '';
  position: absolute;
  inset: 20px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--border-radius);
  pointer-events: none;
  z-index: 0;
}

.portfolio-icon-deco {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  opacity: 0.08;
  z-index: 0;
  color: white;
}

.hero-title--serif-italic {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
}

.portfolio-hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: var(--space-lg);
  position: relative;
  z-index: 1;
}

.pill-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  font-size: var(--font-size-sm);
  font-weight: 500;
  text-decoration: none;
  transition: var(--transition);
}

.pill-button--ghost {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.6);
  color: white;
}

.pill-button--ghost:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: white;
  color: white;
}

.pill-button--solid {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: white;
}

.pill-button--solid:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.5);
  color: white;
}

.portfolio-content {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: var(--space-3xl) var(--space-lg);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
}

.portfolio-card {
  padding: var(--space-2xl);
  border-left: 3px solid var(--accent-color);
  color: var(--text-primary);
}

.portfolio-card--featured {
  grid-column: 1 / -1;
}

.portfolio-card h2,
.portfolio-card h3 {
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.portfolio-card p,
.portfolio-card div {
  color: var(--text-secondary);
  line-height: var(--line-height-relaxed);
}

.metrics-portfolio {
  background: var(--gray-50);
  padding: var(--space-3xl) var(--space-lg);
}

.metrics-portfolio .metrics-container {
  grid-template-columns: repeat(3, 1fr);
}

.portfolio-bar {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  text-align: left;
  padding: var(--space-lg) var(--space-xl);
}

.portfolio-bar .metric-number {
  color: var(--primary-color);
  font-size: 2.5rem;
  font-weight: 700;
  flex-shrink: 0;
  background: none;
  -webkit-text-fill-color: var(--primary-color);
}

.portfolio-bar .metric-label {
  color: var(--text-secondary);
  font-size: var(--font-size-base);
}

/* ---------- Corporate Layout — "Authority & Trust" ---------- */

.hero-corporate {
  background: linear-gradient(180deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 60%, var(--gray-50) 100%);
  min-height: 60vh;
  margin-bottom: 0;
}

.corporate-grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

.hero-badge--shield {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: var(--font-size-sm);
  font-weight: 500;
  letter-spacing: var(--letter-spacing-wide);
  margin-bottom: var(--space-lg);
  color: white;
}

.corporate-hero-contact {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: var(--space-xl);
  position: relative;
  z-index: 1;
}

.corporate-content {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: var(--space-3xl) var(--space-lg);
}

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

.corporate-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-top: 4px solid var(--accent-color);
  border-radius: var(--border-radius);
  padding: var(--space-2xl);
  position: relative;
  transition: var(--transition);
}

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

.corporate-numeral {
  position: absolute;
  top: var(--space-md);
  right: var(--space-lg);
  font-family: var(--font-display);
  font-size: var(--font-size-3xl);
  font-weight: 300;
  color: var(--gray-200);
  line-height: 1;
}

.corporate-card h3 {
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.corporate-rule {
  border: none;
  height: 1px;
  background: var(--gray-200);
  margin: var(--space-md) 0;
}

.corporate-card p,
.corporate-card div {
  color: var(--text-secondary);
  line-height: var(--line-height-relaxed);
}

.metrics-corporate {
  background: var(--primary-fill, var(--primary-color));
  padding: var(--space-3xl) var(--space-lg);
  color: white;
}

.metrics-corporate .metrics-container {
  grid-template-columns: repeat(3, 1fr);
}

.corporate-cell {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--border-radius);
  padding: var(--space-xl);
  backdrop-filter: blur(8px);
}

.corporate-cell .metric-number {
  color: white;
  font-size: 2.5rem;
  font-weight: 700;
}

.corporate-cell .metric-label {
  color: rgba(255, 255, 255, 0.85);
}

/* ---------- Storefront Layout — "Product & Shop" ---------- */

.hero-storefront {
  background: linear-gradient(135deg, var(--accent-fill, var(--accent-color)) 0%, var(--primary-fill, var(--primary-color)) 100%);
  min-height: 55vh;
}

.storefront-stripes {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 40px,
    rgba(255, 255, 255, 0.03) 40px,
    rgba(255, 255, 255, 0.03) 80px
  );
  pointer-events: none;
  z-index: 0;
}

.hero-badge--cart {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: var(--font-size-sm);
  font-weight: 600;
  margin-bottom: var(--space-lg);
  color: white;
}

.hero-title--bold-upper {
  text-transform: uppercase;
  font-weight: 800;
  letter-spacing: var(--letter-spacing-wider);
  font-family: var(--font-body);
}

.storefront-hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: var(--space-xl);
  position: relative;
  z-index: 1;
}

.cta-button--lg {
  padding: 1rem 2rem;
  font-size: var(--font-size-lg);
}

.storefront-content {
  background: var(--gray-50);
  padding: var(--space-3xl) var(--space-lg);
}

.storefront-grid {
  max-width: var(--content-max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
}

.showcase-card {
  background: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.showcase-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.showcase-card__header {
  background: var(--accent-color);
  color: white;
  padding: var(--space-lg) var(--space-xl);
}

.showcase-card__header h3 {
  margin: 0;
  color: white;
  font-size: var(--font-size-lg);
  font-weight: 600;
}

.showcase-card__body {
  padding: var(--space-xl);
  border-bottom: 3px solid var(--accent-color);
}

.showcase-card__body p,
.showcase-card__body div {
  color: var(--text-secondary);
  line-height: var(--line-height-relaxed);
}

.metrics-storefront {
  background: white;
  padding: var(--space-3xl) var(--space-lg);
}

.metrics-storefront .metrics-container {
  display: flex;
  justify-content: center;
  gap: var(--space-2xl);
}

.storefront-badge-circle {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: var(--accent-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  padding: 0;
}

.storefront-badge-circle .metric-number {
  color: white;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
}

.storefront-badge-circle .metric-label {
  color: rgba(255, 255, 255, 0.9);
  font-size: var(--font-size-xs);
  text-align: center;
  padding: 0 0.5rem;
}

/* ---------- Magazine Layout — "Editorial & Content" ---------- */

.hero-magazine {
  background: linear-gradient(180deg, var(--secondary-fill, var(--secondary-color)) 0%, var(--primary-fill, var(--primary-color)) 100%);
  min-height: 45vh;
  margin-bottom: 0;
}

.hero-magazine::before {
  display: none;
}

.magazine-dateline {
  display: block;
  font-family: var(--font-body);
  font-size: var(--font-size-sm);
  letter-spacing: var(--letter-spacing-widest);
  text-transform: uppercase;
  opacity: 0.7;
  margin-bottom: var(--space-lg);
}

.hero-title--editorial {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(3rem, 6vw, 5rem);
}

.hero-subtitle--italic {
  font-style: italic;
}

.magazine-hero-links {
  display: flex;
  gap: var(--space-lg);
  justify-content: center;
  margin-top: var(--space-lg);
  position: relative;
  z-index: 1;
}

.magazine-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.magazine-link:hover {
  color: white;
}

.magazine-content {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: var(--space-3xl) var(--space-lg);
}

.magazine-lead {
  max-width: 740px;
  margin: 0 auto var(--space-2xl);
}

.magazine-lead h2 {
  font-family: var(--font-display);
  font-size: var(--font-size-3xl);
  color: var(--text-primary);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-sm);
  border-bottom: 2px solid var(--accent-color);
  display: inline-block;
}

.magazine-lead__body {
  font-size: var(--font-size-lg);
  line-height: var(--line-height-loose);
  color: var(--text-secondary);
}

.magazine-lead__body p:first-of-type::first-letter {
  font-family: var(--font-display);
  font-size: 3.5rem;
  float: left;
  line-height: 1;
  margin-right: 0.5rem;
  margin-top: 0.1rem;
  color: var(--primary-color);
  font-weight: 700;
}

.magazine-rule {
  border: none;
  height: 1px;
  background: var(--gray-200);
  margin: var(--space-xl) 0;
}

.magazine-secondary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
}

.magazine-article h3 {
  font-family: var(--font-display);
  font-size: var(--font-size-xl);
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
  padding-bottom: var(--space-xs);
  border-bottom: 1px solid var(--accent-color);
  display: inline-block;
}

.magazine-article p,
.magazine-article div {
  color: var(--text-secondary);
  line-height: var(--line-height-relaxed);
}

.metrics-magazine {
  background: var(--secondary-color);
  padding: var(--space-xl) var(--space-lg);
  color: white;
}

.magazine-stat-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xl);
  max-width: var(--content-max-width);
}

.magazine-stat-strip .metric-item {
  text-align: center;
  padding: var(--space-sm) var(--space-md);
}

.magazine-stat-strip .metric-number {
  font-family: var(--font-display);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: white;
}

.magazine-stat-strip .metric-label {
  font-variant: small-caps;
  letter-spacing: var(--letter-spacing-wide);
  font-size: var(--font-size-sm);
  color: rgba(255, 255, 255, 0.8);
}

.magazine-pipe {
  color: rgba(255, 255, 255, 0.3);
  font-size: var(--font-size-2xl);
  font-weight: 200;
  line-height: 1;
}

/* ---------- Landing Page Responsive — 768px ---------- */

@media (max-width: 768px) {
  /* Default layout: collapse timeline */
  .timeline-line { display: none; }
  .timeline-item,
  .timeline-item--left,
  .timeline-item--right {
    width: 100%;
    padding-left: 0;
    padding-right: 0;
  }
  .hero-content--left {
    text-align: center;
    margin: 0 auto;
  }
  .hero-default {
    clip-path: none;
    padding-bottom: var(--space-3xl);
    text-align: center;
  }
  .hero-deco-circle { display: none; }

  /* Minimal layout */
  .hero-minimal {
    min-height: 35vh;
  }

  /* Services layout */
  .services-grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    padding: 0 var(--space-md);
  }
  .service-ordinal {
    font-size: 3.5rem;
  }

  /* Contact layout */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
  }
  .hero-wave svg { height: 50px; }
  .metrics-contact--clip {
    clip-path: none;
    padding-top: var(--space-3xl);
  }

  /* Startup layout */
  .hero-startup-content { padding: 0 1rem; }
  .hero-startup-title { font-size: clamp(2rem, 8vw, 3rem); }
  .hero-startup-cta { justify-content: center; }
  .startup-features { padding: 3rem 1rem; }
  .feature-card { padding: 2rem; }
  .startup-metrics { padding: 3rem 1rem; }
  .geo-circle--1 { width: 200px; height: 200px; }
  .geo-circle--2 { width: 150px; height: 150px; }

  /* Shared metrics */
  .metrics-section { padding: 3rem 1rem; }
  .metrics-section .metrics-container { gap: 2rem; }
  .metrics-section .metric-number { font-size: 2.5rem; }
  .metrics-section .metric-label { font-size: 0.9rem; }

  /* Dividers */
  .divider-angle { height: 30px; margin-top: -30px; }
  .divider-gradient { max-width: 80%; }

  /* Services divider lines collapse */
  .metrics-services-dividers .metric-item + .metric-item::before { display: none; }

  /* Portfolio layout */
  .portfolio-grid { grid-template-columns: 1fr; }
  .portfolio-card--featured { grid-column: auto; }
  .hero-portfolio::after { inset: 10px; }
  .portfolio-icon-deco { display: none; }
  .metrics-portfolio .metrics-container { grid-template-columns: 1fr; }
  .portfolio-bar { justify-content: center; text-align: center; flex-direction: column; gap: 0.5rem; }

  /* Corporate layout */
  .corporate-grid { grid-template-columns: 1fr; }
  .corporate-card { border-top: none; border-left: 4px solid var(--accent-color); }

  /* Storefront layout */
  .storefront-grid { grid-template-columns: 1fr; }
  .showcase-card__header { padding: var(--space-md) var(--space-lg); }
  .storefront-badge-circle { width: 120px; height: 120px; }
  .storefront-badge-circle .metric-number { font-size: 1.5rem; }

  /* Magazine layout */
  .magazine-secondary { grid-template-columns: 1fr; }
  .magazine-pipe { display: none; }
  .magazine-stat-strip { flex-direction: column; gap: var(--space-md); }
  .magazine-stat-strip .metric-item { border-bottom: 1px solid rgba(255, 255, 255, 0.15); padding-bottom: var(--space-md); }
  .magazine-stat-strip .metric-item:last-child { border-bottom: none; }
}

/* ---------- Landing Page Responsive — 640px ---------- */

@media (max-width: 640px) {
  .content-timeline {
    padding: var(--space-lg) var(--space-md);
  }

  .content-minimal {
    padding: var(--space-xl) var(--space-md);
  }

  .services-focus,
  .contact-focus {
    padding: var(--space-xl) var(--space-md);
  }

  .contact-method--hover:hover {
    transform: none;
  }

  /* Portfolio: compact hero */
  .hero-portfolio { min-height: 50vh; }

  /* Storefront: CTA stacks */
  .storefront-hero-cta { flex-direction: column; align-items: center; }
  .storefront-badge-circle {
    width: auto;
    height: auto;
    border-radius: var(--border-radius);
    padding: var(--space-md) var(--space-xl);
    flex-direction: row;
    gap: var(--space-md);
  }

  /* Magazine: compact drop-cap */
  .magazine-lead__body p:first-of-type::first-letter { font-size: 2.5rem; }
  .divider-wave svg { height: 40px; }
}

/* ---------- Landing Page Responsive — 480px ---------- */

@media (max-width: 480px) {
  .hero-startup {
    min-height: 100vh;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
  }
  .hero-startup-content {
    gap: 2rem;
    padding: 0 1rem;
    width: 100%;
  }
  .cta-button {
    width: 100%;
    margin-bottom: 0.5rem;
    justify-content: center;
  }
  .feature-card { padding: 1.5rem; }
  .features-container,
  .metrics-container {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .metric-number { font-size: 2.5rem; }

  .metrics-section { padding: 2rem 1rem; }
  .metrics-section .metrics-container {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .metrics-section .metric-number { font-size: 2rem; }
  .metrics-section .metric-item { padding: 1rem; }

  /* Corporate: pills stack, cells borderless */
  .corporate-hero-contact { flex-direction: column; align-items: center; }
  .corporate-cell { border: none; background: rgba(255, 255, 255, 0.05); }

  /* Portfolio: compact card padding */
  .portfolio-card { padding: var(--space-lg); }
  .pill-button { padding: 0.5rem 1rem; font-size: var(--font-size-xs); }
}

/* =============================================================================
   Comprehensive Dark Mode — Form Elements & Remaining Components
   ============================================================================= */

@media (prefers-color-scheme: dark) {

  /* --- Form Elements --- */
  input[type="text"],
  input[type="email"],
  input[type="url"],
  input[type="password"],
  input[type="search"],
  input[type="number"],
  input[type="tel"],
  input[type="date"],
  input[type="datetime-local"],
  input[type="month"],
  input[type="week"],
  input[type="time"],
  input[type="color"],
  textarea,
  select {
    background: var(--gray-100);
    color: var(--text-primary);
    border: 1px solid var(--gray-300);
    caret-color: var(--accent-color);
  }

  input[type="text"]::placeholder,
  input[type="email"]::placeholder,
  input[type="url"]::placeholder,
  input[type="password"]::placeholder,
  input[type="search"]::placeholder,
  input[type="number"]::placeholder,
  input[type="tel"]::placeholder,
  textarea::placeholder {
    color: var(--text-muted);
  }

  input[type="text"]:focus,
  input[type="email"]:focus,
  input[type="url"]:focus,
  input[type="password"]:focus,
  input[type="search"]:focus,
  input[type="number"]:focus,
  input[type="tel"]:focus,
  textarea:focus,
  select:focus {
    border-color: var(--accent-color);
    outline-color: var(--accent-color);
  }

  select option {
    background: var(--gray-100);
    color: var(--text-primary);
  }

  label {
    color: var(--text-primary);
  }

  fieldset {
    border-color: var(--gray-300);
  }

  legend {
    color: var(--text-primary);
  }

  /* --- Tables --- */
  table {
    border-color: var(--gray-300);
  }

  th {
    background: var(--gray-100);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  td {
    border-color: var(--gray-300);
    color: var(--text-secondary);
  }

  tr:nth-child(even) {
    background: var(--gray-100);
  }

  /* --- Horizontal Rules --- */
  hr {
    border-color: var(--gray-300);
  }

  /* --- Code Blocks --- */
  code {
    background: var(--gray-200);
    color: var(--accent-color);
  }

  pre {
    background: var(--gray-100);
    color: var(--text-primary);
    border: 1px solid var(--gray-300);
  }

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

  /* --- WordPress Block Elements --- */
  .wp-block-table table {
    border-color: var(--gray-300);
  }

  .wp-block-table th,
  .wp-block-table td {
    border-color: var(--gray-300);
  }

  .wp-block-quote {
    border-left-color: var(--accent-color);
    color: var(--text-secondary);
  }

  .wp-block-separator {
    border-color: var(--gray-300);
  }

  /* --- Contact Method Cards --- */
  .contact-method {
    background: var(--gray-100);
    border-color: var(--gray-300);
  }

  .contact-cta {
    background: var(--gray-100);
    border-color: var(--gray-300);
  }

  /* --- New Landing Page Layout Cards --- */
  .portfolio-card {
    border-left-color: var(--accent-color);
  }

  .corporate-card {
    background: var(--white);
    border-color: var(--gray-300);
    border-top-color: var(--accent-color);
  }

  .corporate-numeral {
    color: var(--gray-300);
  }

  .corporate-rule {
    background: var(--gray-300);
  }

  .showcase-card {
    background: var(--white);
    border-color: var(--gray-300);
  }

  .showcase-card__body {
    border-bottom-color: var(--accent-color);
  }

  .metrics-storefront {
    background: var(--gray-100);
  }

  .magazine-lead h2,
  .magazine-article h3 {
    color: var(--text-primary);
    border-bottom-color: var(--accent-color);
  }

  .magazine-rule {
    background: var(--gray-300);
  }

  .divider-rule::before,
  .divider-rule::after {
    background: var(--gray-300);
  }

  /* --- Service Cards --- */
  .service-card {
    background: var(--white);
    border-color: var(--gray-300);
    color: var(--text-primary);
  }

  .service-card p,
  .service-card div {
    color: var(--text-secondary);
  }

  .service-card--numbered h3 {
    color: var(--primary-color);
  }

  .service-ordinal {
    color: var(--gray-200);
  }

  /* --- Search Form --- */
  .search-form input[type="search"] {
    background: var(--gray-100);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  /* --- WordPress Comments --- */
  .comments-area {
    border-top-color: var(--gray-300);
  }

  .comment-body {
    background: var(--gray-100);
    border-color: var(--gray-300);
  }

  .comment-author {
    color: var(--text-primary);
  }

  .comment-content {
    color: var(--text-secondary);
  }

  .comment-list .children {
    border-left-color: var(--gray-300);
  }

  .comment-reply-link,
  .comments-pagination .page-numbers {
    border-color: var(--gray-300);
  }

  .comment-respond {
    background: var(--gray-100);
    border-color: var(--gray-300);
  }

  .comment-form input[type="text"],
  .comment-form input[type="email"],
  .comment-form input[type="url"],
  .comment-form textarea {
    background: var(--gray-200);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  /* --- WooCommerce Elements --- */
  .woocommerce .product,
  .woocommerce-page .product {
    color: var(--text-primary);
  }

  .woocommerce .price,
  .woocommerce-page .price {
    color: var(--text-primary);
  }

  .woocommerce .quantity .qty {
    background: var(--gray-100);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  .woocommerce table.shop_table {
    border-color: var(--gray-300);
  }

  .woocommerce table.shop_table th,
  .woocommerce table.shop_table td {
    border-color: var(--gray-300);
    color: var(--text-primary);
  }

  .woocommerce table.shop_table tbody tr:nth-child(even) {
    background: var(--gray-100);
  }

  .woocommerce .woocommerce-info,
  .woocommerce .woocommerce-message,
  .woocommerce .woocommerce-error {
    background: var(--gray-100);
    color: var(--text-primary);
    border-top-color: var(--accent-color);
  }

  .woocommerce form .form-row input.input-text,
  .woocommerce form .form-row textarea,
  .woocommerce form .form-row select {
    background: var(--gray-100);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  .woocommerce form .form-row label {
    color: var(--text-primary);
  }

  .woocommerce-cart .cart-collaterals,
  .woocommerce-cart .cart_totals {
    background: var(--white);
    border-color: var(--gray-300);
  }

  .woocommerce nav.woocommerce-pagination ul li a,
  .woocommerce nav.woocommerce-pagination ul li span {
    background: var(--gray-100);
    color: var(--text-primary);
    border-color: var(--gray-300);
  }

  .woocommerce nav.woocommerce-pagination ul li span.current {
    background: var(--primary-fill, var(--primary-color));
    color: var(--text-on-primary-fill, var(--text-on-primary));
  }

  /* --- Widget Areas --- */
  .widget {
    color: var(--text-primary);
  }

  .widget-title {
    color: var(--text-primary);
  }

  /* --- Misc Elements --- */
  abbr[title] {
    text-decoration-color: var(--text-muted);
  }

  mark {
    background: var(--warning-color);
    color: #18181b;
  }

  ::selection {
    background: var(--accent-color);
    color: var(--text-on-accent);
  }
}

/* Footer Login Button Styles */
.footer-login {
  margin-top: 1rem;
}

.login-button {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  text-decoration: none;
  border-radius: var(--border-radius);
  font-size: 0.875rem;
  font-weight: 500;
  transition: var(--transition);
  border: none;
  cursor: pointer;
}

.login-button:hover {
  background: var(--secondary-color);
  color: var(--text-on-secondary);
  text-decoration: none;
}

.login-button.logout-button {
  background: var(--secondary-color);
  color: var(--text-on-secondary);
}

.login-button.logout-button:hover {
  background: var(--accent-color);
  color: var(--text-on-accent);
}

/* Responsive adjustments for login button */
@media (max-width: 768px) {
  .footer-login {
    text-align: center;
  }
}

/* ---------- Customizer FAB (floating action button) ---------- */

.rtsb-customizer-fab {
  position: fixed;
  /* --rtsb-dock lifts every floating button above a bottom bar (the
     Speisekarte cart bar sets it, css/speisekarte.css); 0 elsewhere. */
  bottom: calc(2rem + var(--rtsb-dock, 0px));
  right: 2rem;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent-color);
  color: var(--text-on-accent);
  box-shadow: var(--shadow-lg);
  text-decoration: none;
  transition: var(--transition);
  /* Contrast ring so the FAB is distinguishable from flat accent buttons
     (Weiterlesen / In den Warenkorb) that share the same accent color. */
  border: 2px solid var(--text-on-accent);
  cursor: pointer;
}

.rtsb-customizer-fab:hover {
  background: var(--primary-fill, var(--primary-color));
  color: var(--text-on-primary-fill, var(--text-on-primary));
  border-color: var(--text-on-primary-fill, var(--text-on-primary));
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.rtsb-customizer-fab:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 3px;
}

.rtsb-customizer-fab i {
  font-size: 24px;
  line-height: 1;
}

/* Woo-Merchants floating cart — stack above customizer FAB */
.wm-floating-cart {
  bottom: calc(2rem + 56px + 1rem + var(--rtsb-dock, 0px));
  right: 2rem;
}

/* ---------- About Page Hero ---------- */

.hero-about {
  background: linear-gradient(180deg, var(--primary-fill, var(--primary-color)) 0%, var(--secondary-fill, var(--secondary-color)) 100%);
  min-height: 520px;
}

.hero-grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

.hero-title-accent {
  color: rgba(255, 255, 255, 0.85);
}

.hero-about-cta {
  animation: fadeInUp 0.8s ease-out 0.6s both;
}

/* Inset card — carved-into-page look, no hover lift */
.content-card--inset {
  border-radius: var(--border-radius-sm);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.08), inset 0 0 0 1px var(--gray-200);
  border: none;
  background: var(--gray-50);
}

.content-card--inset::before {
  display: none;
}

.content-card--inset:hover {
  transform: none;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.08), inset 0 0 0 1px var(--gray-200);
}

.content-card--inset:focus-within {
  transform: none;
}

@media (max-width: 768px) {
  .hero-about {
    min-height: 400px;
  }
}

@media (max-width: 480px) {
  .hero-about {
    min-height: 350px;
  }
}

/* ========== WOOCOMMERCE BLOCKS — CART & CHECKOUT ========== */

/* --- Shared Container --- */
.wc-block-cart,
.wc-block-checkout {
  --wp--custom--woocommerce--font-size: var(--font-size-base);
  color: var(--text-primary);
}

.wp-block-woocommerce-cart,
.wp-block-woocommerce-checkout {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
}

/* Quantity lock display for UID-bound subscription cart items */
.rtsb-quantity-locked {
  display: inline-block;
  min-width: 2em;
  padding: 0.25em 0.5em;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  color: var(--text-secondary);
  text-align: center;
  font-variant-numeric: tabular-nums;
  cursor: not-allowed;
}

/* Page titles */
.wc-block-cart .wp-block-heading,
.wc-block-checkout .wp-block-heading,
.woocommerce-cart .wp-block-heading,
.woocommerce-checkout .wp-block-heading {
  font-family: var(--font-heading);
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: var(--space-xl);
}

/* --- Form Inputs (Checkout) --- */
.wc-block-checkout input[type="text"],
.wc-block-checkout input[type="email"],
.wc-block-checkout input[type="tel"],
.wc-block-checkout input[type="number"],
.wc-block-checkout input[type="password"],
.wc-block-checkout input[type="url"],
.wc-block-checkout textarea,
.wc-block-checkout select,
.wc-block-checkout .wc-block-components-text-input input,
.wc-block-checkout .wc-block-components-textarea,
.wc-block-checkout .wc-block-components-combobox .components-combobox-control input,
.wc-block-components-text-input input,
.wc-block-components-textarea {
  background: var(--gray-50) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  padding: 0.75rem 1rem !important;
  font-size: var(--font-size-base) !important;
  font-family: var(--font-body) !important;
  transition: var(--transition) !important;
}

.wc-block-checkout input:focus,
.wc-block-checkout select:focus,
.wc-block-checkout textarea:focus,
.wc-block-components-text-input input:focus {
  border-color: var(--accent-color) !important;
  box-shadow: var(--focus-ring) !important;
  outline: none !important;
}

/* Floating labels */
.wc-block-components-text-input label,
.wc-block-components-combobox .components-base-control__label {
  color: var(--text-muted) !important;
  font-family: var(--font-body) !important;
  font-size: var(--font-size-sm) !important;
}

/* A filled or focused field shows its label small above the value. WC Blocks
   makes room for it with its own top padding; the even padding of the rule
   above put the label on top of what was typed ("Vorname" over the name,
   "Land/Region" over the country). Keep the theme's side padding, give the
   label its row back and line it up with the value. */
.wc-block-components-text-input.is-active input[type],
.wc-block-checkout .wc-block-components-text-input.is-active input[type],
.wc-block-components-text-input input[type]:-webkit-autofill,
.wc-block-checkout .wc-block-components-text-input input[type]:-webkit-autofill {
  padding: 24px 1rem 8px !important;
}

.wc-blocks-components-select .wc-blocks-components-select__select {
  padding: 16px 2.5rem 0 1rem !important;
}

.wc-block-components-text-input label,
.wc-blocks-components-select .wc-blocks-components-select__label {
  left: calc(1rem + 1px) !important;
  max-width: calc(100% - 2rem - 2px) !important;
}

/* The arrow of the select ships a fixed dark grey: invisible in dark mode. */
.wc-blocks-components-select .wc-blocks-components-select__expand {
  fill: var(--text-primary);
}

/* Select / Combobox dropdowns */
.wc-block-checkout .wc-block-components-combobox .components-combobox-control input,
.wc-block-checkout select {
  background: var(--gray-50) !important;
  color: var(--text-primary) !important;
}

.components-popover__content,
.wc-block-components-combobox__menu {
  background: var(--white) !important;
  border: 1px solid var(--gray-200) !important;
  border-radius: var(--border-radius) !important;
  box-shadow: var(--shadow-lg) !important;
}

.components-popover__content li,
.wc-block-components-combobox__menu li {
  color: var(--text-primary) !important;
  padding: 0.5rem 1rem !important;
}

.components-popover__content li:hover,
.wc-block-components-combobox__menu li:hover,
.components-popover__content li[aria-selected="true"],
.wc-block-components-combobox__menu li[aria-selected="true"] {
  background: var(--gray-100) !important;
}

/* --- Section Headings (Contact info, Billing, Payment) --- */
.wc-block-checkout .wc-block-components-checkout-step__heading,
.wc-block-checkout .wc-block-components-title,
.wc-block-components-checkout-step__title {
  font-family: var(--font-heading) !important;
  color: var(--text-primary) !important;
  font-weight: 600 !important;
  font-size: var(--font-size-xl) !important;
}

.wc-block-checkout .wc-block-components-checkout-step__description,
.wc-block-components-checkout-step__description {
  color: var(--text-muted) !important;
  font-size: var(--font-size-sm) !important;
}

/* Step container with left border accent */
.wc-block-components-checkout-step {
  border-left: 3px solid var(--gray-200) !important;
  padding-left: var(--space-lg) !important;
  margin-bottom: var(--space-xl) !important;
}

.wc-block-components-checkout-step--with-step-number .wc-block-components-checkout-step__container::after {
  border-color: var(--gray-200) !important;
}

/* --- Order Summary Sidebar --- */
.wc-block-components-order-summary,
.wc-block-checkout__sidebar {
  background: var(--white) !important;
  border: 1px solid var(--gray-200) !important;
  border-radius: var(--border-radius-lg) !important;
  padding: var(--space-xl) !important;
  box-shadow: var(--shadow-sm) !important;
}

.wc-block-components-order-summary .wc-block-components-order-summary__button-text,
.wc-block-components-order-summary-item__description {
  color: var(--text-primary) !important;
}

.wc-block-components-order-summary-item__quantity {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  box-shadow: none !important;
}

/* The badge text is a span: the broad dark-mode `body span` rule would
   flip it light on the light accent. Keep the badge's own ink. */
.wc-block-components-order-summary-item__quantity span,
body .wc-block-components-order-summary-item__quantity span {
  color: var(--text-on-accent) !important;
}

/* --- Dark-mode readability audit (t1822) --------------------------------
   Every rule below is token-driven, so it holds in both schemes; the
   !important on color is needed to beat the broad dark-mode text overrides
   at the top of this file. */

/* WooCommerce breadcrumb ships #767676: below AA on the tinted papers and
   on the dark canvas. */
body .woocommerce-breadcrumb,
body .woocommerce-breadcrumb a {
  color: var(--text-secondary) !important;
}

body .woocommerce-breadcrumb a:hover {
  color: var(--accent-color) !important;
}

/* WC Blocks native selects (country / state) keep a white background from
   the blocks stylesheet while the text goes light in dark mode. */
body .wc-blocks-components-select__container,
body .wc-blocks-components-select__select,
body .wc-block-components-country-input select,
body .wc-block-components-state-input select {
  background-color: var(--white) !important;
  color: var(--text-primary) !important;
  color-scheme: light dark;
}

body .wc-blocks-components-select__label {
  color: var(--text-secondary) !important;
}

/* Stripe's "Test Mode" pill has a fixed pale-amber background. */
body .wc-stripe-test-mode-badge {
  color: #4a3600 !important;
}

/* Highlighted (checked) payment option: WC paints it in the accent with the
   default black text; use a soft accent tint with the theme ink instead. */
body .wc-block-components-radio-control--highlight-checked .wc-block-components-radio-control-accordion-option--checked-option-highlighted,
body .wc-block-components-radio-control--highlight-checked .wc-block-components-radio-control__option-checked {
  background: color-mix(in srgb, var(--accent-color) 12%, var(--white)) !important;
  color: var(--text-primary) !important;
}

/* Native and Blocks checkboxes / radios follow the brand colour. */
body input[type="checkbox"],
body input[type="radio"],
body .wc-block-components-checkbox__input {
  accent-color: var(--primary-color);
  color: var(--text-primary);
}

/* woo-merchants floating cart: the count bubble ships red with white text
   (3.4:1). Ink-on-paper reads in both schemes. */
body .wm-floating-cart .wm-floating-cart-count {
  background: var(--text-primary) !important;
  color: var(--white) !important;
}

/* woo-merchants partner code "apply" button ships a fixed pink. */
body .wm-vp-code-row .wm-vp-code-apply,
body .wm-vp-code-row button {
  background: var(--primary-fill, var(--primary-color)) !important;
  border-color: var(--primary-color) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
}

.wc-block-components-order-summary-item__individual-price,
.wc-block-components-order-summary-item__total-price {
  color: var(--text-primary) !important;
}

/* Order summary product image */
.wc-block-components-order-summary-item__image img {
  border-radius: var(--border-radius-sm) !important;
  border: 1px solid var(--gray-200) !important;
}

/* --- Totals & Subtotals --- */
.wc-block-components-totals-wrapper,
.wc-block-components-totals-item {
  border-color: var(--gray-200) !important;
}

.wc-block-components-totals-item__label {
  color: var(--text-primary) !important;
  font-family: var(--font-body) !important;
}

.wc-block-components-totals-item__value {
  color: var(--text-primary) !important;
  font-weight: 600 !important;
}

.wc-block-components-totals-footer-item .wc-block-components-totals-item__label,
.wc-block-components-totals-footer-item .wc-block-components-totals-item__value {
  font-family: var(--font-heading) !important;
  font-size: var(--font-size-xl) !important;
  font-weight: 700 !important;
  color: var(--text-primary) !important;
}

/* --- Coupons --- */
.wc-block-components-totals-coupon__button {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  border-radius: var(--border-radius) !important;
  font-weight: 600 !important;
  transition: var(--transition) !important;
}

.wc-block-components-totals-coupon__button:hover {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
}

.wc-block-components-totals-coupon-link {
  color: var(--accent-color) !important;
}

/* --- Payment Options --- */
.wc-block-components-radio-control__option,
.wc-block-components-payment-method-label {
  color: var(--text-primary) !important;
}

.wc-block-components-radio-control__input {
  border-color: var(--gray-300) !important;
}

.wc-block-components-radio-control__input:checked {
  border-color: var(--accent-color) !important;
  background: var(--accent-color) !important;
}

/* Notice / error banner */
.wc-block-components-notice-banner {
  background: var(--gray-50) !important;
  color: var(--text-primary) !important;
  border-radius: var(--border-radius) !important;
  border: 1px solid var(--gray-200) !important;
  border-left: 4px solid var(--error-color) !important;
}

.wc-block-components-notice-banner.is-error {
  border-left-color: var(--error-color) !important;
}

.wc-block-components-notice-banner.is-success {
  border-left-color: var(--success-color) !important;
}

.wc-block-components-notice-banner.is-info {
  border-left-color: var(--accent-color) !important;
}

/* --- Checkout Place Order Button --- */
.wc-block-checkout__actions .wc-block-components-checkout-place-order-button,
.wc-block-components-checkout-place-order-button,
.wc-block-cart__submit-button .wc-block-components-button,
.wc-block-components-button.wp-element-button,
.wp-block-woocommerce-proceed-to-checkout-block a,
.wc-block-cart__submit-button a.wc-block-components-button {
  background: var(--accent-color) !important;
  color: var(--text-on-accent) !important;
  border: none !important;
  border-radius: var(--border-radius) !important;
  padding: 0.875rem 2rem !important;
  font-family: var(--font-heading) !important;
  font-weight: 600 !important;
  font-size: var(--font-size-base) !important;
  cursor: pointer !important;
  transition: var(--transition) !important;
  text-decoration: none !important;
  display: inline-block !important;
  text-align: center !important;
}

/* Ensure button child elements (spans, etc.) inherit the correct text color */
.wc-block-components-checkout-place-order-button *,
.wc-block-cart__submit-button .wc-block-components-button *,
.wc-block-components-button.wp-element-button *,
.wp-block-woocommerce-proceed-to-checkout-block a * {
  color: inherit !important;
}

.wc-block-checkout__actions .wc-block-components-checkout-place-order-button:hover,
.wc-block-components-checkout-place-order-button:hover,
.wc-block-cart__submit-button .wc-block-components-button:hover,
.wc-block-components-button.wp-element-button:hover,
.wp-block-woocommerce-proceed-to-checkout-block a:hover,
.wc-block-cart__submit-button a.wc-block-components-button:hover {
  background: var(--primary-fill, var(--primary-color)) !important;
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
  transform: translateY(-1px) !important;
  box-shadow: var(--shadow-md) !important;
  text-decoration: none !important;
}

/* Return to cart link */
.wc-block-checkout__actions .wc-block-components-checkout-return-to-cart-button {
  color: var(--accent-color) !important;
  font-weight: 500 !important;
  text-decoration: none !important;
  transition: var(--transition) !important;
}

.wc-block-checkout__actions .wc-block-components-checkout-return-to-cart-button:hover {
  color: var(--primary-color) !important;
  text-decoration: underline !important;
}

/* --- Cart Page --- */

/* Cart items table header */
.wc-block-cart-items .wc-block-cart-items__header {
  color: var(--text-muted) !important;
  font-family: var(--font-heading) !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  font-size: var(--font-size-xs) !important;
  letter-spacing: var(--letter-spacing-wider) !important;
  border-bottom: 2px solid var(--gray-200) !important;
}

.wc-block-cart-items .wc-block-cart-items__header span {
  color: var(--text-muted) !important;
}

/* Cart item rows */
.wc-block-cart-items .wc-block-cart-items__row {
  border-bottom: 1px solid var(--gray-200) !important;
  padding: var(--space-lg) 0 !important;
}

/* Cart product name */
.wc-block-cart-item__product .wc-block-components-product-name {
  color: var(--accent-color) !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  font-size: var(--font-size-lg) !important;
}

.wc-block-cart-item__product .wc-block-components-product-name:hover {
  color: var(--primary-color) !important;
  text-decoration: underline !important;
}

/* Cart product image */
.wc-block-cart-item__image img {
  border-radius: var(--border-radius) !important;
  border: 1px solid var(--gray-200) !important;
}

/* Cart product price */
.wc-block-cart-item__total .wc-block-components-product-price,
.wc-block-cart-item__product .wc-block-components-product-price {
  color: var(--text-primary) !important;
  font-weight: 600 !important;
}

/* Cart product metadata (description) */
.wc-block-cart-item__product .wc-block-components-product-metadata {
  color: var(--text-muted) !important;
  font-size: var(--font-size-sm) !important;
}

/* Quantity selector */
.wc-block-components-quantity-selector {
  border: 1px solid var(--gray-300) !important;
  border-radius: var(--border-radius) !important;
  overflow: hidden !important;
}

.wc-block-components-quantity-selector input.wc-block-components-quantity-selector__input {
  background: var(--gray-50) !important;
  color: var(--text-primary) !important;
  border: none !important;
  font-weight: 600 !important;
}

.wc-block-components-quantity-selector .wc-block-components-quantity-selector__button {
  background: var(--gray-100) !important;
  color: var(--text-primary) !important;
  border: none !important;
  transition: var(--transition-fast) !important;
}

.wc-block-components-quantity-selector .wc-block-components-quantity-selector__button:hover {
  background: var(--gray-200) !important;
}

/* Remove item link */
.wc-block-cart-item__remove-link {
  color: var(--error-color) !important;
  font-size: var(--font-size-sm) !important;
  text-decoration: none !important;
  transition: var(--transition) !important;
}

.wc-block-cart-item__remove-link:hover {
  color: var(--text-primary) !important;
  text-decoration: underline !important;
}

/* Cart totals sidebar */
.wc-block-cart__totals-title {
  font-family: var(--font-heading) !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  font-size: var(--font-size-xs) !important;
  letter-spacing: var(--letter-spacing-wider) !important;
  color: var(--text-muted) !important;
}

.wp-block-woocommerce-cart-totals-block {
  background: var(--white) !important;
  border: 1px solid var(--gray-200) !important;
  border-radius: var(--border-radius-lg) !important;
  padding: var(--space-xl) !important;
  box-shadow: var(--shadow-sm) !important;
}

/* --- Checkbox & Terms --- */
.wc-block-checkout .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"] {
  border-color: var(--gray-300) !important;
  border-radius: 4px !important;
  background: var(--gray-50) !important;
}

.wc-block-checkout .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:checked {
  background: var(--accent-color) !important;
  border-color: var(--accent-color) !important;
}

.wc-block-checkout .wc-block-components-checkbox__label,
.wc-block-checkout__terms {
  color: var(--text-muted) !important;
  font-size: var(--font-size-sm) !important;
}

.wc-block-checkout__terms a {
  color: var(--accent-color) !important;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .wp-block-woocommerce-cart,
  .wp-block-woocommerce-checkout {
    padding: var(--space-lg) var(--space-md);
  }

  .wc-block-components-order-summary,
  .wc-block-checkout__sidebar,
  .wp-block-woocommerce-cart-totals-block {
    margin-top: var(--space-xl) !important;
  }
}

/* ============================================================
   Per-layout personality overrides
   Each landing-page layout gets a distinct typographic and
   structural identity via body.layout-{slug} scoping. Those
   rules live in css/layouts/{slug}.css (one file per layout,
   registry in inc/layouts.php); only the active layout's file
   is enqueued, right after this stylesheet, so it still wins
   the cascade against the shared landing styles above.
   Never add body.layout-* rules here.
   ============================================================ */

/* =========================================================================
   Companion pages — About + Contact pick up the active layout's typography.
   Each layout block above declares a set of common-name aliases
   (--page-display, --page-body, --page-ink, --page-paper, --page-muted,
   --page-accent, --page-rule) that point at its own scoped vars. This
   single block consumes those aliases so the standalone /about and
   /contact pages adopt the same fonts and palette as the homepage hero,
   without each layout having to repeat the rules.
   ========================================================================= */
body[class*="layout-"] .hero-section.hero-about {
  background: var(--page-paper);
  color: var(--page-ink);
}

body[class*="layout-"] .hero-section.hero-about .hero-badge {
  font-family: var(--page-display);
  color: var(--page-ink);
}

body[class*="layout-"] .hero-section.hero-about .hero-title {
  font-family: var(--page-display);
  color: var(--page-ink);
}

body[class*="layout-"] .hero-section.hero-about .hero-title-accent {
  color: var(--page-accent);
}

body[class*="layout-"] .hero-section.hero-about .hero-subtitle {
  font-family: var(--page-body);
  color: var(--page-muted);
}

body[class*="layout-"] .hero-section.hero-about .hero-about-cta .cta-button.cta-primary {
  font-family: var(--page-display);
}

body[class*="layout-"] .content-card.content-card--inset {
  background: transparent;
  backdrop-filter: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: var(--space-2xl) 0 0;
  margin-bottom: var(--space-2xl);
  animation: none;
  overflow: visible;
}

body[class*="layout-"] .content-card.content-card--inset::before {
  display: none;
}

body[class*="layout-"] .content-card.content-card--inset:hover,
body[class*="layout-"] .content-card.content-card--inset:focus-within {
  background: transparent;
  box-shadow: none;
  transform: none;
  border-color: transparent;
}

/* Single posts — strip the white card so the article sits on the page background */
body.single .post-content > article {
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: var(--space-lg) 0 0;
}

/* Breadcrumb on single posts — match the product page rhythm */
body.single .post-content > .rtsb-breadcrumb {
  margin: 0 0 var(--space-md);
  font-size: 0.95rem;
  color: var(--text-secondary);
}

body.single .post-content > .rtsb-breadcrumb a {
  color: var(--text-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

body.single .post-content > .rtsb-breadcrumb a:hover {
  color: var(--accent-color);
}

body.single .post-content > .rtsb-breadcrumb .rtsb-breadcrumb-sep {
  margin: 0 0.4em;
  color: var(--text-muted, var(--text-secondary));
}

body.single .post-content > .rtsb-breadcrumb .rtsb-breadcrumb-current {
  color: var(--text-primary);
}

body.single .post-content > article:hover {
  box-shadow: none;
  transform: none;
}

body[class*="layout-"] .content-card.content-card--inset .entry-header h1 {
  font-family: var(--page-display);
  color: var(--page-ink);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content {
  font-family: var(--page-body);
  color: var(--page-ink);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content h1,
body[class*="layout-"] .content-card.content-card--inset .entry-content h2,
body[class*="layout-"] .content-card.content-card--inset .entry-content h3,
body[class*="layout-"] .content-card.content-card--inset .entry-content h4 {
  font-family: var(--page-display);
  color: var(--page-ink);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content p,
body[class*="layout-"] .content-card.content-card--inset .entry-content li {
  font-family: var(--page-body);
  color: color-mix(in srgb, var(--page-ink) 85%, transparent);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content a {
  color: var(--page-accent);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content strong {
  color: var(--page-ink);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content blockquote {
  border-left-color: var(--page-accent);
  color: var(--page-muted);
  font-family: var(--page-body);
}

body[class*="layout-"] .content-card.content-card--inset .entry-content code {
  font-family: var(--page-mono, ui-monospace, SFMono-Regular, Menlo, monospace);
  background: color-mix(in srgb, var(--page-ink) 8%, transparent);
  color: var(--page-ink);
}

/* Contact page — labeled entries */
body[class*="layout-"] .entry-content.contact-page p {
  font-family: var(--page-body);
  color: var(--page-ink);
}

body[class*="layout-"] .entry-content.contact-page p strong {
  font-family: var(--page-body);
  color: var(--page-muted);
  font-weight: 600;
  letter-spacing: 0.02em;
}

body[class*="layout-"] .entry-content.contact-page a {
  color: var(--page-ink);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  font-family: var(--page-body);
  font-weight: 500;
}

body[class*="layout-"] .entry-content.contact-page a:hover {
  color: var(--page-accent);
}

body[class*="layout-"] .entry-content.contact-page .contact-map {
  border: 1px solid var(--page-rule);
  border-radius: 4px;
  overflow: hidden;
}

/* Contact page: the people come first, in open rows with a large phone
   number; company, address and the general addresses follow as a quiet
   block; the map stands beside all of it from tablet-landscape up. On phones
   the order is the markup's: heading, people, details, map. */
body[class*="layout-"] .entry-content.contact-page .contact-page__head h1,
.entry-content.contact-page .contact-page__head h1 {
  margin: 0;
  font-family: var(--page-display, inherit);
  font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--page-ink, var(--text-primary));
}

body .entry-content.contact-page .contact-intro {
  max-width: 34rem;
  margin-top: 1rem;
  font-size: 1.125rem;
  line-height: 1.55;
}

body .entry-content.contact-page .contact-intro p {
  margin: 0;
  color: var(--page-muted, var(--text-secondary)) !important;
}

/* An address or a mail address never breaks with a hyphen: "rot-hirsch.tech"
   reads as another domain. */
.entry-content.contact-page a,
.entry-content.contact-page .contact-company {
  hyphens: manual;
  -webkit-hyphens: manual;
}

/* People: rows divided by a hairline, no boxes */
.entry-content.contact-page .contact-people {
  container-type: inline-size;
  margin: clamp(2rem, 5vw, 3.25rem) 0 0;
}

.entry-content.contact-page .contact-people .contact-people__heading {
  margin: 0 0 0.25rem;
  font-family: var(--page-body, inherit);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--page-muted, var(--text-secondary)) !important;
}

.entry-content.contact-page .contact-people .contact-people__list {
  display: block;
}

.entry-content.contact-page .contact-people .contact-person {
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem 0;
  border: 0;
  border-bottom: 1px solid var(--page-rule, var(--gray-200));
  border-radius: 0;
  background: none;
}

.entry-content.contact-page .contact-people .contact-person__photo {
  width: 76px;
  height: 76px;
}

body .entry-content.contact-page .contact-people .contact-person__name {
  font-size: 1.25rem;
  line-height: 1.25;
}

body .entry-content.contact-page .contact-people .contact-person__role {
  font-size: 0.9375rem;
}

.entry-content.contact-page .contact-people .contact-people__list .contact-person a.contact-person__link {
  min-height: 0;
  margin-top: 0.6rem;
  padding: 0.2rem 0;
}

/* The phone number is what a caller looks for: large, steady digits */
body .entry-content.contact-page .contact-people a.contact-person__link[href^="tel:"] .contact-person__link-text {
  font-size: 1.3125rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  white-space: nowrap;
  text-decoration: none;
}

body .entry-content.contact-page .contact-people a.contact-person__link[href^="tel:"]:hover .contact-person__link-text,
body .entry-content.contact-page .contact-people a.contact-person__link[href^="tel:"]:focus-visible .contact-person__link-text {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  text-decoration-color: var(--accent-color);
}

body .entry-content.contact-page .contact-people a.contact-person__link[href^="mailto:"] .contact-person__link-text {
  text-decoration-color: var(--accent-color);
}

/* With room, name and role stand left and the ways to reach the person right */
@container (min-width: 30rem) {
  .entry-content.contact-page .contact-people .contact-person__body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 14rem);
    grid-auto-flow: row dense;
    gap: 0.35rem 1.5rem;
    align-items: baseline;
  }

  .entry-content.contact-page .contact-people .contact-person__name,
  .entry-content.contact-page .contact-people .contact-person__role {
    grid-column: 1;
  }

  .entry-content.contact-page .contact-people .contact-people__list .contact-person a.contact-person__link {
    grid-column: 2;
    justify-self: start;
    margin-top: 0;
    padding: 0;
    align-items: baseline;
  }
}

/* Company, address and the general addresses */
.entry-content.contact-page .contact-page__details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
  gap: 1.75rem 2.5rem;
  margin-top: clamp(2rem, 5vw, 3rem);
}

.entry-content.contact-page > .contact-page__head + .contact-page__details {
  margin-top: clamp(1.5rem, 4vw, 2.5rem);
}

body .entry-content.contact-page .contact-page__details p {
  margin: 0;
  font-size: 1.0625rem;
  line-height: 1.55;
}

/* The label sits as a small line above its value */
body .entry-content.contact-page .contact-page__details p strong {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.9375rem;
  letter-spacing: 0;
}

.entry-content.contact-page .contact-address strong + br {
  display: none;
}

body .entry-content.contact-page .contact-company {
  display: block;
  font-weight: 600;
}

.entry-content.contact-page .address-navigation-link::after {
  content: none;
}

body[class*="layout-"] .entry-content.contact-page .contact-page__details a,
.entry-content.contact-page .contact-page__details a {
  color: var(--page-ink, var(--text-primary));
  text-decoration-color: var(--accent-color);
}

/* Map */
body[class*="layout-"] .entry-content.contact-page .contact-map,
.entry-content.contact-page .contact-map {
  margin-top: 2.5rem;
  border: 1px solid var(--page-rule, var(--gray-200));
  border-radius: calc(var(--border-radius) * 2);
  overflow: hidden;
  background: var(--gray-100);
}

.entry-content.contact-page .contact-map iframe {
  height: 340px;
  border: 0 !important;
  filter: grayscale(0.35) contrast(1.02);
}

/* A night map on a dark page: the tiles are inverted, the hue turned back
   so that water stays blue and woods stay green */
@media (prefers-color-scheme: dark) {
  .entry-content.contact-page .contact-map iframe {
    filter: invert(1) hue-rotate(180deg) grayscale(0.45) brightness(0.92) contrast(0.88);
  }
}

@media (min-width: 960px) {
  .entry-content.contact-page--with-map {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    grid-template-areas:
      "head map"
      "people map"
      "details map";
    grid-template-rows: auto auto 1fr;
    column-gap: clamp(2.5rem, 5vw, 5rem);
  }

  .entry-content.contact-page--with-map .contact-page__head {
    grid-area: head;
  }

  .entry-content.contact-page--with-map .contact-people {
    grid-area: people;
  }

  .entry-content.contact-page--with-map .contact-page__details {
    grid-area: details;
  }

  body[class*="layout-"] .entry-content.contact-page--with-map .contact-map,
  .entry-content.contact-page--with-map .contact-map {
    grid-area: map;
    align-self: start;
    position: sticky;
    top: 6rem;
    margin-top: 0.5rem;
  }

  .entry-content.contact-page--with-map .contact-map iframe {
    height: clamp(420px, 70vh, 640px);
  }
}

/* Useful-links panel — shown on the create-post page beneath the editor.
   Inherits the active layout's page tokens so it sits comfortably under the
   post form on any layout. Each link reads as a title + one-line hint. */
body[class*="layout-"] .useful-links-card {
  margin-top: 1.5rem;
}

body[class*="layout-"] .useful-links-card .useful-links-title {
  font-family: var(--page-display);
  color: var(--page-ink);
  margin: 0 0 0.35rem;
}

body[class*="layout-"] .useful-links-card .useful-links-intro {
  font-family: var(--page-body);
  color: var(--page-muted);
  margin: 0 0 1rem;
}

body[class*="layout-"] .useful-links-card .useful-links-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

body[class*="layout-"] .useful-links-card .useful-links-link {
  display: block;
  padding: 0.85rem 1rem;
  border: 1px solid var(--page-rule);
  border-radius: 6px;
  text-decoration: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

body[class*="layout-"] .useful-links-card .useful-links-link:hover,
body[class*="layout-"] .useful-links-card .useful-links-link:focus-visible {
  border-color: var(--page-accent);
  background: color-mix(in srgb, var(--page-accent) 8%, transparent);
}

body[class*="layout-"] .useful-links-card .useful-links-link-title {
  display: block;
  font-family: var(--page-body);
  font-weight: 600;
  color: var(--page-ink);
}

body[class*="layout-"] .useful-links-card .useful-links-link-desc {
  display: block;
  font-family: var(--page-body);
  font-size: 0.9rem;
  line-height: 1.4;
  color: color-mix(in srgb, var(--page-ink) 70%, transparent);
}

/* =========================================================================
   Companion pages — Blog + Shop pick up the active layout's typography.
   Same mechanism as the About + Contact block above: consume the common-name
   aliases each layout declares (--page-display, --page-body, --page-ink,
   --page-paper, --page-muted, --page-accent, --page-rule) so the posts
   archive / single posts and the WooCommerce shop / product pages adopt the
   homepage's fonts and palette. Fallbacks cover layouts that don't define the
   aliases (e.g. person, which styles the body directly via --person-* vars).
   Typography + color + canvas only — no structural grid changes.
   ========================================================================= */
body[class*="layout-"].blog,
body[class*="layout-"].archive,
body[class*="layout-"].search,
body[class*="layout-"].single-post,
body[class*="layout-"].woocommerce,
body[class*="layout-"].woocommerce-page {
  background: var(--page-paper, var(--gray-50));
  color: var(--page-ink, var(--text-primary));
}

/* These content pages have no hero, so .site-main (which is flush by design for
   landing-page heroes) needs vertical breathing room between the header and the
   footer. Landing-page bodies are not matched here, so their heroes stay flush. */
body[class*="layout-"].blog .site-main,
body[class*="layout-"].archive .site-main,
body[class*="layout-"].search .site-main,
body[class*="layout-"].single-post .site-main,
body[class*="layout-"].woocommerce .site-main,
body[class*="layout-"].woocommerce-page .site-main {
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-3xl);
}

/* Archive / shop page heading */
body[class*="layout-"] .page-title,
body[class*="layout-"] .woocommerce-products-header__title,
body[class*="layout-"] .archive-title,
body[class*="layout-"] .blog-page-title {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"] .archive-description,
body[class*="layout-"] .term-description,
body[class*="layout-"] .woocommerce-products-header .term-description {
  font-family: var(--page-body, var(--font-body));
  color: var(--page-muted, var(--text-secondary));
}

/* --- Blog post cards (archive / index) --- */
body[class*="layout-"] .post-list article.clickable-card {
  border: 1px solid var(--page-rule, var(--border-color));
}

body[class*="layout-"] .post-list .entry-title,
body[class*="layout-"] .post-list .entry-title a {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"] .post-list .entry-meta {
  font-family: var(--page-body, var(--font-body));
  color: var(--page-muted, var(--text-secondary));
}

body[class*="layout-"] .post-list .excerpt-content {
  font-family: var(--page-body, var(--font-body));
  color: color-mix(in srgb, var(--page-ink, var(--text-primary)) 85%, transparent);
}

/* Read-more is a filled accent button — only restyle the font, never the
   label color (base keeps --text-on-accent for a WCAG-safe contrast). */
body[class*="layout-"] .post-list .read-more-link {
  font-family: var(--page-display, var(--font-display));
}

/* --- Single post body --- */
body[class*="layout-"].single-post .entry-title {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"].single-post .entry-content {
  font-family: var(--page-body, var(--font-body));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"].single-post .entry-content h1,
body[class*="layout-"].single-post .entry-content h2,
body[class*="layout-"].single-post .entry-content h3,
body[class*="layout-"].single-post .entry-content h4 {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"].single-post .entry-content a {
  color: var(--page-accent, var(--accent-color));
}

body[class*="layout-"].single-post .entry-meta {
  font-family: var(--page-body, var(--font-body));
  color: var(--page-muted, var(--text-secondary));
}

/* --- WooCommerce product cards --- */
/* Storefront cards bring their own boutique surface (see .storefront-product-card)
   so they opt out of this faint generic border. */
body[class*="layout-"] .products .rtsb-product-card:not(.storefront-product-card) {
  border: 1px solid var(--page-rule, var(--border-color));
}

body[class*="layout-"] .products .rtsb-product-title {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"] .products .rtsb-product-price {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"] .products .rtsb-product-excerpt {
  font-family: var(--page-body, var(--font-body));
  color: color-mix(in srgb, var(--page-ink, var(--text-primary)) 85%, transparent);
}

/* --- Single product --- */
body[class*="layout-"].single-product .product_title {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"].single-product div.product .price {
  font-family: var(--page-display, var(--font-display));
  color: var(--page-ink, var(--text-primary));
}

body[class*="layout-"].single-product .woocommerce-product-details__short-description,
body[class*="layout-"].single-product .woocommerce-Tabs-panel {
  font-family: var(--page-body, var(--font-body));
  color: var(--page-ink, var(--text-primary));
}

/* WooCommerce product-card rating row */
.rtsb-product-card .rtsb-product-rating {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.35rem 0 0.1rem;
}

/* Match the count text instead of the card heading: solid white stars at
   ~15px read as heavy foreign blocks between title and price. Accent colour
   + count-sized glyphs turn them into a quiet metadata row alongside the
   "(1)". Selector depth is deliberate: WooCommerce core sets the size via
   `.woocommerce ul.products li.product .star-rating` (0,4,2), which beat
   the previous shorter selector. The colour carries !important because the
   broad dark-mode `body span { color … !important }` override repaints the
   glyphs light gray otherwise — same fight as the login notices. */
/* No body prefix here: .woocommerce is the BODY itself on archive pages, so
   `body .woocommerce` would demand a descendant and never match. */
.woocommerce ul.products li.product.rtsb-product-card .rtsb-product-rating .star-rating {
  font-size: 0.82rem;
  margin: 0;
}

body .rtsb-product-card .rtsb-product-rating .star-rating,
body .rtsb-product-card .rtsb-product-rating .star-rating span {
  color: var(--accent-color, #941c2f) !important;
}

.rtsb-product-card .rtsb-product-rating-count {
  font-size: 0.82rem;
  opacity: 0.7;
  line-height: 1;
}

/* =========================================================================
   Hero description band — an optional short page description rendered in its
   own paper area directly below the hero (functions.php emits it only when the
   rtsb_homepage_hero_description field is non-empty). The hero subtitle stays
   on the image; this is separate intro copy. Picks up the active layout's
   --page-* aliases (same mechanism as the companion blocks), with fallbacks
   for layouts that don't declare them.
   ========================================================================= */
.hero-description-band {
  background: var(--page-paper, var(--gray-50));
  padding: clamp(1.75rem, 4vw, 3rem) clamp(1.25rem, 4vw, 2.5rem);
}

/* Customizer-only placeholder so the edit pencil stays clickable when the
   description field is empty (the band is not emitted on the front-end). */
.hero-description-band--empty {
  min-height: 4rem;
}

.hero-description-band__inner {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.hero-description-band .hero-description {
  color: var(--page-muted, var(--text-secondary));
  font-family: var(--page-body, var(--font-body));
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  line-height: var(--line-height-relaxed);
}

/* Markdown block children (rtsb_theme_parse_markdown output). Flow spacing
   between blocks, but the band itself owns the outer padding. */
.hero-description-band .hero-description > * {
  margin-top: 0;
  margin-bottom: 0.75em;
}

.hero-description-band .hero-description > *:last-child {
  margin-bottom: 0;
}

.hero-description-band .hero-description h1,
.hero-description-band .hero-description h2,
.hero-description-band .hero-description h3,
.hero-description-band .hero-description h4 {
  color: var(--page-ink, var(--text-primary));
  font-family: var(--page-display, var(--font-display));
  line-height: var(--line-height-tight);
}

.hero-description-band .hero-description a {
  color: var(--page-accent, var(--accent-color));
}

/* Lists read better left-aligned even inside the centered band. */
.hero-description-band .hero-description ul,
.hero-description-band .hero-description ol {
  display: inline-block;
  text-align: left;
  padding-left: 1.25rem;
  margin-left: auto;
  margin-right: auto;
}

.hero-description-band .hero-description blockquote {
  border-left: 3px solid var(--page-rule, var(--border-color));
  padding-left: 1rem;
  text-align: left;
}

.hero-description-band .hero-description code {
  font-family: var(--font-mono, monospace);
  font-size: 0.9em;
}

/* ============================================================================
   Clickable metric tiles (Kennzahlen with optional links)
   ----------------------------------------------------------------------------
   The anchor wraps the existing metric/card markup. `display: contents` keeps
   the parent flex/grid layout intact while still allowing the anchor to be
   interactive (clickable, focusable). Hover/focus styles are applied to the
   inner tile element.
   ========================================================================= */
a.metric-link {
  display: contents;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}
a.metric-link > .metric-item,
a.metric-link > .person-metric,
a.metric-link > .tf-price-card {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
a.metric-link:hover > .metric-item,
a.metric-link:hover > .person-metric,
a.metric-link:hover > .tf-price-card {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
a.metric-link:focus-visible {
  outline: none;
}
a.metric-link:focus-visible > .metric-item,
a.metric-link:focus-visible > .person-metric,
a.metric-link:focus-visible > .tf-price-card {
  outline: 2px solid var(--primary-color, currentColor);
  outline-offset: 3px;
}

/* =============================================================================
   Post 2 Wordpress – Post to Social dashboard ([p2w_social_dashboard])
   -----------------------------------------------------------------------------
   The plugin ships a neutral light-only stylesheet (white cards, grey labels).
   On the dark colour schemes the theme's broad `body span/div { color … }`
   rules flip that grey text light, leaving it invisible on the white cards.
   We re-skin the component onto the theme tokens so it follows every colour
   scheme + automatic dark mode. The tokens themselves flip in dark mode
   (`--white` becomes the dark surface, greys + text invert), so one rule set
   covers both modes; `!important` + the `body .p2w-social` prefix is only there
   to win against the theme's broad dark-mode text overrides.
   ============================================================================= */

body .p2w-social {
  --p2w-surface: var(--white);       /* card / input field surface  */
  --p2w-inset: var(--gray-50);       /* deeper surface (code, inputs) */
  --p2w-border: var(--gray-200);
  --p2w-ink: var(--text-primary);
  --p2w-muted: var(--text-muted);
  color: var(--p2w-ink);
}

/* Headings + intro -------------------------------------------------------- */
body .p2w-social .p2w-social__title {
  color: var(--p2w-ink) !important;
}
body .p2w-social .p2w-social__intro,
body .p2w-social .p2w-field__help,
body .p2w-social .p2w-card__account {
  color: var(--p2w-muted) !important;
}

/* Cards ------------------------------------------------------------------- */
body .p2w-social .p2w-card {
  background: var(--p2w-surface);
  border: 1px solid var(--p2w-border);
  box-shadow: var(--shadow-sm);
}
body .p2w-social .p2w-card__name {
  color: var(--p2w-ink) !important;
}

/* Connection status chips ------------------------------------------------- */
body .p2w-social .p2w-card__status.is-on {
  background: var(--accent-color);
  color: var(--text-on-accent) !important;
}
body .p2w-social .p2w-card__status.is-off {
  background: var(--gray-100);
  color: var(--p2w-muted) !important;
}

/* "App credentials" disclosure + redirect-URI code ------------------------ */
body .p2w-social .p2w-card__creds summary {
  color: var(--accent-color) !important;
}
body .p2w-social .p2w-card__callback small {
  color: var(--p2w-muted) !important;
}
body .p2w-social .p2w-card__callback code,
body .p2w-social code {
  background: var(--p2w-inset);
  color: var(--p2w-ink) !important;
  padding: 2px 6px;
  border-radius: var(--border-radius-sm, 6px);
}

/* Form fields ------------------------------------------------------------- */
body .p2w-social .p2w-field__label {
  color: var(--p2w-ink) !important;
}
body .p2w-social .p2w-field input {
  background: var(--p2w-inset);
  border: 1px solid var(--p2w-border);
  color: var(--p2w-ink);
}
body .p2w-social .p2w-field input::placeholder {
  color: var(--p2w-muted);
}
body .p2w-social .p2w-field input:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 1px;
}

/* Buttons — primary inherits the theme's submit-button styling. Re-skin the
   secondary + danger variants so they don't all read as the primary colour. */
body .p2w-social .p2w-btn--primary {
  color: var(--text-on-primary-fill, var(--text-on-primary)) !important;
}
body .p2w-social .p2w-btn--secondary {
  background: var(--gray-100);
  color: var(--p2w-ink) !important;
  box-shadow: none;
}
body .p2w-social .p2w-btn--secondary:hover {
  background: var(--gray-200);
}
body .p2w-social .p2w-btn--danger {
  background: rgba(220, 38, 38, 0.12);
  color: #dc2626 !important;
  box-shadow: none;
}
body .p2w-social .p2w-btn--danger:hover {
  background: rgba(220, 38, 38, 0.2);
}

/* Settings block ---------------------------------------------------------- */
body .p2w-social .p2w-settings {
  border-top: 1px solid var(--p2w-border);
}
body .p2w-social .p2w-settings h3 {
  color: var(--p2w-ink) !important;
}
body .p2w-social .p2w-check,
body .p2w-social .p2w-check * {
  color: var(--p2w-ink) !important;
}

/* Notices ----------------------------------------------------------------- */
body .p2w-social .p2w-notice--ok {
  background: rgba(26, 127, 55, 0.14);
  color: var(--p2w-ink) !important;
}
body .p2w-social .p2w-notice--error {
  background: rgba(220, 38, 38, 0.14);
  color: var(--p2w-ink) !important;
}

/* =========================================================================
   Post 2 WordPress — form file/image uploader
   The plugin's forms.css hardcodes `color: white` for the dropzone, the "+"
   placeholder and the helper labels, so on a light colour scheme they fade
   into the background (the screenshots: invisible cloud icon, "Wähle Datei"
   and "+"). Re-skin onto theme tokens that flip with light/dark mode so the
   empty-slot hints stay legible in both. `body` prefix + `!important` beats
   the plugin's own `.wf-*` declarations.
   ========================================================================= */
body .wf-file-upload-dropzone,
body .wf-multi-file-uploader-btn {
  border-color: var(--gray-300) !important;
}
body .wf-file-upload-dropzone {
  color: var(--text-muted) !important;
}
body .wf-file-upload-dropzone i,
body .wf-file-upload-dropzone span,
body .wf-file-upload-dropzone .wf-upload-max-size,
body .wf-upload-plus {
  color: var(--text-muted) !important;
}



/* =========================================================================
   Monogram placeholder — a post or product without a photo shows the first
   letter of its title in the layout's display face on the layout's paper,
   instead of a camera glyph. Tagfalter keeps the original glyph.
   ========================================================================= */
body[class*="layout-"]:not(.layout-tagfalter) .clickable-card .post-thumbnail-placeholder,
body[class*="layout-"]:not(.layout-tagfalter) .rtsb-product-image .post-thumbnail-placeholder {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: inherit;
  background: var(--page-paper, var(--gray-100));
  box-shadow: inset 0 0 0 1px var(--page-rule, rgba(0, 0, 0, 0.08));
}

body[class*="layout-"]:not(.layout-tagfalter) .clickable-card .post-thumbnail-placeholder::before,
body[class*="layout-"]:not(.layout-tagfalter) .rtsb-product-image .post-thumbnail-placeholder::before {
  content: attr(data-initial);
  font-family: var(--page-display, var(--font-display));
  font-size: clamp(4.5rem, 9vw, 7rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--page-ink, var(--text-primary));
  opacity: 0.16;
  transform: translateY(0.04em);
}

body[class*="layout-"]:not(.layout-tagfalter) .rtsb-product-image:has(.post-thumbnail-placeholder) {
  background: none;
}

body[class*="layout-"]:not(.layout-tagfalter) .rtsb-product-image:empty::before {
  content: none;
}

/* Dark mode: the classic header and footer sit on --white, which in dark
   mode is the generator's brand-tinted surface. Next to a layout's own
   paper (slate, warm grey, plum) that reads as a different colour band.
   Follow the layout paper instead, lifted a step so the bar still reads. */
@media (prefers-color-scheme: dark) {
  body[class*="layout-"] .site-header:not([class*="site-header--"]),
  body[class*="layout-"] .site-footer:not([class*="site-footer--columns"]):not([class*="site-footer--contact"]):not([class*="site-footer--minimal"]) {
    background: color-mix(in srgb, var(--page-paper, var(--white)) 94%, #ffffff);
  }
}

/* Infinite scroll (js/infinite-scroll.js): blog listings and the shop.
   The numbered shop pagination stays in the HTML for visitors without
   JavaScript and is hidden once the script has taken over. */
.rtsb-infinite-active .woocommerce-pagination {
  display: none;
}

.rtsb-infinite-sentinel {
  height: 1px;
}

.rtsb-infinite-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-height: 0;
  font-size: 0.9rem;
  color: var(--page-muted, var(--text-secondary));
}

.rtsb-infinite-status.is-loading {
  min-height: 4rem;
}

.rtsb-infinite-status.is-loading::before {
  content: '';
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  border: 2px solid color-mix(in srgb, currentColor 25%, transparent);
  border-top-color: var(--page-accent, var(--primary-color));
  animation: rtsb-infinite-spin 0.8s linear infinite;
}

@keyframes rtsb-infinite-spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .rtsb-infinite-status.is-loading::before {
    animation-duration: 2.4s;
  }
}

/* Typography (t2156). The bundled fonts are variable (all weights, optical
   size where the family has it), so the browser never has to fake a weight
   or an italic: font-synthesis is off, and a face without bold or italic
   (Marcellus, Prata, Space Grotesk italic) shows its real regular instead
   of a smeared imitation. German compounds ("Unternehmenslösungen") break
   with hyphens in running text and in headings on narrow screens. */
html {
  font-synthesis: none;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-optical-sizing: auto;
}

h1, h2, h3, h4,
.hero-title,
.entry-title,
.rtsb-section__heading {
  text-wrap: balance;
  overflow-wrap: break-word;
}

p, li, dd, blockquote,
.entry-content,
.excerpt-content,
.hero-subtitle {
  text-wrap: pretty;
  hyphens: auto;
  -webkit-hyphens: auto;
  hyphenate-limit-chars: 8 3 3;
}

@media (max-width: 640px) {
  h1, h2,
  .hero-title {
    hyphens: auto;
    -webkit-hyphens: auto;
    hyphenate-limit-chars: 10 4 4;
  }
}

/* Figures that line up: metrics, prices, opening hours. */
.metric-number,
.price,
.amount,
.rtsb-price-menu__price,
.tf-price-amount,
[class*="hours"] dd,
[class*="hours"] td {
  font-variant-numeric: lining-nums tabular-nums;
}

/* Back to top (t2158, js/back-to-top.js). An ink disc on the layout's paper
   so it reads on every layout in both modes without competing with the
   brand-coloured calls to action. Bottom right; it stacks above the
   Customizer FAB (logged-in editors) and the woo-merchants floating cart
   when those are on the page. Hidden until the script reveals it. */
.rt-to-top {
  position: fixed;
  right: max(1.25rem, env(safe-area-inset-right, 0px));
  bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px) + var(--rtsb-dock, 0px));
  z-index: 9990;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--page-paper, var(--white)) 30%, transparent);
  border-radius: 50%;
  background: color-mix(in srgb, var(--page-ink, var(--text-primary)) 90%, transparent);
  color: var(--page-paper, var(--white));
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s linear 0.25s;
}

.rt-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s;
}

.rt-to-top:hover {
  transform: translateY(-2px);
}

.rt-to-top:active {
  transform: translateY(0) scale(0.96);
}

.rt-to-top:focus-visible {
  outline: 3px solid var(--focus-color, currentColor);
  outline-offset: 3px;
}

.rt-to-top i {
  font-size: 1.35rem;
  line-height: 1;
}

body:has(.rtsb-customizer-fab) .rt-to-top {
  right: calc(2rem + 6px);
  bottom: calc(2rem + 56px + 0.75rem + var(--rtsb-dock, 0px));
}

/* woo-merchants hides an empty cart with an inline style (PHP writes
   "display:none", its JS "display: none"), not with [hidden]. */
/* The cart sits where the theme puts it (2rem + 56px + 1rem, 56px tall, see
   .wm-floating-cart above), its count badge pokes 4px above the disc. */
body:has(.wm-floating-cart:not([style*="display:none"]):not([style*="display: none"])) .rt-to-top {
  right: calc(2rem + 6px);
  bottom: calc(2rem + 56px + 1rem + 56px + 0.75rem + 6px + var(--rtsb-dock, 0px));
}

/* Cart and checkout: no button over amounts, form fields and card inputs. */
body.woocommerce-cart .rt-to-top,
body.woocommerce-checkout .rt-to-top {
  display: none;
}

.rt-to-top-sentinel {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 150vh;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .rt-to-top,
  .rt-to-top.is-visible {
    transform: none;
    transition: opacity 0.15s ease, visibility 0s;
  }
}

/* Dark mode: the Customizer FAB sat on the light accent tint with dark
   icon (a pale pink disc); use the deep accent fill like other brand fills. */
@media (prefers-color-scheme: dark) {
  .rtsb-customizer-fab {
    background: var(--accent-fill, var(--accent-color));
    color: #ffffff;
    border-color: #ffffff;
  }
}
