/*
Theme Name: Finanznavigator Marvin
Theme URI: https://finanznavigator-marvin.ch
Author: Finanznavigator Marvin
Description: Firmen-Theme für Finanznavigator Marvin – warme Creme-Töne, dunkles Marineblau und Goldakzente. Umsetzung des Designs aus dem Lovable-Projekt „Marvin's Financial Compass" als klassisches WordPress-Theme.
Version: 1.1
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: finanznavigator
Tags: business, one-column, custom-menu, custom-logo, featured-images
*/

/* ---------- Design tokens ---------- */
:root {
  --color-bg: #faf6f1;
  --color-ink: #08131c;
  --color-surface: #fffdfb;
  --color-surface-muted: #f3eee6;
  --color-warm: #cd9956;
  --color-conversion: #d72630;
  --color-dark: #061521;
  --color-dark-muted: #15232e;
  --color-dark-fg: #f8f5ef;
  --color-dark-border: #414f5a;
  --color-border: #ddd6cd;
  --color-muted-fg: #62748e;
  --color-primary: #0b1c2a;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-sans: "Manrope", "Segoe UI", sans-serif;
  --font-hand: "Caveat", cursive;
  --radius: 6px;
  --shadow-sm: 0 1px 2px rgba(8, 19, 28, 0.06);
  --shadow-md: 0 6px 16px -6px rgba(8, 19, 28, 0.18);
  --shadow-lg: 0 12px 28px -10px rgba(8, 19, 28, 0.28);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  margin: 0;
  color: var(--color-ink);
}

p { margin: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--color-warm); color: var(--color-ink); }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  border: 0;
}

/* ---------- Layout helpers ---------- */
.section-shell {
  width: 100%;
  max-width: 80rem;
  margin-inline: auto;
  padding-inline: 1.25rem;
}
@media (min-width: 640px) { .section-shell { padding-inline: 2rem; } }
@media (min-width: 1024px) { .section-shell { padding-inline: 4rem; } }

.eyebrow {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-warm);
}

.section-title {
  margin-top: 0.25rem;
  font-size: clamp(1.9rem, 4vw, 2.4rem);
}

.hand {
  font-family: var(--font-hand);
  color: var(--color-muted-fg);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border: 0;
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.btn .arrow { width: 0.9rem; height: 0.9rem; transition: transform 0.2s ease; }
.btn:hover .arrow { transform: translateX(3px); }

.btn-gold {
  background: var(--color-warm);
  color: var(--color-ink);
  box-shadow: var(--shadow-sm);
}
.btn-gold:hover { background: #c08a45; }

.btn-dark-outline {
  background: transparent;
  color: var(--color-dark-fg);
  border: 1px solid var(--color-dark-border);
}
.btn-dark-outline:hover { background: var(--color-dark-muted); }

.btn-light {
  background: var(--color-surface);
  color: var(--color-ink);
  box-shadow: var(--shadow-sm);
}
.btn-light:hover { background: var(--color-surface-muted); }

.btn-outline-warm {
  background: transparent;
  color: var(--color-warm);
  border: 1px solid var(--color-warm);
}
.btn-outline-warm:hover { background: rgba(205, 153, 86, 0.12); }

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 30;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg);
}
.site-header .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 3.5rem;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-ink);
}
.wordmark .mark {
  display: grid;
  place-items: center;
  width: 2rem; height: 2rem;
  border: 1px solid var(--color-warm);
  border-radius: 50%;
  color: var(--color-warm);
}
.wordmark .mark svg { width: 1rem; height: 1rem; }
.wordmark .name {
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0.02em;
}
.main-nav ul {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  list-style: none;
  margin: 0; padding: 0;
}
.main-nav a {
  display: block;
  padding: 0.5rem 0;
  border-bottom: 2px solid transparent;
  font-size: 0.78rem;
  font-weight: 700;
  transition: color 0.2s ease;
}
.main-nav a:hover { color: var(--color-warm); }
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a { border-bottom-color: var(--color-ink); }
.header-cta { display: inline-flex; }
.menu-toggle {
  display: none;
  width: 2.5rem; height: 2.5rem;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  color: var(--color-ink);
  cursor: pointer;
}
.menu-toggle svg { width: 1.25rem; height: 1.25rem; }
.mobile-nav { display: none; border-top: 1px solid var(--color-border); background: var(--color-bg); }
.mobile-nav.is-open { display: block; }
.mobile-nav ul { display: grid; gap: 0.25rem; margin: 0; padding: 0.75rem 0; list-style: none; }
.mobile-nav a { display: block; padding: 0.5rem 0; font-size: 0.9rem; font-weight: 700; }
@media (max-width: 767px) {
  .main-nav, .header-cta { display: none; }
  .menu-toggle { display: inline-flex; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--color-dark-fg);
}
.hero .hero-img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero .hero-scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to right, var(--color-dark) 0%, rgba(6, 21, 33, 0.82) 45%, rgba(6, 21, 33, 0.05) 100%);
}
.hero .grid {
  display: grid;
  align-items: center;
  min-height: 25rem;
}
@media (min-width: 768px) {
  .hero .grid { grid-template-columns: 1.04fr 0.96fr; min-height: 31rem; }
}
.hero-copy { padding: 2.5rem 0 1.75rem; }
.hero h1 {
  margin-top: 0.5rem;
  max-width: 44rem;
  color: var(--color-dark-fg);
  font-size: clamp(2.6rem, 6.5vw, 4.25rem);
  font-weight: 600;
}
.hero h1 .accent { color: var(--color-warm); }
.hero-sub {
  margin-top: 1rem;
  max-width: 29rem;
  font-size: 0.82rem;
  line-height: 1.6;
  color: rgba(248, 245, 239, 0.85);
}
.hero-actions { margin-top: 1.5rem; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.hero-trust {
  margin-top: 1.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  font-size: 0.78rem;
  color: rgba(248, 245, 239, 0.85);
}
.hero-trust span { display: flex; align-items: center; gap: 0.5rem; }
.hero-trust svg { width: 1.15rem; height: 1.15rem; color: var(--color-warm); }

.hero-visual { position: relative; height: 25rem; }
@media (min-width: 768px) { .hero-visual { height: 100%; min-height: 31rem; } }
.hero-visual .portrait {
  position: absolute;
  left: 50%; right: auto; bottom: 0;
  transform: translateX(-50%);
  height: 96%;
  width: auto;
  object-fit: contain;
  object-position: bottom;
}
@media (min-width: 768px) {
  .hero-visual .portrait { left: 8%; transform: none; height: 94%; }
}
.hero-hand {
  position: absolute;
  right: 0; top: 1.25rem;
  transform: rotate(-5deg);
  text-align: center;
  font-family: var(--font-hand);
  font-size: 1.35rem;
  line-height: 1.1;
  color: rgba(248, 245, 239, 0.88);
  text-shadow: 0 1px 8px rgba(6, 21, 33, 0.55);
}
.hero-quote {
  position: absolute;
  right: 0; bottom: 1rem;
  max-width: 11.5rem;
  transform: rotate(-1deg);
  border-radius: var(--radius);
  background: rgba(255, 253, 251, 0.92);
  padding: 0.7rem;
  color: var(--color-ink);
  box-shadow: var(--shadow-lg);
  font-size: 0.66rem;
  line-height: 1.45;
}
.hero-quote .sig {
  margin-top: 0.15rem;
  text-align: right;
  font-family: var(--font-hand);
  font-size: 1.15rem;
  color: var(--color-muted-fg);
}

/* ---------- Topic cards ---------- */
.topics { padding: 1.75rem 0; }
.topics-grid {
  margin-top: 1.25rem;
  display: grid;
  gap: 0.5rem;
}
@media (min-width: 640px) { .topics-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 768px) { .topics-grid { grid-template-columns: repeat(6, 1fr); } }
.topic-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 10rem;
  overflow: hidden;
  padding: 0.9rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.topic-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-warm);
  box-shadow: var(--shadow-md);
}
.topic-card .icon {
  width: 1.5rem; height: 1.5rem;
  color: var(--color-warm);
}
.topic-card h3 {
  margin-top: 0.75rem;
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1;
}
.topic-card p {
  margin-top: 0.5rem;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--color-muted-fg);
}
.topic-card .more {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.7rem;
  font-weight: 700;
  transition: color 0.25s ease;
}
.topic-card .more .arrow { width: 1rem; height: 1rem; flex-shrink: 0; }
.topic-card:hover .more { color: var(--color-warm); }

/* ---------- Path cards (image cards) ---------- */
.paths {
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface);
  padding: 1.75rem 0;
}
.paths-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}
.paths-head .hand { transform: rotate(-4deg); font-size: 1.2rem; line-height: 1.2; }
@media (max-width: 767px) { .paths-head .hand { display: none; } }
.paths-grid {
  margin-top: 1.25rem;
  display: grid;
  gap: 0.75rem;
}
@media (min-width: 768px) { .paths-grid { grid-template-columns: repeat(3, 1fr); } }
.path-card {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 14rem;
  overflow: hidden;
  border-radius: var(--radius);
  padding: 1.25rem;
  color: var(--color-dark-fg);
}
.path-card img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: left;
}
.path-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(6, 21, 33, 0.65);
}
.path-card .icon { width: 1.75rem; height: 1.75rem; color: var(--color-warm); }
.path-card h3 {
  margin-top: 0.75rem;
  color: var(--color-dark-fg);
  font-size: 1.5rem;
}
.path-card p {
  margin-top: 0.25rem;
  max-width: 24rem;
  font-size: 0.72rem;
  line-height: 1.35;
  color: rgba(248, 245, 239, 0.8);
}
.path-card .btn { margin-top: 1rem; width: fit-content; padding: 0.5rem 1.25rem; font-size: 0.72rem; }

/* ---------- Guide section ---------- */
.guide { padding: 1.5rem 0; }
.guide .grid {
  display: grid;
  align-items: center;
  gap: 2rem;
}
@media (min-width: 768px) { .guide .grid { grid-template-columns: 1fr 0.85fr; } }
.guide .copy { border-left: 4px solid var(--color-warm); padding-left: 1.5rem; }
.guide h2 { margin-top: 0.5rem; font-size: clamp(2rem, 4vw, 2.5rem); }
.guide .lead {
  margin-top: 0.75rem;
  max-width: 36rem;
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--color-muted-fg);
}
.guide .bottom {
  margin-top: 1rem;
  display: grid;
  gap: 1rem;
}
@media (min-width: 640px) { .guide .bottom { grid-template-columns: 1fr auto; align-items: end; } }
.checklist { display: grid; gap: 0.4rem; font-size: 0.8rem; }
.checklist li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  list-style: none;
}
.checklist { margin: 0; padding: 0; }
.checklist svg { width: 1rem; height: 1rem; color: var(--color-warm); flex-shrink: 0; }
.guide-img { max-width: 22rem; margin: 0 auto; width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-lg); }

/* ---------- About section ---------- */
.about {
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
  padding: 1.5rem 0;
}
.about .grid { display: grid; gap: 1.75rem; align-items: start; }
@media (min-width: 768px) { .about .grid { grid-template-columns: 1fr 0.48fr; } }
.about .body { margin-top: 0.75rem; display: grid; gap: 0.6rem; }
.about .body p { font-size: 0.84rem; line-height: 1.55; color: var(--color-muted-fg); }
.about .btn { margin-top: 1rem; padding: 0.5rem 1.25rem; font-size: 0.72rem; }
.about .values {
  display: grid;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--color-bg);
  font-size: 0.84rem;
}
.about .values span { display: flex; align-items: center; gap: 0.75rem; }
.about .values svg { width: 1.25rem; height: 1.25rem; color: var(--color-warm); flex-shrink: 0; }

/* ---------- CTA band ---------- */
.cta-band { padding: 1.5rem 0 2rem; }
.cta-band .inner {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--radius);
  padding: 1.75rem 1.75rem;
  color: var(--color-dark-fg);
}
@media (min-width: 640px) { .cta-band .inner { padding: 1.75rem 2.5rem; } }
.cta-band .inner img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%; height: 100%;
  object-fit: cover;
}
.cta-band .inner::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(6, 21, 33, 0.75);
}
.cta-band .cols {
  display: grid;
  align-items: center;
  gap: 1.5rem;
}
@media (min-width: 768px) { .cta-band .cols { grid-template-columns: 1fr auto 1fr; } }
.cta-band h2 {
  margin-top: 0.5rem;
  color: var(--color-dark-fg);
  font-size: clamp(1.8rem, 3.5vw, 2.2rem);
}
.cta-band .sub {
  margin-top: 0.5rem;
  max-width: 28rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: rgba(248, 245, 239, 0.75);
}
.cta-band .hand {
  color: var(--color-dark-fg);
  transform: rotate(-5deg);
  font-size: 1.3rem;
  line-height: 1.15;
  justify-self: end;
}
@media (max-width: 767px) { .cta-band .hand { display: none; } }

/* ---------- Content pages (page.php / single.php) ---------- */
.page-hero {
  border-bottom: 1px solid var(--color-border);
  background: var(--color-dark);
  color: var(--color-dark-fg);
  padding: 3rem 0;
}
.page-hero h1 {
  color: var(--color-dark-fg);
  font-size: clamp(2.2rem, 5vw, 3rem);
}
.page-hero .eyebrow { color: var(--color-warm); }
.page-hero p {
  margin-top: 0.75rem;
  max-width: 42rem;
  font-size: 0.9rem;
  color: rgba(248, 245, 239, 0.8);
}
.page-content { padding: 2.5rem 0 3.5rem; }
.page-content .narrow { max-width: 44rem; margin-inline: auto; }
.page-content .entry-content {
  margin-top: 1.5rem;
  font-size: 1rem;
  line-height: 1.7;
}
.page-content .entry-content h2 { margin: 2rem 0 0.75rem; font-size: 1.8rem; }
.page-content .entry-content h3 { margin: 1.5rem 0 0.5rem; font-size: 1.35rem; }
.page-content .entry-content p { margin: 0 0 1rem; }
.page-content .entry-content ul, .page-content .entry-content ol { margin: 0 0 1rem; padding-left: 1.4rem; }
.page-content .entry-content a { color: var(--color-warm); font-weight: 600; }
.page-content .entry-content img { border-radius: var(--radius); }
.wp-block-image img { border-radius: var(--radius); }

/* ---------- Blog index ---------- */
.blog-list { padding: 2.5rem 0 3.5rem; }
.blog-grid {
  margin-top: 1.5rem;
  display: grid;
  gap: 1rem;
}
@media (min-width: 640px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .blog-grid { grid-template-columns: repeat(3, 1fr); } }
.post-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.post-card:hover { transform: translateY(-4px); border-color: var(--color-warm); box-shadow: var(--shadow-md); }
.post-card .thumb { aspect-ratio: 2 / 1; object-fit: cover; width: 100%; }
.post-card .body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; flex: 1; }
.post-card .date { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-warm); }
.post-card h2 { margin-top: 0.4rem; font-size: 1.25rem; }
.post-card h2 a:hover { color: var(--color-warm); }
.post-card .excerpt { margin-top: 0.4rem; font-size: 0.8rem; color: var(--color-muted-fg); }
.post-card .more { margin-top: auto; padding-top: 0.75rem; font-size: 0.72rem; font-weight: 700; }

/* ---------- Single post ---------- */
.single-article { padding: 2.5rem 0 3.5rem; }
.single-article .narrow { max-width: 44rem; margin-inline: auto; }
.single-article .date { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-warm); }
.single-article .featured { margin: 1.5rem 0; border-radius: var(--radius); }
.single-article .entry-content { margin-top: 1.25rem; line-height: 1.7; }
.single-article .entry-content p { margin: 0 0 1rem; }
.single-article .entry-content h2 { margin: 2rem 0 0.75rem; font-size: 1.8rem; }
.single-article .entry-content h3 { margin: 1.5rem 0 0.5rem; font-size: 1.35rem; }
.single-article .entry-content a { color: var(--color-warm); font-weight: 600; }
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-muted-fg);
}
.back-link:hover { color: var(--color-warm); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--color-border);
  background: var(--color-bg);
  padding: 1.25rem 0 0.75rem;
}
.footer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.75rem;
  font-size: 0.72rem;
  color: var(--color-muted-fg);
}
.footer-tagline {
  max-width: 15rem;
  border-left: 1px solid var(--color-border);
  padding-left: 1.25rem;
}
.footer-nav { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.footer-nav ul { display: flex; flex-wrap: wrap; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.footer-legal { display: flex; flex-wrap: wrap; align-items: center; gap: 1.25rem; }
.footer-legal ul { display: flex; flex-wrap: wrap; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.footer-mail {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-ink);
}
.footer-mail svg { width: 1rem; height: 1rem; }
.footer-copy { margin-top: 0.5rem; font-size: 0.65rem; color: var(--color-muted-fg); }
@media (max-width: 767px) {
  .footer-tagline, .footer-mail { border-left: 0; padding-left: 0; }
}

/* ---------- Motion ---------- */
@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) {
  .animate-rise { animation: rise 0.65s ease-out both; }
}
