/* ==========================================================================
   MADAMA GMBH — HYBRID EDITORIAL ATELIER DESIGN (ENTWURF 3)
   DUAL-TONE: WARM TITANIUM ALABASTER + SOVEREIGN MONOLITH ACCENTS
   ========================================================================== */

:root {
  /* Warm Titanium & Cashmere Bone Canvas */
  --h-bg: #F7F5F0;
  --h-bg-pure: #FFFFFF;
  --h-bg-warm-stone: #EFECE6;
  --h-bg-card: #FFFFFF;
  
  /* Monolithic Sovereign Contrasts (From Entwurf 1) */
  --h-navy-monolith: #0C1420;
  --h-navy-surface: #121C2B;
  --h-navy-card: #0F1726;

  /* Disciplined Corporate Metals (From Brandkit) */
  --h-champagne: #C5B8A5;
  --h-champagne-light: #F4EFEA;
  --h-champagne-dark: #8F7E6B;
  --h-champagne-gold: #B3A28D;

  /* Inks & Text Colors */
  --h-ink: #11161F;
  --h-ink-muted: #526071;
  --h-ink-dim: #8E9BAE;
  --h-ink-inverted: #F8FAFC;

  /* Technical Hairlines (Warm Brushed Titanium) */
  --h-line: #E2DDD5;
  --h-line-subtle: #ECE8E1;
  --h-line-dark: rgba(255, 255, 255, 0.12);

  /* Precise Geometry (Micro-sharp 2px architectural bevel) */
  --h-radius: 2px;

  /* Precision Technical Accents */
  --h-azure: #0284C7;
  --h-azure-signal: #38BDF8;

  /* Shadows (Haptic, tactile deboss & diffuse gallery shadows) */
  --h-shadow-sm: 0 2px 8px rgba(12, 20, 32, 0.04);
  --h-shadow-gallery: 0 16px 40px -8px rgba(12, 20, 32, 0.07);
  --h-shadow-monolith: 0 24px 60px -12px rgba(12, 20, 32, 0.35);

  /* Typography */
  --h-font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --h-font-display: 'Cinzel', 'Playfair Display', 'Newsreader', serif;
  --h-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Smooth Timing */
  --h-ease: cubic-bezier(0.16, 1, 0.3, 1);
  --h-transition: all 0.3s var(--h-ease);
}

/* Base Reset & Invariants */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--h-bg);
  color: var(--h-ink);
}

body {
  font-family: var(--h-font-sans);
  background-color: var(--h-bg);
  color: var(--h-ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 10% 15%, rgba(197, 184, 165, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 90% 75%, rgba(12, 20, 32, 0.03) 0%, transparent 50%);
}

.madama-container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 32px;
}

@media (max-width: 768px) {
  .madama-container {
    padding: 0 20px;
  }
}

/* Headings with Editorial Sophistication */
h1, h2, h3, h4, h5, h6 {
  color: var(--h-ink);
  line-height: 1.18;
  letter-spacing: -0.015em;
  font-weight: 500;
}

.display-title {
  font-family: var(--h-font-sans);
  font-weight: 400;
  letter-spacing: -0.025em;
}

.display-title strong {
  font-weight: 600;
  color: var(--h-ink);
}

.serif-accent {
  font-family: var(--h-font-display);
  font-style: italic;
  font-weight: 400;
  color: var(--h-champagne-dark);
}

.meta-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--h-font-mono);
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--h-champagne-dark);
  margin-bottom: 16px;
}

.meta-eyebrow::before {
  content: '';
  display: inline-block;
  width: 18px;
  height: 1px;
  background: var(--h-champagne-gold);
}

/* Top Dual-Tone Switcher Bar (Institutional Cockpit) */
.hybrid-topbar {
  background: var(--h-bg-warm-stone);
  border-bottom: 1px solid var(--h-line);
  font-size: 0.78rem;
  padding: 8px 0;
  position: relative;
  z-index: 1002;
  width: 100%;
}

.hybrid-topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.hybrid-brand-list {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
  flex-shrink: 1;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.hybrid-brand-list::-webkit-scrollbar {
  display: none;
}

.hybrid-brand-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--h-ink-muted);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  white-space: nowrap;
  transition: var(--h-transition);
}

.hybrid-brand-link:hover {
  color: var(--h-ink);
}

.hybrid-brand-link.active {
  color: var(--h-ink);
  font-weight: 600;
}

.pill-dot-hybrid {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--h-champagne-dark);
  flex-shrink: 0;
}

.pill-dot-hybrid.tech {
  background: var(--h-azure);
  box-shadow: 0 0 6px rgba(2, 132, 199, 0.4);
}

/* Dedicated Topbar Hotline & Status Section (Guaranteed No-Cutoff) */
.hybrid-topbar-hotline {
  font-family: var(--h-font-mono);
  font-size: 0.74rem;
  color: var(--h-ink-muted);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  white-space: nowrap;
  margin-left: auto;
}

.topbar-phone-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.topbar-phone-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--h-ink);
  text-decoration: none;
  font-weight: 600;
  padding: 3px 10px;
  background: #FFFFFF;
  border: 1px solid var(--h-line);
  border-radius: var(--h-radius);
  transition: var(--h-transition);
  white-space: nowrap;
  box-shadow: var(--h-shadow-sm);
}

.topbar-phone-link:hover {
  background: var(--h-navy-monolith);
  color: var(--h-ink-inverted);
  border-color: var(--h-navy-monolith);
  transform: translateY(-1px);
}

.topbar-phone-link svg {
  flex-shrink: 0;
  stroke: currentColor;
}

@media (max-width: 1240px) {
  .topbar-subtext {
    display: none;
  }
}

@media (max-width: 960px) {
  .topbar-location,
  .topbar-separator {
    display: none;
  }
}

@media (max-width: 680px) {
  .hybrid-topbar-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  .hybrid-topbar-hotline {
    margin-left: 0;
    justify-content: space-between;
    width: 100%;
    padding-top: 6px;
    border-top: 1px solid rgba(12, 20, 32, 0.06);
  }
  .topbar-phone-link {
    font-size: 0.8rem;
    padding: 4px 10px;
  }
}

/* Header: Warm Atelier Glass */
.hybrid-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(247, 245, 240, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--h-line);
  transition: padding 0.3s var(--h-ease), background 0.3s var(--h-ease), box-shadow 0.3s var(--h-ease);
}

.hybrid-header.is-scrolled {
  background: rgba(247, 245, 240, 0.98);
  box-shadow: 0 10px 30px -10px rgba(12, 20, 32, 0.08);
  border-bottom-color: rgba(197, 184, 165, 0.4);
}

.hybrid-header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 86px;
  transition: height 0.3s var(--h-ease);
}

.hybrid-header.is-scrolled .hybrid-header-inner {
  height: 72px;
}

.nav-links-list {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
}

.nav-link-item {
  color: var(--h-ink-muted);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 8px 0;
  position: relative;
  transition: var(--h-transition);
}

.nav-link-item:hover,
.nav-link-item.active {
  color: var(--h-ink);
}

.nav-link-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--h-champagne-dark);
  transition: width 0.28s var(--h-ease);
}

.nav-link-item:hover::after,
.nav-link-item.active::after {
  width: 100%;
}

/* Hybrid Buttons (Kantig & Haptisch) */
.btn-hybrid {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--h-radius);
  font-family: var(--h-font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: var(--h-transition);
  border: 1px solid transparent;
}

.btn-monolith {
  background: var(--h-navy-monolith);
  color: #FFFFFF;
  border-color: var(--h-navy-monolith);
  box-shadow: 0 4px 14px rgba(12, 20, 32, 0.15);
}

.btn-monolith:hover {
  background: #182436;
  border-color: #182436;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(12, 20, 32, 0.25);
}

.btn-titanium-outline {
  background: transparent;
  color: var(--h-ink);
  border-color: var(--h-champagne-dark);
}

.btn-titanium-outline:hover {
  background: var(--h-champagne-light);
  border-color: var(--h-ink);
  transform: translateY(-2px);
}

/* Hero: Warm Atelier with Monolith Contrasts */
.hero-hybrid {
  padding: 90px 0 80px;
  position: relative;
}

.hero-hybrid-grid {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 56px;
  align-items: center;
}

.hero-main-title {
  font-size: clamp(2.3rem, 4.4vw, 4.1rem);
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-paragraph {
  font-size: 1.12rem;
  color: var(--h-ink-muted);
  line-height: 1.7;
  max-width: 620px;
  margin-bottom: 34px;
}

/* Badges Strip */
.badges-strip-hybrid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 36px;
}

.badge-hybrid-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border: 1px solid var(--h-line);
  background: #FFFFFF;
  border-radius: var(--h-radius);
  font-family: var(--h-font-mono);
  font-size: 0.73rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--h-ink);
  box-shadow: var(--h-shadow-sm);
}

/* The Monolithic B2B Calculator (Dark Slate in Warm Canvas) */
.calc-monolith-card {
  background: var(--h-navy-monolith);
  border: 1px solid rgba(197, 184, 165, 0.3);
  border-radius: var(--h-radius);
  padding: 38px;
  color: #FFFFFF;
  box-shadow: var(--h-shadow-monolith);
  position: relative;
  overflow: hidden;
}

.calc-monolith-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #F2ECE4, #C5B8A5, #8F7E6B);
}

.calc-monolith-header {
  border-bottom: 1px solid var(--h-line-dark);
  padding-bottom: 16px;
  margin-bottom: 22px;
}

.calc-input-dark {
  width: 100%;
  padding: 12px 14px;
  background: var(--h-navy-surface);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--h-radius);
  color: #FFFFFF;
  font-family: var(--h-font-sans);
  font-size: 0.92rem;
  outline: none;
  transition: var(--h-transition);
}

.calc-input-dark:focus {
  border-color: var(--h-champagne);
}

.calc-slider-dark {
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.15);
  outline: none;
  -webkit-appearance: none;
  border-radius: 2px;
  margin: 14px 0 6px;
}

.calc-slider-dark::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--h-champagne);
  box-shadow: 0 0 10px rgba(197, 184, 165, 0.6);
  cursor: pointer;
}

.calc-result-box-dark {
  background: rgba(7, 11, 18, 0.7);
  border: 1px dashed rgba(197, 184, 165, 0.4);
  border-radius: var(--h-radius);
  padding: 20px;
  text-align: center;
  margin: 22px 0 18px;
}

/* Holding Matrix: Architectural Atelier Gallery */
.section-atelier {
  padding: 100px 0;
  border-top: 1px solid var(--h-line);
  background: #FFFFFF;
}

.atelier-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
  margin-top: 48px;
}

.atelier-card {
  background: var(--h-bg);
  border: 1px solid var(--h-line);
  border-radius: var(--h-radius);
  padding: 36px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: var(--h-transition);
  position: relative;
}

/* Masterclass Hover System (Haptic Precision & Champagne Sheen) */
.atelier-card {
  position: relative;
  background: #FFFFFF;
  border: 1px solid var(--h-line);
  border-radius: var(--h-radius);
  padding: 36px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.4s var(--h-ease),
              background 0.4s var(--h-ease);
  will-change: transform, box-shadow;
}

.atelier-card:hover {
  background: #FFFFFF;
  border-color: var(--h-champagne-gold);
  box-shadow: 0 20px 48px -10px rgba(12, 20, 32, 0.10), 0 0 0 1px rgba(197, 184, 165, 0.35);
  transform: translateY(-6px);
}

.atelier-card.flagship-card {
  border-color: rgba(197, 184, 165, 0.6);
  background: linear-gradient(180deg, #FFFFFF 0%, var(--h-bg) 100%);
}

.atelier-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 22px;
}

.entity-glyph-box {
  width: 44px;
  height: 44px;
  border: 1px solid var(--h-line);
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--h-radius);
  transition: var(--h-transition);
}

.atelier-card:hover .entity-glyph-box {
  border-color: var(--h-champagne-dark);
  box-shadow: 0 4px 14px rgba(197, 184, 165, 0.25);
  transform: scale(1.05);
}

/* Facility Services Grid in Warm Stone */
.services-section-warm {
  padding: 100px 0;
  border-top: 1px solid var(--h-line);
  background: var(--h-bg);
}

.services-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
  margin-top: 48px;
}

.service-gallery-card {
  background: #FFFFFF;
  border: 1px solid var(--h-line);
  border-radius: var(--h-radius);
  padding: 34px;
  transition: transform 0.4s var(--h-ease), box-shadow 0.4s var(--h-ease), border-color 0.3s ease;
  will-change: transform, box-shadow;
}

.service-gallery-card:hover {
  border-color: var(--h-ink);
  box-shadow: 0 16px 40px -10px rgba(12, 20, 32, 0.12), 0 0 0 1px var(--h-champagne-dark);
  transform: translateY(-5px);
}

/* Interactive Monolith Hero & Calc Tilt Card */
.tilt-card {
  transition: transform 0.15s ease-out, box-shadow 0.3s ease;
  transform-style: preserve-3d;
}

.calc-monolith-card {
  background: var(--h-navy-monolith);
  color: var(--h-ink-inverted);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--h-radius);
  padding: 38px;
  box-shadow: var(--h-shadow-monolith);
  transition: transform 0.4s var(--h-ease), box-shadow 0.4s var(--h-ease), border-color 0.4s var(--h-ease);
  position: relative;
  overflow: hidden;
}

.calc-monolith-card:hover {
  border-color: rgba(197, 184, 165, 0.5);
  box-shadow: 0 30px 70px -15px rgba(12, 20, 32, 0.5), 0 0 0 1px rgba(197, 184, 165, 0.3);
}

/* Atmospheric Ambient Orbs for Depth */
.bg-ambient-orb {
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(80px);
  opacity: 0.22;
  z-index: 0;
  transition: transform 0.8s ease-out;
}

.bg-ambient-orb.orb-champagne {
  background: radial-gradient(circle, var(--h-champagne) 0%, transparent 70%);
  top: -120px;
  right: -80px;
}

.bg-ambient-orb.orb-azure {
  background: radial-gradient(circle, rgba(2, 132, 199, 0.25) 0%, transparent 70%);
  bottom: -100px;
  left: -80px;
}

/* Parallax Scrolling Drivers */
[data-parallax] {
  will-change: transform;
}

.parallax-slow {
  transition: transform 0.1s cubic-bezier(0, 0, 0.2, 1);
}

/* Comprehensive Scroll Animations */
.scroll-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.85s var(--h-ease), transform 0.85s var(--h-ease);
  will-change: opacity, transform;
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.scroll-reveal-left {
  opacity: 0;
  transform: translateX(-35px);
  transition: opacity 0.85s var(--h-ease), transform 0.85s var(--h-ease);
}

.scroll-reveal-left.revealed {
  opacity: 1;
  transform: translateX(0);
}

.scroll-reveal-right {
  opacity: 0;
  transform: translateX(35px);
  transition: opacity 0.85s var(--h-ease), transform 0.85s var(--h-ease);
}

.scroll-reveal-right.revealed {
  opacity: 1;
  transform: translateX(0);
}

.scroll-reveal-scale {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.85s var(--h-ease), transform 0.85s var(--h-ease);
}

.scroll-reveal-scale.revealed {
  opacity: 1;
  transform: scale(1);
}

/* Stagger Children Helper */
.stagger-parent > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s var(--h-ease), transform 0.6s var(--h-ease);
}

.stagger-parent.revealed > * {
  opacity: 1;
  transform: translateY(0);
}

.stagger-parent.revealed > *:nth-child(1) { transition-delay: 0.05s; }
.stagger-parent.revealed > *:nth-child(2) { transition-delay: 0.12s; }
.stagger-parent.revealed > *:nth-child(3) { transition-delay: 0.19s; }
.stagger-parent.revealed > *:nth-child(4) { transition-delay: 0.26s; }
.stagger-parent.revealed > *:nth-child(5) { transition-delay: 0.33s; }
.stagger-parent.revealed > *:nth-child(6) { transition-delay: 0.40s; }

/* Micro-Interaction on Magnetic / Tactical Buttons */
.btn-hybrid-primary, .btn-hybrid-secondary, .btn-hybrid-dark {
  position: relative;
  overflow: hidden;
  will-change: transform;
}

.btn-hybrid-primary::after, .btn-hybrid-dark::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  transform: skewX(-20deg);
  transition: none;
}

.btn-hybrid-primary:hover::after, .btn-hybrid-dark:hover::after {
  left: 150%;
  transition: left 0.75s var(--h-ease);
}

/* RFQ Gateway in Hybrid Contrast */
.rfq-hybrid-section {
  padding: 100px 0;
  background: var(--h-bg-warm-stone);
  border-top: 1px solid var(--h-line);
}

.rfq-card-atelier {
  background: #FFFFFF;
  border: 1px solid var(--h-line);
  border-radius: var(--h-radius);
  padding: 48px;
  box-shadow: var(--h-shadow-gallery);
  max-width: 900px;
  margin: 0 auto;
  transition: transform 0.4s var(--h-ease), box-shadow 0.4s var(--h-ease);
}

.rfq-card-atelier:hover {
  box-shadow: 0 24px 60px -12px rgba(12, 20, 32, 0.12);
}

/* Footer Dual-Tone (Master Sovereign Navy Footer) */
.footer-hybrid {
  background: var(--h-navy-monolith);
  color: var(--h-ink-inverted);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 84px 0 36px;
  position: relative;
  z-index: 10;
}

.footer-hybrid-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 44px;
  margin-bottom: 60px;
}

.footer-hybrid a {
  transition: color 0.25s var(--h-ease), transform 0.25s var(--h-ease);
  display: inline-block;
}

.footer-hybrid a:hover {
  color: #FFFFFF !important;
  transform: translateX(2px);
}

.footer-hybrid-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-family: var(--h-font-mono);
  font-size: 0.74rem;
  color: #64748B;
}

@media (max-width: 1024px) {
  .hero-hybrid-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .footer-hybrid-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 640px) {
  .footer-hybrid-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .footer-hybrid-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
  .rfq-card-atelier {
    padding: 24px;
  }
}
