* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #020202;
  color: #f2f2f2;
  font-family: "Ubuntu Mono", monospace;
}

[v-cloak] {
  display: none;
}

.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hero {
  border-bottom: 1px solid #303030;
  padding: 1.5rem 2.5rem 1.25rem;
  background: linear-gradient(180deg, rgba(57, 255, 20, 0.12) 0%, rgba(2, 2, 2, 0) 100%);
}

.hero__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.hero__brand h1 {
  margin: 0;
  font-size: 2rem;
  font-weight: 700;
  color: #39ff14;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hero__tagline {
  margin: 0.75rem 0 0;
  max-width: 640px;
  color: #d0d0d0;
  font-size: 1rem;
}

.layout {
  flex: 1;
  display: grid;
  grid-template-columns: 320px 1fr;
  min-height: 0;
}

.sidebar {
  border-right: 1px solid #303030;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  background: #050505;
}

.sidebar__section h2 {
  margin: 0 0 1rem;
  color: #39ff14;
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.endpoint-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.endpoint-list__item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid #2a2a2a;
  border-radius: 8px;
  background: #0a0a0a;
  color: inherit;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.endpoint-list__item:hover {
  border-color: #39ff14;
}

.endpoint-list__item--active {
  border-color: #39ff14;
  background: rgba(57, 255, 20, 0.08);
}

.endpoint-list__item--overview {
  justify-content: center;
}

.endpoint-list__item--overview .endpoint-list__label {
  font-weight: 700;
  color: #39ff14;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.endpoint-list__method {
  font-size: 0.85rem;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  border: 1px solid #444;
  min-width: 48px;
  text-align: center;
  color: #39ff14;
}

.endpoint-list__label {
  font-size: 0.95rem;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.input-group span {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #9e9e9e;
}

.input-group input,
.custom-headers__item input,
textarea {
  background: #0f0f0f;
  border: 1px solid #2e2e2e;
  border-radius: 6px;
  padding: 0.55rem 0.7rem;
  color: #f8f8f8;
  font-family: inherit;
  font-size: 0.95rem;
}

.input-group input:focus,
.custom-headers__item input:focus,
textarea:focus {
  outline: 1px solid #39ff14;
  box-shadow: 0 0 0 3px rgba(57, 255, 20, 0.15);
}

.sidebar-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sidebar-button {
  background: #0a0a0a;
  border: 1px solid #2a2a2a;
  color: #e6e6e6;
  padding: 0.75rem;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.95rem;
  text-align: center;
  transition: border-color 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.sidebar-button:hover {
  border-color: #39ff14;
  background: rgba(57, 255, 20, 0.08);
  color: #39ff14;
}

.sidebar-button:active {
  background: rgba(57, 255, 20, 0.15);
}

.ghost {
  background: none;
  border: 1px solid #2a2a2a;
  color: #e6e6e6;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.ghost:hover {
  border-color: #39ff14;
  color: #39ff14;
}

.ghost--danger {
  color: #ff6b6b;
  border-color: rgba(255, 107, 107, 0.4);
}

.ghost--danger:hover {
  border-color: #ff6b6b;
}

.ghost--active {
  background: rgba(57, 255, 20, 0.15);
  border-color: #39ff14;
  color: #39ff14;
}

.content {
  padding: 2rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  background: radial-gradient(circle at top left, rgba(57, 255, 20, 0.08), transparent 55%), #000;
}

.panel {
  border: 1px solid #2d2d2d;
  border-radius: 14px;
  padding: 1.5rem;
  background: rgba(4, 4, 4, 0.95);
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.65);
}

.panel__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.panel__header-main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.panel__header h2,
.panel__header h3 {
  margin: 0;
  font-size: 1.25rem;
}

.panel__method {
  font-size: 0.8rem;
  border: 1px solid #39ff14;
  border-radius: 6px;
  padding: 0.1rem 0.45rem;
  margin-right: 0.75rem;
  color: #39ff14;
}

.panel__path {
  border: 1px solid #2d2d2d;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  color: #d0d0d0;
  font-size: 0.85rem;
}

.panel__summary {
  margin: 0 0 1rem;
  color: #dcdcdc;
  line-height: 1.5;
}

.panel__insights,
.panel__tips {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.4rem;
}

.panel__insights li,
.panel__tips li {
  line-height: 1.4;
  color: #bcbcbc;
}

.builder {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.builder__row h4 {
  margin: 0 0 0.75rem;
  color: #39ff14;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
}

.builder__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.builder__textarea {
  width: 100%;
  resize: vertical;
  min-height: 220px;
  line-height: 1.4;
  white-space: pre;
}

.builder__hint {
  margin: 0.5rem 0 0;
  font-size: 0.8rem;
  color: #868686;
}

.status {
  font-size: 0.8rem;
  color: #39ff14;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.status--error {
  color: #ff6b6b;
}

.preset-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.pipeline-flow {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 8rem;
  padding: 2rem 2rem 2rem 3rem;
  overflow-x: auto;
}

.pipeline-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
  flex: 0 0 auto;
  min-width: max-content;
}

.pipeline-stage__label {
  padding: 1rem 1.5rem;
  border: 2px solid #39ff14;
  border-radius: 10px;
  background: rgba(57, 255, 20, 0.08);
  color: #39ff14;
  font-size: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  white-space: nowrap;
  flex-shrink: 0;
}

.pipeline-arrow {
  color: #39ff14;
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  flex-shrink: 0;
  align-self: flex-start;
  padding-top: 1rem;
}

.pipeline-stage__json {
  margin: 0;
  width: auto;
  max-width: none;
  overflow: visible;
  background: transparent !important;
  border: none;
  padding: 0;
  font-size: 0.75rem;
  line-height: 1.35;
}

.pipeline-stage__json code {
  display: block;
  font-size: 0.75rem;
  line-height: 1.35;
  white-space: pre;
  background: transparent !important;
}

.pipeline-column:last-child .pipeline-stage__label {
  border-color: #666666;
  background: rgba(102, 102, 102, 0.08);
  color: #999999;
}

.pipeline-column:last-child .pipeline-stage__json code,
.pipeline-column:last-child .pipeline-stage__json code * {
  color: #888888 !important;
}

.code-block {
  margin: 0;
  max-height: 400px;
  overflow: auto;
  border-radius: 10px;
  background: #050505 !important;
  border: 1px solid #2d2d2d;
  padding: 1rem;
}

.code-block code {
  font-size: 0.9rem;
  line-height: 1.6;
}

.code-block--compact {
  max-height: none;
  overflow: visible;
}

.code-block--compact code {
  font-size: 0.75rem;
  line-height: 1.4;
}

.token-flow {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.5rem;
  font-family: "Ubuntu Mono", monospace;
  font-size: 0.85rem;
}

.token-flow__step {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.token-flow__step--cdn {
  margin-top: 0.5rem;
}

.token-flow__box {
  border: 2px solid #39ff14;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  color: #39ff14;
  font-weight: 700;
  min-width: 60px;
  text-align: center;
  background: rgba(57, 255, 20, 0.05);
}

.token-flow__arrow {
  color: #fff;
  font-weight: 400;
  white-space: nowrap;
}

.token-flow__text {
  color: #fff;
  white-space: nowrap;
}

.token-flow__token {
  color: #39ff14;
  font-weight: 400;
}

.token-flow__spacer {
  height: 0.5rem;
}

/* Reference Container (replaces modal) */
.reference-container {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.docs {
  padding: 2.5rem 2.5rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  background: radial-gradient(circle at top left, rgba(57, 255, 20, 0.08), transparent 55%), #000;
}

.docs-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.docs-section h2 {
  margin: 0;
  color: #39ff14;
  font-size: 1.5rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.docs-section h3 {
  margin: 0 0 0.5rem;
  color: #39ff14;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.docs-intro {
  margin: 0;
  color: #d8d8d8;
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: 820px;
}

.docs-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.docs-feature,
.docs-card {
  border: 1px solid #2d2d2d;
  border-radius: 10px;
  padding: 1.2rem 1.3rem;
  background: rgba(10, 10, 10, 0.85);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.docs-feature-title {
  margin: 0;
  color: #e8e8e8;
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.docs-feature p,
.docs-card p {
  margin: 0;
  color: #bcbcbc;
  font-size: 0.95rem;
  line-height: 1.55;
}

.docs-list {
  margin: 0;
  padding-left: 1.2rem;
  color: #c8c8c8;
  line-height: 1.6;
}

.docs-list li {
  margin: 0.45rem 0;
}

.docs-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
}

.docs-table th,
.docs-table td {
  border: 1px solid #2d2d2d;
  padding: 0.65rem 0.75rem;
  text-align: left;
  font-size: 0.9rem;
  color: #d0d0d0;
}

.docs-table thead th {
  background: rgba(57, 255, 20, 0.08);
  color: #39ff14;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.docs-meta {
  margin: 0;
  color: #9e9e9e;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.docs-link {
  color: #39ff14;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.docs-link:hover {
  opacity: 0.8;
  text-decoration: underline;
}

.example-nav {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.example-nav__item {
  border: 1px solid #2d2d2d;
  background: #0f0f0f;
  color: #dcdcdc;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.example-nav__item:hover {
  border-color: #39ff14;
  color: #39ff14;
}

.example-nav__item:focus-visible {
  outline: 2px solid rgba(57, 255, 20, 0.5);
  outline-offset: 2px;
}

.example-nav__item--active {
  background: rgba(57, 255, 20, 0.15);
  border-color: #39ff14;
  color: #39ff14;
}

.example-description {
  margin: 0;
  color: #c8c8c8;
  font-size: 0.95rem;
  line-height: 1.5;
}

.reference-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid #2d2d2d;
  background: rgba(57, 255, 20, 0.05);
}

.reference-header h2 {
  margin: 0;
  color: #39ff14;
  font-size: 1.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.input-type-tabs {
  display: flex;
  gap: 0.25rem;
  padding: 1.5rem 2rem 0;
  border-bottom: 1px solid #2d2d2d;
  overflow-x: auto;
  background: rgba(4, 4, 4, 0.95);
}

.input-type-tab {
  background: #0f0f0f;
  border: 1px solid #2a2a2a;
  border-bottom: none;
  color: #9e9e9e;
  padding: 0.75rem 1.25rem;
  border-radius: 8px 8px 0 0;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: all 0.25s ease;
  white-space: nowrap;
}

.input-type-tab:hover {
  border-color: #39ff14;
  color: #e6e6e6;
}

.input-type-tab--active {
  background: rgba(57, 255, 20, 0.1);
  border-color: #39ff14;
  color: #39ff14;
  font-weight: 700;
}

.input-reference-body {
  padding: 2rem;
  background: rgba(4, 4, 4, 0.95);
}

.input-type-content h3 {
  margin: 0 0 0.5rem;
  color: #39ff14;
  font-size: 1.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.input-description {
  margin: 0 0 2rem;
  color: #d0d0d0;
  font-size: 1.05rem;
  line-height: 1.5;
}

.param-section {
  margin-bottom: 2rem;
}

.param-section h4 {
  margin: 0 0 0.75rem;
  color: #39ff14;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid #2a2a2a;
  padding-bottom: 0.5rem;
}

.param-section ul {
  margin: 0;
  padding-left: 1.5rem;
  list-style: disc;
}

.param-section li {
  margin: 0.5rem 0;
  color: #d0d0d0;
  line-height: 1.6;
}

.param-section code {
  background: #0f0f0f;
  border: 1px solid #2a2a2a;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: #39ff14;
  font-size: 0.9em;
}

.param-section .code-block {
  margin-top: 0.75rem;
}

/* Overview Panel Styles */
.overview-panel {
  max-width: 900px;
}

.overview-content {
  color: #d0d0d0;
  line-height: 1.7;
  font-size: 1.05rem;
}

.overview-intro {
  margin: 0 0 2rem;
  font-size: 1.15rem;
  color: #e8e8e8;
  line-height: 1.8;
}

.overview-content h3 {
  margin: 2rem 0 1rem;
  color: #39ff14;
  font-size: 1.3rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid #2a2a2a;
  padding-bottom: 0.5rem;
}

.overview-content h3:first-of-type {
  margin-top: 0;
}

.overview-content p {
  margin: 0 0 1.25rem;
  line-height: 1.7;
}

.overview-content code {
  background: #0f0f0f;
  border: 1px solid #2a2a2a;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  color: #39ff14;
  font-size: 0.95em;
}

.overview-content a {
  color: #39ff14;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.overview-content a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

@media (max-width: 1200px) {
  .layout {
    grid-template-columns: 280px 1fr;
  }
}

@media (max-width: 960px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 1.5rem;
    border-right: none;
    border-bottom: 1px solid #303030;
  }

  .sidebar__section {
    flex: 1 1 280px;
  }
}

@media (max-width: 640px) {
  .hero {
    padding: 1.5rem;
  }

  .layout {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 1.5rem;
  }

  .docs {
    padding: 1.5rem 1.5rem 2rem;
    gap: 1.5rem;
  }

  .panel {
    padding: 1.25rem;
  }

  .panel__header {
    flex-direction: column;
    align-items: flex-start;
  }
}

