/* =========================================================
   Fast Finance — App-shell stylesheet
   Palette sampled directly from the brand mark:
   pink #E8055C -> light #FF3C91 -> deep #98012B, navy #19262C
   ========================================================= */

:root {
  --pink: #e8055c;
  --pink-light: #ff3c91;
  --pink-deep: #98012b;
  --navy: #19262c;
  --navy-2: #24333b;
  --bg: #f6f5f8;
  --white: #ffffff;
  --text: #23272b;
  --text-muted: #6b7280;
  --border: #e7e5ec;
  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 9px;
  --shadow-card: 0 10px 24px -14px rgba(25, 38, 44, 0.35);
  --app-max-width: 480px;
  --appbar-h: 58px;
  --tabbar-h: 66px;
}

:root[data-theme="dark"] {
  --bg: #14181a;
  --white: #1d2327;
  --text: #f2f1f4;
  --text-muted: #9aa2a8;
  --border: #2b3236;
}

* { box-sizing: border-box; }

html {
  scroll-padding-top: calc(var(--appbar-h) + env(safe-area-inset-top, 0px));
}

body {
  margin: 0;
  font-family: "Hind Siliguri", "Noto Sans Bengali", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }

/* ---------- App shell ---------- */

.app-shell {
  max-width: var(--app-max-width);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 40px rgba(0,0,0,0.06);
}

.app-bar {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 40;
  height: var(--appbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 16px;
  background: var(--white);
  border-bottom: 1px solid var(--border);
}

.app-bar__brand {
  display: flex;
  align-items: center;
  gap: 9px;
}

.app-bar__brand img { height: 26px; width: auto; }

.app-bar__title {
  font-weight: 700;
  font-size: 15px;
  color: var(--navy);
  letter-spacing: 0.2px;
}

.app-bar__action {
  font-size: 13px;
  font-weight: 600;
  color: var(--pink);
  padding: 8px 12px;
  border-radius: 100px;
  background: rgba(232,5,92,0.08);
}

.app-content {
  flex: 1;
  padding-bottom: calc(var(--tabbar-h) + 18px);
}

/* ---------- Bottom tab bar ---------- */

.tab-bar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 100%;
  max-width: var(--app-max-width);
  display: flex;
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
  z-index: 50;
}

.tab-bar__item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 6px 2px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
}

.tab-bar__item svg { width: 22px; height: 22px; }

.tab-bar__item.is-active {
  color: var(--pink);
}

.tab-bar__item.is-active svg { stroke: var(--pink); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 20px;
  border-radius: 100px;
  font-size: 15px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  text-align: center;
}

.btn-primary {
  background: linear-gradient(120deg, var(--pink) 0%, var(--pink-deep) 100%);
  color: #fff;
  box-shadow: 0 12px 20px -10px rgba(232,5,92,0.55);
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--navy);
  color: var(--navy);
}

.btn-ghost {
  background: rgba(25,38,44,0.06);
  color: var(--navy);
}

.btn-sm { padding: 10px 16px; font-size: 13px; width: auto; }
.btn-block-row { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
  color: #fff;
  padding: 30px 20px 46px;
  clip-path: polygon(0 0, 100% 0, 100% 88%, 0 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: -30% -10% auto auto;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(232,5,92,0.55), transparent 70%);
  filter: blur(2px);
}

.hero__eyebrow-mark {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
}

.hero__mark-line { height: 3px; width: 22px; border-radius: 4px; background: var(--pink); }
.hero__mark-line:nth-child(2) { width: 14px; opacity: 0.7; }
.hero__mark-line:nth-child(3) { width: 8px; opacity: 0.4; }

.hero h1 {
  font-size: 26px;
  line-height: 1.35;
  margin: 0 0 10px;
  position: relative;
  max-width: 300px;
}

.hero p {
  color: rgba(255,255,255,0.75);
  font-size: 14.5px;
  line-height: 1.6;
  margin: 0 0 22px;
  max-width: 300px;
  position: relative;
}

.hero .btn-primary { width: auto; padding: 14px 26px; }

.hero__stats {
  display: flex;
  gap: 22px;
  margin-top: 26px;
  position: relative;
}

.hero__stat b { display: block; font-size: 19px; }
.hero__stat span { font-size: 11.5px; color: rgba(255,255,255,0.65); }

/* ---------- Sections ---------- */

.section { padding: 26px 20px; }
.section-title { font-size: 18px; font-weight: 700; margin: 0 0 4px; color: var(--navy); }
.section-sub { font-size: 13.5px; color: var(--text-muted); margin: 0 0 18px; }

/* Step list (genuinely sequential — numbered) */
.step-list { display: flex; flex-direction: column; gap: 0; }

.step-item {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  position: relative;
}

.step-item:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 17px;
  top: 42px;
  bottom: -6px;
  width: 2px;
  background: var(--border);
}

.step-num {
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  z-index: 1;
}

.step-item.is-active .step-num,
.step-item.is-done .step-num { background: var(--pink); }

.step-body h3 { margin: 3px 0 3px; font-size: 14.5px; color: var(--navy); }
.step-body p { margin: 0; font-size: 13px; color: var(--text-muted); line-height: 1.5; }

/* Feature rows (not identical cards — alternating text/icon rows) */
.feature-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.feature-row:last-child { border-bottom: none; }

.feature-icon {
  flex: none;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(232,5,92,0.09);
  color: var(--pink);
}
.feature-icon svg { width: 22px; height: 22px; }

.feature-body h3 { margin: 0 0 3px; font-size: 14.5px; color: var(--navy); }
.feature-body p { margin: 0; font-size: 13px; color: var(--text-muted); line-height: 1.5; }

/* ---------- Cards / surfaces ---------- */

.surface {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 20px;
}

.info-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}

/* ---------- Forms ---------- */

.form-group { margin-bottom: 16px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}

.form-label .req { color: var(--pink); }

.form-hint { font-size: 11.5px; color: var(--text-muted); margin-top: 5px; }

.form-control {
  width: 100%;
  padding: 13px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
  background: var(--white);
  font-size: 14.5px;
  color: var(--text);
  font-family: inherit;
}

.form-control:focus {
  outline: none;
  border-color: var(--pink);
  box-shadow: 0 0 0 4px rgba(232,5,92,0.12);
}

textarea.form-control { resize: vertical; min-height: 88px; }

.file-drop {
  border: 1.5px dashed var(--border);
  border-radius: var(--radius-md);
  padding: 18px 14px;
  text-align: center;
  background: rgba(25,38,44,0.02);
  position: relative;
}

.file-drop input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.file-drop__icon { color: var(--pink); margin-bottom: 6px; }
.file-drop__label { font-size: 13px; font-weight: 600; color: var(--navy); }
.file-drop__hint { font-size: 11.5px; color: var(--text-muted); margin-top: 3px; }

.fieldset-title {
  font-size: 12.5px;
  font-weight: 700;
  text-transform: none;
  color: var(--pink-deep);
  margin: 22px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(232,5,92,0.15);
}
.fieldset-title:first-child { margin-top: 0; }

.alert {
  padding: 13px 15px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  margin-bottom: 16px;
  line-height: 1.5;
}
.alert-error { background: #fdecef; color: #98012b; border: 1px solid #f6c3d1; }
.alert-success { background: #eafaf1; color: #146c3f; border: 1px solid #bdead2; }
.alert-info { background: #eef4ff; color: #1e429f; border: 1px solid #c7d9fb; }

/* ---------- Badges ---------- */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.badge-pending { background: #fff3e0; color: #b8690a; }
.badge-processing { background: #e8f0fe; color: #1a56b0; }
.badge-approved { background: #e6f7ec; color: #1a7d43; }
.badge-rejected { background: #fdeaea; color: #b8231f; }

/* ---------- Tracking result ---------- */

.tracking-head {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  margin-bottom: 22px;
}
.tracking-head .tn { font-size: 20px; font-weight: 700; letter-spacing: 0.5px; }
.tracking-head .sub { font-size: 12.5px; color: rgba(255,255,255,0.65); margin-top: 4px; }

/* ---------- Empty state ---------- */

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}
.empty-state svg { color: var(--border); margin-bottom: 12px; }
.empty-state h3 { color: var(--navy); margin: 0 0 6px; font-size: 15px; }
.empty-state p { margin: 0; font-size: 13px; }

/* ---------- Footer ---------- */

.app-footer {
  padding: 18px 20px 26px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  border-top: 1px solid var(--border);
}
.app-footer .brand-name { color: var(--navy); font-weight: 700; }

/* =========================================================
   Admin panel
   ========================================================= */

.admin-shell { min-height: 100vh; background: var(--bg); }

.admin-topbar {
  background: var(--navy);
  color: #fff;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 30;
}
.admin-topbar__brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.admin-topbar__brand img { height: 24px; }
.admin-topbar a.logout { font-size: 12.5px; color: rgba(255,255,255,0.75); background: rgba(255,255,255,0.1); padding: 8px 14px; border-radius: 100px; }

.admin-wrap { max-width: 1080px; margin: 0 auto; padding: 20px 16px 60px; }

.admin-stats { display: grid; grid-template-columns: repeat(auto-fit,minmax(140px,1fr)); gap: 12px; margin-bottom: 20px; }
.admin-stat { background: var(--white); border-radius: var(--radius-md); padding: 16px; border: 1px solid var(--border); }
.admin-stat b { display: block; font-size: 22px; color: var(--navy); }
.admin-stat span { font-size: 12px; color: var(--text-muted); }
.admin-stat.accent { border-color: transparent; background: linear-gradient(120deg, var(--pink), var(--pink-deep)); }
.admin-stat.accent b, .admin-stat.accent span { color: #fff; }

.filter-tabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.filter-tabs a {
  font-size: 12.5px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 100px;
  background: var(--white);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.filter-tabs a.is-active { background: var(--navy); color: #fff; border-color: var(--navy); }

.admin-search { margin-bottom: 16px; }
.admin-search .form-control { max-width: 320px; }

.table-card { background: var(--white); border-radius: var(--radius-md); border: 1px solid var(--border); overflow: hidden; }
.table-wrap { overflow-x: auto; }

table.app-table { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 720px; }
table.app-table th, table.app-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); white-space: nowrap; }
table.app-table th { background: rgba(25,38,44,0.03); color: var(--text-muted); font-weight: 600; font-size: 12px; }
table.app-table tr:last-child td { border-bottom: none; }
table.app-table a.view-link { color: var(--pink); font-weight: 700; }

.admin-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: var(--navy);
}
.admin-login-card {
  width: 100%;
  max-width: 360px;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  text-align: center;
}
.admin-login-card img { height: 34px; margin: 0 auto 16px; }
.admin-login-card h1 { font-size: 17px; color: var(--navy); margin: 0 0 22px; }
.admin-login-card .form-group { text-align: left; }

.detail-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 760px) {
  .detail-grid { grid-template-columns: 1.1fr 0.9fr; }
}

.doc-preview { display: grid; grid-template-columns: repeat(auto-fit,minmax(140px,1fr)); gap: 12px; }
.doc-preview figure { margin: 0; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md); overflow: hidden; }
.doc-preview img { width: 100%; height: 130px; object-fit: cover; }
.doc-preview figcaption { padding: 8px 10px; font-size: 11.5px; color: var(--text-muted); }

.kv-list { display: flex; flex-direction: column; }
.kv-row { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.kv-row:last-child { border-bottom: none; }
.kv-row .k { color: var(--text-muted); }
.kv-row .v { font-weight: 600; color: var(--navy); text-align: right; }

.status-history { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.status-history .sh-item { font-size: 12.5px; color: var(--text-muted); display: flex; justify-content: space-between; gap: 10px; }

@media (max-width: 380px) {
  .hero h1 { font-size: 22px; }
}

/* =========================================================
   Accounts, notifications, documents (customer side)
   ========================================================= */

.app-bar__brand { color: inherit; }

.app-bar__bell {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  background: rgba(25,38,44,0.06);
}
.app-bar__bell svg { width: 21px; height: 21px; }
.app-bar__dot {
  position: absolute;
  top: -3px;
  right: -3px;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  border-radius: 100px;
  background: var(--pink);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--white);
}

.tab-bar__icon { position: relative; display: flex; }
.tab-bar__badge {
  position: absolute;
  top: -1px;
  right: -3px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--pink);
  border: 2px solid var(--white);
}

.hero__cta { display: flex; gap: 10px; flex-wrap: wrap; position: relative; }
.hero .btn-hero-ghost {
  width: auto;
  padding: 14px 26px;
  background: rgba(255,255,255,0.1);
  color: #fff;
  border: 1.5px solid rgba(255,255,255,0.28);
}

.auth-switch { text-align: center; font-size: 13.5px; color: var(--text-muted); margin: 18px 0 0; }
.auth-switch a, .link-pink { color: var(--pink); font-weight: 700; }

.success-mark {
  width: 70px; height: 70px; border-radius: 50%;
  background: #e6f7ec; color: #1a7d43;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 18px;
}

.greet { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.greet__avatar {
  flex: none; width: 50px; height: 50px; border-radius: 50%;
  background: linear-gradient(135deg, var(--pink), var(--pink-deep));
  color: #fff; font-size: 20px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.head-note {
  margin-top: 12px; padding: 11px 13px; border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.1); font-size: 13px; line-height: 1.55;
}

.alert-link { display: block; text-decoration: none; }
.section-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }

/* Status badges (custom statuses use one of these colours) */
.badge-c-amber  { background: #fff3e0; color: #b8690a; }
.badge-c-blue   { background: #e8f0fe; color: #1a56b0; }
.badge-c-green  { background: #e6f7ec; color: #1a7d43; }
.badge-c-red    { background: #fdeaea; color: #b8231f; }
.badge-c-purple { background: #f1e9fd; color: #6b34b8; }
.badge-c-teal   { background: #e0f5f4; color: #0f766e; }
.badge-c-pink   { background: #fde8f1; color: #b0104f; }
.badge-c-grey   { background: #eceef1; color: #4b5560; }

/* Timeline (real history of the application) */
.timeline { display: flex; flex-direction: column; }
.tl-item { display: flex; gap: 14px; position: relative; padding-bottom: 18px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item:not(:last-child)::before {
  content: ""; position: absolute; left: 6px; top: 18px; bottom: 0; width: 2px; background: var(--border);
}
.tl-dot {
  flex: none; width: 14px; height: 14px; border-radius: 50%; margin-top: 4px;
  background: var(--white); border: 3px solid var(--border); z-index: 1;
}
.tl-item.is-current .tl-dot { border-color: var(--pink); background: var(--pink); box-shadow: 0 0 0 4px rgba(232,5,92,0.15); }
.tl-body p { margin: 6px 0 0; font-size: 13px; line-height: 1.55; color: var(--text); }
.tl-body time { display: block; margin-top: 5px; font-size: 12px; color: var(--text-muted); }

/* Documents */
.doc-list { display: flex; flex-direction: column; gap: 12px; }
.doc-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 14px 15px; margin-bottom: 12px;
}
.doc-list .doc-card { margin-bottom: 0; }
.doc-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.doc-card__head b { font-size: 14.5px; color: var(--navy); }
.doc-card__desc { margin: 8px 0 0; font-size: 13px; color: var(--text-muted); line-height: 1.55; }
.doc-card__reject { margin: 8px 0 0; font-size: 13px; color: #b8231f; background: #fdeaea; padding: 8px 10px; border-radius: var(--radius-sm); }
.doc-card__file { margin: 8px 0 0; font-size: 12.5px; color: var(--text-muted); word-break: break-word; }
.doc-card__file a { color: var(--pink); font-weight: 600; }
.doc-card__form { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.doc-card__form .form-control { padding: 10px; font-size: 13px; }

/* Notifications */
.notice-list { display: flex; flex-direction: column; gap: 10px; }
.notice {
  display: block; background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 13px 15px;
}
.notice.is-unread { border-left: 4px solid var(--pink); background: #fff8fb; }
.notice b { display: block; font-size: 14px; color: var(--navy); }
.notice p { margin: 5px 0 0; font-size: 13px; line-height: 1.5; color: var(--text); }
.notice time { display: block; margin-top: 6px; font-size: 11.5px; color: var(--text-muted); }

/* =========================================================
   Admin panel v2 — sidebar layout
   ========================================================= */

.adm { display: flex; min-height: 100vh; background: var(--bg); }

.adm-side {
  width: 236px; flex: none; background: var(--navy); color: #fff;
  display: flex; flex-direction: column; padding: 20px 14px;
  position: sticky; top: 0; height: 100vh;
}
.adm-side__brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 20px; font-weight: 700; }
.adm-side__brand img { height: 26px; width: auto; }
.adm-side__brand span { font-size: 13px; color: rgba(255,255,255,0.65); font-weight: 500; }

.adm-nav { display: flex; flex-direction: column; gap: 4px; }
.adm-nav a {
  display: flex; align-items: center; gap: 11px; padding: 11px 12px;
  border-radius: var(--radius-sm); font-size: 14px; font-weight: 600; color: rgba(255,255,255,0.72);
}
.adm-nav a svg { width: 19px; height: 19px; flex: none; }
.adm-nav a:hover { background: rgba(255,255,255,0.07); color: #fff; }
.adm-nav a.is-active { background: linear-gradient(120deg, var(--pink), var(--pink-deep)); color: #fff; }

.adm-side__user {
  margin-top: auto; padding: 12px; border-radius: var(--radius-md);
  background: rgba(255,255,255,0.07); display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.adm-side__user b { display: block; font-size: 13.5px; }
.adm-side__user small { color: rgba(255,255,255,0.6); font-size: 11.5px; }
.adm-side__user .logout { font-size: 12px; padding: 7px 12px; border-radius: 100px; background: rgba(255,255,255,0.12); color: #fff; white-space: nowrap; }

.adm-main { flex: 1; min-width: 0; }
.adm-main .admin-wrap { max-width: 1120px; padding: 26px 24px 70px; }

.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-size: 22px; color: var(--navy); }
.page-head p { margin: 4px 0 0; }
.back-link { display: inline-block; font-size: 12.5px; color: var(--text-muted); margin-bottom: 6px; }
.muted { color: var(--text-muted); }
.small { font-size: 12.5px; }
code.code { background: rgba(25,38,44,0.06); padding: 3px 8px; border-radius: 6px; font-size: 12.5px; letter-spacing: 0.5px; }

.panel {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 18px; margin-bottom: 16px;
}
.panel-title { margin: 0 0 12px; font-size: 15px; color: var(--navy); }

.btn-inline { width: auto; padding: 12px 22px; font-size: 14px; }
.btn-xs { width: auto; padding: 7px 13px; font-size: 12px; }
.btn-danger { background: #fdeaea; color: #b8231f; }
.btn-ok { background: #e6f7ec; color: #1a7d43; }

.chip {
  display: inline-block; padding: 3px 10px; border-radius: 100px; font-size: 11.5px; font-weight: 600;
  background: rgba(25,38,44,0.07); color: var(--navy); margin: 2px 4px 2px 0;
}
.chip-warn { background: #fff3e0; color: #b8690a; }
.chip-off { background: #eceef1; color: #6b7280; }

.admin-stat.warn { background: #fff8ec; border-color: #f6dfb6; }

.ref-card {
  display: flex; gap: 18px; align-items: center; flex-wrap: wrap;
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 14px 18px; margin-bottom: 18px;
}
.ref-card small { display: block; font-size: 11.5px; color: var(--text-muted); margin-bottom: 3px; }
.ref-card__code { font-size: 22px; letter-spacing: 2px; color: var(--pink); }
.ref-card__link { flex: 1; min-width: 240px; }
.ref-card__link .form-control { padding: 9px 12px; font-size: 12.5px; }

.pager { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 16px; }
.pager a { min-width: 36px; text-align: center; padding: 8px 10px; border-radius: var(--radius-sm); background: var(--white); border: 1px solid var(--border); font-size: 13px; font-weight: 600; color: var(--text-muted); }
.pager a.is-active { background: var(--navy); border-color: var(--navy); color: #fff; }

.status-rows { display: flex; flex-direction: column; }
.status-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 0; border-bottom: 1px solid var(--border); }
.status-row:last-child { border-bottom: none; }
.status-row.is-off { opacity: 0.6; }
.status-row__main { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.status-row__actions { display: flex; gap: 6px; }
.status-row__actions form { margin: 0; }

.color-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.color-pick__opt { cursor: pointer; }
.color-pick__opt input { position: absolute; opacity: 0; pointer-events: none; }
.color-pick__opt .badge { border: 2px solid transparent; padding: 6px 13px; }
.color-pick__opt input:checked + .badge { border-color: var(--navy); }
.color-pick__opt input:focus-visible + .badge { outline: 2px solid var(--pink); outline-offset: 2px; }

.check { display: flex; align-items: center; gap: 9px; font-size: 13.5px; margin: 9px 0; cursor: pointer; }
.check input { width: 17px; height: 17px; accent-color: var(--pink); }

.role-card { padding: 14px 0; border-bottom: 1px solid var(--border); }
.role-card:last-child { border-bottom: none; }
.role-card__head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.role-card__head b { color: var(--navy); font-size: 15px; }
.role-card p { margin: 4px 0 0; }
.role-card__perms { margin-top: 8px; }
.role-card__actions { display: flex; gap: 6px; margin-top: 10px; }
.role-card__actions form { margin: 0; }

.perm-list { display: flex; flex-direction: column; gap: 8px; }
.perm { display: flex; gap: 11px; align-items: flex-start; padding: 11px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; }
.perm input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--pink); flex: none; }
.perm b { display: block; font-size: 13.5px; color: var(--navy); }
.perm small { display: block; color: var(--text-muted); font-size: 12px; margin-top: 2px; line-height: 1.45; }

.review-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.review-form .form-control { flex: 1; min-width: 160px; padding: 8px 11px; font-size: 13px; }

.adm .table-card + .pager { margin-bottom: 10px; }

@media (max-width: 860px) {
  .adm { flex-direction: column; }
  .adm-side {
    width: auto; height: auto; position: sticky; top: 0; z-index: 30;
    flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 10px 14px;
  }
  .adm-side__brand { padding: 0; }
  .adm-nav { order: 3; width: 100%; flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 2px; }
  .adm-nav a { padding: 9px 13px; white-space: nowrap; }
  .adm-side__user { margin: 0 0 0 auto; padding: 6px 8px 6px 12px; }
  .adm-side__user small { display: none; }
  .adm-main .admin-wrap { padding: 18px 14px 60px; }
}

@media (prefers-reduced-motion: no-preference) {
  .btn, .adm-nav a, .filter-tabs a { transition: background-color .15s ease, color .15s ease, opacity .15s ease; }
}

:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
