* {
  box-sizing: border-box;
}

/* Base */
body {
  margin: 0;
  font-family: var(--font-body, "Hanken Grotesk", sans-serif);
  background: var(--color-paper, #0b1619);
  color: var(--color-ink-2, #c7e0e3);
}

.container {
  width: 100%;
  min-height: 100vh;
  padding: 20px;
  box-sizing: border-box;
}

/* Header */
h1 {
  text-align: center;
  margin-bottom: 5px;
}

.subtitle {
  text-align: center;
  color: #6E6E73;
  margin-bottom: 30px;
}

/* Card */
.card {
  background: var(--color-paper-2, #102126);
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  min-height: calc(100vh - 120px);
}

/* Layout */
.split {
  display: flex;
  gap: 20px;
  align-items: stretch;
}

.panel {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.panel:first-child {
  padding-right: 10px;
}

/* Inputs */
textarea {
  width: 100%;
  flex: 1;
  min-height: 200px;
  padding: 12px;
  border-radius: 8px;
  border: none;
  background: var(--color-paper, #0b1619);
  color: #e7fbf8;
  font-family: monospace;
  margin-bottom: 10px;
  resize: none;

  white-space: pre-wrap;
  word-break: break-word;
}

/* Buttons */
.buttons {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

button {
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  background: var(--color-rule, #1e3f46);
  color: white;
}

button.primary {
  background: #0071E3;
}

#message {
  color: #f87171;
  margin-top: 10px;
}

/* Viewer */
#viewer {
  flex: 1;
  min-height: 200px;
  background: var(--color-paper, #0b1619);
  padding: 12px;
  border-radius: 8px;
  overflow: auto;
  font-family: monospace;
  font-size: 14px;

  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: anywhere;

  -webkit-overflow-scrolling: touch;
}

/* JSON Styling */
.node {
  margin-left: 18px;
  position: relative;
  padding-left: 12px;
  border-left: 1px solid rgba(195,232,228,0.14);
}

.line {
  padding: 2px 4px;
}

.line:hover {
  background: rgba(34,199,184,0.08);
  border-radius: 4px;
}

.toggle {
  cursor: pointer;
  color: #0071E3;
  margin-right: 6px;
}

.key { color: #67e8f9; }
.string { color: #7dd3a8; }
.number { color: #f4bd62; }
.boolean { color: #fda4af; }
.null { color: #6E6E73; }

/* Scrollbars */
#viewer::-webkit-scrollbar,
textarea::-webkit-scrollbar {
  width: 8px;
}

#viewer::-webkit-scrollbar-thumb,
textarea::-webkit-scrollbar-thumb {
  background: var(--color-rule, #1e3f46);
  border-radius: 6px;
}

#viewer::-webkit-scrollbar-track {
  background: #041116;
}

#viewer {
  scrollbar-width: thin;
  scrollbar-color: var(--color-rule, #1e3f46) #041116;
}

/* Trust + SEO */
.trust {
  font-size: 12px;
  color: #6E6E73;
  margin-top: 8px;
}

.seo-section {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(195,255,248,0.08);
}

.seo-section h2 {
  margin-top: 20px;
  font-size: 20px;
}

.seo-section p {
  color: #1D1D1F;
}

.seo-section a {
  color: #8df7ec;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(141, 247, 236, 0.75);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.seo-section a:hover,
.seo-section a:focus {
  color: #f4bd62;
  text-decoration-color: #f4bd62;
}

.seo-section ul {
  margin-top: 10px;
  padding-left: 18px;
}

.seo-section li {
  margin-bottom: 6px;
}

/* Shared footer */
.footer {
  background: linear-gradient(135deg, var(--color-paper, #0b1619) 0%, var(--color-paper-2, #102126) 100%);
  border-top: 2px solid #0071E3;
  padding: 60px 40px 20px 40px;
  margin-top: 80px;
  color: #1D1D1F;
}

.footer-content {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-section h3 {
  font-size: 20px;
  color: #fff;
  margin: 0 0 15px 0;
  background: var(--color-accent, #0071E3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-section h4 {
  font-size: 15px;
  color: #1D1D1F;
  margin: 0 0 12px 0;
  font-weight: 600;
}

.footer-section p {
  font-size: 14px;
  color: #6E6E73;
  line-height: 1.6;
  margin: 0;
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section li {
  margin-bottom: 8px;
}

.footer-section a {
  color: #1D1D1F;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
}

.footer-section a:hover {
  color: #0071E3;
  padding-left: 4px;
}

.footer-bottom {
  border-top: 1px solid var(--color-rule, #1e3f46);
  padding-top: 20px;
  text-align: center;
  font-size: 13px;
  color: #86868B;
}

@media (max-width: 768px) {
  

  

  

  

  .nav-links {
    position: absolute;
    top: calc(100% + 12px);
    left: 15px;
    right: 15px;
    display: none;
    flex-direction: column;
    gap: 0;
    padding: 10px;
    background: linear-gradient(135deg, var(--color-paper-2, #102126) 0%, var(--color-paper, #0b1619) 100%);
    border: 1px solid var(--color-rule, #1e3f46);
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
  }

  

  .nav-links a:hover,
  .nav-links a:focus {
    background: rgba(34, 199, 184, 0.12);
  }

  .nav-links a::after {
    display: none;
  }

  .navbar.nav-open .nav-links {
    display: flex;
  }

  .menu-toggle {
    display: inline-flex;
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    margin: 0;
    padding: 0;
    border: 1px solid var(--color-rule, #1e3f46);
    border-radius: 8px;
    background: rgba(7, 28, 32, 0.72);
    color: #1D1D1F;
    font: inherit;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
  }

  .menu-toggle:hover,
  .menu-toggle:focus {
    background: rgba(34, 199, 184, 0.12);
  }

  .menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: #1D1D1F;
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
  }

  .navbar.nav-open .menu-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .navbar.nav-open .menu-toggle span:nth-child(2) {
    opacity: 0;
  }

  .navbar.nav-open .menu-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .footer {
    padding: 40px 20px 15px 20px;
  }

  .footer-content {
    gap: 30px;
    margin-bottom: 30px;
  }

  .footer-section h3 {
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  

  

  

  .nav-links {
    left: 10px;
    right: 10px;
  }

  

  .footer {
    padding: 30px 15px 10px 15px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
  }

  .footer-section h3 {
    font-size: 16px;
  }

  .footer-section h4 {
    font-size: 13px;
  }

  .footer-section p {
    font-size: 12px;
  }

  .footer-section a {
    font-size: 12px;
  }

  .footer-bottom p {
    font-size: 11px;
  }
}
