/* Reset und Basis */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    color: #000;
    line-height: 1.6;
    overflow-x: clip;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background-color: #fff;
    padding: 20px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-top-row {
    display: none !important;
}

.header-main-row {
    position: relative;
}

.logo {
    min-height: 120px;
    min-width: 120px;
}

.menu-toggle-checkbox {
    display: none;
}

.menu-toggle {
    display: none;
    width: 40px;
    height: 32px;
    cursor: pointer;
    flex-direction: column;
    justify-content: space-between;
}

.menu-toggle span {
    display: block;
    height: 4px;
    width: 100%;
    background-color: #000;
    border-radius: 2px;
}

nav {
    display: flex;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav a {
    text-decoration: none;
    color: #000;
    font-weight: 600;
    transition: color 0.3s;
    font-size: 1.2em;
}

nav a:hover {
    color: #0095db;
}

.phone-mobile {
    display: none;
}

.phone-desktop {
    display: flex;
}

.phone {
    font-size: 1.4em;
    font-weight: bold;
    color: #000;
    margin-left: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.phone a {
    color: #0095db;
    text-decoration: none;
    white-space: nowrap;
}

/* Hero */
#hero {
    margin-top: 176px;
}

.hero-image {
    background-image: url('images/ATEAM_Header.jpg');
    background-size: cover;
    background-position: center;
    height: 550px;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
}

.hero-image .container {
    width: 100%;
    display: flex;
    align-items: center;
    top: -80px;
    position: relative;
}

.hero-text {
    text-align: left;
    color: #fff;
    font-size: 3.6em;
    font-weight: 800;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    line-height: 1.2em;
    max-width: none;
}

.hero-text p {
    margin: 0;
    white-space: nowrap;
}

section {
    padding: 0;
}

section[id] {
    scroll-margin-top: 190px;
}

section#hero {
    padding: 0;
}

section h2 {
    margin-bottom: 20px;
    color: #0095db;
}

section p {
    margin-bottom: 20px;
}

/* Rechtstexte */
.legal-main {
    padding: 220px 0 80px;
}

.legal-content h1 {
    color: #004a8b;
    font-weight: 700;
    font-size: 2.2em;
    margin-bottom: 24px;
}

.legal-content h2 {
    color: #004a8b;
    font-size: 1.3em;
    margin-top: 28px;
    margin-bottom: 12px;
}

.legal-content p {
    color: #3c3c3b;
    margin-bottom: 12px;
}

/* Intro/Maincontent Sektion */
#intro {
    padding: 80px 0;
}

#intro h1 {
    color: #004a8b;
    font-weight: 700;
    font-size: 2.5em;
    margin-bottom: 10px;
}

#intro h3 {
    color: #004a8b;
    font-weight: 700;
    font-size: 1.3em;
    margin-bottom: 30px;
}

#intro p {
    color: #3c3c3b;
    line-height: 1.6;
    margin-bottom: 1.6em;
}

.intro-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.intro-text {
    flex: 1;
}

.intro-image {
    flex-shrink: 0;
    top: 120px;
    position: relative;
}

.heizkosten-section {
    background-color: #f4f4f8;
}

.heizkosten-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    padding: 60px 0;
}

.heizkosten-text {
    flex: 1;
}

.section-heading {
    color: #004a8b;
    font-weight: 700;
    font-size: 2.5em;
    margin-bottom: 10px;
}

#heizkosten h3 {
    color: #004a8b;
    font-weight: 700;
    font-size: 1.3em;
    margin-bottom: 0.6em;
}

.dot-list {
    list-style: disc;
    padding-left: 1.4em;
    color: #3c3c3b;
    line-height: 1.2;
}

.dot-list li {
    margin-bottom: 0.6em;
}

.heizkosten-image {
    flex-shrink: 0;
    margin-top: 2.8em;
}

.heizkosten-image img {
    display: block;
}

.grey-section {
    background-color: #f4f4f8;
    border-top: 5px solid #fff;
}

.heizkosten-content,
.nebenkosten-content,
.messtechnik-content,
.brandschutz-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    padding: 60px 0;
}

.heizkosten-text,
.nebenkosten-text,
.messtechnik-text,
.brandschutz-text {
    flex: 1;
}

#heizkosten h3,
#nebenkosten h3,
#messtechnik h3,
#brandschutz h3 {
    color: #004a8b;
    font-weight: 700;
    font-size: 1.3em;
    margin-bottom: 0.6em;
}

.nebenkosten-image,
.messtechnik-image,
.brandschutz-image,
.vorteile-image {
    flex-shrink: 0;
}

.nebenkosten-image {
    margin-top: 0.5em;
}

.messtechnik-content,
.brandschutz-content,
.vorteile-content {
    padding: 0 !important;
}

.messtechnik-text,
.brandschutz-text,
.vorteile-text {
    padding: 60px 0;
}

.messtechnik-image,
.brandschutz-image,
.vorteile-image {
    display: flex;
    align-items: center;
}

.messtechnik-image img,
.brandschutz-image img,
.vorteile-image img {
    display: block;
}

/* Vorteile Sektion */
.vorteile-section {
    background-image: url('images/ATEAM_Modul_Vorteile.jpg');
    background-size: cover;
    background-position: center;
    padding: 40px 0;
}

.vorteile-content {
    display: flex;
    gap: 40px;
    align-items: center;
    padding: 80px 0;
}

.vorteile-image {
    display: flex;
    align-items: center;
}

.vorteile-text h2 {
    color: #004a8b;
    margin-bottom: 30px;
}

.vorteile-text .dot-list li {
    font-weight: 600;
    font-size: 1.2em;
}

.vorteile-text {
    flex: 1;
}

.contact-section {
    background-color: #fff;
    padding: 0 0 60px;
}

.contact-content {
    display: flex;
    gap: 0;
    align-items: stretch;
    padding: 60px 0;
    height: 430px;
}

.contact-image {
    flex: 0 0 50%;
    max-width: 50%;
}

.contact-image img {
    display: block;
    width: 100%;
    height: 430px;
    object-fit: cover;
}

.contact-box {
    flex: 0 0 50%;
    max-width: 50%;
    height: 430px;
    background-color: #0095db;
    padding: 5px 15px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

.contact-box form {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.contact-fields {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.contact-header h2 {
    color: #fff;
    margin: 15px 0 15px;
}

.contact-box input,
.contact-box textarea {
    width: 100%;
    border: none;
    border-radius: 6px;
    padding: 15px 18px;
    margin-bottom: 20px;
    font-family: 'Open Sans', sans-serif;
    font-size: 1em;
    color: #333;
}

.contact-box input::placeholder,
.contact-box textarea::placeholder {
    color: rgba(0, 0, 0, 0.45);
}

.contact-box input:focus,
.contact-box textarea:focus {
    outline: 2px solid rgba(255, 255, 255, 0.4);
}

.contact-box input {
    height: 46px;
}

.contact-box textarea {
    resize: vertical;
}

.contact-box button {
    background-color: #5ab7e8;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 14px 0;
    font-size: 1.05em;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease;
    margin: 0 auto;
    display: block;
    width: 220px;
    bottom: 15px;
    position: relative;
}

.contact-box button:hover {
    opacity: 0.9;
}

.company-group-section {
    margin-top: 60px;
}

.company-group-bg {
    background: url('images/ATEAM_Modul_UGSchlamp_Hintergrund_mitSymbol.jpg') center / cover no-repeat;
}

.company-group-container {
    min-height: 520px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 100px 20px;
}

.company-group-label {
    text-transform: uppercase;
    color: #3c3c3b;
    font-weight: 700;
    font-size: 0.9em;
    margin: 25px 0 6px;
}

.company-group-section h2 {
    text-transform: uppercase;
    color: #004a8b;
    font-size: 2em;
    letter-spacing: 5px;
    margin: 0 0 6px;
    font-weight: 300;
}

.company-group-text {
    max-width: 900px;
    margin: 0 auto 24px;
    color: #3c3c3b;
    font-size: 1em;
    line-height: 1.7;
}

.company-group-tags {
    text-transform: uppercase;
    color: #3c3c3b;
    font-size: 0.9em;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.clsLinkUG {
    color: #0095db;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
    font-size: 1em;
    font-style: italic;
}

/* Footer */
.footer-section {
    background-color: #706f6f;
    color: #fff;
    padding: 60px 0;
}

.footer-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.footer-left,
.footer-right {
    display: flex;
    flex-direction: column;
}

.footer-left {
    flex: 0 0 40%;
    max-width: 40%;
}

.footer-right {
    flex: 0 0 60%;
    max-width: 60%;
}

.footer-left img,
.footer-right img {
    width: 100%;
    height: auto;
    margin-bottom: 24px;
}

.footer-left img {
    max-width: 110px;
}

.footer-right img {
    max-width: 436px;
}

.footer-info p,
.footer-right-info p {
    margin: 5px 0;
    color: #fff;
}

.footer-info a {
    color: #fff;
    text-decoration: none;
}

.footer-links {
    margin: 24px 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.footer-links span {
    color: #fff;
}

.footer-social {
    display: flex;
    gap: 16px;
}

.footer-social a {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.2s ease;
}

.footer-social a:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.footer-right-headline {
    text-transform: uppercase;
    font-size: 1.2em;
    letter-spacing: 2px;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 24px;
}

.footer-right-headline p {
    margin: 0;
}

.footer-right-headline a {
    color: #fff;
    text-decoration: none;
}

.footer-right-headline a:hover {
    text-decoration: underline;
}

.footer-right-info p {
    margin: 6px 0;
    color: #fff;
}

/* Menuumschaltung ab 1040px */
@media (max-width: 1040px) {
    header {
        padding: 12px 0;
    }

    .header-top-row {
        display: flex !important;
        justify-content: flex-end;
        padding-bottom: 10px;
    }

    .header-main-row {
        justify-content: space-between;
        align-items: center;
        gap: 20px;
        flex-wrap: wrap;
    }

    .phone-mobile {
        display: flex;
    }

    .phone-desktop {
        display: none;
    }

    .menu-toggle {
        display: flex;
        margin-left: auto;
    }

    .menu-toggle-checkbox {
        position: absolute;
        opacity: 0;
        pointer-events: none;
        width: 0;
        height: 0;
    }

    nav {
        display: none;
        width: 100%;
        order: 3;
    }

    #menuToggle:checked + .menu-toggle + nav {
        display: block;
    }

    nav ul {
        flex-direction: column;
        gap: 15px;
        padding: 18px 20px;
        background-color: #fff;
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        margin-top: 10px;
    }

    nav a {
        font-size: 1.08em;
        display: block;
        padding: 4px 0;
    }

    .phone {
        font-size: 1.15em;
        margin-left: 0;
    }

    .logo {
        min-height: 100px;
        min-width: 100px;
    }

    #hero {
        margin-top: 180px;
    }

    section[id] {
        scroll-margin-top: 190px;
    }
}

/* Tablet */
@media (max-width: 959px) {
    .container {
        padding: 0 18px;
    }

    .hero-image {
        height: 470px;
    }

    .hero-image .container {
        top: -40px;
    }

    .hero-text {
        font-size: 2.4em;
    }

    #intro {
        padding: 60px 0;
    }

    .intro-content,
    .heizkosten-content,
    .nebenkosten-content,
    .messtechnik-content,
    .brandschutz-content,
    .vorteile-content,
    .footer-content,
    .contact-content {
        flex-direction: column;
        gap: 28px;
    }

    .intro-image,
    .heizkosten-image,
    .nebenkosten-image,
    .messtechnik-image,
    .brandschutz-image,
    .vorteile-image {
        margin-top: 0;
        top: 0;
        justify-content: center;
        width: 100%;
    }

    .intro-image img,
    .heizkosten-image img,
    .nebenkosten-image img,
    .messtechnik-image img,
    .brandschutz-image img,
    .vorteile-image img {
        width: min(100%, 560px);
    }

    .messtechnik-text,
    .brandschutz-text,
    .vorteile-text {
        padding: 60px 0 0;
    }

    .section-heading {
        font-size: 2.1em;
    }

    .contact-content {
        height: auto;
        padding: 50px 0;
    }

    .contact-image,
    .contact-box {
        flex: 1 1 100%;
        max-width: 100%;
        height: auto;
    }

    .contact-image img {
        height: auto;
        max-height: 460px;
    }

    .contact-box {
        padding: 24px 20px;
    }

    .contact-box button {
        bottom: 0;
        margin-top: 6px;
        width: 100%;
        max-width: 320px;
    }

    .company-group-container {
        min-height: 460px;
        padding: 80px 20px;
    }

    .footer-left,
    .footer-right {
        max-width: 100%;
        flex: 1 1 100%;
    }

    .footer-left img,
    .footer-right img {
        width: 100%;
    }

    .footer-left img {
        max-width: 110px;
    }

    .footer-right img {
        max-width: 280px;
    }

    section[id] {
        scroll-margin-top: 182px;
    }
}

/* Mobile */
@media (max-width: 767px) {
    #hero {
        margin-top: 165px;
    }

    .hero-image {
        height: 390px;
    }

    .hero-image .container {
        top: -10px;
    }

    .hero-text {
        font-size: 1.95em;
        line-height: 1.2;
        max-width: none;
    }

    #intro h1 {
        font-size: 1.85em;
        line-height: 1.25;
    }

    #intro h3,
    #heizkosten h3,
    #nebenkosten h3,
    #messtechnik h3,
    #brandschutz h3 {
        font-size: 1.13em;
    }

    .section-heading {
        font-size: 1.85em;
    }

    .dot-list {
        line-height: 1.35;
    }

    .dot-list li {
        margin-bottom: 0.5em;
    }

    .contact-section {
        padding-bottom: 40px;
    }

    .contact-content {
        padding: 40px 0;
    }

    .contact-box {
        padding: 22px 18px;
    }

    .contact-box input,
    .contact-box textarea {
        margin-bottom: 12px;
        padding: 13px 14px;
    }

    .contact-box button {
        width: 100%;
    }

    .company-group-section {
        margin-top: 40px;
    }

    .company-group-container {
        min-height: 400px;
        padding: 60px 18px;
    }

    .company-group-label {
        font-size: 0.85em;
    }

    .company-group-section h2 {
        font-size: 1.55em;
        letter-spacing: 1.5px;
    }

    .company-group-text,
    .company-group-tags {
        font-size: 0.95em;
    }

    .footer-section {
        padding: 45px 0;
    }

    .footer-left img,
    .footer-right img {
        width: 100%;
    }

    .footer-left img {
        max-width: 110px;
    }

    .footer-right img {
        max-width: 436px;
    }

    .footer-left,
    .footer-right {
        align-items: center;
        text-align: center;
    }

    .footer-links,
    .footer-social {
        justify-content: center;
    }

    .footer-right-headline {
        font-size: 1.05em;
        letter-spacing: 1.3px;
    }

    section[id] {
        scroll-margin-top: 170px;
    }

    .legal-main {
        padding: 190px 0 60px;
    }
}

/* Kleine Mobile Geraete */
@media (max-width: 440px) {
    .container {
        padding: 0 14px;
    }

    header {
        padding: 10px 0;
    }

    .logo {
        min-height: 84px;
        min-width: 84px;
    }

    .menu-toggle {
        width: 34px;
        height: 26px;
    }

    .menu-toggle span {
        height: 3px;
    }

    .phone {
        font-size: 0.92em;
        gap: 7px;
    }

    #hero {
        margin-top: 148px;
    }

    .hero-image {
        height: 330px;
        background-position: 62% center;
    }

    .hero-text {
        font-size: 1.55em;
        line-height: 1.18;
        max-width: none;
    }

    #intro {
        padding: 45px 0;
    }

    #intro h1 {
        font-size: 1.55em;
    }

    #intro h3 {
        font-size: 1.02em;
        margin-bottom: 20px;
    }

    #intro p {
        margin-bottom: 1.2em;
    }

    .section-heading {
        font-size: 1.5em;
    }

    .messtechnik-text,
    .brandschutz-text,
    .vorteile-text {
        padding-top: 40px;
    }

    .contact-box {
        padding: 18px 14px;
    }

    .contact-header h2 {
        font-size: 1.35em;
        margin-top: 0;
    }

    .contact-box input,
    .contact-box textarea {
        font-size: 0.95em;
        margin-bottom: 10px;
    }

    .company-group-container {
        padding: 48px 14px;
    }

    .company-group-text {
        font-size: 0.92em;
    }

    .company-group-tags {
        font-size: 0.82em;
        line-height: 1.45;
    }

    .footer-links {
        gap: 8px;
    }

    .footer-social a {
        width: 34px;
        height: 34px;
    }

    section[id] {
        scroll-margin-top: 152px;
    }

    .legal-main {
        padding: 165px 0 48px;
    }
}
