body, html {
    height: 100%;
    margin: 0;
    background-color: #f7faf3;
}

#headerbar {
    background-color: #3d8010;
    background-image: linear-gradient(180deg, #489714 0%, #3a7a10 100%);
    box-shadow: 0 2px 10px rgba(30, 70, 5, 0.22);
    padding: 0.55rem 1.5rem;
}

#headertext {
    color: white;
}

.navbar-brand {
    font-weight: 800;
    font-size: 1.35rem;
    letter-spacing: 0.07em;
    color: #fff !important;
}

.navbar .nav-link {
    color: rgba(255,255,255,0.92) !important;
    border-radius: 6px;
    padding: 0.35rem 0.8rem !important;
    transition: background 0.15s, color 0.15s;
}

.navbar .nav-link:hover {
    background: rgba(255,255,255,0.16);
    color: #fff !important;
}

.navbar-toggler {
    border-color: rgba(255,255,255,0.45);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255%2C255%2C255%2C0.9%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.navbar-nav .nav-item {
    display: flex;
    align-items: center;
}

.navbar-nav .nav-item + .nav-item::before {
    content: '';
}
 

#symptom-list {
    font-weight: bold;
}

#button {
    background-color: #489714;
    margin-left: 1em;
    border-color: #489714;
}

#myFooter {
    background-color: #f5faf0;
    color: #555;
    border-top: 1px solid #d4e8c0;
    width: 100%;
}

.footer-inner {
    width: 100%;
    padding: 10px 15px 6px;
    margin-bottom: 0;
    box-sizing: border-box;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 0.76rem;
    color: #6c757d;
    margin-bottom: 6px;
}

.footer-attribution { flex: 1; min-width: 0; }

.footer-meta {
    text-align: right;
    white-space: nowrap;
    font-size: 0.76rem;
    color: #6c757d;
}

.footer-meta p {
    margin: 0;
    padding: 0;
}

.footer-nav-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 2px 6px;
    border-top: 1px solid #d4e8c0;
    padding-top: 6px;
    font-size: 0.8rem;
}

.footer-link {
    color: #4b4b4b;
    text-decoration: none;
}

.footer-link:hover {
    color: #489714;
    text-decoration: underline;
}

.footer-sep { color: #c0d8a8; }

@media (max-width: 767.98px) {
    #myFooter { font-size: 0.8em; }

    .footer-top { flex-direction: column; }
    .footer-meta { text-align: left; white-space: normal; }

    .navbar-nav .nav-item + .nav-item::before { display: none; }
}


#headline {
    font-size: 1.85rem;
    font-weight: 700;
    color: #1e4d00;
    margin-top: 0;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #b5de8a;
}

#scrollToTopBtn {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 30px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: #6aca4d;
    color: white;
    cursor: pointer;
    padding: 15px;
    border-radius: 10px;
    font-size: 18px;
}

#scrollToTopBtn:hover {
    background-color: #76e255;
}

.navbar {
    padding-left: 0;
}

.container {
    margin-top: 1.75rem;
    margin-bottom: 3rem;
}

.disease-row {
    margin-bottom: 1rem;
    width: 100%;
}

.disease-row-container {
    width: 100%;
}

.disease-row-inner {
    width: 100%;
}


.custom-card-body {
    width: 100%;
}


.disease-name {
    font-weight: bold;
    margin-right: 0.5rem;
}

.toggle-icon {
    cursor: pointer;
    font-size: 1.25rem;
}

.symptom-list-container {
    width: 100%;
}

.symptom-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    width: 100%;
}

.error {
    color: white;
    border-radius: 10px;
    background-color: #D0342C;
    padding: inherit;
    padding-top: 10px;
    padding-bottom: 10px;
    padding-right: 10px;
    padding-left: 10px;
    width: fit-content;
    margin-top: 1em;
    margin-bottom: 1em;
}

#search-results {
    padding-bottom: 100px;
}

.result-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 10px;
    font-weight: normal;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.result-rank {
    font-size: 0.95rem;
    font-weight: 600;
    color: #adb5bd;
    min-width: 28px;
    padding-top: 3px;
    text-align: right;
}

.result-body {
    flex: 1;
    min-width: 0;
}

.result-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.result-name {
    font-size: 1rem;
    font-weight: 600;
    color: #1f6455;
    text-decoration: none;
}

.result-name:hover {
    text-decoration: underline;
}

.result-badge {
    border: 1px solid;
    border-radius: 20px;
    padding: 2px 10px;
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.result-bar-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
}

.result-bar-track {
    flex: 1;
    background: #e9ecef;
    border-radius: 4px;
    height: 6px;
    overflow: hidden;
}

.result-bar-fill {
    height: 100%;
    border-radius: 4px;
}

.result-prob {
    font-size: 0.85rem;
    color: #495057;
    white-space: nowrap;
    min-width: 48px;
    text-align: right;
}

.result-meta {
    font-size: 0.8rem;
    margin-top: 5px;
}

.result-match {
    font-weight: 600;
}

.result-freq {
    color: #6c757d;
    font-style: italic;
}

.symptom-tag {
    display: inline-block;
    background: #f0f8e6;
    color: #3d7d10;
    border: 1px solid #a3ce78;
    border-radius: 20px;
    padding: 2px 10px;
    font-size: 0.8rem;
    margin: 2px 4px 2px 0;
}

.form-group {
    margin-bottom: 15px;
}


.form-group .invalid-feedback {
    display: none;
    color: red;
    margin-top: 0.5em;
}

form.was-validated .form-control:invalid ~ .invalid-feedback,
form.was-validated .form-check-input:invalid ~ .invalid-feedback {
    display: block;
}

form.was-validated .form-control:invalid,
form.was-validated .form-check-input:invalid {
    border-color: #dc3545;
}

.btn-primary {
    background-color: #489714 !important;
    border-color: #489714 !important;
    color: #fff !important;
}

.btn-primary:hover {
    background-color: #3a7a10 !important;
    border-color: #3a7a10 !important;
}

.btn-primary:disabled {
    background-color: #489714 !important;
    border-color: #489714 !important;
    opacity: 0.55;
}

.referer-sonstiges-text {
    display: none;
    width: auto;
    margin-left: 10px;
}

.footer-links a.custom-link {
    color: #4b4b4b;
    text-decoration: none; 
  }

.footer-links a.custom-link:hover {
    color: #4b4b4b; 
  }

#symptom-search-link,
#all-diseases-link,
#contact-link,
a[id^="disease-"] {
    color: #1f6455;
    text-decoration: none;
}

#symptom-search-link:hover,
#all-diseases-link:hover,
#contact-link:hover,
a[id^="disease-"]:hover {
    text-decoration: underline;
}

/* ===== Startseite ===== */
.hero-section {
    text-align: center;
    padding: 2em 0 1.5em;
}

.hero-logo {
    max-width: 520px;
    width: 100%;
    height: auto;
}

.hero-subtitle {
    color: #6c757d;
    font-size: 1.05rem;
    margin-top: 0.75em;
}

.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.2rem;
    margin-top: 1.5rem;
}

.feature-card {
    display: block;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
    transition: box-shadow 0.2s, border-color 0.2s, transform 0.15s;
}

.feature-card:hover {
    box-shadow: 0 6px 20px rgba(72, 151, 20, 0.15);
    border-color: #a3ce78;
    text-decoration: none;
    color: inherit;
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 1.8rem;
    color: #489714;
    margin-bottom: 0.75rem;
}

.feature-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f6455;
    margin-bottom: 0.4rem;
}

.feature-card p {
    font-size: 0.88rem;
    color: #555;
    margin: 0;
    line-height: 1.5;
}

/* ===== Symptomsuche ===== */
.search-bar-wrapper {
    display: flex;
    align-items: center;
    border: 1px solid #ced4da;
    border-radius: 8px;
    background: #fff;
    padding: 0 12px;
    max-width: 400px;
    flex: 1;
}

.search-bar-wrapper i {
    color: #adb5bd;
    margin-right: 8px;
    flex-shrink: 0;
}

.search-bar-wrapper input {
    border: none;
    outline: none;
    width: 100%;
    padding: 10px 0;
    font-size: 0.95rem;
    background: transparent;
}

.selected-counter {
    display: inline-block;
    background: #489714;
    color: #fff;
    border-radius: 20px;
    padding: 3px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    transition: background 0.2s;
    white-space: nowrap;
}

.selected-counter.none {
    background: #adb5bd;
}

.symptom-row-checked {
    background: #f2f9ea;
    border-radius: 8px;
    padding: 4px 8px;
    margin-left: -8px;
    margin-right: -8px;
}

/* ===== Krankheits-Detail ===== */
.description-box {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    font-size: 0.92rem;
    color: #333;
    line-height: 1.6;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.info-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem 1rem;
}

.info-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.info-value {
    display: block;
    font-size: 0.9rem;
    color: #212529;
}

.section-heading {
    font-size: 1rem;
    font-weight: 700;
    color: #1f6455;
    margin: 1.5rem 0 0.75rem;
    padding-bottom: 0.3rem;
    border-bottom: 2px solid #e0e0e0;
}

.freq-block {
    margin-bottom: 1rem;
}

.freq-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    margin-bottom: 6px;
    border: 1px solid;
}

.freq-obligat      { background: #ebf5e0; color: #1a5c00; border-color: #7bbe50; }
.freq-sehr-haeufig { background: #f2f9ea; color: #3d7d10; border-color: #a3ce78; }
.freq-haeufig      { background: #f2f9ea; color: #3d7d10; border-color: #a3ce78; }
.freq-gelegentlich { background: #fff6e0; color: #b06000; border-color: #f0b840; }
.freq-selten       { background: #f4f4f4; color: #666;    border-color: #ccc; }
.freq-ausgeschlossen { background: #fdf0f0; color: #a00000; border-color: #f0a0a0; }

.freq-symptom-list {
    list-style: none;
    padding-left: 0.5rem;
    margin: 0 0 0.5rem;
    font-size: 0.88rem;
    color: #444;
}

.freq-symptom-list li {
    padding: 2px 0;
}

.btn-expert {
    display: inline-block;
    background: #f2f9ea;
    color: #1f6455;
    border: 1px solid #a3ce78;
    border-radius: 8px;
    padding: 4px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
}

.btn-expert:hover {
    background: #e0f2d0;
    color: #1f6455;
    text-decoration: none;
}

/* ===== Content-Seiten (Impressum, Datenschutz) ===== */
.content-page {
    max-width: 800px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.75rem 2.25rem;
    font-size: 0.92rem;
    line-height: 1.7;
    color: #333;
    box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}

.content-page h2 {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f6455;
    margin-top: 1.5rem;
    margin-bottom: 0.4rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

/* ===== Kontakt ===== */
.contact-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.75rem;
    max-width: 720px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}

.referer-box {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem 1rem;
}

/* ===== Alle Krankheiten ===== */
.collapse {
    display: none;
}
.collapse.show {
    display: block;
}

.disease-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 10px 0;
    user-select: none;
}

.disease-header:hover .disease-name {
    color: #3d7d10;
}

.disease-toggle-btn {
    color: #adb5bd;
    padding: 0 4px;
    transition: color 0.15s;
    flex-shrink: 0;
}

.disease-header:hover .disease-toggle-btn {
    color: #489714;
}

.disease-detail {
    padding: 0 0 0.5rem;
}

/* ===== 404 ===== */
.error-page {
    text-align: center;
    padding: 4em 1em;
}

.error-page .error-code {
    font-size: 5rem;
    font-weight: 800;
    color: #489714;
    line-height: 1;
}

.error-page .error-msg {
    font-size: 1.2rem;
    color: #555;
    margin: 0.5em 0 1.5em;
}
