/* ============================================================
   MAXIMILIAN SCHMITT – Main Stylesheet
   Digital Analytics & Tracking-Experte
   ============================================================ */

/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700;900&family=DM+Sans:wght@300;400;500;600&display=swap');

/* ── CSS Custom Properties ── */
:root {
  /* Brand Colors */
  --color-gold:        #9a7e3f;
  --color-gold-light:  #b8973f;
  --color-gold-dark:   #7a6230;
  --color-orange:      #f5a623;
  --color-orange-dark: #d4891a;

  /* Neutrals */
  --color-bg:          #fdfaf4;
  --color-bg-section:  #f5f0e4;
  --color-dark:        #1a1a1a;
  --color-dark-footer: #1e1e1e;
  --color-text:        #2d2d2d;
  --color-text-muted:  #6b6b6b;
  --color-white:       #ffffff;
  --color-border:      #e5dcc8;

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  /* Spacing Scale */
  --space-xs:  0.5rem;
  --space-sm:  1rem;
  --space-md:  1.5rem;
  --space-lg:  2.5rem;
  --space-xl:  4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;

  /* Layout */
  --container-max: 1200px;
  --container-pad: 1.5rem;
  --border-radius: 8px;
  --border-radius-lg: 16px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.16);

  /* Transitions */
  --transition: 0.25s ease;
  --transition-slow: 0.4s ease;
}

/* ── Reset & Base ── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

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

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

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

/* ── Focus Styles (BFSG / WCAG 2.1 AA) ── */
:focus-visible {
  outline: 3px solid var(--color-orange);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ── Skip Link (Accessibility) ── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--color-orange);
  color: var(--color-dark);
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  z-index: 9999;
  transition: top var(--transition);
}

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

/* ── Screen Reader Only ── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Container ── */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

/* ── Section Base ── */
.section {
  padding-block: var(--space-2xl);
}

.section--alt {
  background-color: var(--color-bg-section);
}

.section--dark {
  background-color: var(--color-dark);
  color: var(--color-white);
}

/* ── Section Label ── */
.section-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.section--dark .section-label {
  color: var(--color-orange);
}

/* ── Headings ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  line-height: 1.2;
  font-weight: 700;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.6rem); }
h4 { font-size: 1.1rem; font-family: var(--font-body); }

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: all var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
}

.btn--primary {
  background-color: var(--color-orange);
  color: var(--color-dark);
  border-color: var(--color-orange);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background-color: var(--color-orange-dark);
  border-color: var(--color-orange-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(245, 166, 35, 0.35);
}

.btn--outline {
  background-color: transparent;
  color: var(--color-dark);
  border-color: var(--color-dark);
}

.btn--outline:hover,
.btn--outline:focus-visible {
  background-color: var(--color-dark);
  color: var(--color-white);
  transform: translateY(-2px);
}

.btn--outline-light {
  background-color: transparent;
  color: var(--color-white);
  border-color: var(--color-white);
}

.btn--outline-light:hover {
  background-color: var(--color-white);
  color: var(--color-dark);
}

.btn--sm {
  padding: 0.6rem 1.4rem;
  font-size: 0.875rem;
}

/* ── Cards ── */
.card {
  background: var(--color-white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  border: 1px solid var(--color-border);
}

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

.card__icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--color-orange), var(--color-gold));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
  font-size: 1.4rem;
  color: var(--color-white);
}

.card__title {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--color-dark);
}

.card__text {
  color: var(--color-text-muted);
  font-size: 0.925rem;
  line-height: 1.6;
}

/* ── Grid Utilities ── */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}

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

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

.grid-split--reverse > *:first-child {
  order: 2;
}

.grid-split--reverse > *:last-child {
  order: 1;
}

/* ── Text Utilities ── */
.text-center { text-align: center; }
.text-gold   { color: var(--color-gold); }
.text-orange { color: var(--color-orange); }
.text-muted  { color: var(--color-text-muted); }

.lead {
  font-size: 1.125rem;
  line-height: 1.75;
  color: var(--color-text-muted);
}

/* ── Divider ── */
.divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-orange), var(--color-gold));
  border-radius: 2px;
  margin: var(--space-sm) auto var(--space-lg);
}

.divider--left {
  margin-left: 0;
}

/* ── Page Hero (Subpages) ── */
.page-hero {
  background: linear-gradient(135deg, var(--color-gold-dark) 0%, var(--color-gold) 60%, var(--color-gold-light) 100%);
  /* Desktop: nav = 72px fixed + comfortable breathing room */
  padding: calc(72px + 4rem) 0 4rem;
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: rgba(255,255,255,0.04);
  border-radius: 50%;
  pointer-events: none;
}

.page-hero .section-label {
  color: rgba(255,255,255,0.75);
}

.page-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
}

/* ── Breadcrumb ── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;           /* slightly larger base size */
  font-weight: 500;
  margin-bottom: 1.25rem;
  color: rgba(255,255,255,0.9); /* higher contrast: 90% instead of 70% */
  flex-wrap: wrap;
  line-height: 1.5;
}

.breadcrumb a {
  color: #ffd97a;              /* lighter gold – better contrast on dark gold bg */
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: opacity var(--transition);
  /* Tap target: at least 44×44px */
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding-inline: 0.1rem;
}

.breadcrumb a:hover { opacity: 0.8; }

.breadcrumb__sep {
  opacity: 0.6;
  font-size: 0.8rem;
  user-select: none;
}

/* ── CTA Section ── */
.cta-section {
  background: linear-gradient(135deg, var(--color-dark) 0%, #2d2417 100%);
  padding: var(--space-2xl) 0;
  text-align: center;
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  bottom: -80px;
  left: -80px;
  width: 300px;
  height: 300px;
  background: rgba(245,166,35,0.06);
  border-radius: 50%;
}

.cta-section::after {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 250px;
  height: 250px;
  background: rgba(154,126,63,0.08);
  border-radius: 50%;
}

.cta-section .container { position: relative; z-index: 1; }

.cta-section h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  margin-bottom: var(--space-sm);
}

.cta-section p {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.75);
  margin-bottom: var(--space-lg);
  max-width: 560px;
  margin-inline: auto;
  margin-bottom: var(--space-lg);
}

/* ── Badges ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(245,166,35,0.12);
  color: var(--color-orange-dark);
  border: 1px solid rgba(245,166,35,0.25);
  border-radius: 50px;
  padding: 0.3rem 0.9rem;
  font-size: 0.8rem;
  font-weight: 600;
}

/* ── Stats Row ── */
.stats-row {
  display: flex;
  gap: var(--space-xl);
  flex-wrap: wrap;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat__number {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--color-orange);
  line-height: 1;
}

.stat__label {
  font-size: 0.875rem;
  color: rgba(255,255,255,0.65);
  margin-top: 0.25rem;
}

/* ── Form Styles ── */
.form-group {
  margin-bottom: var(--space-md);
}

.form-label {
  display: block;
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--color-dark);
}

.form-control {
  width: 100%;
  padding: 0.85rem 1.1rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--border-radius);
  background: var(--color-white);
  color: var(--color-text);
  font-size: 0.95rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-orange);
  box-shadow: 0 0 0 3px rgba(245,166,35,0.15);
}

.form-control::placeholder {
  color: #aaa;
}

textarea.form-control {
  resize: vertical;
  min-height: 140px;
}

.form-note {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-top: 0.35rem;
}

/* ── Footer ── */
.footer {
  background-color: var(--color-dark-footer);
  color: rgba(255,255,255,0.8);
  padding-top: var(--space-2xl);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: var(--space-xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer__brand .footer-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--color-white);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-sm);
}

.footer__brand p {
  font-size: 0.9rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.55);
  max-width: 280px;
}

.footer__heading {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-orange);
  margin-bottom: var(--space-md);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer__links a {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.6);
  transition: color var(--transition);
}

.footer__links a:hover {
  color: var(--color-orange);
}

.footer__social {
  display: flex;
  gap: 0.75rem;
  margin-top: var(--space-sm);
}

.social-icon {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.08);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.7);
  transition: all var(--transition);
  font-size: 1rem;
}

.social-icon:hover {
  background: var(--color-orange);
  color: var(--color-dark);
  transform: translateY(-2px);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-block: var(--space-md);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.4);
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer__bottom a {
  color: var(--color-orange);
  transition: opacity var(--transition);
}

.footer__bottom a:hover { opacity: 0.8; }

.footer__legal {
  display: flex;
  gap: 1.5rem;
}

/* ── Animations ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

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

.animate-in {
  opacity: 0;
}

.animate-in.visible {
  animation: fadeInUp 0.6s ease forwards;
}

.animate-in[data-delay="1"] { animation-delay: 0.1s; }
.animate-in[data-delay="2"] { animation-delay: 0.2s; }
.animate-in[data-delay="3"] { animation-delay: 0.3s; }
.animate-in[data-delay="4"] { animation-delay: 0.4s; }
.animate-in[data-delay="5"] { animation-delay: 0.5s; }

/* ── Reduced Motion ── */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
