/* ==================================================================
   chrismarks.de – eigene Styles (Menü, Aufklappen, Videos, Formular)
   und Korrekturen. Das Grund-Layout (Tailwind) liegt in style.css.
   Änderungen bitte hier vornehmen.
   ================================================================== */

/* ---------- Grundlagen ---------- */
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { overflow-x: hidden; text-rendering: optimizeLegibility; }
@supports (overflow: clip) { body { overflow-x: clip; } }
section[id] { scroll-margin-top: 76px; }
a.nav-link { text-decoration: none; }

/* Lange deutsche Wörter (z. B. „Geschäftsbedingungen") dürfen auf dem Handy
   nicht über den Rand laufen. Trennstellen sind im HTML mit &shy; gesetzt. */
h1, h2, h3, h4 { overflow-wrap: break-word; -webkit-hyphens: manual; hyphens: manual; }

/* Sichtbarer Tastatur-Fokus (Barrierefreiheit) */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid #111827; outline-offset: 2px; border-radius: 4px;
}
nav a:focus-visible, nav button:focus-visible, #mobile-menu a:focus-visible { outline-color: #fff; }

/* ---------- Mobiles Menü ---------- */
.js-burger { display: flex; }
@media (min-width: 768px) { .js-burger, #mobile-menu { display: none !important; } }
#mobile-menu {
  display: none; position: fixed; top: 68px; left: 0; right: 0; z-index: 49;
  background: #000; padding: 8px 24px 24px; border-top: 1px solid rgba(255,255,255,.1);
  max-height: calc(100vh - 68px); max-height: calc(100dvh - 68px); overflow-y: auto;
  overscroll-behavior: contain;
}
#mobile-menu.is-open { display: block; animation: fadeIn .2s ease; }
#mobile-menu a { display: block; padding: 14px 0; color: rgba(255,255,255,.85); font-size: 16px; border-bottom: 1px solid rgba(255,255,255,.08); text-decoration: none; }
#mobile-menu a:hover { color: #fff; }
#mobile-menu a.mm-cta { margin-top: 16px; border: 0; background: #fff; color: #000; text-align: center; border-radius: 8px; font-weight: 600; }
body.menu-open { overflow: hidden; }

/* ---------- Aufklapp-Bereiche ---------- */
.js-collapsible:not(.is-open) { display: none !important; }
.js-collapsible.is-open { animation: fadeIn .3s ease; }
.js-more:not(.is-open) > .is-extra { display: none !important; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
[data-toggle] svg { transition: transform .2s ease; }
[data-toggle].is-open svg { transform: rotate(180deg); }

/* ---------- Logos „Vertrauen" ---------- */
.logo-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 40px; }
@media (min-width: 768px) { .logo-grid { grid-template-columns: repeat(4, 1fr); gap: 32px; } }

/* ---------- Partner-Logos (Markenbotschafter / Sponsoren) ---------- */
.partner-row { flex-wrap: wrap; justify-content: center; gap: 24px; margin-top: 24px; }
.partner-row a { display: flex; align-items: center; justify-content: center; padding: 24px; background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 12px; min-width: 200px; transition: border-color .2s ease; }
.partner-row a:hover { border-color: #9ca3af; }
.partner-row img { max-height: 80px; max-width: 220px; object-fit: contain; }
@media (max-width: 479px) {
  .partner-row a { min-width: 0; width: 100%; }
}

/* ---------- Karussells ---------- */
[data-carousel-track] { will-change: transform; touch-action: pan-y; }
[data-carousel-dot] { flex-shrink: 0; }
/* Galerie mit vielen Bildern: Punkte auf dem Handy kompakter (eine Zeile) */
@media (max-width: 639px) {
  #impressions [data-carousel-dot] { width: 6px; height: 6px; }
  #impressions [data-carousel-dot] + [data-carousel-dot] { margin-left: -3px; }
}

/* ---------- Kundenstimmen ---------- */
[data-quote-full].is-full { white-space: normal; }

/* ---------- Videos – Zwei-Klick-Lösung ---------- */
.video-consent {
  position: relative; width: 100%; height: 100%; min-height: 300px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 14px; padding: 24px; text-align: center;
  background: radial-gradient(circle at 50% 40%, #2a2a2a 0%, #0b0b0b 70%); color: #fff;
}
.video-consent button {
  display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 999px;
  background: #fff; color: #000; font-weight: 600; font-size: 15px; border: 0; cursor: pointer;
  transition: background-color .2s ease;
}
.video-consent button:hover { background: #e5e5e5; }
.video-consent .play { width: 64px; height: 64px; border-radius: 50%; background: rgba(255,255,255,.12); display: flex; align-items: center; justify-content: center; }
.video-consent .vc-title { font-weight: 600; font-size: 16px; }
.video-consent .vc-note { font-size: 11px; line-height: 1.5; color: rgba(255,255,255,.65); max-width: 320px; }
.video-consent .vc-note a { color: #fff; text-decoration: underline; }
.video-frame { width: 100%; height: 100%; border: 0; display: block; }
.video-more { display: grid; grid-template-columns: repeat(1, minmax(0, 320px)); justify-content: center; gap: 16px; }
.video-card { background: #111; border-radius: 12px; overflow: hidden; border: 1px solid rgba(0,0,0,.1); }
.video-card .vbox { aspect-ratio: 9 / 16; }
.video-card > p { padding: 8px 12px; font-size: 12px; color: #111; background: #fff; margin: 0; }

/* ---------- Kontaktformular ---------- */
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: 14px; line-height: 1.5; border-radius: 8px; }
.form-status:empty { display: none; }
.form-status.is-ok { padding: 12px 14px; background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.form-status.is-error { padding: 12px 14px; background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.form-privacy { font-size: 12px; line-height: 1.5; color: #6b7280; }
.form-privacy a { text-decoration: underline; }
button[type="submit"][disabled] { opacity: .6; cursor: wait; }
.js-contact input, .js-contact textarea { background-color: #fff; }
.js-contact textarea { resize: vertical; }
/* iOS zoomt bei Schrift < 16px beim Antippen ins Formular – verhindern */
@media (max-width: 767px) {
  .js-contact input, .js-contact textarea { font-size: 16px; }
}
#contact a[href^="mailto:"], #contact a[href^="tel:"] { color: inherit; text-decoration: none; }
#contact a[href^="mailto:"]:hover, #contact a[href^="tel:"]:hover { text-decoration: underline; }

/* ---------- Ergänzte Buttons ---------- */
.btn-outline { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border: 1px solid #d1d5db; color: #374151; font-size: 14px; font-weight: 600; border-radius: 8px; background: transparent; cursor: pointer; transition: background-color .2s ease; }
.btn-outline:hover { background: #e5e7eb; }
.btn-primary-more { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; border: 0; }

/* ---------- Weniger Bewegung, wenn im System eingestellt ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- Druck ---------- */
@media print {
  nav, #mobile-menu, .js-burger, [data-carousel-prev], [data-carousel-next], #contact form { display: none !important; }
  section { padding-top: 1rem !important; padding-bottom: 1rem !important; }
}
