/* ==========================================================================
   OpenRP Framework website
   Plain CSS, no build step. Colours come from the logo gradient.
   ========================================================================== */

:root {
  --bg: #0b0d1a;
  --bg-alt: #0f1224;
  --panel: #141830;
  --border: #232848;
  --text: #e8eaf6;
  --muted: #9aa0c0;
  --blue: #1e90ff;
  --purple: #7b3ff2;
  --grad: linear-gradient(135deg, var(--blue), var(--purple));
  --ok: #3ddc97;
  --no: #ff6b81;
  --radius: 14px;
  --max: 1100px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: #1a1f3d;
  border: 1px solid var(--border);
  padding: 0.1em 0.4em;
  border-radius: 6px;
  color: #cfd4ff;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 780px; }

/* ----- Nav ----- */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: rgba(11, 13, 26, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; }
.brand:hover { text-decoration: none; }
.brand b { font-weight: 600; color: var(--muted); }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--muted); font-size: 0.95rem; }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-group { position: relative; }
.nav-group summary { list-style: none; color: var(--muted); cursor: pointer; padding: 10px 0; font-size: .95rem; display: flex; align-items: center; gap: 8px; }
.nav-group summary::-webkit-details-marker { display: none; }
.nav-group summary::after { content: ''; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(45deg); }
.nav-group[open] summary { color: var(--text); }
.nav-group[open] summary::after { transform: translateY(2px) rotate(225deg); }
.nav-dropdown { position: absolute; right: -18px; top: calc(100% + 10px); width: 260px; padding: 7px; border: 1px solid #303655; border-radius: 14px; background: #111528; box-shadow: 0 18px 45px #0005; }
.nav-dropdown a { display: block; padding: 12px 13px; color: var(--text); border-radius: 8px; }
.nav-dropdown a:hover { background: #1d2440; }
.nav-dropdown small { display: block; font-size: .75rem; color: var(--muted); margin-top: 2px; }
.nav-docs span { font-size: .8rem; opacity: .7; }
.nav-links summary:focus-visible, .nav-links a:focus-visible, .nav-toggle:focus-visible { outline: 2px solid #acb6ff; outline-offset: 5px; border-radius: 5px; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text); margin: 5px 0; }

/* ----- Buttons ----- */
.btn {
  display: inline-block; padding: 12px 22px; border-radius: 10px;
  font-weight: 600; border: 1px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--grad); color: #fff !important; }
.btn-primary:hover { filter: brightness(1.1); }
.btn-ghost { border-color: var(--border); color: var(--text); background: var(--panel); }
.btn-ghost:hover { border-color: var(--blue); }
.btn-small { padding: 8px 16px; background: var(--grad); color: #fff !important; font-size: 0.9rem; }

/* ----- Hero ----- */
.hero {
  padding: 80px 0 72px; text-align: center;
  background:
    radial-gradient(60% 50% at 50% 0%, rgba(123, 63, 242, 0.25), transparent 70%),
    radial-gradient(40% 40% at 20% 20%, rgba(30, 144, 255, 0.18), transparent 70%);
}
.hero-logo { width: min(560px, 90%); margin-bottom: 28px; }
h1 { font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.15; margin: 0 0 18px; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { max-width: 640px; margin: 0 auto 28px; color: var(--muted); font-size: 1.1rem; }
.lead strong { color: var(--text); }
.cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.cta.left { justify-content: flex-start; margin-top: 20px; }
.badges { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; padding: 0; margin: 34px 0 0; }
.badges li {
  font-size: 0.8rem; color: var(--muted); border: 1px solid var(--border);
  padding: 4px 12px; border-radius: 999px; background: var(--panel);
}

/* ----- Sections ----- */
.section { padding: 80px 0; }
.section.alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin: 0 0 10px; line-height: 1.2; }
.sub { color: var(--muted); max-width: 720px; margin: 0 0 36px; }
h3 { margin: 0 0 6px; font-size: 1.05rem; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px;
  transition: border-color 0.2s, transform 0.2s;
}
.card:hover { border-color: var(--purple); transform: translateY(-2px); }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.panel { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; }
.panel ul { list-style: none; margin: 14px 0 0; padding: 0; }
.panel li { position: relative; padding: 6px 0 6px 28px; color: var(--muted); }
.panel li b { color: var(--text); }
.ticks li::before, .crosses li::before { position: absolute; left: 0; top: 6px; font-weight: 700; }
.ticks li::before { content: "\2713"; color: var(--ok); }
.crosses li::before { content: "\2715"; color: var(--no); }
h3.ok { color: var(--ok); }
h3.no { color: var(--no); }

/* ----- Steps ----- */
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li { position: relative; padding: 0 0 28px 56px; }
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%;
  background: var(--grad); color: #fff; font-weight: 700;
  display: grid; place-items: center;
}
.steps li::after {
  content: ""; position: absolute; left: 17px; top: 42px; bottom: 6px; width: 2px; background: var(--border);
}
.steps li:last-child::after { display: none; }
.steps p { margin: 4px 0 0; color: var(--muted); }

.code { position: relative; margin-top: 8px; }
.code pre {
  margin: 0; padding: 16px 78px 16px 18px; overflow-x: auto;
  background: #0a0c18; border: 1px solid var(--border); border-radius: 10px;
}
.code code { background: none; border: 0; padding: 0; color: #cfd4ff; }
.copy {
  position: absolute; top: 8px; right: 8px;
  background: var(--panel); color: var(--muted); border: 1px solid var(--border);
  border-radius: 8px; padding: 4px 10px; font-size: 0.8rem; cursor: pointer;
}
.copy:hover { color: var(--text); border-color: var(--blue); }

/* ----- Table ----- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel); }
table { width: 100%; border-collapse: collapse; min-width: 520px; }
th, td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; }
tr:last-child td { border-bottom: 0; }

/* ----- Status ----- */
.gaps { padding-left: 20px; color: var(--muted); }
.gaps li { margin-bottom: 8px; }
.gaps b { color: var(--text); }

/* ----- Footer ----- */
.footer { border-top: 1px solid var(--border); padding: 36px 0; }
.footer-inner { display: flex; flex-direction: column; gap: 12px; }
.footer p { margin: 0; color: var(--muted); font-size: 0.85rem; max-width: 640px; }

/* ----- Mobile ----- */
@media (max-width: 860px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .two { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .grid { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
  .hero { padding: 48px 0; }
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: 8px 16px 16px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 10px 0; width: 100%; }
  .nav-group { width: 100%; }
  .nav-group summary { padding: 12px 0; justify-content: space-between; }
  .nav-dropdown { position: static; width: 100%; margin-bottom: 12px; box-shadow: none; }
  .nav-dropdown a { padding: 10px 12px; }
  .nav-links .btn-small { width: auto; margin-top: 8px; }
}
