:root {
  color-scheme: dark;
  --bg: #07080d;
  --bg-soft: #0b0d14;
  --surface: rgba(17, 19, 29, 0.9);
  --surface-strong: #131621;
  --surface-raised: #181b28;
  --line: rgba(225, 228, 255, 0.11);
  --line-strong: rgba(175, 153, 255, 0.28);
  --text: #f7f7fb;
  --text-soft: #c2c5d2;
  --muted: #878c9f;
  --violet: #9275ff;
  --violet-strong: #7155ee;
  --cyan: #68dbe8;
  --gold: #f2d98d;
  --success: #72e2b3;
  --warning: #f0c679;
  --danger: #ff8f9d;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --max-width: 1180px;
  --ease: cubic-bezier(.2, .75, .25, 1);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 300px;
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(circle at 18% -15%, rgba(113, 85, 238, 0.19), transparent 34%),
    radial-gradient(circle at 94% 34%, rgba(104, 219, 232, 0.08), transparent 29%),
    linear-gradient(180deg, #090a11 0%, var(--bg) 58%, #08090e 100%);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

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

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

a {
  color: var(--cyan);
  text-underline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 10px;
  color: #fff;
  background: var(--violet-strong);
  transform: translateY(-180%);
  transition: transform .2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.ambient,
.grid-backdrop {
  position: fixed;
  z-index: -2;
  pointer-events: none;
}

.ambient {
  width: 410px;
  height: 410px;
  border-radius: 50%;
  filter: blur(110px);
  opacity: .12;
}

.ambient-one {
  top: 12%;
  left: -220px;
  background: var(--cyan);
}

.ambient-two {
  right: -230px;
  bottom: 8%;
  background: var(--violet);
}

.grid-backdrop {
  inset: 0;
  z-index: -3;
  opacity: .19;
  background-image:
    linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .018) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 92%);
}

.site-header,
.security-banner,
.view-tabs,
.page-shell,
.site-footer {
  width: min(calc(100% - 32px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 92px;
  padding-top: env(safe-area-inset-top);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
}

.brand img {
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(113, 85, 238, .28);
}

.brand span,
.user-summary {
  display: grid;
}

.brand strong {
  font-size: 15px;
  letter-spacing: .02em;
}

.brand small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .16em;
}

.session-summary {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 13px;
}

.user-summary {
  justify-items: end;
  gap: 2px;
}

.role-badge,
.soft-badge,
.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 25px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text-soft);
  background: rgba(255, 255, 255, .035);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.role-badge {
  min-height: 21px;
  padding-block: 4px;
  color: #ded6ff;
  border-color: rgba(146, 117, 255, .24);
  background: rgba(146, 117, 255, .09);
}

.user-name {
  max-width: 190px;
  overflow: hidden;
  color: var(--text-soft);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.security-banner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 13px;
  padding: 14px 17px;
  border: 1px solid rgba(240, 198, 121, .18);
  border-radius: var(--radius-md);
  color: #f4e4bd;
  background:
    linear-gradient(110deg, rgba(240, 198, 121, .075), transparent 58%),
    rgba(19, 17, 18, .88);
}

.security-mark,
.state-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(240, 198, 121, .28);
  border-radius: 10px;
  color: var(--gold);
  background: rgba(240, 198, 121, .09);
  font-weight: 900;
}

.security-banner strong {
  display: block;
  font-size: 12px;
}

.security-banner p {
  margin: 3px 0 0;
  color: #bcb6a9;
  font-size: 11px;
}

#site-host {
  color: var(--gold);
  font-weight: 750;
}

.view-tabs {
  display: flex;
  gap: 6px;
  margin-top: 18px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(15, 17, 25, .82);
  box-shadow: 0 15px 50px rgba(0, 0, 0, .18);
}

.view-tab {
  min-height: 42px;
  padding: 0 22px;
  border: 0;
  border-radius: 11px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
  font-weight: 800;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}

.view-tab.is-active {
  color: #fff;
  background: linear-gradient(135deg, rgba(146, 117, 255, .34), rgba(75, 57, 169, .3));
  box-shadow: inset 0 0 0 1px rgba(190, 178, 255, .13);
}

.page-shell {
  padding: 25px 0 48px;
}

.view {
  animation: view-in .42s var(--ease) both;
}

.hero,
.admin-hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(176, 157, 255, .2);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(circle at 84% 12%, rgba(113, 85, 238, .28), transparent 28%),
    radial-gradient(circle at 5% 110%, rgba(104, 219, 232, .13), transparent 38%),
    linear-gradient(135deg, rgba(29, 25, 49, .96), rgba(12, 14, 22, .98) 55%, rgba(10, 12, 18, .99));
  box-shadow: var(--shadow);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(290px, .7fr);
  align-items: end;
  gap: 40px;
  min-height: 330px;
  padding: 50px;
}

.hero::after,
.admin-hero::after {
  position: absolute;
  right: -130px;
  bottom: -190px;
  width: 430px;
  height: 430px;
  border: 1px solid rgba(174, 156, 255, .11);
  border-radius: 50%;
  box-shadow:
    0 0 0 42px rgba(174, 156, 255, .025),
    0 0 0 88px rgba(104, 219, 232, .018);
  content: "";
  pointer-events: none;
}

.hero-copy,
.step-rail,
.admin-hero > * {
  position: relative;
  z-index: 1;
}

.eyebrow {
  color: #b9aaff;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .15em;
}

h1,
h2,
p {
  text-wrap: balance;
}

h1,
h2 {
  margin: 0;
  line-height: 1.06;
  letter-spacing: -.035em;
}

h1 {
  max-width: 690px;
  margin-top: 14px;
  font-size: clamp(40px, 5.2vw, 68px);
}

h2 {
  font-size: clamp(22px, 2.2vw, 28px);
}

.hero-copy > p,
.admin-hero > p {
  max-width: 660px;
  margin: 18px 0 0;
  color: var(--text-soft);
  font-size: 15px;
  line-height: 1.7;
}

.step-rail {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.step-rail li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 10px 14px;
  border: 1px solid rgba(225, 228, 255, .09);
  border-radius: 15px;
  background: rgba(7, 8, 13, .38);
  backdrop-filter: blur(12px);
}

.step-rail span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  color: #dfd8ff;
  background: rgba(146, 117, 255, .13);
  font-size: 10px;
  font-weight: 900;
}

.step-rail strong {
  font-size: 12px;
}

.checkout-layout,
.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(340px, .78fr);
  gap: 18px;
  margin-top: 18px;
}

.panel,
.state-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .022), transparent 46%),
    var(--surface);
  box-shadow: 0 22px 60px rgba(0, 0, 0, .24);
  backdrop-filter: blur(18px);
}

.panel {
  padding: 24px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.panel-heading h2 {
  margin-top: 7px;
}

.plan-panel {
  grid-row: span 2;
}

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

.plan-option {
  position: relative;
  display: grid;
  min-height: 154px;
  padding: 17px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--text);
  text-align: left;
  background: rgba(10, 12, 19, .68);
  transition: border-color .2s ease, background .2s ease, transform .2s var(--ease), box-shadow .2s ease;
}

.plan-option::after {
  position: absolute;
  right: -18px;
  bottom: -31px;
  color: rgba(255, 255, 255, .025);
  font-size: 92px;
  font-weight: 900;
  line-height: 1;
  content: attr(data-index);
  pointer-events: none;
}

.plan-option:hover {
  transform: translateY(-2px);
  border-color: rgba(146, 117, 255, .28);
  background: rgba(20, 21, 34, .86);
}

.plan-option[aria-checked="true"] {
  border-color: rgba(146, 117, 255, .58);
  background:
    radial-gradient(circle at 100% 0%, rgba(146, 117, 255, .18), transparent 44%),
    rgba(22, 20, 38, .93);
  box-shadow: 0 15px 38px rgba(84, 60, 185, .17), inset 0 0 0 1px rgba(200, 190, 255, .07);
}

.plan-option-top {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 9px;
}

.plan-option h3 {
  margin: 0;
  font-size: 17px;
  letter-spacing: -.02em;
}

.plan-check {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: transparent;
  font-size: 11px;
}

.plan-option[aria-checked="true"] .plan-check {
  color: #fff;
  border-color: var(--violet);
  background: var(--violet-strong);
}

.plan-option p {
  position: relative;
  z-index: 1;
  margin: 9px 0 17px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.plan-amount {
  position: relative;
  z-index: 1;
  align-self: end;
  color: var(--gold);
  font-size: 18px;
  font-weight: 850;
}

.card-panel {
  min-height: 338px;
}

.bank-card {
  position: relative;
  display: grid;
  min-height: 206px;
  padding: 21px;
  overflow: hidden;
  border: 1px solid rgba(214, 205, 255, .18);
  border-radius: 22px;
  background:
    radial-gradient(circle at 80% 0%, rgba(146, 117, 255, .31), transparent 34%),
    radial-gradient(circle at 5% 115%, rgba(104, 219, 232, .18), transparent 42%),
    linear-gradient(140deg, #25203e, #111522 55%, #10131a);
  box-shadow: 0 20px 45px rgba(0, 0, 0, .32), inset 0 1px rgba(255, 255, 255, .08);
}

.bank-card::after {
  position: absolute;
  right: -52px;
  bottom: -72px;
  width: 190px;
  height: 190px;
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 50%;
  box-shadow: 0 0 0 29px rgba(255, 255, 255, .018);
  content: "";
}

.bank-card-top,
.bank-card-bottom {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.bank-card-top {
  align-self: start;
  color: #dcd8e9;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.card-number {
  position: relative;
  z-index: 1;
  align-self: center;
  width: 100%;
  padding: 11px 0;
  border: 0;
  color: #fff;
  text-align: left;
  background: transparent;
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 760;
  letter-spacing: .095em;
}

.bank-card-bottom {
  align-self: end;
}

.bank-card-bottom > span:first-child {
  display: grid;
  gap: 2px;
}

.bank-card-bottom small {
  color: #9b9aaa;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .12em;
}

.bank-card-bottom strong {
  max-width: 230px;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.card-chip {
  width: 35px;
  height: 25px;
  border-radius: 7px;
  background: linear-gradient(135deg, #f4df9a, #b99949);
  box-shadow: inset 0 0 0 1px rgba(66, 47, 4, .28);
}

.status-muted {
  color: var(--muted);
}

.status-active,
.status-approved {
  color: var(--success);
  border-color: rgba(114, 226, 179, .2);
  background: rgba(114, 226, 179, .07);
}

.status-pending {
  color: var(--warning);
  border-color: rgba(240, 198, 121, .21);
  background: rgba(240, 198, 121, .07);
}

.status-rejected,
.status-error {
  color: var(--danger);
  border-color: rgba(255, 143, 157, .19);
  background: rgba(255, 143, 157, .065);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 14px;
  color: #fff;
  font-size: 12px;
  font-weight: 820;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: transform .18s var(--ease), filter .18s ease, border-color .18s ease, background .18s ease;
}

.button:not(:disabled):active {
  transform: translateY(1px) scale(.985);
}

.button-primary {
  border-color: rgba(213, 202, 255, .2);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .13), transparent 38%),
    linear-gradient(135deg, #9c7cff, #6f56ec 55%, #5141c4);
  box-shadow: 0 13px 30px rgba(77, 57, 192, .27), inset 0 1px rgba(255, 255, 255, .18);
}

.button-secondary,
.button-ghost {
  border-color: var(--line);
  background: rgba(36, 39, 54, .82);
}

.button-ghost {
  color: var(--text-soft);
  background: rgba(255, 255, 255, .025);
}

.button-danger {
  color: #ffd6dc;
  border-color: rgba(255, 143, 157, .2);
  background: rgba(255, 143, 157, .08);
}

.button:disabled {
  color: #717586;
  border-color: rgba(225, 228, 255, .06);
  background: rgba(46, 49, 64, .48);
  box-shadow: none;
  filter: saturate(.3);
}

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

.button-wide {
  width: 100%;
  margin-top: 12px;
}

.microcopy,
.empty-copy {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.centered {
  text-align: center;
}

.receipt-panel {
  grid-column: 2;
}

.order-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  margin-bottom: 14px;
  padding: 14px 15px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(7, 8, 13, .46);
}

.order-summary > span {
  display: grid;
  gap: 3px;
}

.order-summary small {
  color: var(--muted);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .09em;
}

.order-summary strong {
  font-size: 12px;
}

.order-total {
  justify-items: end;
  text-align: right;
}

.order-total strong {
  color: var(--gold);
  font-size: 15px;
}

.receipt-dropzone {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 13px;
  min-height: 104px;
  padding: 15px;
  overflow: hidden;
  border: 1px dashed rgba(146, 117, 255, .34);
  border-radius: var(--radius-md);
  color: var(--text);
  background: rgba(146, 117, 255, .045);
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease;
}

.receipt-dropzone:hover,
.receipt-dropzone.is-dragging {
  border-color: rgba(104, 219, 232, .52);
  background: rgba(104, 219, 232, .055);
}

.receipt-dropzone input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.receipt-dropzone input:focus-visible + .upload-mark {
  outline: 3px solid rgba(104, 219, 232, .35);
  outline-offset: 3px;
}

.upload-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(146, 117, 255, .24);
  border-radius: 14px;
  color: #ded6ff;
  background: rgba(146, 117, 255, .11);
  font-size: 22px;
  font-weight: 300;
}

.receipt-dropzone > span:nth-of-type(2) {
  display: grid;
  gap: 4px;
}

.receipt-dropzone strong {
  font-size: 12px;
}

.receipt-dropzone small {
  color: var(--muted);
  font-size: 10px;
}

.legal-shell {
  width: min(calc(100% - 32px), 920px);
  margin-inline: auto;
  padding: 24px 0 48px;
}

.legal-hero {
  min-height: 270px;
}

.legal-card {
  margin-top: 18px;
  padding: 12px 30px;
}

.legal-card section {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 17px;
  padding: 27px 0;
}

.legal-card section + section {
  border-top: 1px solid rgba(225, 228, 255, .075);
}

.legal-index {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(146, 117, 255, .2);
  border-radius: 10px;
  color: #dcd4ff;
  background: rgba(146, 117, 255, .08);
  font-size: 9px;
  font-weight: 850;
}

.legal-card h2 {
  font-size: 19px;
}

.legal-card p {
  margin: 10px 0 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.75;
}

.legal-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 18px;
}

.receipt-dropzone img {
  grid-column: 1 / -1;
  width: 100%;
  max-height: 230px;
  margin-top: 4px;
  object-fit: contain;
  border-radius: 12px;
  background: rgba(0, 0, 0, .25);
}

.terms-check,
.toggle-row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  color: var(--text-soft);
  font-size: 11px;
  line-height: 1.5;
}

.terms-check {
  margin-top: 14px;
}

.terms-check input {
  flex: 0 0 auto;
  width: 19px;
  height: 19px;
  margin: 0;
  accent-color: var(--violet);
}

.submit-button {
  min-height: 53px;
  margin-top: 16px;
}

.requests-panel {
  margin-top: 18px;
}

.requests-list,
.admin-pending-list {
  display: grid;
  gap: 10px;
}

.request-item,
.admin-request {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border: 1px solid rgba(225, 228, 255, .075);
  border-radius: var(--radius-md);
  background: rgba(8, 9, 15, .42);
}

.request-main,
.request-side,
.admin-request-copy {
  display: grid;
  gap: 4px;
}

.request-main strong,
.admin-request-copy strong {
  font-size: 13px;
}

.request-main span,
.request-side small,
.admin-request-copy span {
  color: var(--muted);
  font-size: 10px;
}

.request-side {
  justify-items: end;
  text-align: right;
}

.request-side > strong {
  color: var(--gold);
  font-size: 13px;
}

.empty-state {
  display: grid;
  justify-items: center;
  gap: 7px;
  min-height: 210px;
  padding: 24px;
  text-align: center;
}

.empty-state > span {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 15px;
  color: var(--gold);
  background: rgba(240, 198, 121, .06);
  font-size: 12px;
  font-weight: 850;
}

.empty-state strong {
  font-size: 13px;
}

.empty-state p {
  max-width: 390px;
  margin: 0;
  color: var(--muted);
  font-size: 10px;
}

.compact-empty {
  min-height: 160px;
}

.state-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  max-width: 680px;
  margin: 55px auto;
  padding: 22px;
}

.state-card strong {
  font-size: 14px;
}

.state-card p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.state-card-error {
  border-color: rgba(255, 143, 157, .18);
}

.state-card-error .state-icon {
  color: var(--danger);
  border-color: rgba(255, 143, 157, .24);
  background: rgba(255, 143, 157, .07);
}

.spinner {
  flex: 0 0 auto;
  width: 29px;
  height: 29px;
  border: 2px solid rgba(146, 117, 255, .18);
  border-top-color: var(--violet);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

.inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.admin-hero {
  min-height: 235px;
  padding: 43px;
}

.admin-hero h1 {
  font-size: clamp(38px, 5vw, 58px);
}

.admin-card-settings {
  align-self: start;
}

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

.field {
  display: grid;
  gap: 7px;
}

.field-wide {
  grid-column: 1 / -1;
}

.field > span {
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 750;
}

.field input[type="text"] {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  outline: none;
  color: var(--text);
  background: rgba(7, 8, 13, .58);
  font-size: 12px;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.field input[type="text"]:focus {
  border-color: rgba(146, 117, 255, .52);
  box-shadow: 0 0 0 4px rgba(146, 117, 255, .09);
}

.field small,
.toggle-row small {
  color: var(--muted);
  font-size: 9px;
}

.toggle-row {
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(7, 8, 13, .36);
}

.toggle-row > span {
  display: grid;
  gap: 3px;
}

.toggle-row input {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 25px;
  margin: 0;
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #282b38;
  transition: background .2s ease, border-color .2s ease;
}

.toggle-row input::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: #a2a6b5;
  content: "";
  transition: transform .2s var(--ease), background .2s ease;
}

.toggle-row input:checked {
  border-color: rgba(114, 226, 179, .27);
  background: rgba(38, 143, 107, .55);
}

.toggle-row input:checked::after {
  background: #dbfff1;
  transform: translateX(19px);
}

.admin-request {
  align-items: start;
}

.admin-request-actions {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 7px;
}

.admin-request-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 12px;
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
}

.toast {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 50;
  max-width: min(390px, calc(100vw - 32px));
  padding: 13px 16px;
  border: 1px solid rgba(114, 226, 179, .2);
  border-radius: 14px;
  color: #cffff0;
  background: rgba(14, 30, 25, .96);
  box-shadow: 0 20px 55px rgba(0, 0, 0, .44);
  font-size: 11px;
  font-weight: 700;
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition: opacity .22s ease, transform .22s var(--ease);
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.toast.is-error {
  color: #ffd9de;
  border-color: rgba(255, 143, 157, .22);
  background: rgba(38, 18, 23, .97);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 0 calc(34px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(225, 228, 255, .06);
  color: var(--muted);
  font-size: 10px;
}

@media (hover: hover) and (pointer: fine) {
  .button:not(:disabled):hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
  }

  .view-tab:hover {
    color: var(--text-soft);
    background: rgba(255, 255, 255, .035);
  }
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 38px;
  }

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

  .checkout-layout,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .plan-panel,
  .receipt-panel {
    grid-row: auto;
    grid-column: auto;
  }
}

@media (max-width: 620px) {
  .site-header,
  .security-banner,
  .view-tabs,
  .page-shell,
  .site-footer {
    width: min(calc(100% - 24px), var(--max-width));
  }

  .legal-shell {
    width: min(calc(100% - 24px), 920px);
    padding-top: 14px;
  }

  .site-header {
    min-height: 78px;
  }

  .brand img {
    width: 40px;
    height: 40px;
    border-radius: 13px;
  }

  .brand small,
  .user-name {
    display: none;
  }

  .security-banner {
    padding: 13px;
  }

  .security-banner p {
    line-height: 1.5;
  }

  .view-tabs {
    position: sticky;
    top: max(8px, env(safe-area-inset-top));
    z-index: 20;
    margin-top: 12px;
    background: rgba(12, 14, 21, .94);
    backdrop-filter: blur(16px);
  }

  .view-tab {
    flex: 1;
  }

  .page-shell {
    padding-top: 14px;
  }

  .hero,
  .admin-hero {
    border-radius: 22px;
  }

  .legal-card {
    padding: 2px 18px;
  }

  .legal-card section {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 22px 0;
  }

  .legal-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .hero {
    gap: 26px;
    padding: 27px 21px;
  }

  h1 {
    font-size: 37px;
  }

  .hero-copy > p,
  .admin-hero > p {
    font-size: 13px;
  }

  .step-rail {
    gap: 6px;
  }

  .step-rail li {
    grid-template-columns: 1fr;
    justify-items: center;
    min-height: 82px;
    gap: 5px;
    padding: 9px 5px;
    text-align: center;
  }

  .step-rail span {
    width: 31px;
    height: 31px;
  }

  .checkout-layout,
  .admin-layout {
    gap: 12px;
    margin-top: 12px;
  }

  .panel {
    padding: 18px;
    border-radius: 19px;
  }

  .panel-heading {
    margin-bottom: 16px;
  }

  .panel-heading h2 {
    font-size: 21px;
  }

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

  .plan-option {
    min-height: 136px;
  }

  .bank-card {
    min-height: 190px;
    padding: 18px;
  }

  .card-number {
    font-size: 18px;
  }

  .order-summary {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .order-total {
    justify-items: start;
    text-align: left;
  }

  .request-item,
  .admin-request {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .request-side {
    grid-template-columns: auto 1fr;
    align-items: center;
    justify-items: start;
    text-align: left;
  }

  .admin-hero {
    min-height: 0;
    padding: 29px 21px;
  }

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

  .field-wide {
    grid-column: auto;
  }

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

  .admin-request-actions .receipt-link {
    grid-column: 1 / -1;
  }

  .site-footer {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

@media (max-width: 350px) {
  .session-summary {
    gap: 6px;
  }

  .role-badge {
    display: none;
  }

  .panel-heading {
    flex-wrap: wrap;
  }

  .card-number {
    font-size: 16px;
    letter-spacing: .06em;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

:focus-visible {
  outline: 3px solid rgba(104, 219, 232, .5);
  outline-offset: 3px;
}

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

@keyframes view-in {
  from { opacity: 0; transform: translateY(9px); }
  to { opacity: 1; transform: translateY(0); }
}
