html, body {
    height: 100%;
    margin: 0;
}

body {
    overflow: hidden;
}

main {
    display: flex;
    height: calc(100dvh - 100px);
    min-height: 0;
    align-items: stretch;
}

#sideList {
    width: clamp(50px, 30%, 300px);
    padding: 10px;
    box-sizing: border-box;

    overflow-y: auto;
    flex-shrink: 0;

    height: auto;
    align-self: stretch;
}

#content {
    flex: 1;
    padding: 5vw;
    padding-bottom: 20vh;

    overflow-y: auto;
    min-height: 0;
}

#sideList button {
    display: block;
    width: 100%;
    margin: 5px 0;
    padding: 8px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    font-size: 1rem;

    color: white;
}

#sideList button {
    transition: 0.5s ease-in-out;
}

#sideList button:hover {
    transition: 0.5s ease-in-out;
    background-color: rgba(137, 43, 226, 0.61);
}

#sideList button.active {
    transition: 2s ease-in-out;
    background-color: #cccccc3b;
    font-variant: small-caps;
}

.doc-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-main), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 1rem 0;
}

.doc-tip {
  font-size: clamp(0.85rem, 1.2vw, 1rem);
  color: var(--accent-secondary);
  border-left: 0.3rem solid var(--accent-main);
  padding-left: 0.7rem;
  margin: 0.7rem 0;
}

.doc-warning {
  font-size: clamp(0.85rem, 1.2vw, 1rem);
  color: #ff9500;
  border-left: 0.3rem solid #ff5500;
  padding-left: 0.7rem;
  margin: 0.7rem 0;
}

.inline-code {
  font-family: 'Courier New', monospace;
  background-color: rgba(12,12,20,0.95); /* dunkles Lila */
  color: #ff99ff; /* leicht violett für Text */
  padding: 0.2rem 0.4rem;
  border-radius: 0.3rem;
  box-shadow: 0 0 20px rgba(255,72,188,0.3); /* glow */
  font-size: clamp(0.8rem, 1vw, 1rem);
  transition: 1s ease-in-out;
}

.inline-code:hover {
  transition: 1s ease-in-out;
  font-size: clamp(0.82rem, 1.03vw, 1.05rem);
}

.doc-code {
   font-family: 
    'Courier New', monospace;
  font-size: clamp(0.85rem, 1vw, 1.1rem);
  background-color: rgba(0, 0, 0, 0.63); /* dunkles Lila */
  padding: 0.8rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  white-space: pre-wrap;
  color: #ff99ff; /* leicht violett für Text */
  box-shadow: 0 0 10px rgba(255,72,188,0.3); /* glow */
}


.keyword { color: #ff77ff; font-weight: bold; }
.string  { color: #00f0ff; }
.angle   { color: #ffcc66; font-style: italic; } /* <…> */
.comment { color: #888888; font-style: italic; }


.highlight {
  background-color: rgba(188,72,255,0.3);
  padding: 0.2rem 0.4rem;
  border-radius: 0.3rem;
  font-weight: bold;
}

.not-important {
  background-color: rgba(233, 233, 233, 0.3);
  padding: 0.2rem 0.4rem;
  border-radius: 0.3rem;
  font-weight: bold;
  color: #888888;
}

.doc-subtitle {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 600;
  background: linear-gradient(135deg, var(--accent-main), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0.8rem 0;
}

.doc-subsubtitle {
  font-size: clamp(1.5rem, 1.8vw, 2.5rem);
  font-weight: 560;
  background: linear-gradient(135deg, var(--accent-main), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0.8rem 0;
}

.doc-subsubsubtitle {
  font-size: clamp(1.5rem, 1vw, 2.5rem);
  font-weight: 560;
  background: linear-gradient(135deg, var(--accent-main), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0.8rem 0;
}

.doc-text {
  font-size: clamp(0.9rem, 1.5vw, 1.2rem);
  line-height: 1.6;
  color: #000000;
  margin: 0.5rem 0;
}

.doc-small {
  font-size: clamp(0.7rem, 1vw, 0.9rem);
  color: #aaa;
  margin: 0.3rem 0;
}

.doc-container {
  background-color: rgba(142, 69, 202, 0.1); /* Glaseffekt */
  backdrop-filter: blur(5px);
  border-radius: 1rem;
  padding: 2%;
  margin: 1rem 0;
  box-shadow: 0 0 10px rgba(0,0,0,0.4);
}

.doc-image {
  width: clamp(20rem, 40%, 100rem); /* klein-min 8rem, flexibel, max 20rem */
  height: auto;
  border-radius: 0.8rem;
  box-shadow: 0 0 8px rgba(188,72,255,0.3);
  margin: 0.5rem 0;
  display: block;
  transition: 1s ease-in-out;
}

.doc-image:hover {
  transition: 1s ease-in-out;
  scale: 1.05;
}


.video-wrapper {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 Verhältnis */
  margin: 1rem 0;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(188,72,255,0.3);
}

.doc-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  object-fit: cover;
}

.doc-flex {
  display: flex;
  flex-direction: row;
  gap: 2%;
  flex-wrap: wrap;
  align-items: flex-start;
}

.doc-flex-text {
  flex: 1 1 40%;
  min-width: 200px;
}

.doc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: clamp(0.85rem, 1vw, 1rem);
  background-color: rgba(20, 10, 40, 0.6);
  backdrop-filter: blur(4px);
  border-radius: 0.6rem;
  overflow: hidden;
  box-shadow: 0 0 12px rgba(188, 72, 255, 0.25);
}

/* Header */
.doc-table thead {
  background: linear-gradient(
    90deg,
    rgba(140, 60, 200, 0.7),
    rgba(200, 80, 255, 0.7)
  );
}

.doc-table thead th {
  padding: 0.7rem 0.8rem;
  text-align: left;
  font-weight: 600;
  color: #f3e9ff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

/* Body */
.doc-table tbody td {
  padding: 0.65rem 0.8rem;
  color: #e6d9ff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  border: #e729ee17 solid 1px;
}

/* Zebra rows */
.doc-table tbody tr:nth-child(even) {
  background-color: rgba(255, 255, 255, 0.03);
}

.doc-table tbody tr {
  transition: 1s ease-in-out;
}

/* Hover */
.doc-table tbody tr:hover {
  transition: 0.2s ease-in-out;
  background-color: rgba(188, 72, 255, 0.12);
}

/* Optional: code-like cells */
.doc-table .code {
  font-family: 'Courier New', monospace;
  color: #ffb3ff;
  white-space: nowrap;
}

.navigationButton {
    display: none;
    transition: ease 3s;
    background-image: url("../assets/images/settings.svg");
    background-size: contain;
    background-color: rgba(240, 248, 255, 0);
    border: 0;
    aspect-ratio: 1/1;
    height: clamp(10px, 3rem, 70px);
    border-radius: 10%;
    position: fixed;
    top: calc(var(--headline-gap) - 20px);
    right: 1em;

    z-index: 200;
}

.navigationButton:hover {
    transition: ease 1s;
    background-color: var(--glass-color);
}

/*----@media----*/
@media(max-width:1000px) {
  #sideList {
    display: none;
    width: max-content;
    position: absolute;
  }
  .navigationButton {
    display: block;
  }
}

main {
    display: flex;
    height: calc(100dvh - 100px);
    min-height: 0;
    align-items: stretch;
}

/* style.css definiert main:has(> #sideList) { align-items: flex-start; }
   mit höherer Spezifität als das einfache "main" oben – dadurch gewinnt
   sonst flex-start und #sideList streckt sich nicht über die volle Höhe. */
main:has(> #sideList) {
    align-items: stretch;
}