/* INSURIO marketing site – design tokens + layout */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,650;9..144,700&family=Manrope:wght@400;500;600;700&display=swap');

:root {
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Manrope', system-ui, sans-serif;

  --bg: #f3f6f4;
  --bg-elevated: #ffffff;
  --ink: #14201c;
  --ink-muted: #3d4f48;
  --line: rgba(20, 32, 28, 0.12);
  --brand: #0f5c4c;
  --brand-deep: #0a3d34;
  --accent: #c45c26;
  --accent-soft: #f3e0d4;
  --chat-bg: #ffffff;
  --chat-bot: #e8f0ed;
  --chat-user: #0f5c4c;
  --chat-user-ink: #ffffff;
  --hero-glow: radial-gradient(120% 80% at 80% 10%, rgba(196, 92, 38, 0.18), transparent 55%),
    radial-gradient(90% 70% at 10% 90%, rgba(15, 92, 76, 0.16), transparent 50%),
    linear-gradient(165deg, #eef5f1 0%, #f7f3ee 48%, #e7eee9 100%);
  --shadow: 0 18px 50px rgba(20, 32, 28, 0.08);
  --radius: 18px;
  --header-h: 72px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #0c1210;
    --bg-elevated: #151c19;
    --ink: #e8efeb;
    --ink-muted: #a7b5ae;
    --line: rgba(232, 239, 235, 0.12);
    --brand: #3dba9f;
    --brand-deep: #2a8f7a;
    --accent: #e08a55;
    --accent-soft: #3a2a22;
    --chat-bg: #121916;
    --chat-bot: #1c2622;
    --chat-user: #2a8f7a;
    --chat-user-ink: #f4fffb;
    --hero-glow: radial-gradient(100% 80% at 85% 0%, rgba(224, 138, 85, 0.16), transparent 50%),
      radial-gradient(80% 60% at 0% 100%, rgba(61, 186, 159, 0.14), transparent 45%),
      linear-gradient(165deg, #0c1210 0%, #121a17 55%, #0e1613 100%);
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
    color-scheme: dark;
  }
}

:root[data-theme='dark'] {
  --bg: #0c1210;
  --bg-elevated: #151c19;
  --ink: #e8efeb;
  --ink-muted: #a7b5ae;
  --line: rgba(232, 239, 235, 0.12);
  --brand: #3dba9f;
  --brand-deep: #2a8f7a;
  --accent: #e08a55;
  --accent-soft: #3a2a22;
  --chat-bg: #121916;
  --chat-bot: #1c2622;
  --chat-user: #2a8f7a;
  --chat-user-ink: #f4fffb;
  --hero-glow: radial-gradient(100% 80% at 85% 0%, rgba(224, 138, 85, 0.16), transparent 50%),
    radial-gradient(80% 60% at 0% 100%, rgba(61, 186, 159, 0.14), transparent 45%),
    linear-gradient(165deg, #0c1210 0%, #121a17 55%, #0e1613 100%);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
  min-height: 100vh;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--brand);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--accent);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--brand);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 1000;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--line);
  height: var(--header-h);
}

.site-header__inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: inherit;
  text-decoration: none;
}

.brand__logo {
  width: 2.35rem;
  height: 2.35rem;
  object-fit: contain;
  flex-shrink: 0;
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
}

.brand__tag {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-muted);
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.35rem 1rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

@media (max-width: 720px) {
  :root {
    --header-h: 60px;
  }

  .site-header__inner {
    gap: 0.45rem;
    padding: 0 0.9rem;
  }

  .brand {
    gap: 0.35rem;
    min-width: 0;
    flex: 1 1 auto;
  }

  .brand__logo {
    width: 1.7rem;
    height: 1.7rem;
  }

  .brand__name {
    font-size: 1.12rem;
    line-height: 1;
  }

  .brand__tag {
    display: none;
  }

  .nav {
    flex-wrap: nowrap;
    flex: 0 0 auto;
    gap: 0.35rem;
  }

  .nav a:not(.nav__cta) {
    display: none;
  }

  .theme-toggle {
    padding: 0.38rem 0.55rem;
    font-size: 0.72rem;
    line-height: 1;
    white-space: nowrap;
  }

  .nav__cta {
    padding: 0.42rem 0.7rem;
    font-size: 0.78rem;
    white-space: nowrap;
  }
}

.nav a {
  color: var(--ink-muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
}

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

.nav__cta {
  background: var(--brand);
  color: #fff !important;
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
}

.theme-toggle {
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.45rem 0.75rem;
  cursor: pointer;
  font: inherit;
  font-size: 0.8rem;
}

.hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  background: var(--hero-glow);
  overflow: hidden;
  display: flex;
  align-items: stretch;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cpath fill='%2014201c' fill-opacity='0.03' d='M0 0h80v80H0zm80 80h80v80H80z'/%3E%3C/svg%3E");
  pointer-events: none;
}

.hero__inner {
  position: relative;
  max-width: 1120px;
  margin: 0 auto;
  padding: 3.5rem 1.25rem 3rem;
  width: 100%;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem;
  align-items: center;
}

@media (max-width: 900px) {
  .hero__inner {
    grid-template-columns: 1fr;
    padding-top: 2.25rem;
  }
  .hero {
    min-height: auto;
  }
}

.hero__brand {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 4.6rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
  color: var(--ink);
  animation: rise 0.7s ease both;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.hero__logo {
  width: clamp(3.2rem, 8vw, 4.5rem);
  height: clamp(3.2rem, 8vw, 4.5rem);
  object-fit: contain;
  flex-shrink: 0;
}

.hero__title {
  animation: rise 0.7s ease 0.08s both;
}

.hero__lead,
.trust-row {
  animation: rise 0.7s ease 0.16s both;
}

.hero .insurio-chat {
  animation: rise 0.75s ease 0.12s both;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero__brand,
  .hero__title,
  .hero__lead,
  .trust-row,
  .hero .insurio-chat,
  .insurio-msg {
    animation: none;
  }
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 550;
  line-height: 1.25;
  margin: 0 0 0.85rem;
  max-width: 18ch;
  color: var(--ink-muted);
}

.hero__lead {
  margin: 0 0 1.5rem;
  max-width: 36ch;
  color: var(--ink-muted);
  font-size: 1.05rem;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--ink-muted);
  font-size: 0.88rem;
}

.trust-row li {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.trust-row li::before {
  content: '';
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--brand);
}

.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 4rem 1.25rem;
}

.section__eyebrow {
  color: var(--accent);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  margin: 0 0 0.6rem;
}

.section__title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  max-width: 18ch;
}

.section__text {
  color: var(--ink-muted);
  max-width: 54ch;
  margin: 0 0 1.75rem;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  counter-reset: step;
}

@media (max-width: 800px) {
  .steps {
    grid-template-columns: 1fr;
  }
}

.step {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}

.step h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 0 0 0.4rem;
}

.step h3::before {
  counter-increment: step;
  content: counter(step) '. ';
  color: var(--brand);
}

.step p {
  margin: 0;
  color: var(--ink-muted);
}

.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.85rem;
}

.topic-link {
  display: block;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--line);
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.topic-link:hover {
  color: var(--brand);
  border-color: var(--brand);
}

.topic-link strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 0.25rem;
}

.topic-link span {
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.prose {
  max-width: 68ch;
}

.prose h2 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  margin: 2.2rem 0 0.7rem;
}

.prose h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin: 1.6rem 0 0.5rem;
}

.prose p,
.prose li {
  color: var(--ink-muted);
}

.prose ul {
  padding-left: 1.15rem;
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 0.95rem 0;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq details p {
  color: var(--ink-muted);
  margin: 0.6rem 0 0.2rem;
}

.page-hero {
  background: var(--hero-glow);
  padding: 3rem 1.25rem 2rem;
}

.page-hero__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

@media (max-width: 900px) {
  .page-hero__inner {
    grid-template-columns: 1fr;
  }
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3rem);
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  line-height: 1.05;
}

.page-hero .lead {
  color: var(--ink-muted);
  font-size: 1.05rem;
  margin: 0 0 1rem;
  max-width: 40ch;
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 3rem;
  padding: 2.5rem 1.25rem 3rem;
  background: color-mix(in srgb, var(--bg-elevated) 70%, var(--bg));
}

.site-footer__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 800px) {
  .site-footer__inner {
    grid-template-columns: 1fr;
  }
}

.site-footer h2 {
  font-family: var(--font-display);
  font-size: 1rem;
  margin: 0 0 0.7rem;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer li {
  margin: 0.35rem 0;
}

.site-footer a {
  color: var(--ink-muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--brand);
}

.site-footer__brand {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin: 0 0 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-footer__logo {
  width: 2rem;
  height: 2rem;
  object-fit: contain;
}

.site-footer p {
  color: var(--ink-muted);
  margin: 0;
  font-size: 0.92rem;
}

/* Chat widget */
.insurio-chat {
  background: var(--chat-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  min-height: 420px;
  max-height: min(70vh, 640px);
  overflow: hidden;
}

.insurio-chat__head {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.insurio-chat__head strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
}

.insurio-chat__status {
  font-size: 0.75rem;
  color: var(--ink-muted);
}

.insurio-chat__messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.insurio-msg {
  max-width: 92%;
  padding: 0.7rem 0.85rem;
  border-radius: 14px;
  font-size: 0.95rem;
  line-height: 1.45;
  white-space: pre-wrap;
  animation: msg-in 0.28s ease;
}

@keyframes msg-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.insurio-msg--bot {
  align-self: flex-start;
  background: var(--chat-bot);
  color: var(--ink);
}

.insurio-msg--user {
  align-self: flex-end;
  background: var(--chat-user);
  color: var(--chat-user-ink);
}

.insurio-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0 1rem 0.65rem;
}

.insurio-chip {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  font: inherit;
  font-size: 0.82rem;
  cursor: pointer;
}

.insurio-chip:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.insurio-chat__form {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  border-top: 1px solid var(--line);
}

.insurio-chat__form input {
  flex: 1;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  border-radius: 12px;
  padding: 0.7rem 0.85rem;
  font: inherit;
}

.insurio-chat__form button {
  border: 0;
  background: var(--brand);
  color: #fff;
  border-radius: 12px;
  padding: 0.7rem 1rem;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.insurio-chat__form button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.insurio-chat--compact {
  min-height: 360px;
}

.insurio-chat-actions {
  align-self: flex-start;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  max-width: 100%;
  animation: msg-in 0.28s ease;
}

.insurio-chat-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: var(--brand);
  color: #fff !important;
  text-decoration: none !important;
  border-radius: 12px;
  padding: 0.55rem 0.9rem;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
}

.insurio-chat-btn--ghost {
  background: transparent;
  color: var(--brand) !important;
  border: 1px solid var(--brand);
}

.insurio-chat-btn:disabled {
  opacity: 0.55;
  cursor: wait;
}

.insurio-feedback {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  width: min(100%, 22rem);
}

.insurio-feedback__form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.75rem;
  background: var(--chat-bot);
  border-radius: 14px;
  border: 1px solid var(--line);
}

.insurio-feedback__label {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink);
}

.insurio-feedback__stars {
  display: flex;
  gap: 0.15rem;
}

.insurio-star {
  border: 0;
  background: transparent;
  color: #c5c0b8;
  font-size: 1.45rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.1rem;
}

.insurio-star.is-active,
.insurio-star:hover {
  color: #c9a227;
}

.insurio-feedback__form textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font: inherit;
  font-size: 0.88rem;
  resize: vertical;
  min-height: 4.5rem;
}

.insurio-feedback__status,
.insurio-feedback__done {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

.insurio-feedback__done {
  color: var(--ink);
}

.cta-band {
  margin: 2rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--line);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--brand);
  color: #fff !important;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
  font-weight: 600;
  border: 0;
  cursor: pointer;
}

.btn--ghost {
  background: transparent;
  color: var(--ink) !important;
  border: 1px solid var(--line);
}

.article-layout {
  max-width: 1120px;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 3rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 2.5rem;
  align-items: start;
}

@media (max-width: 900px) {
  .article-layout {
    grid-template-columns: 1fr;
  }
}

.sticky-chat {
  position: sticky;
  top: calc(var(--header-h) + 1rem);
}

.legal {
  max-width: 72ch;
  margin: 0 auto;
  padding: 3rem 1.25rem 4rem;
}

.legal:has(.about-story) {
  max-width: 56rem;
}

.legal h1 {
  font-family: var(--font-display);
  font-size: 2.2rem;
}

.legal h2 {
  margin-top: 2rem;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.legal ul {
  padding-left: 1.2rem;
}

.legal li {
  margin: 0.35rem 0;
}

.muted {
  color: var(--ink-muted);
}

.about-story {
  max-width: 46rem;
}

.about-story > p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--ink-muted);
}

.about-story > p.about-story__lead {
  font-size: 1.2rem;
  color: var(--ink);
  line-height: 1.55;
}

.about-team {
  display: grid;
  gap: 1.25rem;
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
}

.about-team--solo {
  max-width: 16rem;
}

@media (min-width: 640px) {
  .about-team:not(.about-team--solo) {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

.about-team__person {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.about-team__person img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 14px;
  background: var(--bg-elevated);
}

.about-team__person strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
}

.about-team__person span {
  font-size: 0.88rem;
  color: var(--ink-muted);
  line-height: 1.35;
}

.about-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.1rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.about-trust a {
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
}

.about-trust a:hover {
  text-decoration: underline;
}

.legal:has(.page-story) {
  max-width: 44rem;
}

.page-story__lead {
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--ink);
  margin: 0 0 1.25rem;
}

.page-story > p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--ink-muted);
}

.page-story__block {
  margin-top: 2.25rem;
}

.page-story__block h2 {
  margin-top: 0;
}

.page-story__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 1rem 0 0;
}

.download-hero {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
  margin: 0 0 1.5rem;
}

.download-hero__logo {
  width: 5.5rem;
  height: 5.5rem;
  object-fit: contain;
}

.voice {
  margin: 1.25rem 0 0;
  padding: 1.15rem 0 0;
  border-top: 1px solid var(--line);
}

.voice p {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.45;
  color: var(--ink);
}

.voice footer {
  margin-top: 0.65rem;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

/* ——— KV-Rechner (BAG / priminfo-ähnlich) ——— */
.page-hero--tool .page-hero__inner {
  align-items: end;
}

.page-hero__jump {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 1.25rem 0 0;
}

.page-hero__aside-note {
  background: color-mix(in srgb, var(--bg-elevated) 88%, transparent);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
  box-shadow: var(--shadow);
  max-width: 28rem;
}

.page-hero__aside-note p {
  margin: 0;
  color: var(--ink-muted);
  line-height: 1.55;
}

.page-hero__aside-note strong {
  color: var(--ink);
}

.section__inner-chat {
  max-width: 720px;
  margin: 0 auto;
}

.kv-calc-section {
  padding-top: 0.5rem;
}

.kv-calc {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem 1rem;
}

.kv-calc__shell {
  background:
    radial-gradient(90% 70% at 100% 0%, rgba(196, 92, 38, 0.1), transparent 55%),
    radial-gradient(70% 60% at 0% 100%, rgba(15, 92, 76, 0.1), transparent 50%),
    var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  padding: clamp(1.25rem, 3vw, 2rem);
  overflow: hidden;
}

.kv-calc__eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
}

.kv-calc__title {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3vw, 2.1rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.kv-calc__lead {
  margin: 0 0 1.5rem;
  max-width: 52ch;
  color: var(--ink-muted);
}

.kv-calc__form {
  display: grid;
  gap: 1.25rem;
}

.kv-calc__row--plz {
  display: grid;
  grid-template-columns: minmax(0, 220px) 1fr;
  gap: 1rem;
  align-items: end;
}

.kv-calc label {
  display: grid;
  gap: 0.35rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}

.kv-calc label span {
  color: var(--ink-muted);
  font-weight: 600;
  font-size: 0.82rem;
}

.kv-calc input[type='text'],
.kv-calc input[type='number'],
.kv-calc select {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font: inherit;
  font-size: 1rem;
}

.kv-calc input:focus,
.kv-calc select:focus {
  outline: 2px solid color-mix(in srgb, var(--brand) 45%, transparent);
  outline-offset: 1px;
}

.kv-calc__meta {
  margin: 0;
  padding-bottom: 0.85rem;
  color: var(--ink-muted);
  font-size: 0.92rem;
}

.kv-calc__people-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.kv-calc__people-head h3 {
  margin: 0;
  font-size: 1.05rem;
}

.kv-calc__adders {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.kv-person {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.95rem 1rem;
  margin-bottom: 0.75rem;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  animation: kv-fade-up 0.35s ease both;
}

.kv-person__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.kv-person__remove {
  border: 0;
  background: transparent;
  color: var(--ink-muted);
  font: inherit;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.kv-person__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  align-items: end;
}

.kv-person__hint {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.85rem;
  align-self: center;
}

.kv-switch {
  display: flex !important;
  align-items: center;
  gap: 0.55rem;
  font-weight: 500 !important;
  padding-bottom: 0.55rem;
}

.kv-switch input {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--brand);
}

.kv-calc__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem 1.25rem;
  padding-top: 0.25rem;
}

.kv-calc__submit {
  min-width: 12rem;
  border-radius: 12px !important;
  padding: 0.85rem 1.35rem !important;
  font-size: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kv-calc__submit:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(15, 92, 76, 0.22);
}

.kv-calc__note {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.kv-calc__error {
  margin: 0;
  color: #b42318;
  font-weight: 600;
}

.kv-calc__results {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  animation: kv-fade-up 0.45s ease both;
}

.kv-calc__summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.kv-calc__stat {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.95rem 1rem;
  background: var(--bg);
  display: grid;
  gap: 0.2rem;
}

.kv-calc__stat span {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  font-weight: 700;
}

.kv-calc__stat strong {
  font-family: var(--font-display);
  font-size: 1.45rem;
  letter-spacing: -0.02em;
}

.kv-calc__stat em {
  font-style: normal;
  color: var(--ink-muted);
  font-size: 0.88rem;
}

.kv-calc__stat-insurer {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.kv-calc__stat-insurer .kv-logo-wrap,
.kv-calc__stat-insurer .kv-logo {
  width: 28px;
  height: 28px;
}

.kv-calc__stat-insurer .kv-logo {
  border-radius: 7px;
  padding: 2px;
}

.kv-calc__stat-insurer span {
  font-size: 0.88rem;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--ink-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kv-logo-wrap {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
}

.kv-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 4px;
  display: block;
  flex: 0 0 auto;
  box-sizing: border-box;
}

.kv-logo--fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--brand-deep);
  background: color-mix(in srgb, var(--brand) 12%, var(--bg));
  letter-spacing: 0.02em;
  box-sizing: border-box;
}

.kv-calc__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.kv-offer {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg);
  padding: 0.85rem 0.95rem;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.kv-offer:hover {
  border-color: color-mix(in srgb, var(--brand) 35%, var(--line));
}

.kv-offer--best {
  border-color: color-mix(in srgb, var(--brand) 45%, var(--line));
  box-shadow: 0 8px 22px rgba(15, 92, 76, 0.08);
}

.kv-offer__main {
  display: grid;
  grid-template-columns: 1.7rem 44px minmax(0, 1fr) auto auto;
  gap: 0.65rem 0.7rem;
  align-items: center;
}

.kv-offer__rank {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-deep);
  background: color-mix(in srgb, var(--brand) 12%, transparent);
  flex: 0 0 auto;
}

.kv-offer--best .kv-offer__rank {
  background: var(--brand);
  color: #fff;
}

.kv-offer__meta {
  min-width: 0;
  display: grid;
  gap: 0.12rem;
}

.kv-offer__name {
  font-size: 0.95rem;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kv-offer__model {
  color: var(--ink-muted);
  font-size: 0.82rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kv-offer__price {
  text-align: right;
  display: grid;
  gap: 0.05rem;
  justify-items: end;
}

.kv-offer__price strong {
  font-family: var(--font-display);
  font-size: 1.12rem;
  color: var(--brand-deep);
  white-space: nowrap;
}

.kv-offer__price span {
  color: var(--ink-muted);
  font-size: 0.75rem;
}

.kv-offer__cta {
  white-space: nowrap;
  padding: 0.5rem 0.85rem !important;
  border-radius: 999px !important;
  font-size: 0.82rem !important;
  min-height: 40px;
}

.kv-offer__form {
  margin-top: 0.85rem;
  padding: 0.95rem;
  border-radius: 12px;
  background: color-mix(in srgb, var(--brand) 7%, var(--bg-elevated));
  border: 1px solid color-mix(in srgb, var(--brand) 22%, var(--line));
}

.kv-offer__form-lead {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
  color: var(--ink-muted);
  line-height: 1.45;
}

.kv-offerte-form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.kv-offerte-form label {
  display: grid;
  gap: 0.3rem;
  font-size: 0.82rem;
  color: var(--ink-muted);
}

.kv-offerte-form input[type='text'],
.kv-offerte-form input[type='email'],
.kv-offerte-form input[type='tel'] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--ink);
  padding: 0.65rem 0.75rem;
  font: inherit;
  font-size: 0.95rem;
}

.kv-offerte-form__consent {
  display: flex !important;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0.85rem 0 0.75rem;
  font-size: 0.86rem !important;
  color: var(--ink) !important;
  line-height: 1.4;
}

.kv-offerte-form__consent input {
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.kv-offerte-form__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.kv-offerte-form__status,
.kv-offerte-form__done {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

.kv-offerte-form__done {
  color: var(--ink);
}

:root[data-theme='dark'] .kv-logo,
:root:not([data-theme='light']) .kv-logo {
  background: #f7faf8;
}

:root[data-theme='dark'] .kv-offer__price strong,
:root:not([data-theme='light']) .kv-offer__price strong {
  color: var(--brand);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .kv-logo {
    background: #f7faf8;
  }
  :root:not([data-theme='light']) .kv-offer__price strong {
    color: var(--brand);
  }
}

.kv-offer__details {
  margin-top: 0.55rem;
  padding-top: 0.45rem;
  border-top: 1px dashed var(--line);
}

.kv-offer__details summary {
  cursor: pointer;
  color: var(--ink-muted);
  font-size: 0.86rem;
  font-weight: 600;
}

.kv-calc__detail-list {
  list-style: none;
  margin: 0.65rem 0 0.35rem;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.kv-calc__detail-list li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.35rem 1rem;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.kv-calc__disclaimer {
  margin: 1rem 0 0;
  color: var(--ink-muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

.kv-calc__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.15rem;
}

@keyframes kv-fade-up {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 800px) {
  .kv-calc {
    padding: 0 0.85rem 0.5rem;
  }

  .kv-calc__shell {
    padding: 1.05rem 0.95rem 1.2rem;
    border-radius: 16px;
  }

  .kv-calc__title {
    font-size: 1.45rem;
  }

  .kv-calc__lead {
    font-size: 0.95rem;
    margin-bottom: 1.1rem;
  }

  .kv-calc__row--plz,
  .kv-person__grid,
  .kv-calc__summary {
    grid-template-columns: 1fr;
  }

  .kv-calc__people-head {
    align-items: stretch;
  }

  .kv-calc__adders {
    width: 100%;
  }

  .kv-calc__adders .btn {
    flex: 1 1 auto;
    justify-content: center;
    min-height: 44px;
    border-radius: 12px;
  }

  .kv-person {
    padding: 0.85rem;
  }

  .kv-person__grid {
    gap: 0.65rem;
  }

  .kv-calc__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .kv-calc__submit {
    width: 100%;
    min-width: 0;
    min-height: 48px;
    border-radius: 14px !important;
  }

  .kv-calc__note {
    text-align: center;
  }

  .kv-calc__summary {
    gap: 0.65rem;
  }

  .kv-calc__stat strong {
    font-size: 1.3rem;
  }

  .kv-offer {
    padding: 0.8rem;
  }

  .kv-offer__main {
    grid-template-columns: 1.6rem 40px minmax(0, 1fr);
    grid-template-areas:
      "rank logo meta"
      "price price price"
      "cta cta cta";
    column-gap: 0.55rem;
    row-gap: 0.55rem;
  }

  .kv-offer__rank { grid-area: rank; }
  .kv-offer__main > .kv-logo { grid-area: logo; }
  .kv-offer__meta { grid-area: meta; }
  .kv-offer__price {
    grid-area: price;
    text-align: left;
    justify-items: start;
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    padding-top: 0.55rem;
    border-top: 1px solid var(--line);
    margin: 0;
  }

  .kv-offer__cta {
    grid-area: cta;
    width: 100%;
    justify-content: center;
    border-radius: 12px !important;
    min-height: 44px;
  }

  .kv-offer__price strong {
    font-size: 1.22rem;
  }

  .kv-offer__name {
    -webkit-line-clamp: 2;
    white-space: normal;
  }

  .kv-offer__model {
    white-space: nowrap;
  }

  .kv-offerte-form__grid {
    grid-template-columns: 1fr;
  }

  .kv-offerte-form__actions {
    flex-direction: column;
  }

  .kv-offerte-form__actions .btn {
    width: 100%;
    min-height: 46px;
    border-radius: 12px;
  }

  .kv-calc__cta {
    flex-direction: column;
  }

  .kv-calc__cta .btn {
    width: 100%;
    min-height: 46px;
    border-radius: 12px;
  }
}

@media (max-width: 420px) {
  .kv-logo,
  .kv-logo-wrap {
    width: 40px;
    height: 40px;
  }

  .kv-logo {
    width: 40px;
    height: 40px;
  }
}

