/* =========================================================
   RSM Onepage – main.css
   Reinigungs-Service Michel GmbH | media-line
   ========================================================= */

/* ---------- Custom Properties ---------- */
:root {
  --brand:        #009FE3;
  --brand-dark:   #0077B6;
  --brand-darker: #023E6B;
  --brand-soft:   #E5F6FD;

  --bg:           #ffffff;
  --bg-alt:       #f4fafe;
  --bg-card:      #ffffff;
  --surface:      #ffffff;
  --text:         #1a2c38;
  --text-soft:    #4a5b66;
  --text-muted:   #7c8a93;
  --border:       #e4edf2;
  --shadow:       0 4px 24px rgba(2, 62, 107, 0.08);
  --shadow-lg:    0 18px 50px rgba(2, 62, 107, 0.16);
  --header-bg:    rgba(255, 255, 255, 0.92);

  --radius:       16px;
  --radius-sm:    10px;
  --maxw:         1180px;
  --header-h:     76px;

  --ff-display:   "Poppins", "Segoe UI", system-ui, sans-serif;
  --ff-body:      "Inter", "Segoe UI", system-ui, sans-serif;

  --t-fast: .18s ease;
  --t:      .3s cubic-bezier(.4,0,.2,1);
}

html[data-theme="dark"] {
  --brand:        #2fb6f0;
  --brand-dark:   #1a93cf;
  --brand-darker: #8fd6f4;
  --brand-soft:   #11303f;

  --bg:           #0c1820;
  --bg-alt:       #0f1f2a;
  --bg-card:      #142733;
  --surface:      #142733;
  --text:         #e8f1f6;
  --text-soft:    #b2c4ce;
  --text-muted:   #7f95a1;
  --border:       #1f3a49;
  --shadow:       0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg:    0 18px 50px rgba(0, 0, 0, 0.55);
  --header-bg:    rgba(12, 24, 32, 0.92);
}

/* ---------- Reset / Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--ff-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background var(--t), color var(--t);
  overflow-x: hidden;
}

h1, h2, h3, h4 { font-family: var(--ff-display); line-height: 1.15; color: var(--text); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.6rem); margin: 0 0 .6em; }
h3 { font-size: 1.25rem; margin: 0 0 .4em; }
p  { margin: 0 0 1.1em; color: var(--text-soft); }
a  { color: var(--brand-dark); text-decoration: none; transition: color var(--t-fast); }
a:hover { color: var(--brand); }
img { max-width: 100%; height: auto; display: block; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 24px; }
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section--alt { background: var(--bg-alt); }

.eyebrow {
  display: inline-block;
  font-family: var(--ff-display);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: .8em;
}
.section-head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.section-head p { font-size: 1.08rem; }

/* ---------- Buttons ---------- */
.btn {
  --b: var(--brand);
  display: inline-flex; align-items: center; gap: .55em;
  font-family: var(--ff-display); font-weight: 600; font-size: 1rem;
  padding: 14px 28px; border-radius: 999px; border: 2px solid var(--b);
  cursor: pointer; transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast), color var(--t-fast);
}
.btn--primary { background: var(--b); color: #fff; box-shadow: 0 8px 24px rgba(0,159,227,.32); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0,159,227,.42); color:#fff; }
.btn--ghost { background: transparent; color: var(--brand-dark); }
.btn--ghost:hover { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-2px); }
html[data-theme="dark"] .btn--ghost { color: var(--text); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  height: var(--header-h);
  background: var(--header-bg);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t), box-shadow var(--t), background var(--t);
}
.site-header.is-scrolled { border-bottom-color: var(--border); box-shadow: 0 4px 20px rgba(2,62,107,.06); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { height: 38px; width: auto; }
.brand span.brand-fallback {
  font-family: var(--ff-display); font-weight: 700; font-size: 1.15rem; color: var(--brand-dark);
  letter-spacing: .02em;
}

.main-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block; padding: 8px 14px; border-radius: 8px;
  font-family: var(--ff-display); font-weight: 500; font-size: .96rem;
  color: var(--text-soft);
}
.main-nav a:hover, .main-nav a.is-active { color: var(--brand-dark); background: var(--brand-soft); }

.header-actions { display: flex; align-items: center; gap: 10px; }

.theme-toggle, .nav-toggle {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}
.theme-toggle:hover, .nav-toggle:hover { border-color: var(--brand); color: var(--brand); }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .icon-sun  { display: none; }
html[data-theme="dark"] .theme-toggle .icon-sun  { display: block; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

.nav-toggle { display: none; }
.nav-toggle svg { width: 22px; height: 22px; }

.header-cta { margin-left: 4px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding-top: calc(var(--header-h) + clamp(48px, 8vw, 96px));
  padding-bottom: clamp(56px, 9vw, 110px);
  background:
    radial-gradient(1100px 540px at 88% -10%, var(--brand-soft) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 100%);
  overflow: hidden;
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.1rem, 5.2vw, 3.6rem);
  letter-spacing: -.01em; margin: 0 0 .5em;
}
.hero h1 .accent { color: var(--brand); }
.hero-lead { font-size: clamp(1.05rem, 1.6vw, 1.22rem); max-width: 540px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 8px; }

.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 22px; }
.badge {
  display: inline-flex; align-items: center; gap: .5em;
  background: var(--surface); border: 1px solid var(--border); color: var(--text-soft);
  font-family: var(--ff-display); font-weight: 500; font-size: .85rem;
  padding: 7px 14px; border-radius: 999px; box-shadow: var(--shadow);
}
.badge svg { width: 16px; height: 16px; color: var(--brand); }

.hero-media { position: relative; }
.hero-media .ph {
  aspect-ratio: 4 / 5; border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}
.hero-media .float-card {
  position: absolute; left: -18px; bottom: 26px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
  padding: 16px 20px; display: flex; align-items: center; gap: 14px;
}
.float-card .num { font-family: var(--ff-display); font-weight: 800; font-size: 1.9rem; color: var(--brand); line-height: 1; }
.float-card .lbl { font-size: .82rem; color: var(--text-muted); line-height: 1.3; }

/* ---------- Image Placeholder ---------- */
.ph {
  position: relative; width: 100%;
  background:
    repeating-linear-gradient(45deg, var(--brand-soft) 0 14px, transparent 14px 28px),
    linear-gradient(135deg, var(--brand) 0%, var(--brand-dark) 100%);
  display: flex; align-items: center; justify-content: center;
  color: #fff; overflow: hidden;
}
.ph::after {
  content: attr(data-label);
  font-family: var(--ff-display); font-weight: 600; font-size: .8rem;
  letter-spacing: .12em; text-transform: uppercase;
  background: rgba(255,255,255,.18); backdrop-filter: blur(4px);
  padding: 7px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.4);
}

/* ---------- USP Strip ---------- */
.usp {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  margin-top: -1px;
}
.usp-item { text-align: center; padding: 8px; }
.usp-item .ico {
  width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 16px;
  background: var(--brand-soft); color: var(--brand);
  display: flex; align-items: center; justify-content: center;
}
.usp-item .ico svg { width: 28px; height: 28px; }
.usp-item strong { display: block; font-family: var(--ff-display); font-size: 1.05rem; color: var(--text); }
.usp-item span { font-size: .92rem; color: var(--text-muted); }

/* ---------- Services ---------- */
.services-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px;
}
.service-card {
  position: relative; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 32px 28px;
  box-shadow: var(--shadow);
  transition: transform var(--t), box-shadow var(--t), border-color var(--t);
  overflow: hidden;
}
.service-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-dark));
  transform: scaleX(0); transform-origin: left; transition: transform var(--t);
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--brand-soft); }
.service-card:hover::before { transform: scaleX(1); }
.service-card .ico {
  width: 60px; height: 60px; border-radius: 16px; margin-bottom: 20px;
  background: var(--brand-soft); color: var(--brand);
  display: flex; align-items: center; justify-content: center;
}
.service-card .ico svg { width: 30px; height: 30px; }
.service-card h3 { color: var(--text); }
.service-card p { font-size: .98rem; margin: 0; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: clamp(32px, 5vw, 70px); align-items: center; }
.about-media .ph { aspect-ratio: 5 / 4; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.about-list { list-style: none; padding: 0; margin: 22px 0 28px; display: grid; gap: 12px; }
.about-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--text-soft); }
.about-list svg { flex: 0 0 auto; width: 22px; height: 22px; color: var(--brand); margin-top: 3px; }
.owner-line { display: flex; align-items: center; gap: 14px; margin-top: 8px; }
.owner-line .ph { width: 58px; height: 58px; border-radius: 50%; flex: 0 0 auto; }
.owner-line .ph::after { display: none; }
.owner-line strong { font-family: var(--ff-display); color: var(--text); display: block; }
.owner-line span { font-size: .9rem; color: var(--text-muted); }

/* ---------- Stats banner ---------- */
.stats {
  background: linear-gradient(120deg, var(--brand-dark), var(--brand));
  border-radius: var(--radius); padding: clamp(36px, 5vw, 56px);
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
  color: #fff; box-shadow: var(--shadow-lg);
}
.stat { text-align: center; }
.stat .n { font-family: var(--ff-display); font-weight: 800; font-size: clamp(1.9rem, 4vw, 2.8rem); line-height: 1; }
.stat .t { font-size: .9rem; opacity: .92; margin-top: 8px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 4vw, 56px); align-items: start; }
.contact-info { display: grid; gap: 16px; margin: 24px 0 28px; }
.contact-info .row { display: flex; gap: 14px; align-items: flex-start; }
.contact-info .row .ico {
  width: 44px; height: 44px; flex: 0 0 auto; border-radius: 12px;
  background: var(--brand-soft); color: var(--brand);
  display: flex; align-items: center; justify-content: center;
}
.contact-info .row .ico svg { width: 22px; height: 22px; }
.contact-info .row .meta span { display: block; font-size: .82rem; color: var(--text-muted); }
.contact-info .row .meta a, .contact-info .row .meta strong { font-family: var(--ff-display); color: var(--text); font-weight: 600; }
.contact-info .row .meta a:hover { color: var(--brand); }

/* CF7 styling */
.form-wrap { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: clamp(24px, 3vw, 38px); box-shadow: var(--shadow); }
.form-wrap .wpcf7 p { margin: 0 0 16px; }
.form-wrap label { display: block; font-family: var(--ff-display); font-weight: 500; font-size: .92rem; color: var(--text); margin-bottom: 6px; }
.form-wrap input[type=text],
.form-wrap input[type=email],
.form-wrap input[type=tel],
.form-wrap textarea {
  width: 100%; font-family: var(--ff-body); font-size: 1rem; color: var(--text);
  background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 13px 15px; transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.form-wrap input:focus, .form-wrap textarea:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(0,159,227,.15);
}
.form-wrap textarea { min-height: 130px; resize: vertical; }
.form-wrap .wpcf7-list-item { margin: 0; }
.form-wrap input[type=submit] {
  font-family: var(--ff-display); font-weight: 600; font-size: 1rem; cursor: pointer;
  background: var(--brand); color: #fff; border: none; border-radius: 999px;
  padding: 14px 34px; transition: transform var(--t-fast), box-shadow var(--t-fast);
  box-shadow: 0 8px 24px rgba(0,159,227,.32);
}
.form-wrap input[type=submit]:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0,159,227,.42); }
.form-wrap .acceptance-line { font-size: .85rem; color: var(--text-muted); }
.form-wrap .acceptance-line a { text-decoration: underline; }
.wpcf7-not-valid-tip { color: #d33; font-size: .82rem; }
.wpcf7 form .wpcf7-response-output { border-radius: var(--radius-sm); font-size: .92rem; margin: 8px 0 0; }

.form-fallback p { margin: 0 0 14px; }
.form-fallback .field { margin-bottom: 16px; }
.form-fallback label { display:block; font-family: var(--ff-display); font-weight:500; font-size:.92rem; margin-bottom:6px; }
.form-fallback input, .form-fallback textarea {
  width:100%; font-size:1rem; background: var(--bg-alt); border:1px solid var(--border);
  border-radius: var(--radius-sm); padding:13px 15px; color: var(--text);
}

/* ---------- Map ---------- */
.map-wrap { margin-top: 56px; }
#rsm-map {
  height: 420px; width: 100%; border-radius: var(--radius);
  border: 1px solid var(--border); box-shadow: var(--shadow); z-index: 1;
  background: var(--bg-alt);
}
.leaflet-container { font-family: var(--ff-body); border-radius: var(--radius); }

/* ---------- Footer ---------- */
.site-footer { background: var(--brand-darker); color: #cfe8f6; padding: 64px 0 28px; }
html[data-theme="dark"] .site-footer { background: #081117; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-footer h4 { color: #fff; font-family: var(--ff-display); font-size: 1.05rem; margin: 0 0 16px; }
.site-footer a { color: #cfe8f6; }
.site-footer a:hover { color: #fff; }
.site-footer p { color: #a9cfe4; }
.footer-logo { height: 40px; margin-bottom: 16px; filter: brightness(0) invert(1); }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer-bottom {
  margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.14);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  font-size: .86rem; color: #8fb8cf;
}
.footer-bottom a { color: #8fb8cf; }
.footer-bottom .legal { display: flex; gap: 18px; flex-wrap: wrap; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed; right: 22px; bottom: 22px; z-index: 900;
  width: 50px; height: 50px; border-radius: 50%; border: none; cursor: pointer;
  background: var(--brand); color: #fff; box-shadow: 0 8px 24px rgba(0,159,227,.4);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity var(--t), transform var(--t), visibility var(--t), background var(--t-fast);
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--brand-dark); }
.to-top svg { width: 22px; height: 22px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- Mobile nav ---------- */
.nav-backdrop {
  position: fixed; inset: 0; background: rgba(2,62,107,.5); backdrop-filter: blur(2px);
  z-index: 998; opacity: 0; visibility: hidden; transition: opacity var(--t), visibility var(--t);
}
.nav-backdrop.is-open { opacity: 1; visibility: visible; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .usp { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  :root { --header-h: 66px; }
  .nav-toggle { display: inline-flex; }
  .header-cta { display: none; }
  .main-nav {
    position: fixed; top: 0; right: 0; height: 100dvh; width: min(82vw, 340px);
    background: var(--surface); z-index: 999; padding: calc(var(--header-h) + 16px) 24px 24px;
    box-shadow: var(--shadow-lg); transform: translateX(100%); transition: transform var(--t);
    overflow-y: auto;
  }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav ul { flex-direction: column; gap: 4px; }
  .main-nav a { padding: 12px 14px; font-size: 1.05rem; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { order: -1; max-width: 440px; margin-inline: auto; }
  .hero-media .ph { aspect-ratio: 16 / 11; }
  .about-grid { grid-template-columns: 1fr; }
  .about-media { max-width: 480px; margin-inline: auto; }
  .contact-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); row-gap: 28px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .services-grid { grid-template-columns: 1fr; }
  .usp { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-media .float-card { left: 8px; }
}
