/* AISO Marketing Site — modern, accessible, performance-minded */
:root {
  --bg: #0b0f1a;
  --bg-elevated: #12182a;
  --bg-card: #161d33;
  --border: rgba(255,255,255,0.08);
  --text: #e8ecf7;
  --text-muted: #9aa3bd;
  --brand: #7c3aed;
  --brand-2: #22d3ee;
  --brand-grad: linear-gradient(135deg, #7c3aed 0%, #2563eb 50%, #22d3ee 100%);
  --success: #34d399;
  --warning: #fbbf24;
  --radius: 14px;
  --shadow: 0 20px 50px rgba(0,0,0,0.35);
  --font: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-2); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: min(100% - 2rem, var(--max)); margin-inline: auto; }

/* Skip link */
.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--brand); color: #fff; padding: .5rem 1rem; z-index: 1000;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(14px);
  background: rgba(11,15,26,0.85);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: .9rem 0; gap: 1rem;
}
.logo {
  display: flex; align-items: center; gap: .6rem;
  font-weight: 700; color: var(--text); text-decoration: none; font-size: 1.05rem;
}
.logo-img { width: 34px; height: 34px; border-radius: 10px; display: block; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--brand-grad);
  display: grid; place-items: center; font-size: .85rem; font-weight: 800; color: #fff;
}
.nav-links {
  display: flex; gap: 1.25rem; align-items: center; list-style: none; margin: 0; padding: 0;
}
.nav-links a { color: var(--text-muted); font-weight: 500; text-decoration: none; font-size: .95rem; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-toggle {
  display: none; background: transparent; border: 1px solid var(--border);
  color: var(--text); border-radius: 8px; padding: .4rem .6rem; cursor: pointer;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .7rem 1.15rem; border-radius: 999px; font-weight: 600; font-size: .95rem;
  border: 1px solid transparent; cursor: pointer; text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary {
  background: var(--brand-grad); color: #fff;
  box-shadow: 0 8px 24px rgba(124,58,237,.35);
}
.btn-ghost {
  background: transparent; color: var(--text); border-color: var(--border);
}
.btn-ghost:hover { border-color: rgba(255,255,255,.2); background: rgba(255,255,255,.03); }

/* Hero */
.hero {
  padding: 5rem 0 4rem;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto;
  height: 70%; background: radial-gradient(ellipse at 30% 20%, rgba(124,58,237,.25), transparent 55%),
    radial-gradient(ellipse at 80% 0%, rgba(34,211,238,.12), transparent 45%);
  pointer-events: none;
}
.hero-grid {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.5rem; align-items: center;
  position: relative;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .25rem .7rem; border-radius: 999px; font-size: .8rem; font-weight: 600;
  background: rgba(124,58,237,.15); color: #c4b5fd; border: 1px solid rgba(124,58,237,.3);
  margin-bottom: 1rem;
}
.hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.1rem); line-height: 1.15; margin: 0 0 1rem;
  letter-spacing: -0.02em;
}
.hero h1 span {
  background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-lead { color: var(--text-muted); font-size: 1.1rem; max-width: 36rem; margin: 0 0 1.75rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-bottom: 1.5rem; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 1.25rem; color: var(--text-muted); font-size: .9rem; }
.hero-meta strong { color: var(--text); }

.hero-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: calc(var(--radius) + 4px);
  padding: 1.25rem; box-shadow: var(--shadow);
}
.hero-card pre {
  margin: 0; font-family: var(--mono); font-size: .78rem; color: #a5b4fc;
  white-space: pre-wrap; line-height: 1.5;
}
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-top: 1rem; }
.stat {
  background: rgba(255,255,255,.03); border: 1px solid var(--border); border-radius: 12px;
  padding: .75rem; text-align: center;
}
.stat b { display: block; font-size: 1.2rem; color: var(--brand-2); }
.stat span { font-size: .75rem; color: var(--text-muted); }

/* Sections */
section { padding: 4rem 0; }
.section-title { font-size: clamp(1.5rem, 3vw, 2rem); margin: 0 0 .5rem; letter-spacing: -0.02em; }
.section-sub { color: var(--text-muted); margin: 0 0 2rem; max-width: 40rem; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }

.card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.35rem; transition: border-color .2s, transform .2s;
}
.card:hover { border-color: rgba(124,58,237,.4); transform: translateY(-2px); }
.card-icon {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(124,58,237,.15); color: #c4b5fd; font-size: 1.2rem; margin-bottom: .85rem;
}
.card h3 { margin: 0 0 .4rem; font-size: 1.1rem; }
.card p { margin: 0; color: var(--text-muted); font-size: .95rem; }

.badge-pro {
  display: inline-block; margin-left: .35rem; padding: .1rem .45rem;
  background: var(--brand); color: #fff; border-radius: 4px; font-size: .65rem; font-weight: 700;
  vertical-align: middle; letter-spacing: .04em;
}

/* Pricing */
.price-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: calc(var(--radius) + 2px);
  padding: 1.75rem; position: relative;
}
.price-card.featured {
  border-color: rgba(124,58,237,.55);
  box-shadow: 0 0 0 1px rgba(124,58,237,.25), var(--shadow);
}
.price-card .tag {
  position: absolute; top: 1rem; right: 1rem; font-size: .7rem; font-weight: 700;
  background: var(--brand-grad); color: #fff; padding: .2rem .55rem; border-radius: 999px;
}
.price { font-size: 2.4rem; font-weight: 800; margin: .5rem 0; letter-spacing: -0.03em; }
.price small { font-size: 1rem; font-weight: 500; color: var(--text-muted); }
.price-card ul { list-style: none; padding: 0; margin: 1.25rem 0; }
.price-card li {
  padding: .45rem 0 .45rem 1.5rem; position: relative; color: var(--text-muted); font-size: .95rem;
}
.price-card li::before {
  content: "✓"; position: absolute; left: 0; color: var(--success); font-weight: 700;
}

/* Blog */
.article-list { display: grid; gap: 1.25rem; }
.article-card {
  display: grid; grid-template-columns: 160px 1fr; gap: 1.25rem;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; text-decoration: none; color: inherit;
}
.article-card:hover { border-color: rgba(124,58,237,.4); text-decoration: none; }
.article-thumb {
  background: var(--brand-grad); min-height: 120px;
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: .9rem; padding: 1rem; text-align: center;
}
.article-body { padding: 1.1rem 1.1rem 1.1rem 0; }
.article-body time, .meta { color: var(--text-muted); font-size: .85rem; }
.article-body h2 { margin: .35rem 0 .5rem; font-size: 1.2rem; color: var(--text); }
.article-body p { margin: 0; color: var(--text-muted); font-size: .95rem; }

/* Article page */
.article-header { padding: 3rem 0 1.5rem; border-bottom: 1px solid var(--border); margin-bottom: 2rem; }
.article-header h1 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); margin: .5rem 0 1rem; letter-spacing: -0.02em; }
.prose {
  max-width: 42rem; font-size: 1.05rem; color: #cdd3e6;
}
.prose h2, .prose h3 { color: var(--text); margin-top: 2rem; letter-spacing: -0.01em; }
.prose p, .prose li { color: var(--text-muted); }
.prose a { text-decoration: underline; }
.prose code {
  font-family: var(--mono); font-size: .9em; background: rgba(255,255,255,.06);
  padding: .1rem .35rem; border-radius: 4px;
}
.prose pre {
  background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 10px;
  padding: 1rem; overflow-x: auto; font-family: var(--mono); font-size: .85rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border); padding: 3rem 0 2rem; margin-top: 2rem;
  color: var(--text-muted); font-size: .9rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; margin-bottom: 2rem;
}
.footer-grid h4 { color: var(--text); margin: 0 0 .75rem; font-size: .95rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: .4rem; }
.footer-grid a { color: var(--text-muted); text-decoration: none; }
.footer-grid a:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 1.25rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; }

/* Admin */
.admin-layout { display: grid; grid-template-columns: 220px 1fr; min-height: 100vh; }
.admin-sidebar {
  background: var(--bg-elevated); border-right: 1px solid var(--border); padding: 1.25rem;
}
.admin-sidebar a {
  display: block; padding: .55rem .75rem; border-radius: 8px; color: var(--text-muted);
  text-decoration: none; margin-bottom: .25rem;
}
.admin-sidebar a:hover, .admin-sidebar a.active { background: rgba(124,58,237,.15); color: var(--text); }
.admin-main { padding: 1.5rem; }
.admin-main h1 { margin-top: 0; }
.form-row { margin-bottom: 1rem; }
.form-row label { display: block; font-weight: 600; margin-bottom: .35rem; font-size: .9rem; }
.form-row input, .form-row textarea, .form-row select {
  width: 100%; padding: .65rem .8rem; border-radius: 10px;
  border: 1px solid var(--border); background: var(--bg); color: var(--text); font: inherit;
}
.form-row textarea { min-height: 180px; resize: vertical; font-family: var(--mono); font-size: .9rem; }
table.data { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.data th, table.data td { text-align: left; padding: .65rem; border-bottom: 1px solid var(--border); }
table.data th { color: var(--text-muted); font-weight: 600; }
.toast {
  position: fixed; bottom: 1.25rem; right: 1.25rem; background: var(--bg-card);
  border: 1px solid var(--border); padding: .85rem 1.1rem; border-radius: 12px;
  box-shadow: var(--shadow); display: none; z-index: 200;
}
.toast.show { display: block; animation: fadeIn .25s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Responsive */
@media (max-width: 900px) {
  .hero-grid, .grid-3, .grid-2, .footer-grid, .article-card, .admin-layout {
    grid-template-columns: 1fr;
  }
  .nav-toggle { display: inline-flex; }
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; background: var(--bg-elevated); padding: 1rem;
    border-bottom: 1px solid var(--border);
  }
  .nav-links.open { display: flex; }
  .article-body { padding: 1rem; }
  .article-thumb { min-height: 80px; }
}
