/* Swiss Style Design System - SafeRoute */

/* 1. Variables & Design Tokens */
:root {
    /* Colors - Minimalist & Strategic */
    --color-bg: #FFFFFF;
    --color-text-primary: #191615;
    /* SafeRoute Darkest */
    --color-text-secondary: #595959;
    --color-accent: #e69d3d;
    /* SafeRoute Orange - Use Sparingly */
    --color-grid-line: #E5E5E5;
    --color-white: #ffffff;
    /* On-dark variants – used in dark-background sections & footer */
    --color-on-dark: rgba(255, 255, 255, 0.75);
    --color-on-dark-muted: rgba(255, 255, 255, 0.60);
    --color-border-dark: rgba(255, 255, 255, 0.15);
    --color-accent-dark: #d4882a;  /* Btn hover – accent darkened ~15% */
    --color-bg-subtle: #f5f5f5;    /* Light grey for interactive hover states */

    /* Typography - Inter (Modern, Neutral, Swiss) */
    --font-family-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    /* Scale (Major Third approx) */
    --font-size-base: 1rem;
    /* 16px */
    --font-size-sm: 0.8rem;
    /* 12.8px */
    --font-size-md: 1.25rem;
    /* 20px */
    --font-size-lg: 1.563rem;
    /* 25px */
    --font-size-xl: 1.953rem;
    /* 31px */
    --font-size-2xl: 2.441rem;
    /* 39px */
    --font-size-3xl: 3.052rem;
    /* 48px */
    --font-size-4xl: 3.815rem;
    /* 61px */
    --font-size-5xl: 4.768rem;
    /* 76px */

    /* Spacing - Modular Scale */
    --space-unit: 8px;
    --space-xs: calc(1 * var(--space-unit));
    /* 8px */
    --space-sm: calc(2 * var(--space-unit));
    /* 16px */
    --space-md: calc(4 * var(--space-unit));
    /* 32px */
    --space-lg: calc(8 * var(--space-unit));
    /* 64px */
    --space-xl: calc(20 * var(--space-unit));
    /* 160px - Increased for better separation */
    --space-2xl: calc(30 * var(--space-unit));
    /* 240px - Increased */

    /* Grid */
    --grid-columns: 12;
    --grid-gap: var(--space-sm);
    --max-width: 1440px;

    /* Motion — exponential easing for natural deceleration */
    --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
    --ease-out-expo:  cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    font-family: var(--font-family-sans);
    line-height: 1.4;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 3. Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Inter Tight', var(--font-family-sans);
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-sm);
}

h1 {
    font-size: clamp(2.5rem, 8vw, var(--font-size-5xl));
}

h2 {
    font-size: clamp(2rem, 6vw, var(--font-size-3xl));
}

h3 {
    font-size: clamp(1.5rem, 5vw, var(--font-size-xl));
}

h4 {
    font-size: var(--font-size-lg);
}

p {
    font-size: var(--font-size-base);
    margin-bottom: var(--space-md);
    max-width: 60ch;
    /* Optimal line length */
}

a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid var(--color-text-primary);
    transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

a:hover {
    background-color: var(--color-text-primary);
    color: var(--color-bg);
}

.brand {
    text-transform: uppercase;
    font-weight: 700;
}

.dot {
    color: var(--color-accent);
}

/* 4. Layout Utility Classes */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.grid {
    display: grid;
    grid-template-columns: repeat(var(--grid-columns), 1fr);
    gap: var(--grid-gap);
}

@media (max-width: 768px) {
    .grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
}

.section {
    padding: var(--space-xl) 0;
    border-top: 1px solid var(--color-grid-line);
}

@media (max-width: 768px) {
    .section {
        padding: var(--space-lg) 0;
    }
}

.section:first-of-type {
    border-top: none;
}

/* Background Utilities */
.bg-light {
    background-color: var(--color-bg-subtle);
    border-top: none;
    /* Seamless flow */
    border-bottom: 1px solid var(--color-grid-line);
}

.bg-dark {
    background-color: var(--color-text-primary);
    color: var(--color-bg);
    border-top: none;
}

.bg-dark h2,
.bg-dark p,
.bg-dark li,
.bg-dark a {
    color: var(--color-bg);
}

.bg-dark .hero-subtitle,
.economy-visual .hero-subtitle {
    color: var(--color-accent);
}

/* Header Navigation Mobile */
@media (max-width: 768px) {
    .header {
        padding: var(--space-xs) 0;
    }

    .nav-grid {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .logo img {
        height: 32px !important;
    }

    .logo-text {
        font-size: 1.1rem;
    }

    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 1001;
        padding: 0;
    }

    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--color-text-primary);
        transition: transform 0.3s ease, background-color 0.3s ease;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--color-bg);
        flex-direction: column;
        padding: var(--space-xl) var(--space-md);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
        display: flex !important;
        /* Force flex but move off-screen */
    }

    .nav-links.is-open {
        right: 0;
    }

    .nav-links li {
        margin-bottom: var(--space-md);
        opacity: 0;
        transform: translateX(20px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .nav-links.is-open li {
        opacity: 1;
        transform: translateX(0);
    }

    /* Menu Toggle States */
    .mobile-menu-toggle.is-active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .mobile-menu-toggle.is-active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.is-active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }

    .nav-item:last-child {
        margin-top: var(--space-lg);
    }
}

/* 4.1 Grid Spans & Responsive Layout */
.hero-content {
    grid-column: 1 / 8;
}

.hero-title {
    font-size: clamp(2rem, 10vw, 3.5rem);
    line-height: 1.1;
    margin-bottom: var(--space-sm);
}

.header-text-content {
    grid-column: 1 / 6;
}

.journey-header-content {
    grid-column: 1 / 6;
}

.service-lead-content {
    grid-column: 1 / 6;
}

@media (max-width: 992px) {

    .hero-content,
    .header-text-content,
    .journey-header-content,
    .service-lead-content {
        grid-column: 1 / -1;
    }
}

/* Sec 02: Data List (Interactive Accordion) */
.data-list {
    list-style: none;
    border-top: 2px solid var(--color-text-primary);
}

.data-list-item {
    border-bottom: 2px solid var(--color-text-primary);
    transition: background-color 0.3s ease;
    width: 100%;
    outline: none;
}

.data-list-item:hover {
    background-color: var(--color-bg-subtle);
}

.data-list summary {
    padding: var(--space-md) 0;
    font-size: var(--font-size-md);
    font-weight: 700;
    display: flex;
    align-items: center;
    cursor: pointer;
    list-style: none;
    user-select: none;
    transition: padding-left 0.3s ease;
}

.data-list summary::-webkit-details-marker {
    display: none;
}

.data-list summary::before {
    content: "→";
    font-family: monospace;
    font-size: 1.2rem;
    color: var(--color-accent);
    margin-right: var(--space-md);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
}

.data-list-item:hover summary {
    padding-left: var(--space-sm);
}

.data-list-item:hover summary::before {
    transform: translateX(5px);
}

.data-list-item.is-open summary::before {
    transform: rotate(90deg);
}

/* Sec 09: FAQ (Premium Animation) */
.faq-item {
    margin-bottom: var(--space-sm);
    border-bottom: 1px solid var(--color-grid-line);
    padding-bottom: var(--space-sm);
    overflow: hidden;
    list-style: none;
    outline: none;
}

.faq-item summary {
    font-weight: 600;
    cursor: pointer;
    padding: var(--space-xs) 0;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}

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

.faq-item summary::after {
    content: '+';
    font-family: monospace;
    color: var(--color-accent);
    font-size: 1.3rem;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-item.is-open summary::after {
    transform: rotate(45deg);
}

/* Shared FAQ-Style Animation */
.expand-wrapper {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-item.is-open .expand-wrapper,
.data-list-item.is-open .expand-wrapper {
    grid-template-rows: 1fr;
}

.expand-content-inner {
    overflow: hidden;
}

.expand-content-inner p {
    padding-bottom: var(--space-sm);
    color: var(--color-text-secondary);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.data-list-item .expand-content-inner p {
    padding-left: calc(1.2rem + var(--space-md));
    padding-bottom: var(--space-md);
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.6;
}

.faq-item.is-open .expand-content-inner p,
.data-list-item.is-open .expand-content-inner p {
    opacity: 1;
    transform: translateY(0);
}

/* Sec 03: Problem Compare */
.problem-compare {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.compare-card {
    border: 1px solid var(--color-text-primary);
    padding: var(--space-md) var(--space-lg);
    background: var(--color-bg);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.compare-card-left {
    background: var(--color-bg-subtle);
}

.compare-card-right {
    background: linear-gradient(180deg, #ffffff 0%, #fcfaf7 100%);
    border-left: 4px solid var(--color-accent);
    box-shadow: 0 10px 26px rgba(25, 22, 21, 0.08);
}

.compare-card:hover {
    transform: translateY(-4px);
    border-color: var(--color-accent);
}

.compare-card-left:hover {
    box-shadow: 0 8px 20px rgba(25, 22, 21, 0.08);
}

.compare-card-right:hover {
    box-shadow: 0 14px 28px rgba(25, 22, 21, 0.12);
}

.compare-title {
    margin-bottom: var(--space-sm);
    letter-spacing: 0.04em;
    font-size: 1.9rem;
}

.compare-card-left .compare-title {
    color: var(--color-text-secondary);
}

.compare-card-right .compare-title {
    color: var(--color-text-primary);
}

.compare-item {
    border-top: 1px solid rgba(25, 22, 21, 0.25);
    padding-top: var(--space-sm);
    margin-top: var(--space-sm);
}

.compare-item h5 {
    font-size: 1.65rem;
    line-height: 1.2;
    margin-bottom: var(--space-xs);
}

.compare-item p {
    font-size: 1rem;
    line-height: 1.55;
    margin-bottom: 0;
    max-width: 60ch;
}

@media (max-width: 768px) {
    .problem-compare {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }

    .compare-card {
        padding: var(--space-sm) var(--space-md);
    }

    .compare-card-right {
        border-left: 1px solid var(--color-text-primary);
        border-top: 4px solid var(--color-accent);
        box-shadow: none;
    }

    .compare-card:hover {
        transform: none;
    }

    .compare-title {
        font-size: 1.3rem;
    }

    .compare-item h5 {
        font-size: 1.35rem;
    }

    #problem .btn {
        width: 100%;
        text-align: center;
    }
}

/* 15. Kundenreise (Journey Chart) */
@media (max-width: 768px) {
    .journey-line-svg text {
        display: none;
    }

    .x-axis-content span {
        font-size: 0.72rem;
        letter-spacing: 0.04em;
    }

    .phase-label {
        display: none;
    }
}

/* Sec 04: Bento Grid (Why Us) */
.bento-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: var(--space-md);
}

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

.bento-item {
    background-color: var(--color-text-primary);
    color: white;
    padding: var(--space-lg);
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 250px;
    transition: transform 0.3s ease;
}

.bento-item:hover {
    transform: scale(1.02);
}

.bento-icon {
    font-size: 2rem;
    color: var(--color-accent);
    margin-bottom: var(--space-md);
}

.bento-title {
    font-size: var(--font-size-lg);
    font-weight: 700;
    margin-bottom: var(--space-xs);
}

.bento-text {
    font-size: 0.95rem;
    opacity: 0.9;
    line-height: 1.4;
}

/* Sec 05: Role Grid (Unsere Rolle) */
.role-enclosure {
    grid-column: 1 / -1;
    margin-top: var(--space-lg);
    border: 1px solid var(--color-accent);
    padding: var(--space-lg);
    position: relative;
    background: rgba(230, 157, 61, 0.02);
    /* Very subtle accent tint */
}

.enclosure-label {
    position: absolute;
    top: -12px;
    left: var(--space-lg);
    background: white;
    padding: 0 10px;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--color-accent);
    letter-spacing: 0.1em;
}

@media (max-width: 768px) {
    .role-enclosure {
        margin-top: 0;
        padding: var(--space-md);
    }

    .enclosure-label {
        left: var(--space-sm);
        font-size: 0.65rem;
    }
}

.role-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
}

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

.role-card {
    border: 1px solid var(--color-grid-line);
    padding: var(--space-lg);
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
    background: white;
}

.role-card:hover {
    border-color: var(--color-accent);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.role-header {
    margin-bottom: var(--space-md);
    position: relative;
}

.role-num {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-accent);
    opacity: 0.2;
    line-height: 1;
    display: block;
}

.role-card h3 {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: var(--color-accent);
    margin-top: -1.5rem;
    /* Overlap with number */
    position: relative;
    z-index: 2;
}

.role-card h4 {
    font-size: 1.5rem;
    margin-bottom: var(--space-sm);
    line-height: 1.2;
}

.role-card p {
    font-size: 1rem;
    color: var(--color-text-secondary);
    margin-bottom: 0;
}

/* Sec 06: Vertical Timeline (Wie wir arbeiten) */
#prozess .services-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.process-step-premium {
    padding-left: var(--space-lg);
    border-left: 2px solid #eee;
    transition: border-color 0.3s ease;
    margin-bottom: var(--space-lg);
}

.process-step-premium:hover {
    border-left-color: var(--color-accent);
}

.process-step-premium .mono {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--color-accent);
    display: block;
    margin-bottom: var(--space-xs);
}

.process-step-premium h4 {
    font-size: 1.25rem;
    margin-bottom: var(--space-xs);
}

.process-step-premium p {
    font-size: 0.95rem;
    opacity: 0.8;
    margin-bottom: 0;
}

/* Header and Component Responsiveness already handled in specific sections above */

/* 5. Components */

/* Video Wrapper */
.video-wrapper {
    margin-top: var(--space-lg);
    border: 1px solid var(--color-text-primary);
    width: 100%;
    max-width: 800px;
    align-self: start;
}

.hero-video {
    margin-top: var(--space-xl);
}

@media (max-width: 768px) {
    .video-wrapper {
        margin-top: var(--space-md);
    }

    .hero-video {
        margin-top: var(--space-md);
    }
}

/* Checklist */
.checklist li {
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: flex-start;
}

.checklist li span {
    color: var(--color-accent);
    margin-right: var(--space-sm);
    font-weight: 700;
}

/* Sec 09: FAQ (Premium Animation) */
.faq-item {
    margin-bottom: var(--space-sm);
    border-bottom: 1px solid var(--color-grid-line);
    padding-bottom: var(--space-sm);
    overflow: hidden;
    /* Added to contain animation */
}

.faq-item summary {
    font-weight: 600;
    cursor: pointer;
    padding: var(--space-xs) 0;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}

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

.faq-item summary::after {
    content: '+';
    font-family: monospace;
    color: var(--color-accent);
    font-size: 1.3rem;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-item[open] summary::after {
    transform: rotate(45deg);
}

.faq-content {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-item.is-open .faq-content {
    grid-template-rows: 1fr;
}

.faq-content-inner {
    overflow: hidden;
}

.faq-content p {
    margin-top: var(--space-sm);
    padding-bottom: var(--space-sm);
    color: var(--color-text-secondary);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 768px) {
    .faq-item summary {
        font-size: 1rem;
    }
}

.faq-item.is-open .faq-content p {
    opacity: 1;
    transform: translateY(0);
}

/* Header */
.header {
    padding: var(--space-md) 0;
    border-bottom: 2px solid var(--color-text-primary);
    position: sticky;
    top: 0;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    z-index: 100;
}

.nav-grid {
    align-items: center;
}

/* Mobile toggle is hidden by default and only shown on small screens */
.mobile-menu-toggle {
    display: none;
}

/* 4. Buttons & Interactions */
.btn {
    display: inline-block;
    padding: var(--space-sm) var(--space-lg);
    background-color: var(--color-accent);
    color: var(--color-bg);
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: var(--color-accent-dark);
    /* Darker shade of accent */
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--color-text-primary);
    color: var(--color-text-primary);
}

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

.btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

/* Service & Benefit Cards Hover */
.service-item {
    border-top: 2px solid var(--color-text-primary);
    padding-top: var(--space-sm);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.service-item:hover {
    border-color: var(--color-accent);
    transform: translateY(-4px);
}

/* Link Hover - Use Accent Color but ensure readability on dark */
a {
    transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

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

/* Specific Footer Link Hover for better contrast */
.footer a:hover {
    color: var(--color-accent);
    background-color: transparent;
    /* Remove background on hover for text links */
    border-bottom-color: var(--color-accent);
}

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Immediately show all content for users who prefer reduced motion or have JS disabled */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* Logo */
.logo {
    display: inline-flex;
    /* Better formatting */
    align-items: center;
    border-bottom: none;
    padding: 8px;
    /* Add padding for the hover box */
    border-radius: 4px;
    transition: background-color 0.3s ease;
    text-decoration: none;
    /* Ensure no underline */
    background: transparent;
    border: none;
    box-shadow: none;
    gap: 10px;
}

.logo img,
.logo-img {
    height: 32px;
    width: auto;
    display: block;
    transition: filter 0.3s ease;
}

/* Header nav uses slightly larger logo */
.header .logo-img {
    height: 48px;
}

.logo-text {
    font-weight: 700;
    font-size: 1.25rem;
    margin-left: 10px;
    letter-spacing: -0.03em;
    color: var(--color-text-primary);
    transition: color 0.3s ease;
    border: none;
    text-decoration: none;
}

.logo-divider {
    display: none;
    width: 92px;
    height: 4px;
    background: #d8d8d8;
    border-radius: 2px;
    opacity: 0.6;
    margin-left: 10px;
}

/* Logo Hover Effect: Black Background, White Logo & Text */
.logo:hover {
    background-color: var(--color-text-primary);
    transform: translateY(-1px);
}

.logo:hover img {
    filter: brightness(0) invert(1);
}

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

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

.logo::before,
.logo::after,
.logo-text::before,
.logo-text::after {
    content: none !important;
    display: none !important;
}

.logo,
.logo * {
    border: none !important;
    box-shadow: none !important;
    text-decoration: none !important;
    background-image: none !important;
}

@media (max-width: 768px) {
    .logo-divider {
        display: none;
    }
}

/* Nav Links */
.nav-links {
    grid-column: 5 / -1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    /* Vertically align items */
    gap: var(--space-md);
    list-style: none;
}

/* Footer Link Hover - Simple & Clean */
.footer a {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 2px;
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
    color: rgba(255, 255, 255, 0.8);
    /* Highly visible light grey default */
}

.footer a:hover {
    color: var(--color-white) !important;
    /* Force White */
    border-bottom-color: var(--color-accent) !important;
    /* Accent Underline */
    opacity: 1;
}

.nav-item a {
    font-size: var(--font-size-sm);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
    border-bottom: none;
    padding: 8px 12px;
    border-radius: 4px;
}

.nav-item a:hover {
    background-color: var(--color-bg-subtle);
    /* Light grey background for nav items */
    color: var(--color-text-primary);
}

/* Exception for Button in Nav */
.nav-item .btn {
    color: white !important;
    background-color: var(--color-accent) !important;
}

.nav-item .btn:hover {
    background-color: var(--color-accent-dark) !important;
    color: white !important;
    transform: translateY(-2px);
}

/* Hero Section */
.hero {
    padding: var(--space-2xl) 0;
}

.hero-content {
    grid-column: 1 / 8;
}

.hero-subtitle {
    font-family: 'Inter Tight', var(--font-family-sans);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    margin-bottom: var(--space-sm);
    display: block;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* Services Section */
.services-title {
    grid-column: 1 / 4;
}

#loesung .services-title {
    grid-column: 1 / 6;
    max-width: 760px;
}

.services-list {
    grid-column: 5 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
}

.service-item {
    border-top: 1px solid var(--color-text-primary);
    padding-top: var(--space-sm);
}

.service-number {
    font-family: monospace;
    color: var(--color-accent);
    margin-bottom: var(--space-xs);
    display: block;
}

/* Einstieg Deliverables aligned with "Fuer Wen" style */
.deliverables-list {
    margin-top: 2px;
}

#angebot .deliverables-list .data-list-item {
    border-bottom-width: 1px;
}

#angebot .deliverables-list summary {
    font-size: 1.2rem;
    font-weight: 600;
    padding: var(--space-xs) 0;
    line-height: 1.32;
}

#angebot .deliverables-list .expand-content-inner p {
    padding-left: calc(1.2rem + var(--space-sm));
    padding-bottom: var(--space-xs);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Nach dem Einstieg: static list */
.post-entry-list {
    list-style: none;
    border-top: 1px solid var(--color-text-primary);
}

.post-entry-list li {
    border-bottom: 1px solid rgba(25, 22, 21, 0.22);
    padding: var(--space-sm) 0;
}

.post-entry-list li strong {
    display: block;
    font-size: 1.18rem;
    line-height: 1.3;
    margin-bottom: var(--space-xs);
    font-weight: 600;
}

.post-entry-list li p {
    margin-bottom: 0;
    font-size: 0.98rem;
    line-height: 1.55;
    color: var(--color-text-secondary);
    max-width: 66ch;
}

/* Contact Section Visual */
#kontakt .contact-visual {
    border-radius: 4px;
    overflow: hidden;
    min-height: 460px;
    max-height: 560px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#kontakt .contact-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center top;
}

/* Personal Section */
#ansprechpartner .personal-visual {
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--color-grid-line);
    background: #efefef;
}

#ansprechpartner .personal-image {
    width: 100%;
    height: auto;
    display: block;
}

#ansprechpartner .personal-image-fallback {
    min-height: 420px;
    padding: var(--space-md);
    background: linear-gradient(135deg, #ececec, #f8f8f8);
    color: var(--color-text-primary);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: var(--space-xs);
    text-align: center;
}

#ansprechpartner .personal-image-fallback strong {
    font-size: var(--font-size-lg);
}

#ansprechpartner .personal-content p {
    max-width: 64ch;
    margin-bottom: var(--space-md);
}

#ansprechpartner .personal-qualifications {
    margin: var(--space-sm) 0 var(--space-sm);
    padding: var(--space-sm) 0;
    border-top: 1px solid var(--color-text-primary);
    border-bottom: none;
}

#ansprechpartner .personal-qualifications h3 {
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    margin-bottom: var(--space-sm);
}

#ansprechpartner .qualification-list {
    list-style: none;
    display: grid;
    gap: var(--space-xs);
    margin-bottom: 0;
}

#ansprechpartner .qualification-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 0;
}

#ansprechpartner .qualification-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--color-accent);
    font-weight: 700;
}

#ansprechpartner .personal-contact {
    margin-top: var(--space-xs);
    padding-top: var(--space-sm);
    border-top: 1px solid var(--color-text-primary);
}

#ansprechpartner .personal-contact h3 {
    margin-bottom: var(--space-sm);
}

#ansprechpartner .personal-contact p {
    margin-bottom: var(--space-sm);
}

/* CMS Blog Section */
.blog-cms-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-sm);
}

#insights .blog-cms-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
}

.blog-cms-card {
    background: #ffffff;
    border: 1px solid rgba(25, 22, 21, 0.18);
    border-top: 2px solid var(--color-text-primary);
    padding: var(--space-md);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.blog-cms-card:hover {
    transform: translateY(-3px);
    border-top-color: var(--color-accent);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

.blog-cms-meta {
    display: block;
    font-size: 0.75rem;
    color: var(--color-accent);
    letter-spacing: 0.04em;
    margin-bottom: var(--space-xs);
}

.blog-cms-card h3 {
    font-size: 1.45rem;
    line-height: 1.25;
    margin-bottom: var(--space-xs);
}

.blog-cms-card p {
    margin-bottom: var(--space-sm);
    max-width: 100%;
    color: var(--color-text-secondary);
    font-size: 0.95rem;
}

.blog-cms-link {
    border-bottom: 1px solid var(--color-text-primary);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding-bottom: 2px;
    background: transparent;
    color: var(--color-text-primary);
    display: inline-block;
}

.blog-cms-link:hover {
    border-bottom-color: var(--color-accent);
    background: transparent !important;
    color: var(--color-accent) !important;
    transform: none;
}

/* Blog Detail Page */
.blog-page-shell {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--space-md);
    align-items: start;
    margin-top: var(--space-md);
}

.blog-detail-card {
    background: #ffffff;
    border: 1px solid rgba(25, 22, 21, 0.15);
    border-top: 3px solid var(--color-accent);
    padding: var(--space-lg);
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.blog-detail-card.is-switching {
    will-change: opacity, transform; /* applied only while animating */
    opacity: 0.45;
    transform: translateY(4px);
}

.blog-detail-title {
    font-size: clamp(1.8rem, 3.6vw, 2.8rem);
    line-height: 1.12;
    margin-bottom: var(--space-sm);
}

.blog-detail-excerpt {
    font-size: 1.16rem;
    color: var(--color-text-secondary);
    margin-bottom: var(--space-md);
    max-width: 100%;
}

.blog-markdown h2,
.blog-markdown h3,
.blog-markdown h4 {
    margin-top: var(--space-md);
    margin-bottom: var(--space-xs);
}

.blog-markdown p {
    max-width: 72ch;
    margin-bottom: var(--space-sm);
    line-height: 1.7;
}

.blog-markdown a {
    color: var(--color-text-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
    border-bottom: none;
    background: transparent;
}

.blog-markdown a:hover {
    color: var(--color-accent) !important;
    background: transparent !important;
}

.blog-markdown ul {
    margin: 0 0 var(--space-sm) 1.2rem;
}

.blog-markdown li {
    margin-bottom: 6px;
    line-height: 1.6;
}

.blog-sidebar-card {
    background: #ffffff;
    border: 1px solid rgba(25, 22, 21, 0.15);
    padding: var(--space-md);
    position: sticky;
    top: 120px;
}

.blog-sidebar-card h3 {
    font-size: 1.2rem;
    margin-bottom: var(--space-sm);
}

.blog-mini-list {
    list-style: none;
    padding: 0;
}

.blog-mini-list li {
    border-top: 1px solid rgba(25, 22, 21, 0.2);
    padding: 0;
}

.blog-mini-list a {
    border-bottom: none;
    display: block;
    padding: 10px 12px;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.blog-mini-list a:hover {
    background: rgba(230, 157, 61, 0.1);
    color: var(--color-text-primary);
}

.blog-mini-list li.is-active a {
    background: rgba(230, 157, 61, 0.12);
    border-left: 3px solid var(--color-accent);
    padding-left: 9px;
}

.blog-mini-list li.is-active strong {
    color: var(--color-accent);
}

.blog-mini-list strong {
    display: block;
    font-size: 1rem;
    line-height: 1.3;
}

.blog-mini-list span {
    display: block;
    margin-top: 4px;
    color: var(--color-text-secondary);
    font-size: 0.85rem;
}

/* Values Section */
.values-grid {
    align-items: start;
}

.value-card {
    grid-column: span 4;
    background-color: var(--color-bg);
    padding: var(--space-md);
    border: 1px solid var(--color-grid-line);
}

.value-card h3 {
    margin-top: var(--space-sm);
}

/* Footer */
.footer {
    background-color: var(--color-text-primary);
    color: var(--color-bg);
    padding: var(--space-xl) 0;
    border-top: 1px solid var(--color-border-dark);
}

/* Footer Link Conflict Removed: Using styles from lines 354+ */

/* Utilities */
.text-right {
    text-align: right;
}

.uppercase {
    text-transform: uppercase;
}

.mono {
    font-family: monospace;
}

.d-block {
    display: block;
}

/* 6. Responsive Design */
@media (max-width: 1024px) {
    :root {
        --font-size-5xl: 3.5rem;
        --font-size-3xl: 2.5rem;
    }
}

@media (max-width: 1180px) {
    .section {
        padding: var(--space-lg) 0;
    }

    .grid {
        gap: var(--space-md);
    }

    h1,
    h2,
    h3,
    h4 {
        overflow-wrap: anywhere;
        hyphens: auto;
    }

    .nav-links {
        gap: var(--space-sm);
    }

    .nav-item a {
        font-size: 0.78rem;
        padding: 6px 8px;
    }

    .nav-item .btn {
        padding: 7px 12px !important;
        font-size: 0.82rem !important;
    }

    .hero-content,
    .header-text-content,
    .journey-header-content,
    .service-lead-content,
    .services-title,
    .services-list {
        grid-column: 1 / -1 !important;
    }

    .hero-video {
        grid-column: 1 / -1 !important;
        margin-top: var(--space-sm);
        max-width: 100%;
    }

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

    #zielgruppe > div,
    #zielgruppe .grid>div,
    #angebot .grid>div,
    #mehrwert-final .grid>div,
    #faq .grid>div,
    #weltweit .grid>div,
    #impact .grid>div,
    #ansprechpartner .personal-grid>div,
    #insights .grid>div {
        grid-column: 1 / -1 !important;
    }

    #mehrwert-final .services-list {
        grid-template-columns: 1fr !important;
    }

    .problem-compare {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }

    .pareto-container {
        grid-template-columns: 1fr;
        gap: var(--space-md);
        padding: var(--space-md);
    }

    #zusammenarbeit .service-lead-content h2 {
        font-size: clamp(1.9rem, 4.4vw, 2.7rem);
        line-height: 1.12;
        max-width: 100%;
    }

    .blog-page-shell {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }

    .blog-sidebar-card {
        position: static;
        top: auto;
    }

    #zusammenarbeit .service-lead-content,
    #zusammenarbeit .grid>div:last-child {
        grid-column: 1 / -1 !important;
    }

    #zusammenarbeit .service-lead-content h2 {
        font-size: clamp(2rem, 4.6vw, 2.8rem);
        line-height: 1.12;
    }

    #zusammenarbeit .service-lead-content {
        margin-bottom: var(--space-sm);
    }

    /* Portrait image: cap height when stacked full-width on tablet */
    #ansprechpartner .personal-visual {
        max-height: 520px;
        overflow: hidden;
    }

    #ansprechpartner .personal-image {
        width: 100%;
        height: 520px;
        object-fit: cover;
        object-position: center 10%;
    }
}

@media (max-width: 1024px) {
    /* Prevent fixed off-screen nav panel from creating horizontal scroll */
    html {
        overflow-x: hidden;
    }

    .header {
        padding: var(--space-xs) 0;
    }

    .nav-grid {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .logo img {
        height: 32px !important;
    }

    .logo-text {
        font-size: 1.1rem;
    }

    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 1001;
        padding: 0;
    }

    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--color-text-primary);
        transition: transform 0.3s ease, background-color 0.3s ease;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--color-bg);
        flex-direction: column;
        padding: var(--space-xl) var(--space-md);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
        display: flex !important;
        justify-content: flex-start;
        align-items: flex-start;
    }

    .nav-links.is-open {
        right: 0;
    }

    .nav-links li {
        margin-bottom: var(--space-md);
        opacity: 0;
        transform: translateX(20px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .nav-links.is-open li {
        opacity: 1;
        transform: translateX(0);
    }

    .mobile-menu-toggle.is-active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .mobile-menu-toggle.is-active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.is-active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
}

@media (max-width: 768px) {
    :root {
        --grid-columns: 4;
        --space-lg: calc(5 * var(--space-unit));
        --space-xl: calc(8 * var(--space-unit));
        --space-2xl: calc(10 * var(--space-unit));
        --font-size-5xl: 2.5rem;
    }

    .grid {
        grid-template-columns: repeat(var(--grid-columns), 1fr);
        gap: var(--space-md);
    }

    .section {
        padding: var(--space-md) 0;
    }

    /* Sections Mobile */
    .hero-content {
        grid-column: 1 / -1;
    }

    .services-title {
        grid-column: 1 / -1;
        margin-bottom: var(--space-md);
    }

    .services-list {
        grid-column: 1 / -1;
        grid-template-columns: 1fr;
    }

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

    .value-card {
        grid-column: span 4;
        margin-bottom: var(--space-sm);
    }

    /* Footer Mobile */
    .footer .grid>div {
        grid-column: 1 / -1 !important;
        margin-bottom: var(--space-md);
    }

    /* Comparison Section Mobile */
    #mehrwert .grid>div {
        grid-column: 1 / -1 !important;
        padding-left: 0 !important;
        border-left: none !important;
        margin-bottom: var(--space-md);
    }

    /* Pricing Section Mobile */
    #angebot .grid>div {
        grid-column: 1 / -1 !important;
        margin-bottom: var(--space-md);
    }

    #angebot .deliverables-list summary {
        font-size: 1rem;
    }

    #angebot .deliverables-list .expand-content-inner p {
        padding-left: calc(1rem + var(--space-sm));
        font-size: 0.95rem;
    }

    .post-entry-list li strong {
        font-size: 1.05rem;
    }

    .post-entry-list li p {
        font-size: 0.95rem;
    }

    /* Fuer Wen Mobile */
    #zielgruppe > div,
    #zielgruppe .grid>div {
        grid-column: 1 / -1 !important;
    }

    #zielgruppe .header-text-content h2 {
        font-size: clamp(2rem, 10vw, 2.8rem);
        line-height: 1.12;
        max-width: 100%;
    }

    #zielgruppe .header-text-content p {
        max-width: 100%;
    }

    #zielgruppe .data-list summary {
        font-size: 1.1rem;
        line-height: 1.35;
    }

    /* Hide journey only on mobile (keep desktop) */
    #kundenreise {
        display: none !important;
    }

    /* Prozess (Ihr Weg) Mobile */
    #prozess .services-title {
        margin-bottom: var(--space-sm);
    }

    #prozess .services-list {
        grid-column: 1 / -1 !important;
        gap: var(--space-sm);
    }

    #prozess .services-title .btn {
        width: 100%;
        text-align: center;
    }

    .process-step-premium {
        padding-left: var(--space-md);
        margin-bottom: var(--space-md);
        border-left-width: 3px;
    }

    .process-step-premium h4 {
        font-size: 1.125rem;
        line-height: 1.3;
    }

    .process-step-premium p {
        font-size: 0.95rem;
        line-height: 1.55;
    }

    /* Nach dem Einstieg Mobile */
    #zusammenarbeit .grid>div {
        grid-column: 1 / -1 !important;
    }

    #zusammenarbeit .service-lead-content {
        margin-bottom: var(--space-sm);
    }

    #zusammenarbeit .service-lead-content div[style*="font-size: var(--font-size-2xl)"] {
        font-size: 2rem !important;
    }

    #zusammenarbeit ul li {
        margin-bottom: var(--space-sm) !important;
        padding-bottom: var(--space-sm) !important;
        line-height: 1.5;
    }

    /* Ihr Mehrwert Mobile */
    #mehrwert-final .services-title {
        margin-bottom: var(--space-sm);
    }

    #mehrwert-final .services-title .btn {
        width: 100%;
        text-align: center;
    }

    #mehrwert-final .services-list {
        grid-column: 1 / -1 !important;
        grid-template-columns: 1fr !important;
        gap: var(--space-sm) !important;
    }

    #mehrwert-final .service-item {
        padding-top: var(--space-xs);
    }

    #mehrwert-final .service-item h3 {
        font-size: 1.4rem;
        line-height: 1.2;
    }

    /* Globale Dimension Mobile */
    #weltweit .grid>div {
        grid-column: 1 / -1 !important;
    }

    #weltweit h2 {
        font-size: clamp(1.8rem, 9vw, 2.5rem) !important;
        line-height: 1.15;
    }

    #weltweit p {
        max-width: 100%;
    }

    /* Kontext Schweiz Mobile */
    #impact .grid>div {
        grid-column: 1 / -1 !important;
    }

    #impact div[style*="background: rgba(255,255,255,0.05)"] {
        padding: var(--space-md) !important;
        margin-bottom: var(--space-sm);
    }

    #impact strong {
        font-size: clamp(2rem, 12vw, 2.8rem) !important;
        line-height: 1.05 !important;
    }

    #impact .grid[style*="opacity: 0.6"] .mono {
        font-size: 0.72rem !important;
        line-height: 1.6;
        word-break: break-word;
    }

    #impact .btn {
        width: 100%;
        text-align: center;
    }

    /* Contact Section Mobile */
    #kontakt .grid>div {
        grid-column: 1 / -1 !important;
        margin-bottom: var(--space-md);
    }

    #kontakt .contact-visual {
        min-height: 0;
        max-height: none;
    }

    #kontakt .contact-image {
        height: auto;
        object-fit: contain;
    }

    /* Personal Section Mobile */
    #ansprechpartner .personal-grid>div {
        grid-column: 1 / -1 !important;
    }

    #ansprechpartner .personal-content {
        order: 1;
    }

    #ansprechpartner .personal-visual {
        order: 2;
        max-height: 420px;
    }

    #ansprechpartner .personal-image {
        height: 420px;
    }

    #ansprechpartner .personal-image-fallback {
        min-height: 280px;
    }

    #ansprechpartner .btn {
        width: 100%;
        text-align: center;
    }

    #insights .grid>div {
        grid-column: 1 / -1 !important;
    }

    .blog-cms-grid {
        grid-template-columns: 1fr;
    }

    .blog-cms-card h3 {
        font-size: 1.1rem;
    }

    .blog-page-shell {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }

    .blog-detail-card {
        padding: var(--space-md);
    }

    .blog-sidebar-card {
        position: static;
        top: auto;
    }

    .video-wrapper {
        grid-column: 1 / -1 !important;
        margin-top: var(--space-md);
    }
}

/* Sec 04: Pareto Diagram (Strategic Leverage Schematic) */
.pareto-container {
    grid-column: 1 / -1;
    margin-top: var(--space-lg);
    background: #ffffff;
    border: 1px solid var(--color-grid-line);
    padding: var(--space-xl);
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: var(--space-xl);
    align-items: center;
}

.leverage-visual {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-lg) 0;
    gap: var(--space-md);
}

.leverage-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 140px;
}

.leverage-box-input {
    width: 40px;
    height: 40px;
    background: var(--color-accent);
    border: 2px solid var(--color-text-primary);
    box-shadow: 4px 4px 0 rgba(230, 157, 61, 0.2);
    margin-bottom: var(--space-sm);
}

.leverage-box-output {
    width: 100px;
    height: 100px;
    background: #f8f8f8;
    border: 2px solid var(--color-text-primary);
    box-shadow: 8px 8px 0 var(--color-accent);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.leverage-box-output strong {
    font-size: 2.2rem;
    color: var(--color-text-primary);
}

.leverage-arrow {
    flex: 1;
    height: 2px;
    background: var(--color-grid-line);
    position: relative;
}

.leverage-arrow::after {
    content: '';
    position: absolute;
    right: -2px;
    top: 50%;
    transform: translateY(-50%);
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 8px solid var(--color-grid-line);
}

.leverage-label-main {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--color-text-primary);
}

.leverage-label-sub {
    font-size: 0.65rem;
    opacity: 0.6;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 4px;
}

.pareto-text-content p {
    font-size: 1.15rem;
    line-height: 1.6;
}

@media (max-width: 900px) {
    .pareto-container {
        grid-template-columns: 1fr;
    }

    .leverage-visual {
        flex-direction: column;
        gap: var(--space-xl);
    }

    .leverage-arrow {
        width: 2px;
        height: 40px;
        background: #ddd;
    }

    .leverage-arrow::after {
        right: 50%;
        bottom: -2px;
        top: auto;
        transform: translateX(50%);
        border-left: 6px solid transparent;
        border-right: 6px solid transparent;
        border-top: 8px solid #ddd;
    }
}

/* --- BRAND TYPOGRAPHY --- */
.brand {
    font-weight: 700;
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

.dot {
    color: var(--color-accent);
}

/* --- PHASE 33: ECONOMY VISUAL --- */
/* --- PHASE 33: ECONOMY VISUAL (REFINED FLAG STYLE) --- */
.economy-visual {
    background-color: var(--color-text-primary);
    color: var(--color-bg);
    overflow: hidden;
    padding-bottom: var(--space-3xl);
}

.economy-chart {
    position: relative;
    padding: var(--space-3xl) 0 60px;
    /* Space for the bottom border and some breathing room */
    min-height: 600px;
    margin-top: var(--space-xl);
}

/* Y-Axis Markers (Coordinate System) */
.economy-y-axis {
    position: absolute;
    left: 0;
    right: 0;
    top: var(--space-3xl);
    /* Match chart padding */
    height: 500px;
    /* Fixed height for the coordinate system */
    display: flex;
    flex-direction: column-reverse;
    justify-content: space-between;
    pointer-events: none;
    z-index: 1;
}

.economy-chart-area {
    position: absolute;
    left: 0;
    right: 0;
    top: var(--space-3xl);
    /* Match chart top padding */
    height: 500px;
    /* Increased height for better vertical resolution */
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    padding: 0 40px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    z-index: 2;
}

.y-marker {
    width: 100%;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    position: relative;
}

.y-marker::after {
    content: attr(data-value);
    position: absolute;
    right: 0;
    top: -10px;
    font-size: 0.7rem;
    font-family: var(--font-mono);
    color: rgba(255, 255, 255, 0.4);
}

.economy-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    height: 100%;
    /* Fill the 400px chart area */
    justify-content: flex-end;
}

.flagpole {
    width: 8px;
    background: linear-gradient(90deg, #666, #333, #666);
    position: relative;
    border-radius: 4px 4px 0 0;
    /* Ensure it starts exactly at the baseline */
    margin: 0;
    transform-origin: bottom;
}

/* MATHEMATICAL PRECISION BASED ON SCALE */
.flagpole.usa {
    height: 100%;
}

/* ~28T */
.flagpole.china {
    height: 63.2%;
}

/* ~17.7T */
.flagpole.cyber {
    height: 38%;
}

/* ~10.6T (Adjusted to clear 8T line visually) */

.flagpole::after {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 12px;
    background: #888;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.flag-container {
    position: absolute;
    top: 20px;
    left: 6px;
    width: 120px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.3);
}

.flag-container.usa {
    background: #fff url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 741 390"><path d="M0 0h741v390H0z" fill="%23fff"/><path d="M0 0h741v30H0zm0 60h741v30H0zm0 60h741v30H0zm0 60h741v30H0zm0 60h741v30H0zm0 60h741v30H0zm0 60h741v30H0z" fill="%23b22234"/><path d="M0 0h296.4v210H0z" fill="%233c3b6e"/></svg>') no-repeat center/cover;
}

.flag-container.china {
    background: #ee1c25 url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 900 600"><path fill="%23ee1c25" d="M0 0h900v600H0z"/><path fill="%23ffff00" d="M150 150l-12 37 31-23H131l31 23zm90-100l-4 13 11-8h-11l11 8zm30 40l-4 13 11-8h-11l11 8zm0 60l-4 13 11-8H259l11 8zm-30 40l-4 13 11-8h-11l11 8z"/></svg>') no-repeat center/cover;
}

.flag-container.cyber {
    background: #000 url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" shape-rendering="crispEdges"><path fill="white" d="M6 1h4v1H6zM4 2h8v1H4zM3 3h10v1H3zM2 4h12v5h-2v1h-8V9H2V4zm3 2v2h2V6H5zm6 0v2h2V6h-2zM7 9h2v1H7V9z"/><path fill="white" d="M1 11h2v1H1zM2 12h2v1H2zM3 13h2v1H3zM13 11h2v1h-2zM12 12h2v1h-2zM11 13h2v1h-2zM1 15h2v1H1zM2 14h2v1H2zM13 15h2v1h-2zM12 14h2v1h-2z"/></svg>') no-repeat center/60%;
    border: 1px solid var(--color-accent);
}

.economy-callout {
    position: absolute;
    bottom: calc(100% + 5px);
    /* Tighter proximity to the tip */
    left: 50%;
    transform: translateX(-50%);
    background: white;
    color: black;
    padding: 10px 15px;
    min-width: 150px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    z-index: 25;
    border-radius: 2px;
    white-space: nowrap;
}

.economy-callout::before {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 10px solid white;
}

.economy-callout b {
    display: block;
    text-transform: uppercase;
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    font-weight: 800;
}

.economy-callout span {
    display: block;
    font-size: 1.1rem;
    font-weight: 500;
    margin-top: 2px;
    color: #000;
}

@media (max-width: 768px) {
    .economy-chart {
        padding-top: var(--space-lg);
        min-height: auto;
        margin-top: var(--space-md);
    }

    .economy-y-axis {
        display: none;
    }

    .economy-chart-area {
        position: relative;
        top: 0;
        height: auto;
        min-height: 0;
        flex-direction: column;
        align-items: flex-start;
        padding: var(--space-sm) var(--space-sm) var(--space-lg);
        border-bottom: none;
        border-left: 2px solid rgba(255, 255, 255, 0.2);
        gap: var(--space-lg);
    }

    .economy-item {
        width: 100%;
        height: auto;
        align-items: flex-start;
        padding-bottom: var(--space-xs);
    }

    .economy-item:last-child {
        padding-bottom: var(--space-md);
    }

    .flagpole {
        width: 100%;
        /* Responsive horizontal poles */
        height: 8px !important;
        border-radius: 0 3px 3px 0;
        transform-origin: left;
    }

    .flagpole.usa {
        width: 99%;
    }

    .flagpole.china {
        width: 63%;
    }

    .flagpole.cyber {
        width: 34%;
    }

    .flag-container {
        display: none;
    }

    .economy-callout {
        position: static;
        transform: none;
        bottom: auto;
        left: auto;
        margin-bottom: var(--space-xs);
        min-width: 0;
        width: auto;
        white-space: normal;
        background: transparent;
        color: var(--color-bg);
        box-shadow: none;
        border: none;
        padding: 0;
        display: flex;
        flex-direction: column;
        gap: 2px;
    }

    .economy-callout::before {
        display: none;
    }

    .economy-callout b {
        font-size: 0.78rem;
        letter-spacing: 0.05em;
        color: var(--color-accent);
        white-space: nowrap;
    }

    .economy-callout span {
        display: block;
        font-size: 1rem;
        font-weight: 700;
        color: var(--color-bg);
        line-height: 1.25;
        min-height: 1.25em;
    }
}

/* 15. Kundenreise (Journey Chart) */
.journey-section {
    background-color: var(--color-bg);
    border-top: 1px solid var(--color-grid-line);
    padding: var(--space-xl) 0;
}

.journey-chart-container {
    margin-top: var(--space-lg);
    grid-column: 7 / -1;
    /* Align to the right half on desktop */
    width: 100%;
}

.chart-frame-wrapper {
    position: relative;
    width: 100%;
}

.chart-frame {
    display: grid;
    grid-template-columns: 80px 1fr;
    /* Space for Y-axis labels */
    gap: var(--space-sm);
    position: relative;
    width: 100%;
}

.y-axis-title {
    position: absolute;
    left: -70px;
    top: 50%;
    transform: translateY(-50%) rotate(-90deg);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-secondary);
    white-space: nowrap;
}

.y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 0;
    height: 100%;
    position: relative;
}

.y-axis-labels {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    text-align: right;
    padding-right: 15px;
    border-right: 1px solid var(--color-text-primary);
}

.y-axis-labels span {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-text-secondary);
}

.chart-main {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    /* Fixed aspect ratio for the chart area itself */
    background: #fafafa;
    border-bottom: 2px solid var(--color-text-primary);
    overflow: hidden;
}

.phase-divider {
    position: absolute;
    left: 40%;
    top: 0;
    bottom: 0;
    border-left: 1px dashed #ccc;
    z-index: 2;
}

.phase-label {
    position: absolute;
    top: 15px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-text-secondary);
    z-index: 5;
}

.phase-aufbau-label {
    left: 15px;
}

.phase-kontinuitaet-label {
    left: calc(40% + 15px);
}

.journey-line-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

.x-axis-footer {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: var(--space-sm);
    margin-top: var(--space-sm);
    position: relative;
}

.x-axis-title {
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-secondary);
}

.x-axis-content {
    display: flex;
    justify-content: space-between;
    position: relative;
    padding-top: 5px;
}

.x-axis-content span {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@media (max-width: 992px) {
    .journey-chart-container {
        grid-column: 1 / -1;
        margin-top: var(--space-xl);
    }
}

@media (max-width: 768px) {
    .chart-frame {
        grid-template-columns: 1fr;
        height: 300px;
    }

    .y-axis-labels,
    .y-axis-title {
        display: none;
    }

    .x-axis-footer {
        grid-template-columns: 1fr;
        margin-top: var(--space-md);
    }

    .x-axis-title {
        position: static;
        transform: none;
        margin-top: var(--space-xs);
        text-align: center;
        font-size: 0.72rem;
    }

    .x-axis-content {
        padding-top: 0;
        gap: var(--space-xs);
    }

    .x-axis-content span {
        font-size: 0.72rem;
    }

    .phase-divider {
        display: block;
        left: 40%;
        border-left: 1px dashed #bdbdbd;
        z-index: 3;
    }

    .phase-divider::after {
        content: "80% SCHUTZ";
        position: absolute;
        top: 8px;
        left: 6px;
        font-family: monospace;
        font-size: 0.66rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        color: var(--color-text-primary);
        background: rgba(255, 255, 255, 0.9);
        padding: 2px 4px;
        border-radius: 2px;
    }

    .chart-main {
        aspect-ratio: 4 / 3;
    }

    .chart-main::before {
        content: "PHASE 1: AUFBAU";
        position: absolute;
        top: 8px;
        left: 8px;
        font-family: monospace;
        font-size: 0.62rem;
        font-weight: 700;
        letter-spacing: 0.06em;
        color: var(--color-text-secondary);
        z-index: 6;
    }

    .chart-main::after {
        content: "PHASE 2: BEGLEITUNG";
        position: absolute;
        top: 8px;
        right: 8px;
        font-family: monospace;
        font-size: 0.62rem;
        font-weight: 700;
        letter-spacing: 0.06em;
        color: var(--color-text-secondary);
        z-index: 6;
    }
}

/* ─── Accessibility ─────────────────────────────────────────────────────── */

/* Global keyboard focus indicator – visible only for keyboard navigation */
:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
    border-radius: 2px;
}

/* Remove default focus ring for mouse users (handled by :focus-visible above) */
:focus:not(:focus-visible) {
    outline: none;
}

/* Skip navigation link – visually hidden until focused */
.skip-nav {
    position: absolute;
    left: -10000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
    background: var(--color-accent);
    color: #fff;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-family-sans);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    border-radius: 0 0 4px 4px;
    z-index: 9999;
    white-space: nowrap;
}

.skip-nav:focus {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    width: auto;
    height: auto;
    overflow: visible;
}

/* Noscript fallback: make all reveal sections visible without JS */
.no-js .reveal {
    opacity: 1;
    transform: none;
}

/* ─── Typography Utilities ──────────────────────────────────────────────── */

.lead {
    font-size: var(--font-size-md);
    line-height: 1.5;
    margin-bottom: var(--space-md);
}

/* Opacity-based text softening — preferred over grey color tokens */
.text-muted {
    opacity: 0.8;
}

.text-muted-2 {
    opacity: 0.6;
}

/* ─── Hero Layout Helpers ────────────────────────────────────────────────── */

/* Desktop: video occupies right 5 columns; mobile falls through to full-width */
.hero-video {
    grid-column: 8 / -1;
    box-shadow: none;
}

.hero .grid {
    align-items: start;
}

.hero .btn-group {
    margin-bottom: var(--space-lg);
}

/* ─── Button Variants ────────────────────────────────────────────────────── */

.btn--sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn--full {
    width: 100%;
    text-align: center;
    display: block;
}

/* ─── Price Display ──────────────────────────────────────────────────────── */

.price-display {
    font-size: var(--font-size-3xl);
    font-weight: 700;
    color: var(--color-accent);
}

.price-display--light {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--color-text-primary);
}

.price-unit {
    font-size: var(--font-size-lg);
    font-weight: 400;
    opacity: 0.8;
}

.price-note {
    display: block;
    opacity: 0.6;
    font-size: var(--font-size-sm);
    margin-top: var(--space-xs);
}

/* ─── Bento Grid Variants ────────────────────────────────────────────────── */

.bento-item--inverted {
    background: var(--color-bg) !important;
    border: 2px solid var(--color-text-primary) !important;
    color: var(--color-text-primary) !important;
}

/* ─── Dark Section Stat Cards ────────────────────────────────────────────── */

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    padding: var(--space-lg);
    border-left: 4px solid var(--color-accent);
}

.stat-label {
    font-size: var(--font-size-md);
    display: block;
    margin-bottom: var(--space-sm);
    color: var(--color-on-dark);
}

.stat-value {
    font-size: var(--font-size-4xl);
    color: var(--color-white);
    display: block;
    line-height: 1.1;
    font-weight: 700;
}

.stat-description {
    margin-top: var(--space-md);
    font-size: 0.9rem;
    color: var(--color-on-dark-muted);
}

/* ─── Footer Component Helpers ───────────────────────────────────────────── */

.footer-logo {
    height: 40px;
    width: auto;
    margin-bottom: var(--space-md);
    opacity: 0.9;
}

.footer-brand-text {
    font-size: var(--font-size-sm);
    opacity: 0.7;
    line-height: 1.6;
}

.footer-nav-label {
    font-family: 'Inter Tight', var(--font-family-sans);
    font-size: var(--font-size-sm);
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--color-on-dark-muted);
    margin-bottom: var(--space-sm);
}

.footer-nav-list {
    list-style: none;
    padding: 0;
}

.footer-nav-list li {
    margin-bottom: var(--space-xs);
}

.footer-bottom {
    grid-column: 1 / -1;
    margin-top: var(--space-xl);
    padding-top: var(--space-md);
    border-top: 1px solid var(--color-border-dark);
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.footer-copyright {
    font-size: 0.8rem;
    opacity: 0.5;
}

.footer-social-link {
    text-decoration: none;
    border-bottom: none !important;
}

.footer-social-icon {
    height: 24px;
    width: 24px;
    filter: brightness(0) invert(1);
}

/* Footer grid column layout */
.footer-col-brand   { grid-column: 1 / 4; }
.footer-col-links   { grid-column: 5 / 7; }
.footer-col-legal   { grid-column: 8 / 10; }
.footer-col-contact { grid-column: 11 / -1; }

/* ─── Economy Chart Accent ───────────────────────────────────────────────── */

/* Highlight the cyber-crime column callout in accent orange */
.economy-callout.cyber {
    border-top: 3px solid var(--color-accent);
}

.economy-callout.cyber b {
    color: var(--color-accent);
}

/* Angebot section: accent label to draw eye to the offer */
#angebot .hero-subtitle {
    color: var(--color-accent);
}

/* ─── Entrance Animations ─────────────────────────────────────────────────── */

@keyframes sr-enter {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes sr-settle {
    from { transform: translateY(16px); }
    to   { transform: translateY(0); }
}

@keyframes sr-side-left {
    from { transform: translateX(-24px); }
    to   { transform: translateX(0); }
}

@keyframes sr-side-right {
    from { transform: translateX(24px); }
    to   { transform: translateX(0); }
}

/* ─── Hero — staggered entrance (section is pre-active on load) ───────────── */

.hero-content .hero-subtitle {
    animation: sr-enter 0.75s var(--ease-out-expo) 80ms backwards;
}

.hero-content h1 {
    animation: sr-enter 0.75s var(--ease-out-expo) 180ms backwards;
}

.hero-content .lead {
    animation: sr-enter 0.75s var(--ease-out-expo) 320ms backwards;
}

.hero-content .btn-group {
    animation: sr-enter 0.75s var(--ease-out-expo) 480ms backwards;
}

/* ─── Economy Chart — bars grow from baseline ─────────────────────────────── */

/* Override base flagpole: start collapsed, grow on section activation */
.flagpole {
    transform: scaleY(0);
    transition: transform 1.1s var(--ease-out-quart);
    /* transform-origin: bottom already set */
}

/* Callout labels hidden until bars finish growing */
.economy-callout {
    opacity: 0;
    transition: opacity 0.4s var(--ease-out-expo);
}

/* Staggered bar growth when #weltweit enters viewport */
#weltweit.active .flagpole.usa   { transform: scaleY(1); transition-delay:   0ms; }
#weltweit.active .flagpole.china { transform: scaleY(1); transition-delay: 220ms; }
#weltweit.active .flagpole.cyber { transform: scaleY(1); transition-delay: 440ms; }

/* Callouts fade in after their bar has grown (~85% of 1.1s) */
#weltweit.active .flagpole.usa   .economy-callout { opacity: 1; transition-delay:  860ms; }
#weltweit.active .flagpole.china .economy-callout { opacity: 1; transition-delay: 1080ms; }
#weltweit.active .flagpole.cyber .economy-callout { opacity: 1; transition-delay: 1300ms; }

/* ─── JS-driven child stagger (class added by IntersectionObserver) ────────── */

/* Stat cards — punch in after dark section background reveals */
.stat-card.is-entering {
    animation: sr-enter 0.65s var(--ease-out-expo);
}

/* Compare cards — directional entry from opposite sides */
.compare-card-left.is-entering {
    animation: sr-side-left 0.7s var(--ease-out-expo);
}

.compare-card-right.is-entering {
    animation: sr-side-right 0.7s var(--ease-out-expo);
}

/* Role cards — sequential vertical settle */
.role-card.is-entering {
    animation: sr-settle 0.65s var(--ease-out-expo);
}

/* Process steps — cascading vertical settle */
.process-step-premium.is-entering {
    animation: sr-settle 0.6s var(--ease-out-expo);
}

/* ─── Reduced motion — disable all entrance animations ───────────────────── */

@media (prefers-reduced-motion: reduce) {
    .hero-content .hero-subtitle,
    .hero-content h1,
    .hero-content .lead,
    .hero-content .btn-group {
        animation: none;
    }

    .flagpole {
        transform: scaleY(1) !important;
        transition: none !important;
    }

    .economy-callout {
        opacity: 1 !important;
        transition: none !important;
    }

    .stat-card.is-entering,
    .compare-card-left.is-entering,
    .compare-card-right.is-entering,
    .role-card.is-entering,
    .process-step-premium.is-entering {
        animation: none !important;
    }
}
