@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;600;700&display=swap");

:root {
  --primary-color: #ffffff;
  --secondary-background-color: #f9f9f9;
  --card-background-color: #ffffff;
  --text-color: #333333;
  --accent-color: #3498db;
  --border-color: #dddddd;
  --pre-border-color: #ddd;
  --header-height-desktop: 70px;
  --header-height-mobile: 60px;
  --sidebar-width-desktop: 280px;
  --line-thickness: 1.5px;
  --code-text-color: #333;
  --table-header-bg: #f2f2f2;
  --input-bg-color: #ffffff;
  --input-text-color: #333333;
  --input-border-color: #dddddd;
  --button-text-color: #ffffff;
  --box-shadow-light: rgba(0, 0, 0, 0.05);
  --box-shadow-medium: rgba(0, 0, 0, 0.1);
  --pre-background-color: var(--secondary-background-color);
}
body.light-yellow {
  --accent-color: #ffc300;
  --button-text-color: #333333;
}
body.dark,
body.dark-blue,
body.dark-yellow {
  --primary-color: #1c2128;
  --secondary-background-color: #22272e;
  --card-background-color: #22272e;
  --text-color: #c9d1d9;
  --border-color: #30363d;
  --pre-border-color: var(--border-color);
  --code-text-color: #c9d1d9;
  --table-header-bg: #272c34;
  --input-bg-color: #22272e;
  --input-text-color: #c9d1d9;
  --input-border-color: #30363d;
  --button-text-color: #1c2128;
  --box-shadow-light: rgba(0, 0, 0, 0.2);
  --box-shadow-medium: rgba(0, 0, 0, 0.3);
  --pre-background-color: var(--secondary-background-color);
}
body.dark-blue {
  --accent-color: #58a6ff;
}
body.dark-yellow {
  --accent-color: #ffc300;
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family: "Open Sans", sans-serif;
  background-color: var(--primary-color);
  color: var(--text-color);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
}
.preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #121212;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.spinner-modern {
  width: 60px;
  height: 60px;
  border: 6px solid transparent;
  border-top: 6px solid #00bcd4;
  border-radius: 50%;
  animation: spin 0.8s cubic-bezier(0.55, 0.3, 0.1, 1) infinite;
  background: conic-gradient(from 0deg, #00bcd4, #00acc1, #00838f, #00bcd4);
  -webkit-mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 6px),
    black calc(100% - 6px)
  );
  mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 6px),
    black calc(100% - 6px)
  );
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.header {
  background-color: var(--primary-color);
  color: var(--text-color);
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-height-mobile);
  border-bottom: 1px solid var(--border-color);
  transition: height 0.3s ease;
}
.header-logo {
  font-size: 1.3em;
  font-weight: 700;
  color: var(--accent-color);
  flex-shrink: 0;
}
.header-logo span {
  color: var(--text-color);
  font-weight: 300;
}
.hamburger-menu {
  display: none;
  cursor: pointer;
  font-size: 1.4em;
  color: var(--text-color);
  padding: 0 10px;
  margin-left: auto;
}

.hamburger-menu {
  cursor: pointer;
  font-size: 24px;
  transition: transform 0.3s ease;
}

.hamburger-menu.open {
  transform: rotate(90deg);
}

.main-container {
  display: flex;
  flex-grow: 1;
  padding-top: 0;
}
.sidebar {
  width: var(--sidebar-width-desktop);
  background-color: var(--secondary-background-color);
  padding: 20px;
  height: calc(100dvh - var(--header-height-desktop));
  overflow-y: auto;
  border-right: 1px solid var(--border-color);
  transition:
    transform 0.3s ease,
    width 0.3s ease;
  display: flex;
  flex-direction: column;
}
.sidebar-section-header {
  font-size: 0.85em;
  font-weight: 600;
  margin-top: 20px;
  margin-bottom: 10px;
  color: var(--accent-color);
  padding-bottom: 5px;
  border-bottom: 1px solid var(--border-color);
}
.sidebar-section-header:first-child {
  margin-top: 0;
}
.sidebar ul {
  list-style-type: none;
  padding-left: 0;
}
.sidebar ul li {
  padding-left: 0;
}
.sidebar ul li .category-name,
.sidebar ul li .doc-item-name,
.sidebar ul li a.doc-main-item {
  padding: 10px 5px;
  cursor: pointer;
  border-radius: 4px;
  transition:
    background-color 0.2s ease,
    color 0.2s ease;
  display: flex;
  align-items: center;
  position: relative;
  font-size: 0.8em;
  font-weight: 600;
  color: var(--text-color);
}
.sidebar ul li .category-name i {
  color: var(--accent-color);
  margin-right: 8px;
  flex-shrink: 0;
  width: 1.2em;
  text-align: center;
}
.sidebar ul li .category-name .category-text-content {
  flex-grow: 1;
  text-align: left;
}
.sidebar ul li .category-name .arrow {
  margin-left: auto;
  flex-shrink: 0;
}
.sidebar ul li a.doc-main-item {
  text-decoration: none;
  font-weight: normal;
}
.sidebar ul li .doc-item-name {
  font-weight: normal;
}
.sidebar ul li .category-name:hover,
.sidebar ul li .doc-item-name:hover,
.sidebar ul li a.doc-main-item:hover {
  background-color: color-mix(in srgb, var(--border-color) 50%, transparent);
}
.sidebar ul li .category-name.active,
.sidebar ul li a.doc-main-item.active {
  background-color: var(--accent-color);
  color: var(--button-text-color);
}
.sidebar ul li .category-name.active i {
  color: var(--button-text-color);
}
.sidebar ul li .category-name .arrow,
.sidebar ul li .doc-item-name .arrow {
  font-size: 0.75em;
  transition: transform 0.3s ease;
}
.sidebar ul li .category-name.active .arrow {
  color: var(--button-text-color);
}
.sidebar ul li .api-list,
.sidebar ul li .doc-sub-list {
  list-style-type: none;
  padding-left: 0;
  margin-left: 10px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  position: relative;
}
.sidebar ul li .api-list.expanded,
.sidebar ul li .doc-sub-list.expanded {
  max-height: 1000px;
  transition: max-height 0.5s ease-in;
}
.sidebar ul li .api-list::before,
.sidebar ul li .doc-sub-list::before {
  content: "";
  position: absolute;
  left: 0px;
  top: 0;
  width: var(--line-thickness);
  background-color: var(--accent-color);
  z-index: 0;
  height: 100%;
}
.sidebar ul li .api-list li,
.sidebar ul li .doc-sub-list li {
  position: relative;
  padding-left: 22px;
}
.sidebar ul li .api-list li::before,
.sidebar ul li .doc-sub-list li::before {
  content: "";
  position: absolute;
  left: 0px;
  top: 0.75em;
  width: 12px;
  height: var(--line-thickness);
  background-color: var(--accent-color);
  z-index: 0;
}
.sidebar ul li .api-list li::after,
.sidebar ul li .doc-sub-list li::after {
  content: "";
  position: absolute;
  left: 0px;
  top: 0;
  bottom: 0;
  width: var(--line-thickness);
  background-color: var(--accent-color);
  z-index: -1;
}
.sidebar ul li .api-list li:last-child::after,
.sidebar ul li .doc-sub-list li:last-child::after {
  height: 0.75em;
  bottom: auto;
}
.sidebar ul li .api-list li a,
.sidebar ul li .doc-sub-list li a {
  display: block;
  padding: 8px 5px;
  text-decoration: none;
  color: var(--text-color);
  border-radius: 4px;
  font-size: 0.7em;
  transition: color 0.2s ease;
  position: relative;
  z-index: 1;
}
.sidebar ul li .api-list li a:hover,
.sidebar ul li .doc-sub-list li a:hover {
  color: var(--text-color);
  padding-left: 5px;
}
.sidebar ul li .api-list li a.active-endpoint {
  color: var(--accent-color);
  font-weight: bold;
  background-color: color-mix(in srgb, var(--border-color) 60%, transparent);
}
.sidebar-theme-switcher {
  margin-top: auto;
  padding: 15px 5px;
  border-top: 1px solid var(--border-color);
}
.sidebar-theme-switcher label {
  font-size: 0.75em;
  margin-right: 5px;
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
}
.sidebar-theme-switcher select {
  width: 100%;
  padding: 8px;
  border: 1px solid var(--input-border-color);
  background-color: var(--input-bg-color);
  color: var(--input-text-color);
  border-radius: 4px;
  font-size: 0.75em;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}
.sidebar-theme-switcher select:hover,
.sidebar-theme-switcher select:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent-color) 20%, transparent);
}
#sidebarApiUrlSwitcherSelect {
  margin-bottom: 15px;
}
.main-content {
  flex-grow: 1;
  padding: 25px;
  overflow-y: auto;
  height: calc(100dvh - var(--header-height-desktop));
  background-color: var(--primary-color);
}
.content-search-container {
  margin-bottom: 20px;
  position: relative;
}
.content-search-container .fa-search {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--input-text-color);
  opacity: 0.7;
  font-size: 0.65em;
}
.content-search-input {
  width: 100%;
  padding: 10px 12px 10px 35px;
  border: 1px solid var(--input-border-color);
  background-color: var(--input-bg-color);
  color: var(--input-text-color);
  border-radius: 4px;
  font-size: 0.65em;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}
.content-search-input:hover,
.content-search-input:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent-color) 20%, transparent);
}
.api-endpoint-container {
  margin-bottom: 15px;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background-color: var(--card-background-color);
  box-shadow: 0 2px 5px var(--box-shadow-light);
  transition: box-shadow 0.3s ease;
  overflow: visible;
}
.api-endpoint-container:hover {
  box-shadow: 0 4px 10px var(--box-shadow-medium);
}
.endpoint-header {
  padding: 15px 20px;
  cursor: pointer;
  background-color: var(--secondary-background-color);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  position: relative;
}
.api-endpoint-container.details-open .endpoint-header {
  border-bottom-style: dashed;
}
.endpoint-header .arrow {
  font-size: 1.2em;
  transition: transform 0.3s ease;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}
.endpoint-method {
  padding: 2px 8px;
  border-radius: 4px;
  color: #ffffff;
  font-weight: bold;
  font-size: 0.6em;
  text-transform: uppercase;
  flex-shrink: 0;
}
.method-GET {
  background-color: #27ae60;
}
.method-POST {
  background-color: #2980b9;
}
.method-PUT {
  background-color: #f39c12;
}
.method-DELETE {
  background-color: #c0392b;
}
.method-PATCH {
  background-color: #8e44ad;
}
.endpoint-title {
  font-size: 0.85em;
  font-weight: 600;
  color: var(--text-color);
  margin-left: 0px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.endpoint-header-main-info {
  display: flex;
  flex-direction: column;
  width: calc(100% - 30px);
  overflow: hidden;
}
.endpoint-header-top-line {
  display: flex;
  align-items: center;
  width: 100%;
  margin-bottom: 8px;
}
.endpoint-header-top-line .endpoint-method {
  margin-right: 10px;
}
.endpoint-url {
  font-family: "Courier New", Courier, monospace;
  font-size: 0.65em;
  color: var(--text-color);
  background-color: color-mix(
    in srgb,
    var(--accent-color) 10%,
    var(--primary-color)
  );
  padding: 2px 5px;
  border-radius: 3px;
  word-break: break-all;
  margin-top: 0;
  display: block;
  width: 100%;
}
.endpoint-details-injected {
  padding: 20px;
  border-top: 1px dashed var(--border-color);
  animation: fadeInDetails 0.3s ease-out;
  background-color: var(--card-background-color);
}
@keyframes fadeInDetails {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.endpoint-details-injected h4 {
  font-size: 0.8em;
  color: var(--accent-color);
  margin-top: 15px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 5px;
}
.endpoint-details-injected h4:first-child {
  margin-top: 0;
}
.endpoint-details-injected p {
  margin-bottom: 10px;
  font-size: 0.6em;
}
pre[class*="language-"] {
  background-color: var(--pre-background-color);
  padding: 1em;
  margin: 0.5em 0;
  font-size: 0.6em;
  overflow: auto;
  border: 1px solid var(--pre-border-color);
  border-radius: 0.5em;
  color: var(--code-text-color);
}
.parameters-table,
.headers-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 15px;
  font-size: 0.6em;
}
.parameters-table th,
.parameters-table td,
.headers-table th,
.headers-table td {
  border: 1px solid var(--border-color);
  padding: 10px;
  text-align: left;
}
.parameters-table th,
.headers-table th {
  background-color: var(--table-header-bg);
  font-weight: 600;
}
.parameters-table td span.required {
  color: #c0392b;
  font-weight: bold;
}
.parameters-table td span.param-type {
  font-style: italic;
  color: color-mix(in srgb, var(--text-color) 70%, transparent);
}
.try-it-out-section {
  margin-top: 20px;
  padding: 15px;
  border: 1px solid var(--border-color);
  border-radius: 5px;
  background-color: var(--secondary-background-color);
}
.try-it-out-section h4 {
  margin-top: 0;
}
.try-it-out-controls {
  margin-top: 15px;
  display: flex;
  gap: 10px;
}
.try-it-out-section .form-group {
  margin-bottom: 12px;
}
.try-it-out-section label {
  display: block;
  font-weight: 600;
  margin-bottom: 5px;
  font-size: 0.6em;
}
.try-it-out-section input[type="text"],
.try-it-out-section input[type="number"],
.try-it-out-section input[type="url"],
.try-it-out-section select,
.try-it-out-section textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--input-border-color);
  background-color: var(--input-bg-color);
  color: var(--input-text-color);
  border-radius: 4px;
  font-size: 0.6em;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}
.try-it-out-section input[type="text"]:focus,
.try-it-out-section input[type="number"]:focus,
.try-it-out-section input[type="url"]:focus,
.try-it-out-section select:focus,
.try-it-out-section textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent-color) 20%, transparent);
}
.try-it-out-section .radio-group label,
.try-it-out-section .checkbox-group label {
  font-weight: normal;
  margin-right: 15px;
  display: inline-flex;
  align-items: center;
}
.try-it-out-section .radio-group input,
.try-it-out-section .checkbox-group input {
  margin-right: 5px;
}
.btn {
  background-color: var(--accent-color);
  color: var(--button-text-color);
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.6em;
  font-weight: 600;
  transition:
    background-color 0.2s ease,
    transform 0.1s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn.btn-secondary {
  background-color: var(--secondary-background-color);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}
.btn.btn-secondary:hover {
  background-color: color-mix(in srgb, var(--border-color) 50%, transparent);
}
.btn:hover {
  background-color: color-mix(in srgb, var(--accent-color) 80%, black);
}
.btn:active {
  transform: translateY(1px);
}
.btn-execute {
  margin-top: 0;
}
.response-section {
  margin-top: 20px;
}
.response-section h5 {
  font-size: 0.6em;
  color: var(--text-color);
  margin-bottom: 8px;
}
.response-loader {
  border: 5px solid var(--border-color);
  border-top: 5px solid var(--accent-color);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 30px auto;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}
.response-media {
  max-width: 100%;
  max-height: 400px;
  display: block;
  margin-top: 10px;
  border: 1px solid var(--border-color);
  background-color: var(--primary-color);
}
.response-status {
  font-weight: bold;
  margin-bottom: 10px;
}
.status-200 {
  color: #27ae60;
}
.status-201 {
  color: #27ae60;
}
.status-204 {
  color: #27ae60;
}
.status-error-app {
  color: #e74c3c;
}
.status-400 {
  color: #e74c3c;
}
.status-401 {
  color: #f39c12;
}
.status-403 {
  color: #c0392b;
}
.status-404 {
  color: #e74c3c;
}
.status-500 {
  color: #c0392b;
}
.page-content-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 20px;
  background-color: var(--card-background-color);
  border-radius: 8px;
  box-shadow: 0 4px 15px var(--box-shadow-light);
}
.page-hero {
  background-color: var(--accent-color);
  color: var(--button-text-color);
  padding: 40px 20px;
  text-align: center;
  border-radius: 8px;
  margin-bottom: 30px;
}
.page-hero h1 {
  font-size: 1.4em;
  margin-bottom: 10px;
}
.page-hero p {
  font-size: 0.7em;
  opacity: 0.9;
}
.page-section {
  margin-bottom: 30px;
  padding: 20px;
  background-color: var(--secondary-background-color);
  border-radius: 6px;
}
.page-section h3 {
  font-size: 1em;
  color: var(--accent-color);
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}
.page-section p,
.page-section ul {
  font-size: 0.7em;
  line-height: 1.4;
  margin-bottom: 10px;
}
.page-section ul {
  list-style: none;
  padding-left: 0;
}
.page-section ul li {
  padding-left: 20px;
  position: relative;
  margin-bottom: 8px;
}
.page-section ul li i {
  position: absolute;
  left: 0;
  top: 4px;
  color: var(--accent-color);
  font-size: 1.1em;
}
.contact-list li {
  display: flex;
  align-items: center;
  margin-bottom: 12px !important;
}
.contact-list li i {
  font-size: 1.3em;
  width: 12px;
  text-align: center;
  margin-right: 10px;
  top: 3px !important;
}
.contact-list li a {
  color: var(--accent-color);
  text-decoration: none;
}
.contact-list li a:hover {
  text-decoration: underline;
}

@media (min-width: 769px) {
  .header {
    height: var(--header-height-desktop);
    position: fixed;
    width: 100%;
  }
  .main-container {
    padding-top: var(--header-height-desktop);
  }
  .sidebar {
    height: calc(100dvh - var(--header-height-desktop));
  }
  .main-content {
    height: calc(100dvh - var(--header-height-desktop));
  }
  .api-endpoint-container.view-table {
    display: block;
    width: 100%;
    margin-bottom: 0;
    border-bottom: 1px solid var(--border-color);
    border-radius: 0;
    box-shadow: none;
  }
  .api-endpoint-container.view-table:hover {
    background-color: var(--secondary-background-color);
  }
  .api-endpoint-container.view-table .endpoint-header {
    background-color: transparent;
    padding: 12px 10px;
  }
  .api-endpoint-container.view-table.details-open .endpoint-header {
    border-bottom-style: dashed;
  }
  .api-endpoint-container.view-table .endpoint-title {
    font-size: 0.9em;
  }
  .main-content.table-view .api-endpoint-container {
    border: none;
    box-shadow: none;
    border-bottom: 1px solid var(--border-color);
  }
  .main-content.table-view .api-endpoint-container:last-child {
    border-bottom: none;
  }
}
@media (max-width: 768px) {
  .header {
    height: var(--header-height-mobile);
  }
  .hamburger-menu {
    display: block;
    z-index: 1002;
  }
  .sidebar {
    position: fixed;
    left: 0;
    top: var(--header-height-mobile);
    width: 80%;
    max-width: 300px;
    height: calc(100dvh - var(--header-height-mobile));
    transform: translateX(-100%);
    z-index: 999;
    background-color: var(--secondary-background-color);
    box-shadow: 2px 0 5px var(--box-shadow-medium);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .main-content {
    height: calc(100dvh - var(--header-height-mobile));
  }
  .api-endpoint-container {
    margin-left: auto;
    margin-right: auto;
  }
  .endpoint-header .arrow {
    top: 15px;
    transform: none;
  }
  .endpoint-header-main-info {
    width: calc(100% - 30px);
  }
  .endpoint-title {
    margin-left: 0;
  }
  .endpoint-header-top-line .endpoint-method {
    margin-right: 5px;
  }
}

.doc-main-item i {
  margin-right: 8px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.card {
  background-color: transparent;
  border-left: 4px solid #4e73df;
  padding: 10px;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.card h3 {
  font-size: 0.8rem;
  color: #3498db;
}

.card .value {
  font-size: 0.7rem;
  font-weight: bold;
  color: #3498db;
}

.buttonDonation {
  display: inline-block;
  margin-top: 1rem; /* tambahkan jarak atas */
  padding: 0.75em 0.90em;
  font-size: 0.6rem;
  font-weight: 600;
  color: #ffffff;
  background-color: #1f6feb;
  border: none;
  border-radius: 0.5em;
  text-decoration: none;
  text-align: center;
  transition: background-color 0.3s ease, transform 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.buttonDonation:hover {
  background-color: #1558d6;
  transform: translateY(-2px);
}

.buttonDonation:active {
  transform: scale(0.98);
}
