@import url("reset.css");
@import url("font.css");

:root {
    --text: #222222;
    --primary: #252e65;
    --primary-transparent: rgba(37, 46, 101, 0.9);
    --secondary: #454f8d;
    --contrast: #4e5479;
    --grey: #f1f4f8;
    /*=============================*/
    --border-radius: 0;
    --heading-weight: 600;
    --heading-font-family: 'Titillium Web', sans-serif;
    --regular-font-family: 'Titillium Web', sans-serif;
    --regular-font-weight: 400;
}

* {
    box-sizing: border-box;
}

img {
    max-width: 100%;
}

body {
    width: 100%;
    overflow-x: hidden;
    font: var(--regular-font-weight) 16px/150% var(--regular-font-family), sans-serif;
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1 {
    font: var(--heading-weight) 300%/100% var(--heading-font-family);
    margin-bottom: 30px;
    text-transform: uppercase;
}

h2 {
    font: var(--heading-weight) 240%/100% var(--heading-font-family);
    margin-bottom: 30px;
    color: var(--primary);
    text-transform: uppercase;
}

h3 {
    font: var(--heading-weight) 140%/100% var(--heading-font-family);
    margin-bottom: 10px;
    color: var(--primary);
    text-transform: uppercase;
}

p~h2,
p~h3{
    margin-top: 30px;
}

p~h4,
p~h5,
p~h6 {
    margin-top: 20px;
}

h4 {
    font: var(--heading-weight) 125%/100% var(--heading-font-family);
    margin-bottom: 10px;
    text-transform: uppercase;
    color: var(--primary)
}

h5 {
    font: var(--heading-weight) 120%/100% var(--heading-font-family);
    margin-bottom: 10px;
}

h6 {
    font: var(--heading-weight) 110%/100% var(--heading-font-family);
    margin-bottom: 10px;
}

small {
    font-size: 50%;
    font-family: var(--regular-font-family);
    font-weight: var(--regular-font-weight);
    text-transform: uppercase;
    display: inline-block;
    line-height: 120%;
}

p {
    margin-bottom: 10px;
}

a {
    text-decoration: none;
    transition: 0.3s;
}

a:hover {
    opacity: 0.5;
}

.dsa-secure-plugin a:hover {
    opacity: 1;
}

nav {
    z-index: 999;
    position: fixed;
    top: 0;
    background-color: var(--primary);
    width: 100%;
    box-sizing: border-box;
    text-align: center;
}

nav .container {
    padding-top: 20px;
    padding-bottom: 20px;
}

.logo{
    max-width: 145px;
    position: absolute;
    top: 0;
}

nav .span {
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    position: fixed;
    display: none;
    height: 44px;
    width: 55px;
    padding: 10px;
}

nav .span div {
    width: 100%;
    border-bottom: 3px solid #fff;
}

button,
.btn {
    border: none;
    background-color: var(--primary);
    color: #fff;
    padding: 8px 20px;
    margin-top: 15px;
    text-decoration: none;
    display: inline-block;
    border-radius: var(--border-radius);
    font-size: 100%;
    font-weight: var(--heading-weight)
}

button:hover {
    cursor: pointer;
}

.desktop-nav {
    width: 100%;
    padding: 10px 5%;
    text-align: right;
}

.desktop-nav a {
    padding: 0 10px;
    color: #fff;
    text-transform: uppercase;
}

.overlay {
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    background-color: var(--primary);
    background-color: var(--primary-transparent);
    overflow-x: hidden;
    transition: 0.5s;
}

.overlay-content {
    position: relative;
    top: 25%;
    width: 100%;
    text-align: center;
    margin-top: 30px;
}

.overlay a {
    padding: 12px;
    text-decoration: none;
    font-size: 150%;
    color: #fff;
    display: block;
}

.overlay .closebtn {
    position: absolute;
    font-size: 60px;
}

.overlay .closebtn,
nav .span {
    top: 20px;
    right: 5%;
}

.overlay a.closebtn {
    font-weight: 300;
}

.cursor {
    cursor: pointer;
}

.dse {
    font-size: 80%;
    text-align: center;
    position: fixed;
    bottom: 5px;
    right: 5%;
    background-color: var(--contrast);
    border-radius: var(--border-radius);
    color: #fff;
    width: 290px;
    padding: 5px;
}

.dsa-cookie-notice {
    border-radius: var(--border-radius);
}

.dse a {
    color: #fff;
}

article {
    width: 100%;
}

.container {
    padding: 100px 10%;
}

.flexbox {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.col-2 {
    width: 48%;
}

.col-3 {
    width: 33%;
}

.col-4 {
    width: 24%;
}

.col-5 {
    width: 19%;
}

.text-col {
    padding: 30px 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.img-col img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    border-radius: var(--border-radius);
}

.no-header .section-5 .container{    
    padding: 180px 10%;   
}

.no-header .section-5 .container h1,
.no-header .section-5 .container h2 {    
    width: 100%; 
}

header {
    width: 100%;
    min-height: 70vh;
    background: url('../images/verein-fuer-existenzsicherung-ev.jpg') no-repeat center/cover;    
    display: flex;
    align-items: flex-end;
    justify-content: center;
    margin-top: 80px;
    position: relative;
}

header:before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 0;
    mix-blend-mode: multiply;
    background-color: #62667e;
}

header .container {    
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    color: #fff;
    position: relative;
    z-index: 1;
}

header h1 {
    color: #fff;    
    max-width: 1220px;
}

header h2{
    color: #fff;
    font-size: 150%;
}

header b {
    color: #fff;
}

.intro-box{
    background-color: var(--secondary);
    padding: clamp(20px, 5%,60px);
    max-width: 700px;
}

article:nth-of-type(odd) {
    background-color: var(--grey);
}

article:nth-of-type(even) {
    background-color: #fff;
}

.section-intro {
    text-align: center;
    max-width: 1024px;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pic-boxes .col {
    background-color: var(--grey);
}

.pic-boxes h3 {   
    margin-bottom: 20px;
}

.picture-box {
    aspect-ratio: 7/4;
}

.text-box {
    padding: 20px;
}

.picture-box img {
    width: 100%;
    border-radius: var(--border-radius);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

article ul {
    margin-left: 2px;
    margin-bottom: 16px;
}

article ul li {    
    margin-bottom: 5px;
    display: flex;
    align-items: flex-start;
}

article ul li::before {
    content: '';
    display: block;
    position: relative;
    bottom: -5px;
    flex-shrink: 0;
    height: 14px;
    width: 10px;
    margin-right: 7px;
    background: url('../images/list.png') no-repeat center/contain;
}

b {
    font-weight: 700;
    color: var(--primary)
}

.highlight {
    font-style: italic;
    color: var(--primary);
    font-size: 115%;
    line-height: 160%;
    margin-bottom: 20px;
}

article.alternate,
.alternate{
    background-color: var(--primary);
    color: #fff;
}

article.alternate h2,
.alternate h2,
article.alternate h3,
.alternate h3{
    color: #fff;
}

.parent {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 1fr);
    grid-column-gap: 20px;
    grid-row-gap: 20px;
}

.small-child {
    background-color: var(--contrast);
    padding: clamp(20px, 5%, 60px);
}

.child-1 {
    grid-area: 1 / 1 / 3 / 3;
}

.child-2 {
    grid-area: 1 / 3 / 2 / 4;
}

.child-2:before,
.child-3:before,
.child-4:before,
.child-5:before{
    display: block;
    height: 42px;
    width: 42px;
    margin-bottom: 30px;    
}

.child-2:before {
    content: '';
    background: url('../images/icon-erfahrung-und-expertise.png') no-repeat center/ contain;    
}

.child-3 {
    grid-area: 1 / 4 / 2 / 5;
}

.child-3:before {
    content: '';
    background: url('../images/icon-individuelle-betreuung.png') no-repeat center/ contain;    
}

.child-4 {
    grid-area: 2 / 3 / 3 / 4;
}

.child-4:before {
    content: '';
    background: url('../images/icon-diskretion-und-vertrauen.png') no-repeat center/ contain;
}

.child-5 {
    grid-area: 2 / 4 / 3 / 5;
}

.child-5:before {
    content: '';
    background: url('../images/icon-erfolgsorientiert.png') no-repeat center/ contain;
}

article.so-funktioniert-es{
    background-color: var(--grey)
}

.number-boxes{
    margin-top: 40px;
}

.number-boxes .col{
    position: relative;
    text-align: center;
    background-color: #fff;
    padding: 30px 20px 20px 20px;
}

.number-boxes .col:before{
    content: '';
    position: absolute;
    display: block;
    height: 33px;
    width: 48px;
    top: -34px;
    left: calc(50% - 30px);
    background-color: var(--primary);
    border-radius: 100px;
    overflow: hidden;
    color: #fff;
    font-size: 29px;
    line-height: 29px;
    padding: 17px 10px;
}

.number-boxes .col:nth-of-type(1):before{
    content: '1';
}

.number-boxes .col:nth-of-type(2):before{
    content: '2';
}

.number-boxes .col:nth-of-type(3):before{
    content: '3';
}

.number-boxes .col:nth-of-type(4):before{
    content: '4';
}

/*-------- KONTAKT -------*/

article.kontakt{
    background-color: #fff;
}

article.kontakt .col-2{
    width: 50%;
}

.kontakt .flexbox {
    flex-wrap: nowrap;
}

.kontakt .contactblock {
    margin-top: 100px;
}

.kontaktformular {
    width: 100%;
    height: 800px;
}

.kontakt .infos {
    margin-top: 20px;
}

.kontakt .col-3 {
    background-color: var(--grey);
    padding: 20px;
    position: relative;
    display: flex;
}

.kontakt h4{
    width: calc(100% - 40px);
}

.kontakt .col-3::before{
    content: '';
    position: relative;
    bottom: -4px;
    margin-right: 7px;
    display: block;
    flex-shrink: 0;
    height: 15px;
    width: 17px;
}

.kontakt .col-3:nth-of-type(1)::before{
    background: url('../images/icon-nav.png') no-repeat center/contain;
}

.kontakt .col-3:nth-of-type(2)::before{
    background: url('../images/icon-phone.png') no-repeat center/contain;
}

.kontakt .col-3:nth-of-type(3)::before{
    background: url('../images/icon-envelope.png') no-repeat center/contain;
}

.kontakt .col-3 a {
    color: var(--text)
}

/*------ FOOTER ------*/

footer {
    background-color: var(--primary);
    color: #fff;
}

footer h3 {
    color: #fff;
}

footer ul {
    list-style: disc;
    margin-left: 15px;
}

footer p a,
footer ul li a {
    color: #fff;
    text-decoration: underline;
}

footer b {
    color: #fff;
}

.sidenav {
    position: fixed;
    right: 5px;
    top: 30%;
    z-index: 9999;
}

.sidenav a,
.sidenav button {
    display: block;
    height: 60px;
    width: 60px;
    background-color: var(--primary);
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    padding: 15px;
    margin-top: 0;
}

.sidenav img {
    height: 100%;
}

.infosite h1 {
    flex-basis: 100%;
}

.infosite .container {
    align-items: flex-start;
}

article p a,
article ul li a {
    color: var(--primary);
    text-decoration: underline;
}

.kontaktformular h4 {
    text-align: center;
    margin-top: 20px;
}

.kontaktformular h5 {
    text-align: center;
    margin-top: 20px;
}

.fehlerseite ul li {
    list-style: none;
}

@media screen and (max-width: 1800px) {
    .col-4 {
        width: 49%;
        margin-bottom: 2%;
    }

    .col-5 {
        width: 32%;
        margin-bottom: 2%;
    }

    .section-7 .flexbox {
        justify-content: center;
        gap: 2%;
    }

    .kontakt .infos{
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .kontakt .infos .col-3{
        width: 48%;
        margin-bottom: 2%;
    }
}

@media screen and (max-width: 1450px) {
    .col-1-3 {
        width: 40%;
    }

    .col-2-3 {
        width: 60%;
    }

    .logo {
        max-width: 105px;
    }

    nav {
        height: 80px;
    }

    nav .span {
        display: flex;
        right: 10%;
    }

    .desktop-nav {
        display: none;
    }
}

@media screen and (max-width: 1300px){
    .parent {        
        grid-template-columns: 1fr 1fr; /* 2 gleich breite Spalten */
        grid-template-rows: auto 1fr 1fr; /* 1. Reihe auto, 2.+3. gleich hoch */
        gap: 20px; /* Optional: Abstand zwischen den Elementen */
      }
      
      .child-1 {
        grid-area: unset;
        grid-column: 1 / 3; /* Nimmt beide Spalten ein (von 1 bis 3) */
        grid-row: 1; /* Erste Reihe */
      }
      
      .child-2 {
        grid-area: unset;
        grid-column: 1;
        grid-row: 2;
      }
      
      .child-3 {
        grid-area: unset;
        grid-column: 2;
        grid-row: 2;
      }
      
      .child-4 {
        grid-area: unset;
        grid-column: 1;
        grid-row: 3;
      }
      
      .child-5 {
        grid-area: unset;
        grid-column: 2;
        grid-row: 3;
      }
    
}

@media screen and (max-width: 1200px){
    .kontakt .infos .col-3{
        width: 32%;
    }

    .section-7 .flexbox{
        flex-wrap: wrap;
    }

    article.kontakt .col-2 {
        width: 100%;
    }
}

@media screen and (max-width: 1024px) {   
    .col-2 {
        width: 100%;
        margin-bottom: 20px;
    }

    .col-3 {
        width: 100%;
        margin-bottom: 20px;
    }

    .container {
        padding: 50px 5%;
    }

    .text-col {
        padding: 20px 0 0 0;
    }

    .sidenav {
        top: auto;
        bottom: 50px;
    }

    .sidenav a,
    .sidenav button {
        height: 45px;
        width: 45px;
        padding: 11px;
    }

    .col-5 {
        width: 49%;
    }

    .logoline {
        height: 120px;
    }    

    .no-header .section-5 .container{    
        padding: 130px 10%;   
    }
}

@media screen and (max-width: 830px) {   
    .kontakt .infos .col-3{
        width: 48%;
    }
}

@media screen and (max-width: 700px) {
    .col-4 {
        width: 100%;
        margin-bottom: 20px;
    }

    h1,
    h2 {
        font: var(--heading-weight) 190%/100% var(--heading-font-family);
        margin-bottom: 10px;
    }

    h3 {
        font-size: 150%;
    }

    h4 {
        font-size: 120%;
    }

    .logoline {
        height: 100px;
    }

    .kontakt .col-1-3,
    .kontakt .col-2-3 {
        width: 100%;
    }
}

@media screen and (max-width: 650px) {
    .parent {        
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr 1fr 1fr, 1fr;
        gap: 10px;
      }
      
      .child-1 {
        grid-column: 1; /* Nimmt beide Spalten ein (von 1 bis 3) */
        grid-row: 1; /* Erste Reihe */
      }
      
      .child-2 {
        grid-column: 1;
        grid-row: 2;
      }
      
      .child-3 {
        grid-column: 1;
        grid-row: 3;
      }
      
      .child-4 {
        grid-column: 1;
        grid-row: 4;
      }
      
      .child-5 {
        grid-column: 1;
        grid-row: 5;
      }

      header {
        margin-top: 50px;
    }
}

@media screen and (max-width: 600px) {
    .col-5 {
        width: 100%;
    }

    .kontakt .infos .col-3{
        width: 100%;
    }

    .overlay .closebtn, nav .span {
        top: 10px;
        right: 5%;
    }

    nav {
        height: 60px;
    }

    .logo {
        max-width: 75px;
    }
}

/* When the height of the screen is less than 450 pixels, change the font-size of the links and position the close button again, so they don't overlap */
@media screen and (max-height: 450px) {
    .overlay a {
        font-size: 20px
    }

    .overlay .closebtn {
        font-size: 40px;
        top: 15px;
        right: 35px;
    }
}