/* ============================================
   Mein-E-Autorechner.de - Stylesheet
   Modern, electric, trustworthy design
   ============================================ */

:root {
  --color-primary: #0066ff;
  --color-primary-dark: #0052cc;
  --color-primary-light: #00d4ff;
  --color-accent: #00e676;
  --color-accent-dark: #00b050;
  --color-bg: #fefefe;
  --color-bg-alt: #f6f9fc;
  --color-bg-card: #ffffff;
  --color-text: #0f172a;
  --color-text-light: #64748b;
  --color-border: #e2e8f0;
  --color-success: #00b050;
  --color-warning: #f59e0b;
  --color-danger: #ef4444;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 25px -5px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 40px -10px rgb(0 102 255 / 0.15);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Plus Jakarta Sans', 'Inter', sans-serif;
  --gradient-primary: linear-gradient(135deg, #0066ff 0%, #00d4ff 100%);
  --gradient-accent: linear-gradient(135deg, #00e676 0%, #00d4ff 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text);
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: 1rem; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 1rem; margin-top: 2rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.75rem; margin-top: 1.5rem; }
p { margin-bottom: 1rem; }

a { color: var(--color-primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-primary-dark); }

.container { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: 760px; margin: 0 auto; padding: 0 1.5rem; }

/* Header */
.header {
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(8px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--color-primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--gradient-primary);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(0, 102, 255, 0.3);
}

.nav { display: flex; gap: 2rem; align-items: center; }
.nav a { color: var(--color-text); font-weight: 500; font-size: 0.95rem; }
.nav a:hover { color: var(--color-primary); }

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  margin: 5px 0;
  transition: 0.3s;
}

@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    padding: 1.5rem;
    gap: 1rem;
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
  }
  .nav.open { display: flex; }
}

/* Hero */
.hero {
  background: linear-gradient(135deg, #eef4ff 0%, #e0f7ff 50%, #e6fff5 100%);
  padding: 5rem 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 230, 118, 0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content { position: relative; z-index: 1; }

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--color-text-light);
  max-width: 600px;
  margin: 0 auto 2rem;
}

.badge {
  display: inline-block;
  background: white;
  color: var(--color-primary);
  padding: 0.5rem 1.25rem;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(0, 102, 255, 0.1);
}

/* Tools section */
.tools-section { padding: 4rem 0; background: var(--color-bg-alt); }

.section-title { text-align: center; margin-bottom: 3rem; }
.section-title h2 { margin-bottom: 0.5rem; }
.section-title p { color: var(--color-text-light); }

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.tool-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--color-text);
  position: relative;
  overflow: hidden;
}

.tool-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s;
}

.tool-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
  border-color: var(--color-primary-light);
  color: var(--color-text);
}

.tool-card:hover::before { opacity: 1; }

.tool-card-icon {
  width: 52px;
  height: 52px;
  background: var(--gradient-primary);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: white;
  margin-bottom: 1rem;
  box-shadow: 0 8px 16px rgba(0, 102, 255, 0.2);
}

.tool-card h3 { margin: 0 0 0.5rem 0; font-size: 1.15rem; }
.tool-card p { color: var(--color-text-light); font-size: 0.95rem; flex: 1; margin-bottom: 1rem; }
.tool-card-link { color: var(--color-primary); font-weight: 600; font-size: 0.9rem; }

/* Tool page */
.tool-page { padding: 3rem 0; }

.breadcrumb {
  font-size: 0.9rem;
  color: var(--color-text-light);
  margin-bottom: 1.5rem;
}

.tool-card-main {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
}

.form-group { margin-bottom: 1.25rem; }

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: white;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; }

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

.btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  width: 100%;
  box-shadow: 0 4px 12px rgba(0, 102, 255, 0.25);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0, 102, 255, 0.35);
}

.btn-secondary {
  background: white;
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
  box-shadow: none;
}

.btn-secondary:hover {
  background: var(--color-bg-alt);
  box-shadow: var(--shadow-sm);
}

/* Result Box */
.result-box {
  margin-top: 1.5rem;
  padding: 1.75rem;
  background: linear-gradient(135deg, #eef4ff 0%, #e0f7ff 100%);
  border-left: 4px solid var(--color-primary);
  border-radius: var(--radius-md);
  display: none;
}

.result-box.visible { display: block; }

.result-value {
  font-size: 2.75rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-family: var(--font-display);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.result-label { font-weight: 600; margin-bottom: 0.5rem; }
.result-text { color: var(--color-text); font-size: 0.95rem; }

.result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.result-item {
  background: white;
  padding: 1rem;
  border-radius: var(--radius-sm);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.result-item-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-primary);
  font-family: var(--font-display);
}

.result-item-label { font-size: 0.85rem; color: var(--color-text-light); }

/* Info sections */
.info-section {
  background: var(--color-bg-alt);
  padding: 2rem;
  border-radius: var(--radius-lg);
  margin: 2rem 0;
}

.info-section h2 { margin-top: 0; }
.info-section ul { padding-left: 1.5rem; margin-bottom: 1rem; }
.info-section li { margin-bottom: 0.5rem; }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

table th {
  background: var(--gradient-primary);
  color: white;
  padding: 0.75rem;
  text-align: left;
  font-weight: 600;
}

table td { padding: 0.75rem; border-top: 1px solid var(--color-border); }
table tr:nth-child(even) { background: var(--color-bg-alt); }

.formula-box {
  background: var(--color-bg-alt);
  padding: 1rem;
  border-radius: 8px;
  font-family: monospace;
  font-size: 0.95rem;
  margin: 1rem 0;
  border-left: 3px solid var(--color-primary);
}

.highlight-box {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  border-left: 4px solid var(--color-warning);
  margin: 1.5rem 0;
}

.highlight-box.success {
  background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
  border-left-color: var(--color-success);
}

/* Footer */
.footer { background: #0a0e1a; color: #cbd5e1; padding: 3rem 0 1.5rem; margin-top: 4rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

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

.footer h4 { color: white; margin-bottom: 1rem; font-size: 1rem; }
.footer a { color: #cbd5e1; display: block; padding: 0.25rem 0; font-size: 0.95rem; }
.footer a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: #94a3b8;
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  max-width: 500px;
  margin: 0 auto;
  background: white;
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: 0 20px 50px rgba(0,0,0,0.15);
  border: 1px solid var(--color-border);
  z-index: 1000;
  display: none;
}

.cookie-banner.visible { display: block; }
.cookie-banner h4 { margin-bottom: 0.5rem; }
.cookie-banner p { font-size: 0.9rem; color: var(--color-text-light); margin-bottom: 1rem; }
.cookie-buttons { display: flex; gap: 0.75rem; }
.cookie-buttons .btn { width: auto; flex: 1; padding: 0.65rem 1rem; font-size: 0.9rem; }

/* Ad placeholder */
.ad-slot {
  margin: 2rem 0;
  padding: 1rem;
  background: var(--color-bg-alt);
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-md);
  text-align: center;
  color: var(--color-text-light);
  font-size: 0.85rem;
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.text-center { text-align: center; }
.mt-2 { margin-top: 2rem; }
.mb-2 { margin-bottom: 2rem; }
