/* Base Styles & Fonts */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&family=Open+Sans:ital,wght@0,400;0,600;1,400&display=swap');

:root {
    --primary-color: #2c4672;
    --secondary-color: #045575;
    --text-color: #444;
    --bg-color: #fff;
    --light-bg: #f9f9f9;
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--text-color);
    margin: 0;
    padding: 0;
    background-color: var(--light-bg);
}

h1, h2, h3, h4, h5 {
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-color);
    font-weight: 600;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Background layout */
.cm-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    background-image: url('assets/background.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    opacity: 0.2; /* To tone it down, assuming it's an overlay */
}

/* Wrapper */
.page_wrapper {
    background-color: #ffffff;
    max-width: 1400px;
    margin: 0 auto;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
    position: relative;
    z-index: 1;
}

/* Header & Nav */
.head_wrapper {
    padding: 20px 40px;
    background-color: #fff;
}

.content_center {
    max-width: 1200px;
    margin: 0 auto;
}

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

.cm-logo img {
    max-height: 80px;
    width: auto;
}

nav.navigation_wrapper > ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 20px;
}

nav.navigation_wrapper li {
    position: relative;
}

nav.navigation_wrapper a {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    color: var(--text-color);
    text-transform: uppercase;
    font-size: 14px;
    padding: 10px;
    display: block;
}

nav.navigation_wrapper a:hover,
nav.navigation_wrapper li.cm_current > a {
    color: var(--primary-color);
    text-decoration: none;
}

/* Dropdown */
.cm_subnavigation {
    display: none !important;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fff;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    min-width: 250px;
    z-index: 100;
}

li.cm_has_subnavigation:hover .cm_subnavigation {
    display: flex !important;
}

.cm_subnavigation li {
    border-bottom: 1px solid #eee;
}

/* Keyvisual */
.keyvisual_wrapper {
    width: 100%;
    overflow: hidden;
}

#keyvisual img {
    width: 100%;
    height: auto;
    display: block;
}

/* Content Area */
.content_wrapper {
    padding: 40px;
}

.cm_column_wrapper {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    margin: 0;
}

.cm_column {
    flex: 1 1 0% !important;
    width: auto !important;
    max-width: 100% !important;
    margin: 0 10px;
    padding: 0;
}

.cm_column_gap {
    display: none !important;
}

.cm-widget-button_2 {
    display: inline-block;
    padding: 15px 30px;
    background-color: var(--primary-color);
    color: #fff !important;
    text-align: center;
    border-radius: 4px;
    font-weight: 600;
    transition: background 0.3s;
}

.cm_widget_block_center {
    text-align: center;
}

.cm-widget-button_2:hover {
    background-color: var(--secondary-color);
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* Ensure Team Portraits have a consistent uniform size, and don't over-stretch in half-empty rows */
.cm_column img[src^="assets/B92A"],
.cm_column img[src^="assets/IMG_"],
.cm_column img[src^="assets/content_platzhalter"] {
    aspect-ratio: 2 / 3;
    object-fit: cover;
    width: 100%;
    max-width: 280px; /* Prevent single items from blowing up to fill the whole screen */
    border-radius: 4px; /* Optional, for cleaner uniform look */
}

/* Scaled down Broschüren images */
img[src^="assets/Brosch"],
img[src*="informationsbrosch"] {
    max-width: 75% !important;
    display: block;
    margin: 0 auto;
}

/* Separating Line Widgets with Icons */
.cm-widget_separatingline.cm-w_sl-icon {
    display: flex;
    align-items: center;
}
.cm-w_sl-straight {
    flex-grow: 1;
    height: 1px;
    background-color: currentColor;
}
.cm-w_sl-icon i.fa {
    margin: 0 15px;
}
.cm-w_sl-i40 i.fa {
    font-size: 40px;
}

/* Sidebars / Additional Content Areas */
.sidebar_wrapper_top, .sidebar_wrapper_bottom_background {
    padding: 40px;
    background-color: #f4f6f9;
}

.sidebar_wrapper_bottom_background h2 {
    font-size: 18px;
    margin-bottom: 10px;
}

/* Footer */
.footer_wrapper {
    background-color: var(--primary-color);
    color: #fff;
    padding: 20px 40px;
    text-align: center;
}

.footer_wrapper a {
    color: #fff;
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--primary-color);
    color: white;
    padding: 20px;
    z-index: 9999;
    display: flex;
    justify-content: center;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
}

.cookie-content {
    max-width: 800px;
    text-align: center;
}

.cookie-content h3 {
    margin-top: 0;
    color: #fff;
}

.cookie-content button {
    background-color: #fff;
    color: var(--primary-color);
    border: none;
    padding: 10px 20px;
    margin-top: 10px;
    cursor: pointer;
    font-weight: bold;
    border-radius: 4px;
}

/* Mobile Nav */
.toggle_navigation {
    display: none;
    cursor: pointer;
}

.hamburger-box {
    width: 30px;
    height: 24px;
    display: inline-block;
    position: relative;
}

.hamburger-inner, .hamburger-inner::before, .hamburger-inner::after {
    width: 30px;
    height: 3px;
    background-color: var(--primary-color);
    position: absolute;
    transition: transform 0.15s ease;
}

.hamburger-inner::before, .hamburger-inner::after {
    content: "";
    display: block;
}

.hamburger-inner::before {
    top: -10px;
}

.hamburger-inner::after {
    bottom: -10px;
}

.mobile_navigation {
    display: none;
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background-color: #fff;
    z-index: 1000;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.mobile_navigation ul {
    flex-direction: column;
}

.mobile_navigation .cm_subnavigation {
    position: static;
    display: block;
    box-shadow: none;
    padding-left: 20px;
}

@media (max-width: 900px) {
    #main_nav {
        display: none;
    }
    .toggle_navigation {
        display: block;
    }
    .cm_column_wrapper {
        flex-direction: column;
    }
    .cm_column {
        width: 100% !important;
        margin-bottom: 20px;
    }
    .flexbox_container {
        flex-wrap: wrap;
    }
}
