/* agenticai.mn — MCST Data & AI team portal
   One stylesheet for every page. Light and dark are both first-class. */

:root {
  color-scheme: light dark;

  --bg:        #f7f7f5;
  --surface:   #ffffff;
  --border:    #e2e2dd;
  --border-strong: #cfcfc7;
  --text:      #1a1a18;
  --muted:     #6b6b63;
  --accent:    #1f6f5c;
  --accent-soft: #e8f2ef;
  --warn:      #8a5a00;
  --warn-soft: #fdf3e0;
  --warn-border: #e8d3a8;

  --radius: 10px;
  --maxw: 940px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:        #16161a;
    --surface:   #1e1e23;
    --border:    #2e2e35;
    --border-strong: #40404a;
    --text:      #ececea;
    --muted:     #9a9aa0;
    --accent:    #6ec8ac;
    --accent-soft: #1b2f2a;
    --warn:      #e0b56a;
    --warn-soft: #2a2216;
    --warn-border: #4a3c22;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.6 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---- header ------------------------------------------------------------- */

header.site {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

header.site .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 18px;
  padding-bottom: 18px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}

.brand b {
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.brand span {
  font-size: 13px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
}

/* ---- hero --------------------------------------------------------------- */

.hero {
  padding: 44px 0 8px;
}

.hero h1 {
  margin: 0 0 10px;
  font-size: 26px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 650;
}

.hero p {
  margin: 0;
  max-width: 62ch;
  color: var(--muted);
}

/* ---- sections ----------------------------------------------------------- */

section { padding: 34px 0 6px; }

.section-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.section-head h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.section-head .note {
  font-size: 13px;
  color: var(--muted);
}

/* ---- cards -------------------------------------------------------------- */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 12px;
}

.card {
  display: block;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  transition: border-color .12s ease, transform .12s ease;
}

.card:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.card h3 {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
}

.card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
}

.card .host {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  color: var(--accent);
  word-break: break-all;
}

/* compact list style for the long docs list */

.links {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2px 24px;
}

.links a {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  font-size: 14px;
}

.links a:hover { color: var(--accent); }

.links a em {
  font-style: normal;
  font-size: 12.5px;
  color: var(--muted);
  margin-left: auto;
  text-align: right;
  white-space: nowrap;
}

/* ---- badges ------------------------------------------------------------- */

.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
  vertical-align: middle;
}

.badge.lock {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--accent);
}

.badge.open {
  background: transparent;
  color: var(--muted);
  border-color: var(--border-strong);
}

/* ---- callout ------------------------------------------------------------ */

.callout {
  margin: 18px 0 0;
  padding: 14px 16px;
  background: var(--warn-soft);
  border: 1px solid var(--warn-border);
  border-left: 3px solid var(--warn);
  border-radius: var(--radius);
  font-size: 13.5px;
}

.callout b { color: var(--warn); }

.callout p { margin: 0 0 8px; }
.callout p:last-child { margin-bottom: 0; }

/* ---- gate panel (the /internal entry on the public page) ---------------- */

.gate {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.gate div { max-width: 60ch; }
.gate h3 { margin: 0 0 4px; font-size: 15px; font-weight: 600; }
.gate p  { margin: 0; font-size: 13.5px; color: var(--muted); }

.btn {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--bg);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid var(--accent);
}

.btn:hover { filter: brightness(1.08); }

.btn.ghost {
  background: transparent;
  color: var(--muted);
  border-color: var(--border-strong);
  font-weight: 500;
}

.btn.ghost:hover { color: var(--text); border-color: var(--text); }

/* ---- footer ------------------------------------------------------------- */

footer.site {
  margin-top: 52px;
  padding: 22px 0 40px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
}

footer.site .wrap {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

footer.site a { color: var(--muted); }

/* ---- centered message pages (404 / no-access) -------------------------- */

.center {
  max-width: 52ch;
  margin: 0 auto;
  padding: 90px 20px;
  text-align: center;
}

.center h1 { font-size: 22px; margin: 0 0 10px; letter-spacing: -0.01em; }
.center p  { color: var(--muted); margin: 0 0 22px; }

a { color: var(--accent); }

/* owner line on a product card — who to ask when it breaks */

.card .owner {
  display: block;
  margin-top: 6px;
  font-size: 11.5px;
  color: var(--muted);
}
