:root {
    --primary: #1a1a1a;
    --secondary: #333;
    --accent: #4CAF50;
    --text: #e0e0e0;
    --text-secondary: #b0b0b0;
}

*, body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--primary);
    color: var(--text);
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    line-height: 1.6;
}

header, footer {
    flex-shrink: 0;
    background: var(--secondary);
    padding: 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

footer {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

nav a, .tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0.8rem 1.5rem;
    min-width: 120px;
    border-radius: 5px;
    color: var(--text);
    text-decoration: none;
}

nav a {
    text-decoration: none;
}

.tab {
    cursor: pointer;
    background: transparent;
    border: none;
    font-size: 1rem;
    transition: background-color 0.2s;
}

nav a:hover, .tab:hover {
    background-color: var(--accent);
}

.tab:hover {
    color: var(--primary);
}

.tab.active {
    background: var(--accent);
    color: var(--primary);
    font-weight: bold;
    box-shadow: 0 0 0 2px var(--accent);
}

main {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 1rem;
    overflow: hidden;
    min-height: 0;
}

.tabs {
    display: flex;
    gap: 4px;
    background: var(--secondary);
    padding: 0.5rem 1rem;
    border-radius: 5px 5px 0 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.tab-content {
    display: none;
    background: var(--primary);
    border: 1px solid var(--secondary);
    border-top: none;
    padding: 1rem;
    border-radius: 0 0 5px 5px;
}

.tab-content.active {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
}

.json-editor-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* dark styling of the editor */
div.jsoneditor,
div.jsoneditor-menu {
  border-color: #4b4b4b;
}
div.jsoneditor-menu {
  background-color: #4b4b4b;
}
div.jsoneditor-tree,
div.jsoneditor textarea.jsoneditor-text {
  background-color: #666666;
  color: #ffffff;
}
div.jsoneditor-field,
div.jsoneditor-value {
  color: #ffffff;
}
table.jsoneditor-search div.jsoneditor-frame {
  background: #808080;
}

tr.jsoneditor-highlight,
tr.jsoneditor-selected {
  background-color: #808080;
}

div.jsoneditor-field[contenteditable=true]:focus,
div.jsoneditor-field[contenteditable=true]:hover,
div.jsoneditor-value[contenteditable=true]:focus,
div.jsoneditor-value[contenteditable=true]:hover,
div.jsoneditor-field.jsoneditor-highlight,
div.jsoneditor-value.jsoneditor-highlight {
  background-color: #808080;
  border-color: #808080;
}

div.jsoneditor-field.jsoneditor-highlight-active,
div.jsoneditor-field.jsoneditor-highlight-active:focus,
div.jsoneditor-field.jsoneditor-highlight-active:hover,
div.jsoneditor-value.jsoneditor-highlight-active,
div.jsoneditor-value.jsoneditor-highlight-active:focus,
div.jsoneditor-value.jsoneditor-highlight-active:hover {
  background-color: #b1b1b1;
  border-color: #b1b1b1;
}

div.jsoneditor-tree button:focus {
  background-color: #868686;
}

/* coloring of JSON in tree mode */
div.jsoneditor-readonly {
  color: #acacac;
}
div.jsoneditor td.jsoneditor-separator {
  color: #acacac;
}
div.jsoneditor-value.jsoneditor-string {
  color: #00ff88;
}
div.jsoneditor-value.jsoneditor-object,
div.jsoneditor-value.jsoneditor-array {
  color: #bababa;
}
div.jsoneditor-value.jsoneditor-number {
  color: #ff4040;
}
div.jsoneditor-value.jsoneditor-boolean {
  color: #ff8048;
}
div.jsoneditor-value.jsoneditor-null {
  color: #49a7fc;
}
div.jsoneditor-value.jsoneditor-invalid {
  color: white;
}