/* ============================================
   Victorian Industrial Steampunk - Enhanced
   Maximum Detail Airship Engine Room Aesthetic
   ============================================ */

/* ========== BRASS PANELS & FRAMES ========== */

.brass-panel-heavy {
  background: url('../assets/images/textures/brushed-alum-dark.png'), linear-gradient(135deg,
    var(--color-brass-polished) 0%,
    var(--color-brass-aged) 50%,
    var(--color-brass-oxidized) 100%);
  border: 6px solid var(--color-bronze-dark);
  box-shadow:
    inset 0 2px 4px rgba(255,255,255,0.4),
    inset 0 -2px 4px rgba(0,0,0,0.4),
    0 8px 16px rgba(0,0,0,0.3);
  position: relative;
  padding: var(--spacing-xl);
}

.brass-panel-heavy::before,
.brass-panel-heavy::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  background: radial-gradient(circle, var(--color-brass-oxidized) 30%, var(--color-bronze-dark) 70%);
  border-radius: 50%;
  box-shadow: inset 0 2px 3px rgba(0,0,0,0.5);
}

.brass-panel-heavy::before {
  top: 12px;
  left: 12px;
}

.brass-panel-heavy::after {
  top: 12px;
  right: 12px;
}

/* Ornate Viewport Frame (for stream embed) */
.viewport-frame {
  position: relative;
  border: 8px solid var(--color-brass-aged);
  background: url('../assets/images/textures/brushed-alum-dark.png'), linear-gradient(135deg, var(--color-brass-polished), var(--color-brass-oxidized));
  box-shadow:
    inset 0 0 30px rgba(0,0,0,0.3),
    0 12px 24px rgba(0,0,0,0.4);
  padding: 8px;
}

.viewport-frame::before {
  content: '';
  position: absolute;
  inset: -12px;
  border: 2px solid var(--color-bronze-dark);
  border-radius: 4px;
  pointer-events: none;
}

/* Twitter/X Embed Viewport Frame */
.twitter-viewport {
  max-width: 700px;
  margin: 0 auto;
}

.twitter-viewport-label {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  background: linear-gradient(135deg, rgba(42, 34, 24, 0.92) 0%, rgba(58, 50, 38, 0.95) 100%);
  border: 3px solid var(--color-brass-polished);
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  padding: var(--spacing-sm) var(--spacing-md);
  position: relative;
}

.twitter-viewport-label .stamped-label {
  color: var(--color-brass-polished);
  margin: 0;
  font-size: var(--font-size-sm);
}

.twitter-viewport-label::before,
.twitter-viewport-label::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-brass-aged) 30%, var(--color-bronze-dark) 70%);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.5);
  top: 50%;
  transform: translateY(-50%);
}

.twitter-viewport-label::before {
  left: 10px;
}

.twitter-viewport-label::after {
  right: 10px;
}

.twitter-viewport-frame {
  position: relative;
  border: 6px solid var(--color-brass-aged);
  background: url('../assets/images/textures/brushed-alum-dark.png'), linear-gradient(135deg, var(--color-brass-polished), var(--color-brass-oxidized));
  box-shadow:
    inset 0 0 30px rgba(0,0,0,0.3),
    0 8px 20px rgba(0,0,0,0.4);
  padding: 6px;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.twitter-viewport-frame .twitter-viewport-inner {
  background: #15202b;
  overflow: hidden;
  border-radius: 2px;
  min-height: 500px;
  padding: var(--spacing-sm);
}

/* Curator.io Feed Overrides - Steampunk Dark Theme */
#curator-feed-default-feed-layout .crt-post {
  background: rgba(42, 34, 24, 0.9) !important;
  border: 1px solid var(--color-brass-aged) !important;
  border-radius: var(--radius-md) !important;
}

#curator-feed-default-feed-layout .crt-post-header .crt-post-name {
  color: var(--color-gold) !important;
  font-family: var(--font-technical) !important;
}

#curator-feed-default-feed-layout .crt-post-text,
#curator-feed-default-feed-layout .crt-post-content-text {
  color: var(--color-ivory) !important;
  font-family: var(--font-body) !important;
}

#curator-feed-default-feed-layout a {
  color: var(--color-brass-polished) !important;
}

#curator-feed-default-feed-layout a:hover {
  color: var(--color-gold) !important;
}

#curator-feed-default-feed-layout .crt-load-more .crt-load-more-button {
  background: radial-gradient(ellipse at 40% 40%, var(--color-brass-polished), var(--color-brass-aged)) !important;
  border: 2px solid var(--color-bronze-dark) !important;
  color: var(--color-iron-dark) !important;
  font-family: var(--font-display) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  border-radius: var(--radius-md) !important;
}

#curator-feed-default-feed-layout .crt-logo {
  opacity: 0.4;
}

/* Corner Brackets */
.corner-brackets::before,
.corner-brackets::after {
  content: '';
  position: absolute;
  width: 40px;
  height: 40px;
  border: 3px solid var(--color-brass-aged);
  pointer-events: none;
}

.corner-brackets::before {
  top: -3px;
  left: -3px;
  border-right: none;
  border-bottom: none;
}

.corner-brackets::after {
  top: -3px;
  right: -3px;
  border-left: none;
  border-bottom: none;
}

/* Riveted Border */
.riveted-border {
  position: relative;
  border: 4px solid var(--color-bronze-dark);
  background: var(--color-brass-aged);
}

.riveted-border::before {
  content: '';
  position: absolute;
  inset: -2px;
  background-image:
    radial-gradient(circle, var(--color-bronze-dark) 4px, transparent 4px);
  background-size: 30px 30px;
  background-position: 0 0, 15px 15px;
  pointer-events: none;
}

/* ========== MECHANICAL BUTTONS ========== */

.brass-button {
  position: relative;
  padding: var(--spacing-sm) var(--spacing-lg);
  background: url('../assets/images/textures/brushed-alum.png'), radial-gradient(ellipse at 40% 40%, var(--color-brass-polished), var(--color-brass-aged));
  border: 3px solid var(--color-bronze-dark);
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--font-size-base);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-iron-dark);
  text-shadow: 0 1px 0 rgba(255,255,255,0.3);
  box-shadow:
    0 4px 0 var(--color-brass-oxidized),
    0 6px 8px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.4);
  cursor: pointer;
  transition: all 0.15s ease;
}

.brass-button:hover {
  background: radial-gradient(ellipse at 40% 40%, #E5B968, var(--color-brass-polished));
  box-shadow:
    0 5px 0 var(--color-brass-oxidized),
    0 8px 12px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.5);
}

.brass-button:active {
  transform: translateY(3px);
  box-shadow:
    0 1px 0 var(--color-brass-oxidized),
    0 2px 4px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.4);
}

.brass-button.active {
  box-shadow:
    0 4px 0 var(--color-brass-oxidized),
    0 6px 8px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.4),
    0 0 10px rgba(60, 130, 122, 0.3),
    inset 0 0 14px rgba(60, 130, 122, 0.1);
  border-color: rgba(60, 130, 122, 0.5);
}

/* Hexagonal Brass Plate */
.brass-hex-plate {
  position: relative;
  padding: var(--spacing-lg);
  background: linear-gradient(135deg, var(--color-brass-polished), var(--color-brass-aged));
  clip-path: polygon(30% 0%, 70% 0%, 100% 50%, 70% 100%, 30% 100%, 0% 50%);
  box-shadow: 0 8px 16px rgba(0,0,0,0.3);
}

/* ========== LEVER SWITCHES ========== */

.lever-switch {
  position: relative;
  width: 80px;
  height: 120px;
  display: inline-block;
}

.lever-base {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 30px;
  background: linear-gradient(to bottom, var(--color-brass-aged), var(--color-bronze-dark));
  border-radius: 4px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

.lever-arm {
  position: absolute;
  bottom: 25px;
  left: 50%;
  transform-origin: bottom center;
  transform: translateX(-50%) rotate(-30deg);
  width: 8px;
  height: 60px;
  background: linear-gradient(to right, var(--color-iron-dark), var(--color-steel-dark));
  border-radius: 4px;
  transition: transform 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  box-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.lever-arm::before {
  content: '';
  position: absolute;
  top: 0;
  left: -6px;
  width: 20px;
  height: 20px;
  background: radial-gradient(circle, var(--color-brass-polished), var(--color-brass-aged));
  border-radius: 50%;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.3);
}

.lever-switch.active .lever-arm {
  transform: translateX(-50%) rotate(30deg);
}

.lever-indicator {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-steel-dark);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
  transition: background 0.3s ease;
}

.lever-switch.active .lever-indicator {
  background: var(--color-indicator-green);
  box-shadow:
    inset 0 2px 4px rgba(0,0,0,0.3),
    0 0 12px var(--color-indicator-green);
}

/* ========== PRESSURE GAUGES ========== */

.pressure-gauge {
  position: relative;
  width: 140px;
  height: 140px;
  display: inline-block;
}

.gauge-bezel {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    var(--color-brass-polished) 0deg,
    var(--color-brass-aged) 90deg,
    var(--color-brass-oxidized) 180deg,
    var(--color-brass-aged) 270deg,
    var(--color-brass-polished) 360deg
  );
  box-shadow:
    inset 0 0 20px rgba(0,0,0,0.4),
    0 8px 16px rgba(0,0,0,0.3);
}

.gauge-face {
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-aged-paper), var(--color-parchment));
  box-shadow: inset 0 0 10px rgba(0,0,0,0.2);
}

.gauge-needle {
  position: absolute;
  bottom: 50%;
  left: 50%;
  width: 3px;
  height: 45%;
  background: linear-gradient(to top, var(--color-bronze-dark), var(--color-copper-bright));
  transform-origin: bottom center;
  transform: translateX(-50%) rotate(-90deg);
  border-radius: 3px 3px 0 0;
  transition: transform 1.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  box-shadow: 2px 2px 4px rgba(0,0,0,0.4);
}

.gauge-center-rivet {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-brass-polished), var(--color-bronze-dark));
  box-shadow:
    inset 0 2px 4px rgba(0,0,0,0.4),
    0 2px 4px rgba(255,255,255,0.3);
  z-index: 10;
}

.gauge-glass-shine {
  position: absolute;
  top: 15%;
  left: 20%;
  width: 35%;
  height: 35%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.4), transparent);
  pointer-events: none;
}

/* ========== ENGRAVED TEXT STYLES ========== */

.engraved-text {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-bronze-dark);
  text-shadow:
    0 1px 0 rgba(255,255,255,0.3),
    0 -1px 0 rgba(0,0,0,0.5);
}

.embossed-text {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-brass-aged);
  text-shadow:
    1px 1px 0 rgba(0,0,0,0.4),
    -1px -1px 0 rgba(255,255,255,0.3);
}

.stamped-label {
  font-family: var(--font-technical);
  font-size: var(--font-size-sm);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-iron-dark);
}

/* ========== DECORATIVE GEARS (SVG) ========== */

.gear-decoration {
  opacity: 0.85;
  filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.4));
  animation: rotate-gear 20s linear infinite;
  display: inline-block;
  vertical-align: middle;
  width: 60px;
  height: 60px;
}

.gear-decoration.absolute {
  position: absolute;
}

.gear-decoration.small {
  width: 28px;
  height: 28px;
}

.gear-decoration.medium {
  width: 60px;
  height: 60px;
}

.gear-decoration.large {
  width: 100px;
  height: 100px;
}

.gear-decoration.reverse {
  animation: rotate-gear-reverse 25s linear infinite;
}

.gear-decoration.gear {
  animation: rotate-gear 20s linear infinite;
}

.gear-decoration.gear-reverse {
  animation: rotate-gear-reverse 25s linear infinite;
}

@keyframes rotate-gear {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes rotate-gear-reverse {
  from { transform: rotate(360deg); }
  to { transform: rotate(0deg); }
}

/* ========== RIVETS ========== */

.rivet-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, var(--color-brass-aged), var(--color-bronze-dark));
  box-shadow:
    inset 0 1px 2px rgba(0,0,0,0.5),
    0 1px 2px rgba(255,255,255,0.3);
}

.rivet-dot.rivet-large {
  width: 14px;
  height: 14px;
}

/* Corner Rivets Utility */
.with-corner-rivets {
  position: relative;
}

.with-corner-rivets::before,
.with-corner-rivets::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-brass-aged) 30%, var(--color-bronze-dark) 70%);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.5);
}

.with-corner-rivets::before {
  top: 10px;
  left: 10px;
}

.with-corner-rivets::after {
  top: 10px;
  right: 10px;
}

/* ========== SECTION DECORATIVE GEARS ========== */

.section-with-gears {
  position: relative;
  overflow: hidden;
}

.section-with-gears .section-gear {
  position: absolute;
  fill: var(--color-brass-polished);
  opacity: 0.15;
  z-index: 0;
}

.section-with-gears .section-gear.top-left {
  top: -30px;
  left: -30px;
  width: 120px;
  height: 120px;
  animation: rotate-gear 30s linear infinite;
}

.section-with-gears .section-gear.top-right {
  top: -20px;
  right: -20px;
  width: 80px;
  height: 80px;
  animation: rotate-gear-reverse 25s linear infinite;
}

.section-with-gears .section-gear.bottom-right {
  bottom: -30px;
  right: -30px;
  width: 120px;
  height: 120px;
  animation: rotate-gear 35s linear infinite;
}

.section-with-gears .section-gear.bottom-left {
  bottom: -20px;
  left: -20px;
  width: 80px;
  height: 80px;
  animation: rotate-gear-reverse 28s linear infinite;
}

/* ========== STEAM EFFECTS ========== */

.steam-wisp {
  position: absolute;
  width: 40px;
  height: 40px;
  background: radial-gradient(circle, rgba(245, 241, 232, 0.6), transparent 70%);
  border-radius: 50%;
  animation: steam-rise 4s ease-out infinite;
  pointer-events: none;
}

@keyframes steam-rise {
  0% {
    opacity: 0.6;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(-80px) scale(1.8);
  }
}

.steam-wisp:nth-child(2) {
  animation-delay: 1.5s;
  left: 20%;
}

.steam-wisp:nth-child(3) {
  animation-delay: 3s;
  left: 40%;
}

/* ========== CHAIN LINKS ========== */

.chain-connector {
  position: relative;
  height: 4px;
  background: var(--color-iron-dark);
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.chain-connector::before {
  content: '';
  position: absolute;
  top: 50%;
  left: -6px;
  transform: translateY(-50%);
  width: 12px;
  height: 8px;
  border: 2px solid var(--color-iron-dark);
  border-radius: 50%;
}

.chain-connector::after {
  content: '';
  position: absolute;
  top: 50%;
  right: -6px;
  transform: translateY(-50%);
  width: 12px;
  height: 8px;
  border: 2px solid var(--color-iron-dark);
  border-radius: 50%;
}

/* ========== AGED PAPER TEXTURE ========== */

.aged-paper {
  background-color: var(--color-aged-paper);
  background-image:
    radial-gradient(circle at 20% 30%, rgba(139, 115, 85, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(139, 115, 85, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(139, 115, 85, 0.03) 0%, transparent 50%);
}

/* ========== BLUEPRINT GRID ========== */

.blueprint-grid {
  background-image:
    linear-gradient(rgba(60, 130, 122, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(60, 130, 122, 0.1) 1px, transparent 1px);
  background-size: 20px 20px;
}

/* ========== VIGNETTE EFFECT ========== */

.vignette {
  position: relative;
}

.vignette::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(58, 50, 38, 0.3) 100%);
  pointer-events: none;
}

/* ========== INDUSTRIAL TEXTURES ========== */

.brushed-brass {
  background:
    linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.1) 50%, transparent 100%),
    linear-gradient(135deg, var(--color-brass-polished), var(--color-brass-aged));
  background-size: 3px 100%, 100% 100%;
}

.oxidized-copper {
  background:
    linear-gradient(135deg, var(--color-copper-aged), var(--color-verdigris));
  background-size: 100% 100%;
}

/* ========== TECHNICAL LABEL PLATES ========== */

.label-plate {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: linear-gradient(to bottom, var(--color-brass-aged), var(--color-brass-oxidized));
  border: 2px solid var(--color-bronze-dark);
  border-radius: 2px;
  font-family: var(--font-technical);
  font-size: var(--font-size-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-iron-dark);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.3),
    0 2px 4px rgba(0,0,0,0.3);
}

/* ========== PIPE CONNECTORS ========== */

.pipe-vertical {
  width: 8px;
  background: linear-gradient(to right, var(--color-copper-aged), var(--color-copper-bright), var(--color-copper-aged));
  box-shadow:
    inset -2px 0 4px rgba(0,0,0,0.3),
    2px 0 4px rgba(0,0,0,0.2);
}

.pipe-horizontal {
  height: 8px;
  background: linear-gradient(to bottom, var(--color-copper-aged), var(--color-copper-bright), var(--color-copper-aged));
  box-shadow:
    inset 0 -2px 4px rgba(0,0,0,0.3),
    0 2px 4px rgba(0,0,0,0.2);
}

/* ========== ORNATE DIVIDERS ========== */

.brass-divider {
  height: 3px;
  background: linear-gradient(to right,
    transparent 0%,
    var(--color-brass-aged) 10%,
    var(--color-brass-polished) 50%,
    var(--color-brass-aged) 90%,
    transparent 100%);
  box-shadow: 0 1px 2px rgba(0,0,0,0.3);
  margin: var(--spacing-lg) 0;
  position: relative;
}

.brass-divider::before,
.brass-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-brass-polished), var(--color-bronze-dark));
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.4);
}

.brass-divider::before {
  left: 10%;
}

.brass-divider::after {
  right: 10%;
}

/* ========== RESPONSIVE ADJUSTMENTS ========== */

@media (prefers-reduced-motion: reduce) {
  .gear-decoration,
  .steam-wisp {
    animation: none !important;
  }
}

@media (max-width: 768px) {
  .brass-panel-heavy {
    padding: var(--spacing-md);
  }

  .pressure-gauge {
    width: 100px;
    height: 100px;
  }

  .lever-switch {
    width: 60px;
    height: 90px;
  }
}

/* ========== SECTION TITLE BAR (Obsidian Slider Style) ========== */

/*
  Mimics the nav's obsidian sliding ruler:
  dark obsidian slab, brass top/bottom borders, brass side accents,
  inner highlight, outer glow shadow — scaled up for section headings.
*/

.section-title-bar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-md);
  margin: 0 auto var(--spacing-xl) auto;

  /* Obsidian slab */
  background: linear-gradient(
    180deg,
    rgba(18, 14, 10, 0.97) 0%,
    rgba(28, 22, 16, 1)    40%,
    rgba(18, 14, 10, 0.97) 100%
  );

  /* Brass borders top & bottom, subtle side lines */
  border-top:    3px solid rgba(212, 168, 88, 0.85);
  border-bottom: 3px solid rgba(212, 168, 88, 0.85);
  border-left:   1px solid rgba(140, 110, 60, 0.5);
  border-right:  1px solid rgba(140, 110, 60, 0.5);
  border-radius: 4px;

  /* Depth: outer shadow + inner highlight + soft glow */
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.6),
    0 6px 20px rgba(0, 0, 0, 0.6),
    0 2px 6px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -1px 0 rgba(0, 0, 0, 0.6),
    inset 0 0 40px rgba(0, 0, 0, 0.3);

  /* Sizing — feel substantial but not overwhelming */
  padding: 1rem 3.5rem;
  max-width: 680px;
  width: fit-content;

  /* Overflow rivet-dots via ::before/::after */
  overflow: visible;
}

/* Brass rivet dots — real <span> elements so ::before/::after are free */
.title-rivet {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #E8C870, #A07830 60%, #6B4C20);
  box-shadow:
    0 0 0 2px rgba(140, 110, 60, 0.6),
    0 2px 4px rgba(0, 0, 0, 0.5),
    inset 0 1px 2px rgba(255, 255, 255, 0.3);
  z-index: 3;
  flex-shrink: 0;
  /* override flex positioning — use absolute */
  margin: 0;
}
.title-rivet-l { left:  1.2rem; }
.title-rivet-r { right: 1.2rem; }

/* ::before is now unused on the bar — clear it */
.section-title-bar::before { content: none; }

/* The heading text inside */
.section-title-bar h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-gold);
  text-shadow:
    0 0 12px rgba(212, 168, 88, 0.55),
    0 0 30px rgba(212, 168, 88, 0.2),
    0  1px 0 rgba(0, 0, 0, 0.8);
  margin: 0;
  padding: 0;
  line-height: 1;
  white-space: nowrap;
}

/* Tiny gear icons flanking the text (optional — add via JS or HTML) */
.section-title-bar .title-gear {
  width: 22px;
  height: 22px;
  opacity: 0.75;
  animation: rotate-gear 18s linear infinite;
  flex-shrink: 0;
}
.section-title-bar .title-gear.reverse {
  animation-direction: reverse;
  animation-duration: 22s;
}

/* On teal backgrounds, keep the slab look — no color change needed */

/* Mobile: allow text to wrap, reduce padding */
@media (max-width: 600px) {
  .section-title-bar {
    padding: 0.85rem 2.5rem;
    max-width: 95%;
  }
  .section-title-bar h2 {
    white-space: normal;
    text-align: center;
    font-size: 1.1rem;
  }
}

/* ========== GLASS GLARE ON OBSIDIAN BARS ========== */

/*
  Glass glare overlay — driven by JS (js/main.js: initGlassGlare).
  A single position:fixed element covers the viewport; JS clips it via
  clip-path to only show over .section-title-bar rects, updating on scroll
  and resize. This sidesteps the CSS limitation where background-attachment:fixed
  breaks inside overflow:clip/hidden ancestors (like .bg-cream).
*/
#glass-glare {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999; /* below sticky nav (z-index:1000) */
  background-image:
    linear-gradient(
      112deg,
      transparent            0%,
      rgba(255,255,255,0.05) 38%,
      rgba(255,255,255,0.22) 50%,
      rgba(255,255,255,0.05) 62%,
      transparent            100%
    ),
    url('/assets/images/textures/glass-overlay.png');
  background-repeat: no-repeat, repeat;
  background-size: cover, cover;
  mix-blend-mode: screen;
  /* clip-path set dynamically by JS */
  clip-path: polygon(0 0);
}
