*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg: #0f1720;
  --bg-soft: #152230;
  --panel: rgba(18, 29, 40, 0.78);
  --panel-strong: rgba(19, 33, 46, 0.94);
  --panel-muted: rgba(173, 216, 230, 0.12);
  --line: rgba(173, 216, 230, 0.14);
  --line-strong: rgba(173, 216, 230, 0.24);
  --text: #e8f6fb;
  --muted: #91aab8;
  --accent: #add8e6;
  --accent-dark: #7fb8ca;
  --accent-strong: #bfe6f3;
  --accent-soft: rgba(173, 216, 230, 0.18);
  --danger: #e98a97;
  --danger-soft: rgba(233, 138, 151, 0.16);
  --shadow: 0 28px 72px rgba(0, 0, 0, 0.34);
  --radius: 24px;
  --radius-sm: 18px;
  --container: 1220px;
  --font-display: "Sora", sans-serif;
  --font-body: "Manrope", sans-serif;
}

body[data-theme="light"] {
  --bg: #eef8fc;
  --bg-soft: #e1f1f7;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-strong: rgba(255, 255, 255, 0.94);
  --panel-muted: rgba(173, 216, 230, 0.16);
  --line: rgba(47, 89, 111, 0.12);
  --line-strong: rgba(47, 89, 111, 0.2);
  --text: #18354a;
  --muted: #5d7d92;
  --accent: #add8e6;
  --accent-dark: #88bfd1;
  --accent-strong: #366d88;
  --accent-soft: rgba(173, 216, 230, 0.26);
  --danger: #d66c7c;
  --danger-soft: rgba(214, 108, 124, 0.14);
  --shadow: 0 24px 60px rgba(90, 131, 153, 0.16);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(173, 216, 230, 0.12), transparent 28%),
    radial-gradient(circle at top right, rgba(173, 216, 230, 0.08), transparent 24%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
  position: relative;
  transition: background 0.45s ease, color 0.45s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.32;
  background-image:
    linear-gradient(rgba(173, 216, 230, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(173, 216, 230, 0.03) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.82), transparent 90%);
}

body::after {
  content: "";
  position: fixed;
  inset: auto -10% -24% auto;
  width: 46vw;
  height: 46vw;
  min-width: 320px;
  min-height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(173, 216, 230, 0.12), transparent 68%);
  filter: blur(20px);
  pointer-events: none;
  animation: haloShift 18s ease-in-out infinite;
}

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

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

button,
a {
  color: inherit;
}

a {
  text-decoration: none;
}

code {
  padding: 0.16rem 0.42rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

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

h1,
h2,
h3,
.brand strong,
.status-card__title {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.5rem, 4.8vw, 4.9rem);
  line-height: 1.02;
  margin-bottom: 0;
}

h2 {
  font-size: clamp(1.36rem, 2.3vw, 2.1rem);
  line-height: 1.18;
  margin-bottom: 0.7rem;
}

h3 {
  font-size: 1.08rem;
  line-height: 1.28;
  margin-bottom: 0.55rem;
}

.container {
  width: min(calc(100% - 32px), var(--container));
  margin: 0 auto;
}

.section {
  padding: 38px 0;
}

.section-stack,
.hero__content,
.hero__aside,
.admin-side {
  display: grid;
  gap: 20px;
}

.header,
.footer {
  position: relative;
  z-index: 2;
}

.header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(18px);
  background: rgba(10, 16, 23, 0.82);
  border-bottom: 1px solid var(--line);
}

body[data-theme="light"] .header {
  background: rgba(248, 252, 255, 0.78);
}

.header__inner,
.panel-header,
.footer__inner,
.section-heading,
.row,
.table-controls,
.status-card__top,
.product-card__top,
.product-card__bottom,
.news-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.section-heading {
  align-items: flex-end;
}

.section-heading--compact {
  align-items: flex-start;
  margin-bottom: 18px;
}

.header__inner,
.panel-header,
.footer__inner {
  padding: 18px 0;
}

.footer {
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.footer__inner--simple {
  justify-content: center;
}

.footer__inner--legal {
  justify-content: space-between;
  align-items: flex-start;
}

.footer__brand,
.footer__copy {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.footer__brand {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.footer__copy {
  justify-content: center;
  padding-bottom: 24px;
  color: var(--muted);
}

.footer-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--muted);
  transition: color 0.2s ease, opacity 0.2s ease;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: var(--text);
}

.header__controls,
.panel-header__actions,
.hero__actions,
.section-actions,
.filter-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.brand__logo {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  overflow: visible;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.brand__logo-image {
  display: none;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand__logo-image.is-ready {
  display: block;
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.24));
}

.brand__logo-fallback.is-hidden {
  display: none;
}

.brand__logo-fallback {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--panel-muted);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.brand strong {
  font-size: 1.03rem;
}

.brand small,
.muted,
.helper-text,
.field span,
.metric span,
.metric small,
.news-card p,
.product-card p,
.section-heading__text {
  color: var(--muted);
}

.nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav__link,
.btn,
.filter-chip {
  border-radius: 999px;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.nav__link {
  padding: 11px 16px;
  border: 1px solid transparent;
  color: var(--muted);
}

.nav__link:hover,
.nav__link[aria-current="page"] {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--line);
  color: var(--text);
}

.btn {
  border: 1px solid transparent;
  padding: 13px 18px;
  font-weight: 800;
  cursor: pointer;
}

.btn:hover,
.btn:focus-visible,
.filter-chip:hover,
.filter-chip:focus-visible {
  transform: translateY(-1px);
}

.btn--primary {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #112132;
  box-shadow: var(--shadow);
}

.btn--ghost,
.filter-chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  color: var(--text);
}

.btn--danger {
  background: var(--danger-soft);
  border: 1px solid rgba(233, 138, 151, 0.24);
  color: var(--danger);
}

.btn.is-disabled,
.btn[aria-disabled="true"] {
  opacity: 0.68;
  cursor: not-allowed;
  pointer-events: none;
}

.theme-toggle {
  min-width: 48px;
  width: 48px;
  height: 48px;
  padding: 0;
  font-size: 1.2rem;
  line-height: 1;
  position: relative;
}

.theme-toggle::before,
.theme-toggle::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.theme-toggle::before {
  width: 16px;
  height: 16px;
  border-radius: 50%;
}

.theme-toggle[data-mode="dark"]::before {
  background: var(--accent);
  box-shadow:
    0 0 0 4px rgba(173, 216, 230, 0.12),
    0 0 18px rgba(173, 216, 230, 0.28);
}

.theme-toggle[data-mode="dark"]::after {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px dashed rgba(173, 216, 230, 0.4);
}

.theme-toggle[data-mode="light"]::before {
  width: 18px;
  height: 18px;
  background: var(--accent);
  border-radius: 50%;
  transform: translateX(-3px);
  box-shadow: 6px 0 0 0 var(--panel);
}

.theme-toggle[data-mode="light"]::after {
  opacity: 0;
}

.block-card,
.news-card,
.product-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.06), transparent 38%),
    linear-gradient(180deg, rgba(173, 216, 230, 0.06), transparent 78%),
    var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  transition: transform 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.block-card::before,
.news-card::before,
.product-card::before {
  content: "";
  position: absolute;
  right: -72px;
  bottom: -92px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(173, 216, 230, 0.16), transparent 70%);
  filter: blur(16px);
  opacity: 0.58;
  animation: ambientBloom 15s ease-in-out infinite;
  pointer-events: none;
}

.block-card {
  padding: 28px;
}

.hero {
  padding-top: 48px;
}

.hero__grid,
.content-grid,
.admin-panels,
.admin-grid,
.stats-grid,
.news-list,
.products-grid,
.status-card__stats,
.preview-stack,
.monitor-card__stats,
.form-grid {
  display: grid;
  gap: 18px;
}

.hero__grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
}

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

.admin-panels {
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  margin-top: 18px;
}

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

.stat-box strong,
.metric strong,
.preview-stack strong,
.monitor-metric strong {
  font-size: 1.3rem;
}

.hero__text,
.page-lead,
.season-card p,
.status-card__footer p {
  line-height: 1.74;
}

.eyebrow {
  margin-bottom: 0.8rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.status-badge,
.badge,
.chip,
.filter-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1;
  border-radius: 999px;
}

.badge,
.chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}

.badge--accent,
.filter-chip.active {
  background: var(--accent-soft);
  color: var(--accent-strong);
  border-color: var(--line-strong);
}

.badge--soft {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  color: var(--muted);
}

.status-badge {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
}

.status-badge[data-state="online"] {
  background: rgba(116, 214, 168, 0.14);
  color: #74d6a8;
}

.status-badge[data-state="offline"],
.status-badge[data-state="error"] {
  background: var(--danger-soft);
  color: var(--danger);
}

.feature-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 12px;
  color: var(--muted);
}

.content-card--accent {
  overflow: hidden;
}

.content-card--accent::after,
.hero__content::after {
  content: "";
  position: absolute;
  inset: auto -20% -35% auto;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(173, 216, 230, 0.18), transparent 70%);
  pointer-events: none;
}

.hero__content {
  animation: cardDrift 11s ease-in-out infinite;
}

.hero__aside > .block-card:first-child {
  animation: cardDrift 13s ease-in-out infinite reverse;
}

.hero__aside > .block-card:last-child {
  animation: cardDrift 9s ease-in-out infinite;
}

.news-card:hover,
.product-card:hover,
.status-card:hover,
.season-card:hover,
.content-card:hover,
.preview-card:hover,
.monitor-card:hover,
.stat-box:hover {
  transform: translate3d(0, -4px, 0);
  border-color: var(--line-strong);
}

.page-hero__content {
  max-width: 900px;
}

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

.news-list--wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.news-card__image-wrap {
  aspect-ratio: 16 / 10;
  background: rgba(255, 255, 255, 0.04);
}

.news-card__image,
.product-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-card__content,
.product-card__content {
  display: grid;
  gap: 14px;
  padding: 22px;
}

.products-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 320px));
  justify-content: center;
}

.product-card__image {
  width: 100%;
  height: 196px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.04);
}

.product-card__meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.product-card__top {
  align-items: flex-start;
}

.product-card {
  display: grid;
  align-content: start;
}

.product-card__content {
  align-content: start;
}

.product-card__headline {
  display: grid;
  gap: 8px;
}

.product-card .description {
  margin: 0;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card__bottom {
  justify-content: flex-start;
}

.product-card__bottom .btn {
  width: 100%;
}

.product-card--compact {
  padding-top: 18px;
}

.product-card--compact .product-card__image {
  width: 32px;
  height: 32px;
  margin: 0 0 0 22px;
  border-radius: 10px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.product-card--compact .product-card__content {
  padding-top: 18px;
}

.product-card__image--interactive,
.product-card__title--interactive {
  cursor: pointer;
}

.price {
  color: var(--accent-strong);
  font-size: 1.18rem;
  font-weight: 800;
}

.product-details {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.product-details--dialog {
  color: var(--text);
  gap: 10px;
}

.product-dialog {
  padding: 0;
  border: 0;
  background: transparent;
  width: min(1040px, calc(100% - 24px));
  max-width: 1040px;
}

.product-dialog::backdrop {
  background: rgba(7, 12, 18, 0.78);
  backdrop-filter: blur(8px);
}

.product-dialog__panel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.06), transparent 38%),
    linear-gradient(180deg, rgba(173, 216, 230, 0.06), transparent 78%),
    var(--panel-strong);
  box-shadow: var(--shadow);
}

.product-dialog__backdrop {
  display: none;
}

.product-dialog__close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
}

.product-dialog__grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1.05fr);
}

.product-dialog__media {
  min-height: 100%;
  background: rgba(255, 255, 255, 0.04);
}

.product-dialog__image {
  width: 100%;
  height: 100%;
  min-height: 340px;
  object-fit: cover;
}

.product-dialog__content {
  display: grid;
  gap: 18px;
  padding: 32px;
}

.product-dialog__meta,
.product-dialog__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.product-dialog__description {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.shop-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 16px;
  align-items: end;
}

.shop-toolbar__meta {
  display: grid;
  gap: 4px;
  justify-items: end;
}

.payments-card,
.legal-card,
.legal-section {
  display: grid;
  gap: 16px;
}

.info-grid,
.info-list {
  display: grid;
  gap: 18px;
}

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

.info-card {
  display: grid;
  gap: 18px;
}

.info-list > div {
  display: grid;
  gap: 6px;
}

.info-link {
  color: var(--text);
  word-break: break-word;
}

.info-link:hover,
.info-link:focus-visible {
  color: var(--accent-strong);
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.social-link:hover,
.social-link:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.08);
}

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

.payment-logo-card {
  display: grid;
  place-items: center;
  min-height: 92px;
  padding: 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

body[data-theme="light"] .payment-logo-card {
  background: rgba(255, 255, 255, 0.98);
}

.payment-logo {
  max-width: 100%;
  max-height: 34px;
  width: auto;
  object-fit: contain;
}

.legal-stack {
  display: grid;
  gap: 18px;
}

.legal-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
  color: var(--muted);
  line-height: 1.72;
}

.register-card {
  display: grid;
  gap: 18px;
}

.shop-warning-banner {
  border: 1px solid rgba(240, 82, 82, 0.38);
  background:
    linear-gradient(135deg, rgba(120, 11, 29, 0.88), rgba(66, 7, 18, 0.94)),
    radial-gradient(circle at top right, rgba(255, 183, 77, 0.18), transparent 48%);
}

.shop-warning-banner h2 {
  margin: 8px 0 10px;
  color: #ffd7d7;
  font-size: clamp(1.5rem, 2.8vw, 2.4rem);
  line-height: 1.1;
  text-transform: uppercase;
}

.shop-warning-banner p:last-child {
  margin: 0;
  color: #fff1f1;
  font-size: 1.02rem;
  font-weight: 800;
  line-height: 1.7;
}

.account-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.account-status strong {
  color: var(--accent-strong);
}

.checkbox-field {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.checkbox-field--boxed {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.checkbox-field input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.checkbox-field span {
  color: var(--text);
  line-height: 1.65;
}

.checkbox-field a {
  color: var(--accent-strong);
}

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

.term-card {
  display: grid;
  gap: 6px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-align: left;
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.term-card strong {
  font-size: 1rem;
}

.term-card span {
  color: var(--muted);
}

.term-card:hover,
.term-card:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
}

.term-card.active {
  border-color: rgba(245, 158, 11, 0.9);
  background: rgba(245, 158, 11, 0.12);
}

.product-dialog__checkout {
  display: grid;
  gap: 16px;
  margin-top: 18px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.product-dialog__checkout-top {
  display: grid;
  gap: 8px;
}

.product-dialog__checkout .price {
  font-size: clamp(1.2rem, 2.8vw, 1.8rem);
}

.product-checkout-form {
  display: grid;
  gap: 14px;
}

.account-blocked-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(7, 11, 16, 0.88);
  backdrop-filter: blur(10px);
}

.account-blocked-overlay__panel {
  width: min(100%, 720px);
  padding: clamp(28px, 4vw, 48px);
  border-radius: 28px;
  border: 1px solid rgba(240, 82, 82, 0.34);
  background: linear-gradient(160deg, rgba(31, 41, 55, 0.96), rgba(17, 24, 39, 0.98));
  text-align: center;
  box-shadow: 0 32px 120px rgba(0, 0, 0, 0.42);
}

.account-blocked-overlay__panel h2 {
  margin: 10px 0 14px;
  color: #ffe2e2;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.06;
}

.account-blocked-overlay__panel p:last-child {
  margin: 0;
  color: #ffd6d6;
  font-size: 1.04rem;
  line-height: 1.7;
}

.is-account-blocked {
  overflow: hidden;
}

.filter-group {
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

.filter-group::-webkit-scrollbar {
  height: 8px;
}

.filter-group::-webkit-scrollbar-thumb {
  background: var(--accent-soft);
  border-radius: 999px;
}

.filter-group::-webkit-scrollbar-track {
  background: transparent;
}

.filter-chip {
  flex: 0 0 auto;
  white-space: nowrap;
}

.admin-shell {
  padding-top: 18px;
  padding-bottom: 42px;
}

#adminSection {
  display: grid;
  gap: 18px;
}

#adminSection > .stats-grid,
#adminSection > .admin-quicknav,
#adminSection > .admin-grid,
#adminSection > .admin-panels,
#adminSection > .admin-purchases {
  margin-top: 0;
}

#adminSection > .admin-grid {
  order: 1;
}

#adminSection > .admin-panels {
  order: 2;
}

#adminSection > .admin-purchases {
  order: 3;
}

.auth-card {
  width: min(100%, 760px);
  margin: 40px auto 0;
}

.admin-quicknav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.auth-card__actions,
.admin-box__actions {
  margin-top: 16px;
}

.admin-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 18px;
}

.stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 6px;
}

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

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

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

.field--compact {
  min-width: min(100%, 280px);
}

.form-section {
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.field input,
.field textarea,
.field select,
.table-select {
  width: 100%;
  padding: 13px 14px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.field input:focus,
.field textarea:focus,
.field select:focus,
.table-select:focus {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.08);
}

.table-wrap {
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: 12px 10px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.table-select {
  min-width: 140px;
}

.image-preview {
  margin-top: 18px;
  padding: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.image-preview img {
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  border-radius: 12px;
}

.notice,
.error {
  margin-top: 14px;
  padding: 13px 14px;
  border-radius: 16px;
}

.notice {
  background: var(--accent-soft);
  color: var(--accent-strong);
  border: 1px solid var(--line-strong);
}

.error {
  background: var(--danger-soft);
  color: var(--danger);
  border: 1px solid rgba(233, 138, 151, 0.24);
}

.empty-state {
  display: grid;
  gap: 8px;
  min-height: 220px;
  place-content: center;
  text-align: center;
}

.hidden {
  display: none !important;
}

.reveal-node {
  opacity: 0;
  transform: translate3d(0, 26px, 0) rotateX(8deg) scale(0.985);
  filter: blur(8px);
  transition:
    opacity 0.9s cubic-bezier(0.2, 0.9, 0.15, 1),
    transform 0.9s cubic-bezier(0.2, 0.9, 0.15, 1),
    filter 0.9s cubic-bezier(0.2, 0.9, 0.15, 1);
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal-node.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) rotateX(0deg) scale(1);
  filter: blur(0);
}

@keyframes ambientBloom {
  0% {
    transform: translate3d(0, 0, 0) scale(0.92);
    opacity: 0.42;
  }
  50% {
    transform: translate3d(-16px, -20px, 0) scale(1.08);
    opacity: 0.7;
  }
  100% {
    transform: translate3d(10px, -6px, 0) scale(0.96);
    opacity: 0.48;
  }
}

@keyframes haloShift {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(-24px, -18px, 0) scale(1.08);
  }
}

@keyframes cardDrift {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(0, -6px, 0);
  }
}

@media (max-width: 1140px) {
  .hero__grid,
  .content-grid--launch,
  .admin-panels,
  .admin-grid,
  .news-list,
  .news-list--wide,
  .products-grid,
  .info-grid,
  .stats-grid,
  .shop-toolbar,
  .status-card__stats {
    grid-template-columns: 1fr;
  }

  .shop-toolbar__meta {
    justify-items: start;
  }

  .payment-logos {
    grid-template-columns: 1fr;
  }

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

  .product-dialog__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .header__inner,
  .panel-header,
  .footer__inner,
  .section-heading,
  .row,
  .table-controls,
  .status-card__top,
  .product-card__top,
  .product-card__bottom,
  .news-card__meta {
    flex-direction: column;
    align-items: stretch;
  }

  .header__controls,
  .panel-header__actions,
  .nav {
    width: 100%;
  }

  .nav {
    flex-wrap: wrap;
  }

  .block-card,
  .auth-card,
  .admin-box,
  .stat-box {
    padding: 22px;
  }

  .account-status {
    flex-direction: column;
    align-items: stretch;
  }

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

  .product-dialog {
    width: min(calc(100% - 16px), 100%);
  }

  .product-dialog__content {
    padding: 22px;
  }

  .product-dialog__close {
    position: static;
    margin: 16px 16px 0 auto;
  }
}
