:root {
    --blue: #00477a;
    --blue-light: #0a6ba8;
    --night: #07131f;
    --night-soft: #0c1c2b;
    --ink: #16212b;
    --muted: #66727d;
    --line: rgba(16, 35, 51, 0.12);
    --white: #ffffff;
    --offwhite: #f4f6f8;

    --container: 1240px;
    --radius-lg: 34px;
    --radius-md: 24px;
    --shadow: 0 28px 80px rgba(7, 19, 31, 0.16);
}

/* ==========================================================
   GRUNDLAGEN
========================================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    overflow-x: hidden;
    background: var(--night);
    color: var(--ink);
    font-family: "Inter", sans-serif;
    line-height: 1.6;
}

body.nav-open {
    overflow: hidden;
}

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

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    font: inherit;
}

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

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    font-family: "Manrope", sans-serif;
    letter-spacing: -0.04em;
    line-height: 1.06;
}

h1 {
    max-width: 850px;
    margin-bottom: 28px;
    color: var(--white);
    font-size: clamp(4rem, 9vw, 8.4rem);
}

h2 {
    margin-bottom: 24px;
    font-size: clamp(2.7rem, 5vw, 5.2rem);
}

h3 {
    font-size: 1.65rem;
}

.site-shell {
    width: 100%;
    overflow: hidden;
}

.container {
    width: min(calc(100% - 40px), var(--container));
    margin-inline: auto;
}

.section {
    position: relative;
    padding: 130px 0;
}

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

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

.eyebrow {
    margin-bottom: 18px;
    color: #8ac8ef;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.eyebrow-dark {
    color: var(--blue);
}

/* ==========================================================
   BUTTONS
========================================================== */

.button {
    display: inline-flex;
    min-height: 54px;
    align-items: center;
    justify-content: center;
    padding: 0 24px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.94rem;
    font-weight: 700;
    transition:
        transform 180ms ease,
        background 180ms ease,
        border-color 180ms ease,
        color 180ms ease;
}

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

.button-primary {
    background: var(--blue);
    color: var(--white);
}

.button-primary:hover {
    background: var(--blue-light);
}

.button-ghost {
    border-color: rgba(255, 255, 255, 0.35);
    background: rgba(7, 19, 31, 0.15);
    color: var(--white);
    backdrop-filter: blur(12px);
}

.button-ghost:hover {
    background: rgba(255, 255, 255, 0.1);
}

.button-light {
    background: var(--white);
    color: var(--night);
}

.button-disabled {
    background: #e7ebef;
    color: #78838d;
    cursor: not-allowed;
}

.button-disabled:hover {
    transform: none;
}

.button-disabled-dark {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.55);
}

/* ==========================================================
   HEADER
========================================================== */

.site-header {
    position: fixed;
    z-index: 1000;
    top: 0;
    right: 0;
    left: 0;
    padding: 22px 0;
    color: var(--white);
    transition:
        padding 220ms ease,
        background 220ms ease,
        box-shadow 220ms ease;
}

.site-header.is-scrolled {
    padding: 12px 0;
    background: rgba(7, 19, 31, 0.9);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(18px);
}

.header-inner,
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 13px;
}

.brand-mark {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.08);
    font-family: "Manrope", sans-serif;
    font-weight: 800;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.brand-copy strong {
    font-family: "Manrope", sans-serif;
    font-size: 0.96rem;
}

.brand-copy small {
    margin-top: 5px;
    opacity: 0.58;
    font-size: 0.7rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 0.88rem;
    font-weight: 600;
}

.main-nav a {
    opacity: 0.78;
    transition: opacity 180ms ease;
}

.main-nav a:hover {
    opacity: 1;
}

.main-nav .nav-link-muted {
    opacity: 0.48;
}

.main-nav .nav-link-button {
    padding: 11px 18px;
    border-radius: 999px;
    background: var(--blue);
    opacity: 1;
}

.nav-toggle {
    display: none;
    width: 46px;
    height: 46px;
    padding: 11px;
    border: 0;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: var(--white);
}

/* ==========================================================
   HERO

   Das eigentliche Bild wird in basis.php über
   style="background-image: url(...)" eingesetzt.
========================================================== */

.hero {
    position: relative;
    display: flex;
    min-height: 100svh;
    align-items: flex-end;
    overflow: hidden;
    isolation: isolate;
    background: var(--night);
}

.hero-media,
.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-media {
    z-index: -2;
    width: 100%;
    height: 100%;

    /* Verhindert Wiederholungen und vierfache Bilder */
    background-repeat: no-repeat !important;
    background-position: center 55%;
    background-size: cover !important;

    transform: scale(1.025);
    transform-origin: center;
}

.hero-overlay {
    z-index: -1;
    background:
        linear-gradient(
            180deg,
            rgba(7, 19, 31, 0.04) 30%,
            rgba(7, 19, 31, 0.82) 100%
        ),
        linear-gradient(
            90deg,
            rgba(4, 13, 22, 0.96) 0%,
            rgba(4, 13, 22, 0.74) 38%,
            rgba(4, 13, 22, 0.22) 72%,
            rgba(4, 13, 22, 0.08) 100%
        ),
        radial-gradient(
            circle at 76% 24%,
            rgba(0, 71, 122, 0.28),
            transparent 30%
        );
}

.hero-content {
    position: relative;
    z-index: 2;
    padding-top: 180px;
    padding-bottom: 120px;
}

.hero-text {
    max-width: 670px;
    margin-bottom: 38px;
    color: rgba(255, 255, 255, 0.76);
    font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.scroll-hint {
    position: absolute;
    z-index: 2;
    right: 7vw;
    bottom: 55px;
    display: flex;
    align-items: center;
    gap: 14px;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.75rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.scroll-hint i {
    display: block;
    width: 44px;
    height: 1px;
    background: rgba(255, 255, 255, 0.5);
}

/* ==========================================================
   UNTERNEHMEN
========================================================== */

.intro {
    overflow: hidden;
}

.split-layout {
    display: grid;
    grid-template-columns: 0.92fr 1.08fr;
    align-items: center;
    gap: 90px;
}

.section-copy .lead {
    margin-bottom: 24px;
    color: var(--ink);
    font-size: 1.28rem;
    font-weight: 600;
}

.section-copy p:not(.eyebrow):not(.lead) {
    color: var(--muted);
}

.media-stack {
    position: relative;
    min-height: 640px;
}

.media-card {
    position: absolute;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.media-card-main {
    inset: 0 0 70px 70px;
    overflow: hidden;
    background-color: var(--night-soft);

    /* company-about.webp */
    background-repeat: no-repeat !important;
    background-position: center center;
    background-size: cover !important;
}

.media-card-main::after {
    position: absolute;
    inset: 0;
    content: "";
    border-radius: inherit;
    background:
        linear-gradient(
            180deg,
            rgba(7, 19, 31, 0.02) 48%,
            rgba(7, 19, 31, 0.58) 100%
        );
    pointer-events: none;
}

.media-card-accent {
    z-index: 2;
    left: 0;
    bottom: 0;
    width: min(390px, 76%);
    padding: 28px;
    background: var(--blue);
    color: var(--white);
}

.media-card-accent span {
    display: block;
    margin-bottom: 8px;
    opacity: 0.68;
    font-size: 0.78rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.media-card-accent strong {
    font-family: "Manrope", sans-serif;
    font-size: 1.35rem;
}

/* ==========================================================
   ABSCHNITTSÜBERSCHRIFTEN
========================================================== */

.section-heading {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: end;
    gap: 80px;
    margin-bottom: 64px;
}

.section-heading h2 {
    margin-bottom: 0;
}

.section-heading > p {
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.58);
}

.section-heading-dark > p {
    color: var(--muted);
}

/* ==========================================================
   TRANSPORTLÖSUNGEN
========================================================== */

.service-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
}

.service-card {
    position: relative;
    min-height: 500px;
    overflow: hidden;
    border-radius: var(--radius-md);
    background: var(--night-soft);
}

.service-card-large {
    grid-column: span 2;
    min-height: 590px;
}

.service-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;

    background-color: var(--night-soft);
    background-repeat: no-repeat !important;
    background-position: center center;
    background-size: cover !important;

    transition: transform 600ms ease;
}

.service-card:hover .service-image {
    transform: scale(1.035);
}

.service-image::after {
    position: absolute;
    inset: 0;
    content: "";
    background:
        linear-gradient(
            180deg,
            rgba(7, 19, 31, 0.02) 25%,
            rgba(7, 19, 31, 0.94) 100%
        );
}

.service-content {
    position: absolute;
    z-index: 2;
    right: 0;
    bottom: 0;
    left: 0;
    padding: 36px;
}

.service-content span {
    color: #80c4ee;
    font-size: 0.78rem;
    letter-spacing: 0.16em;
}

.service-content h3 {
    margin: 12px 0 14px;
}

.service-content p {
    max-width: 640px;
    margin-bottom: 0;
    color: rgba(255, 255, 255, 0.66);
}

/*
   Individuelle Bildpositionen.
   Diese Werte kannst du später je Bild fein anpassen.
*/

.service-image-general {
    background-position: center 55%;
}

.service-image-cold {
    background-position: center center;
}

.service-image-special {
    background-position: center center;
}

/* ==========================================================
   AKTUELLES
========================================================== */

.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.news-card {
    display: flex;
    min-height: 340px;
    flex-direction: column;
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--white);
    transition:
        transform 180ms ease,
        box-shadow 180ms ease;
}

.news-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 55px rgba(7, 19, 31, 0.1);
}

.news-meta {
    margin-bottom: 56px;
    color: var(--blue);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.news-card h3 {
    margin-bottom: 18px;
}

.news-card p {
    color: var(--muted);
}

.news-card a {
    margin-top: auto;
    color: var(--blue);
    font-weight: 700;
}

/* ==========================================================
   KARRIERE
========================================================== */

.career {
    overflow: hidden;
    padding-top: 0;
    background: var(--offwhite);
}

.career-panel {
    display: grid;
    min-height: 610px;
    grid-template-columns: 0.9fr 1.1fr;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--blue);
    color: var(--white);
    box-shadow: var(--shadow);
}

.career-copy {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 72px;
}

.career-copy p:not(.eyebrow) {
    margin-bottom: 34px;
    color: rgba(255, 255, 255, 0.76);
}

.career-copy .button {
    align-self: flex-start;
}

.career-image {
    position: relative;
    min-width: 0;
    min-height: 610px;
    background-color: var(--night-soft);

    /* career-driver.webp */
    background-repeat: no-repeat !important;
    background-position: center center;
    background-size: cover !important;
}

.career-image::after {
    position: absolute;
    inset: 0;
    content: "";
    background:
        linear-gradient(
            90deg,
            rgba(0, 71, 122, 0.56) 0%,
            rgba(0, 71, 122, 0.16) 26%,
            transparent 58%
        );
    pointer-events: none;
}

/* ==========================================================
   PORTALE
========================================================== */

.portal-section {
    padding-top: 40px;
}

.portal-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
}

.portal-card {
    display: flex;
    min-height: 430px;
    flex-direction: column;
    justify-content: center;
    padding: 52px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--white);
}

.portal-card p:not(.eyebrow) {
    max-width: 560px;
    color: var(--muted);
}

.portal-card .button {
    align-self: flex-start;
    margin-top: 18px;
}

.portal-card-dark {
    border-color: transparent;
    background: var(--night);
    color: var(--white);
}

.portal-card-dark p:not(.eyebrow) {
    color: rgba(255, 255, 255, 0.62);
}

/* ==========================================================
   KONTAKT
========================================================== */

.contact {
    background: var(--night);
    color: var(--white);
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: end;
    gap: 60px;
}

.contact-copy p:not(.eyebrow) {
    max-width: 700px;
    color: rgba(255, 255, 255, 0.64);
    font-size: 1.12rem;
}

.contact-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
}

.text-link {
    color: rgba(255, 255, 255, 0.66);
    font-size: 0.9rem;
}

/* ==========================================================
   FOOTER
========================================================== */

.site-footer {
    padding: 34px 0;
    background: #050d15;
    color: rgba(255, 255, 255, 0.58);
}

.site-footer strong {
    color: var(--white);
}

.site-footer p {
    margin: 5px 0 0;
    font-size: 0.85rem;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    font-size: 0.82rem;
}

/* ==========================================================
   404-SEITE
========================================================== */

.error-page {
    display: grid;
    min-height: 100svh;
    place-items: center;
    padding: 40px 20px;
    background:
        radial-gradient(
            circle at 75% 20%,
            rgba(0, 71, 122, 0.32),
            transparent 35%
        ),
        var(--night);
    color: var(--white);
}

.error-page__content {
    width: min(100%, 760px);
    text-align: center;
}

.error-page__content h1 {
    margin-inline: auto;
    font-size: clamp(3rem, 9vw, 6.5rem);
}

.error-page__content p:not(.eyebrow) {
    max-width: 600px;
    margin: 0 auto 34px;
    color: rgba(255, 255, 255, 0.68);
}

/* ==========================================================
   SCROLL-ANIMATION
========================================================== */

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition:
        opacity 700ms ease,
        transform 700ms ease;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================
   TABLET
========================================================== */

@media (max-width: 1050px) {
    .main-nav {
        position: fixed;
        inset: 0;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
        padding: 90px 32px;
        background: rgba(7, 19, 31, 0.98);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-12px);
        transition:
            opacity 180ms ease,
            visibility 180ms ease,
            transform 180ms ease;
    }

    .main-nav.is-open {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .main-nav a {
        font-size: 1.35rem;
    }

    .nav-toggle {
        position: relative;
        z-index: 1001;
        display: block;
    }

    .split-layout,
    .section-heading,
    .career-panel,
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .split-layout {
        gap: 60px;
    }

    .section-heading {
        gap: 22px;
    }

    .media-stack {
        min-height: 560px;
    }

    .career-image {
        min-height: 480px;
        background-position: center center;
    }

    .career-image::after {
        background:
            linear-gradient(
                180deg,
                rgba(0, 71, 122, 0.08) 45%,
                rgba(0, 71, 122, 0.62) 100%
            );
    }
}

/* ==========================================================
   SMARTPHONE
========================================================== */

@media (max-width: 760px) {
    .container {
        width: min(calc(100% - 26px), var(--container));
    }

    .section {
        padding: 88px 0;
    }

    h1 {
        font-size: clamp(3.4rem, 16vw, 5.4rem);
    }

    h2 {
        font-size: clamp(2.4rem, 11vw, 3.6rem);
    }

    .brand-copy {
        display: none;
    }

    .hero {
        min-height: 100svh;
    }

    .hero-media {
        /*
           Auf Mobilgeräten liegt der Bildfokus etwas weiter rechts.
           Falls der LKW dadurch ungünstig sitzt, 58 % verändern.
        */
        background-position: 58% center;
        transform: scale(1.01);
    }

    .hero-overlay {
        background:
            linear-gradient(
                180deg,
                rgba(4, 13, 22, 0.28) 0%,
                rgba(4, 13, 22, 0.72) 54%,
                rgba(4, 13, 22, 0.96) 100%
            );
    }

    .hero-content {
        padding-top: 160px;
        padding-bottom: 95px;
    }

    .hero-actions,
    .hero-actions .button {
        width: 100%;
    }

    .scroll-hint {
        display: none;
    }

    .media-stack {
        min-height: 440px;
    }

    .media-card-main {
        inset: 0 0 58px 22px;
        background-position: center center;
    }

    .media-card-accent {
        width: min(330px, 88%);
        padding: 22px;
    }

    .service-grid,
    .news-grid,
    .portal-grid {
        grid-template-columns: 1fr;
    }

    .service-card-large {
        grid-column: auto;
    }

    .service-card,
    .service-card-large {
        min-height: 460px;
    }

    .service-content {
        padding: 28px;
    }

    .career-copy,
    .portal-card {
        padding: 38px 26px;
    }

    .career-image {
        min-height: 360px;

        /*
           Bei Bedarf den sichtbaren Bereich verschieben:
           0 % = ganz links
           50 % = Mitte
           100 % = ganz rechts
        */
        background-position: 62% center;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* ==========================================================
   KLEINE SMARTPHONES
========================================================== */

@media (max-width: 480px) {
    .hero-media {
        background-position: 62% center;
    }

    .media-stack {
        min-height: 390px;
    }

    .media-card-main {
        inset: 0 0 54px 14px;
    }

    .media-card-accent strong {
        font-size: 1.15rem;
    }

    .career-image {
        min-height: 310px;
        background-position: 66% center;
    }
}

/* ==========================================================
   REDUZIERTE BEWEGUNG
========================================================== */

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

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    .hero-media {
        transform: none;
    }
}
