/* ============================================================
   Shotbot – stylesheet
   Design: dark / technical / electric lime
   2026 rewrite
   ============================================================ */

/* ─── Custom Properties ───────────────────────────────────── */
:root {
  --bg:          #0a0c10;
  --bg-surface:  #12151d;
  --bg-raised:   #1a1e2a;
  --border:      #252a38;
  --border-lite: #1e2232;

  --text:        #e2e6f0;
  --text-muted:  #8892a4;
  --text-dim:    #5a6370;

  --accent:      #9fef00;
  --accent-dark: #7bc800;
  --accent-glow: rgba(159,239,0,.15);
  --accent-dim:  rgba(159,239,0,.08);

  --red:         #ff4d4d;
  --amber:       #f59e0b;
  --green-soft:  #22c55e;

  --radius:      6px;
  --radius-lg:   12px;

  --font-head:   'Syne', 'Segoe UI', system-ui, sans-serif;
  --font-body:   'IBM Plex Sans', 'Segoe UI', system-ui, sans-serif;
  --font-mono:   'IBM Plex Mono', 'Fira Code', monospace;

  --max-w:       1100px;
  --col-aside:   280px;
  --header-h:    64px;

  --transition:  0.18s ease;
}

/* ─── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: #fff; }

p   { margin-bottom: 1em; }
ul, ol { padding-left: 1.4em; margin-bottom: 1em; }
li  { margin-bottom: .35em; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
  margin-bottom: .75em;
}
h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 800; }
h2 { font-size: clamp(1.15rem, 2.5vw, 1.5rem); color: var(--text-muted); font-weight: 600; margin-top: 2rem; }
h3 { font-size: 1.05rem; color: var(--accent); font-weight: 600; margin-top: 1.5rem; }
h4 { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); font-weight: 600; }

code, pre {
  font-family: var(--font-mono);
  font-size: .88em;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
code { padding: .15em .4em; }
pre  { padding: 1rem 1.25rem; overflow-x: auto; line-height: 1.55; }
pre code { background: none; border: none; padding: 0; font-size: 1em; }

blockquote {
  border-left: 3px solid var(--accent);
  padding: .75rem 1rem;
  background: var(--accent-dim);
  color: var(--text-muted);
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 1em;
}

hr { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

table { width: 100%; border-collapse: collapse; margin-bottom: 1em; }
th, td { text-align: left; padding: .6rem .75rem; border-bottom: 1px solid var(--border); font-size: .9rem; }
th { color: var(--text-muted); font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--bg-raised); }

/* ─── Layout / Container ──────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.layout-two-col {
  display: grid;
  grid-template-columns: 1fr var(--col-aside);
  gap: 3rem;
  align-items: start;
  padding-top: 2.5rem;
  padding-bottom: 4rem;
}

.col-main { min-width: 0; }
.col-aside { position: sticky; top: calc(var(--header-h) + 1.5rem); }

/* ─── Header ──────────────────────────────────────────────── */
.site-header {
  height: var(--header-h);
  background: rgba(10,12,16,.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.logo { flex-shrink: 0; display: flex; align-items: center; }
.logo img { transition: opacity var(--transition); }
.logo:hover img { opacity: .85; }

/* ─── Nav ─────────────────────────────────────────────────── */
.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; padding: 0; margin: 0; display: flex; gap: .25rem; }

.main-nav a {
  display: block;
  padding: .45rem .85rem;
  font-size: .88rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
}
.main-nav a:hover,
.main-nav a.current { color: var(--text); background: var(--bg-raised); }
.main-nav a.current { color: var(--accent); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  padding: .4rem;
  border-radius: var(--radius);
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-muted);
  border-radius: 2px;
  transition: all var(--transition);
}

/* ─── Aside widgets ───────────────────────────────────────── */
.widget {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}
.widget h4 { margin-bottom: 1rem; }

.widget-auth form { display: flex; flex-direction: column; gap: .6rem; }

.aside-links { list-style: none; padding: 0; }
.aside-links li { border-bottom: 1px solid var(--border-lite); }
.aside-links li:last-child { border-bottom: none; }
.aside-links a {
  display: block;
  padding: .55rem .25rem;
  font-size: .88rem;
  color: var(--text-muted);
}
.aside-links a:hover { color: var(--accent); padding-left: .5rem; }

/* ─── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .6rem 1.25rem;
  font-family: var(--font-head);
  font-size: .9rem;
  font-weight: 700;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #0a0c10;
}
.btn-primary:hover {
  background: #b8ff0d;
  color: #0a0c10;
  box-shadow: 0 0 20px var(--accent-glow);
}
.btn-secondary {
  background: var(--bg-raised);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
.btn-ghost { background: none; color: var(--accent); border: 1px solid var(--accent); }
.btn-ghost:hover { background: var(--accent-dim); }
.btn-sm { padding: .4rem .85rem; font-size: .8rem; }
.btn-lg { padding: .8rem 1.75rem; font-size: 1rem; }

/* ─── Forms ───────────────────────────────────────────────── */
.form-group {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  margin-bottom: 1rem;
}
.form-label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.form-input, .form-textarea, .form-select {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-body);
  font-size: .95rem;
  padding: .6rem .85rem;
  border-radius: var(--radius);
  width: 100%;
  transition: border-color var(--transition), box-shadow var(--transition);
  -webkit-appearance: none;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.form-textarea { min-height: 100px; resize: vertical; }
.form-hint { font-size: .8rem; color: var(--text-dim); }
.form-checkbox { display: flex; align-items: center; gap: .5rem; cursor: pointer; }
.form-checkbox input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }

/* ─── Alerts / Notices ────────────────────────────────────── */
.alert {
  padding: .9rem 1rem;
  border-radius: var(--radius);
  border-left: 3px solid;
  margin-bottom: 1.25rem;
  font-size: .92rem;
}
.alert-warning { background: rgba(245,158,11,.08); border-color: var(--amber); color: var(--text); }
.alert-info    { background: rgba(159,239,0,.06);  border-color: var(--accent); color: var(--text); }
.alert-success { background: rgba(34,197,94,.08);  border-color: var(--green-soft); color: var(--text); }
.alert-error   { background: rgba(255,77,77,.08);  border-color: var(--red); color: var(--text); }

/* ─── Cards ───────────────────────────────────────────────── */
.card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.card-accent { border-left: 3px solid var(--accent); border-radius: 0 var(--radius-lg) var(--radius-lg) 0; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
}
.stat-card .stat-value {
  font-family: var(--font-head);
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  margin-bottom: .25rem;
}
.stat-card .stat-label {
  font-size: .8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ─── Homepage hero ───────────────────────────────────────── */
.hero {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1rem;
}
.hero-title .accent { color: var(--accent); }
.hero-subtitle { font-size: 1.1rem; color: var(--text-muted); max-width: 540px; margin-bottom: 1.75rem; }

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-shots {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}
.hero-shots img {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  transition: transform var(--transition), border-color var(--transition);
}
.hero-shots img:hover { transform: scale(1.04); border-color: var(--accent); }

/* ─── Capture form ────────────────────────────────────────── */
.capture-form {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-top: 1.5rem;
}
.capture-form-row {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
}
.capture-form-row .form-input { flex: 1; }

/* ─── Quota bar ───────────────────────────────────────────── */
.quota-bar-wrap { margin: .75rem 0; }
.quota-bar {
  height: 6px;
  background: var(--bg-raised);
  border-radius: 3px;
  overflow: hidden;
}
.quota-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 3px;
  transition: width .4s ease;
}
.quota-bar-fill.warn { background: var(--amber); }
.quota-bar-fill.full { background: var(--red); }
.quota-label { font-size: .8rem; color: var(--text-muted); margin-top: .3rem; }

/* ─── Pricing / Packs ─────────────────────────────────────── */
.pack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}
.pack-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: .75rem;
  transition: border-color var(--transition), transform var(--transition);
  cursor: pointer;
}
.pack-card:hover, .pack-card.selected {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,.4);
}
.pack-card.selected { background: var(--accent-dim); }
.pack-name { font-family: var(--font-head); font-weight: 700; font-size: 1rem; }
.pack-credits { font-size: 1.5rem; font-weight: 800; font-family: var(--font-head); color: var(--accent); }
.pack-unit { font-size: .75rem; color: var(--text-muted); margin-top: -.5rem; }
.pack-price { font-size: 1.8rem; font-weight: 800; font-family: var(--font-head); }
.pack-per { font-size: .75rem; color: var(--text-dim); }

/* ─── Screenshots gallery ─────────────────────────────────── */
.shot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: .75rem;
}
.shot-thumb {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: border-color var(--transition);
}
.shot-thumb:hover { border-color: var(--accent); }
.shot-thumb img { width: 100%; height: auto; display: block; }

/* ─── Code blocks (API docs) ──────────────────────────────── */
.code-example { position: relative; margin: 1rem 0; }
.code-example pre { margin: 0; font-size: .83rem; }
.code-lang {
  position: absolute;
  top: .6rem; right: .75rem;
  font-size: .7rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
}

/* ─── Admin ───────────────────────────────────────────────── */
.admin-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: 100vh;
  gap: 0;
}
.admin-sidebar {
  background: var(--bg-surface);
  border-right: 1px solid var(--border);
  padding: 1.5rem 1rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.admin-sidebar .logo { margin-bottom: 2rem; }
.admin-nav { list-style: none; padding: 0; }
.admin-nav li { margin-bottom: .25rem; }
.admin-nav a {
  display: flex; align-items: center; gap: .6rem;
  padding: .55rem .75rem;
  border-radius: var(--radius);
  font-size: .9rem;
  color: var(--text-muted);
  font-weight: 500;
  transition: all var(--transition);
}
.admin-nav a:hover, .admin-nav a.current {
  background: var(--bg-raised);
  color: var(--text);
}
.admin-nav a.current { color: var(--accent); }
.admin-content { padding: 2rem; }
.admin-section-title { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--text-dim); margin: 1.25rem 0 .5rem .75rem; }

/* ─── Badges ──────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: .2em .55em;
  font-size: .72rem;
  font-weight: 600;
  border-radius: 99px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.badge-green  { background: rgba(34,197,94,.15); color: #4ade80; }
.badge-amber  { background: rgba(245,158,11,.15); color: #fbbf24; }
.badge-red    { background: rgba(255,77,77,.15); color: #f87171; }
.badge-blue   { background: rgba(99,179,237,.15); color: #93c5fd; }
.badge-lime   { background: var(--accent-dim); color: var(--accent); }

/* ─── Progress / Password strength ───────────────────────── */
.pwd-strength { margin-top: .35rem; }
.pwd-bar {
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: .3rem;
}
.pwd-bar-fill {
  height: 100%;
  border-radius: 2px;
  transition: width .3s ease, background .3s;
}
.pwd-label { font-size: .78rem; color: var(--text-dim); }

/* ─── Footer ──────────────────────────────────────────────── */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  padding: 3rem 0 2rem;
  background: var(--bg-surface);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.footer-brand p { font-size: .88rem; color: var(--text-muted); margin-top: 1rem; line-height: 1.55; }
.footer-links h4 { margin-bottom: .75rem; }
.footer-links ul { list-style: none; padding: 0; }
.footer-links li { margin-bottom: .4rem; }
.footer-links a { font-size: .88rem; color: var(--text-muted); }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 1.5rem; display: flex; flex-direction: column; gap: .35rem; }
.footer-bottom p { font-size: .8rem; color: var(--text-dim); }
.footer-legal a { color: var(--text-dim); }
.footer-legal a:hover { color: var(--accent); }

/* ─── Utilities ───────────────────────────────────────────── */
.text-accent  { color: var(--accent); }
.text-muted   { color: var(--text-muted); }
.text-dim     { color: var(--text-dim); }
.text-center  { text-align: center; }
.text-mono    { font-family: var(--font-mono); }
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 1rem; }
.gap-1 { gap: .5rem; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.w-full { width: 100%; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ─── Animation ───────────────────────────────────────────── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeIn .35s ease forwards; }

/* ─── Responsive ──────────────────────────────────────────── */
@media (max-width: 900px) {
  .layout-two-col {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .col-aside {
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .main-nav { display: none; }
  .main-nav.open {
    display: flex;
    position: fixed;
    inset: var(--header-h) 0 0;
    background: var(--bg);
    flex-direction: column;
    padding: 1.5rem;
    z-index: 99;
    overflow-y: auto;
  }
  .main-nav.open ul {
    flex-direction: column;
    gap: .5rem;
  }
  .main-nav.open a { font-size: 1.1rem; padding: .75rem 1rem; }
  .nav-toggle { display: flex; }

  .hero-title { font-size: clamp(1.7rem, 7vw, 2.4rem); }
  .capture-form-row { flex-direction: column; }
  .pack-grid { grid-template-columns: 1fr 1fr; }
  .card-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .col-aside { grid-template-columns: 1fr; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { height: auto; position: static; }
}

@media (max-width: 380px) {
  .pack-grid { grid-template-columns: 1fr; }
}
