/* ===== CSS Custom Properties — Elegant Fintech (Kautionsrechner-Style) ===== */
:root {
  /* Primary – Muted Teal/Forest Green */
  --color-primary: #4E7A6E;
  --color-primary-dark: #3D6358;
  --color-primary-light: #E8F0ED;
  --color-primary-hover: #5D8B7E;

  /* Accent – Warm Gold */
  --color-accent: #C9A96E;
  --color-accent-light: #F5EDD8;
  --color-accent-dark: #B08E4A;

  /* Backgrounds – Warm Cream */
  --color-bg: #F5F1EB;
  --color-bg-alt: #EDE8E0;
  --color-bg-card: #FFFFFF;
  --color-surface: #FAFAF7;
  --color-bg-muted: #F0ECE4;

  /* Hero & Footer – Dark Forest */
  --color-dark: #1A2E2B;
  --color-dark-alt: #243D39;
  --color-dark-card: #2A3F3B;

  /* Text */
  --color-text: #1A2E2B;
  --color-text-secondary: #5F7370;
  --color-text-muted: #8A9A97;

  /* Borders */
  --color-border: #D8D3CB;
  --color-border-light: #E8E3DB;

  /* Semantic */
  --color-success: #4E7A6E;
  --color-danger: #C0392B;
  --color-bid: #4E7A6E;
  --color-ask: #C0392B;
  --color-warning: #D4A017;
  --color-info: #4E7A6E;

  /* Radius – elegant, generous */
  --radius: 12px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --radius-full: 999px;

  /* Shadows – subtle, warm */
  --shadow-xs: 0 1px 2px rgba(26,46,43,0.04);
  --shadow: 0 1px 4px rgba(26,46,43,0.06);
  --shadow-md: 0 4px 12px rgba(26,46,43,0.08);
  --shadow-lg: 0 8px 24px rgba(26,46,43,0.10);

  /* Layout */
  --max-width: 1200px;
  --header-height: 56px;

  /* Typography */
  --font-stack: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", "Fira Code", monospace;

  /* Motion */
  --transition: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 15px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-stack);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

main { flex: 1; }

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

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

a:hover { color: var(--color-primary-dark); }

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

/* Utility classes */
.text-accent { color: var(--color-accent); }
.text-gold { color: var(--color-accent); font-style: italic; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

/* ===== Header — Dark Forest ===== */
.site-header {
  background: var(--color-dark);
  border-bottom: none;
  height: var(--header-height);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
  letter-spacing: -0.02em;
}

.logo:hover { color: var(--color-accent); }

.logo svg rect { fill: var(--color-accent); }

.logo-text { white-space: nowrap; }

.main-nav .nav-list {
  display: flex;
  list-style: none;
  gap: 0.25rem;
  align-items: center;
}

.main-nav a {
  color: rgba(255,255,255,0.8);
  font-size: 0.867rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

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

.nav-lang a {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  font-weight: 500;
}

.nav-lang a:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  flex-direction: column;
  gap: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.9);
  transition: 0.3s;
  border-radius: 2px;
}

/* ===== Hero — Dark Forest Gradient ===== */
.hero {
  background: linear-gradient(170deg, #1A2E2B 0%, #243D39 40%, #2D4A44 100%);
  padding: 4rem 0 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -15%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(201,169,110,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero h1 {
  font-size: 2.75rem;
  margin-bottom: 0.5rem;
  color: #fff !important;
  position: relative;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--color-accent);
  font-weight: 600;
  font-style: italic;
  margin-bottom: 0.75rem;
  position: relative;
}

.hero-desc {
  color: rgba(255,255,255,0.65);
  max-width: 550px;
  margin: 0 auto 2.5rem;
  position: relative;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ===== Search ===== */
.search-box {
  position: relative;
  max-width: 520px;
  margin: 0 auto;
}

.search-input {
  width: 100%;
  padding: 0.9rem 1.25rem 0.9rem 3rem;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  font-family: var(--font-stack);
  transition: all var(--transition);
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.search-box::before {
  content: '';
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23888888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E");
  z-index: 1;
  pointer-events: none;
}

.search-input::placeholder { color: rgba(255,255,255,0.45); }

.search-input:focus {
  outline: none;
  border-color: var(--color-accent);
  background: rgba(255,255,255,0.12);
  box-shadow: 0 0 0 3px rgba(201,169,110,0.15);
}

.search-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 50;
  max-height: 300px;
  overflow-y: auto;
}

.search-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
}

.search-item:last-child { border-bottom: none; }
.search-item:hover { background: var(--color-bg-alt); }
.search-item span { color: var(--color-text-secondary); font-size: 0.85rem; font-family: var(--font-mono); }

/* ===== Stats Bar — Warm ===== */
.stats-bar {
  padding: 1rem 0;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}

.stats-grid {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.stat-item {
  text-align: center;
  background: var(--color-bg-alt);
  padding: 1rem 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}
.stat-number { display: block; font-size: 1.75rem; font-weight: 800; color: var(--color-primary); letter-spacing: -0.03em; }
.stat-label { font-size: 0.8rem; color: var(--color-text-secondary); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 500; }

.stats-grid-bar {
  display: flex;
  gap: 0;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}

.stat-item-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.75rem;
  flex: 1;
  border-right: 1px solid var(--color-border-light, #E8E3DB);
}
.stat-item-bar:last-child { border-right: none; }

.stat-icon-bar {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-num-bar {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
}

.stat-lbl-bar {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  font-weight: 600;
  margin-top: 0.2rem;
}

/* ===== Stock Table — Neobroker ===== */
.stocks-section { padding: 2rem 0 3rem; }

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.section-header h2 {
  font-size: 1.35rem;
  font-weight: 700;
}

.filter-bar {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.filter-select {
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-stack);
  font-size: 0.85rem;
  background: var(--color-bg);
}

.sort-buttons { display: flex; gap: 0.25rem; }

.sort-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.85rem;
  font-family: var(--font-stack);
  font-weight: 500;
  transition: all var(--transition);
}

.sort-btn.active, .sort-btn:hover {
  background: var(--color-primary);
  color: white;
  border-color: var(--color-primary);
}

.stock-table-wrapper { overflow-x: auto; }

.stock-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.stock-table th {
  text-align: left;
  padding: 0.65rem 0.75rem;
  background: transparent;
  font-weight: 600;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  border-bottom: 1px solid var(--color-border);
  white-space: nowrap;
}

.stock-table td {
  padding: 0.8rem 0.75rem;
  border-bottom: 1px solid var(--color-border-light);
  vertical-align: middle;
  color: var(--color-text);
}

.stock-table tbody tr { transition: background var(--transition); }
.stock-table tbody tr:hover { background: var(--color-bg-card); }

.stock-table .num {
  text-align: right;
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

.stock-table small { color: var(--color-text-secondary); font-size: 0.75rem; }

.stock-row:hover { background: var(--color-bg-alt); }

.stock-link { color: var(--color-text); }
.stock-link:hover { color: var(--color-primary); }

.isin-cell { font-family: var(--font-mono); font-size: 0.8rem; color: var(--color-text-secondary); }

/* ===== Badge ===== */
.badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  background: var(--color-bg-alt);
  border-radius: 99px;
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  white-space: nowrap;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.6rem 1.25rem;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-stack);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
  text-decoration: none;
  line-height: 1.4;
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(78, 122, 110, 0.25);
}

.btn-primary:hover {
  background: var(--color-primary-dark);
  color: #fff;
  box-shadow: 0 4px 12px rgba(78, 122, 110, 0.35);
  transform: translateY(-1px);
}

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

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

.btn-link {
  background: none;
  color: var(--color-primary);
  padding: 0.6rem 0.5rem;
  text-decoration: underline;
}

/* ===== Stock Detail Page ===== */
/* ===== Breadcrumb — Neobroker ===== */
.breadcrumb {
  background: transparent;
  padding: 0.6rem 0;
  font-size: 0.8rem;
}

.breadcrumb ol {
  display: flex;
  list-style: none;
  gap: 0.35rem;
  flex-wrap: wrap;
  align-items: center;
}

.breadcrumb li::after {
  content: '›';
  margin-left: 0.35rem;
  color: var(--color-text-muted);
  font-size: 0.9em;
}

.breadcrumb li:last-child::after { content: ''; }
.breadcrumb li:last-child { color: var(--color-text-muted); }
.breadcrumb a { color: var(--color-text-muted); font-weight: 400; }
.breadcrumb a:hover { color: var(--color-primary); }

/* ===== Stock Header — Elegant ===== */
.stock-header {
  padding: 2rem 0 1.25rem;
  background: linear-gradient(135deg, #f0f4f8 0%, var(--color-surface) 60%, #f5f0e8 100%);
  border-bottom: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
}

.stock-header::after {
  content: '';
  position: absolute;
  top: -40%;
  right: -10%;
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(201,169,110,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.stock-header-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
}

.stock-title-area h1 {
  font-size: 1.65rem;
  margin-bottom: 0.4rem;
  font-weight: 700;
}

.stock-title-area h1 small {
  font-weight: 400;
  color: var(--color-text-muted);
  font-size: 0.55em;
}

.stock-meta {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  align-items: center;
}

.stock-meta .badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  background: var(--color-primary-light);
  color: var(--color-primary);
  border: none;
}

.isin-tag, .currency-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.15rem 0.5rem;
  background: var(--color-bg);
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.stock-price-box {
  text-align: right;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow);
  min-width: 220px;
}

.main-price {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}

.main-currency {
  font-size: 1rem;
  color: var(--color-text-secondary);
}

.price-date {
  display: block;
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  margin-top: 0.25rem;
}

.price-change-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.2em;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.2em 0.55em;
  border-radius: var(--radius-full);
  vertical-align: middle;
  margin-left: 0.5rem;
  letter-spacing: 0.01em;
}

.price-change-badge.price-up {
  background: rgba(78, 122, 110, 0.12);
  color: var(--color-success);
}

.price-change-badge.price-down {
  background: rgba(192, 57, 43, 0.1);
  color: var(--color-danger);
}

/* ===== Price Grid — Neobroker ===== */
.price-details { padding: 1.25rem 0; }

.price-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.price-card {
  background: var(--color-bg-card);
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  text-align: left;
  border: 1px solid var(--color-border);
  transition: all var(--transition);
}

.price-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow);
}

.price-label {
  display: block;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  margin-bottom: 0.3rem;
  font-weight: 600;
}

.price-val {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.price-val.bid { color: var(--color-bid); }
.price-val.ask { color: var(--color-ask); }

.price-qty {
  display: block;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-top: 0.2rem;
}

/* ===== Trade CTA — Neobroker ===== */
.trade-cta {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.trade-cta .btn,
.trade-cta .btn-primary {
  flex: 1;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--color-primary);
  color: #fff;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.trade-cta .btn:hover,
.trade-cta .btn-primary:hover {
  background: var(--color-primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.trade-cta .btn-sell {
  flex: 1;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: transparent;
  color: var(--color-danger);
  border: 1.5px solid var(--color-danger);
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.trade-cta .btn-sell:hover {
  background: var(--color-danger);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* ===== Chart — Elegant ===== */
.chart-section {
  padding: 2rem 0;
  background: var(--color-bg);
}

.chart-controls {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--color-border-light);
  padding-bottom: 0.5rem;
}

.chart-period {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.85rem;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: var(--font-stack);
  transition: all var(--transition);
  color: var(--color-text-muted);
  position: relative;
}

.chart-period.active {
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
}

.chart-period:hover {
  color: var(--color-text);
}

.chart-container {
  background: var(--color-bg-card);
  padding: 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  height: 320px;
}

.chart-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--color-text-secondary);
  font-style: italic;
  text-align: center;
  padding: 2rem;
}

.chart-note {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  margin-top: 0.5rem;
}

.chart-notice {
  display: none;
  font-size: 0.8rem;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.75rem;
  margin: 0.5rem 0 0;
}

/* Content Grid (Main + Sidebar) */
.company-section { padding: 2rem 0; }

.content-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2rem;
  align-items: start;
}

.content-sidebar { position: sticky; top: calc(var(--header-height) + 1rem); }

/* ===== Content Typography — Elegant Readable ===== */
.company-desc {
  margin-bottom: 1.25rem;
  line-height: 1.8;
  font-size: 0.95rem;
  color: var(--color-text);
  max-width: 65ch;
}

.company-desc::first-line {
  font-weight: 500;
}

.source-note {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
  font-style: italic;
}

.source-note a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.no-data {
  color: var(--color-text-secondary);
  font-style: italic;
  margin-bottom: 1.5rem;
}

/* Detail Table */
.detail-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1.25rem;
  background: var(--color-bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
}

.detail-table th,
.detail-table td {
  padding: 0.7rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border-light);
  font-size: 0.88rem;
}

.detail-table th {
  width: 40%;
  color: var(--color-text-muted);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--color-bg);
}

.detail-table tr:last-child th,
.detail-table tr:last-child td { border-bottom: none; }

/* Data Table (Financials) */
.financials-section { padding: 2rem 0; background: var(--color-bg-alt); }
.financials-section .container { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.data-table {
  width: 100%;
  min-width: 480px;
  border-collapse: collapse;
  background: var(--color-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.data-table th,
.data-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

.data-table th {
  background: var(--color-bg-alt);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
}

.data-table .num { text-align: right; font-family: var(--font-mono); }

/* Broker Box */
.broker-box {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  padding: 1.5rem;
  border-radius: var(--radius);
  border: 1px solid #bae6fd;
  position: sticky;
  top: calc(var(--header-height) + 1rem);
}

.broker-box h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.broker-box p {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  margin-bottom: 1rem;
}

.broker-list {
  list-style: none;
}

.broker-link {
  display: block;
  padding: 0.5rem 0.75rem;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  margin-bottom: 0.5rem;
  font-weight: 500;
  transition: all 0.2s;
}

.broker-link:hover {
  border-color: var(--color-primary);
  background: #e8f0fe;
}

/* News */
.news-section { padding: 2rem 0; }

.news-list { list-style: none; }

.news-item {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.news-item time {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  white-space: nowrap;
}

/* Disclaimer */
.disclaimer-section {
  padding: 1.5rem 0;
  border-top: 1px solid var(--color-border);
}

.disclaimer-text, .last-updated {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
}

/* ===== Ad Slots ===== */
.ad-slot {
  text-align: center;
  padding: 0;
  min-height: 0;
}

.ad-slot:not(:has(iframe)):not(:has(ins)):not(:has(img)) { display: none; }

.ad-slot-top { margin: 0.5rem auto; max-width: var(--max-width); }
.ad-slot-mid { margin: 1rem 0; }
.ad-slot-sidebar { margin-top: 1rem; }
.ad-slot-bottom { margin: 0.5rem auto; max-width: var(--max-width); }

/* ===== Footer ===== */
/* ===== Footer — Dark Forest ===== */
.site-footer {
  background: var(--color-dark);
  color: rgba(255,255,255,0.65);
  padding: 3rem 0 1.5rem;
  margin-top: auto;
  border-top: none;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-col h3 {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.footer-col p {
  font-size: 0.85rem;
  line-height: 1.6;
  color: rgba(255,255,255,0.55);
}

.footer-col ul { list-style: none; }

.footer-col li { margin-bottom: 0.4rem; }

.footer-col a {
  color: rgba(255,255,255,0.55);
  font-size: 0.85rem;
  transition: color var(--transition);
}

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

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.25rem;
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

.footer-bottom .disclaimer { margin-top: 0.5rem; font-size: 0.75rem; }
.footer-bottom .data-source { margin-top: 0.25rem; font-size: 0.75rem; }

/* ===== Cookie Banner ===== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--color-bg-card);
  border-top: 1px solid var(--color-border);
  box-shadow: 0 -4px 16px rgba(26,46,43,0.12);
  z-index: 1000;
  padding: 1.25rem;
  color: var(--color-text);
}

.cookie-content {
  max-width: var(--max-width);
  margin: 0 auto;
}

.cookie-title {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.cookie-text {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  margin-bottom: 1rem;
}

.cookie-details { margin-bottom: 1rem; }

.cookie-option {
  display: block;
  padding: 0.5rem 0;
  font-size: 0.85rem;
  cursor: pointer;
}

.cookie-option span {
  display: block;
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  margin-left: 1.5rem;
}

.cookie-option input { margin-right: 0.5rem; }

.cookie-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* ===== Legal Pages ===== */
.legal-page {
  padding: 2rem 0;
}

.legal-page h1 { font-size: 1.75rem; margin-bottom: 1.5rem; }
.legal-page h2 { font-size: 1.25rem; margin: 1.5rem 0 0.75rem; }
.legal-page h3 { font-size: 1rem; margin: 1rem 0 0.5rem; }
.legal-page p { margin-bottom: 0.75rem; line-height: 1.7; }
.legal-page ul { margin: 0.5rem 0 1rem 1.5rem; }
.legal-page li { margin-bottom: 0.25rem; }

/* ===== 404 ===== */
.error-page {
  padding: 4rem 0;
  text-align: center;
}

.error-page h1 {
  font-size: 5rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.error-page p {
  color: var(--color-text-secondary);
  margin-bottom: 2rem;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .content-grid {
    grid-template-columns: 1fr;
  }
  .content-sidebar { position: static; }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .hero h1 { font-size: 1.5rem; }
  .hero-subtitle { font-size: 1rem; }

  .stats-grid { gap: 1.5rem; }
  .stat-number { font-size: 1.25rem; }

  .stats-grid-bar { flex-direction: column; }
  .stat-item-bar { border-right: none; border-bottom: 1px solid var(--color-border-light, #E8E3DB); }
  .stat-item-bar:last-child { border-bottom: none; }

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

  .stock-header-inner {
    flex-direction: column;
  }

  .stock-price-box { text-align: left; min-width: unset; width: 100%; }
  .main-price { font-size: 1.75rem; }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .nav-toggle { display: flex; }

  .main-nav .nav-list {
    display: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-dark);
    flex-direction: column;
    padding: 0.75rem;
    border-bottom: 2px solid var(--color-accent);
    box-shadow: 0 8px 24px rgba(0,0,0,0.35);
    gap: 0.25rem;
    z-index: 200;
  }

  .main-nav .nav-list.open { display: flex; }

  /* Mobile nav: links gut lesbar auf dunklem Hintergrund */
  .main-nav .nav-list > li > a {
    color: rgba(255,255,255,0.88);
    padding: 0.6rem 0.9rem;
    border-radius: var(--radius-sm);
    display: block;
  }
  .main-nav .nav-list > li > a:hover { color: var(--color-accent); background: rgba(255,255,255,0.07); }

  /* Mobile Dropdown: inline statt absolut */
  .nav-dropdown-menu {
    position: static !important;
    display: none;
    background: rgba(255,255,255,0.06);
    border: none !important;
    box-shadow: none !important;
    border-radius: var(--radius-sm);
    padding: 0.25rem 0 0.25rem 0.75rem;
    margin-top: 0.25rem;
  }
  .nav-dropdown.active .nav-dropdown-menu { display: block !important; }
  /* CSS-hover auf Mobile deaktivieren – JS übernimmt */
  .nav-dropdown:hover .nav-dropdown-menu { display: none; }
  .nav-dropdown-menu li a {
    color: rgba(255,255,255,0.8) !important;
    padding: 0.45rem 0.75rem;
    font-size: 0.84rem;
  }
  .nav-dropdown-menu li a:hover { color: var(--color-accent) !important; background: rgba(255,255,255,0.08); }

  /* "Tools ▾" tap öffnet Untermenü auf Mobile */
  .nav-dropdown { position: static; }
  .nav-dropdown > a {
    padding: 0.6rem 0.9rem !important;
    display: block;
    text-align: center;
  }
  .nav-dropdown-menu {
    padding: 0.2rem 0 !important;
    margin: 0.15rem auto 0;
    width: auto;
  }
  .nav-dropdown-menu li a {
    padding: 0.45rem 1.25rem !important;
    text-align: center;
  }

  .stock-table { font-size: 0.8rem; }
  .stock-table th, .stock-table td { padding: 0.5rem; }

  .isin-cell { display: none; }
}

@media (max-width: 480px) {
  .container { padding: 0 0.75rem; }

  .hero { padding: 2rem 0; }
  .hero h1 { font-size: 1.25rem; }

  .stats-grid {
    flex-direction: column;
    gap: 0.75rem;
  }

  .price-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    width: 100%;
  }

  .filter-select { width: 100%; }

  .cookie-actions {
    flex-direction: column;
  }

  .cookie-actions .btn { width: 100%; }
}

/* ===== Wiki / Company Profile ===== */
.wiki-profile,
.company-web-profile {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

/* Company website profile gets a subtle left-border accent to distinguish from wiki */
.company-web-profile {
  border-left: 3px solid var(--color-primary);
  padding-left: 1rem;
}

.wiki-thumb-figure {
  margin: 0 0 0.75rem 0;
  float: right;
  margin-left: 1.25rem;
  max-width: 200px;
}

.wiki-thumbnail {
  border-radius: var(--radius);
  object-fit: cover;
  flex-shrink: 0;
  max-width: 200px;
  height: auto;
  display: block;

}

.wiki-license {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  margin-top: 0.25rem;
  text-align: center;
}

.wiki-license a {
  color: var(--color-text-muted);
  text-decoration: underline;
  text-underline-offset: 1px;
}

.wiki-license a:hover { color: var(--color-primary); }
}

.wiki-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

/* ===== Delisting Section ===== */
.delisting-section {
  padding: 2.5rem 0;
  background: var(--color-bg-alt);
}

.delisting-section .container {
  border-left: 4px solid var(--color-info);
  padding-left: 1.5rem;
  max-width: 850px;
}

.delisting-section h2 {
  margin-bottom: 1rem;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.delisting-section h2::before {
  content: '\2139';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--color-info);
  color: white;
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
}

.delisting-section p {
  margin-bottom: 0.75rem;
  line-height: 1.8;
  color: var(--color-text-secondary);
}

/* ===== How To Buy ===== */
.howto-section { padding: 2.5rem 0; }
.howto-section h2 { margin-bottom: 1.5rem; }

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

.howto-step {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--color-bg-card);
  padding: 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-xs);
  transition: all var(--transition);
}

.howto-step:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: white;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.step-content h3 {
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
  color: var(--color-text);
}

.step-content p {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* ===== FAQ Section ===== */
.faq-section {
  padding: 2.5rem 0;
  background: var(--color-bg-alt);
}

.faq-section h2 { margin-bottom: 1.5rem; }

.faq-list { max-width: 800px; }

.faq-item {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition);
}

.faq-item:hover { box-shadow: var(--shadow); }

.faq-item[open] { border-color: var(--color-primary); }

.faq-question {
  padding: 1.1rem 1.25rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.95rem;
  transition: color var(--transition);
}

.faq-question:hover { color: var(--color-primary); }

.faq-question::after {
  content: '+';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  background: var(--color-bg-alt);
  border-radius: 50%;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--color-primary);
  transition: all var(--transition);
}

.faq-item[open] .faq-question::after {
  content: '\2212';
  background: var(--color-primary);
  color: white;
}

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

.faq-answer {
  padding: 0 1.25rem 1.25rem;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--color-text-secondary);
  border-top: 1px solid var(--color-border-light);
  margin-top: -0.25rem;
  padding-top: 1rem;
  max-width: 65ch;
}

/* ===== Related Stocks ===== */
.related-section { padding: 2rem 0; }
.related-section h2 { margin-bottom: 1.5rem; }

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

.related-card {
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-text);
  transition: all var(--transition);
  box-shadow: var(--shadow-xs);
}

.related-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
  color: var(--color-text);
  transform: translateY(-3px);
}

.related-card strong { font-size: 0.9rem; margin-bottom: 0.25rem; }

.related-meta {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  margin-bottom: 0.5rem;
}

.related-price {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-primary);
}

@media (max-width: 768px) {
  .wiki-profile,
  .company-web-profile { flex-direction: column; }
  .wiki-thumbnail { max-width: 100%; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
}

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

/* ===== Print ===== */
@media print {
  .site-header, .site-footer, .cookie-banner, .ad-slot,
  .trade-cta, .broker-box, .nav-toggle { display: none !important; }

  body { color: black; }
  a { color: black; text-decoration: underline; }
}

/* ===== Info Section Header (Delisting / HowTo / FAQ shared) ===== */
.info-section-header {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  margin-bottom: 1.5rem;
}

.info-section-header h2 { margin-bottom: 0; }

.info-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: var(--radius);
  flex-shrink: 0;
}

.info-icon-blue  { background: #eff6ff; color: var(--color-primary); }
.info-icon-green { background: #f0fdf4; color: var(--color-success); }
.info-icon-purple { background: #f5f3ff; color: #7c3aed; }
.info-icon-amber { background: #fffbeb; color: #d97706; }

/* ===== Delisting: override old border-left style, use card grid ===== */
.delisting-section .container {
  border-left: none !important;
  padding-left: 1rem !important;
  max-width: 100% !important;
}

.delisting-section h2 { display: none; } /* replaced by info-section-header */
.delisting-section h2::before { display: none; }

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

.info-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-left: 3px solid var(--color-primary);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition);
}

.info-card:hover { box-shadow: var(--shadow-md); }

.info-card p {
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--color-text-secondary);
  margin: 0;
}

/* ===== HowTo: new icon-based steps ===== */
.step-number { display: none; } /* replaced by step-icon-wrap */

.step-icon-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.step-num-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  min-width: 24px;
  border-radius: 50%;
  background: var(--color-primary);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
}

.howto-step svg { color: var(--color-primary); }

/* ===== FAQ: new structure with toggle icons ===== */
.faq-question { align-items: center; }

.faq-q-text { flex: 1; }

.faq-toggle-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  min-width: 30px;
  border-radius: 50%;
  background: var(--color-bg-alt);
  color: var(--color-primary);
  transition: all var(--transition);
  flex-shrink: 0;
}

.faq-question::after { display: none; } /* replaced by faq-toggle-icon */

.icon-minus { display: none; }
.icon-plus  { display: block; }

.faq-item[open] .faq-toggle-icon {
  background: var(--color-primary);
  color: white;
}

.faq-item[open] .icon-minus { display: block; }
.faq-item[open] .icon-plus  { display: none; }

/* ===== Stock Actions (Watchlist + Alert buttons) ===== */
.stock-actions {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.6rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.btn-watchlist, .btn-alert {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  background: var(--color-bg-card);
  color: var(--color-text-secondary);
  font-family: var(--font-stack);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-watchlist:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
  background: var(--color-accent-light);
}

.btn-watchlist.is-watching {
  background: var(--color-accent-light);
  border-color: var(--color-accent);
  color: var(--color-accent-dark);
}

.btn-watchlist.is-watching svg { fill: var(--color-accent); }

.btn-alert:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-primary-light);
}

/* ===== Price Alert Modal ===== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  z-index: 500;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  backdrop-filter: blur(4px);
}

.modal-overlay.open { display: flex; }

.modal-box {
  background: var(--color-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 460px;
  animation: modalIn 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(-8px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--color-border);
}

.modal-header h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-text-secondary);
  line-height: 1;
  padding: 0.25rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.modal-close:hover { background: var(--color-bg-alt); color: var(--color-text); }

.modal-body { padding: 1.5rem; }

.modal-stock-name { margin-bottom: 1.25rem; font-size: 0.9rem; color: var(--color-text-secondary); }

.alert-form { display: flex; flex-direction: column; gap: 1rem; }

.form-group { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1rem; }

.form-group label { font-size: 0.85rem; font-weight: 600; color: var(--color-text); }

.form-required { color: var(--color-danger); }
.form-optional { color: var(--color-text-muted); font-weight: 400; font-size: 0.8em; }

.form-select, .form-input {
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-stack);
  font-size: 0.9rem;
  background: var(--color-bg-card);
  color: var(--color-text);
  transition: border-color var(--transition);
  width: 100%;
}

textarea.form-input { resize: vertical; min-height: 100px; }

.form-select:focus, .form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(78, 122, 110, 0.12);
}

.form-input-sm { padding: 0.4rem 0.65rem; font-size: 0.85rem; }

.form-group-checkbox {
  margin-top: 0.5rem;
}

.checkbox-label {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-size: 0.82rem;
  color: var(--color-text-secondary);
  line-height: 1.5;
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  margin-top: 0.2rem;
  width: 18px;
  height: 18px;
  accent-color: var(--color-primary);
  flex-shrink: 0;
}

.checkbox-label a { color: var(--color-primary); text-decoration: underline; }

.form-hint { font-size: 0.78rem; color: var(--color-text-muted); }

.form-actions { display: flex; gap: 0.5rem; margin-top: 0.5rem; }
.form-actions .btn { flex: 1; }

/* ===== Investor Tools Section ===== */
.investor-tools-section {
  padding: 2.5rem 0;
  background: var(--color-bg);
}

.investor-tools-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.investor-tools-header h2 { margin-bottom: 0; font-size: 1.4rem; }
.investor-tools-header svg { color: var(--color-primary); }

.investor-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.5rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: box-shadow var(--transition);
}

.tool-card:hover { box-shadow: var(--shadow-lg); }

.tool-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
}

.tool-icon-blue  { background: #eff6ff; color: var(--color-primary); }
.tool-icon-green { background: #f0fdf4; color: var(--color-success); }
.tool-icon-amber { background: #fffbeb; color: #d97706; }

.tool-card h3 { font-size: 1rem; margin: 0; }

.tool-desc { font-size: 0.85rem; color: var(--color-text-secondary); margin: 0; }

.yield-calc-inputs { display: flex; flex-direction: column; gap: 0.6rem; }

.calc-row { display: flex; flex-direction: column; gap: 0.2rem; }

.calc-row label { font-size: 0.78rem; font-weight: 500; color: var(--color-text-secondary); }

.calc-row .form-input-sm { width: 100%; }

.yield-result {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.25rem;
}

.yield-label { font-size: 0.8rem; color: var(--color-text-secondary); }

.yield-value {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1rem;
}

.yield-pct { font-size: 0.85rem; font-weight: 600; }

.yield-pos { color: var(--color-success); }
.yield-neg { color: var(--color-danger); }

/* Watchlist status inside tool card */
.watchlist-not-added { font-size: 0.85rem; color: var(--color-text-secondary); margin: 0; }
.watchlist-added { font-size: 0.85rem; color: var(--color-success); margin: 0; }

.btn-danger {
  background: #fef2f2;
  color: var(--color-danger);
  border: 1px solid #fca5a5;
}
.btn-danger:hover { background: #fee2e2; color: var(--color-danger); }

/* Alerts list inside tool card */
.watchlist-alerts-list { margin-top: 0.5rem; }

.alerts-title { font-size: 0.78rem; font-weight: 600; color: var(--color-text-secondary); margin-bottom: 0.4rem; }

.alerts-list { list-style: none; display: flex; flex-direction: column; gap: 0.35rem; }

.alert-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.6rem;
}

.alert-item.alert-triggered { opacity: 0.6; }

.alert-type-badge {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--color-primary);
}

.alert-target { font-family: var(--font-mono); font-weight: 600; }

.alert-note { color: var(--color-text-secondary); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.alert-badge-hit {
  font-size: 0.7rem;
  background: #fef9c3;
  color: #854d0e;
  padding: 0.1rem 0.4rem;
  border-radius: 99px;
  font-weight: 600;
}

.alert-remove {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-secondary);
  font-size: 1rem;
  padding: 0;
  line-height: 1;
  margin-left: auto;
}

.alert-remove:hover { color: var(--color-danger); }

/* ===== ISIN Code ===== */
.isin-code {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  background: var(--color-bg-alt);
  padding: 0.1rem 0.4rem;
  border-radius: var(--radius-sm);
}

/* ===== HV Box ===== */
.management-section {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.hv-box {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border: 1px solid #86efac;
  border-left: 4px solid var(--color-success);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
}

.hv-icon {
  color: var(--color-success);
  flex-shrink: 0;
  margin-top: 2px;
}

.hv-date {
  font-weight: 700;
  color: var(--color-success);
  font-size: 1rem;
  margin-left: 0.4rem;
}

.hv-ort {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  margin-top: 0.25rem;
}

/* ===== Management Grid ===== */
.mgmt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.mgmt-card {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1rem;
}

.mgmt-label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-secondary);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.mgmt-list {
  list-style: none;
  font-size: 0.85rem;
}

.mgmt-list li {
  padding: 0.2rem 0;
  border-bottom: 1px solid var(--color-border);
}

.mgmt-list li:last-child { border-bottom: none; }

/* ===== News Cards ===== */
.news-section {
  padding: 2.5rem 0;
  background: var(--color-bg-alt);
}

.news-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
  margin-bottom: 1rem;
}

.news-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-xs);
  transition: box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.news-card:hover { box-shadow: var(--shadow-md); }

.news-card-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.news-date {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  font-family: var(--font-mono);
}

.news-badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.news-badge-hv  { background: var(--color-primary-light, #E8F0ED); color: var(--color-primary-dark, #3D6358); }
.news-badge-div { background: #fef3c7; color: #92400e; }

.news-card-title {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.4;
  margin: 0;
}

.news-card-title a {
  color: var(--color-text);
}

.news-card-title a:hover { color: var(--color-primary); }

.news-card-excerpt {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
  margin: 0;
}

.news-source-note {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
}

@media (max-width: 768px) {
  .stock-actions { justify-content: flex-start; }
  .investor-tools-grid { grid-template-columns: 1fr; }
  .info-cards-grid { grid-template-columns: 1fr; }
  .news-cards { grid-template-columns: 1fr; }
  .mgmt-grid { grid-template-columns: 1fr; }
}

/* ===== Ratgeber & Glossar Pages ===== */

.ratgeber-hero {
  background: linear-gradient(170deg, #1A2E2B 0%, #243D39 40%, #2D4A44 100%);
  color: #fff !important;
  padding: 3rem 0 2.5rem;
}

.ratgeber-hero *, .ratgeber-hero h1, .ratgeber-hero a { color: inherit; }

.ratgeber-hero-inner {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2rem;
  align-items: start;
}

.ratgeber-label {
  display: inline-block;
  background: rgba(255,255,255,0.2);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}

.ratgeber-hero h1 {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: #fff;
}

.ratgeber-lead {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.85);
  line-height: 1.7;
}

.ratgeber-toc {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius);
  padding: 1.25rem;
  font-size: 0.88rem;
}

.ratgeber-toc strong {
  display: block;
  color: #fff;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.75rem;
}

.ratgeber-toc ol {
  padding-left: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.ratgeber-toc a {
  color: rgba(255,255,255,0.9);
  text-decoration: none;
  transition: color var(--transition);
}

.ratgeber-toc a:hover { color: #fff; text-decoration: underline; }

/* ===== Ratgeber Content — Expert-Style Typography ===== */
.ratgeber-body { background: var(--color-bg); }

.ratgeber-content {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--color-text);
}

.ratgeber-section {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 2rem 2.25rem;
  margin-bottom: 1.75rem;
  position: relative;
}

.ratgeber-section h2 {
  font-size: 1.35rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--color-primary-light);
  color: var(--color-text);
}

.ratgeber-section h3 {
  font-size: 1.05rem;
  margin: 1.5rem 0 0.75rem;
  color: var(--color-text);
  position: relative;
  padding-left: 0.75rem;
  border-left: 3px solid var(--color-accent);
}

.ratgeber-content p {
  margin-bottom: 1rem;
  max-width: 68ch;
  color: var(--color-text-secondary);
}

.ratgeber-content p strong {
  color: var(--color-text);
  font-weight: 600;
}

.ratgeber-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 1.25rem;
}

.ratgeber-list li {
  position: relative;
  padding: 0.6rem 0 0.6rem 1.75rem;
  border-bottom: 1px solid var(--color-border-light);
  color: var(--color-text-secondary);
  line-height: 1.7;
}

.ratgeber-list li:last-child { border-bottom: none; }

.ratgeber-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-primary);
}

.ratgeber-list li strong {
  color: var(--color-text);
}

.ratgeber-section-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  flex-shrink: 0;
}

/* Layout */
.ratgeber-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2.5rem;
  max-width: var(--max-width);
  margin: 2.5rem auto;
  padding: 0 1rem;
  align-items: start;
}

.ratgeber-article {
  min-width: 0;
}

.ratgeber-article h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  padding-top: 0.5rem;
  border-top: 3px solid var(--color-primary);
  scroll-margin-top: 80px;
}

.ratgeber-article h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.5rem 0 0.5rem;
  color: var(--color-text);
}

.ratgeber-article p {
  color: var(--color-text-secondary);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.ratgeber-article ul, .ratgeber-article ol {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.ratgeber-article li {
  color: var(--color-text-secondary);
  line-height: 1.8;
  margin-bottom: 0.3rem;
}

.ratgeber-article strong { color: var(--color-text); }

/* Info Boxes */
.ratgeber-box {
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
  font-size: 0.88rem;
  line-height: 1.7;
  position: relative;
}

.ratgeber-box--info, .ratgeber-box-info {
  background: var(--color-primary-light);
  border-left: 3px solid var(--color-primary);
  color: var(--color-dark);
}

.ratgeber-box--warning, .ratgeber-box-warn {
  background: var(--color-accent-light);
  border-left: 3px solid var(--color-accent);
  color: var(--color-dark);
}

.ratgeber-box--danger {
  background: rgba(192,57,43,0.06);
  border-left: 3px solid var(--color-danger);
  color: var(--color-dark);
}

.ratgeber-box--success {
  background: var(--color-primary-light);
  border-left: 3px solid var(--color-success);
  color: var(--color-dark);
}

.ratgeber-box-legal {
  background: rgba(192,57,43,0.04);
  border: 1px solid rgba(192,57,43,0.15);
  border-left: 3px solid var(--color-danger);
  color: var(--color-dark);
}

/* Compare Table */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.88rem;
}

.compare-table th {
  background: var(--color-primary);
  color: #fff;
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
}

.compare-table td {
  padding: 0.65rem 1rem;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  vertical-align: top;
}

.compare-table tr:hover td { background: var(--color-bg-alt); }

.compare-table tr:last-child td { border-bottom: none; }

.compare-table .compare-label {
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
}

/* Risk Grid */
.risk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.risk-card {
  border-radius: var(--radius);
  padding: 1.25rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  transition: all var(--transition);
}

.risk-card:hover { box-shadow: var(--shadow-md); }

.risk-card.risk-high, .risk-card--high {
  border-left: 4px solid var(--color-danger);
}

.risk-card.risk-medium, .risk-card--medium {
  border-left: 4px solid var(--color-accent);
}

.risk-card.risk-low, .risk-card--low {
  border-left: 4px solid var(--color-primary);
}

.risk-level {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  margin-bottom: 0.5rem;
}

.risk-high .risk-level { background: rgba(192,57,43,0.08); color: var(--color-danger); }
.risk-medium .risk-level { background: var(--color-accent-light); color: var(--color-accent-dark); }
.risk-low .risk-level { background: var(--color-primary-light); color: var(--color-primary); }

.risk-card h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: var(--color-text);
}

.risk-card p {
  font-size: 0.82rem;
  line-height: 1.6;
  margin: 0;
  color: var(--color-text-secondary);
}

/* Step Process */
.step-process {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 1.5rem 0;
}

.step-process-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  transition: all var(--transition);
}

.step-process-item:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow);
}

.step-process-num {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  background: var(--color-primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

.step-process-content h4 {
  font-weight: 600;
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
}

.step-process-content p {
  font-size: 0.85rem;
  margin: 0;
  color: var(--color-text-secondary);
}

/* Legal Box */
.legal-box {
  background: var(--color-surface, #FAFAF7);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
}

.legal-box h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-secondary);
  margin-bottom: 0.75rem;
}

.legal-box ul {
  padding-left: 1.25rem;
  margin: 0;
}

.legal-box li {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  margin-bottom: 0.3rem;
}

/* Sidebar */
.ratgeber-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  position: sticky;
  top: calc(var(--header-height) + 1rem);
}

.sidebar-widget {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.sidebar-widget h3 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-secondary);
  margin-bottom: 0.75rem;
}

.sidebar-widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-widget li {
  padding: 0.3rem 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 0.88rem;
}

.sidebar-widget li:last-child { border-bottom: none; }

.sidebar-widget a {
  color: var(--color-primary);
  text-decoration: none;
  font-size: 0.88rem;
}

.sidebar-widget a:hover { text-decoration: underline; }

.sidebar-widget--highlight {
  background: var(--color-primary-light);
  border-color: #bfdbfe;
}

.sidebar-widget--disclaimer {
  background: #fffbeb;
  border-color: #fde68a;
  font-size: 0.82rem;
}

.sidebar-widget--disclaimer p { color: #78350f; margin: 0; }

/* ===== Glossar-Specific ===== */

.glossar-layout {
  /* same ratgeber-layout grid, nothing extra needed */
}

.glossar-alpha-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.5rem;
}

.glossar-alpha-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.15);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: background var(--transition);
}

.glossar-alpha-nav a:hover {
  background: rgba(255,255,255,0.35);
}

.glossar-section {
  margin-bottom: 2rem;
  scroll-margin-top: 80px;
}

.glossar-letter {
  font-size: 2rem;
  font-weight: 800;
  color: var(--color-primary);
  border-bottom: 2px solid var(--color-primary-light);
  padding-bottom: 0.5rem;
  margin-bottom: 1.25rem;
  scroll-margin-top: 80px;
}

.glossar-term {
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
  background: var(--color-bg-card);
  transition: box-shadow var(--transition), border-color var(--transition);
  scroll-margin-top: 80px;
}

.glossar-term:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}

/* Glossar Einzelseiten → link each term to its own page */
.glossar-term h3 a {
  color: var(--color-text);
  text-decoration: none;
}
.glossar-term h3 a:hover { color: var(--color-primary); }

/* Glossar Term Hero (Einzelseite) */
.glossar-term-hero {
  background: linear-gradient(170deg, #1A2E2B 0%, #243D39 40%, #2D4A44 100%);
  padding: 2.5rem 0 2rem;
  color: #fff !important;
}

.glossar-term-hero * { color: inherit; }

.glossar-term-hero .glossar-term-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--color-accent) !important;
  color: var(--color-dark) !important;
  font-size: 1.5rem;
  font-weight: 800;
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
}

.glossar-term-hero h1 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.glossar-term-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.glossar-term-tags .glossar-tag {
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.8);
}

.glossar-definition {
  font-size: 1.05rem;
  line-height: 1.9;
  color: var(--color-text);
  max-width: 68ch;
}

/* Verwandte Begriffe Grid */
.glossar-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 0.75rem;
}

.glossar-related-card {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 1rem;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--color-text);
  transition: all var(--transition);
}

.glossar-related-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow);
}

.glossar-related-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  background: var(--color-primary-light);
  color: var(--color-primary);
  font-size: 0.85rem;
  font-weight: 800;
  border-radius: var(--radius-sm);
}

.glossar-related-card strong { font-size: 0.88rem; }
.glossar-related-card p { font-size: 0.78rem; color: var(--color-text-muted); margin: 0.2rem 0 0; line-height: 1.4; }

/* Prev / Next Navigation */
.glossar-term-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
}

.glossar-nav-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--color-text);
  transition: all var(--transition);
  max-width: 40%;
}

.glossar-nav-link:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow);
}

.glossar-nav-label {
  display: block;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.glossar-nav-link strong { font-size: 0.85rem; }

.glossar-nav-overview {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.glossar-alpha-nav-sidebar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.glossar-alpha-nav-sidebar a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
  text-decoration: none;
  transition: all var(--transition);
}

.glossar-alpha-nav-sidebar a.active,
.glossar-alpha-nav-sidebar a:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.glossar-term h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 0.5rem;
}

.glossar-term p {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}

.glossar-term a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.glossar-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.glossar-tag {
  display: inline-block;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.tag-cloud-item {
  display: inline-block;
  background: rgba(37,99,235,0.1);
  color: var(--color-primary);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  text-decoration: none;
  transition: background var(--transition);
}

.tag-cloud-item:hover {
  background: rgba(37,99,235,0.2);
}

/* Responsive */
@media (max-width: 900px) {
  .ratgeber-hero-inner,
  .ratgeber-layout {
    grid-template-columns: 1fr;
  }

  .ratgeber-sidebar {
    position: static;
    order: -1;
  }

  .ratgeber-toc {
    max-width: 100%;
  }
}

@media (max-width: 600px) {
  .ratgeber-hero h1 { font-size: 1.5rem; }
  .ratgeber-article h2 { font-size: 1.2rem; }
  .risk-grid { grid-template-columns: 1fr; }
  .compare-table { font-size: 0.8rem; }
}

/* =====================================================
   NAV DROPDOWN
   ===================================================== */
.nav-dropdown { position: relative; }
.nav-dropdown > a { cursor: pointer; }
/* ===== Dropdown — Dark Forest ===== */
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--color-dark-card);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
  min-width: 200px;
  list-style: none;
  padding: 0.35rem;
  z-index: 200;
}
.nav-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}
.nav-dropdown-menu li a {
  display: block;
  padding: 0.5rem 0.85rem;
  font-size: 0.85rem;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.nav-dropdown-menu li a:hover {
  background: rgba(255,255,255,0.08);
  color: var(--color-accent);
}
.nav-dropdown:hover .nav-dropdown-menu { display: block; }
.nav-dropdown > a { padding-bottom: 0.6rem; }

/* Trade Note */
.trade-note { font-size: .78rem; color: var(--color-text-muted); margin-top: .35rem; }

/* =====================================================
   NEW FEATURE CSS: Stock Detail Page Enhancements
   ===================================================== */

/* Inaktiv-Banner */
.inaktiv-banner {
  background: #fef2f2;
  border-left: 4px solid var(--color-danger, #C0392B);
  color: #b91c1c;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.9rem;
  margin-bottom: 0;
}
.inaktiv-banner svg { flex-shrink: 0; margin-top: 0.1rem; }

/* OTC-Score Badge */
.otc-score-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 700;
  cursor: default;
  letter-spacing: 0.02em;
}
.otc-score-high { background: rgba(2,137,1,0.08); color: var(--color-success); }
.otc-score-mid  { background: rgba(249,124,0,0.08); color: var(--color-warning); }
.otc-score-low  { background: rgba(208,13,0,0.08); color: var(--color-danger); }

.price-age-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  background: var(--color-surface);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
}

/* Spread Alarm */
.spread-alarm {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
  margin-top: 1rem;
}
.spread-alarm svg { flex-shrink: 0; margin-top: 0.1rem; }
.spread-alarm-warn {
  background: #fffbeb;
  border: 1px solid #fbbf24;
  color: #92400e;
}
.spread-alarm-high {
  background: #fef2f2;
  border: 1px solid #f87171;
  color: #b91c1c;
}

/* Chart Footer */
.chart-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.75rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.chart-note { font-size: 0.8rem; color: var(--color-text-muted); margin: 0; }
.chart-actions { display: flex; gap: 0.5rem; }
.btn-chart-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  background: var(--color-bg-card);
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--transition);
}
.btn-chart-action:hover { background: var(--color-primary-light); color: var(--color-primary); border-color: var(--color-primary); }

/* Sidebar Boxes (Dividendenrendite + KGV) */
.sidebar-box {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  margin-bottom: 1rem;
}
.sidebar-box h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 0.75rem 0;
  color: var(--color-text);
}

/* Dividendenrendite Box */
.div-rendite-box { border-top: 3px solid var(--color-success, #4E7A6E); }
.div-rendite-val {
  font-size: 2rem;
  font-weight: 800;
  color: #059669;
  line-height: 1;
  margin-bottom: 0.4rem;
}
.div-rendite-note { font-size: 0.82rem; color: var(--color-text-secondary); margin: 0 0 0.25rem; }
.div-rendite-hint { font-size: 0.75rem; color: var(--color-text-muted); margin: 0; font-style: italic; }

/* KGV-Rechner Box */
/* AI Research Box */
.ai-research-box {
  border-top: 3px solid var(--color-accent);
  background: var(--color-bg-card);
}

.ai-research-content {
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--color-text-secondary);
  margin-bottom: 0.75rem;
  max-height: 400px;
  overflow-y: auto;
}

.ai-research-content strong { color: var(--color-text); font-weight: 600; }

.ai-research-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  padding-top: 0.5rem;
  border-top: 1px solid var(--color-border-light);
}

.ai-research-disclaimer {
  font-size: 0.68rem;
  color: var(--color-text-muted);
  font-style: italic;
  margin-top: 0.5rem;
}

.kgv-box { border-top: 3px solid var(--color-primary); }
.kgv-hint { font-size: 0.8rem; color: var(--color-text-muted); margin: 0 0 0.5rem; }
.kgv-input-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}
.kgv-input {
  flex: 1;
  padding: 0.45rem 0.7rem;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  font-size: 0.9rem;
  min-width: 0;
}
.kgv-currency { font-size: 0.85rem; color: var(--color-text-muted); white-space: nowrap; }
.kgv-result {
  background: var(--color-bg-muted);
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  margin-bottom: 0.5rem;
}
.kgv-result strong { font-size: 1.1rem; color: var(--color-primary, var(--color-primary, #4E7A6E)); }

/* =====================================================
   NEW PAGES: Dividenden-Kalender, HV-Kalender,
   Branchenvergleich, Raritäten, Depot-Simulator,
   Newsletter
   ===================================================== */

/* Generic data table for new pages */
.data-page-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  background: var(--color-bg-card);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.07);
}
.data-page-table th {
  background: var(--color-bg-muted);
  padding: 0.7rem 0.9rem;
  text-align: left;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  border-bottom: 2px solid var(--color-border);
}
.data-page-table td {
  padding: 0.65rem 0.9rem;
  border-bottom: 1px solid var(--color-border);
  vertical-align: middle;
}
.data-page-table tr:last-child td { border-bottom: none; }
.data-page-table tr:hover td { background: var(--bg-hover, #f9fafb); }
.data-page-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.data-page-table .rendite-high { color: #059669; font-weight: 700; }
.data-page-table .rendite-mid  { color: #d97706; }
.data-page-table .rendite-low  { color: var(--color-text-muted); }

/* Depot Simulator */
.depot-container { max-width: 900px; margin: 2rem auto; padding: 0 1rem; }
.depot-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.depot-summary-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  text-align: center;
}
.depot-summary-card .depot-val {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-text);
  display: block;
}
.depot-summary-card .depot-label {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.depot-gain { color: #059669 !important; }
.depot-loss { color: var(--color-danger, #C0392B) !important; }
.depot-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.depot-table th {
  padding: 0.6rem 0.8rem;
  text-align: left;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-text-muted);
  text-transform: uppercase;
  border-bottom: 2px solid var(--color-border);
}
.depot-table td { padding: 0.65rem 0.8rem; border-bottom: 1px solid var(--color-border); }
.depot-empty { text-align: center; padding: 3rem 1rem; color: var(--color-text-muted); }
.depot-add-form {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}
.depot-form-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr auto;
  gap: 0.75rem;
  align-items: end;
}
@media (max-width: 600px) { .depot-form-row { grid-template-columns: 1fr 1fr; } }

/* Newsletter page */
.newsletter-container { max-width: 600px; margin: 3rem auto; padding: 0 1rem; text-align: center; }
.newsletter-form-box {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.07);
}
.newsletter-form-row { display: flex; gap: 0.75rem; margin: 1rem 0; }
.newsletter-form-row input { flex: 1; }
@media (max-width: 500px) { .newsletter-form-row { flex-direction: column; } }

/* Raritäten / Special cards */
.raritaeten-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}
.raritaet-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.15s, transform 0.15s;
  display: block;
}
.raritaet-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.1); transform: translateY(-2px); }
.raritaet-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.15rem 0.5rem;
  border-radius: 10px;
  margin-bottom: 0.5rem;
  background: var(--color-bg-muted);
  color: var(--color-text-muted);
}
.raritaet-card-name { font-size: 1rem; font-weight: 700; margin: 0 0 0.3rem; }
.raritaet-card-meta { font-size: 0.8rem; color: var(--color-text-muted); }
.raritaet-card-price { font-size: 1.1rem; font-weight: 700; color: var(--color-text); margin-top: 0.4rem; }

/* HV-Kalender */
.hv-list { list-style: none; padding: 0; margin: 0; }
.hv-list-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 0.9rem 1rem;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}
.hv-list-date {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-primary, var(--color-primary, #4E7A6E));
  white-space: nowrap;
  min-width: 90px;
}
.hv-list-name { font-weight: 600; color: var(--color-text); }
.hv-list-ort { font-size: 0.78rem; color: var(--color-text-muted); }
.hv-ical-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
  padding: 0.3rem 0.6rem;
  background: var(--color-bg-muted);
  border-radius: 6px;
  color: var(--color-text-secondary);
  text-decoration: none;
  border: 1px solid var(--color-border);
  white-space: nowrap;
}
.hv-ical-btn:hover { background: var(--color-primary-light, var(--color-primary-light, #E8F0ED)); color: var(--color-primary, var(--color-primary, #4E7A6E)); }
