:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #201b32;
  background: #f5f4fb;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --primary: #6441d8;
  --primary-dark: #4526a7;
  --primary-light: #eee9ff;
  --violet-900: #32165d;
  --violet-800: #46247f;
  --violet-700: #5934b5;
  --gold: #e6bc4c;
  --gold-light: #fff5ce;
  --surface: #ffffff;
  --surface-soft: #f7f6fc;
  --text: #211c31;
  --muted: #756f86;
  --border: #e6e2ef;
  --success: #1d9b67;
  --success-soft: #e8f8f1;
  --danger: #d64c57;
  --danger-soft: #fff0f1;
  --warning: #c8891d;
  --shadow-sm: 0 8px 24px rgba(44, 30, 85, 0.08);
  --shadow-md: 0 18px 48px rgba(44, 30, 85, 0.14);
  --shadow-lg: 0 28px 90px rgba(31, 15, 70, 0.26);
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-xl: 36px;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: #f5f4fb;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: #f5f4fb;
  color: var(--text);
}

body.modal-open {
  overflow: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.app-icon {
  flex: 0 0 auto;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 7px;
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  line-height: 1.2;
}

.eyebrow--light {
  color: #f5d978;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 19px;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 750;
  transition: transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease, background 160ms ease;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.button:active:not(:disabled) {
  transform: translateY(0);
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.button--primary {
  background: linear-gradient(135deg, var(--primary), #8751e4);
  color: #fff;
  box-shadow: 0 10px 24px rgba(100, 65, 216, 0.24);
}

.button--secondary {
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
}

.button--gold {
  background: linear-gradient(135deg, #f0ce6d, #d8a934);
  color: #392408;
  box-shadow: 0 12px 28px rgba(215, 166, 48, 0.28);
}

.button--danger-soft {
  background: var(--danger-soft);
  color: var(--danger);
}

.button--block {
  width: 100%;
}

.button--small {
  min-height: 39px;
  padding: 0 14px;
  border-radius: 11px;
  font-size: 0.86rem;
}

.icon-button {
  display: inline-flex;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: transparent;
  color: currentColor;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease, opacity 160ms ease;
}

.icon-button:hover:not(:disabled) {
  background: rgba(100, 65, 216, 0.1);
}

.icon-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.icon-button--soft {
  background: #f0edf9;
  color: var(--primary-dark);
}

.icon-button--danger {
  background: var(--danger-soft);
  color: var(--danger);
}

.inline-actions {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.app-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.app-logo img {
  flex: 0 0 auto;
  object-fit: contain;
}

.app-logo__text {
  display: flex;
  flex-direction: column;
}

.app-logo__text strong {
  font-size: 1.03rem;
  line-height: 1.15;
}

.app-logo__text span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.74rem;
}

.app-logo--light .app-logo__text strong {
  color: #fff;
}

.app-logo--light .app-logo__text span {
  color: rgba(255, 255, 255, 0.66);
}

.loading-spinner {
  display: flex;
  min-height: 180px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--muted);
  font-weight: 650;
}

.loading-spinner--compact {
  min-height: 0;
  gap: 8px;
}

.loading-spinner__circle {
  width: 27px;
  height: 27px;
  border: 3px solid rgba(100, 65, 216, 0.18);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.loading-spinner--compact .loading-spinner__circle {
  width: 19px;
  height: 19px;
  border-width: 2px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.toast-host {
  position: fixed;
  z-index: 2000;
  top: max(16px, env(safe-area-inset-top));
  right: 16px;
  display: grid;
  width: min(390px, calc(100vw - 32px));
  gap: 10px;
  pointer-events: none;
}

.toast-message {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 11px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: #2d2542;
  box-shadow: var(--shadow-md);
  color: #fff;
  cursor: pointer;
  pointer-events: auto;
  text-align: left;
}

.toast-message--success { background: #187956; }
.toast-message--error { background: #a93442; }
.toast-message--info { background: #4a347e; }

.toast-enter-active,
.toast-leave-active { transition: opacity 180ms ease, transform 180ms ease; }
.toast-enter-from,
.toast-leave-to { opacity: 0; transform: translateY(-10px); }

.modal-backdrop {
  position: fixed;
  z-index: 1500;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  background: rgba(22, 14, 41, 0.68);
  backdrop-filter: blur(10px);
  overflow-y: auto;
}

.modal-card {
  width: min(100%, 560px);
  max-height: calc(100dvh - 36px);
  overflow: hidden;
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--shadow-lg);
  animation: modalUp 220ms ease-out;
}

.modal-card--wide {
  width: min(100%, 760px);
}

@keyframes modalUp {
  from { opacity: 0; transform: translateY(24px) scale(0.98); }
}

.modal-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 21px 15px;
  border-bottom: 1px solid var(--border);
}

.modal-card__header h2 {
  margin: 0;
  font-size: 1.16rem;
}

.modal-card__body {
  max-height: calc(100dvh - 180px);
  overflow-y: auto;
  padding: 21px;
}

.modal-card__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 15px 21px max(15px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--border);
  background: #fbfafe;
}

/* User login */
.user-login-page {
  position: relative;
  display: flex;
  min-height: 100dvh;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 28px 18px 64px;
  background:
    radial-gradient(circle at 80% 12%, rgba(247, 205, 90, 0.25), transparent 24%),
    linear-gradient(150deg, #2f135b 0%, #5c31bd 50%, #9a4ec7 100%);
}

.user-login-page__glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
  pointer-events: none;
}

.user-login-page__glow--one {
  width: 260px;
  height: 260px;
  top: -80px;
  left: -100px;
  background: rgba(141, 106, 245, 0.25);
}

.user-login-page__glow--two {
  width: 220px;
  height: 220px;
  right: -90px;
  bottom: 4%;
  background: rgba(255, 212, 96, 0.14);
}

.user-login-card {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  padding: 28px 24px 24px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 32px;
  background: rgba(37, 19, 77, 0.54);
  box-shadow: 0 30px 80px rgba(24, 8, 53, 0.36);
  backdrop-filter: blur(20px);
}

.user-login-card__brand {
  text-align: center;
}

.user-login-card__brand .app-logo {
  display: flex;
  justify-content: center;
}

.user-login-card__badge {
  display: inline-flex;
  margin-top: 10px;
  padding: 6px 11px;
  border: 1px solid rgba(247, 215, 111, 0.34);
  border-radius: 999px;
  background: rgba(247, 215, 111, 0.1);
  color: #f4d976;
  font-size: 0.67rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.user-login-card h1 {
  margin: 12px 0 7px;
  color: #fff;
  font-size: clamp(2rem, 8vw, 2.65rem);
  line-height: 1;
}

.user-login-card__brand p {
  max-width: 310px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.92rem;
  line-height: 1.55;
}

.pin-form {
  margin-top: 28px;
}

.pin-form > label {
  display: block;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.83rem;
  font-weight: 700;
}

.pin-boxes {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 18px;
  cursor: text;
}

.pin-box {
  display: grid;
  aspect-ratio: 1 / 1;
  max-height: 68px;
  place-items: center;
  border: 1.5px solid rgba(255, 255, 255, 0.23);
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.09);
  color: #f7dc7c;
  font-size: 2rem;
  transition: border 160ms ease, background 160ms ease, transform 160ms ease;
}

.pin-box--filled {
  border-color: rgba(246, 210, 93, 0.65);
  background: rgba(246, 210, 93, 0.1);
}

.pin-box--active {
  transform: translateY(-2px);
  border-color: #f2d56f;
}

.pin-boxes__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.user-login-card__security {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.76rem;
}


/* User app */
.user-app-shell {
  min-height: 100dvh;
  background: var(--surface-soft);
}

.user-app-content {
  min-height: 100dvh;
  padding-bottom: calc(86px + env(safe-area-inset-bottom));
}

.user-bottom-nav {
  position: fixed;
  z-index: 100;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 8px 10px max(8px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(225, 220, 238, 0.9);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 -12px 35px rgba(48, 31, 86, 0.08);
  backdrop-filter: blur(18px);
}

.user-bottom-nav__item {
  display: flex;
  min-height: 58px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-radius: 15px;
  color: #8a8496;
  font-size: 0.72rem;
  font-weight: 700;
  transition: color 160ms ease, background 160ms ease;
}

.user-bottom-nav__item.router-link-active {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.user-bottom-nav__icon {
  display: grid;
  place-items: center;
}

.user-home-page {
  min-height: 100dvh;
}

.user-hero {
  position: relative;
  overflow: hidden;
  padding: max(18px, env(safe-area-inset-top)) 18px 32px;
  border-radius: 0 0 34px 34px;
  background:
    radial-gradient(circle at 90% 10%, rgba(248, 214, 104, 0.3), transparent 28%),
    linear-gradient(145deg, #31155f, #6237c5 56%, #a653ca);
  color: #fff;
  box-shadow: 0 20px 45px rgba(69, 38, 145, 0.22);
}

.user-hero::after {
  position: absolute;
  width: 190px;
  height: 190px;
  right: -55px;
  bottom: -110px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  content: "";
}

.user-hero__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.user-hero__status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.7rem;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #56d99a;
  box-shadow: 0 0 0 4px rgba(86, 217, 154, 0.14);
}

.user-hero__copy {
  position: relative;
  z-index: 1;
  margin-top: 28px;
}

.user-hero__copy h1 {
  max-width: 430px;
  margin-bottom: 10px;
  font-size: clamp(1.8rem, 8vw, 2.4rem);
  line-height: 1.07;
}

.user-hero__copy p {
  max-width: 450px;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.91rem;
  line-height: 1.55;
}

.search-control {
  display: flex;
  min-height: 47px;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  color: #8a8497;
}

.search-control input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.search-control--hero {
  position: relative;
  z-index: 1;
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 13px 30px rgba(35, 12, 77, 0.16);
}

.user-section {
  padding: 24px 16px;
}

.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-size: 1.25rem;
}

.count-chip {
  display: inline-grid;
  min-width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 11px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 800;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.service-card {
  position: relative;
  display: flex;
  min-width: 0;
  overflow: hidden;
  flex-direction: column;
  border: 1px solid rgba(115, 88, 183, 0.13);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(252, 250, 255, 0.98));
  box-shadow:
    0 18px 44px rgba(54, 33, 104, 0.11),
    0 3px 10px rgba(54, 33, 104, 0.05);
  isolation: isolate;
  transition:
    transform 190ms ease,
    box-shadow 190ms ease,
    border-color 190ms ease;
}

.service-card::before {
  position: absolute;
  z-index: 2;
  top: 0;
  right: 14%;
  left: 14%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.95), transparent);
  content: "";
  pointer-events: none;
}

.service-card:hover {
  border-color: rgba(100, 65, 216, 0.25);
  box-shadow:
    0 24px 58px rgba(54, 33, 104, 0.16),
    0 5px 14px rgba(54, 33, 104, 0.07);
  transform: translateY(-4px);
}

.service-card__visual {
  position: relative;
  display: grid;
  min-height: 142px;
  overflow: hidden;
  place-items: center;
  border-bottom: 1px solid rgba(115, 88, 183, 0.09);
  background:
    radial-gradient(circle at 15% 18%, rgba(137, 90, 231, 0.20), transparent 34%),
    radial-gradient(circle at 92% 85%, rgba(232, 190, 76, 0.23), transparent 33%),
    linear-gradient(145deg, #f5f0ff 0%, #fffaf0 100%);
}

.service-card:nth-child(4n + 2) .service-card__visual {
  background:
    radial-gradient(circle at 12% 20%, rgba(63, 145, 255, 0.20), transparent 34%),
    radial-gradient(circle at 92% 82%, rgba(120, 84, 230, 0.18), transparent 34%),
    linear-gradient(145deg, #eef7ff 0%, #f8f4ff 100%);
}

.service-card:nth-child(4n + 3) .service-card__visual {
  background:
    radial-gradient(circle at 14% 18%, rgba(255, 113, 143, 0.18), transparent 34%),
    radial-gradient(circle at 92% 82%, rgba(241, 185, 63, 0.20), transparent 34%),
    linear-gradient(145deg, #fff1f5 0%, #fff9e9 100%);
}

.service-card:nth-child(4n + 4) .service-card__visual {
  background:
    radial-gradient(circle at 14% 18%, rgba(42, 189, 153, 0.18), transparent 34%),
    radial-gradient(circle at 92% 82%, rgba(84, 113, 232, 0.18), transparent 34%),
    linear-gradient(145deg, #edfff9 0%, #f1f4ff 100%);
}

.service-card__visual::after {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.22) 1px, transparent 1px);
  background-size: 22px 22px;
  content: "";
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.55), transparent 90%);
  opacity: 0.46;
  pointer-events: none;
}

.service-card__orb {
  position: absolute;
  z-index: 0;
  border-radius: 999px;
  filter: blur(1px);
  opacity: 0.72;
  pointer-events: none;
}

.service-card__orb--one {
  top: -28px;
  left: -22px;
  width: 84px;
  height: 84px;
  border: 18px solid rgba(255, 255, 255, 0.42);
}

.service-card__orb--two {
  right: -18px;
  bottom: -35px;
  width: 92px;
  height: 92px;
  background: rgba(255, 255, 255, 0.32);
}

.service-card__vip {
  position: absolute;
  z-index: 3;
  top: 12px;
  right: 12px;
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  gap: 6px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 7px 18px rgba(61, 39, 112, 0.09);
  color: #4c337c;
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  backdrop-filter: blur(10px);
}

.service-card__vip > span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #2ac98d;
  box-shadow: 0 0 0 3px rgba(42, 201, 141, 0.14);
}

.service-card__logo,
.credential-modal__logo,
.admin-service-card__logo,
.logo-upload__preview {
  display: grid;
  overflow: hidden;
  place-items: center;
  border: 1px solid #ece8f4;
  background: #fff;
  color: var(--primary);
}

.service-card__logo {
  position: relative;
  z-index: 2;
  width: 96px;
  height: 96px;
  border: 1px solid rgba(255, 255, 255, 0.94);
  border-radius: 29px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 18px 38px rgba(46, 28, 92, 0.18),
    inset 0 0 0 1px rgba(102, 70, 187, 0.06);
  transition: transform 190ms ease, box-shadow 190ms ease;
}

.service-card:hover .service-card__logo {
  box-shadow:
    0 22px 44px rgba(46, 28, 92, 0.23),
    inset 0 0 0 1px rgba(102, 70, 187, 0.08);
  transform: scale(1.035) rotate(-1deg);
}

.service-card__logo img {
  width: 84%;
  height: 84%;
  object-fit: contain;
}

.credential-modal__logo img,
.admin-service-card__logo img,
.logo-upload__preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.service-card__content {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  padding: 18px 15px 12px;
  text-align: center;
}

.service-card__content h3 {
  margin-bottom: 7px;
  color: #241c38;
  font-size: 1.02rem;
  font-weight: 850;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.service-card__content p {
  display: -webkit-box;
  min-height: 3.9em;
  margin-bottom: 0;
  overflow: hidden;
  color: #7d758e;
  font-size: 0.75rem;
  line-height: 1.48;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.service-card__footer {
  padding: 0 13px 13px;
}

.service-card__action {
  display: flex;
  width: 100%;
  min-height: 47px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 8px 0 16px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, #5c3dcc 0%, #7b4fe2 58%, #9062ee 100%);
  box-shadow: 0 12px 25px rgba(100, 65, 216, 0.25);
  color: #fff;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 820;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    opacity 160ms ease;
}

.service-card__action:hover:not(:disabled) {
  box-shadow: 0 15px 30px rgba(100, 65, 216, 0.34);
  transform: translateY(-1px);
}

.service-card__action:active:not(:disabled) {
  transform: translateY(0);
}

.service-card__action:disabled {
  cursor: not-allowed;
  opacity: 0.63;
}

.service-card__action-icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.23);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.empty-state {
  display: flex;
  min-height: 260px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  border: 1px dashed #dcd6ea;
  border-radius: 22px;
  background: #fff;
  color: var(--muted);
  text-align: center;
}

.empty-state h2,
.empty-state h3 {
  margin: 14px 0 7px;
  color: var(--text);
}

.empty-state p {
  max-width: 400px;
  margin-bottom: 0;
  line-height: 1.55;
}

.empty-state--small {
  min-height: 150px;
}

/* Credential modal */
.credential-modal__service {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.credential-modal__logo {
  width: 70px;
  height: 70px;
  flex: 0 0 auto;
  border-radius: 20px;
}

.credential-modal__service h3 {
  margin: 0 0 4px;
  font-size: 1.25rem;
}

.credential-modal__service p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.credential-field {
  margin-bottom: 13px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: #fbfafe;
}

.credential-field > span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
}

.credential-field__value {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.credential-field__value strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.credential-field__secret {
  letter-spacing: 0.04em;
}

.credential-field--compact {
  margin-bottom: 0;
}

.credential-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.credential-modal__notice,
.info-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 17px;
  padding: 13px 14px;
  border-radius: 14px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 0.78rem;
  line-height: 1.5;
}

.credential-modal__notice span,
.info-banner p {
  margin: 0;
}

.credential-modal__actions {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 10px;
  margin-top: 18px;
}

/* User detail pages */
.user-page {
  min-height: 100dvh;
  padding: max(22px, env(safe-area-inset-top)) 16px 28px;
}

.user-page--soft {
  background:
    radial-gradient(circle at 90% 4%, rgba(118, 78, 218, 0.13), transparent 20%),
    var(--surface-soft);
}

.mobile-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 22px;
}

.mobile-page-header h1 {
  margin: 0;
  font-size: 1.75rem;
}

.header-icon-chip {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 15px;
  background: var(--primary-light);
  color: var(--primary-dark);
}

.subscription-card {
  position: relative;
  overflow: hidden;
  padding: 23px;
  border-radius: 26px;
  background: linear-gradient(145deg, #351666, #6940cd 62%, #9b51c5);
  box-shadow: 0 20px 46px rgba(72, 39, 151, 0.24);
  color: #fff;
}

.subscription-card__halo {
  position: absolute;
  width: 190px;
  height: 190px;
  top: -100px;
  right: -60px;
  border-radius: 50%;
  background: rgba(242, 209, 103, 0.26);
  filter: blur(2px);
}

.subscription-card__top,
.subscription-card__remaining {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.subscription-card__label {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.subscription-card__code {
  position: relative;
  display: block;
  margin: 24px 0 5px;
  color: #f6da78;
  font-size: clamp(2.5rem, 15vw, 4.2rem);
  letter-spacing: 0.16em;
  line-height: 1;
}

.subscription-card > p {
  position: relative;
  color: rgba(255, 255, 255, 0.66);
  font-size: 0.82rem;
}

.subscription-card__remaining {
  margin-top: 25px;
}

.subscription-card__remaining span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.78rem;
}

.subscription-card__remaining strong {
  font-size: 1.05rem;
}

.progress-track {
  position: relative;
  overflow: hidden;
  height: 8px;
  margin-top: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.progress-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #f2d267, #fff0af);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.69rem;
  font-weight: 800;
  white-space: nowrap;
}

.status-pill--success {
  background: var(--success-soft);
  color: var(--success);
}

.status-pill--gold {
  background: var(--gold-light);
  color: #936a0c;
}

.status-pill--muted {
  background: #eeecf3;
  color: #716b7f;
}

.status-pill--danger {
  background: var(--danger-soft);
  color: var(--danger);
}

.status-pill--button {
  border: 0;
  cursor: pointer;
}

.subscription-card .status-pill--success,
.subscription-card .status-pill--gold {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.13);
  color: #f7dc7c;
}

.detail-card-list,
.profile-details {
  display: grid;
  gap: 11px;
  margin-top: 18px;
}

.detail-card,
.profile-details article {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: 17px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.detail-card__icon {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 13px;
  background: var(--primary-light);
  color: var(--primary-dark);
}

.detail-card div:last-child,
.profile-details article > div:first-child {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 3px;
}

.detail-card span,
.profile-details span {
  color: var(--muted);
  font-size: 0.76rem;
}

.detail-card strong,
.profile-details strong {
  font-size: 0.92rem;
}

.profile-card {
  padding: 26px 20px;
  border: 1px solid var(--border);
  border-radius: 25px;
  background: #fff;
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.profile-avatar {
  display: grid;
  width: 84px;
  height: 84px;
  margin: 0 auto 15px;
  place-items: center;
  border: 5px solid #fff;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #b158d1);
  box-shadow: 0 10px 28px rgba(95, 53, 184, 0.28);
  color: #fff;
  font-size: 1.7rem;
  font-weight: 850;
}

.profile-card h2 {
  margin: 3px 0 7px;
}

.profile-card p {
  color: var(--muted);
  font-size: 0.85rem;
}

.profile-details article {
  justify-content: space-between;
}

.profile-details article > .app-icon {
  color: var(--primary);
}

.profile-logout {
  margin-top: 18px;
}

/* Forms */
.form-field {
  display: grid;
  gap: 7px;
}

.form-field > span,
.logo-upload__label {
  color: #4f495d;
  font-size: 0.8rem;
  font-weight: 750;
}

.form-field input,
.form-field textarea,
.form-field select,
.filter-select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 13px;
  outline: none;
  background: #fff;
  color: var(--text);
  transition: border 160ms ease, box-shadow 160ms ease;
}

.form-field input,
.form-field select,
.filter-select {
  min-height: 46px;
  padding: 0 13px;
}

.form-field textarea {
  min-height: 90px;
  padding: 12px 13px;
  resize: vertical;
}

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus,
.filter-select:focus {
  border-color: rgba(100, 65, 216, 0.6);
  box-shadow: 0 0 0 4px rgba(100, 65, 216, 0.09);
}

.form-field small,
.logo-upload small {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.4;
}

.input-with-icon {
  display: flex;
  min-height: 48px;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: #fff;
  color: #8b8498;
}

.input-with-icon:focus-within {
  border-color: rgba(100, 65, 216, 0.6);
  box-shadow: 0 0 0 4px rgba(100, 65, 216, 0.09);
}

.input-with-icon input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.input-with-icon--trailing {
  padding-left: 0;
}

.input-with-icon--trailing input {
  padding-left: 13px;
}

.input-icon-button {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.modal-form {
  display: grid;
  gap: 15px;
}

.switch-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 13px 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fbfafe;
}

.switch-field > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.switch-field strong {
  font-size: 0.86rem;
}

.switch-field span {
  color: var(--muted);
  font-size: 0.73rem;
}

.switch-field input {
  width: 42px;
  height: 23px;
  accent-color: var(--primary);
}

/* Admin login */
.admin-login-page {
  display: grid;
  min-height: 100dvh;
  grid-template-columns: minmax(0, 1.1fr) minmax(420px, 0.9fr);
  background: #fff;
}

.admin-login-visual {
  position: relative;
  display: flex;
  overflow: hidden;
  flex-direction: column;
  justify-content: space-between;
  padding: 52px clamp(40px, 6vw, 90px);
  background:
    radial-gradient(circle at 75% 12%, rgba(242, 207, 92, 0.28), transparent 24%),
    linear-gradient(145deg, #2d1254, #5b31ba 58%, #9a4cc4);
  color: #fff;
}

.admin-login-visual__orb {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.admin-login-visual__orb--one {
  width: 410px;
  height: 410px;
  right: -200px;
  bottom: -130px;
}

.admin-login-visual__orb--two {
  width: 220px;
  height: 220px;
  top: 28%;
  left: -120px;
}

.admin-login-visual__copy {
  position: relative;
  z-index: 1;
  max-width: 680px;
}

.admin-login-visual__copy h1 {
  margin-bottom: 16px;
  font-size: clamp(2.5rem, 4.5vw, 4.7rem);
  line-height: 1.03;
}

.admin-login-visual__copy p {
  max-width: 540px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 1rem;
  line-height: 1.7;
}

.admin-login-visual__features {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-login-visual__features span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.79rem;
}

.admin-login-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 38px;
}

.admin-login-form {
  display: grid;
  width: min(100%, 420px);
  gap: 17px;
}

.admin-login-form h2 {
  margin: -2px 0 -10px;
  font-size: 2rem;
}

.admin-login-form > p {
  margin-bottom: 5px;
  color: var(--muted);
}

.admin-login-form__mobile-logo {
  display: none;
}

.admin-login-form__back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
}

/* Admin layout */
.admin-shell {
  min-height: 100dvh;
  background: #f5f4fa;
}

.admin-sidebar {
  position: fixed;
  z-index: 500;
  top: 0;
  bottom: 0;
  left: 0;
  display: flex;
  width: 268px;
  flex-direction: column;
  padding: 22px 16px;
  background:
    radial-gradient(circle at 80% 0%, rgba(236, 196, 75, 0.16), transparent 23%),
    linear-gradient(180deg, #29114e, #45208b);
  color: #fff;
  box-shadow: 12px 0 38px rgba(33, 14, 68, 0.14);
}

.admin-sidebar__brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 5px 24px;
}

.admin-sidebar__close {
  display: none;
  color: #fff;
}

.admin-sidebar__nav {
  display: grid;
  gap: 7px;
}

.admin-sidebar__link,
.admin-sidebar__logout {
  display: flex;
  min-height: 48px;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  border-radius: 13px;
  background: transparent;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.87rem;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  transition: background 160ms ease, color 160ms ease;
}

.admin-sidebar__link:hover,
.admin-sidebar__link.router-link-active,
.admin-sidebar__logout:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.admin-sidebar__link.router-link-active {
  box-shadow: inset 3px 0 0 #f0d16b;
}

.admin-sidebar__logout {
  width: 100%;
  margin-top: auto;
}

.admin-main {
  min-height: 100dvh;
  margin-left: 268px;
}

.admin-topbar {
  position: sticky;
  z-index: 100;
  top: 0;
  display: flex;
  min-height: 76px;
  align-items: center;
  padding: 0 30px;
  border-bottom: 1px solid rgba(225, 221, 236, 0.88);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px);
}

.admin-menu-button {
  display: none;
}

.admin-topbar__title {
  display: flex;
  flex-direction: column;
}

.admin-topbar__title strong {
  font-size: 0.95rem;
}

.admin-topbar__title span,
.admin-topbar__account span {
  color: var(--muted);
  font-size: 0.7rem;
}

.admin-topbar__account {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.admin-topbar__account > div:last-child {
  display: flex;
  flex-direction: column;
}

.admin-topbar__account strong {
  font-size: 0.8rem;
}

.admin-avatar {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #9d53d4);
  color: #fff;
  font-weight: 850;
}

.admin-content {
  padding: 28px 30px 50px;
}

.admin-view {
  width: min(100%, 1440px);
  margin: 0 auto;
}

.admin-page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 25px;
}

.admin-page-heading h1 {
  margin: 0 0 5px;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.admin-page-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.admin-page-heading--with-back {
  align-items: center;
  justify-content: flex-start;
}

.admin-page-heading__main {
  flex: 1;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.metric-card {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.metric-card::after {
  position: absolute;
  width: 90px;
  height: 90px;
  top: -42px;
  right: -30px;
  border-radius: 50%;
  background: currentColor;
  content: "";
  opacity: 0.07;
}

.metric-card__icon {
  display: grid;
  width: 45px;
  height: 45px;
  margin-bottom: 18px;
  place-items: center;
  border-radius: 14px;
  background: currentColor;
  color: inherit;
}

.metric-card__icon .app-icon {
  color: #fff;
}

.metric-card > span,
.metric-card > small {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
}

.metric-card > strong {
  display: block;
  margin: 4px 0;
  color: var(--text);
  font-size: 2rem;
}

.metric-card--purple { color: #7750dc; }
.metric-card--blue { color: #3f82d5; }
.metric-card--gold { color: #c59527; }
.metric-card--green { color: #23a471; }

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.admin-panel {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.admin-panel--table {
  padding: 0;
  overflow: hidden;
}

.admin-panel__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 17px;
}

.admin-panel--table > .admin-panel__heading {
  padding: 20px 20px 0;
}

.admin-panel__heading h2 {
  margin: 0;
  font-size: 1.12rem;
}

.admin-panel__heading > .app-icon {
  color: var(--primary);
}

.stat-list {
  display: grid;
  gap: 4px;
}

.stat-list > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 0;
  border-bottom: 1px solid #eeeaf4;
}

.stat-list > div:last-child {
  border-bottom: 0;
}

.stat-list span {
  color: var(--muted);
  font-size: 0.82rem;
}

.activity-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.activity-summary > div {
  display: flex;
  min-height: 110px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 13px;
  border-radius: 15px;
  background: #f7f5fc;
  text-align: center;
}

.activity-summary strong {
  color: var(--primary-dark);
  font-size: 1.55rem;
}

.activity-summary span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.7rem;
}

.activity-list {
  display: grid;
}

.activity-row {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) minmax(100px, 0.6fr) auto;
  align-items: center;
  gap: 13px;
  padding: 13px 20px;
  border-top: 1px solid #eeeaf4;
}

.activity-row__icon,
.table-icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 12px;
  background: var(--primary-light);
  color: var(--primary-dark);
}

.activity-row__main {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
}

.activity-row__main strong {
  font-size: 0.84rem;
}

.activity-row__main span,
.activity-row__label,
.activity-row time {
  color: var(--muted);
  font-size: 0.72rem;
}

/* Admin services */
.admin-service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 17px;
}

.admin-service-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.admin-service-card__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.admin-service-card__logo {
  width: 67px;
  height: 67px;
  border-radius: 18px;
}

.admin-service-card__content {
  flex: 1;
  margin: 18px 0;
}

.admin-service-card__content h2 {
  margin-bottom: 7px;
  font-size: 1.15rem;
}

.admin-service-card__content p {
  display: -webkit-box;
  margin-bottom: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.admin-service-card__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 9px;
  margin-bottom: 15px;
}

.admin-service-card__stats > div {
  padding: 10px;
  border-radius: 13px;
  background: #f7f5fc;
}

.admin-service-card__stats strong,
.admin-service-card__stats span {
  display: block;
}

.admin-service-card__stats strong {
  font-size: 1.1rem;
}

.admin-service-card__stats span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.67rem;
}

.admin-service-card__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-service-card__actions .button {
  flex: 1;
}

.admin-empty-state {
  min-height: 380px;
}

.logo-upload {
  display: grid;
  gap: 9px;
}

.logo-upload__content {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px;
  border: 1px dashed #d8d2e5;
  border-radius: 15px;
  background: #fbfafe;
}

.logo-upload__preview {
  width: 82px;
  height: 82px;
  flex: 0 0 auto;
  border-radius: 17px;
}

.logo-upload__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.logo-upload__controls small {
  width: 100%;
}

/* Tables */
.responsive-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.admin-table th,
.admin-table td {
  padding: 13px 16px;
  border-bottom: 1px solid #eeeaf4;
  text-align: left;
  vertical-align: middle;
}

.admin-table th {
  background: #faf9fd;
  color: #6f687d;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.admin-table tbody tr:last-child td {
  border-bottom: 0;
}

.admin-table tbody tr:hover {
  background: #fcfbfe;
}

.admin-table__actions {
  width: 110px;
  text-align: right !important;
  white-space: nowrap;
}

.table-primary-cell {
  display: flex;
  min-width: 200px;
  align-items: center;
  gap: 10px;
}

.table-primary-cell > div:last-child {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
}

.table-primary-cell span {
  color: var(--muted);
  font-size: 0.71rem;
}

.code-mask {
  display: inline-block;
  min-width: 62px;
  padding: 7px 9px;
  border-radius: 9px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: 0.1em;
  text-align: center;
}

.admin-filter-bar {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 210px;
  gap: 12px;
  margin-bottom: 17px;
}

.info-banner--compact {
  margin-top: 0;
}

.created-code-card {
  text-align: center;
}

.created-code-card > strong {
  display: block;
  margin: 8px 0;
  color: var(--primary-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: clamp(3rem, 15vw, 4.5rem);
  letter-spacing: 0.15em;
}

.created-code-card > p {
  color: var(--muted);
}

/* Not found */
.not-found-page {
  display: flex;
  min-height: 100dvh;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  background: var(--surface-soft);
  text-align: center;
}

.not-found-page__code {
  margin-top: 20px;
  color: var(--primary);
  font-size: 5rem;
  font-weight: 900;
  line-height: 1;
}

.not-found-page h1 {
  margin: 10px 0;
}

.not-found-page p {
  margin-bottom: 22px;
  color: var(--muted);
}

.admin-sidebar-backdrop {
  display: none;
}

@media (min-width: 680px) {
  .modal-backdrop {
    align-items: center;
  }

  .user-app-shell {
    width: min(100%, 720px);
    margin: 0 auto;
    box-shadow: 0 0 0 1px rgba(225, 220, 238, 0.75);
  }

  .user-bottom-nav {
    right: 50%;
    left: auto;
    width: min(100%, 720px);
    transform: translateX(50%);
  }

  .user-section {
    padding-right: 22px;
    padding-left: 22px;
  }

  .service-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-service-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .admin-login-page {
    grid-template-columns: 1fr;
  }

  .admin-login-visual {
    display: none;
  }

  .admin-login-form-wrap {
    min-height: 100dvh;
    padding: 28px 20px;
    background:
      radial-gradient(circle at 85% 5%, rgba(111, 73, 218, 0.13), transparent 23%),
      #f8f7fc;
  }

  .admin-login-form__mobile-logo {
    display: block;
    margin-bottom: 8px;
  }

  .admin-sidebar {
    width: 276px;
    transform: translateX(-105%);
    transition: transform 220ms ease;
  }

  .admin-sidebar--open {
    transform: translateX(0);
  }

  .admin-sidebar__close {
    display: inline-flex;
  }

  .admin-sidebar-backdrop {
    position: fixed;
    z-index: 450;
    inset: 0;
    display: block;
    background: rgba(24, 14, 43, 0.56);
    backdrop-filter: blur(3px);
  }

  .admin-main {
    margin-left: 0;
  }

  .admin-menu-button {
    display: inline-flex;
    margin-right: 10px;
  }

  .admin-content {
    padding: 22px 18px 40px;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .admin-topbar {
    min-height: 66px;
    padding: 0 14px;
  }

  .admin-topbar__account > div:last-child {
    display: none;
  }

  .admin-page-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-page-heading > .button {
    align-self: flex-start;
  }

  .admin-page-heading--with-back {
    display: grid;
    grid-template-columns: auto 1fr;
  }

  .admin-page-heading--with-back > .button {
    grid-column: 1 / -1;
  }

  .metric-grid,
  .admin-service-grid {
    grid-template-columns: 1fr;
  }

  .admin-filter-bar {
    grid-template-columns: 1fr;
  }

  .activity-row {
    grid-template-columns: auto 1fr;
  }

  .activity-row__label,
  .activity-row time {
    grid-column: 2;
  }

  .responsive-table-wrap {
    overflow: visible;
  }

  .admin-table,
  .admin-table thead,
  .admin-table tbody,
  .admin-table tr,
  .admin-table th,
  .admin-table td {
    display: block;
  }

  .admin-table thead {
    display: none;
  }

  .admin-table tbody {
    display: grid;
    gap: 12px;
    padding: 13px;
  }

  .admin-table tr {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 15px;
    background: #fff;
  }

  .admin-table td {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 10px 12px;
    text-align: right;
  }

  .admin-table td::before {
    flex: 0 0 auto;
    color: var(--muted);
    content: attr(data-label);
    font-size: 0.67rem;
    font-weight: 750;
    text-transform: uppercase;
  }

  .admin-table__actions {
    width: auto;
    text-align: right !important;
  }

  .table-primary-cell {
    min-width: 0;
  }
}

@media (max-width: 520px) {
  .service-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
  }

  .service-card {
    border-radius: 24px;
  }

  .service-card__visual {
    min-height: 132px;
  }

  .service-card__logo {
    width: 88px;
    height: 88px;
    border-radius: 26px;
  }

  .service-card__content {
    padding-right: 12px;
    padding-left: 12px;
  }

  .service-card__action {
    padding-left: 13px;
    font-size: 0.74rem;
  }


  .credential-meta-grid,
  .credential-modal__actions,
  .form-row {
    grid-template-columns: 1fr;
  }

  .modal-card__footer {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .modal-card__footer .button {
    width: 100%;
  }

  .activity-summary {
    grid-template-columns: 1fr;
  }

  .activity-summary > div {
    min-height: 80px;
  }

  .logo-upload__content {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 390px) {
  .user-login-card {
    padding-right: 18px;
    padding-left: 18px;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

}
