/* ===== Fastcloud — Member Area & Admin Panel ===== */
:root {
  --bg: #0b0f1a;
  --bg-2: #0f1524;
  --card: #131a2b;
  --card-2: #182136;
  --line: #222c44;
  --text: #e6ebf5;
  --muted: #8a96b3;
  --primary: #22d3ee;
  --primary-2: #3b82f6;
  --ok: #22c55e;
  --warn: #f59e0b;
  --bad: #ef4444;
  --info: #38bdf8;
  --radius: 14px;
  --side-w: 250px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: "Plus Jakarta Sans", system-ui, sans-serif; background: var(--bg); color: var(--text); line-height: 1.55; font-size: 15px; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
[data-lucide] { width: 18px; height: 18px; stroke-width: 2; flex-shrink: 0; }
.mono { font-family: "JetBrains Mono", monospace; }
.muted { color: var(--muted); }
.w-full { width: 100%; }
.grad { background: linear-gradient(90deg, var(--primary), var(--primary-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ===== Brand ===== */
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-2)); }
.brand-logo { width: 38px; height: 38px; border-radius: 10px; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text b { font-size: 1.1rem; font-weight: 800; }
.brand-text small { font-size: .65rem; letter-spacing: 1.5px; color: var(--muted); font-weight: 600; }

/* ===== Buttons ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 10px; font-weight: 600; font-size: .95rem; font-family: inherit; border: 1px solid transparent; cursor: pointer; transition: .2s; color: var(--text); background: var(--card-2); white-space: nowrap; }
.btn:hover { filter: brightness(1.12); }
.btn-primary { background: linear-gradient(90deg, var(--primary), var(--primary-2)); color: #06121f; }
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-ghost:hover { border-color: var(--primary); }
.btn-danger { background: rgba(239,68,68,.15); color: #fca5a5; border-color: rgba(239,68,68,.35); }
.btn-danger-text { color: #fca5a5; }
.btn-ok { background: rgba(34,197,94,.15); color: #86efac; border-color: rgba(34,197,94,.35); }
.btn-sm { padding: 7px 14px; font-size: .85rem; }
.btn-xs { padding: 4px 10px; font-size: .78rem; border-radius: 8px; }
.icon-btn { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--card); border: 1px solid var(--line); color: var(--text); cursor: pointer; }

/* ===== Layout ===== */
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--side-w); background: var(--bg-2); border-right: 1px solid var(--line); display: flex; flex-direction: column; z-index: 40; transition: transform .25s; }
.side-brand { padding: 18px 18px; border-bottom: 1px solid var(--line); }
.side-nav { flex: 1; overflow-y: auto; padding: 8px 10px; }
.side-group { font-size: .68rem; letter-spacing: 1.6px; text-transform: uppercase; color: var(--muted); font-weight: 700; padding: 16px 10px 6px; }
.side-nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: #c3cbe0; font-weight: 500; margin-bottom: 2px; }
.side-nav a:hover { background: var(--card); color: var(--text); }
.side-nav a.active { background: rgba(34,211,238,.1); color: var(--text); box-shadow: inset 0 0 0 1px rgba(34,211,238,.35); }
.side-foot { padding: 12px; border-top: 1px solid var(--line); }
.side-backdrop { display: none; }

.main { margin-left: var(--side-w); min-height: 100vh; }
.topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 14px; padding: 12px 24px; background: rgba(11,15,26,.88); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar-title { display: flex; flex-direction: column; line-height: 1.2; }
.topbar-title small { color: var(--muted); font-size: .78rem; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.user-chip { display: flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); font-weight: 600; font-size: .9rem; }
.user-chip img { width: 30px; height: 30px; border-radius: 8px; }
.content { padding: 28px 24px 60px; max-width: 1320px; margin: 0 auto; }

.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head h1 { font-size: 1.7rem; font-weight: 800; }
.page-head p { color: var(--muted); }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); margin-bottom: 10px; font-size: .9rem; }
.back:hover { color: var(--text); }

/* ===== Card ===== */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.card-head { padding: 18px 22px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.card-head h3 { font-size: 1.05rem; }
.card-head p { color: var(--muted); font-size: .85rem; }
.card-body { padding: 20px 22px; }
.stack > * + * { margin-top: 18px; }
.grid { display: grid; gap: 18px; }
.g-2 { grid-template-columns: repeat(2, 1fr); }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.split { display: grid; grid-template-columns: 1fr 360px; gap: 18px; align-items: start; }
.mt { margin-top: 18px; }

/* Stat strip */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stats.accent { border-top: 3px solid var(--primary); }
.stat { padding: 18px 22px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat small { display: flex; align-items: center; gap: 6px; text-transform: uppercase; letter-spacing: 1px; font-size: .72rem; color: var(--muted); font-weight: 600; margin-bottom: 6px; }
.stat small [data-lucide] { width: 14px; height: 14px; }
.stat b { font-size: 1.35rem; font-weight: 800; }
.stat .sub { font-size: .8rem; color: var(--warn); }

/* Spec tiles */
.specs { display: grid; grid-template-columns: repeat(4, 1fr); }
.spec { padding: 20px 22px; border-right: 1px solid var(--line); }
.spec:last-child { border-right: 0; }
.spec [data-lucide] { color: var(--primary); width: 22px; height: 22px; margin-bottom: 14px; }
.spec b { display: block; font-size: 1.35rem; font-weight: 800; }
.spec small { color: var(--muted); }

/* Key-value list */
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--muted); }
.kv span:last-child { font-weight: 600; text-align: right; word-break: break-all; }

/* Pills / alerts */
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 11px; border-radius: 999px; font-size: .78rem; font-weight: 600; white-space: nowrap; }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill-ok { background: rgba(34,197,94,.12); color: #4ade80; }
.pill-warn { background: rgba(245,158,11,.12); color: #fbbf24; }
.pill-bad { background: rgba(239,68,68,.12); color: #f87171; }
.pill-info { background: rgba(56,189,248,.12); color: #7dd3fc; }
.pill-muted { background: rgba(138,150,179,.12); color: var(--muted); }
.alert { padding: 14px 18px; border-radius: 12px; margin-bottom: 18px; border: 1px solid; }
.alert-success { background: rgba(34,197,94,.1); border-color: rgba(34,197,94,.3); color: #86efac; }
.alert-error { background: rgba(239,68,68,.1); border-color: rgba(239,68,68,.35); color: #fca5a5; }
.alert-warn { background: rgba(245,158,11,.08); border-color: rgba(245,158,11,.35); color: #fcd34d; }
.alert-info { background: rgba(56,189,248,.08); border-color: rgba(56,189,248,.3); color: #7dd3fc; }

/* Table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); font-weight: 600; padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: rgba(255,255,255,.015); }
.empty { padding: 40px 20px; text-align: center; color: var(--muted); }
.actions { display: flex; gap: 6px; flex-wrap: wrap; }
.actions form { display: inline; }

/* Forms */
label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: 6px; color: #c3cbe0; }
.field { margin-bottom: 16px; }
.hint { font-size: .78rem; color: var(--muted); margin-top: 4px; }
input[type=text], input[type=number], input[type=url], input[type=password], input[type=datetime-local], input[type=file], select, textarea {
  width: 100%; padding: 10px 13px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font: inherit; font-size: .93rem;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); }
textarea { min-height: 90px; resize: vertical; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; }
.check input { width: 16px; height: 16px; accent-color: var(--primary); }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; }

/* ===== Configurator ===== */
.cfg-section { margin-bottom: 26px; }
.cfg-section h4 { display: flex; align-items: center; gap: 8px; font-size: 1rem; margin-bottom: 12px; }
.cfg-section h4 [data-lucide] { color: var(--primary); }
.options { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.opt { text-align: left; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; color: var(--text); font: inherit; cursor: pointer; transition: .2s; }
.opt:hover { border-color: #33507a; }
.opt.active { border-color: var(--primary); background: rgba(34,211,238,.08); }
.opt b { display: block; }
.opt small { display: block; color: var(--muted); font-size: .78rem; }
.opt .accent { color: var(--primary); font-weight: 700; font-size: .82rem; }
.opt .flag { font-size: 1.3rem; }
.sliders { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 28px; }
.slider-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.slider-top span { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.slider-top span [data-lucide] { color: var(--primary); }
.slider-top b { font-size: 1.3rem; }
.slider-top b small { color: var(--muted); font-weight: 500; font-size: .8rem; }
input[type=range] { width: 100%; accent-color: var(--primary); cursor: pointer; }
.slider-bottom { display: flex; justify-content: space-between; font-size: .78rem; color: var(--muted); margin-top: 4px; }
.slider-bottom .accent { color: var(--primary); }
.summary { position: sticky; top: 90px; border-top: 3px solid var(--primary); }
.sum-big { font-size: 2.3rem; font-weight: 800; line-height: 1.1; }
.sum-line { display: flex; justify-content: space-between; padding: 9px 0; font-size: .93rem; }
.sum-line span:first-child { color: var(--muted); }
.sum-line.disc span:last-child { color: var(--ok); }
.sum-total { display: flex; justify-content: space-between; align-items: center; padding: 16px 0; border-top: 1px solid var(--line); margin-top: 8px; }
.sum-total b { font-size: 1.5rem; }

/* Product card */
.product { display: flex; flex-direction: column; overflow: hidden; }
.product img { height: 150px; width: 100%; object-fit: cover; }
.product .card-body { flex: 1; display: flex; flex-direction: column; }
.product p { color: var(--muted); font-size: .9rem; flex: 1; margin: 6px 0 14px; }
.product-foot { display: flex; justify-content: space-between; align-items: center; padding-top: 14px; border-top: 1px solid var(--line); }
.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .7rem; font-weight: 700; letter-spacing: .5px; background: rgba(34,211,238,.12); color: var(--primary); text-transform: uppercase; }

/* Invoice QR */
.qr-box { background: #fff; color: #111; border-radius: 16px; overflow: hidden; max-width: 330px; margin: 0 auto; }
.qr-box .qr-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid #eee; }
.qr-box .qr-head b { color: #d61f3c; font-weight: 800; letter-spacing: .5px; }
.qr-box .qr-head small { color: #666; font-size: .75rem; }
.qr-box .qr-body { padding: 18px; text-align: center; }
.qr-box .qr-body img { width: 230px; height: 230px; margin: 10px auto; image-rendering: pixelated; }
.qr-box .qr-foot { padding: 10px; text-align: center; font-size: .8rem; color: #555; border-top: 1px solid #eee; }
.pay-amount { text-align: center; margin: 18px 0 6px; }
.pay-amount small { color: var(--muted); }
.pay-amount b { display: block; font-size: 2rem; font-weight: 800; }
.cred { display: flex; align-items: center; gap: 8px; }
.cred code { font-family: "JetBrains Mono", monospace; background: var(--bg); border: 1px solid var(--line); padding: 6px 10px; border-radius: 8px; flex: 1; overflow-x: auto; }
.info-row { display: flex; gap: 14px; align-items: flex-start; }
.info-row .ico { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; background: rgba(34,211,238,.1); color: var(--primary); flex-shrink: 0; }

/* ===== Login ===== */
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 16px;
  background: radial-gradient(600px 400px at 20% 10%, rgba(34,211,238,.14), transparent 70%), radial-gradient(500px 400px at 85% 90%, rgba(59,130,246,.14), transparent 70%), var(--bg); }
.login-card { width: 100%; max-width: 420px; padding: 36px 32px; text-align: center; }
.login-card .brand { justify-content: center; margin-bottom: 26px; }
.login-card h1 { font-size: 1.5rem; margin-bottom: 6px; }
.login-card p { color: var(--muted); margin-bottom: 26px; }
.btn-discord { background: #5865f2; color: #fff; width: 100%; padding: 13px; font-size: 1rem; }
.btn-discord svg { width: 22px; height: 22px; }

/* ===== Responsive ===== */
@media (max-width: 1100px) {
  .split { grid-template-columns: 1fr; }
  .summary { position: static; }
  .g-4, .stats, .specs { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2), .spec:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2), .spec:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 860px) {
  .sidebar { transform: translateX(-100%); }
  body.side-open .sidebar { transform: none; }
  body.side-open .side-backdrop { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 35; }
  .main { margin-left: 0; }
  .g-2, .g-3, .sliders { grid-template-columns: 1fr; }
  .hide-sm { display: none !important; }
  .topbar { padding: 10px 16px; }
  .content { padding: 20px 16px 50px; }
}
@media (min-width: 861px) { .topbar .icon-btn { display: none; } }
@media (max-width: 520px) {
  .g-4, .stats, .specs { grid-template-columns: 1fr; }
  .stat, .spec { border-right: 0 !important; border-bottom: 1px solid var(--line); }
}
