/* raten-rechner.de - Hauptstylesheet 2025 */

:root {
  --bg: #dce8f0;
  --card: #ffffff;
  --text: #152535;
  --muted: #3a5a6a;
  --line: rgba(0,50,80,.18);
  --brand: #006090;
  --brand2: #0088c0;
  --accent: #004a70;
  --accent2: #0070a0;
  --radius: 18px;
  --shadow: 0 18px 45px rgba(0,40,70,.18);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  line-height: 1.65;
}

a {
  color: inherit;
}

/* Container */
.container {
  width: min(1120px, 92%);
  margin: 0 auto;
}

/* Topbar / Navigation */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255,255,255,.95);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo-img {
  height: 48px;
  width: auto;
  display: block;
}

.navlinks {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.navlinks a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 12px;
}

.navlinks a:hover {
  background: rgba(0,95,138,.1);
  color: var(--accent);
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(0,119,168,.35);
  background: linear-gradient(135deg, rgba(0,119,168,.12), rgba(0,160,214,.08));
  font-weight: 700;
  text-decoration: none;
  color: var(--brand);
}

/* Hero Section */
.hero {
  padding: 28px 0 18px;
}

.breadcrumb {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  margin: 18px 0 8px;
}

.breadcrumb a {
  color: var(--muted);
  text-decoration: none;
}

.heroGrid {
  display: grid;
  grid-template-columns: 1.25fr .75fr;
  gap: 18px;
}

/* Cards */
.card {
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,255,255,.92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
}

.card.calculator {
  background: linear-gradient(180deg, rgba(220,245,235,.95), rgba(200,235,220,.85));
  border: 1px solid rgba(0,120,100,.15);
}

/* Typography */
h1 {
  font-size: 34px;
  line-height: 1.15;
  margin: 6px 0 14px;
}

h2 {
  font-size: 24px;
  margin: 28px 0 14px;
}

h3 {
  font-size: 20px;
  margin: 22px 0 12px;
}

.lead {
  color: var(--muted);
  margin: 0 0 18px;
  font-size: 16px;
}

/* Grid Layouts */
.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* Bubbles */
.bubble {
  padding: 18px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(0,95,138,.05);
  transition: all .2s;
}

.bubble:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,119,168,.18);
  background: rgba(0,119,168,.08);
}

.bubble strong {
  display: block;
  margin-bottom: 8px;
  font-size: 16px;
}

.bubble p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

/* Form Elements */
.formgrid {
  display: grid;
  gap: 16px;
}

.field label {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
  font-weight: 600;
}

.field input,
.field select {
  width: 100%;
  padding: 14px;
  background: #ffffff;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 14px;
  font-size: 16px;
  transition: border-color .2s;
}

.field select {
  background: #ffffff;
  color: var(--text);
}

.field select option {
  background: #ffffff;
  color: var(--text);
  padding: 10px;
}

.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(0,119,168,.18);
}

.field-help {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 4px;
}

/* Quick Presets */
.quick-presets {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.quick-presets strong {
  font-size: 13px;
  color: var(--muted);
  margin-right: 4px;
}

.preset-btn {
  padding: 6px 12px;
  font-size: 12px;
  background: rgba(0,96,144,.08);
  border: 1px solid rgba(0,96,144,.2);
  border-radius: 20px;
  color: var(--brand);
  cursor: pointer;
  transition: all .2s;
  font-weight: 600;
}

.preset-btn:hover {
  background: rgba(0,96,144,.15);
  transform: translateY(-1px);
}

/* Buttons */
.btnrow {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.btn {
  cursor: pointer;
  border: none;
  border-radius: 14px;
  padding: 14px 20px;
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  transition: all .2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 25px rgba(0,119,168,.4);
}

.btn.secondary {
  background: rgba(0,95,138,.1);
  color: var(--accent);
  border: 1px solid rgba(0,95,138,.25);
}

.btn.ghost {
  background: rgba(0,95,138,.05);
  color: var(--accent);
  border: 1px solid var(--line);
  font-weight: 700;
}

/* Notices */
.notice {
  border: 1px solid rgba(0,119,168,.3);
  background: rgba(0,119,168,.07);
  padding: 16px;
  border-radius: 16px;
  color: var(--text);
  font-size: 14px;
}

.notice b {
  color: var(--brand);
}

.danger {
  border: 1px solid rgba(220,80,80,.3);
  background: rgba(220,80,80,.06);
  padding: 16px;
  border-radius: 16px;
  color: var(--text);
  font-size: 14px;
}

.danger b {
  color: #dc5050;
}

/* KPIs */
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 24px 0;
}

.kpi {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 12px;
  background: rgba(0,95,138,.04);
  text-align: center;
  transition: transform .2s;
  min-width: 0;
  overflow: hidden;
}

.kpi:hover {
  transform: translateY(-4px);
  background: rgba(0,119,168,.08);
}

.kpi .label {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kpi .value {
  font-size: clamp(16px, 3.5vw, 24px);
  font-weight: 900;
  margin: 8px 0 4px;
  color: var(--brand);
  word-break: break-word;
  overflow-wrap: break-word;
  line-height: 1.2;
}

.kpi .hint {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Tables */
.tableWrap {
  overflow: auto;
  border-radius: 16px;
  border: 1px solid var(--line);
  margin: 18px 0;
  background: rgba(255,255,255,.6);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-size: 14px;
}

th {
  color: var(--muted);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: .5px;
}

tr:hover {
  background: rgba(0,119,168,.06);
}

/* Sections */
.section {
  padding: 40px 0;
}

/* Features */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 40px 0;
}

.feature {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
}

.feature-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--accent), var(--brand));
  border-radius: 50%;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: bold;
  color: #fff;
}

/* Lists */
ul {
  list-style: none;
  padding: 0;
}

ul li {
  position: relative;
  padding-left: 24px;
  margin: 12px 0;
  color: var(--text);
}

ul li:before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--brand);
  font-weight: bold;
  font-size: 16px;
}

/* Details / Accordion */
details {
  border: 1px solid var(--line);
  background: rgba(0,95,138,.04);
  border-radius: 16px;
  padding: 16px;
  margin: 16px 0;
  cursor: pointer;
  transition: all .2s;
}

details[open] {
  background: rgba(0,119,168,.08);
}

summary {
  cursor: pointer;
  font-weight: 800;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

details p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

/* Footer */
footer {
  margin-top: 40px;
  border-top: 1px solid var(--line);
  padding: 40px 0 26px;
  color: var(--muted);
  text-align: center;
}

/* CTA Section */
.cta-section {
  background: linear-gradient(135deg, var(--accent), var(--brand));
  color: #fff;
  padding: 40px 20px;
  border-radius: var(--radius);
  margin: 40px 0;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.cta-section h2 {
  margin: 0 0 16px;
  font-size: 28px;
  color: #fff;
  text-align: center;
}

.cta-section p {
  text-align: center;
  margin: 0 0 24px;
}

.cta-section .btn {
  background: #fff;
  color: var(--brand);
  padding: 16px 32px;
  font-size: 18px;
}

/* Affiliate Form Styles */
.affiliate-box {
  margin-top: 24px;
  padding: 20px;
  border: 1px solid rgba(200,120,50,.3);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,237,213,.9), rgba(255,228,196,.8));
}

.affiliate-title {
  margin-bottom: 16px;
}

.affiliate-title strong {
  font-size: 16px;
  color: var(--text);
  display: block;
  margin-bottom: 4px;
}

.affiliate-title small {
  font-size: 12px;
  color: var(--muted);
}

.affiliate-title small a {
  color: #c06000;
}

.affiliate-label {
  font-size: 11px;
  color: #c06000;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.affiliate-form .form-row-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.affiliate-form .form-group {
  margin-bottom: 12px;
}

.affiliate-form .form-group label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
  font-weight: 600;
}

.affiliate-form .select-shell {
  position: relative;
}

.affiliate-form .select-shell select {
  width: 100%;
  padding: 12px 12px 12px 36px;
  background: #fffaf5;
  border: 1px solid rgba(200,120,50,.25);
  color: var(--text);
  border-radius: 12px;
  font-size: 14px;
  appearance: none;
  cursor: pointer;
}

.affiliate-form .select-shell select option {
  background: #fffaf5;
  color: var(--text);
  padding: 8px;
}

.affiliate-form .select-shell select:focus {
  outline: none;
  border-color: #d97706;
}

.affiliate-form .select-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  pointer-events: none;
}

.affiliate-form .btn-primary {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #d97706, #f59e0b);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  margin-top: 8px;
  transition: all .2s;
}

.affiliate-form .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 25px rgba(217,119,6,.4);
}

.affiliate-disclaimer {
  font-size: 11px;
  color: var(--muted);
  margin-top: 14px;
  line-height: 1.5;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.form-powered {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 12px;
}

.form-powered a {
  color: var(--brand);
  text-decoration: none;
}

/* Responsive */
@media (max-width: 980px) {
  .heroGrid {
    grid-template-columns: 1fr;
  }
  
  .nav {
    flex-wrap: wrap;
  }
  
  .navlinks {
    width: 100%;
    justify-content: flex-start;
  }
  
  .grid3 {
    grid-template-columns: 1fr;
  }
  
  .kpis {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  
  .kpi {
    padding: 14px 10px;
  }
  
  .kpi .value {
    font-size: clamp(15px, 4vw, 20px);
  }
}

@media (max-width: 480px) {
  .kpis {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  
  .kpi {
    padding: 12px 8px;
  }
  
  .kpi .label {
    font-size: 11px;
  }
  
  .kpi .value {
    font-size: clamp(14px, 3.5vw, 18px);
  }
  
  .kpi .hint {
    font-size: 10px;
  }
}

@media (max-width: 600px) {
  .affiliate-form .form-row-main {
    grid-template-columns: 1fr;
  }
}

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