
body {
  font-family: 'Noto Serif SC', 'KaiTi', serif; /* klassische chinesische Schriftarten */
  max-width: 900px;
  margin: 0 auto;
  padding: 30px 20px;
  background-color: #f8f4e8; /* Reispapier-Hintergrund */
  color: #3b2e2a; /* dunkle Tinte */
  line-height: 1.6;
}
.back-link {
display: inline-block;
margin-bottom: 20px;
margin-top: -20px;
color: #5c3a21;
font-family: 'KaiTi', serif;
font-size: 16px;
text-decoration: none;
background-color: #f4efe4;
padding: 6px 12px;
border-radius: 6px;
border: 1px solid #a67c52;
transition: background-color 0.2s ease;
}

.back-link:hover {
background-color: #e6d8bd;
color: #3b2e2a;
}


h1 {
  text-align: center;
  color: #5c3a21; /* warme braune Tinte */
  margin-bottom: 40px;
  font-weight: bold;
  font-size: 3em;
  border-bottom: 4px double #a67c52;
  padding-bottom: 12px;
  background: linear-gradient(to right, #e6d8bd, #f4efe4);
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.poem-container {
position: relative;
border-radius: 15px;
padding: 25px 30px;
font-size: 1.4em;
font-family: 'Noto Serif SC', 'KaiTi', serif;
color: #4a3926;
border: 3px solid #a67c52;
overflow: hidden;
z-index: 0;
}

.poem-container::before {
content: "";
position: absolute;
inset: 0;
background: linear-gradient(135deg, #fbf7ed, #f5ecda, #fdfaf3, #f5ecda);
background-size: 300% 300%;
animation: softShift 18s ease-in-out infinite;
z-index: -1;
opacity: 0.5;
filter: blur(1.2px);
}

@keyframes softShift {
0% {
    background-position: 0% 50%;
}
50% {
    background-position: 100% 50%;
}
100% {
    background-position: 0% 50%;
}
}

.poem-line {
  margin-bottom: 18px;
  line-height: 1.8;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.char-container {
  position: relative;
  margin: 0 3px;
  cursor: pointer;
  text-align: center;
  user-select: none;
}

.char {
  font-size: 22px;
  display: block;
}
#languageSelect {
  font-family: 'KaiTi', serif;
  font-size: 16px;
  padding: 6px 14px;
  border: 2px solid #a67c52;
  border-radius: 8px;
  background-color: #fbf7ed;
  color: #3b2e2a;
  margin-bottom: 25px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  cursor: pointer;
  transition: border-color 0.3s ease;
  appearance: none;       /* Für moderne Browser */
  -webkit-appearance: none; /* Safari/Chrome */
  -moz-appearance: none;    /* Firefox */
}

#languageSelect:hover {
  border-color: #8b5e2c;
}

#languageSelect:focus {
  outline: none;
  border-color: #5a3825;
}



.pinyin {
  font-size: 13px;
  color: #c0392b; /* tiefes Rot */
  display: none;
  position: absolute;
  top: -20px;
  left: 0;
  right: 0;
  font-family: 'KaiTi', serif;
  font-weight: bold;
}

.translation {
  font-size: 13px;
  color: #2980b9; /* tiefes Blau */
  display: none;
  position: absolute;
  bottom: -20px;
  left: 0;
  right: 0;
  font-family: 'KaiTi', serif;
  font-style: italic;
}

.line-controls {
  margin-left: 18px;
  display: flex;
  gap: 12px;
}

button {
  padding: 6px 14px;
  background-color: #a67c52; /* warmes Braun */
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 15px;
  font-family: 'KaiTi', serif;
  transition: background-color 0.3s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  user-select: none;
}

button:hover {
  background-color: #8b5e2c; /* dunkleres Braun beim Hover */
}

.status-bar {
  margin-top: 25px;
  padding: 12px 20px;
  background-color: #e6d8bd;
  border-left: 5px solid #a67c52;
  font-size: 15px;
  font-style: italic;
  color: #5c3a21;
  box-shadow: 2px 2px 6px rgba(0,0,0,0.1);
  font-family: 'KaiTi', serif;
}

.instructions {
  margin-top: 35px;
  padding: 20px 30px;
  background-color: #fbf7ed;
  border-left: 5px solid #a67c52;
  border-radius: 15px;
  box-shadow: 3px 3px 12px rgba(0,0,0,0.07);
  font-family: 'KaiTi', serif;
  color: #5c3a21;
  font-size: 1.15em;
  line-height: 1.5;
}
#translationCard {
  position: fixed;
  background: #fdf9f1;
  border: 2px solid #b59f7b;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  display: none;
  max-width: 280px;
  font-size: 16px;
  z-index: 10000;

  top: 50%;
  right: 0;
  transform: translateY(-50%);
  color: #3b2e2a;
  font-family: 'Noto Serif SC', 'KaiTi', serif;
}

/* Kopfbereich für Button */
#translationCard .card-header {
  position: relative;
  height: 24px;
}

/* Schließen-Button */
#translationCard .close-btn {
  position: absolute;
  top: 0;
  left: 0;
  background: none;
  border: none;
  font-size: 20px;
  font-weight: bold;
  color: #a67c52;
  cursor: pointer;
  z-index: 2;
}

#translationCard .close-btn:hover {
  color: #000;
}

/* Inhaltsteil */
#translationCard .info-block {
  padding-left: 2.5rem;
  padding-top: 4px;
}

#translationCard .info-label {
  font-weight: bold;
  color: #5a3825;
  margin-top: 10px;
  margin-bottom: 4px;
  font-size: 17px;
}

#translationCard .info-content {
  background-color: #fcf7ef;
  padding: 6px 10px;
  border-left: 3px solid #a67c52;
  margin-bottom: 12px;
  border-radius: 4px;
  font-size: 15px;
  color: #3b2e2a;
}
