/* ============================================
   k-websites.de — Apple-Style Stylesheet
   ============================================ */

:root {
  --bg: #ffffff;
  --bg-soft: #f5f5f7;
  --bg-card: #ffffff;
  --text: #1d1d1f;
  --text-soft: #6e6e73;
  --text-softer: #86868b;
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --border: #d2d2d7;
  --radius: 18px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  --shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.12);
  --nav-height: 52px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 24px);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "Helvetica Neue", Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection {
  background: rgba(0, 113, 227, 0.2);
}

img {
  max-width: 100%;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---------- Navigation ---------- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  transition: background 0.3s ease;
}

.nav-inner {
  max-width: 1024px;
  margin: 0 auto;
  height: 100%;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}

.nav-logo:hover {
  text-decoration: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  color: var(--text-soft);
  text-decoration: none;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-cta {
  background: var(--accent);
  color: #fff !important;
  padding: 7px 16px;
  border-radius: 980px;
  font-weight: 500;
  transition: background 0.2s ease, transform 0.2s ease;
}

.nav-cta:hover {
  background: var(--accent-hover);
  transform: scale(1.03);
}

/* Mobile nav */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

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

.hero {
  min-height: 100vh; /* Fallback für ältere Browser ohne svh-Unterstützung */
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-height) + 60px) 22px 60px;
  position: relative;
  background: linear-gradient(180deg, #fbfbfd 0%, #f5f5f7 100%);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-soft);
  background: rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.06);
  padding: 6px 16px;
  border-radius: 980px;
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.1s forwards;
}

.hero-badge .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #30d158;
  animation: pulse 2s ease-in-out infinite;
}

.hero h1 {
  font-size: clamp(42px, 7vw, 80px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  max-width: 900px;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.25s forwards;
}

.hero h1 .gradient-text {
  background: linear-gradient(90deg, #0071e3, #7d55ff, #0071e3);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 6s linear infinite;
}

.hero p {
  font-size: clamp(18px, 2.5vw, 24px);
  color: var(--text-soft);
  max-width: 640px;
  margin-top: 24px;
  font-weight: 400;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.4s forwards;
}

.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 40px;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.55s forwards;
}

.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-softer);
  font-size: 24px;
  opacity: 0;
  animation: fadeUp 0.8s ease 1s forwards, bounce 2.4s ease-in-out 1.8s infinite;
  text-decoration: none;
}

.hero-scroll:hover {
  text-decoration: none;
  color: var(--text-soft);
}

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

.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 980px;
  font-size: 17px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.2s ease,
    box-shadow 0.25s ease;
}

.btn:hover {
  text-decoration: none;
  transform: scale(1.04);
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 8px 24px rgba(0, 113, 227, 0.35);
}

.btn-secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn-secondary:hover {
  background: rgba(0, 113, 227, 0.06);
}

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

.section {
  padding: 110px 22px;
}

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

.container {
  max-width: 1024px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 70px;
}

.section-header .eyebrow {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}

.section-header h2 {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
}

.section-header p {
  font-size: 19px;
  color: var(--text-soft);
  margin-top: 18px;
}

/* ---------- Cards Grid ---------- */

.grid {
  display: grid;
  gap: 20px;
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 36px 30px;
  box-shadow: var(--shadow);
  transition: transform 0.35s cubic-bezier(0.34, 1.4, 0.64, 1), box-shadow 0.35s ease;
}

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

.section-soft .card {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.card-icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: 22px;
  background: linear-gradient(135deg, #f5f5f7, #e8e8ed);
}

.card h3 {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.card p {
  font-size: 15.5px;
  color: var(--text-soft);
  line-height: 1.65;
}

/* ---------- Stats strip ---------- */

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  text-align: center;
}

.stat h3 {
  font-size: clamp(40px, 6vw, 64px);
  font-weight: 700;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text) 30%, var(--text-softer));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat p {
  font-size: 16px;
  color: var(--text-soft);
  margin-top: 6px;
}

/* ---------- Process / Ablauf ---------- */

.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  counter-reset: step;
}

.process-step {
  position: relative;
  padding: 30px 24px;
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform 0.35s cubic-bezier(0.34, 1.4, 0.64, 1), box-shadow 0.35s ease;
}

.process-step:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.process-step .step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 17px;
  margin-bottom: 18px;
}

.process-step h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.process-step p {
  font-size: 14.5px;
  color: var(--text-soft);
  line-height: 1.6;
}

/* ---------- Big CTA ---------- */

.cta-banner {
  text-align: center;
  background: #1d1d1f;
  color: #f5f5f7;
  border-radius: 28px;
  padding: 90px 40px;
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -20%;
  width: 70%;
  height: 200%;
  background: radial-gradient(ellipse, rgba(0, 113, 227, 0.25), transparent 70%);
  pointer-events: none;
}

.cta-banner::after {
  content: "";
  position: absolute;
  bottom: -60%;
  right: -20%;
  width: 70%;
  height: 200%;
  background: radial-gradient(ellipse, rgba(125, 85, 255, 0.18), transparent 70%);
  pointer-events: none;
}

.cta-banner h2 {
  font-size: clamp(30px, 5vw, 48px);
  font-weight: 700;
  letter-spacing: -0.025em;
  position: relative;
  z-index: 1;
}

.cta-banner p {
  font-size: 19px;
  color: #a1a1a6;
  margin-top: 16px;
  position: relative;
  z-index: 1;
}

.cta-banner .btn {
  margin-top: 36px;
  position: relative;
  z-index: 1;
}

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

.footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  padding: 40px 22px;
  font-size: 13px;
  color: var(--text-softer);
}

.footer-inner {
  max-width: 1024px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  color: var(--text-soft);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

/* ---------- Contact page ---------- */

.page-hero {
  padding: calc(var(--nav-height) + 90px) 22px 60px;
  text-align: center;
  background: linear-gradient(180deg, #fbfbfd 0%, #ffffff 100%);
}

.page-hero h1 {
  font-size: clamp(36px, 6vw, 60px);
  font-weight: 700;
  letter-spacing: -0.03em;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.1s forwards;
}

.page-hero p {
  font-size: 19px;
  color: var(--text-soft);
  max-width: 560px;
  margin: 18px auto 0;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.25s forwards;
}

.contact-wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 20px 22px 110px;
}

.contact-form {
  background: var(--bg-card);
  border-radius: 24px;
  padding: 44px 40px;
  box-shadow: var(--shadow);
  opacity: 0;
  animation: fadeUp 0.8s ease 0.4s forwards;
}

.form-group {
  margin-bottom: 22px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 16px;
  font-size: 16px;
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-soft);
  color: var(--text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
}

.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236e6e73' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.12);
}

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

.form-consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--text-soft);
  margin-bottom: 26px;
}

.form-consent input {
  margin-top: 3px;
  accent-color: var(--accent);
}

.contact-form .btn {
  width: 100%;
  font-size: 17px;
}

.form-success {
  display: none;
  text-align: center;
  padding: 20px 0 0;
  color: #248a3d;
  font-weight: 500;
}

.form-success.visible {
  display: block;
  animation: fadeUp 0.5s ease forwards;
}

.contact-alt {
  text-align: center;
  margin-top: 36px;
  font-size: 15px;
  color: var(--text-soft);
  opacity: 0;
  animation: fadeUp 0.8s ease 0.55s forwards;
}

/* ---------- Legal pages ---------- */

.legal {
  max-width: 720px;
  margin: 0 auto;
  padding: calc(var(--nav-height) + 80px) 22px 110px;
}

.legal h1 {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 40px;
}

.legal h2 {
  font-size: 22px;
  font-weight: 600;
  margin: 40px 0 12px;
  letter-spacing: -0.01em;
}

.legal h3 {
  font-size: 17px;
  font-weight: 600;
  margin: 26px 0 8px;
}

.legal p,
.legal li {
  font-size: 16px;
  color: var(--text-soft);
  line-height: 1.7;
}

.legal ul {
  padding-left: 22px;
  margin: 10px 0;
}

.legal .notice {
  background: #fff8e6;
  border: 1px solid #f2d98c;
  border-radius: 12px;
  padding: 16px 20px;
  font-size: 14px;
  color: #8a6d1a;
  margin-bottom: 36px;
}

/* ---------- Scroll reveal ---------- */

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ---------- Keyframes ---------- */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gradientShift {
  to {
    background-position: 200% center;
  }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.85); }
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
  .hero-badge, .hero h1, .hero p, .hero-actions, .hero-scroll,
  .page-hero h1, .page-hero p, .contact-form, .contact-alt, .reveal {
    opacity: 1;
    transform: none;
  }
}

/* Auf sehr flachen Bildschirmen (z. B. Handy quer) würde der
   Scroll-Pfeil die Buttons überlappen — dann ausblenden. */
@media (max-height: 700px) {
  .hero-scroll {
    display: none;
  }
}

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

@media (max-width: 860px) {
  .grid-3,
  .process {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 700px) {
  .section {
    padding: 80px 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(255, 255, 255, 0.95);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    padding: 12px 22px 20px;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease;
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 14px 0;
    font-size: 17px;
  }

  .nav-cta {
    display: inline-block;
    margin-top: 10px;
    text-align: center;
  }

  .grid-3,
  .grid-2,
  .process,
  .stats {
    grid-template-columns: 1fr;
  }

  .contact-form {
    padding: 32px 24px;
  }

  .cta-banner {
    padding: 60px 24px;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
    justify-content: center;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}
