/* Общие стили */
body {
  margin: 0;
  padding: 0;
  font-family: sans-serif;
  background-color: #f6f8fa;
  color: #24292e;
  overflow: hidden;
}

.container {
  max-width: 1200px;
  margin: 20px auto;
  padding: 2rem;
  background-color: #ffffff;
  box-shadow: 0 4px 6px rgba(27, 31, 35, 0.1);
  border-radius: 8px;
  position: relative;
}

.header {
  background-color: #f6f8fa;
  padding: 1rem;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  border: 1px solid rgba(27, 31, 35, 0.15);
  border-bottom: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  text-align: center;
}

.theme-toggle {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.theme-toggle:hover {
  transform: scale(1.2);
}

.main-content {
  padding: 2rem;
}

.section-title {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 1rem;
  border-bottom: 2px solid #eaecef;
  padding-bottom: 0.5rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: "";
  width: 50px;
  height: 3px;
  background-color: #177eae;
  display: block;
  margin-top: 0.5rem;
  border-radius: 2px;
}

.description {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.label {
  font-weight: 600;
  margin-right: 0.5rem;
}

.code-snippet {
  background-color: rgba(27, 31, 35, 0.05);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-family: "Courier New", Courier, monospace;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  transition: background-color 0.3s ease;
}

.code-snippet:hover {
  background-color: rgba(27, 31, 35, 0.1);
}

.response-example {
  background-color: #f6f8fa;
  padding: 1rem;
  border-radius: 4px;
  font-family: "Courier New", Courier, monospace;
  font-size: 0.95rem;
  line-height: 1.5;
  overflow-x: auto;
  transition: background-color 0.3s ease;
}

.response-example:hover {
  background-color: #e1e4e8;
}

.error-message,
.success-message {
  font-weight: 600;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}

.error-message {
  color: #b45c65;
}

.success-message {
  color: #458b99;
}

.api-method {
  margin-bottom: 2rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.api-method.visible {
  opacity: 1;
  transform: translateY(0);
}

.api-method-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  cursor: pointer;
  position: relative;
  transition: color 0.3s ease;
}

.api-method-title:hover {
  color: #315680;
}

.api-method-title::after {
  content: "▼";
  font-size: 0.8rem;
  position: absolute;
  right: -1.5rem;
  top: 50%;
  transform: translateY(-50%) rotate(0deg);
  transition: transform 0.3s ease;
}

.api-method-title.active::after {
  transform: translateY(-50%) rotate(180deg);
}

.api-method .description {
  display: none;
  animation: fadeIn 0.5s ease-in-out;
}

.api-method .description.visible {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Темная тема */
body.dark-theme {
  background-color: #1e1e1e;
  color: #c9d1d9;
}

.container.dark-theme {
  background-color: #2d2d2d;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.5);
}

.header.dark-theme {
  background-color: #2d2d2d;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.section-title.dark-theme::after {
  background-color: #3d6d8f;
}

.code-snippet.dark-theme,
.response-example.dark-theme {
  background-color: rgba(255, 255, 255, 0.1);
}

.code-snippet.dark-theme:hover,
.response-example.dark-theme:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

/* Мобильная адаптация */
@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .header-title {
    font-size: 1.25rem;
  }

  .code-snippet,
  .response-example {
    font-size: 0.85rem;
  }

  .theme-toggle {
    font-size: 1.25rem;
  }
}

/* Футер */
.footer {
  background-color: rgb(213, 213, 213);
  color: white;
  padding: 12px 0;
  text-align: center;
  width: 100%;
  margin-top: auto;
}

.footer-container {
  max-width: 73%;
  margin: 0 auto;
}

.footer-link {
  color: #28383d;
  text-decoration: none;
}

.footer-link:hover {
  text-decoration: underline;
}
