body.dark-mode {
 background-color: #121212;
 color: #e0e0e0;
}

.split-container {
  display: flex;
  flex-direction: row;
  margin-top: 60px;
  width: 100%;
  height: calc(100vh - 120px);
}

.panel {
  padding: 20px;
  margin: 10px;
  border: 1px solid #333;
  border-radius: 8px;
  overflow-y: auto;
}

#image-analysis {
  flex: 1;
  max-width: 50%;
}

#translation-app {
  flex: 1;
  max-width: 50%;
}

textarea {
 width: 100%;
 height: 100px;
 margin-bottom: 10px;
 background-color: #333;
 color: #fff;
 border: none;
 padding: 10px;
 border-radius: 4px;
 box-sizing: border-box;
 padding-left: 30px;
 padding-right: 30px;
 line-height: 2;
 white-space: pre-wrap;
 font-family: monospace;
}

button {
 display: block;
 width: 100%;
 padding: 10px;
 margin-bottom: 10px;
 background-color: blue;
 color: #fff;
 border: none;
 border-radius: 4px;
 cursor: pointer;
  font-size: 20px;
}

button:hover {
 background-color: #0056b3;
}

#translations {
 margin-bottom: 10px;
}

#select_translation_style {
  width: 100%;
  height: 40px;
  background-color: blue;
  color: white;
  text-align: center;
  font-size: 16px;
  border-radius: 4px;
  z-index: 999999999;
  max-height: 300px;
  overflow-y: auto;
  position: relative;
}

#select_translation_style:focus {
  height: auto;
  min-height: 40px;
  max-height: 300px;
}

#select_translation_style option {
  padding: 8px;
  background-color: #222;
}

#select_translation_style option:hover {
  background-color: #444;
}

#search_style,
#titleInput {
 width: 100%;
 height: 40px;
 background-color: #333;
 color: lime;
 text-align: left;
 font-size: 16px;
 border-radius: 4px;
 border: 1px solid #555;
 padding-left: 30px;
 padding-right: 30px;
 box-sizing: border-box;
}



#addApikey {
 position: fixed;
 top: 2%;
 right: 3%;
 font-size: 18px;
 cursor: pointer;
 z-index: 400;
 color: white;
}

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 50px;
  background-color: #222;
  border-bottom: 1px solid #555;
}
h1 {
  margin: 0;
  padding: 0;
  font-size: 20px;
  font-weight: bold;
  color: white;
  text-align: center;
  line-height: 50px;
}

footer {
  position: fixed;
  top: 5px;
  left: 10px;
  text-align: left;
  z-index: 100;
}

footer p {
  font-size: 12px;
  color: blue;
  margin: 0;
}

#waiting-gif {
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  position: fixed;
  width: 250px;
  height: 250px;
  z-index: 999;
}

/* Image analysis styles */
h2 {
  color: #fff;
  margin-top: 0;
  border-bottom: 1px solid #444;
  padding-bottom: 10px;
}

.camera-controls {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
}

.control-button {
  flex: 1;
  margin: 0 5px;
  padding: 8px;
  font-size: 14px;
}

#camera-container {
  position: relative;
  margin-bottom: 15px;
}

#camera-feed {
  width: 100%;
  border-radius: 8px;
  background-color: #333;
}

#capture-photo, #cancel-camera {
  position: relative;
  margin-top: 10px;
  width: 48%;
  padding: 8px;
}

.close-camera-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  color: white;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  z-index: 10;
}

#image-preview-container {
  display: flex;
  justify-content: center;
  margin: 15px 0;
}

#image-preview {
  max-width: 100%;
  max-height: 300px;
  border-radius: 8px;
  border: 1px solid #555;
}

.ai-message-container {
  display: flex;
  margin: 15px 0;
  gap: 10px;
}

#ai-message-input {
  flex: 1;
  padding: 8px;
  background-color: #333;
  color: white;
  border: 1px solid #444;
  border-radius: 4px;
}

#send-ai-message {
  background-color: blue;
}

#analysis-output {
  padding: 15px;
  background-color: #222;
  border-radius: 8px;
  min-height: 100px;
  max-height: 300px;
  overflow-y: auto;
  margin-top: 15px;
  border: 1px solid #444;
}

/* Code block styling */
.code-block {
  background-color: #1a1a1a;
  border: 1px solid #444;
  border-radius: 4px;
  padding: 10px;
  margin: 10px 0;
  overflow-x: auto;
  font-family: monospace;
  color: #eee;
  line-height: 1.4;
}

.inline-code {
  background-color: #333;
  padding: 2px 4px;
  border-radius: 3px;
  font-family: monospace;
  color: #eee;
}

.analysis-content {
  line-height: 2;
  white-space: pre-wrap;
}

.analysis-content p {
  margin-bottom: 10px;
  line-height: 2;
}

#analysis-output {
  padding: 15px;
  background-color: #222;
  border-radius: 8px;
  min-height: 100px;
  max-height: 300px;
  overflow-y: auto;
  margin-top: 15px;
  border: 1px solid #444;
  white-space: pre-wrap;
  line-height: 2;
}

.analyzing-message {
  text-align: center;
  font-size: 18px;
  font-weight: bold;
  transition: color 0.3s ease;
}

#kiDenkt {
position: fixed;
bottom: 70px;
width: 100%;
text-align: center;
font-size: 30px;
  display: none;
}

#editLeftSideResponse {
position: fixed;
bottom: -7px;
left: 0;
right: 0;
height: 50px;
width: 100vw;
background-color: black;
color: white;
padding: 20px;
resize: none;
outline: none;
border-top: 1px solid blue;
font-size: 16px;
}

@media (max-width: 768px) {
  .split-container {
    flex-direction: column;
  }
  
  #image-analysis, #translation-app {
    max-width: 100%;
  }
}