/* ==========================================================================
   Nexio — Personalberatung für kaufmännische Fach- & Führungskräfte
   Design-Tokens orientiert an der draft-ai-Vorlage:
   warmes Off-White, warm near-black, neutrale dunkle Sektionen,
   Serif-Display (Newsreader) + Grotesk (Geist), Teal-Akzent.
   ========================================================================== */

:root {
  --canvas: #f4f3ef;
  --surface: #ffffff;
  --ink: #1a1916;
  --ink-muted: #6f6c66;
  --ink-faint: #a7a39c;
  --line: #e6e3dc;
  --line-strong: #d6d2c9;

  --night: #0a0a0c;
  --night-2: #161619;
  --night-line: #27272c;
  --night-ink: #f6f6f8;
  --night-muted: #8b8b94;

  --accent: #0abab5;
  --accent-bright: #5eeae5;
  --accent-deep: #0a8a86;

  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Newsreader", ui-serif, Georgia, serif;

  --radius-card: 1rem;
  --max-w: 80rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}
@media (min-width: 640px) {
  .container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

/* --- Typo-Bausteine ----------------------------------------------------- */

.font-display {
  font-family: var(--font-sans);
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 0.98;
}

.font-serif-display {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.01em;
}

.eyebrow {
  font-size: 0.6875rem;
  line-height: 1;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 600;
}

.section-title {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.12;
  margin-top: 1rem;
}

.section-lead {
  color: var(--ink-muted);
  font-size: 1.075rem;
  line-height: 1.7;
  max-width: 40rem;
  margin-top: 1.25rem;
}

/* --- Buttons ------------------------------------------------------------ */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  font-family: var(--font-sans);
  cursor: pointer;
  border: 1px solid transparent;
  transition: opacity 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn-primary {
  background: var(--ink);
  color: var(--canvas);
}
.btn-primary:hover {
  opacity: 0.88;
}

.btn-secondary {
  border-color: var(--line-strong);
  color: var(--ink);
  background: transparent;
}
.btn-secondary:hover {
  background: rgba(0, 0, 0, 0.04);
}

/* Varianten für dunkle Sektionen */
.btn-light {
  background: var(--night-ink);
  color: var(--night);
}
.btn-light:hover {
  opacity: 0.88;
}
.btn-ghost-dark {
  border-color: var(--night-line);
  color: var(--night-ink);
}
.btn-ghost-dark:hover {
  background: rgba(255, 255, 255, 0.06);
}

/* --- Header ------------------------------------------------------------- */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  transition: background-color 0.3s ease, box-shadow 0.3s ease,
    border-color 0.3s ease;
  background: transparent;
  border-bottom: 1px solid transparent;
}
.site-header.is-solid {
  background: rgba(244, 243, 239, 0.72);
  backdrop-filter: blur(16px) saturate(1.5);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  border-bottom-color: var(--line);
}
.site-header.is-open {
  background: var(--canvas);
}

.header-inner {
  display: flex;
  height: 3.5rem;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-size: 1.22rem;
  color: var(--ink);
}
.brand-mark {
  width: 22px;
  height: 22px;
  flex: none;
}

.nav-desktop {
  display: none;
  align-items: center;
  gap: 0.35rem;
}
.nav-desktop a {
  padding: 0.45rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-muted);
  transition: color 0.2s ease, background-color 0.2s ease;
}
.nav-desktop a:hover {
  color: var(--ink);
  background: rgba(0, 0, 0, 0.04);
}
.header-cta {
  display: none;
}
@media (min-width: 820px) {
  .nav-desktop,
  .header-cta {
    display: inline-flex;
  }
  .menu-toggle {
    display: none;
  }
}
.header-cta .btn {
  padding: 0.5rem 1.05rem;
}

.menu-toggle {
  appearance: none;
  background: none;
  border: 0;
  padding: 0.5rem;
  margin-right: -0.5rem;
  cursor: pointer;
  color: var(--ink);
}

.mobile-menu {
  position: fixed;
  inset: 3.5rem 0 auto 0;
  z-index: 49;
  background: var(--canvas);
  border-bottom: 1px solid var(--line);
  padding: 0.75rem 1.25rem 1.5rem;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.mobile-menu[data-open="true"] {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.mobile-menu a {
  display: block;
  padding: 0.8rem 0.25rem;
  font-size: 1.05rem;
  font-weight: 500;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}
.mobile-menu a:last-child {
  border-bottom: 0;
}

/* --- Hero --------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--canvas);
}
.hero-grain {
  position: absolute;
  inset: 0;
  opacity: 0.05;
  mix-blend-mode: overlay;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

/* Zentrierter Hero (reine Text-Variante) */
.hero-center {
  position: relative;
  z-index: 10;
  max-width: 48rem;
  margin: 0 auto;
  text-align: center;
  padding-top: 9.5rem;
  padding-bottom: 7rem;
}
@media (min-width: 1024px) {
  .hero-center {
    padding-top: 11rem;
    padding-bottom: 8.5rem;
  }
}
.hero h1 {
  font-size: clamp(2.9rem, 6.5vw, 4.6rem);
  color: var(--ink);
  margin-top: 1.25rem;
}
.hero-sub {
  margin: 1.75rem auto 0;
  max-width: 34rem;
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--ink-muted);
}
.hero-ctas {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

/* Hero-Einblendungen (Blur-to-Focus, Linear-Stil) */
@keyframes heroFocus {
  0% {
    opacity: 0;
    filter: blur(18px);
    transform: translateY(10px) scale(1.015);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: none;
  }
}
@keyframes heroRise {
  0% {
    opacity: 0;
    filter: blur(16px);
    transform: translateY(70px);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
  }
}
.hero-focus {
  opacity: 0;
  animation: heroFocus 1.15s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.hero-rise {
  opacity: 0;
  animation: heroRise 1.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@media (prefers-reduced-motion: reduce) {
  .hero-focus,
  .hero-rise {
    animation: none;
    opacity: 1;
    filter: none;
    transform: none;
  }
}

/* --- Scroll-Reveal ------------------------------------------------------ */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
      transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .reveal.in {
    opacity: 1;
    transform: none;
  }
}

/* --- Sektionen ---------------------------------------------------------- */

.section {
  padding: 6rem 0;
}
@media (min-width: 1024px) {
  .section {
    padding: 7.5rem 0;
  }
}

.section-dark {
  background: var(--night);
  color: var(--night-ink);
}
.section-dark .eyebrow {
  color: var(--night-muted);
}
.section-dark .section-lead {
  color: var(--night-muted);
}

/* Fachbereiche */
.fields-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  overflow: hidden;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 820px) {
  .fields-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.field-cell {
  background: var(--surface);
  padding: 1.6rem 1.5rem;
  min-height: 8.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.9rem;
  transition: background-color 0.2s ease;
}
.field-cell:hover {
  background: #fbfaf7;
}
.field-cell .num {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--ink-faint);
  font-weight: 600;
}
.field-cell h3 {
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.field-cell p {
  font-size: 0.8rem;
  color: var(--ink-muted);
  line-height: 1.55;
  margin-top: 0.3rem;
}

/* Leistungen */
.services-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 1.25rem;
}
@media (min-width: 820px) {
  .services-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.service-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.service-icon {
  width: 40px;
  height: 40px;
  border-radius: 0.6rem;
  display: grid;
  place-content: center;
  background: var(--canvas);
  border: 1px solid var(--line);
  color: var(--ink);
}
.service-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.service-card p {
  font-size: 0.9rem;
  color: var(--ink-muted);
  line-height: 1.65;
}
.service-card ul {
  margin: 0.25rem 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.service-card li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.85rem;
  color: var(--ink-muted);
}
.service-card li::before {
  content: "";
  flex: none;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--accent);
  margin-top: 0.5rem;
}

/* Prozess */
.process-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 2.5rem 1.5rem;
  counter-reset: step;
}
@media (min-width: 820px) {
  .process-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.process-step {
  position: relative;
  padding-top: 1.5rem;
  border-top: 1px solid var(--night-line);
}
.process-step .step-num {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--accent-bright);
  line-height: 1;
}
.process-step h3 {
  margin-top: 0.9rem;
  font-size: 1.02rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.process-step p {
  margin-top: 0.6rem;
  font-size: 0.87rem;
  line-height: 1.65;
  color: var(--night-muted);
}

/* Warum Nexio */
.why-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 2.5rem 3rem;
}
@media (min-width: 820px) {
  .why-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.why-item {
  padding-top: 1.4rem;
  border-top: 1px solid var(--line-strong);
}
.why-item h3 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.why-item p {
  margin-top: 0.6rem;
  font-size: 0.92rem;
  color: var(--ink-muted);
  line-height: 1.7;
  max-width: 32rem;
}

/* FAQ */
.faq-list {
  margin-top: 3rem;
  border-top: 1px solid var(--line-strong);
  max-width: 52rem;
}
.faq-item {
  border-bottom: 1px solid var(--line-strong);
}
.faq-item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.4rem 0;
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary::after {
  content: "+";
  flex: none;
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--ink-faint);
  transition: transform 0.25s ease;
  line-height: 1;
}
.faq-item[open] summary::after {
  transform: rotate(45deg);
}
.faq-item .faq-body {
  padding: 0 0 1.6rem;
  max-width: 44rem;
  color: var(--ink-muted);
  font-size: 0.95rem;
  line-height: 1.75;
}

/* Kontakt / CTA */
.cta-section {
  background: var(--night);
  color: var(--night-ink);
  position: relative;
  overflow: hidden;
}
.cta-dotgrid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
}
.cta-inner {
  position: relative;
  text-align: center;
  max-width: 46rem;
  margin: 0 auto;
  padding: 7rem 1.25rem;
}
.cta-inner h2 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  line-height: 1.1;
}
.cta-inner p {
  margin-top: 1.4rem;
  color: var(--night-muted);
  font-size: 1.05rem;
  line-height: 1.7;
}
.cta-actions {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}
/* Kontakt-Formular (dunkle Sektion) */
.contact-form {
  margin: 2.75rem auto 0;
  max-width: 34rem;
  text-align: left;
  display: grid;
  gap: 1.1rem;
}
.form-row {
  display: grid;
  gap: 1.1rem;
}
@media (min-width: 640px) {
  .form-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.contact-form label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--night-muted);
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  background: var(--night-2);
  border: 1px solid var(--night-line);
  border-radius: 0.5rem;
  padding: 0.7rem 0.9rem;
  color: var(--night-ink);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  line-height: 1.5;
  transition: border-color 0.2s ease;
}
.contact-form textarea {
  resize: vertical;
  min-height: 7rem;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(139, 139, 148, 0.6);
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.form-actions {
  margin-top: 0.4rem;
  text-align: center;
}
.form-hint {
  margin-top: 0.2rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--night-muted);
}

/* --- Footer ------------------------------------------------------------- */

.site-footer {
  background: var(--night);
  color: var(--night-muted);
  border-top: 1px solid var(--night-line);
  font-size: 0.85rem;
}
.footer-inner {
  padding: 3.5rem 0 2.5rem;
  display: grid;
  gap: 2.5rem;
}
@media (min-width: 820px) {
  .footer-inner {
    grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr));
  }
}
.footer-brand .brand {
  color: var(--night-ink);
}
.footer-brand p {
  margin-top: 1rem;
  max-width: 22rem;
  line-height: 1.65;
}
.footer-col h4 {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--night-muted);
  font-weight: 600;
  margin-bottom: 1rem;
}
.footer-col ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.footer-col a {
  color: var(--night-muted);
  transition: color 0.2s ease;
}
.footer-col a:hover {
  color: var(--night-ink);
}
.footer-bottom {
  border-top: 1px solid var(--night-line);
  padding: 1.5rem 0 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
}
.footer-bottom nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}
.footer-bottom a:hover {
  color: var(--night-ink);
}

/* --- Unterseiten / Rechtstexte ------------------------------------------ */

.subpage-main {
  padding: 8.5rem 0 6rem;
}
.subpage-main .eyebrow {
  margin-bottom: 0.75rem;
  display: block;
}
.subpage-main h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  line-height: 1.1;
}
.legal-updated {
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--ink-faint);
}

.legal-prose {
  margin-top: 3rem;
  max-width: 46rem;
  color: #3d3b36;
  font-size: 1.02rem;
  line-height: 1.72;
  overflow-wrap: break-word;
  hyphens: auto;
}
.legal-prose h2 {
  margin-top: 2.75rem;
  margin-bottom: 0.15rem;
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  scroll-margin-top: 5rem;
}
.legal-prose h3 {
  margin-top: 1.85rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
}
.legal-prose p {
  margin-top: 1rem;
}
.legal-prose ul {
  margin-top: 0.85rem;
  padding-left: 1.3rem;
}
.legal-prose li {
  margin-top: 0.4rem;
}
.legal-prose li::marker {
  color: var(--ink-faint);
}
.legal-prose strong {
  color: var(--ink);
  font-weight: 600;
}
.legal-prose a {
  color: var(--accent-deep);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.legal-prose a:hover {
  opacity: 0.8;
}
.legal-prose hr {
  margin: 2.5rem 0;
  border: 0;
  border-top: 1px solid var(--line);
}

/* Platzhalter-Markierung in Rechtstexten */
.placeholder {
  background: rgba(10, 186, 181, 0.1);
  border: 1px dashed rgba(10, 138, 134, 0.45);
  border-radius: 0.25rem;
  padding: 0 0.3rem;
  color: var(--accent-deep);
  font-style: normal;
}
.placeholder-hint {
  margin-top: 2rem;
  border: 1px dashed var(--line-strong);
  border-radius: 0.6rem;
  background: var(--surface);
  padding: 1rem 1.25rem;
  font-size: 0.85rem;
  color: var(--ink-muted);
}
