/* ==========================================================================
   KS Akademie – Rebuild (HTML/CSS3/JS, framework-frei)
   Design-Tokens 1:1 aus akademie.ksautoglas.com uebernommen
   ========================================================================== */

@font-face {
  font-display: swap;
  font-family: 'Poppins';
  font-style: normal;
  font-weight: 400;
  src: url('../assets/fonts/poppins-regular.woff2') format('woff2');
}

:root {
  --ct-width: 1400px;

  --cl-logo: #e2017b;
  --cl-logo2: #828282;
  --cl-logo-trans: rgba(226, 1, 123, 0.8);
  --cl-gray: #444;

  --cl-border: #333;
  --cl-font: #454c53;
  --cl-body: #444;
  --cl-link: #e2017b;
  --cl-link-hover: #333;

  --fs-body: 1em;
  --fs-h1: 2.4em;
  --fs-h2: 1.8em;
  --fs-h3: 1.3em;
  --fs-h4: 1.1em;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
  font-size: var(--fs-body);
  color: var(--cl-body);
  font-family: 'Poppins', Arial, sans-serif;
  font-style: normal;
  font-weight: 400;
  background-color: #efefef;
  scroll-behavior: smooth;
}

body { padding-top: 138px; }

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

a { color: var(--cl-logo); text-decoration: none; }
a:hover { color: #333; text-decoration: none; }

h1, h2, h3, h4, h5 { color: var(--cl-gray); margin: 0 0 16px; font-weight: 600; }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); }

p { line-height: 1.7; margin: 0 0 1em; }

.center { text-align: center; }

.auto-container {
  width: var(--ct-width);
  max-width: 100%;
  margin: 0 auto;
  padding: 0 20px;
}

.clearfix::after { content: ""; display: block; clear: both; }

/* -- Buttons ----------------------------------------------------------- */

.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 3px;
  border: 0;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .03em;
  cursor: pointer;
  transition: background 300ms ease;
}

.btn-ks { background: var(--cl-logo); color: #fff; }
.btn-ks:hover { background: #ff2da0; color: #fff; }

.btn-ks2 { background: var(--cl-logo2); color: #fff; }
.btn-ks2:hover { background: #666; color: #fff; }

/* -- Header -------------------------------------------------------------- */

header.main-header {
  width: 100%;
  z-index: 999;
  background: #ffffff;
  transition: all 300ms ease;
}

.fixed-top-header {
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
}

.main-header .logo { position: relative; padding: 0; }
.main-header .logo img { max-width: 190px; padding-left: 10px; }

.header-top {
  background: #efefef;
  padding: 18px 0;
}
.header-top .auto-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.header-lower {
  position: relative;
  background-color: var(--cl-logo2);
}
.header-lower .auto-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  align-items: center;
}

.header-info { justify-self: end; }

.hotline {
  font-size: 17px;
  line-height: 20px;
  color: var(--cl-logo2);
  display: flex;
  align-items: center;
  gap: 16px;
}
.hotline .icon { width: 30px; height: 30px; flex: none; color: var(--cl-logo); }
.hotline p { margin: 0; font-size: 130%; line-height: 1.2; }
.hotline a { color: var(--cl-logo2); font-weight: 600; }
.hotline a:hover { color: var(--cl-logo); }

/* -- Social / Rueckruf links --------------------------------------------- */

.social-links {
  justify-self: end;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  padding-right: 10px;
  flex-wrap: wrap;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 10px;
  background: var(--cl-logo);
  color: #fff;
  font-size: 13px;
  border-radius: 3px;
  transition: background 500ms ease-out;
  white-space: nowrap;
}

.social-links a:hover { background: #fb4848; color: #fff; }
.social-links a.icon-link { padding: 0; width: 32px; min-width: 32px; }

/* -- Hauptmenue ------------------------------------------------------------ */

.main-menu { position: relative; z-index: 5; }
.main-menu ul { list-style: none; margin: 0; padding: 0; }

.main-menu .navbar-collapse { display: flex; padding-left: 10px; }
.main-menu .navigation { display: flex; }
.main-menu .navigation > li { position: relative; }

.main-menu .navigation > li > a {
  position: relative;
  display: block;
  font-size: 14px;
  line-height: 23px;
  padding: 16px 15px;
  color: #ffffff;
  text-transform: uppercase;
  transition: all 300ms ease;
}

.main-menu .navigation > li.drop > a { padding-right: 30px; }
.main-menu .navigation > li.drop > a .caret {
  display: inline-block;
  margin-left: 6px;
  border-top: 5px solid #fff;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  vertical-align: middle;
}

.main-menu .navigation > li:hover > a,
.main-menu .navigation > li.active > a {
  color: #fff;
  background: var(--cl-logo);
}

.main-menu .navigation > li > ul {
  position: absolute;
  display: block;
  width: 220px;
  top: 120%;
  left: 0;
  opacity: 0;
  visibility: hidden;
  margin: 0;
  padding: 0;
  background: var(--cl-logo);
  border-radius: 0 0 5px 5px;
  transition: all 300ms ease;
}

.main-menu .navigation > li:hover > ul {
  top: 100%;
  opacity: 1;
  visibility: visible;
}

.main-menu .navigation > li > ul > li {
  border-bottom: 1px solid rgba(255,255,255,.5);
}
.main-menu .navigation > li > ul > li:last-child { border: none; }

.main-menu .navigation > li > ul > li > a {
  display: block;
  line-height: 24px;
  font-size: 14px;
  color: #fff;
  padding: 9px 15px;
  transition: all 300ms ease;
}

.main-menu .navigation > li > ul > li:hover > a {
  background: rgba(255,255,255,.3);
  padding-left: 20px;
}

.navbar-toggle {
  display: none;
  background: none;
  border: 0;
  color: #fff;
  padding: 8px;
  cursor: pointer;
}

/* -- Sidenav (mobile) ------------------------------------------------------ */

.sidenav {
  height: 100%;
  width: 0;
  position: fixed;
  z-index: 1030;
  top: 0;
  left: 0;
  background-color: #ddd;
  overflow-x: hidden;
  transition: width .4s ease;
  padding-top: 60px;
  text-align: center;
}

.sidenav .sidemenu { list-style: none; text-align: left; padding: 3%; margin: 0; }

.sidenav li a {
  padding: 10px 10px 10px 24px;
  text-decoration: none;
  font-size: 22px;
  color: #333;
  display: block;
  background-color: #fff;
  border-left: 3px solid var(--cl-logo);
  margin-bottom: 5px;
  transition: .3s;
}
.sidenav li.active a { color: var(--cl-logo); }
.sidenav li a:hover { background: #f6f6f6; }

.sidenav .dropdown-menu {
  display: block;
  position: relative;
  padding: 0;
  margin: 5px 0 0 20px;
}

.sidenav .closebtn {
  position: absolute;
  top: 8px;
  right: 24px;
  font-size: 40px;
  color: #000;
  line-height: 1;
}

/* -- Hero ------------------------------------------------------------------ */

.hero {
  position: relative;
  background:
    linear-gradient(100deg, rgba(12,12,14,.88) 0%, rgba(20,20,23,.6) 48%, rgba(20,20,23,.25) 100%),
    url('../assets/img/autoglas.jpg') center center / cover no-repeat;
  color: #fff;
  padding: 90px 0;
  border-bottom: 4px solid var(--cl-logo);
}
.hero-content { max-width: 720px; }
.hero-content h1,
.hero-content .lead,
.hero-content p { text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.hero .eyebrow { color: var(--cl-logo); text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero p { color: rgba(255,255,255,.92); font-size: 1.05em; }
.hero-actions { display: flex; gap: 16px; margin-top: 28px; flex-wrap: wrap; }
.hero-actions.center { justify-content: center; }
.hero .btn-ks2 { background: rgba(255,255,255,.18); }
.hero .btn-ks2:hover { background: rgba(255,255,255,.3); }

.eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .8em;
  font-weight: 600;
  color: var(--cl-logo);
  margin-bottom: 12px;
}

/* -- Sections ---------------------------------------------------------- */

.section { padding: 70px 0; }
.section.alt { background: #fff; }
.section.cta {
  background: var(--cl-logo2);
  color: #fff;
}
.section.cta h2, .section.cta p { color: #fff; }
.section.cta p { opacity: .9; }

.section-head { max-width: 640px; margin: 0 auto 48px; }
.section-head.center { text-align: center; }

/* -- Card grid ----------------------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.card {
  background: #fff;
  border-radius: 6px;
  padding: 30px 24px;
  box-shadow: 0 2px 14px rgba(0,0,0,.06);
  transition: transform 250ms ease, box-shadow 250ms ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(0,0,0,.1);
}

.card-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--cl-logo-trans);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.card h3 { margin-bottom: 10px; font-size: 1.15em; }
.card p { font-size: .95em; color: #666; }
.card-link { font-weight: 600; font-size: .9em; }

/* -- Two column ----------------------------------------------------------- */

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.check-list { list-style: none; margin: 0 0 28px; padding: 0; }
.check-list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--cl-logo);
}
.check-list li::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 9px;
  width: 8px;
  height: 4px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}

.media-box {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--cl-logo2), var(--cl-logo));
  opacity: .9;
}

/* -- Footer ---------------------------------------------------------------- */

footer { background: #e2e2e2; padding: 24px 0; color: #333; }
footer a { color: #333; }
footer a:hover { color: var(--cl-logo); }

.rechtliches { display: flex; justify-content: center; gap: 20px; margin-bottom: 8px; }
.rechtliches p { margin: 0; }

.copyright { font-size: .85em; }

/* -- Go top button ----------------------------------------------------------- */

a.gotop {
  position: fixed;
  bottom: 30px;
  right: 0;
  width: 0;
  height: 40px;
  text-align: center;
  line-height: 40px;
  background: var(--cl-logo);
  color: #fff;
  cursor: pointer;
  z-index: 51;
  border-radius: 50% 0 0 50%;
  overflow: hidden;
  transition: width .3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
body.down a.gotop { width: 40px; }
a.gotop svg { flex: none; margin-left: 12px; }

/* -- Modal ------------------------------------------------------------------ */

.modal {
  position: fixed;
  inset: 0;
  z-index: 1050;
  display: none;
  overflow-y: auto;
  background: rgba(0,0,0,.6);
}
.modal.show { display: block; }

.modal-dialog {
  width: 100%;
  max-width: 560px;
  margin: 6vh auto;
  padding: 0 16px;
}

.modal-content {
  background: #f8f8f8;
  border-radius: 4px;
  box-shadow: 0 4px 20px rgba(0,0,0,.4);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #e5e5e5;
}
.modal-title { margin: 0; font-size: 18px; font-weight: 600; color: #666; }
.modal-header .close {
  background: none;
  border: 0;
  font-size: 28px;
  line-height: 1;
  color: #999;
  cursor: pointer;
}
.modal-header .close:hover { color: #333; }

.modal-body { padding: 20px; max-height: 60vh; overflow-y: auto; }
.rueckruf-intro { margin-bottom: 20px; font-size: .95em; }

.row { display: flex; flex-wrap: wrap; gap: 0 16px; }
.form-group { margin-bottom: 16px; flex: 1 1 45%; }
.form-group.col-6 { flex: 1 1 45%; }
.form-group label { display: block; margin-bottom: 6px; font-size: .9em; font-weight: 600; }
.form-control {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: .95em;
}
.form-control:focus { outline: none; border-color: var(--cl-logo); }

.modal-footer {
  padding: 15px 20px;
  border-top: 1px solid #e5e5e5;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* -- Page hero (Unterseiten) ------------------------------------------------ */

.page-hero {
  background: linear-gradient(120deg, var(--cl-logo) 0%, #a8016c 100%);
  color: #fff;
  padding: 70px 0 60px;
}
.page-hero h1 { color: #fff; margin-bottom: 10px; }
.page-hero .eyebrow { color: rgba(255,255,255,.85); }
.page-hero .lead { color: rgba(255,255,255,.92); font-size: 1.05em; max-width: 640px; margin: 0; }

/* -- Info box (Steinschlag-Schulung Detailseite) ----------------------------- */

.info-box {
  background: #fff;
  border-radius: 8px;
  padding: 30px;
  box-shadow: 0 2px 14px rgba(0,0,0,.06);
}
.info-box h4 { font-size: 1.05em; margin-bottom: 10px; }
.info-box h4:not(:first-child) { margin-top: 22px; }

.plain-list { list-style: none; margin: 0 0 4px; padding: 0; }
.plain-list li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
  font-size: .95em;
  color: #555;
}
.plain-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--cl-logo);
  font-weight: 700;
}

.price-tag {
  margin-top: 24px;
  padding: 18px;
  border-radius: 6px;
  background: #f6f6f6;
  border-left: 4px solid var(--cl-logo);
  text-align: center;
}
.price-tag span { display: block; font-size: .85em; color: #777; margin-bottom: 4px; }
.price-tag strong { display: block; font-size: 1.5em; color: var(--cl-gray); }
.price-tag small { display: block; font-size: .8em; color: #999; }

/* -- Termine -------------------------------------------------------------- */

.termin-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.termin-card {
  display: flex;
  gap: 22px;
  background: #fff;
  border-radius: 8px;
  padding: 26px;
  box-shadow: 0 2px 14px rgba(0,0,0,.06);
}

.termin-date {
  flex: none;
  width: 84px;
  height: 84px;
  border-radius: 8px;
  background: var(--cl-logo);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.termin-date .day { font-size: 1.8em; font-weight: 700; line-height: 1; }
.termin-date .month { font-size: .8em; text-transform: uppercase; letter-spacing: .04em; margin-top: 4px; }

.termin-info h3 { margin-bottom: 10px; font-size: 1.1em; }
.termin-info p { margin: 0 0 8px; font-size: .92em; color: #555; display: flex; align-items: center; gap: 8px; }
.termin-info svg { flex: none; color: var(--cl-logo); }

.termin-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.route-link { font-weight: 600; font-size: .9em; }
.btn-sm { padding: 9px 18px; font-size: .8em; }

/* -- Anmeldeformular (Formular-Seiten) ---------------------------------------- */

.form-wrap {
  max-width: 640px;
  margin: 0 auto;
  background: #fff;
  border-radius: 8px;
  padding: 40px;
  box-shadow: 0 2px 14px rgba(0,0,0,.06);
}
.form-wrap .form-group { margin-bottom: 20px; }
.form-wrap label { display: block; margin-bottom: 4px; font-weight: 600; font-size: .95em; }
.form-wrap small { display: block; margin-bottom: 6px; color: #888; font-size: .82em; }
.form-wrap textarea.form-control { resize: vertical; }
.form-wrap input[readonly] { background: #f4f4f4; color: #888; }

.captcha-box { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.captcha-question {
  display: inline-block;
  padding: 10px 18px;
  background: #eee;
  border-radius: 3px;
  font-weight: 700;
  letter-spacing: .05em;
  color: var(--cl-gray);
}
.captcha-input { max-width: 120px; }

.form-note { margin-top: 20px; font-size: .88em; color: #777; text-align: center; }

/* -- Responsive -------------------------------------------------------------- */

@media (max-width: 1400px) { header, .auto-container { width: 100%; } }

@media (max-width: 1024px) {
  body { padding-top: 0; }
  .fixed-top-header { position: relative; }
  .header-top .auto-container { grid-template-columns: 1fr; text-align: center; }
  .header-info { justify-self: center; margin-top: 12px; }
  .hotline { justify-content: center; }
  .header-lower .auto-container { grid-template-columns: 1fr; padding: 8px 0; }
  .social-links { justify-self: center; justify-content: center; }
  .main-menu .navbar-collapse { display: none; }
  .navbar-toggle { display: inline-flex; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; }
  .col-media { order: -1; }
  .termin-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .card-grid { grid-template-columns: 1fr; }
  .hero { padding: 60px 0; }
  h1 { font-size: 1.8em; }
  .row { flex-direction: column; }
  .form-group.col-6 { flex: 1 1 100%; }
  .termin-card { flex-direction: column; }
  .form-wrap { padding: 26px 20px; }
}
