/* HelpDeskCentral Developer Portal — shared styles (light, Comfortaa) */
:root {
  --ink: #17191c;
  --ink-soft: #62676d;
  --ink-faint: #9aa1a7;
  --line: #e6e8ec;
  --line-soft: #f0f2f4;
  --bg: #ffffff;
  --bg-soft: #f6f7f9;
  --brand: #3081d0;
  --brand-dark: #2568ae;
  --accent: #ffc409;
  --accent-dark: #e0ac08;
  --accent-ink: #201900;
  --ok: #15803d;
  --ok-bg: #dcfce7;
  --bad: #e5484d;
  --bad-bg: #fdecec;
  --code-bg: #101418;
  --radius: 14px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Comfortaa', -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line-soft); }
.nav-row { display: flex; align-items: center; gap: 22px; height: 64px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 17px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--ink); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 15px; }
.desktop-nav { display: flex; gap: 18px; margin-left: 8px; }
.desktop-nav a { color: var(--ink-soft); text-decoration: none; font-size: 14px; font-weight: 700; }
.desktop-nav a:hover, .desktop-nav a.active { color: var(--ink); }
.nav-cta { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.nav-user { font-size: 13px; color: var(--ink-soft); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-family: inherit; font-weight: 800; font-size: 14px; border-radius: 12px; padding: 11px 20px; cursor: pointer; border: 1.5px solid transparent; text-decoration: none; transition: filter .15s, transform .1s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 4px 0 var(--accent-dark); }
.btn-primary:hover { filter: brightness(.97); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { filter: brightness(1.15); }
.btn-outline { background: #fff; border-color: var(--line); color: var(--ink); }
.btn-outline:hover { background: var(--bg-soft); }
.btn-sm { padding: 8px 14px; font-size: 13px; border-radius: 10px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; box-shadow: none; }

/* Hero */
.hero { padding: 72px 0 48px; text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); background: var(--bg-soft); border: 1px solid var(--line-soft); padding: 7px 14px; border-radius: 999px; }
.hero h1 { font-size: clamp(30px, 5vw, 50px); line-height: 1.12; margin: 20px 0 14px; letter-spacing: -.01em; }
.hero h1 .hl { color: var(--brand); }
.hero p.sub { color: var(--ink-soft); font-size: 16px; max-width: 620px; margin: 0 auto 26px; line-height: 1.6; }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-meta { margin-top: 16px; font-size: 13px; color: var(--ink-faint); }

/* Code window */
.code-window { margin: 34px auto 0; max-width: 640px; background: var(--code-bg); border-radius: 16px; overflow: hidden; text-align: left; box-shadow: 0 24px 60px rgba(9,30,66,.25); }
.code-bar { display: flex; gap: 7px; padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.08); }
.code-bar i { width: 11px; height: 11px; border-radius: 50%; background: #3a4350; display: block; }
.code-window pre { margin: 0; padding: 18px; overflow-x: auto; color: #d7dee8; font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; font-size: 13px; line-height: 1.65; }
.tok-k { color: #7cc4ff; } .tok-s { color: #ffd479; } .tok-c { color: #6b7684; } .tok-n { color: #f093fb; }

/* Sections */
section.block { padding: 52px 0; }
.sec-head { text-align: center; margin-bottom: 30px; }
.sec-head h2 { font-size: clamp(22px, 3.4vw, 32px); margin: 0 0 10px; }
.sec-head p { color: var(--ink-soft); margin: 0; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; background: #fff; }
.card h3 { margin: 0 0 8px; font-size: 16px; }
.card p { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.6; }
.card .ico { width: 40px; height: 40px; border-radius: 12px; background: var(--bg-soft); display: flex; align-items: center; justify-content: center; font-size: 19px; margin-bottom: 12px; }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; text-align: center; }
.stat b { font-size: 30px; display: block; }
.stat span { color: var(--ink-soft); font-size: 13px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: step; }
.step { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.step b.num { display: inline-flex; width: 30px; height: 30px; border-radius: 50%; background: var(--ink); color: #fff; align-items: center; justify-content: center; font-size: 14px; margin-bottom: 10px; }

/* Docs */
.doc-layout { display: grid; grid-template-columns: 230px 1fr; gap: 28px; padding: 30px 0 60px; }
.doc-nav { position: sticky; top: 84px; align-self: start; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; font-size: 13.5px; }
.doc-nav a { display: block; color: var(--ink-soft); text-decoration: none; padding: 7px 10px; border-radius: 8px; font-weight: 700; }
.doc-nav a:hover { background: var(--bg-soft); color: var(--ink); }
.doc-body h2 { margin-top: 34px; padding-top: 10px; border-top: 1px solid var(--line-soft); }
.doc-body h2:first-child { margin-top: 0; border-top: 0; padding-top: 0; }
.endpoint { border: 1px solid var(--line); border-radius: var(--radius); margin: 14px 0; overflow: hidden; }
.endpoint-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px; background: var(--bg-soft); font-family: ui-monospace, Consolas, monospace; font-size: 13.5px; }
.method { font-weight: 800; font-size: 12px; padding: 4px 10px; border-radius: 7px; background: #067647; color: #fff; }
.endpoint-body { padding: 14px 16px; font-size: 14px; }
.endpoint-body table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.endpoint-body th, .endpoint-body td { text-align: left; padding: 7px 8px; border-bottom: 1px solid var(--line-soft); }
.endpoint-body th { color: var(--ink-faint); font-weight: 700; }
.param-req { color: var(--bad); font-weight: 800; }

/* Playground */
.playground { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: #fff; }
.playground .row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.playground select, .playground input[type=text] { font-family: inherit; }
#pg-out { background: var(--code-bg); color: #d7dee8; border-radius: 12px; padding: 16px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; max-height: 340px; overflow: auto; white-space: pre-wrap; }

/* Forms */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 800; margin-bottom: 6px; }
.input, select.input, textarea.input { width: 100%; font-family: inherit; font-size: 14px; background: #f4f5f7; border: 2px solid transparent; border-radius: 12px; padding: 12px 14px; outline: none; color: var(--ink); }
.input:focus { background: #fff; border-color: var(--brand); }
.auth-wrap { max-width: 420px; margin: 48px auto 70px; }
.auth-card { border: 1px solid var(--line); border-radius: 18px; padding: 30px 26px; }
.auth-card h1 { margin: 0 0 6px; font-size: 24px; }
.auth-card p.sub { color: var(--ink-soft); font-size: 14px; margin: 0 0 20px; }
.form-err { display: none; background: var(--bad-bg); color: var(--bad); font-size: 13px; padding: 10px 14px; border-radius: 10px; margin-bottom: 14px; }
.form-ok { display: none; background: var(--ok-bg); color: var(--ok); font-size: 13px; padding: 10px 14px; border-radius: 10px; margin-bottom: 14px; }

/* Dashboard */
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 24px 0; }
.kv { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--line-soft); font-size: 14px; }
.kv:last-child { border-bottom: 0; }
.kv b { font-weight: 800; }
table.tokens { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.tokens th, table.tokens td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line-soft); }
table.tokens th { color: var(--ink-faint); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
.pill { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 3px 10px; border-radius: 999px; }
.pill-on { background: var(--ok-bg); color: var(--ok); }
.pill-off { background: #f0f2f4; color: var(--ink-faint); }
.pill-paid { background: #fff4d6; color: #8a6d00; }
.quota-bar { height: 10px; border-radius: 999px; background: var(--line-soft); overflow: hidden; margin-top: 8px; }
.quota-bar i { display: block; height: 100%; background: var(--brand); border-radius: 999px; }
.key-once { background: var(--code-bg); color: #ffd479; border-radius: 10px; padding: 12px 14px; font-family: ui-monospace, Consolas, monospace; font-size: 13px; word-break: break-all; margin: 12px 0; }
.link-btn { background: none; border: 0; color: var(--bad); font-weight: 800; font-size: 13px; cursor: pointer; font-family: inherit; padding: 0; }
.link-btn:hover { text-decoration: underline; }

/* Status */
.status-row { display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 12px; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: #c6ccd2; flex: none; }
.dot.ok { background: #16a34a; box-shadow: 0 0 0 4px #dcfce7; }
.dot.bad { background: var(--bad); box-shadow: 0 0 0 4px var(--bad-bg); }
.dot.warn { background: #f59e0b; box-shadow: 0 0 0 4px #fef3c7; }
.status-row b { font-size: 15px; }
.status-row small { display: block; color: var(--ink-soft); font-size: 12.5px; }
.status-row .ms { margin-left: auto; font-size: 12.5px; color: var(--ink-faint); font-family: ui-monospace, Consolas, monospace; }

/* Pricing */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.price-card { border: 1.5px solid var(--line); border-radius: 18px; padding: 26px 22px; position: relative; }
.price-card.hot { border-color: var(--ink); box-shadow: 0 18px 44px rgba(9,30,66,.12); }
.price-tag { position: absolute; top: -13px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; font-size: 11.5px; font-weight: 800; padding: 4px 14px; border-radius: 999px; }
.price-card h3 { margin: 0; font-size: 17px; }
.price { font-size: 34px; font-weight: 800; margin: 12px 0 2px; }
.price small { font-size: 13px; color: var(--ink-soft); font-weight: 700; }
.price-card ul { list-style: none; padding: 0; margin: 16px 0 22px; font-size: 14px; color: var(--ink-soft); }
.price-card ul li { padding: 6px 0 6px 26px; position: relative; }
.price-card ul li::before { content: '✓'; position: absolute; left: 4px; color: var(--ok); font-weight: 800; }

/* Footer */
footer.site-footer { border-top: 1px solid var(--line-soft); margin-top: 40px; padding: 34px 0; color: var(--ink-soft); font-size: 13.5px; }
.foot-grid { display: flex; gap: 26px; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; }
.foot-grid nav { display: flex; gap: 16px; flex-wrap: wrap; }
.foot-grid nav a { color: var(--ink-soft); text-decoration: none; font-weight: 700; }
.foot-grid nav a:hover { color: var(--ink); }

@media (max-width: 860px) {
  .grid-3, .grid-2, .steps, .price-grid, .dash-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .doc-layout { grid-template-columns: 1fr; }
  .doc-nav { position: static; }
  .desktop-nav { display: none; }
}
