body {
    font-family: Arial, sans-serif;
    padding: 20px;
    display: grid;
    justify-items: center;
    background-color: #f4f4f4;
    gap: 20px;
}

#searchForm {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 600px;
    margin-bottom: 20px;
    background-color: #dddbdb;
    padding: 10px;
    border-radius: 10px;
}

#searchForm input[type="text"] {
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

#searchForm input[type="submit"] {
    padding: 10px;
    border-radius: 5px;
    border: none;
    background-color: #4CAF50;
    color: white;
    cursor: pointer;
}

#searchForm input[type="submit"]:hover {
    background-color: #45a049;
}

.line {
    display: inline-block;
    padding: 0 5px;
    color: white;
    border-radius: 3px;

}

#results {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 600px;
}

.collapsible {
    background-color: #eee;
    color: #444;
    cursor: pointer;
    padding: 18px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 15px;
    margin-top: 10px;
    border-radius: 10px;
    transition: border-radius 0.3s ease;

}

.active,
.collapsible:hover {
    background-color: #ccc;
}

.collapsible:after {
    content: url('data:image/svg+xml;utf8,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path transform="scale(1, -1) translate(0, -24)" d="M6.34317 7.75732L4.92896 9.17154L12 16.2426L19.0711 9.17157L17.6569 7.75735L12 13.4142L6.34317 7.75732Z" fill="currentColor"/></svg>');
    color: black;
    float: right;
    margin-left: 5px;
}

.active:after {
    content: url('data:image/svg+xml;utf8,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M6.34317 7.75732L4.92896 9.17154L12 16.2426L19.0711 9.17157L17.6569 7.75735L12 13.4142L6.34317 7.75732Z" fill="currentColor"/></svg>');
}

.active{
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.content {
    background-color: white;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.2s ease-out;
    width: 100%;
    border-radius: 0 0 10px 10px;
}

.connection {
    border: none;
    padding: 10px;
    margin-bottom: 10px;
}

.from,
.to,
.departure,
.arrival,
.duration {
    font-size: 14px;
}

.info-button {
    position: relative;
    display: inline-block;
    border: none;
    background-color: lightcoral;
    color: black;
    cursor: pointer;
    width: 3%;
    border-radius: 50%;
}

.info-button:hover .info-text {
    visibility: visible;
    opacity: 1; /* Fügen Sie diese Zeile hinzu */
}

.info-text {
    visibility: hidden;
    width: 120px;
    background-color: #555;
    color: #fff;
    text-align: center;
    padding: 5px 0;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    opacity: 0; /* Fügen Sie diese Zeile hinzu */
    transition: opacity 0.3s ease; /* Ändern Sie diese Zeile */
}

.info-text::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: #555 transparent transparent transparent;
}

.getLocation {
    padding: 10px;
    border-radius: 5px;
    border: none;
    background-color: #4CAF50;
    color: white;
    cursor: pointer;
    margin-bottom: 10px;
    width: 96%;
}

/* HTML: <div class="loader"></div> */
.loader {
    display: none;
    width: 60px;
    aspect-ratio: 2;
    --_g: no-repeat radial-gradient(circle closest-side,#000 90%,#0000);
    background:
            var(--_g) 0%   50%,
            var(--_g) 50%  50%,
            var(--_g) 100% 50%;
    background-size: calc(100%/3) 50%;
    animation: l3 1s infinite linear;
}
@keyframes l3 {
    20%{background-position:0%   0%, 50%  50%,100%  50%}
    40%{background-position:0% 100%, 50%   0%,100%  50%}
    60%{background-position:0%  50%, 50% 100%,100%   0%}
    80%{background-position:0%  50%, 50%  50%,100% 100%}
}


@media (max-width: 600px) {
    .body {
        padding: 20px;
    }

    .info-button {
        width: 18px;
    }

    .getLocation {
        width: 90%;
    }
    .info-text {
        width: 60px;
        margin-left: -30px;
    }
}