/* OMAR-VPN — lobster theme */
:root{
  --shell-deep:#7a1c12;
  --shell:#c5443a;
  --shell-bright:#e2563d;
  --tail:#f08a4b;
  --cream:#fbe9c8;
  --sand:#f4d9a8;
  --ink:#2a0d0a;
  --ink-2:#5a221b;
  --ok:#2f8f5e;
  --warn:#b07b00;
  --bad:#8b1a1a;
  --shadow:0 18px 40px rgba(80,15,10,.35);
}

*{box-sizing:border-box}
html,body{margin:0;padding:0;font-family:ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:var(--ink);}
body.lobster{
  min-height:100vh;
  background:
    radial-gradient(1200px 600px at 20% -10%, rgba(255,200,140,.45), transparent 60%),
    radial-gradient(900px 600px at 110% 110%, rgba(255,160,90,.35), transparent 60%),
    linear-gradient(160deg, #4a0d08 0%, #8e1e12 35%, #c5443a 70%, #f08a4b 100%);
  background-attachment:fixed;
  display:flex;
  flex-direction:column;
  align-items:center;
  padding:24px 16px 80px;
}

/* lobster claws as decorative side accents */
.claw{
  position:fixed;
  top:50%;
  width:240px;height:240px;
  transform:translateY(-50%);
  background:
    radial-gradient(closest-side at 35% 35%, var(--shell-bright), var(--shell) 60%, var(--shell-deep) 100%);
  filter:drop-shadow(0 6px 18px rgba(0,0,0,.35));
  pointer-events:none;
  opacity:.55;
  z-index:0;
}
.claw-l{
  left:-120px;
  clip-path:polygon(0 30%, 60% 0, 100% 30%, 90% 55%, 100% 70%, 70% 100%, 0 80%);
}
.claw-r{
  right:-120px;
  clip-path:polygon(40% 0, 100% 30%, 100% 80%, 30% 100%, 0 70%, 10% 55%, 0 30%);
}
@media (max-width:720px){ .claw{display:none} }

/* lock icon (admin entry) */
.lock-btn,.back-btn{
  position:fixed;top:18px;right:18px;z-index:5;
  display:inline-flex;align-items:center;gap:6px;
  padding:9px 12px;border-radius:999px;
  background:rgba(255,255,255,.14);
  color:var(--cream);
  text-decoration:none;
  border:1px solid rgba(255,255,255,.28);
  backdrop-filter:blur(6px);
  transition:transform .15s ease,background .15s ease;
}
.lock-btn:hover,.back-btn:hover{ background:rgba(255,255,255,.22); transform:translateY(-1px) }
.back-btn{font-size:14px}

/* card */
.card{
  position:relative;z-index:1;
  width:100%;max-width:540px;
  margin-top:36px;
  padding:28px 26px;
  background:linear-gradient(180deg,var(--cream),#fff5dc);
  border-radius:22px;
  box-shadow:var(--shadow);
  border:2px solid rgba(122,28,18,.22);
}
.logo-wrap{display:flex;justify-content:center;margin-bottom:8px}
.logo-wrap.small{margin-bottom:2px}
.logo{
  width:118px;height:118px;border-radius:50%;
  object-fit:cover;
  border:4px solid var(--shell);
  box-shadow:0 8px 24px rgba(122,28,18,.4);
  background:#fff;
}
.logo.small{width:54px;height:54px;border-width:3px;box-shadow:0 4px 12px rgba(122,28,18,.35)}

h1{
  margin:8px 0 4px;text-align:center;
  font-size:34px;letter-spacing:.5px;
  color:var(--shell-deep);
  font-weight:800;
}
.tag{margin:0;text-align:center;color:var(--ink-2);font-size:14px}
.sub{margin:0 0 6px;color:var(--ink-2);font-size:13px}
label{display:block;margin:14px 0 6px;font-weight:600;color:var(--ink-2)}

input[type=text],input[type=password]{
  width:100%;padding:13px 14px;border-radius:12px;
  border:2px solid rgba(122,28,18,.25);
  background:#fff;font-size:15px;color:var(--ink);
  outline:none;transition:border-color .15s,box-shadow .15s;
}
input:focus{border-color:var(--shell);box-shadow:0 0 0 3px rgba(197,68,58,.2)}

button{
  font-family:inherit;font-size:15px;font-weight:600;
  border:none;border-radius:12px;cursor:pointer;
  padding:13px 16px;margin-top:12px;width:100%;
  transition:transform .12s ease, filter .12s ease, background .12s;
}
button.primary{
  color:#fff;
  background:linear-gradient(180deg,var(--shell-bright),var(--shell-deep));
  box-shadow:0 6px 16px rgba(122,28,18,.35);
}
button.primary:hover{filter:brightness(1.06);transform:translateY(-1px)}
button.ghost{
  background:transparent;color:var(--shell-deep);
  border:2px solid rgba(122,28,18,.3);
}
button.ghost:hover{background:rgba(122,28,18,.07)}
button.ghost.small{width:auto;padding:8px 12px;font-size:13px;margin:0}
button.danger{
  background:#8b1a1a;color:#fff;
}
button.danger:hover{filter:brightness(1.1)}
button.copy{
  width:auto;padding:9px 14px;margin:0;
  background:var(--shell);color:#fff;font-size:13px;
}

.hint{margin-top:10px;text-align:center;color:var(--ink-2);font-size:13px}
.error{color:var(--bad);font-size:14px;margin:8px 0 0;min-height:18px}

/* steps (multi-step landing flow) */
.step{display:none}
.step.active{display:block}

/* link reveal */
.link-box{
  display:flex;align-items:center;gap:8px;
  background:#fff;border:2px dashed var(--shell);
  border-radius:14px;padding:10px 12px;margin-top:6px;
}
.link-box code{
  flex:1;display:block;
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
  font-size:12px;color:var(--ink);
  word-break:break-all;
  max-height:6.5em;overflow:auto;
}
.copied{
  color:var(--ok);font-size:13px;text-align:center;
  margin:6px 0 0;height:18px;opacity:0;transition:opacity .2s;
}
.copied.show{opacity:1}

/* how-to accordions */
.howto{
  margin-top:14px;border:1px solid rgba(122,28,18,.2);
  border-radius:12px;background:#fff;padding:0 14px;
}
.howto > summary{
  cursor:pointer;padding:12px 4px;font-weight:700;color:var(--shell-deep);
  list-style:none;
}
.howto > summary::-webkit-details-marker{display:none}
.howto > summary::before{content:"▸";display:inline-block;margin-right:8px;transition:transform .15s}
.howto[open] > summary::before{transform:rotate(90deg)}
.howto ol,.howto ul{margin:0 0 14px;padding-left:22px;color:var(--ink-2);line-height:1.55;font-size:14px}
.howto li{margin:4px 0}
.howto b{color:var(--ink)}

footer{
  position:relative;z-index:1;
  margin-top:30px;color:rgba(255,235,200,.85);
  font-size:12px;text-align:center;max-width:560px;
}

/* ---------- ADMIN DASH ---------- */
.admin .card{max-width:900px}
.dash{
  position:relative;z-index:1;
  width:100%;max-width:980px;display:flex;flex-direction:column;gap:18px;margin-top:24px;
}
.dash-head{
  display:flex;justify-content:space-between;align-items:center;gap:16px;
  background:linear-gradient(180deg,var(--cream),#fff5dc);
  padding:14px 18px;border-radius:18px;border:2px solid rgba(122,28,18,.22);
  box-shadow:var(--shadow);
}
.brand{display:flex;align-items:center;gap:14px}
.brand h1{font-size:22px;margin:0;text-align:left}
.brand .tag{text-align:left}
.dash-head .actions{display:flex;gap:8px;flex-wrap:wrap}
.dash-head .actions button{margin:0}

.create .row{display:grid;grid-template-columns:1fr auto auto;gap:10px;align-items:center}
@media (max-width:720px){ .create .row{grid-template-columns:1fr} }
.checkbox{display:inline-flex;align-items:center;gap:8px;font-size:14px;color:var(--ink-2);user-select:none}
.checkbox input{width:18px;height:18px;accent-color:var(--shell)}
.create button{margin-top:0}

.result{
  margin-top:14px;background:#fff;border:2px solid var(--ok);
  border-radius:12px;padding:14px;
}
.result.hidden{display:none}
.result h3{margin:0 0 8px;color:var(--ok)}
.result .kv{display:grid;grid-template-columns:120px 1fr;gap:6px 12px;font-size:14px;align-items:center}
.result .kv b{color:var(--ink-2);font-weight:600}
.result code{
  font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12px;
  background:#f7f0db;padding:6px 8px;border-radius:6px;display:inline-block;word-break:break-all;
}

.list-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px}
.count{
  display:inline-block;background:var(--shell);color:#fff;
  font-size:13px;border-radius:999px;padding:2px 10px;margin-left:6px;
}

#users-table{display:flex;flex-direction:column;gap:8px}
.user-row{
  display:grid;
  grid-template-columns: 1.2fr 1.2fr 1fr auto;
  gap:10px;align-items:center;
  background:#fff;border:1px solid rgba(122,28,18,.2);
  padding:10px 12px;border-radius:12px;font-size:13px;
}
.user-row .nm{font-weight:700;color:var(--shell-deep);font-size:15px;display:flex;align-items:center;gap:8px}
.user-row .nm .badge{font-size:11px;padding:2px 8px;border-radius:999px;font-weight:600}
.badge.active{background:#e3f5ea;color:var(--ok)}
.badge.stopped{background:#fde8c6;color:var(--warn)}
.badge.nopass{background:#e9e6ff;color:#4a39a8}
.badge.fresh{background:#dff1ff;color:#0a4d80}
.badge.used{background:#eee;color:#777}
.user-row .pwd code.used{text-decoration:line-through;color:#999;background:#f0f0f0}
.user-row .pwd code,.user-row .uuid code{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12px;background:#f7f0db;padding:3px 6px;border-radius:6px;display:inline-block;word-break:break-all}
.user-row .actions{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}
.user-row .actions button{margin:0;padding:6px 10px;width:auto;font-size:12px;border-radius:8px}
@media (max-width:720px){
  .user-row{grid-template-columns:1fr;}
  .user-row .actions{justify-content:flex-start}
}

/* modal */
.modal{
  position:fixed;inset:0;background:rgba(20,5,5,.55);display:flex;align-items:center;justify-content:center;z-index:50;
  backdrop-filter:blur(4px);
}
.modal.hidden{display:none}
.modal-card{
  background:linear-gradient(180deg,var(--cream),#fff5dc);
  padding:22px;border-radius:16px;max-width:420px;width:calc(100% - 32px);
  border:2px solid rgba(122,28,18,.25);box-shadow:var(--shadow);
}
.modal-card h3{margin:0 0 8px;color:var(--shell-deep)}
.modal-card p{margin:0 0 14px;color:var(--ink-2)}
.modal-actions{display:flex;gap:10px;justify-content:flex-end}
.modal-actions button{width:auto;margin:0;padding:10px 14px}

.hidden{display:none !important}
