@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=JetBrains+Mono:wght@400;500;600&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  color-scheme: light;
  --sg-ink: #17142a;
  --sg-ink-soft: #2e2b45;
  --sg-muted: #55596b;
  --sg-iris: #5635e6;
  --sg-iris-light: #7254ef;
  --sg-iris-hover: #4829cf;
  --sg-iris-wash: #efebfd;
  --sg-iris-border: #d9d2f5;
  --sg-surface: #f7f6fc;
  --sg-border: #e5e2f0;
  --sg-border-subtle: #eceaf4;
  --sg-post-bg: #dcf4e4;
  --sg-post-text: #1c7c44;
  --sg-get-bg: #e3e8fc;
  --sg-get-text: #3a47ba;
  --sg-del-bg: #fce6e6;
  --sg-del-text: #c63636;
  --sg-font-sans: 'Plus Jakarta Sans', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --sg-font-mono: 'JetBrains Mono', 'DM Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: linear-gradient(180deg, #ffffff 0%, #f6f4fc 22%, #faf9fe 72%, #f6f4fc 100%);
  color: var(--sg-ink);
  font-family: var(--sg-font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
  min-height: 100vh;
}

::selection {
  background: var(--sg-iris);
  color: #ffffff;
}

button {
  font-family: var(--sg-font-sans);
}

code,
pre,
textarea.sg-code-editor {
  font-family: var(--sg-font-mono);
  font-variant-numeric: tabular-nums;
}

/* 1. Sticky Top Navigation Bar */
.sg-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-header-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.sg-brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.sg-brand-logo {
  height: 28px;
  width: auto;
  display: block;
}

.sg-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 100%;
}

.sg-nav a {
  display: inline-flex;
  align-items: center;
  height: 100%;
  color: var(--sg-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  border-bottom: 2px solid transparent;
  transition: color 160ms ease, border-color 160ms ease;
}

.sg-nav a:hover,
.sg-nav a.sg-nav-active {
  color: var(--sg-ink);
  font-weight: 600;
  border-bottom-color: var(--sg-iris);
}

.sg-header-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

.sg-version-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  color: var(--sg-ink);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.sg-version-dot {
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background: #22b562;
  display: inline-block;
}

.sg-auth-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  background: linear-gradient(135deg, #5635e6 0%, #7254ef 100%);
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  line-height: 16px;
  padding: 10px 18px;
  border-radius: 9999px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(86, 53, 230, 0.24);
  transition: transform 150ms ease, filter 150ms ease;
}

.sg-auth-pill-btn:hover {
  filter: brightness(1.06);
}

.sg-auth-pill-btn:active {
  transform: scale(0.98);
}

.sg-auth-pill-btn.sg-auth-active {
  background: linear-gradient(135deg, #1b7f46 0%, #239b56 100%);
  box-shadow: 0 6px 16px rgba(27, 127, 70, 0.22);
}

/* 2. Main Shell & Hero */
.sg-main {
  max-width: 1140px;
  margin: 0 auto;
  padding: 36px 24px 0;
}

.sg-hero-grid {
  display: grid;
  grid-template-columns: 1.12fr 1fr;
  align-items: center;
  gap: 44px;
  margin-bottom: 30px;
}

.sg-hero-eyebrow {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--sg-iris);
}

.sg-hero-title {
  margin: 0 0 16px;
  font-size: clamp(32px, 3.6vw, 44px);
  font-weight: 700;
  line-height: 1.09;
  letter-spacing: -0.03em;
  color: var(--sg-ink);
  text-wrap: balance;
}

.sg-hero-subtitle {
  margin: 0 0 24px;
  max-width: 500px;
  font-size: 16px;
  line-height: 1.58;
  color: var(--sg-muted);
}

.sg-hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.sg-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #5635e6 0%, #7254ef 100%);
  color: #ffffff;
  border: 1px solid transparent;
  border-radius: 9999px;
  padding: 12px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(86, 53, 230, 0.22);
  transition: transform 150ms ease, filter 150ms ease;
}

.sg-btn-primary:hover {
  filter: brightness(1.06);
}

.sg-btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  color: var(--sg-ink);
  border: 1px solid #cbc5ea;
  border-radius: 9999px;
  padding: 12px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 150ms ease, background-color 150ms ease;
}

.sg-btn-secondary:hover {
  border-color: var(--sg-iris);
  background: var(--sg-iris-wash);
}

.sg-hero-media {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #e9eef0;
  border: 1px solid var(--sg-border);
  box-shadow: 0 20px 44px -18px rgba(23, 20, 42, 0.22);
}

.sg-hero-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sg-hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* 3. 3-Column Feature Capability Strip */
.sg-feature-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(23, 20, 42, 0.04);
  margin-bottom: 24px;
  overflow: hidden;
}

.sg-feature-item {
  border: none;
  background: transparent;
  text-align: left;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  position: relative;
  transition: background-color 150ms ease;
}

.sg-feature-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: 0;
  top: 16px;
  bottom: 16px;
  width: 1px;
  background: var(--sg-border-subtle);
}

.sg-feature-item:hover {
  background: var(--sg-surface);
}

.sg-feature-icon {
  color: var(--sg-iris);
  flex-shrink: 0;
  display: inline-flex;
}

.sg-feature-title {
  display: block;
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-feature-desc {
  display: block;
  margin: 0;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--sg-muted);
}

/* 4. API Architecture & Integration Overview */
.sg-overview-section {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 18px;
  padding: 28px 30px;
  margin-bottom: 28px;
  box-shadow: 0 6px 24px rgba(23, 20, 42, 0.04);
}

.sg-overview-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-section-eyebrow {
  margin: 0 0 6px;
  font-size: 12.5px;
  font-weight: 700;
  color: #5b7f3a;
}

.sg-overview-heading {
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--sg-ink);
  text-wrap: balance;
}

.sg-overview-copy {
  margin: 0;
  max-width: 650px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--sg-muted);
}

.sg-overview-auth-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  flex-shrink: 0;
}

.sg-env-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--sg-muted);
  white-space: nowrap;
}

.sg-env-line code {
  font-size: 12px;
  color: var(--sg-ink);
  background: var(--sg-surface);
  padding: 2px 6px;
  border-radius: 5px;
}

.sg-auth-outline-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  color: var(--sg-iris);
  border: 1px solid #cbc5ea;
  border-radius: 9999px;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 150ms ease, border-color 150ms ease;
}

.sg-auth-outline-btn:hover {
  background: var(--sg-iris-wash);
  border-color: var(--sg-iris);
}

.sg-overview-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 22px;
}

.sg-overview-step {
  position: relative;
  min-width: 0;
}

.sg-overview-step:not(:last-child) {
  padding-right: 20px;
  border-right: 1px solid var(--sg-border-subtle);
}

.sg-step-index {
  display: inline-block;
  font-family: var(--sg-font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  font-weight: 600;
  color: var(--sg-iris);
  margin-bottom: 6px;
}

.sg-step-title {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-step-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.58;
  color: var(--sg-muted);
}

.sg-step-desc code {
  font-size: 12px;
  color: var(--sg-ink);
  background: var(--sg-surface);
  padding: 1px 5px;
  border-radius: 4px;
}

/* 4A. Step-by-Step Getting Started Section */
.sg-gs-section {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 18px;
  padding: 28px 30px;
  margin-bottom: 30px;
  box-shadow: 0 6px 24px rgba(23, 20, 42, 0.04);
}

.sg-gs-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-gs-heading {
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--sg-ink);
  text-wrap: balance;
}

.sg-gs-subtitle {
  margin: 0;
  max-width: 640px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--sg-muted);
}

.sg-gs-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sg-gs-step {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: start;
  gap: 24px;
  padding: 22px 0;
}

.sg-gs-step:not(:last-child) {
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-gs-step:last-child {
  padding-bottom: 4px;
}

.sg-gs-step-meta {
  min-width: 0;
}

.sg-gs-num {
  display: inline-block;
  font-family: var(--sg-font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  font-weight: 700;
  color: var(--sg-iris);
  margin-bottom: 5px;
}

.sg-gs-step-title {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-gs-step-title code,
.sg-gs-step-desc code,
.sg-gs-link-btn code {
  font-size: 12px;
  color: var(--sg-ink);
  background: var(--sg-surface);
  padding: 1px 5px;
  border-radius: 4px;
}

.sg-gs-step-desc {
  margin: 0 0 12px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--sg-muted);
}

.sg-gs-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.sg-gs-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #ffffff;
  color: var(--sg-iris);
  border: 1px solid var(--sg-iris-border);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease;
}

.sg-gs-link-btn:hover {
  background: var(--sg-iris-wash);
  border-color: var(--sg-iris);
}

.sg-gs-code-wrap {
  background: var(--sg-surface);
  border: 1px solid var(--sg-border);
  border-radius: 12px;
  overflow: hidden;
  min-width: 0;
}

.sg-gs-code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 13px;
  background: #ffffff;
  border-bottom: 1px solid var(--sg-border-subtle);
  font-family: var(--sg-font-mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--sg-muted);
}

.sg-gs-copy-btn {
  background: #ffffff;
  color: var(--sg-ink-soft);
  border: 1px solid var(--sg-border);
  border-radius: 6px;
  padding: 3px 10px;
  font-family: var(--sg-font-sans);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}

.sg-gs-copy-btn:hover {
  background: var(--sg-iris-wash);
  color: var(--sg-iris);
  border-color: var(--sg-iris-border);
}

.sg-gs-copy-btn.is-copied {
  background: #eef4e4;
  color: #1c7c44;
  border-color: #b7cc8e;
}

.sg-gs-pre {
  margin: 0;
  padding: 13px 14px;
  background: #f9f8fd;
  color: var(--sg-ink);
  font-size: 12px;
  line-height: 1.55;
  overflow-x: auto;
}

/* 4B. Geospatial File Validator & Certified Samples (spectagis.com) */
.sg-validator-section {
  margin: 34px 0 30px;
}

.sg-validator-intro {
  max-width: 740px;
  margin: 0 auto 24px;
  text-align: center;
}

.sg-validator-eyebrow {
  margin: 0 0 8px;
  font-family: var(--sg-font-mono);
  font-size: 12px;
  font-weight: 600;
  color: #5b7f3a;
}

.sg-validator-heading {
  margin: 0 0 10px;
  font-size: clamp(24px, 2.7vw, 32px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--sg-ink);
  text-wrap: balance;
}

.sg-validator-subtitle {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--sg-muted);
}

.sg-validator-subtitle code {
  font-size: 13px;
  color: var(--sg-ink);
  background: var(--sg-iris-wash);
  padding: 1px 6px;
  border-radius: 5px;
}

.sg-validator-card {
  background: #ffffff;
  border: 1px solid #e3e6dd;
  border-radius: 20px;
  box-shadow: 0 16px 40px rgba(23, 20, 41, 0.05);
  overflow: hidden;
}

.sg-validator-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 24px;
  border-bottom: 1px solid #eceaf3;
}

.sg-validator-topbar-label {
  font-family: var(--sg-font-mono);
  font-size: 12.5px;
  font-weight: 600;
  color: #5b7f3a;
}

.sg-validator-topbar-meta {
  font-family: var(--sg-font-mono);
  font-size: 11.5px;
  color: #5c4a9e;
}

.sg-validator-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
  gap: 24px;
  padding: 22px 24px;
}

.sg-validator-left {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.sg-val-dropzone {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px 18px;
  border: none;
  border-radius: 14px;
  background: #fbfafe;
  color: #ada6de;
  text-align: left;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}

.sg-val-dropzone:hover,
.sg-val-dropzone.is-dragover {
  background: #f4f2fd;
  color: #5c4a9e;
}

.sg-val-dash-border {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.sg-val-dash-border rect {
  width: calc(100% - 2px);
  height: calc(100% - 2px);
}

.sg-val-upload-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #f0eefc;
  color: #5c4a9e;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sg-val-drop-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.sg-val-drop-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #5c4a9e;
}

.sg-val-drop-desc {
  font-size: 12.5px;
  line-height: 1.45;
  color: #5b6170;
}

.sg-val-support-note {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-family: var(--sg-font-mono);
  font-size: 11px;
  color: #5b6170;
}

.sg-val-canvas-wrap {
  position: relative;
  height: 274px;
  border-radius: 14px;
  background: #f5f8f7;
  border: 1px solid #e3e6dd;
  overflow: hidden;
}

.sg-val-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(215, 222, 218, 0.55) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(215, 222, 218, 0.55) 1px, transparent 1px);
  background-size: 40px 40px;
}

.sg-val-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.sg-val-canvas-badge {
  position: absolute;
  left: 14px;
  bottom: 14px;
  max-width: calc(100% - 28px);
  padding: 6px 11px;
  border-radius: 8px;
  font-family: var(--sg-font-mono);
  font-size: 11.5px;
  line-height: 1.35;
  color: #ffffff;
  background: rgba(63, 95, 39, 0.92);
  font-variant-numeric: tabular-nums;
}

.sg-val-canvas-badge.is-warn {
  background: rgba(122, 78, 14, 0.94);
}

.sg-validator-right {
  min-width: 0;
}

.sg-val-rules-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sg-val-rule-btn {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 15px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: #ffffff;
  text-align: left;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease, opacity 150ms ease;
}

.sg-val-rule-btn:hover {
  background: #faf9fd;
  border-color: #eceaf3;
}

.sg-val-rule-btn.is-pass {
  background: #f4f9ef;
  border-color: #b7cc8e;
}

.sg-val-rule-btn.is-flag {
  background: #fff6e8;
  border-color: #f2d49e;
}

.sg-val-rule-btn.is-pending {
  opacity: 0.65;
}

.sg-val-rule-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

.sg-val-rule-content {
  flex: 1 1 auto;
  min-width: 0;
}

.sg-val-rule-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.sg-val-rule-title-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.sg-val-rule-num {
  font-family: var(--sg-font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12.5px;
  font-weight: 600;
  color: #5b7f3a;
}

.sg-val-rule-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #3f5f27;
}

.sg-val-rule-btn.is-flag .sg-val-rule-title {
  color: #7a4e0e;
}

.sg-val-rule-tag {
  font-family: var(--sg-font-mono);
  font-size: 11px;
  color: #5c4a9e;
}

.sg-val-rule-btn.is-flag .sg-val-rule-tag {
  color: #7a4e0e;
}

.sg-val-rule-body {
  margin: 0;
  font-size: 12.8px;
  line-height: 1.5;
  color: #5b6170;
}

.sg-val-result {
  border-top: 1px solid #eceaf3;
  background: #faf9fd;
  padding: 18px 24px;
}

.sg-val-result-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.sg-val-result-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.sg-val-result-badge {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sg-val-result-badge.is-ok {
  background: #eef4e4;
  border: 1px solid #b7cc8e;
  color: #005825;
}

.sg-val-result-badge.is-err {
  background: #fff6e8;
  border: 1px solid #f2d49e;
  color: #b7791f;
}

.sg-val-result-title {
  margin: 0 0 2px;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-val-result-meta {
  margin: 0;
  font-family: var(--sg-font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--sg-muted);
}

.sg-val-result-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.sg-val-errors-box {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #f2d49e;
  background: #fffaf2;
  font-size: 13px;
  color: #7a4e0e;
}

.sg-val-errors-box ul {
  margin: 6px 0 0;
  padding-left: 18px;
}

.sg-val-fields-strip {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
}

.sg-val-field-item {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}

.sg-val-field-item strong {
  display: block;
  color: var(--sg-ink);
  margin-bottom: 2px;
}

.sg-samples-block {
  margin-top: 22px;
}

.sg-samples-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.sg-samples-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-samples-meta {
  font-size: 12.5px;
  color: var(--sg-muted);
}

.sg-samples-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.sg-sample-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid #e3e6dd;
  background: #ffffff;
  transition: border-color 150ms ease, background-color 150ms ease;
}

.sg-sample-card.is-invalid-sample {
  border-color: #f2d49e;
  background: #fffdf8;
}

.sg-sample-card.is-active {
  border-color: var(--sg-iris);
  background: #f7f6fb;
}

.sg-sample-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-family: var(--sg-font-mono);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}

.sg-sample-status {
  font-weight: 600;
  color: #3f5f27;
}

.sg-sample-card.is-invalid-sample .sg-sample-status {
  color: #9b6412;
}

.sg-sample-acres {
  color: var(--sg-muted);
}

.sg-sample-title {
  margin: 6px 0 4px;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-sample-desc {
  margin: 0 0 8px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--sg-muted);
}

.sg-sample-filename {
  margin: 0;
  font-family: var(--sg-font-mono);
  font-size: 11px;
  color: #5c4a9e;
  background: #f6f5fb;
  padding: 6px 9px;
  border-radius: 7px;
  overflow-wrap: anywhere;
}

.sg-sample-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid #eceaf3;
}

.sg-sample-test-btn {
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--sg-iris);
  color: #ffffff;
  border: none;
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.sg-sample-test-btn:hover {
  background: var(--sg-iris-hover);
}

.sg-sample-dl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: #ffffff;
  color: var(--sg-ink-soft);
  border: 1px solid #e3e6dd;
  border-radius: 9px;
  padding: 8px 11px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.sg-sample-dl-btn:hover {
  background: var(--sg-surface);
  color: var(--sg-ink);
}

/* 5. Endpoint Tag Group Cards (Claims, Second Crop, Webhooks) */
.sg-tag-card {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 16px;
  padding: 18px 22px;
  margin-bottom: 18px;
  box-shadow: 0 4px 18px rgba(23, 20, 42, 0.03);
}

.sg-tag-header {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  background: transparent;
  border: none;
  padding: 2px 0 12px;
  text-align: left;
  cursor: pointer;
}

.sg-tag-card.is-collapsed .sg-tag-header {
  padding-bottom: 2px;
}

.sg-tag-icon-box {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sg-tag-icon-iris {
  background: #5635e6;
  color: #ffffff;
}

.sg-tag-icon-sage {
  background: #1ea653;
  color: #ffffff;
}

.sg-tag-icon-webhook {
  background: #efebfd;
  color: #5635e6;
}

.sg-tag-title-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.sg-tag-title {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--sg-ink);
}

.sg-tag-desc {
  font-size: 13px;
  line-height: 1.4;
  color: var(--sg-muted);
}

.sg-tag-right {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.sg-tag-count-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 9999px;
  white-space: nowrap;
}

.sg-count-iris {
  background: var(--sg-iris-wash);
  color: var(--sg-iris);
}

.sg-count-sage {
  background: #dcf4e4;
  color: #1c7c44;
}

.sg-chevron {
  color: var(--sg-muted);
  transition: transform 160ms ease;
  display: inline-flex;
}

.sg-tag-card.is-collapsed .sg-chevron {
  transform: rotate(180deg);
}

.sg-tag-card.is-collapsed .sg-op-list {
  display: none;
}

/* 6. Endpoint Operation Rows */
.sg-op-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sg-op-item {
  border: 1px solid var(--sg-border-subtle);
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
  transition: border-color 150ms ease;
}

.sg-op-item:hover {
  border-color: #cfc8ee;
}

.sg-op-summary {
  width: 100%;
  background: transparent;
  border: none;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  cursor: pointer;
}

.sg-op-summary:hover {
  background: #faf9fe;
}

.sg-method-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 66px;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  flex-shrink: 0;
}

.sg-method-post {
  background: var(--sg-post-bg);
  color: var(--sg-post-text);
}

.sg-method-get {
  background: var(--sg-get-bg);
  color: var(--sg-get-text);
}

.sg-method-delete {
  background: var(--sg-del-bg);
  color: var(--sg-del-text);
}

.sg-op-path {
  font-family: var(--sg-font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--sg-ink);
  min-width: 245px;
  flex-shrink: 0;
}

.sg-op-summary-text {
  font-size: 13px;
  color: var(--sg-muted);
  flex: 1 1 auto;
}

.sg-op-chevron {
  color: var(--sg-muted);
  flex-shrink: 0;
  transition: transform 160ms ease;
  display: inline-flex;
}

.sg-op-item.is-open .sg-op-chevron {
  transform: rotate(90deg);
}

/* 7. Light-Themed Interactive "Try It Out" Drawer (Zero Black Backgrounds!) */
.sg-op-body {
  display: none;
  background: #faf9fe;
  border-top: 1px solid var(--sg-border-subtle);
  padding: 18px 20px;
}

.sg-op-item.is-open .sg-op-body {
  display: block;
}

.sg-op-purpose {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-left: 3px solid var(--sg-iris);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 14px;
}

.sg-op-purpose-label {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--sg-iris);
}

.sg-op-desc-block {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--sg-ink-soft);
}

.sg-op-params-card {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 14px;
}

.sg-op-params-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  background: var(--sg-surface);
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-op-params-title {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sg-ink);
}

.sg-op-params-counts {
  font-size: 12px;
  font-weight: 500;
  color: var(--sg-muted);
  font-variant-numeric: tabular-nums;
}

.sg-op-params-empty {
  margin: 0;
  padding: 12px 14px;
  font-size: 12.5px;
  color: var(--sg-muted);
}

.sg-op-params-scroll {
  overflow-x: auto;
}

.sg-op-params-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.sg-op-params-table th {
  text-align: left;
  padding: 8px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sg-muted);
  background: #fcfbfe;
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-op-params-table td {
  padding: 9px 14px;
  vertical-align: top;
  border-bottom: 1px solid var(--sg-border-subtle);
  color: var(--sg-ink-soft);
  line-height: 1.45;
}

.sg-op-params-table tr:last-child td {
  border-bottom: none;
}

.sg-param-name {
  font-family: var(--sg-font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--sg-ink);
  word-break: break-word;
}

.sg-param-in {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--sg-surface-2);
  color: var(--sg-muted);
  font-size: 10.5px;
  font-weight: 600;
  text-transform: lowercase;
}

.sg-req-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.sg-req-badge.is-required {
  background: #ede9fe;
  color: var(--sg-iris);
}

.sg-req-badge.is-optional {
  background: #f3f2f8;
  color: var(--sg-muted);
  font-weight: 600;
}

.sg-param-type {
  font-family: var(--sg-font-mono);
  font-size: 11.5px;
  color: var(--sg-muted);
  white-space: nowrap;
}

.sg-try-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.sg-field-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--sg-ink-soft);
  margin-bottom: 5px;
}

.sg-input,
.sg-select,
.sg-code-editor {
  width: 100%;
  background: #ffffff;
  color: var(--sg-ink);
  border: 1px solid #d7d2ea;
  border-radius: 8px;
  padding: 8px 11px;
  font-size: 13px;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.sg-input:focus,
.sg-select:focus,
.sg-code-editor:focus {
  border-color: var(--sg-iris);
  box-shadow: 0 0 0 3px rgba(86, 53, 230, 0.14);
}

.sg-code-editor {
  min-height: 220px;
  resize: vertical;
  line-height: 1.5;
  background: #ffffff;
  color: var(--sg-ink);
}

.sg-enum-assist {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.sg-enum-assist-title {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--sg-iris);
}

.sg-execute-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

.sg-server-pill {
  font-family: var(--sg-font-mono);
  font-size: 12px;
  color: var(--sg-muted);
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 8px;
  padding: 6px 10px;
}

.sg-exec-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #5635e6 0%, #7254ef 100%);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(86, 53, 230, 0.22);
}

.sg-exec-btn:disabled {
  opacity: 0.6;
  cursor: wait;
}

.sg-response-box {
  margin-top: 16px;
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 10px;
  overflow: hidden;
}

.sg-response-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 14px;
  background: var(--sg-surface);
  border-bottom: 1px solid var(--sg-border-subtle);
  font-size: 12px;
  font-weight: 600;
  color: var(--sg-ink);
}

.sg-status-ok {
  color: var(--sg-post-text);
  background: var(--sg-post-bg);
  padding: 2px 8px;
  border-radius: 6px;
}

.sg-status-err {
  color: var(--sg-del-text);
  background: var(--sg-del-bg);
  padding: 2px 8px;
  border-radius: 6px;
}

.sg-response-pre {
  margin: 0;
  padding: 14px;
  background: #ffffff;
  color: var(--sg-ink);
  font-size: 12px;
  line-height: 1.55;
  overflow-x: auto;
  max-height: 360px;
}

/* 8. Schema Rows Matching Mockup */
.sg-schemas-section {
  margin: 22px 0 36px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sg-schema-card {
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(23, 20, 42, 0.02);
}

.sg-schema-row-btn {
  width: 100%;
  background: #ffffff;
  border: none;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  cursor: pointer;
  transition: background-color 150ms ease;
}

.sg-schema-row-btn:hover {
  background: #faf9fe;
}

.sg-schema-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--sg-iris);
  flex-shrink: 0;
}

.sg-schema-icon-leaf {
  color: #1ea653;
}

.sg-schema-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-schema-meta {
  font-size: 13px;
  color: var(--sg-muted);
}

.sg-schema-type {
  font-size: 13px;
  font-weight: 600;
  color: var(--sg-iris);
}

.sg-schema-right {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.sg-expand-pill {
  font-size: 11px;
  font-weight: 600;
  color: var(--sg-ink);
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 7px;
  padding: 4px 10px;
}

.sg-schema-body {
  display: none;
  background: #faf9fe;
  border-top: 1px solid var(--sg-border-subtle);
  padding: 14px 18px;
}

.sg-schema-card.is-open .sg-schema-body {
  display: block;
}

.sg-schema-card.is-open .sg-op-chevron {
  transform: rotate(180deg);
}

.sg-enum-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.sg-enum-val {
  font-family: var(--sg-font-mono);
  font-size: 12px;
  background: #ffffff;
  color: var(--sg-ink);
  border: 1px solid var(--sg-border);
  border-radius: 6px;
  padding: 4px 9px;
}

.sg-prop-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 8px;
  overflow: hidden;
}

.sg-prop-table th,
.sg-prop-table td {
  text-align: left;
  padding: 8px 12px;
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-prop-table th {
  background: var(--sg-surface);
  color: var(--sg-muted);
  font-weight: 600;
}

/* 9. Clean Light Authorize & Environment Modal */
.sg-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(23, 20, 42, 0.35);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.sg-modal-backdrop.is-open {
  display: flex;
}

.sg-modal {
  width: 100%;
  max-width: 500px;
  background: #ffffff;
  border: 1px solid var(--sg-border);
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(23, 20, 42, 0.22);
  overflow: hidden;
}

.sg-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--sg-border-subtle);
}

.sg-modal-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: var(--sg-ink);
}

.sg-modal-close {
  background: transparent;
  border: 1px solid var(--sg-border);
  border-radius: 8px;
  width: 30px;
  height: 30px;
  color: var(--sg-muted);
  cursor: pointer;
  font-size: 16px;
}

.sg-modal-body {
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.sg-modal-foot {
  padding: 14px 22px;
  background: var(--sg-surface);
  border-top: 1px solid var(--sg-border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* 10. Editorial Footer with Subtle Contour Lines */
.sg-footer-wrap {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--sg-border-subtle);
  background: #ffffff;
  margin-top: 36px;
}

.sg-footer-contours {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 380px;
  height: 100%;
  pointer-events: none;
  opacity: 0.45;
}

.sg-footer-inner {
  position: relative;
  z-index: 1;
  max-width: 1140px;
  margin: 0 auto;
  padding: 24px 24px 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.sg-footer-left {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  color: var(--sg-muted);
}

.sg-footer-logo {
  height: 22px;
  width: auto;
  display: block;
}

.sg-footer-sep {
  width: 1px;
  height: 16px;
  background: var(--sg-border);
}

.sg-footer-links {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
}

.sg-footer-links a {
  color: var(--sg-iris);
  text-decoration: none;
  font-weight: 500;
}

.sg-footer-links a:hover {
  text-decoration: underline;
}

@media (max-width: 960px) {
  .sg-hero-grid,
  .sg-overview-steps,
  .sg-gs-step,
  .sg-validator-grid,
  .sg-samples-grid {
    grid-template-columns: 1fr;
  }
  .sg-overview-auth-actions {
    align-items: flex-start;
  }
  .sg-overview-step:not(:last-child) {
    padding-right: 0;
    padding-bottom: 16px;
    border-right: none;
    border-bottom: 1px solid var(--sg-border-subtle);
  }
  .sg-feature-strip {
    grid-template-columns: 1fr;
  }
  .sg-feature-item:not(:last-child)::after {
    display: none;
  }
  .sg-feature-item:not(:last-child) {
    border-bottom: 1px solid var(--sg-border-subtle);
  }
  .sg-nav {
    display: none;
  }
  .sg-op-path {
    min-width: 150px;
  }
}

@media (max-width: 580px) {
  .sg-op-summary {
    flex-wrap: wrap;
  }
}
