html, body {
    font-family: 'Segoe UI', sans-serif;
    margin: 0;
    background: #121212;
    color: #e0e0e0;
    height: 100vh;
}

 #page {
    display: flex;
    flex-direction: column;
    height: 100vh; /* ← jetzt korrekt */
}

.main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
    margin-bottom: 10px; /* oder was du willst */
    margin-top: 10px; /* oder was du willst */
}

.chat-container {
    overflow-y: auto;
    padding: 20px;
    min-height: 0;
    min-width: calc(100% - 530px);
}

.entry {
    background: #1e1e1e;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 8px;
    box-shadow: 0 0 5px #333;
}

.user {
    font-weight: bold;
    color: #90caf9;
    margin-bottom: 5px;
}

.response {
    margin-top: 10px;
    color: #80cbc4;
}

form {
    padding: 10px;
    background: #1a1a1a;
    display: flex;
    gap: 10px;
    border: none;
}

textarea {
    flex: 1;
    resize: none;
    font-size: 1.25em;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #444;
    background: #2c2c2c;
    color: #e0e0e0;
}

input[type=submit] {
    padding: 10px 20px;
    height:40px;
    font-size: 1em;
    border-radius: 5px;
    border: none;
    background: #0078D4;
    color: white;
    cursor: pointer;
}

input[type=submit]:disabled {
    background-color: #555 !important;
    color: #aaa !important;
    cursor: not-allowed;
    opacity: 0.6;
}

input[type=submit] {
    transition: background 0.3s ease, color 0.3s ease, opacity 0.3s ease;
}

@keyframes blink {
  0% { opacity: 0.2; }
  50% { opacity: 1; }
  100% { opacity: 0.2; }
}

#thinking-indicator {
  animation: blink 1.5s infinite;
  padding: 10px;
  color: #ccc;
}

#headline-sidebar {
    width: 250px;
    background: #1a1a1a;
    padding: 20px;
    border-left: 1px solid #333;
    overflow-y: auto;
    border-radius: 8px;
    min-height: 0; /* ← WICHTIG! */
    flex-shrink: 0; /* ← verhindert das Schrumpfen */
}

#headline-sidebar h3 {
    margin-top: 0;
    color: #90caf9;
}

#headline-sidebar ul {
    list-style: none;
    padding: 0;
}

#headline-sidebar li {
    margin-bottom: 10px;
}

#headline-sidebar a {
    color: #80cbc4;
    text-decoration: none;
    cursor: pointer;
}

#headline-sidebar_dates a:hover {
    text-decoration: underline;
}

#headline-sidebar-dates {
    width: 150px;
    background: #1a1a1a;
    padding: 20px;
    border-left: 1px solid #333;
    overflow-y: auto;
    border-radius: 8px;
    min-height: 0; /* ← WICHTIG! */
    flex-shrink: 0; /* ← verhindert das Schrumpfen */
}

#headline-sidebar-dates h3 {
    margin-top: 0;
    color: #90caf9;
}

#headline-sidebar-dates ul {
    list-style: none;
    padding: 0;
}

#headline-sidebar-dates li {
    margin-bottom: 10px;
}

#headline-sidebar-dates a {
    color: #80cbc4;
    text-decoration: none;
    cursor: pointer;
}

#headline-sidebar-dates a:hover {
    text-decoration: underline;
}

.highlight {
    background-color: #333333;
    transition: background-color 0.5s ease;
}

.upload-button {
    display: inline-block;
    margin-top: 0px;
    padding: 10px 20px;
    height: 20px;
    font-size: 1em;
    border-radius: 5px;
    background: #0078D4;
    color: white;
    cursor: pointer;
    text-align: center;
    transition: background 0.3s ease, color 0.3s ease;
}

.upload-button:hover {
    background: #005fa3;
}

.upload-button span {
    display: inline-block;
    vertical-align: middle;
}

.link_question {
    color: #80cbc4;
    text-decoration: none;
    cursor: pointer;
}

.lightbox {
    position: fixed; z-index: 9999; left: 0; top: 0; width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.9); display: flex; align-items: center; justify-content: center;
}
.lightbox-content {
    max-width: 90%; max-height: 90%; text-align: center; color: white;
}
#lightbox-viewer img { max-width: 100%; max-height: 80vh; border: 2px solid #444; }
#lightbox-viewer pre {
    text-align: left; background: #1e1e1e; padding: 20px; overflow: auto;
    max-height: 70vh; border-radius: 5px; font-family: monospace;
}
.close-btn {
    position: absolute; top: 20px; right: 35px; color: #f1f1f1;
    font-size: 40px; font-weight: bold; cursor: pointer;
}
.lightbox-caption { margin-top: 10px; font-family: sans-serif; }
