/* Shared styles for /developers/* portal pages.
 * Extracted from server.js DEVELOPERS_APPS_STYLE constant.
 * Edit this file directly — hot-reload via express.static, no server restart needed. */

:root {
  --bart-blue: #c8402a;
  --bart-blue-dark: #a63320;
  --ink: #1e293b;
  --ink-soft: #64748b;
  --line: #e2e8f0;
  --bg-soft: #f8fafc;
  --code-bg: #0f172a;
  --code-fg: #e2e8f0;
}

* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  line-height: 1.6;
  background: #fff;
}

.container {
  max-width: 760px;
  margin: 0 auto;
  padding: 1.5rem;
}
.topbar {
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
}
.topbar .container {
  padding-top: 1rem;
  padding-bottom: 1rem;
}
.crumb {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 0;
}
.crumb a {
  color: var(--bart-blue);
  text-decoration: none;
}
.crumb a:hover {
  text-decoration: underline;
}
h1 {
  font-size: 1.65rem;
  margin: 0.25rem 0 0;
}
h2 {
  font-size: 1.15rem;
  margin: 1.5rem 0 0.5rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--line);
}
h3 {
  font-size: 1rem;
  margin: 1.1rem 0 0.4rem;
}
p {
  color: var(--ink-soft);
  margin: 0 0 0.9rem;
}
label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
  margin: 1rem 0 0.25rem;
}
label .req {
  color: #dc2626;
}
label .hint {
  font-weight: 400;
  color: var(--ink-soft);
  font-size: 0.8rem;
  margin-left: 0.35rem;
}

input[type='text'],
input[type='url'],
input[type='number'],
textarea {
  width: 100%;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.95rem;
}
input:focus,
textarea:focus {
  outline: 2px solid var(--bart-blue);
  outline-offset: -1px;
  border-color: var(--bart-blue);
}
textarea {
  font-family: 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.88rem;
  line-height: 1.5;
}

.btn {
  padding: 0.55rem 1rem;
  border-radius: 6px;
  border: 1px solid transparent;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.92rem;
  text-decoration: none;
  display: inline-block;
}
.btn-primary {
  background: var(--bart-blue);
  color: #fff;
}
.btn-primary:hover {
  background: var(--bart-blue-dark);
}
.btn-ghost {
  background: transparent;
  color: var(--bart-blue);
  border-color: var(--line);
}
.btn-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  margin-top: 0.75rem;
}
th,
td {
  text-align: left;
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th {
  font-weight: 600;
  background: var(--bg-soft);
}

code.inline {
  background: var(--bg-soft);
  padding: 0.12rem 0.35rem;
  border-radius: 4px;
  font-family: 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.9em;
  border: 1px solid var(--line);
  overflow-wrap: anywhere;
}
pre {
  background: var(--code-bg);
  color: var(--code-fg);
  padding: 1rem;
  border-radius: 8px;
  overflow-x: auto;
  font-family: 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.85rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.callout {
  background: var(--bg-soft);
  border-left: 3px solid var(--bart-blue);
  padding: 0.8rem 1rem;
  border-radius: 0 6px 6px 0;
  margin: 1rem 0;
}
.callout p {
  margin: 0;
  color: var(--ink);
}
.callout.warn {
  border-left-color: #f59e0b;
  background: #fffbeb;
}
.callout.err {
  border-left-color: #dc2626;
  background: #fef2f2;
  color: #7f1d1d;
}

.checkbox-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem 0.75rem;
  margin-top: 0.25rem;
}
.checkbox-list label {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  margin: 0;
  font-weight: 400;
  font-size: 0.9rem;
  cursor: pointer;
}
.checkbox-list label input {
  margin-top: 0.3rem;
  flex-shrink: 0;
}
.checkbox-list label .scope-id {
  font-family: 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.82rem;
  color: var(--bart-blue);
  display: block;
}

.empty {
  color: var(--ink-soft);
  font-style: italic;
  padding: 0.9rem 0;
}
.csbox {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.csbox input {
  flex: 1;
  font-family: 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.85rem;
}

@media (max-width: 560px) {
  .checkbox-list {
    grid-template-columns: 1fr;
  }
}
