/*
Theme Name: Stonehall
Theme URI: https://stonehall.ai
Author: Stonehall
Author URI: https://stonehall.ai
Description: Custom theme for Stonehall – Business AI Solutions. Parallax paper texture, clear glass plate cards, calligraphic typography.
Version: 2.0.0
Text Domain: stonehall
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

/* ==========================================================================
   Self-Hosted Fonts
   ========================================================================== */

@font-face {
  font-family: 'Centralwell';
  src: url('assets/fonts/centralwell-personal-use.regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Montserrat';
  src: url('assets/fonts/Montserrat-VariableFont_wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Caveat';
  src: url('assets/fonts/Caveat-VariableFont_wght.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* ==========================================================================
   Design Tokens
   ========================================================================== */

:root {
  /* Glass effect — clear transparent plate, NOT frosted */
  --glass-bg: rgba(255, 255, 255, 0.06);
  --glass-shine: linear-gradient(135deg,
      rgba(255, 255, 255, 0.35) 0%,
      rgba(255, 255, 255, 0.0) 40%,
      rgba(255, 255, 255, 0.0) 60%,
      rgba(255, 255, 255, 0.08) 100%);
  --glass-border: rgba(255, 255, 255, 0.45);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.10);
  --glass-radius: 1.25rem;

  /* Typography */
  --font-heading: 'Centralwell', cursive;
  --font-body: 'Montserrat', sans-serif;
  --font-glass-pen: 'Caveat', cursive;

  /* Colors */
  --color-text: #2c2c2c;
  --color-text-light: rgba(44, 44, 44, 0.6);
  --color-text-glass-pen: rgba(44, 44, 44, 0.75);
  --color-bg-paper: #f5f0e8;
  --color-nav-bg: rgba(245, 240, 232, 0.6);
  --color-nav-bg-scrolled: rgba(245, 240, 232, 0.85);
  --color-link: #3a3a3a;
  --color-link-hover: #1a1a1a;

  /* Spacing */
  --section-padding: clamp(0rem, 2vw, 8rem);
  --content-max-width: 800px;
  --card-padding: clamp(2rem, 4vw, 3.5rem);
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background-color: var(--color-bg-paper);
  overflow-x: hidden;
}

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

a {
  color: var(--color-link);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover,
a:focus {
  color: var(--color-link-hover);
}

/* ==========================================================================
   Focus Visible — Accessibility (WCAG 2.1 AA)
   ========================================================================== */

:focus-visible {
  outline: 2px solid var(--color-link);
  outline-offset: 3px;
  border-radius: 3px;
}

.btn-cta:focus-visible,
.btn-home:focus-visible {
  outline: 2px solid var(--color-link);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.1);
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--color-link);
  outline-offset: 4px;
  border-radius: 4px;
}

.menu a:focus-visible {
  outline: 2px solid var(--color-link);
  outline-offset: 2px;
  border-radius: 3px;
}

/* Night mode: use light focus ring */
body.stonehall-theme-night :focus-visible {
  outline-color: #90b4e0;
}

body.stonehall-theme-night .btn-cta:focus-visible,
body.stonehall-theme-night .btn-home:focus-visible {
  outline-color: #90b4e0;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.15);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-body);
  font-weight: 700;
  line-height: 1.2;
}

/* ==========================================================================
   Skip to Content (Accessibility)
   ========================================================================== */

.skip-to-content {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
  z-index: 10000;
  padding: 1rem 2rem;
  background: var(--color-text);
  color: #fff;
  font-size: 0.875rem;
  border-radius: 0 0 var(--glass-radius) 0;
}

.skip-to-content:focus {
  position: fixed;
  top: 0;
  left: 0;
  width: auto;
  height: auto;
  overflow: visible;
}



/* ==========================================================================
   Navigation
   ========================================================================== */

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}

/* Offset nav when WP admin bar is visible */
.admin-bar .site-nav {
  top: 32px;
  padding-top: 1rem;
}

/* Scrolled state — stays transparent per design intent */
.site-nav.scrolled {
  background: transparent;
}


.nav-inner {
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Hide logo in nav — it lives in the hero section instead (matches stonehall.at) */
.site-branding {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.site-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--color-text);
  letter-spacing: -0.02em;
}

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

.nav-inner .menu {
  display: flex;
  list-style: none;
  gap: 2.5rem;
  align-items: center;
  padding: 0.5rem 2rem;
  /* Glass plate handles background/border/shadow — menu is transparent */
  background: transparent;
  border: none;
  box-shadow: none;
  position: relative;
  z-index: 1;
  pointer-events: auto;
}

/* Nav centering wrapper */
.nav-center {
  text-align: center;
}

/* Nav glass plate — compact pill, no background color, only blur */
.glass-plate-wrap.nav-glass {
  display: inline-block;
  width: auto;
  box-shadow: none;
}

.nav-glass .plate {
  --plate-radius: 999px;
  --plate-padding: 0;
  --lg-radius: 999px;
  --lg-padding: 0;
  width: fit-content;
}

/* No tint/background — transparent glass, blur only */
.nav-glass .liquid-glass-tint {
  background: transparent;
}

.nav-glass .plate-content {
  display: flex;
  justify-content: center;
  padding: 0;
}


.nav-inner .menu li a {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  color: var(--color-text);
  position: relative;
  padding: 0.25rem 0;
}

.nav-inner .menu li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 1px;
  background: var(--color-text);
  transition: width 0.3s ease, left 0.3s ease;
}

.nav-inner .menu li a:hover::after,
.nav-inner .menu li.current-menu-item a::after {
  width: 100%;
  left: 0;
}

/* Hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 101;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  margin: 5px 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 2rem;
}

/* Scroll Indicator — bottom of hero viewport */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0.4;
  color: var(--color-text);
  animation: scroll-bounce 2s ease-in-out infinite;
  transition: opacity 0.3s ease;
}

.scroll-indicator:hover {
  opacity: 0.8;
}

@keyframes scroll-bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(8px); }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-indicator {
    animation: none;
  }
}

/* Front-Page Blocks — max-width on wide screens */
.front-page-blocks {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

@media (max-width: 768px) {
  .front-page-blocks {
    max-width: none;
    padding: 0 1rem;
  }
}

.hero-logo {
  max-width: 400px;
  width: 80vw;
  mix-blend-mode: multiply;
}

.hero .custom-logo {
  max-width: 400px;
  width: 80vw;
  mix-blend-mode: multiply;
}

/* WebM animated logo — needs alpha-transparent WebM for proper display */
.hero-logo-video {
  max-width: 400px;
  width: 80vw;
  mix-blend-mode: multiply;
  display: block;
}

/* Reduced-motion: hide video, show static logo fallback */
@media (prefers-reduced-motion: reduce) {
  .hero-logo-video {
    display: none;
  }

  .hero-logo-static {
    display: block !important;
  }
}

.hero-tagline {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text);
  opacity: 0.5;
}

/* ==========================================================================
   Glass Plate Integration (POC system)
   ========================================================================== */

/* Content inside the multi-layer plate */
.plate-content {
  position: relative;
  z-index: 1;
  pointer-events: auto;
  color: var(--color-text);
}

/* Glass plate wrapper — controls section-level size */
.glass-plate-wrap {
  position: relative;
  width: 100%;
}

/* ==========================================================================
   Icon System
   ========================================================================== */

.sh-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
}

.sh-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

/* Stroke-based icons: ensure stroke inherits currentColor */
.sh-icon svg[stroke="currentColor"] {
  fill: none;
}

/* Icon Block */
.wp-block-stonehall-icon {
  display: flex;
}

.wp-block-stonehall-icon.has-text-align-center {
  justify-content: center;
}

.wp-block-stonehall-icon.has-text-align-right {
  justify-content: flex-end;
}

/* ==========================================================================
   Gutenberg Block Integration
   ========================================================================== */

/* Neutralize WP block wrapper margins — section-level spacing is handled
   by .section-credo / .section-values / .section-teaser inside the blocks. */
.wp-block-stonehall-credo,
.wp-block-stonehall-values,
.wp-block-stonehall-teaser,
.wp-block-stonehall-glass-plate,
.wp-block-stonehall-business-card {
  margin: 0;
  padding: 0;
  max-width: none;
}

/* When a section class appears inside a glass plate (from the block's
   $content wrapper), suppress its section-level padding/margins so only
   the plate's own padding controls inner spacing. */
.plate-content .section-credo,
.plate-content .section-values,
.plate-content .section-teaser {
  padding: 0;
  margin: 0;
  max-width: none;
}

/* ==========================================================================
   Credo Section
   ========================================================================== */

.section-credo {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.credo-quote {
  font-family: var(--font-glass-pen);
  font-size: clamp(1.4rem, 2.8vw, 1.75rem);
  color: var(--color-text-glass-pen);
  line-height: 1.8;
  margin-bottom: 1.25rem;
  font-style: normal;
  border: none;
  padding: 0;
}

.credo-body,
.contact-about-text {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(0.95rem, 1.5vw, 1.05rem);
  line-height: 1.8;
  color: var(--color-text);
  opacity: 0.85;
}

/* ==========================================================================
   Values Section
   ========================================================================== */

.section-values {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.value-card .plate-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.value-card-icon {
  width: 64px;
  height: 64px;
  margin-bottom: 1.5rem;
  object-fit: contain;
}

.value-card-title {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.value-card-text {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--color-text);
  opacity: 0.8;
}

/* ==========================================================================
   Teaser Section
   ========================================================================== */

.section-teaser {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.section-teaser .plate-content {
  text-align: center;
}

.teaser-text {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  line-height: 1.8;
  color: var(--color-text);
  opacity: 0.85;
  margin-bottom: 2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.btn-cta {
  display: inline-block;
  padding: 0.75rem 2rem;
  border: 1px solid var(--color-text);
  border-radius: var(--glass-radius);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  color: var(--color-text);
  transition: background 0.3s ease, color 0.3s ease;
}

.btn-cta:hover {
  background: var(--color-text);
  color: #fff;
}

/* ==========================================================================
   Contact Page
   ========================================================================== */

.page-contact {
  padding: calc(var(--section-padding) + 4rem) 2rem var(--section-padding);
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.section-contact-about {
  margin-bottom: 2rem;
}

.section-founder,
.section-business-card {
  /* padding: var(--section-padding) 2rem; */
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.founder-card {
  padding: 0;
}

.founder-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.founder-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: hsl(212, 70%, 45%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.founder-avatar span {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  color: #fff;
  letter-spacing: 0.05em;
}

.founder-name {
  font-family: var(--font-glass-pen);
  /* font-family: var(--font-heading); */
  font-size: 1.6rem;
  margin-bottom: 0.25rem;
}

.founder-role {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--color-text-light);
}

.founder-contact-details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.founder-contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
  color: var(--color-text);
}

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

.founder-contact-icon {
  width: 1.25rem;
  height: 1.25rem;
  object-fit: contain;
  flex-shrink: 0;
}

.founder-divider {
  border: none;
  border-top: 1px dashed rgba(44, 44, 44, 0.2);
  margin: 1.5rem 0;
}

.founder-address {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--color-text);
  font-style: normal;
}

/* ==========================================================================
   Imprint Page
   ========================================================================== */

.page-imprint {
  padding: calc(var(--section-padding) + 4rem) 2rem var(--section-padding);
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.section-imprint {
  margin-bottom: 2rem;
}

.imprint-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 2rem;
}

.imprint-content h2 {
  font-size: 1.3rem;
  margin: 2rem 0 0.75rem;
}

.imprint-content p {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.imprint-content address {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.95rem;
  line-height: 1.8;
  font-style: normal;
  margin-bottom: 1rem;
}

.imprint-content a {
  color: var(--color-link);
}

.imprint-content a:hover {
  color: var(--color-link-hover);
}

/* ==========================================================================
   Page Layouts (Sidebars)
   ========================================================================== */

.layout-wrapper {
  max-width: var(--content-max-width);
  margin: 0 auto;
  /* padding: 0 2rem; (handled by content-wrap usually, but let's add it if needed. Actually we'll let content-wrap keep its padding) */
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .layout-wrapper.has-sidebar {
    display: grid;
    grid-template-columns: 1fr 340px; /* Right sidebar by default */
    gap: 4rem;
    align-items: start;
    padding: calc(var(--section-padding) + 2rem) 2rem var(--section-padding);
  }

  .layout-wrapper.has-sidebar-left {
    grid-template-columns: 340px 1fr;
  }

  /* Override the default content-wrap padding when inside a sidebar layout */
  .layout-wrapper.has-sidebar .content-wrap {
    padding: 0;
    max-width: none;
    margin: 0;
    width: 100%;
  }

  .layout-wrapper.has-sidebar-left .content-wrap {
    order: 2;
  }

  .layout-wrapper.has-sidebar-left .sidebar-area {
    order: 1;
  }
}

/* Sidebar Widgets */
.sidebar-area .glass-plate-content {
  padding: var(--card-padding);
}

.sidebar-area .widget {
  margin-bottom: 2rem;
}

.sidebar-area .widget:last-child {
  margin-bottom: 0;
}

.sidebar-area .widget-title {
  margin-bottom: 1rem;
  font-size: 1.25rem;
  font-weight: 500;
  border-bottom: 1px solid var(--color-text-light);
  padding-bottom: 0.5rem;
}

.sidebar-area .widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-area .widget ul li {
  margin-bottom: 0.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px dashed var(--color-text-light);
}

.sidebar-area .widget ul li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.sidebar-area .widget a {
  text-decoration: none;
  color: var(--color-link);
  transition: color 0.3s ease;
}

.sidebar-area .widget a:hover {
  text-decoration: underline;
  color: var(--color-link-hover);
}

/* ==========================================================================
   Single Post & Page
   ========================================================================== */

.content-wrap {
  padding: calc(var(--section-padding) + 4rem) 2rem var(--section-padding);
  max-width: 800px;
  margin: 0 auto;
}

.content-wrap.content-full-width {
  max-width: var(--content-max-width);
}

.content-wrap .glass-card {
  padding: var(--card-padding);
}

.content-wrap .entry-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.5rem;
}

/* Page Title Alignment (Customizer: 7.7) */
.page-title-align-center .entry-title,
.page-title-align-center .archive-header h1,
.page-title-align-center .search-header h1 {
  text-align: center;
}

.page-title-align-right .entry-title,
.page-title-align-right .archive-header h1,
.page-title-align-right .search-header h1 {
  text-align: right;
}

/* Container Boxed Mode (Customizer: 7.10) */
.container-boxed .content-wrap {
  background: var(--page-title-bg, transparent);
  border-radius: var(--glass-radius);
  box-shadow: 0 2px 16px rgba(0,0,0,0.04);
}

.content-wrap .entry-meta {
  font-size: 0.85rem;
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

.content-wrap .entry-content {
  font-size: 1.05rem;
  line-height: 1.8;
}

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

.content-wrap .entry-content h2 {
  font-size: 1.8rem;
  margin: 2.5rem 0 1rem;
}

.content-wrap .entry-content h3 {
  font-size: 1.4rem;
  margin: 2rem 0 0.75rem;
}

.content-wrap .featured-image {
  width: 100%;
  border-radius: calc(var(--glass-radius) - 4px);
  margin-bottom: 2rem;
}

/* ==========================================================================
   Archive & Search Header
   ========================================================================== */

.archive-header,
.search-header {
  text-align: center;
  padding: calc(var(--section-padding) + 4rem) 2rem 2rem;
}

.archive-header h1,
.search-header h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1rem;
}

.archive-content,
.search-content {
  padding: 2rem 2rem var(--section-padding);
  max-width: var(--content-max-width);
  margin: 0 auto;
}

/* ==========================================================================
   404 Page
   ========================================================================== */

.page-404 {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.page-404 .glass-card {
  max-width: 500px;
  text-align: center;
}

.page-404 h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.page-404 p {
  font-size: 1.1rem;
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

.page-404 .btn-home {
  display: inline-block;
  padding: 0.75rem 2rem;
  border: 1px solid var(--color-text);
  border-radius: var(--glass-radius);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: background 0.3s ease, color 0.3s ease;
}

.page-404 .btn-home:hover {
  background: var(--color-text);
  color: #fff;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  padding: 0 0 3rem;
  text-align: center;
}

/* Footer Widget Grid */
.footer-widgets {
  padding: 4rem 2rem 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.footer-widgets-inner {
  display: grid;
  gap: 2rem;
}

.footer-cols-1 .footer-widgets-inner { grid-template-columns: 1fr; }
.footer-cols-2 .footer-widgets-inner { grid-template-columns: repeat(2, 1fr); }
.footer-cols-3 .footer-widgets-inner { grid-template-columns: repeat(3, 1fr); }
.footer-cols-4 .footer-widgets-inner { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 768px) {
  .footer-widgets-inner {
    grid-template-columns: 1fr !important;
  }
}

.footer-col .widget-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-text-light);
}

.footer-col .widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col .widget ul li {
  margin-bottom: 0.4rem;
}

.footer-col .widget a {
  text-decoration: none;
  color: var(--color-text-light);
  transition: color 0.3s ease;
}

.footer-col .widget a:hover {
  color: var(--color-text);
  text-decoration: underline;
}

.footer-inline {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
  font-size: 0.85rem;
  color: var(--color-text-light);
}

.footer-inline a {
  color: var(--color-text-light);
  transition: color 0.3s ease;
}

.footer-inline a:hover {
  color: var(--color-text);
}

.footer-inline .sep {
  margin: 0 0.35rem;
  opacity: 0.5;
}

.footer-inline .active-lang {
  font-weight: 600;
  color: var(--color-text);
}

/* Social Links */
.footer-social-links,
.social-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.social-link {
  display: inline-flex;
  color: var(--color-text-light);
  transition: color 0.3s ease, transform 0.2s ease;
}

.social-link:hover {
  color: var(--color-text);
  transform: translateY(-1px);
}

.social-link svg {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   Custom Blocks — Front-end Styles
   ========================================================================== */

/* --- Testimonials --- */
.stonehall-testimonials {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.testimonials-grid {
  display: grid;
  gap: 2rem;
}

.testimonial-card .glass-plate-content {
  padding: var(--card-padding);
}

.testimonial-quote {
  font-style: italic;
  font-size: 1rem;
  line-height: 1.7;
  margin: 0 0 1.5rem;
  position: relative;
  padding-left: 1rem;
  border-left: 3px solid var(--color-text-light);
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.testimonial-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.testimonial-meta {
  display: flex;
  flex-direction: column;
}

.testimonial-name {
  font-style: normal;
  font-weight: 600;
  font-size: 0.9rem;
}

.testimonial-role {
  font-size: 0.8rem;
  opacity: 0.7;
}

/* --- Pricing --- */
.stonehall-pricing {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.pricing-grid {
  display: grid;
  gap: 2rem;
  align-items: start;
}

.pricing-tier .glass-plate-content {
  padding: var(--card-padding);
  text-align: center;
}

.pricing-highlighted .glass-plate-content {
  border: 2px solid var(--color-link);
}

.pricing-name {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.pricing-price {
  margin-bottom: 1.5rem;
}

.pricing-amount {
  font-size: 2.5rem;
  font-weight: 700;
}

.pricing-period {
  font-size: 0.85rem;
  opacity: 0.6;
}

.pricing-features {
  text-align: left;
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.pricing-features p {
  margin: 0;
  padding: 0.25rem 0;
  border-bottom: 1px dashed var(--color-text-light);
}

.pricing-cta {
  display: inline-block;
  padding: 0.75rem 2rem;
  border: 1px solid var(--color-text);
  border-radius: var(--glass-radius);
  text-decoration: none;
  font-weight: 500;
  transition: background 0.3s ease, color 0.3s ease;
}

.pricing-cta:hover {
  background: var(--color-text);
  color: #fff;
}

/* --- Team Grid --- */
.stonehall-team {
  padding: var(--section-padding) 2rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.team-grid {
  display: grid;
  gap: 2rem;
}

.team-card .glass-plate-content {
  padding: var(--card-padding);
  text-align: center;
}

.team-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1rem;
}

.team-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
}

.team-role {
  font-size: 0.85rem;
  opacity: 0.7;
  margin: 0 0 0.75rem;
}

.team-bio {
  font-size: 0.85rem;
  margin: 0;
  line-height: 1.6;
}

/* --- FAQ Accordion --- */
.stonehall-faq {
  padding: var(--section-padding) 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.stonehall-faq .glass-plate-content {
  padding: var(--card-padding);
}

.faq-item {
  border-bottom: 1px solid var(--color-text-light);
  padding: 1rem 0;
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-question {
  cursor: pointer;
  font-weight: 600;
  font-size: 1rem;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-chevron {
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.faq-item[open] .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0.75rem 0 0;
  font-size: 0.9rem;
  line-height: 1.7;
  opacity: 0.85;
}

/* --- Section Divider --- */
.stonehall-divider {
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.stonehall-divider svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* --- Block Responsive --- */
@media (max-width: 768px) {
  .testimonials-grid,
  .pricing-grid,
  .team-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ==========================================================================
   No Content Fallback
   ========================================================================== */

.no-content {
  padding: var(--section-padding) 2rem;
  display: flex;
  justify-content: center;
}

.no-content .glass-card {
  max-width: 500px;
  text-align: center;
}

/* ==========================================================================
   Breadcrumbs
   ========================================================================== */

.breadcrumbs {
  padding: 0.75rem var(--card-padding, 2rem);
  font-size: 0.85rem;
  color: var(--color-text);
  opacity: 0.6;
}

.breadcrumbs a {
  color: var(--color-link);
}

.breadcrumb-sep {
  margin: 0 0.35rem;
}

.breadcrumb-current {
  font-weight: 500;
}

/* ==========================================================================
   Entry Meta & Post Navigation (single.php)
   ========================================================================== */

.entry-meta {
  font-size: 0.85rem;
  opacity: 0.7;
  margin-bottom: 1.5rem;
}

.entry-meta-sep {
  margin: 0 0.25rem;
}

/* ==========================================================================
   Author Info Box
   ========================================================================== */

.author-bio-box {
  margin-top: 3rem;
  padding: var(--lg-padding);
}

.author-bio-box .plate-content {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

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

.author-info {
  flex: 1;
}

.author-name {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}

.author-bio {
  font-size: 0.95rem;
  opacity: 0.8;
  margin-bottom: 0.75rem;
}

.author-link {
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (max-width: 768px) {
  .author-bio-box .plate-content {
    flex-direction: column;
    text-align: center;
  }
}

/* ==========================================================================
   Related Posts
   ========================================================================== */

.related-posts {
  margin-top: 4rem;
}

.related-posts-title {
  margin-bottom: 2rem;
  font-size: 1.5rem;
  text-align: center;
}

/* ==========================================================================
   Post Navigation
   ========================================================================== */

.post-navigation {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  display: flex;
  justify-content: space-between;
  gap: 2rem;
}

.post-navigation .nav-subtitle {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.5;
  margin-bottom: 0.25rem;
}

.post-navigation .nav-title {
  font-weight: 500;
}

/* ==========================================================================
   Pagination (archive, search, index)
   ========================================================================== */

.pagination,
.nav-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  padding: 2rem 0;
  flex-wrap: wrap;
}

.pagination .page-numbers,
.nav-links .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  height: 2.5rem;
  padding: 0 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.pagination .page-numbers:hover,
.nav-links .page-numbers:hover {
  background: rgba(0, 0, 0, 0.08);
}

.pagination .page-numbers.current,
.nav-links .page-numbers.current {
  background: var(--color-link);
  color: #fff;
}

/* ==========================================================================
   Search Form
   ========================================================================== */

.search-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 400px;
}

.search-form .search-field {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
  font-family: inherit;
  color: var(--color-text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-form .search-field:focus {
  outline: none;
  border-color: var(--color-link);
  box-shadow: 0 0 0 3px rgba(83, 137, 212, 0.15);
}

.search-form .search-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 0.5rem;
  background: var(--color-link);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease;
}

.search-form .search-submit:hover {
  background: var(--color-link-hover);
}

/* ==========================================================================
   Comments
   ========================================================================== */

.comments-area {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.comments-title {
  margin-bottom: 1.5rem;
}

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

.comment-list .comment {
  padding: 1rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.comment-list .comment-body {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.comment-reply-title {
  font-size: 1.2rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.comment-form textarea {
  width: 100%;
  min-height: 120px;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 0.5rem;
  font-family: inherit;
  font-size: 0.9rem;
  resize: vertical;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 0.5rem;
  font-family: inherit;
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

.comment-form .form-submit .submit {
  display: inline-flex;
  padding: 0.6rem 1.5rem;
  border: none;
  border-radius: 0.5rem;
  background: var(--color-link);
  color: #fff;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.comment-form .form-submit .submit:hover {
  background: var(--color-link-hover);
}

/* ==========================================================================
   Blog Grid & Card Styles
   ========================================================================== */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.blog-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--glass-radius, 1.25rem);
  background: rgba(255, 255, 255, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.blog-card-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--glass-radius, 1.25rem) var(--glass-radius, 1.25rem) 0 0;
}

.blog-card-title {
  padding: 1.25rem 1.5rem 0.5rem;
  font-size: 1.15rem;
  line-height: 1.35;
}

.blog-card-title a {
  color: inherit;
  text-decoration: none;
}

.blog-card-title a:hover {
  color: var(--color-link-hover);
}

.blog-card-excerpt {
  padding: 0 1.5rem 1.5rem;
  font-size: 0.9rem;
  opacity: 0.75;
  line-height: 1.6;
}

/* ==========================================================================
   Glass Plate Entrance Animations
   ========================================================================== */

.glass-plate-wrap {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.glass-plate-wrap.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .glass-plate-wrap {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ==========================================================================
   Value Card Hover Effect
   ========================================================================== */

.value-card {
  transition: transform 0.3s ease;
}

.value-card:hover {
  transform: translateY(-6px);
}

.value-card:hover .glass-plate-wrap {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   Responsive
   ========================================================================== */

/* Large desktop — 1200px */
@media (max-width: 1200px) {
  :root {
    --content-max-width: 960px;
  }
}

/* Small desktop / large tablet — 1024px */
@media (max-width: 1024px) {
  :root {
    --content-max-width: 768px;
    --section-padding: clamp(3rem, 6vw, 5rem);
  }

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

  .hero-logo,
  .hero .custom-logo,
  .hero-logo-video {
    max-width: 320px;
  }
}

/* Tablet — 768px */
@media (max-width: 768px) {
  .values-grid {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
  }

  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .nav-toggle {
    display: block;
  }

  .nav-inner {
    flex-direction: column;
    gap: 0;
  }

  .nav-inner .menu {
    display: none;
    flex-direction: column;
    gap: 1.25rem;
    padding: 1.5rem 1rem;
    width: 100%;
    text-align: center;
    /* No extra background — glass plate handles the frosted glass look */
    background: transparent;
  }

  .nav-inner .menu.is-open {
    display: flex;
  }

  /* Mobile: nav-center centered, not full width */
  .nav-center {
    display: none;
    text-align: center;
  }

  .nav-center.is-open {
    display: block;
  }

  .glass-plate-wrap.nav-glass {
    display: inline-block;
    width: auto;
    margin-top: 0.5rem;
  }

  .nav-glass .plate {
    width: auto;
  }

  .hero-logo,
  .hero .custom-logo,
  .hero-logo-video {
    max-width: 280px;
  }

  .founder-header {
    flex-direction: column;
    text-align: center;
  }

  /* Mobile: disable fixed background-attachment (iOS) */
  body {
    background-attachment: scroll !important;
  }

  /* Mobile font scaling */
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.4rem; }
}

/* Mobile — 375px */
@media (max-width: 480px) {
  :root {
    --card-padding: 1.5rem;
  }

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

  .hero-logo,
  .hero .custom-logo,
  .hero-logo-video {
    max-width: 220px;
  }
}

/* ==========================================================================
   Dynamic Theme — Page Backgrounds (Night / Afternoon)
   Matches POC panel styles. Body class set by dynamic-theme.js / PHP.
   ========================================================================== */

/* Smooth transition for all theme changes */
body {
  transition: background-color 0.8s ease, color 0.8s ease;
}

/* ── Night ─────────────────────────────────────────────────── */

body.stonehall-theme-night {
  background-color: #1a1e2e;
  color: #e8e8e8;
}

/* Darken the paper texture on night */
body.stonehall-theme-night::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background: inherit;
  filter: brightness(0.25) saturate(0.5);
  pointer-events: none;
}

body.stonehall-theme-night .plate-content,
body.stonehall-theme-night .nav-inner .menu li a,
body.stonehall-theme-night .credo-quote,
body.stonehall-theme-night .credo-body,
body.stonehall-theme-night .value-card-title,
body.stonehall-theme-night .value-card-text,
body.stonehall-theme-night .teaser-text,
body.stonehall-theme-night .founder-name,
body.stonehall-theme-night .founder-contact-item,
body.stonehall-theme-night .founder-address,
body.stonehall-theme-night .contact-about-text,
body.stonehall-theme-night h1,
body.stonehall-theme-night h2,
body.stonehall-theme-night h3 {
  color: #e8e8e8;
}

body.stonehall-theme-night .hero-tagline {
  color: #e8e8e8;
  opacity: 0.65; /* raised from 0.5 for WCAG AA contrast compliance */
}

body.stonehall-theme-night .founder-role {
  color: rgba(232, 232, 232, 0.6);
}

body.stonehall-theme-night .hero-logo,
body.stonehall-theme-night .hero .custom-logo,
body.stonehall-theme-night .hero-logo-video {
  mix-blend-mode: screen;
}

body.stonehall-theme-night .hero-logo-static {
  mix-blend-mode: screen;
}

body.stonehall-theme-night .btn-cta {
  border-color: #e8e8e8;
  color: #e8e8e8;
}

body.stonehall-theme-night .btn-cta:hover {
  background: #e8e8e8;
  color: #1a1e2e;
}

body.stonehall-theme-night .nav-inner .menu li a::after {
  background: #e8e8e8;
}

body.stonehall-theme-night .footer-copyright,
body.stonehall-theme-night .site-footer a {
  color: rgba(232, 232, 232, 0.6);
}

body.stonehall-theme-night .founder-divider {
  border-top-color: rgba(232, 232, 232, 0.2);
}

/* ── Afternoon ────────────────────────────────────────────── */

body.stonehall-theme-afternoon {
  background-color: #f0e0c8;
  background-image: linear-gradient(160deg, #f5e6d0, #e8c9a0, #d4a86a);
}

/* Warm-filtered paper texture overlay for afternoon */
body.stonehall-theme-afternoon::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background: inherit;
  filter: brightness(0.75) saturate(0.4) sepia(0.3);
  opacity: 0.4;
  pointer-events: none;
}

/* ==========================================================================
   Back to Top Button
   ========================================================================== */

.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 90;
  width: 3rem;
  height: 3rem;
  border: none;
  border-radius: 50%;
  background: var(--color-link);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, background 0.2s ease;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--color-link-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

body.stonehall-theme-night .back-to-top {
  background: #90b4e0;
  color: #1a1e2e;
}

/* ==========================================================================
   Print Stylesheet
   ========================================================================== */

@media print {
  /* Hide interactive + decorative elements */
  .site-nav,
  .back-to-top,
  .skip-to-content,
  .nav-toggle,
  .footer-lang-group,
  .glass-plate-wrap,
  .post-navigation,
  .pagination {
    display: none !important;
  }

  /* Reset backgrounds and colors */
  body {
    background: #fff !important;
    color: #000 !important;
    font-size: 12pt;
  }

  a {
    color: #000 !important;
    text-decoration: underline;
  }

  /* Show link URLs */
  a[href]::after {
    content: ' (' attr(href) ')';
    font-size: 0.8em;
    color: #666;
  }

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

  /* Avoid page breaks inside key elements */
  .glass-card,
  .blog-card,
  article,
  .value-card {
    break-inside: avoid;
  }

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

/* ==========================================================================
   Preloader
   ========================================================================== */

.preloader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-background, #fff);
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.preloader-done {
  opacity: 0;
  visibility: hidden;
}

.preloader-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--color-text-light, #ccc);
  border-top-color: var(--color-text, #333);
  border-radius: 50%;
  animation: preloader-spin 0.7s linear infinite;
}

@keyframes preloader-spin {
  to { transform: rotate(360deg); }
}