/*=====================================================================================================================
    Globales Design
=====================================================================================================================*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Google Sans", sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

h1, h2, h3 {
    color: #4671b4;
    margin-bottom: 15px;
}

h1 {
    font-size: 1.8rem;
    border-left: 5px solid #4671b4;
    padding-left: 15px;
}


h2 {
    font-size: 1.4rem;
    margin-top: 10px;
}

main a {
    text-decoration: none;
    color: #4671b4;
    position: relative;
    z-index: 1;
    display: inline-block;
}

main a:hover{
    text-decoration: underline;
}

/* --- HEADER & NAVIGATION --- */
header {
    background-color: #ffffffb6;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);

    backdrop-filter: blur(10px); /* Glas-Effekt: verschwimmt den Hintergrund */
    -webkit-backdrop-filter: blur(10px);

}

.responsive-img {
    max-width: 300px;
    height: auto;
}

/*=====================================================================================================================
    Nav
=====================================================================================================================*/

nav {
    background-color: #ffffffb6;
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-radius: 0 0 50px 50px;
    box-shadow: 0 10px 15px -10px rgba(0, 0, 0, 0.1);

    backdrop-filter: blur(10px); /* Glas-Effekt: verschwimmt den Hintergrund */
    -webkit-backdrop-filter: blur(10px);
}

nav a {
    text-decoration: none;
    color: #30283a;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 8px 15px;
    border-radius: 20px;
    transition: all 0.3s ease;
    background-color: rgba(70, 113, 180, 0.075);
    margin-top: 5px;
}


nav a:hover {
    color: #4671b4;
    background-color: rgba(70, 113, 180, 0.2);
    transform: scale(1.07);
}

nav a:active {
    color: #4671b4;
    background-color: rgba(70, 113, 180, 0.1);
    transform: scale(1.07);
}

/*=====================================================================================================================
    Projekt Container
=====================================================================================================================*/

@media (max-width: 500px) {
    .projekt-container {
        margin-left: 0.5rem !important;
        margin-right: 0.5rem !important;
        margin-bottom: 4rem;
        padding: 1rem 1rem !important;
    }

    h1{
        border-left: none;
        text-align: center;
    }
}

/* --- MAIN LAYOUT --- */
main {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
    animation: fadeIn 0.8s ease-in-out;
}

/* --- PROJEKT CONTAINER --- */
.projekt-container {
    background: #fff;
    padding: 3rem;
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    margin-bottom: 3rem;
    
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start; 
    min-height: 100px;
    text-align: left;
    overflow: hidden;

    
}

.projekt-container > *:last-child {
    margin-bottom: 0 !important;
}

.projekt-container img[src*="Gaulhofer_Logo"] {
    /* Das Bild ist maximal 300px groß, aber NIEMALS breiter als der Container */
    max-width: 100%; 
    width: 300px; 
    height: auto;
    display: block;
    margin: 20px auto;
    object-fit: contain; 
}

.projekt-container img[src*="Images/Logo/Design ohne Titel (42).png"] {
    border-radius: 50px;
    height: auto;
    width: 100%;
    margin-top: 20px;
}

.projekt {
    display: flex;
    justify-content: flex-start;
}

/*=====================================================================================================================
    Listen und Tabellen
=====================================================================================================================*/

/* --- LISTEN & TABELLEN --- */
ul {
    list-style: none;
    margin: 15px 0;
    width: 100%; /* Nimmt verfügbaren Platz ein */
    max-width: 100%; /* Verhindert Überlaufen */
}

li {
    padding: 10px 0;
    border-bottom: 1px solid #f1f1f1;
    position: relative;
    padding-left: 25px;
    word-wrap: break-word; /* Verhindert, dass langer Text ausbricht */
    overflow-wrap: break-word;
}

li::before {
    content: "•";
    color: #4671b4;
    font-weight: bold;
    position: absolute;
    left: 5px;
}

li:last-child {
    border-bottom: none;
}

/* --- TABELLEN LOGIK --- */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    margin-bottom: 15px; 
    font-size: 1rem;
}

table:last-child {
    margin-bottom: 0;
}

td {
    padding: 12px 5px;
    border-bottom: 1px solid #f1f1f1;
}

td:last-child {
    text-align: right;
    font-weight: bold;
    color: #4671b4;
}

@media (max-width: 400px) {
    table {
        font-size: clamp(0.6rem, 4vw, 0.9rem);
    }
    
    td {
        padding: 8px 3px;
    }
}

/* --- BILDER GALERIE (ROWS) --- */
.row {
    display: flex;
    flex-direction: column;
    background: #fff;
    margin-bottom: 40px;
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.row img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
    cursor: pointer;
}

.row img:hover {
    transform: scale(1.07);
}

.img-box img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.text-box {
    padding: 20px;
    text-align: center;
    font-weight: 500;
    color: #444;
}

/* --- KONTAKTFORMULAR --- */
.kontakt-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 20px;
}

.form-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.form-group {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 250px;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.form-group input, 
.form-group textarea {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-family: inherit;
    transition: border-color 0.3s ease;
    background-color: #fcfcfc;
}

.form-group input:focus, 
.form-group textarea:focus {
    outline: none;
    border-color: #4671b4;
}

.form-group input::placeholder, 
.form-group textarea::placeholder {
    color: #888;
    font-size: 0.95rem;
}

.form-group input:focus::placeholder, 
.form-group textarea:focus::placeholder {
    color: #ccc;
}

.submit-btn {
    background-color: #4671b4;
    color: white;
    padding: 15px 25px;
    border: none;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    align-self: flex-start;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.submit-btn:hover {
    background-color: #35568a;
    transform: translateY(-2px);
}

.kontakt-link {
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
    text-decoration: none;
}








/* --- SLIDER --- */
.slider {
    width: 100%;
    height: auto;
    margin: auto;
    overflow: hidden;
    position: relative;
}

.slide-track {
    display: flex;
    width: calc(250px * 8);
    animation: scroll 17s linear infinite;
}

.slide {
    width: 250px;
    height: 180px;
    padding: 10px;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Ergänze diesen Teil für den Link */
.slide a {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 20px; /* Gleicher Radius wie das Bild */
    overflow: hidden;    /* Zwingt den Inhalt in die Rundung */
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    display: block; /* Verhindert kleine Abstände unter dem Bild */
}






/* --- LEISTUNGEN GRID --- */
.leistungen-grid {
    display: grid;
    grid-template-columns: 1fr; 
    gap: 30px;
    margin-top: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.leistung-box {
    background: #fcfcfc;
    padding: 20px;
    border-radius: 40px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border: 1px solid #4670b412;
    width: 100%;
    box-sizing: border-box;
    
    /* NEU: Macht die Box zum Bezugspunkt für die Schriftgröße */
    container-type: inline-size; 
}

.leistung-box p {
    /* ERKLÄRUNG:
       1. 0.9rem: Mindestgröße (damit es lesbar bleibt)
       2. 4cqw: Passt sich der Breite der Box an (4% der Boxbreite)
       3. 1.2rem: Maximalgröße für große Monitore
    */
    font-size: clamp(0.9rem, 4cqw, 1.2rem);
    
    line-height: 1.5;
    margin: 0;
    
    /* Verhindert, dass lange Wörter die Box sprengen */
    hyphens: auto; 
    word-wrap: break-word;
    overflow-wrap: break-word;
}









/* Container & Basis */
.job-container {
    max-width: 850px;
    margin: 50px auto;
    padding: 0 20px;
}

.job-dropdown {
    background: #ffffff;
    border-radius: 50px;
    margin-bottom: 20px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.03);
    transition: box-shadow 0.3s ease;
    display: block;
    overflow: hidden;
}

.job-dropdown:hover {
    box-shadow: 0 12px 35px rgba(70, 113, 180, 0.12);
}

/* Header / Summary */
.job-dropdown summary {
    list-style: none;
    padding: 30px 40px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    outline: none;
    user-select: none;
}

.job-dropdown summary::-webkit-details-marker {
    display: none;
}

.job-title {
    font-weight: 700;
    font-size: 1.25rem;
    color: #4671b4;
}

/* Der schlichte Pfeil */
.job-dropdown summary i {
    transition: transform 0.3s ease-in-out;
    color: #4671b4;
    font-size: 1.2rem;
}

.job-dropdown[open] summary i {
    transform: rotate(180deg);
}

/* --- DIE ANIMATION (0.3s Aufrollen) --- */
.job-dropdown .content-wrapper {
    display: grid;
    grid-template-rows: 0fr; /* Geschlossen */
    transition: grid-template-rows 0.3s ease-in-out;
}

.job-dropdown[open] .content-wrapper {
    grid-template-rows: 1fr; /* Offen */
}

.job-content-inner {
    overflow: hidden; /* Verhindert, dass Text während der Animation herausragt */
}

/* Text-Inhalt Styling */
.job-content {
    padding: 20px 45px 40px 45px; /* Viel Abstand für modernen Look */
    line-height: 1.7;
    color: #4a4a4a;
    border-top: 1px solid #f0f0f0; /* Dezente Trennung zum Titel */
}

.job-content h3 {
    margin: 25px 0 10px 0;
    color: #333;
    font-size: 1.1rem;
    font-weight: 600;
}

.job-content ul {
    padding-left: 20px;
    margin-bottom: 0;
}

.job-content li {
    margin-bottom: 8px;
}







/* --- BUTTONS --- */
.button-container {
    text-align: center;
    margin-top: 25px;
    align-items: center;
}

.btn-secondary {
    display: inline-block;
    padding: 12px 25px;
    background-color: transparent;
    color: #4671b4;
    border: 2px solid #4671b4;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background-color: #4671b4;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(70, 113, 180, 0.2);
    text-decoration: none;
}












/* --- FOOTER & SOCIAL --- */
footer {
    background-color: #fff;
    padding: 40px 20px;
    text-align: center;
    border-top: 1px solid #eee;
    margin-top: 60px;
    border-radius: 50px 50px 0 0;
    box-shadow: 0 10px 15px 10px rgba(0, 0, 0, 0.1);

}

.footer-link {
    color: #4671b4;
    text-decoration: none;
    font-weight: bold;
}

.footer-link:hover {
    text-decoration: underline;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 25px 0;
}

.social-icons a {
    text-decoration: none;
    color: #4671b4;
    font-size: 1.5rem;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #4671b4;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background-color: #4671b4;
    color: white;
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 5px 15px rgba(70, 113, 180, 0.3);
}

.copyright {
    font-size: 0.8rem;
    color: #888;
    margin-top: 20px;
    text-decoration: none !important;
}

.copyright:hover,
.copyright:focus,
.copyright:active,
.copyright:visited {
    text-decoration: none !important;
}














/* --- ANIMATIONEN --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-250px * 4)); }
}

/* --- MEDIA QUERIES (RESPONSIVE) --- */
@media (max-width: 600px) {
    nav {
        flex-wrap: wrap;
        gap: 5px;
    }
    nav a {
        font-size: 0.8rem;
        padding: 5px 10px;
    }
}

@media (min-width: 600px) {
    .leistungen-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .row {
        flex-direction: row;
        align-items: center;
        min-height: 300px;
    }

    .row:nth-child(even) {
        flex-direction: row-reverse;
    }

    .img-box {
        flex: 1;
        max-width: 50%;
        height: 350px;
        overflow: hidden;
    }

    .img-box img {
        height: 100%;
    }

    .text-box {
        flex: 1;
        padding: 40px;
        text-align: left;
    }
}

@media (min-width: 900px) {
    .leistungen-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}














/* --- DSGVO COOKIE BANNER --- */
#cookie-banner {
    display: none; /* Wird per JS auf 'flex' gesetzt */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5); 
    backdrop-filter: blur(8px);    
    z-index: 9999;
    justify-content: center;
    align-items: flex-end;     
    padding-bottom: 40px; 
    padding-left: 20px;
    padding-right: 20px;
}

.cookie-box {
    background: #fff;
    max-width: 500px;
    width: 100%;
    border-radius: 50px; /* Deine gewünschten abgerundeten Ecken */
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    animation: slideInUp 0.5s ease-out;
}

@keyframes slideInUp {
    from { transform: translateY(100px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* --- BUTTON LAYOUT LOGIK --- */
.cookie-buttons {
    display: flex;
    /* MOBILE FIRST: Untereinander stapeln */
    flex-direction: column-reverse; /* Dreht die Reihenfolge um: Ablehnen nach unten */
    gap: 12px;
    margin-top: 20px;
}

@media (min-width: 600px) {
    .cookie-buttons {
        /* DESKTOP: Nebeneinander */
        flex-direction: row; 
        justify-content: space-between;
        gap: 20px;
    }
    
    .cookie-box button {
        flex: 1; /* Beide Buttons gleich breit auf Desktop */
    }

    /* Auf Desktop soll Ablehnen links und Akzeptieren rechts sein */
    #decline-cookies {
        order: 1;
    }
    #accept-cookies {
        order: 2;
    }
}

/* --- BUTTON STYLING --- */
.cookie-box button {
    padding: 14px 25px;
    border-radius: 25px;
    font-weight: bold;
    font-family: inherit;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

#accept-cookies { 
    background-color: #4671b4; 
    color: white; 
}

#accept-cookies:hover {
    background-color: #35568a;
    transform: scale(1.03);
}

.btn-outline { 
    background-color: #f1f1f1; 
    color: #333; 
}

.btn-outline:hover {
    background-color: #e0e0e0;
    transform: scale(1.03);
}













/* --- JOB ALERT --- */
#job-alert {
    font-family: "Google Sans", sans-serif;
    display: none; 
    background-color: #2c3e50;
    color: #ffffff;
    text-align: center;
    padding: 10px;
    position: relative;
    width: 100%;
    z-index: 1000;
    box-sizing: border-box;
}

#job-alert p {
    margin: 0;
    display: inline-block;
    font-size: 16px;
}

#job-alert a {
    color: #4671b4; 
    text-decoration: none;
    font-weight: bold;
    border-bottom: 1px solid #4671b4;
    margin-left: 5px;
    cursor: pointer;
    transition: color 0.2s ease, border-bottom-color 0.3s ease;
}

#job-alert a:hover {
    color: #81c784;
    border-bottom-color: #81c784;
}

#close-job-alert {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: white;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    padding: 0 10px;
    transition: color 0.4s ease;
}

#close-job-alert:hover {
    color: #e74c3c;
}

@media (max-width: 600px) {
    #job-alert {
        padding: 15px 40px 15px 15px;
    }
    #job-alert p {
        display: block;
    }
    #job-alert a {
        display: block;
        margin-left: 0;
        margin-top: 1px;
        border-bottom: none;
        color: #4671b4;
    }
}

.Details {
    text-decoration: none;
    color: #4671b4;
    padding-bottom: 2px;
}








/* --- MODAL STYLES --- */
.modal {
    display: none; 
    position: fixed; 
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: hidden; 
    background-color: rgba(0, 0, 0, 0.9); 
    flex-direction: column;
    justify-content: center; 
    align-items: center;     
}

/* Bild und Caption erhalten beide die Animation */
.modal-content, #caption {
    animation: zoom 0.4s ease-out;
    /* Sorgt dafür, dass die Animation sauber abschließt */
    animation-fill-mode: both; 
}

.modal-content {
    display: block;
    width: auto;
    height: auto;
    max-width: 90%; 
    max-height: 70vh; 
    border-radius: 50px 50px 0 0; 
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    margin: 0; 
}

#caption {
    display: block;
    box-sizing: border-box;
    text-align: center;
    color: #222;
    font-family: "Google Sans", sans-serif;
    font-size: 1.1rem;
    font-weight: 500;
    padding: 20px; 
    margin: 0; 
    background-color: #ffffff; 
    border-radius: 0 0 50px 50px; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    /* Sorgt dafür, dass die Breite der Caption exakt zum Bild passt */
    width: 100%;
    max-width: 90%; 
}

.close {
    position: absolute;
    top: 15px;
    right: 25px;
    color: #ffffff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10001;
}

/* Die gemeinsame Animation */
@keyframes zoom {
    from {
        transform: scale(0.8); 
        opacity: 0;
    } 
    to {
        transform: scale(1); 
        opacity: 1;
    }
}

@media only screen and (max-width: 700px){
    .modal-content {
        max-width: 95%;
        max-height: 60vh;
        border-radius: 50px 50px 0 0;
    }
    #caption {
        max-width: 95%;
        font-size: 0.95rem;
        border-radius: 0 0 50px 50px;
    }
}

.modal-trigger {
    cursor: pointer;
    transition: 0.3s;
}
.modal-trigger:hover {
    opacity: 0.8;
}





@media screen {
    .projekt-container img[src*="Gaulhofer_Logo"] {
        max-width: 300px;
        height: auto;
        display: block;
        margin: 20px auto;
    }

    .projekt-container img[src*="Images/Logo/Design ohne Titel (42).png"] {
        border-radius: 30px;
        height: auto;
        width: 100%;
        margin-top: 20px;
    }
}