﻿* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

form {
  min-height: 100%;
}

body {
  background: var(--background);
  color: var(--text);
  font-family: Segoe UI;
}

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 35px;
  z-index: 999;
}

.logo {
  width: 170px;
  height: 50px;
  background-image: var(--logo);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

  .logo i {
    margin-right: 8px;
  }

.topbar nav {
  display: flex;
  align-items: center;
  gap: 25px;
}

.topbar a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 600;
}

  .topbar a:hover {
    color: var(--primary);
  }

.layout {
  display: flex;
  padding-top: 70px;
}

.sidebar {
  width: 380px;
  height: calc(100vh - 70px);
  background: var(--surface);
  border-right: 1px solid var(--border);
  position: fixed;
  top: 70px;
  left: 0;
  overflow-y: scroll;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: #5b6474 transparent;
  padding-top: 10px;

}

.tree-title {
  cursor: pointer;
}

.tree-item {
  cursor: pointer;
}

.tree {
  padding-bottom: 50px;
}
/* Pesquisa */

.search {
  position: relative;
}

.search-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  max-height: 300px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #5b6474 transparent;
  display: none;
  z-index: 1000;
}

.search input {
  width: 100%;
  padding: 12px 15px 12px 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--background);
  color: var(--text);
}


.search i {
  position: absolute;
  top: 9px;
  left: 11px;
  color: var(--text-secondary);
}

.search-item {
  padding: 10px 14px;
  cursor: pointer;
}

  .search-item:hover {
    background: var(--surface-hover);
  }

/*Menu*/

.menu {
  padding: 20px;
}

.menu-title {
  margin-top: 20px;
  margin-bottom: 12px;
  font-size: 12px;
  font-weight: bold;
  color: var(--text-secondary);
  letter-spacing: 1px;
}

.menu-item {
  display: flex;
  padding: 12px;
  border-radius: 8px;
  text-decoration: none;
  color: var(--text);
  cursor: pointer;
}

  .menu-item:hover {
    background: var(--surface-hover);
  }

  .menu-item.active {
    background: var(--primary);
    color: white;
  }

.content {
  margin-left: 410px;
  margin-right: 25px;
  flex: 1;
}

.endpoint-type {
  background: #1a83c4;
  color: white;
  padding: 6px 14px;
  border-radius: 5px;
  font-weight: bold;
  display: inline-block;
  margin-bottom: 15px;
}

.endpoint-url {
  color: var(--text-secondary);
  margin-top: 10px;
  margin-bottom: 40px;
}

.endpoint-header {
  margin-bottom: 40px;
  margin-top: 50px;
}

section {
  margin-bottom: 50px;
}

  section h2 {
    margin-bottom: 20px;
  }

  section p {
    line-height: 30px;
  }

pre {
  background: #0F172A;
  color: #E2E8F0;
  padding: 25px;
  border-radius: 8px;
  overflow: auto;
  font-size: 14px;
  scrollbar-width: thin;
  scrollbar-color: #5b6474 transparent;
}

ul {
  margin-left: 20px;
}

li {
  margin-bottom: 10px;
}

.theme-button {
  border: none;
  background: none;
  color: var(--text);
  cursor: pointer;
  font-size: 22px;
}

/*code container*/


code {
  display: inline-block;
  background: var(--surface-hover);
  padding: 8px 12px;
  border-radius: 5px;
}

.code-container {
  width: 550px;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-top: 20px;
  margin-right: 20px;
  background: var(--codebackground);
}

.code-header {
  height: 46px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 16px;
  background: var(--surface-hover);
  color: var(--text);
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  font-weight: 600;
}

.copy-button {
  background: transparent;
  border: none;
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  padding: 6px 10px;
  border-radius: 6px;
}

  .copy-button:hover {
    background: rgba(255, 255, 255, .08);
  }

.code-container pre {
  margin: 0;
  padding: 20px;
  background: var(--codebackground);
  color: #DCDCDC;
  max-width: 100%;
  max-height: 700px;
  font-size: 14px;
  line-height: 24px;
  font-family: Consolas, "Courier New", monospace;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #5b6474 transparent;
}

/*parametros*/

.parameter-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 5px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #5b6474 transparent;
  background: var(--surface);
  margin-right: 20px;
}

.drop-btn {
  width: 100%;
  border: none;
  background: transparent;
  padding: 15px 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
}

  .drop-btn:hover {
    background: var(--surface-hover);
  }

  .drop-btn i {
    transition: .25s;
  }

.parameter-item.active .drop-btn i {
  transform: rotate(180deg);
}

.param-obrigatorio {
  color: var(--text);
  font-size: 18px;
  font-weight: bold;
  line-height: 1;
}

.drop-content {
  max-height: 0;
  overflow: hidden;
  padding: 0 18px;
  background: var(--codebackground);
  border-top: 0 solid var(--border);
  opacity: 0;
  transition: max-height .25s ease, opacity .25s ease, padding .25s ease, border-top .25s ease;
}

.parameter-item.active .drop-content {
  max-height: 4200px;
  padding: 18px;
  opacity: 1;
  border-top: 1px solid var(--border);
}

.param-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;

}


.param-title {
  display: flex;
  align-items: center;
  gap: 4px;
}

.param-row {
  display: flex;
  align-items: flex-start;
  gap: 15px;
}

.param-label {
  min-width: 95px;
  font-weight: 600;
  color: var(--text-secondary);
}

.param-value {
  flex: 1;
  color: var(--text);
  word-break: break-word;
}

/*Arvore de Operações*/

.tree-title {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 8px 8px;
  border-radius: 8px;
  user-select: none;
}


  .tree-title:hover {
    background: var(--surface-hover);
  }

.tree-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px 8px 34px;
  text-decoration: none;
  color: var(--text);
}

  .tree-item:hover {
    background: var(--surface-hover);
  }

.tree-node > .tree-content {
  margin-left: 10px;
  overflow: visible;
  max-height: none;
  transition: max-height .25s ease;
}

.tree-node.closed > .tree-content {
  max-height: 0;
  overflow: hidden;
}

.arrow {
  transition: .25s;
  font-size: 12px;
}

.tree-node:not(.closed) > .tree-title > .arrow {
  transform: rotate(90deg);
}

.folder {
  color: #1a83c4;
}
/*links*/

#observacoes a {
  color: #1a83c4;
  text-decoration: underline;
}

  #observacoes a:hover {
    color: #0097ef;
    text-decoration: underline;
  }