/* ===== Local Fonts ===== */
@font-face {
    font-family: 'DM Sans';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/dm-sans-400.woff2') format('woff2');
}

@font-face {
    font-family: 'DM Sans';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('/fonts/dm-sans-500.woff2') format('woff2');
}

@font-face {
    font-family: 'DM Sans';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('/fonts/dm-sans-600.woff2') format('woff2');
}

@font-face {
    font-family: 'DM Sans';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/dm-sans-700.woff2') format('woff2');
}

/* ===== Variables ===== */
:root {
    --bg-white: #ffffff;
    --bg-light: #f7f8f9;
    --bg-dark: #101814;
    --bg-darker: #101814;
    
    --green: #1B4D3E;
    --green-light: #2E7D32;
    --green-accent: #4CAF50;
    --green-glow: #9acd32;
    --blue: #1a3a5c;
    --gold: #B8860B;
    --brown: #6D4C41;
    
    --text-primary: #1a1a1a;
    --text-secondary: #555;
    --text-muted: #888;
    --text-white: #ffffff;
    --border-color: #e5e5e5;
    
    --font-family: 'DM Sans', -apple-system, sans-serif;
    --radius: 12px;
    --radius-lg: 16px;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-family);
    background: var(--bg-white);
    color: var(--text-primary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ===== Icons ===== */
.icon {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.icon-lg { width: 32px; height: 32px; }
.icon-xl { width: 40px; height: 40px; }

.icon-box {
    width: 56px;
    height: 56px;
    background: var(--bg-light);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.icon-box-green {
    background: rgba(27, 77, 62, 0.08);
    color: var(--green);
}

.icon-box-white {
    background: rgba(255,255,255,0.15);
    color: white;
}

/* ===== Animations ===== */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
    animation: fallback-reveal 0s 1.5s forwards;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
    animation: none;
}

.animate-fade {
    opacity: 0;
    transition: opacity 0.8s ease;
    animation: fallback-reveal 0s 1.5s forwards;
}

.animate-fade.animated { opacity: 1; animation: none; }

@keyframes fallback-reveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Page Enter Animations ===== */
@keyframes enterUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes enterLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes enterRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes enterScale {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pageFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.page-enter {
    animation: pageFadeIn 0.4s ease forwards;
}

/* Portfolio detail page */
.portfolio-breadcrumb { animation: enterDown 0.4s ease 0.05s both; }
.portfolio-detail-hero { animation: enterScale 0.7s ease 0.1s both; }
.portfolio-detail-content { animation: pageFadeIn 0.5s ease 0.2s both; }
.portfolio-detail-main { animation: enterLeft 0.6s ease 0.3s both; }
.portfolio-detail-sidebar { animation: enterRight 0.6s ease 0.35s both; }

/* Blog overview page */
.blog-page .section-header { animation: enterDown 0.5s ease 0.1s both; }
.blog-list-item { animation: enterUp 0.5s ease both; }
.blog-list-item:nth-child(odd) { animation-name: enterLeft; }
.blog-list-item:nth-child(even) { animation-name: enterRight; }
.blog-list-item:nth-child(1) { animation-delay: 0.15s; }
.blog-list-item:nth-child(2) { animation-delay: 0.25s; }
.blog-list-item:nth-child(3) { animation-delay: 0.35s; }
.blog-list-item:nth-child(4) { animation-delay: 0.45s; }
.blog-list-item:nth-child(5) { animation-delay: 0.55s; }
.blog-list-item:nth-child(n+6) { animation-delay: 0.6s; }

/* Blog post detail */
.blog-post-hero { animation: enterScale 0.8s ease both; }
.blog-post-header { animation: enterLeft 0.5s ease 0.15s both; }
.blog-post-content { animation: enterUp 0.6s ease 0.25s both; }
.blog-post-footer { animation: pageFadeIn 0.5s ease 0.4s both; }

/* Legal pages */
.legal-header { animation: enterDown 0.5s ease 0.1s both; }
.legal-content { animation: pageFadeIn 0.4s ease 0.15s both; }
.legal-section:nth-child(odd) { animation: enterLeft 0.5s ease both; }
.legal-section:nth-child(even) { animation: enterRight 0.5s ease both; }
.legal-section:nth-child(1) { animation-delay: 0.2s; }
.legal-section:nth-child(2) { animation-delay: 0.28s; }
.legal-section:nth-child(3) { animation-delay: 0.36s; }
.legal-section:nth-child(4) { animation-delay: 0.44s; }
.legal-section:nth-child(5) { animation-delay: 0.52s; }

.stagger-children > *:nth-child(1) { transition-delay: 0s; }
.stagger-children > *:nth-child(2) { transition-delay: 0.08s; }
.stagger-children > *:nth-child(3) { transition-delay: 0.16s; }
.stagger-children > *:nth-child(4) { transition-delay: 0.24s; }
.stagger-children > *:nth-child(5) { transition-delay: 0.32s; }
.stagger-children > *:nth-child(6) { transition-delay: 0.4s; }

/* ===== Navigation ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 1.1rem 4rem;
    display: flex;
    justify-content: center;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    transition: padding 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav.scrolled {
    padding: 0.5rem 4rem;
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
    border-color: transparent;
}

.nav-container {
    max-width: 1200px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo + CODE Wrapper */
.nav-brand-group {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.nav-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    overflow: hidden;
    max-width: 200px;
    transition: max-width 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav.scrolled .nav-logo {
    max-width: 0;
    opacity: 0;
    pointer-events: none;
}

.nav-logo-img {
    height: 32px;
    width: auto;
    flex-shrink: 0;
}

/* "CODE" – immer sichtbar, gleitet beim Scroll nach links */
.nav-brand {
    font-size: 1.4rem;
    font-weight: 70;
    padding-top: 10px;
    letter-spacing: 0.15em;
    color: var(--green);
    white-space: nowrap;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav.scrolled .nav-brand {
    transform: translateX(-10px);
}

/* Navigation Links */
.nav-links {
    display: flex;
    gap: 1.75rem;
    font-size: 0.875rem;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    position: relative;
    transition: color 0.25s ease;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--green);
    border-radius: 1px;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-links a:hover { color: var(--green); }
.nav-links a:hover::after { width: 100%; }

.nav-cta {
    background: var(--green);
    color: white;
    padding: 0.65rem 1.25rem;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.85rem;
    transition: background 0.25s ease, transform 0.25s ease;
}

/* ===== Hero ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 7rem 4rem 4rem;
    background: var(--bg-light);
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.hero-bg svg {
    width: 100%;
    height: 100%;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 1;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-label {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--green);
    margin-bottom: 1.25rem;
}

.hero-title {
    font-size: clamp(2.25rem, 4.5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 1.25rem;
}

.text-green { color: var(--green); }

.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 440px;
    line-height: 1.75;
}

.hero-buttons {
    display: flex;
    gap: 0.75rem;
}

.btn {
    padding: 0.875rem 1.75rem;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--green);
    color: white;
}

.btn-primary:hover { background: var(--green-light); }

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

.btn-secondary:hover {
    border-color: var(--green);
    color: var(--green);
}

/* Hero Tiles */
.hero-tiles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.hero-tile {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    border-radius: 0;
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    transition: transform 0.3s;
}

.hero-tile:hover { transform: translateY(-4px); }

.hero-tile-main {
    grid-column: span 2;
    background: var(--green);
    color: white;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem;
    text-align: center;
}

.hero-tile-main .icon-box {
    background: rgba(255,255,255,0.15);
    margin-bottom: 1rem;
}

.hero-tile-title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.hero-tile-subtitle {
    font-size: 0.8rem;
    opacity: 0.7;
}

.hero-tile-stat {
    text-align: center;
}

.hero-tile-stat .stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--green);
    display: block;
    line-height: 1;
}

.hero-tile-stat .stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* ===== Sections ===== */
.section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 6rem 4rem;
}

.section-alt { background: var(--bg-light); }

.section-green {
    background: #1B4D3E;
    color: white;
}

.section-green h2 {
    color: white;
}

.section-green .section-number {
    color: rgba(255,255,255,0.5);
}

.section-green .section-desc {
    color: rgba(255,255,255,0.7);
}

.section-green .service-tile {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.1);
}

.section-green .service-tile:hover {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.2);
}

.section-green .service-tile h4 {
    color: white;
}

.section-green .service-tile p {
    color: rgba(255,255,255,0.7);
}

.section-green .icon-box {
    background: rgba(255,255,255,0.15);
    color: white;
}

/* ===== Services – Hexagon Grid ===== */
.hex-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
}

.hex-row {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.hex-row + .hex-row {
    margin-top: -65px;
}

.hex-item {
    width: 250px;
    height: 280px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2.5rem 1.75rem;
    gap: 0.5rem;
    transition: transform 0.3s ease, background 0.3s ease;
    cursor: default;
}

.hex-item:hover {
    transform: scale(1.07);
    background: rgba(255, 255, 255, 0.15);
}

/* LIMS – Hervorgehobenes Zentrum */
.hex-item-center {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.14);
    filter: drop-shadow(0 0 20px rgba(154, 205, 50, 0.25));
}

.hex-bg-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    z-index: 0;
}

.hex-item-center:hover {
    background: rgba(255, 255, 255, 0.55);
    filter: drop-shadow(0 0 28px rgba(154, 205, 50, 0.4));
}

.hex-item-center:hover .hex-bg-img {
    opacity: 0.4;
}

.hex-item-center .hex-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.25rem;
}

.hex-item-center .hex-icon,
.hex-item-center h4,
.hex-item-center p {
    position: relative;
    z-index: 1;
    transition: color 0.4s ease;
}

.hex-item-center:hover .hex-icon {
    color: var(--green);
}

.hex-item-center:hover h4 {
    color: var(--green);
}

.hex-item-center:hover p {
    color: var(--green);
}

.hex-item h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: white;
    margin: 0;
}

.hex-item p {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    margin: 0;
    max-width: 170px;
}

/* Responsive */
@media (max-width: 900px) {
    .hex-item {
        width: 200px;
        height: 225px;
        padding: 2rem 1.25rem;
    }

    .hex-item h4 { font-size: 0.85rem; }
    .hex-item p { font-size: 0.72rem; max-width: 140px; }

    .hex-row + .hex-row { margin-top: -52px; }
}

@media (max-width: 640px) {
    .hex-row {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    .hex-row + .hex-row { margin-top: 8px; }

    .hex-item {
        width: 220px;
        height: 248px;
    }
}

/* ===== Services ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.service-tile {
    background: white;
    padding: 1.75rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    transition: transform 0.3s, border-color 0.3s;
}

.service-tile:hover {
    transform: translateY(-6px);
    border-color: var(--green);
}

.service-tile .icon-box { margin-bottom: 1.25rem; }

.service-tile h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.service-tile p {
    color: var(--text-secondary);
    font-size: 0.875rem;
    line-height: 1.6;
}

/* ===== About ===== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-quote {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 1.25rem 0;
    line-height: 1.35;
}

.about-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-size: 0.95rem;
    line-height: 1.75;
}

.about-tiles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.about-tile {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
}

.about-tile-main {
    grid-column: span 2;
    background: var(--green);
    color: white;
    border: none;
    padding: 2rem;
}

.about-tile .icon-box { margin: 0 auto 1rem; }

.about-tile-main .icon-box { background: rgba(255,255,255,0.15); }

.about-tile-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--green);
    display: block;
}

.about-tile-main .about-tile-value { color: white; }

.about-tile-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.about-tile-main .about-tile-label { color: rgba(255,255,255,0.7); }

/* ===== Portfolio - Dark Masonry + Carousel ===== */
.portfolio-section {
    background: var(--bg-darker);
    padding: 6rem 0;
    min-height: 100vh;
}

.portfolio-section .section-number {
    color: rgba(255,255,255,0.45);
}

.portfolio-header {
    padding: 0 4rem;
    margin-bottom: 2.5rem;
}

.portfolio-header-content {
    max-width: 1200px;
    margin: 0 auto;
}

.portfolio-title-large {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 600;
    color: white;
    line-height: 1.35;
    max-width: 700px;
    margin-bottom: 2rem;
}

/* Portfolio Filter Tabs */
.portfolio-filter {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0;
}

.filter-btn {
    padding: 0.5rem 1.25rem;
    border-radius: 4px;
    border: none;
    background: transparent;
    color: rgba(255,255,255,0.5);
    font-weight: 500;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.filter-btn:hover { color: white; background: rgba(255,255,255,0.08); }

.filter-btn.active {
    background: var(--green);
    color: white;
}

/* Portfolio Filter Grid */
.portfolio-grid-container {
    padding: 0 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.portfolio-filter-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.portfolio-filter-item {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: 4px;
    overflow: hidden;
    text-decoration: none;
    display: block;
    transition: opacity 0.3s, transform 0.3s;
}

.portfolio-filter-item .portfolio-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    text-align: center;
}

.portfolio-filter-item.agricore { background: linear-gradient(135deg, #1B4D3E 0%, #2E7D32 100%); }
.portfolio-filter-item.enercore { background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%); }
.portfolio-filter-item.pastacore { background: linear-gradient(135deg, #b45309 0%, #f59e0b 100%); }
.portfolio-filter-item.terracore { background: linear-gradient(135deg, #78350f 0%, #a16207 100%); }
.portfolio-filter-item.integration { background: linear-gradient(135deg, #4338ca 0%, #818cf8 100%); }

.portfolio-filter-item.has-image {
    background-size: cover;
    background-position: center;
}

@media (max-width: 900px) {
    .portfolio-filter-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .portfolio-grid-container {
        padding: 0 1.5rem;
    }
}

@media (max-width: 600px) {
    .portfolio-filter-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-filter {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* Portfolio Masonry Grid */
.portfolio-masonry {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    padding: 0 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.portfolio-masonry-row {
    display: grid;
    gap: 0.5rem;
}

.portfolio-masonry-row.row-single {
    grid-template-columns: 1fr;
}

.portfolio-masonry-row.row-double {
    grid-template-columns: 1fr 1fr;
}

.portfolio-masonry-row.row-triple {
    grid-template-columns: 1fr 1fr 1fr;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    cursor: pointer;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* Scroll reveal - items start hidden */
.portfolio-item[data-category] {
    opacity: 0;
    transform: translateY(30px);
}

.portfolio-item[data-category].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Grid fade on filter */
.portfolio-masonry {
    transition: opacity 0.3s ease;
}

.portfolio-masonry.portfolio-fading {
    opacity: 0;
}

.portfolio-item-tall {
    aspect-ratio: 16/10;
}

.portfolio-item-medium {
    aspect-ratio: 4/3;
}

.portfolio-item-square {
    aspect-ratio: 1/1;
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

/* Placeholder for portfolio items */
.portfolio-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.6s ease;
}

.portfolio-item:hover .portfolio-image,
.portfolio-item:hover .portfolio-placeholder {
    transform: scale(1.05);
}

.portfolio-placeholder .icon-box {
    width: 80px;
    height: 80px;
    background: rgba(255,255,255,0.1);
    margin-bottom: 1rem;
}

.portfolio-placeholder-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: white;
}

.portfolio-placeholder-subtitle {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
}

/* Portfolio Info (visible by default at bottom) */
.portfolio-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: white;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.portfolio-info .portfolio-client {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.8;
}

.portfolio-info h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 0.25rem;
}

.portfolio-item:hover .portfolio-info {
    opacity: 0;
}

/* Portfolio Overlay (visible on hover) */
.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.88);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.4s ease;
    text-align: center;
    z-index: 2;
}

.portfolio-overlay h4,
.portfolio-overlay p,
.portfolio-overlay .portfolio-category-tag,
.portfolio-overlay .portfolio-cta {
    transform: translateY(10px);
    transition: transform 0.4s ease, opacity 0.4s ease;
    opacity: 0;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-item:hover .portfolio-overlay .portfolio-category-tag {
    transform: translateY(0);
    opacity: 1;
    transition-delay: 0.05s;
}

.portfolio-item:hover .portfolio-overlay h4 {
    transform: translateY(0);
    opacity: 1;
    transition-delay: 0.1s;
}

.portfolio-item:hover .portfolio-overlay p {
    transform: translateY(0);
    opacity: 1;
    transition-delay: 0.15s;
}

.portfolio-item:hover .portfolio-overlay .portfolio-cta {
    transform: translateY(0);
    opacity: 1;
    transition-delay: 0.2s;
}

.portfolio-category-tag {
    display: inline-block;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    margin-bottom: 1rem;
    color: white;
}

.portfolio-item.agricore .portfolio-category-tag { background: #1B4D3E; }
.portfolio-item.enercore .portfolio-category-tag { background: #2563eb; }
.portfolio-item.pastacore .portfolio-category-tag { background: #d97706; }
.portfolio-item.terracore .portfolio-category-tag { background: #78350f; }
.portfolio-item.integration .portfolio-category-tag { background: #6366f1; }

.portfolio-overlay h4 {
    font-size: 1.25rem;
    color: white;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.portfolio-overlay p {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.6;
    margin-bottom: 1.25rem;
    max-width: 280px;
}

.portfolio-cta {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
    padding: 0.5rem 1rem;
    border: 2px solid white;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.portfolio-item:hover .portfolio-cta {
    background: white;
    color: #1B4D3E;
}

/* Portfolio mit Bild */
.portfolio-item.has-image .portfolio-placeholder {
    display: none;
}

/* Portfolio All Link */
.portfolio-all-link {
    text-align: center;
    margin-top: 3rem;
}

.btn-outline {
    display: inline-block;
    padding: 0.85rem 2rem;
    border: 2px solid var(--green);
    color: var(--green);
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: var(--green);
    color: white;
}

/* Portfolio Carousel */
.portfolio-carousel {
    position: relative;
    margin-top: 3rem;
}

.portfolio-carousel-track {
    display: flex;
    gap: 1.5rem;
    padding: 0 4rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.portfolio-carousel-track::-webkit-scrollbar {
    display: none;
}

.portfolio-slide {
    flex: 0 0 calc(50% - 0.75rem);
    scroll-snap-align: start;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.portfolio-slide-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.portfolio-slide-number {
    position: absolute;
    bottom: 1rem;
    left: 1.5rem;
    font-size: 6rem;
    font-weight: 700;
    color: rgba(255,255,255,0.15);
    line-height: 1;
    pointer-events: none;
}

.portfolio-slide-info {
    position: absolute;
    bottom: 1.5rem;
    left: 1.5rem;
    right: 1.5rem;
}

.portfolio-slide-title {
    font-size: 1rem;
    color: white;
    font-weight: 500;
}

.portfolio-slide-category {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
}

/* Portfolio Progress Bar */
.portfolio-progress {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
    padding: 0 4rem;
}

.progress-line {
    width: 60px;
    height: 3px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    cursor: pointer;
    transition: background 0.3s;
}

.progress-line.active {
    background: white;
}

.progress-line:hover {
    background: rgba(255,255,255,0.5);
}

/* ===== Products ===== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.product-tile {
    border-radius: 0;
    padding: 1.75rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    cursor: pointer;
    transition: transform 0.3s;
}

.product-tile:hover { transform: translateY(-4px); }

.product-tile-dark { color: white; }

.product-tile-light {
    background: white;
    border: 1px solid var(--border-color);
}

.product-tile .icon-box, .product-logo-box {
    width: 64px;
    height: 64px;
}

.product-logo-box {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
    overflow: hidden;
    flex-shrink: 0;
}

.product-logo-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-tile-dark .icon-box { background: rgba(255,255,255,0.15); }

.product-tile-info { flex: 1; }

.product-tile-row {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.2rem;
}

.product-tile-info h3 {
    font-size: 1.15rem;
    font-weight: 700;
}

.product-tile-info p {
    opacity: 0.7;
    font-size: 0.85rem;
}

.product-badge {
    font-size: 0.55rem;
    padding: 0.2rem 0.45rem;
    background: rgba(255,255,255,0.2);
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.product-arrow {
    font-size: 1.1rem;
    opacity: 0.4;
}

/* ===== Timeline ===== */
/* ===== Process Timeline ===== */
.process-timeline {
    position: relative;
    max-width: 680px;
    margin-top: 1rem;
}

.process-timeline::before {
    content: '';
    position: absolute;
    left: 23px;
    top: 12px;
    bottom: 12px;
    width: 2px;
    background: linear-gradient(to bottom, var(--green), rgba(27,77,62,0.15));
}

.process-step {
    position: relative;
    display: flex;
    gap: 1.5rem;
    padding-bottom: 2.25rem;
}

.process-step:last-child {
    padding-bottom: 0;
}

.process-marker {
    flex-shrink: 0;
    z-index: 1;
}

.process-icon {
    width: 48px;
    height: 48px;
    background: var(--bg-light);
    border: 2px solid rgba(27,77,62,0.2);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--green);
    transition: all 0.3s ease;
}

.process-step:hover .process-icon {
    background: var(--green);
    color: white;
    border-color: var(--green);
    transform: scale(1.08);
}

.process-icon svg {
    width: 22px;
    height: 22px;
}

.process-content {
    padding-top: 0.15rem;
    flex: 1;
    min-width: 0;
}

.process-number {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--green);
    opacity: 0.5;
    letter-spacing: 0.08em;
    margin-bottom: 0.15rem;
    display: block;
}

.process-step h4 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
    color: var(--text-primary);
}

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

.section-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
    max-width: 520px;
    line-height: 1.6;
    margin-top: 0.75rem;
}

@media (max-width: 600px) {
    .process-timeline::before {
        left: 19px;
    }
    .process-step {
        gap: 1rem;
        padding-bottom: 1.75rem;
    }
    .process-icon {
        width: 40px;
        height: 40px;
        border-radius: 11px;
    }
    .process-icon svg {
        width: 18px;
        height: 18px;
    }
}

/* ===== Contact ===== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-intro {
    opacity: 0.85;
    font-size: 1rem;
    margin-bottom: 2rem;
    max-width: 360px;
    line-height: 1.75;
}

.contact-tiles {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.contact-tile {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: rgba(255,255,255,0.05);
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
}

.contact-tile .icon-box {
    background: rgba(255,255,255,0.1);
    width: 44px;
    height: 44px;
}

.contact-tile-label {
    font-size: 0.65rem;
    opacity: 0.5;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.contact-tile-value {
    font-size: 0.95rem;
    font-weight: 500;
}

/* Contact Form */
.contact-form-wrapper {
    background: rgba(255,255,255,0.05);
    border-radius: 4px;
    padding: 2rem;
    border: 1px solid rgba(255,255,255,0.1);
}

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

.form-group label {
    display: block;
    font-size: 0.7rem;
    opacity: 0.6;
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 4px;
    color: white;
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color 0.2s;
}

.form-input::placeholder { color: rgba(255,255,255,0.35); }

.form-input:focus {
    outline: none;
    border-color: rgba(255,255,255,0.3);
}

textarea.form-input { resize: none; }

.form-submit {
    width: 100%;
    padding: 0.9rem;
    background: white;
    color: var(--bg-dark);
    border: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    font-family: inherit;
    transition: transform 0.2s;
}

.form-submit:hover { transform: translateY(-2px); }

.form-success {
    text-align: center;
    padding: 2.5rem;
}

.success-icon {
    width: 56px;
    height: 56px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.form-success h4 {
    font-size: 1.15rem;
    margin-bottom: 0.35rem;
}

.form-success p {
    opacity: 0.7;
    font-size: 0.9rem;
}

.form-error {
    background: rgba(220, 38, 38, 0.15);
    border: 1px solid rgba(220, 38, 38, 0.3);
    color: #fca5a5;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.validation-message {
    color: #fca5a5;
    font-size: 0.78rem;
    margin-top: 0.3rem;
}

/* ===== Why Choose Us - Feature Grid ===== */
.why-section {
    background: var(--bg-white);
    padding: 6rem 4rem;
    min-height: auto;
}

.why-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem 6rem;
    max-width: 1100px;
    margin: 0 auto;
}

.why-item {
    padding: 0;
}

.why-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.why-number {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

.why-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.why-icon svg {
    width: 40px;
    height: 40px;
    stroke: var(--text-primary);
    stroke-width: 1;
}

.why-title {
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.why-divider {
    width: 120px;
    height: 3px;
    background: var(--text-primary);
    margin-bottom: 1.5rem;
}

.why-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.8;
    max-width: 400px;
}

/* Dark variant for AGRICORE */
.why-section-dark {
    background: var(--bg-dark);
}

.why-section-dark .why-number {
    color: rgba(255,255,255,0.4);
}

.why-section-dark .why-icon svg {
    stroke: var(--green-glow);
}

.why-section-dark .why-title {
    color: white;
}

.why-section-dark .why-divider {
    background: var(--green-glow);
}

.why-section-dark .why-text {
    color: rgba(255,255,255,0.6);
}

@media (max-width: 768px) {
    .why-section {
        padding: 4rem 1.5rem;
    }
    
    .why-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .why-title {
        font-size: 1.5rem;
    }
}

/* ===== Testimonials ===== */
.testimonials-section {
    background: var(--bg-darker);
    padding: 5rem 4rem;
}

.testimonials-container {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.testimonials-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 3rem;
    letter-spacing: -0.02em;
}

/* Testimonial Carousel */
.testimonial-carousel {
    position: relative;
}

.testimonial-avatars {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.testimonial-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 10px;
    transition: all 0.3s ease;
}

.testimonial-avatar:hover {
    background: #ffffff;
    border-color: rgba(255,255,255,0.3);
}

.testimonial-avatar.active {
    border-color: var(--green-accent);
    background: #ffffff;
}

.testimonial-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Slides */
.testimonial-slides {
    position: relative;
    min-height: 200px;
}

.testimonial-slide {
    display: none;
    animation: fadeIn 0.4s ease;
}

.testimonial-slide.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.testimonial-text {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.8;
    font-style: italic;
    margin-bottom: 2rem;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

.testimonial-divider {
    width: 40px;
    height: 2px;
    background: rgba(255,255,255,0.2);
    margin: 0 auto 1.5rem;
}

.testimonial-name {
    display: block;
    font-weight: 700;
    color: white;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    margin-bottom: 0.25rem;
}

.testimonial-role {
    display: block;
    font-size: 0.85rem;
    color: var(--green-accent);
}

.testimonial-link {
    display: inline-block;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.4);
    margin-top: 0.4rem;
    text-decoration: none;
    transition: color 0.2s;
}

.testimonial-link:hover {
    color: rgba(255,255,255,0.7);
}

.testimonials-empty {
    color: rgba(255,255,255,0.5);
    font-style: italic;
}

@media (max-width: 768px) {
    .testimonials-section {
        padding: 3rem 1.5rem;
    }
    
    .testimonials-title {
        font-size: 2rem;
    }
    
    .testimonial-text {
        font-size: 1rem;
    }
    
    .testimonial-avatar {
        width: 52px;
        height: 52px;
    }
}

/* ===== Footer ===== */
.footer {
    padding: 1.25rem 4rem;
    background: var(--bg-darker);
    color: white;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
}

.footer-logo-img {
    height: 26px;
    width: auto;
    opacity: 0.6;
}

.footer-links {
    display: flex;
    gap: 1.75rem;
    font-size: 0.8rem;
}

.footer-links a {
    opacity: 0.6;
    transition: opacity 0.2s;
}

.footer-links a:hover { opacity: 1; }

.footer-copy {
    font-size: 0.75rem;
    opacity: 0.4;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .hero-grid,
    .about-grid,
    .contact-grid,
    .section-header-split {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    
    .portfolio-slide { flex: 0 0 calc(80% - 0.75rem); }
    
    .portfolio-masonry-row.row-double,
    .portfolio-masonry-row.row-triple {
        grid-template-columns: 1fr;
    }
    
    .section { min-height: auto; padding: 4rem 3rem; }
    
    .portfolio-header,
    .portfolio-masonry,
    .portfolio-carousel-track,
    .portfolio-progress {
        padding-left: 2rem;
        padding-right: 2rem;
    }
}

@media (max-width: 768px) {
    .nav { padding: 1rem 1.5rem; }
    .nav-links { display: none; }
    
    .section, .hero { padding: 3rem 1.5rem; }
    
    .services-grid,
    .products-grid,
    .hero-tiles,
    .about-tiles {
        grid-template-columns: 1fr;
    }
    
    .hero-tile-main,
    .about-tile-main {
        grid-column: span 1;
    }
    
    .hero-buttons { flex-direction: column; }
    
    .portfolio-header,
    .portfolio-masonry,
    .portfolio-carousel-track,
    .portfolio-progress {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    
    .portfolio-slide { flex: 0 0 calc(90% - 0.75rem); }
    
    .portfolio-slide-number { font-size: 4rem; }
    
    .footer-container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* ===== Blog Teaser ===== */
/* ===== Blog Staggered Layout ===== */
.blog-staggered {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    align-items: start;
    min-height: 600px;
}

.blog-staggered-header {
    position: sticky;
    top: 8rem;
}

.blog-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.4rem 1rem;
    background: var(--text-primary);
    color: white;
    border-radius: 0;
    margin-bottom: 1.5rem;
}

.blog-staggered-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.05;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.blog-staggered-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.blog-view-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 1.75rem;
    background: var(--green-accent);
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 0;
    transition: background 0.2s, transform 0.2s;
}

.blog-view-btn:hover {
    background: var(--green);
    transform: translateY(-2px);
}

.blog-view-btn span {
    font-size: 1.1rem;
    transition: transform 0.2s;
}

.blog-view-btn:hover span {
    transform: translate(2px, -2px);
}

/* Staggered Grid */
.blog-staggered-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    align-items: start;
}

.blog-staggered-card {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.3s;
}

.blog-staggered-card:hover {
    transform: translateY(-6px);
}

/* Stagger vertical positions */
.blog-staggered-card-0 { margin-top: 12rem; }
.blog-staggered-card-1 { margin-top: 5rem; }
.blog-staggered-card-2 { margin-top: 0; }

.blog-staggered-image {
    width: 100%;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    border-radius: 0;
    background: #f0f0f0;
    margin-bottom: 1rem;
}

.blog-staggered-card-1 .blog-staggered-image {
    aspect-ratio: 4 / 4;
}

.blog-staggered-card-2 .blog-staggered-image {
    aspect-ratio: 16 / 10;
}

.blog-staggered-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s;
}

.blog-staggered-card:hover .blog-staggered-image img {
    transform: scale(1.05);
}

.blog-staggered-card h3 {
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.35;
    color: var(--text-primary);
    margin: 0;
}

/* Responsive */
@media (max-width: 1024px) {
    .blog-staggered {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .blog-staggered-header {
        position: static;
    }
    
    .blog-staggered-title {
        font-size: 2.5rem;
    }
    
    .blog-staggered-card-0 { margin-top: 6rem; }
    .blog-staggered-card-1 { margin-top: 2rem; }
    .blog-staggered-card-2 { margin-top: 0; }
}

@media (max-width: 768px) {
    .blog-staggered-grid {
        grid-template-columns: 1fr;
    }
    
    .blog-staggered-card-0,
    .blog-staggered-card-1,
    .blog-staggered-card-2 {
        margin-top: 0;
    }
    
    .blog-staggered-image {
        aspect-ratio: 16 / 9;
    }
    
    .blog-staggered-card-1 .blog-staggered-image,
    .blog-staggered-card-2 .blog-staggered-image {
        aspect-ratio: 16 / 9;
    }
    
    .blog-staggered-title {
        font-size: 2rem;
    }
}

.blog-empty {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
    grid-column: 1 / -1;
}

/* Form Hint */
.form-hint {
    display: block;
    font-size: 0.75rem;
    color: #888;
    margin-top: 0.35rem;
}

/* ===== Legal Pages (Impressum, Datenschutz) ===== */
.legal-page {
    background: var(--bg-dark);
    min-height: 100vh;
    padding: 2rem 4rem 4rem;
}

.legal-container {
    max-width: 780px;
    margin: 0 auto;
}

.legal-header {
    margin-bottom: 3rem;
}

.legal-back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--green-accent);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    transition: opacity 0.2s;
}

.legal-back:hover { opacity: 0.7; }

.legal-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffffff;
}

.legal-content {
    color: rgba(255,255,255,0.7);
    line-height: 1.8;
}

.legal-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.legal-section:last-of-type { border-bottom: none; }

.legal-section h2 {
    font-size: 1.3rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 1rem;
}

.legal-section h3 {
    font-size: 1.05rem;
    font-weight: 600;
    color: #ffffff;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.legal-section p {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.legal-section address {
    font-style: normal;
    font-size: 0.95rem;
    line-height: 1.9;
}

.legal-section a {
    color: var(--green-accent);
    text-decoration: none;
    transition: opacity 0.2s;
}

.legal-section a:hover { opacity: 0.8; }

.legal-source {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.35);
    margin-top: 2rem;
}

.footer-links a.active {
    color: var(--green-accent);
}

@media (max-width: 768px) {
    .legal-page { padding: 1rem 1.5rem 3rem; }
    .legal-header h1 { font-size: 1.8rem; }
}

/* ===== Services – Hexagon Grid ===== */
.hex-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
}

.hex-row {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.hex-row + .hex-row {
    margin-top: -65px;
}

.hex-item {
    width: 250px;
    height: 280px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2.5rem 1.75rem;
    gap: 0.5rem;
    transition: transform 0.3s ease, background 0.3s ease;
    cursor: default;
}

.hex-item:hover {
    transform: scale(1.07);
    background: rgba(255, 255, 255, 0.15);
}

/* LIMS – Hervorgehobenes Zentrum */
.hex-item-center {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.14);
    filter: drop-shadow(0 0 20px rgba(154, 205, 50, 0.25));
}

.hex-bg-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    z-index: 0;
}

.hex-item-center:hover {
    background: rgba(255, 255, 255, 0.55);
    filter: drop-shadow(0 0 28px rgba(154, 205, 50, 0.4));
}

.hex-item-center:hover .hex-bg-img {
    opacity: 0.4;
}

.hex-item-center .hex-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.25rem;
}

.hex-item-center .hex-icon,
.hex-item-center h4,
.hex-item-center p {
    position: relative;
    z-index: 1;
    transition: color 0.4s ease;
}

.hex-item-center:hover .hex-icon {
    color: var(--green);
}

.hex-item-center:hover h4 {
    color: var(--green);
}

.hex-item-center:hover p {
    color: var(--green);
}

.hex-item h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: white;
    margin: 0;
}

.hex-item p {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    margin: 0;
    max-width: 170px;
}

/* Responsive */
@media (max-width: 900px) {
    .hex-item {
        width: 200px;
        height: 225px;
        padding: 2rem 1.25rem;
    }

    .hex-item h4 { font-size: 0.85rem; }
    .hex-item p { font-size: 0.72rem; max-width: 140px; }

    .hex-row + .hex-row { margin-top: -52px; }
}

@media (max-width: 640px) {
    .hex-row {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    .hex-row + .hex-row { margin-top: 8px; }

    .hex-item {
        width: 220px;
        height: 248px;
    }
}

.section-dark {
    background: var(--bg-dark);
    color: white;
}

.section-darker {
    background: var(--bg-darker);
    color: white;
}

.section-header {
    margin-bottom: 3.5rem;
}

.section-number {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    color: var(--green-accent);
    margin-bottom: 0.75rem;
    display: block;
}

.section-dark .section-number,
.section-darker .section-number {
    color: rgba(255,255,255,0.45);
}

.section h2 {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.section-dark h2 {
    color: white;
}

.section-desc {
    color: var(--text-secondary);
    max-width: 400px;
    font-size: 0.95rem;
}

.section-dark .section-desc,
.section-darker .section-desc {
    color: rgba(255,255,255,0.6);
}

/* Section Header - Two Columns */
.section-header-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.section-header-split p {
    color: rgba(255,255,255,0.6);
    font-size: 0.95rem;
    line-height: 1.8;
}

/* Auch den blog-view-btn color-Bug fixen */
.blog-view-btn {
    color: var(--text-primary);
}
