:root {
  color-scheme: light;
  --bg: #f5f7fb;
  --surface: rgba(255, 255, 255, 0.95);
  --border: rgba(15, 23, 42, 0.12);
  --text: #0f172a;
  --muted: #475569;
  --accent: #1d7ede;
  --accent-strong: #145ca2;
  --glow: 0 0 0 1px rgba(29, 126, 222, 0.22), 0 18px 50px rgba(29, 126, 222, 0.18);
  --shadow: 0 22px 70px rgba(15, 23, 42, 0.12);
  --card-radius: 18px;
  --overlay-top: linear-gradient(180deg, rgba(245, 247, 251, 0.9) 0%, rgba(245, 247, 251, 0.6) 60%, rgba(180, 210, 245, 0.35) 100%);
  --overlay-bottom: radial-gradient(120% 120% at 50% 0%, rgba(68, 148, 227, 0.65) 0%, rgba(68, 148, 227, 0.18) 50%, transparent 70%);
  --card-bg: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(234, 240, 248, 0.94) 100%);
  --panel-border: rgba(15, 23, 42, 0.12);
  --drop-border: rgba(29, 126, 222, 0.35);
  --drop-bg: rgba(255, 255, 255, 0.96);
  --panel-bg: rgba(255, 255, 255, 0.95);
  --hash-bg: rgba(255, 255, 255, 0.96);
  --font-base: "Noto Kufi Arabic", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-size-body: 14px;
  --font-size-title: 20px;
  --font-size-section: 18px;
  --font-size-label: 13px;
  --font-size-status: 12px;
  --font-size-button: 14px;
  --button-height: 44px;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1117;
  --surface: rgba(19, 26, 35, 0.92);
  --border: rgba(255, 255, 255, 0.08);
  --text: #f1f5f9;
  --muted: #9ca3af;
  --accent: #43a2ff;
  --accent-strong: #2f7cd8;
  --glow: 0 0 0 1px rgba(67, 162, 255, 0.3), 0 22px 60px rgba(0, 0, 0, 0.45);
  --shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  --card-radius: 18px;
  --overlay-top: linear-gradient(180deg, rgba(12, 18, 26, 0.92) 0%, rgba(12, 18, 26, 0.75) 60%, rgba(18, 92, 191, 0.35) 100%);
  --overlay-bottom: radial-gradient(120% 120% at 50% 0%, rgba(24, 121, 221, 0.9) 0%, rgba(24, 121, 221, 0.2) 50%, transparent 70%);
  --card-bg: linear-gradient(180deg, rgba(17, 24, 35, 0.94) 0%, rgba(12, 18, 26, 0.96) 100%);
  --panel-border: rgba(255, 255, 255, 0.08);
  --drop-border: rgba(67, 162, 255, 0.6);
  --drop-bg: rgba(16, 21, 30, 0.9);
  --panel-bg: rgba(18, 26, 36, 0.85);
  --hash-bg: rgba(18, 26, 36, 0.9);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --bg: #0d1117;
    --surface: rgba(19, 26, 35, 0.92);
    --border: rgba(255, 255, 255, 0.08);
    --text: #f1f5f9;
    --muted: #9ca3af;
    --accent: #43a2ff;
    --accent-strong: #2f7cd8;
    --glow: 0 0 0 1px rgba(67, 162, 255, 0.3), 0 22px 60px rgba(0, 0, 0, 0.45);
    --shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
    --overlay-top: linear-gradient(180deg, rgba(12, 18, 26, 0.92) 0%, rgba(12, 18, 26, 0.75) 60%, rgba(18, 92, 191, 0.35) 100%);
    --overlay-bottom: radial-gradient(120% 120% at 50% 0%, rgba(24, 121, 221, 0.9) 0%, rgba(24, 121, 221, 0.2) 50%, transparent 70%);
  }
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes drift {
  from {
    transform: translate3d(-10px, 0, 0) scale(1);
  }
  to {
    transform: translate3d(10px, -6px, 0) scale(1.04);
  }
}

@keyframes glowPulse {
  0% {
    box-shadow: var(--glow);
  }
  100% {
    box-shadow: 0 0 0 1px rgba(79, 70, 229, 0.2), 0 18px 70px rgba(79, 70, 229, 0.25);
  }
}

@keyframes loaderSpin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 0 0 60px;
  font-family: var(--font-base);
  font-size: var(--font-size-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
  direction: inherit;
  text-align: start;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: var(--overlay-top);
  z-index: 0;
}

.page-loader {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 20% 20%, rgba(67, 162, 255, 0.16), transparent 45%),
    linear-gradient(135deg, rgba(11, 116, 211, 0.28), rgba(15, 23, 42, 0.6));
  backdrop-filter: blur(12px);
  z-index: 9999;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.page-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.page-loader__glass {
  padding: 16px 18px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.22);
  display: grid;
  gap: 10px;
  place-items: center;
  color: #0a1b2f;
}

.page-loader__spinner {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid rgba(67, 162, 255, 0.22);
  border-top-color: var(--accent);
  animation: loaderSpin 1s ease-in-out infinite;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}

.page-loader__text {
  margin: 0;
  font-weight: 800;
  letter-spacing: 0.08em;
  font-size: 12px;
  text-transform: uppercase;
  color: inherit;
}

:root[data-theme="dark"] .page-loader__glass {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-base);
  font-size: var(--font-size-body);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.page {
  width: min(1180px, 96vw);
  display: grid;
  gap: 22px;
  position: relative;
  z-index: 1;
  padding: 32px 0px 0;
  box-sizing: border-box;
  margin: 0 auto;
}

.topbar {
  width: 100%;
  padding: 10px 24px;
  background: #ffffff;
  color: #0a1b2f;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  position: relative;
  z-index: 6;
}

.topbar-inner {
  width: min(1180px, 96vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #0a1b2f;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand img {
  height: 60px;
  width: auto;
  display: block;
}

.brand-logo--light {
  display: block;
}

.brand-logo--dark {
  display: none;
}

:root:not([data-theme="dark"]) .brand-logo--light {
  display: block !important;
}

:root:not([data-theme="dark"]) .brand-logo--dark {
  display: none !important;
}

:root[data-theme="dark"] .brand-logo--light {
  display: none !important;
}

:root[data-theme="dark"] .brand-logo--dark {
  display: block !important;
}

.brand-name {
  font-size: 16px;
}

.topnav {
  display: flex;
  gap: 18px;
  justify-content: center;
  flex-wrap: wrap;
}

.topnav a {
  color: #0a1b2f;
  text-decoration: none;
  font-weight: 700;
  font-size: var(--font-size-body);
}

.topnav a:hover {
  text-decoration: underline;
  color: #0b74d3;
}

:root[data-theme="dark"] .topbar {
  background: #0b1320;
  color: #f8fafc;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
}

:root[data-theme="dark"] .brand,
:root[data-theme="dark"] .brand-name,
:root[data-theme="dark"] .topnav a {
  color: #f8fafc;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.45);
  opacity: 1;
}

:root[data-theme="dark"] .topnav a:hover {
  color: #ffffff;
}

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

.header {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
  animation: floatIn 0.55s ease forwards;
  direction: inherit;
  text-align: start;
}

.logo-banner {
  display: flex;
  justify-content: center;
  align-items: center;
  width: min(320px, 70vw);
  margin: 0 auto 12px;
}

.logo-banner img {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
}

.hero {
  margin: 0 calc(50% - 50vw);
  width: 100vw;
  background: linear-gradient(135deg, #0b74d3, #0d4ba3);
  color: #e8f2ff;
  padding: clamp(26px, 6vw, 48px) 0;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 60px rgba(6, 42, 94, 0.25);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("/img/sakkbg.png");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  filter: blur(10px);
  transform: scale(1.06);
  z-index: 0;
}

.hero-inner {
  width: min(1180px, 92vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(12px, 3vw, 22px);
  min-height: 280px;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.08), transparent 55%);
  opacity: 0.8;
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  text-align: center;
  align-content: center;
  justify-items: center;
}

.hero-kicker {
  margin: 0;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: rgba(232, 242, 255, 0.8);
}

.hero h1 {
  margin: 0;
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 1.35;
  color: #fff;
}

.hero-subtitle {
  margin: 0;
  color: rgba(232, 242, 255, 0.9);
  font-size: var(--font-size-body);
  line-height: 1.7;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-width: 200px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

.hero-visual {
  position: relative;
  justify-self: center;
  align-self: center;
  width: clamp(180px, 36vw, 320px);
  aspect-ratio: 1;
  opacity: 0.9;
}

.hero-globe {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 14px 40px rgba(0, 0, 0, 0.24));
}

.hero-meta {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-self: flex-end;
  justify-content: center;
}

.features-band {
  margin: 0 calc(50% - 50vw);
  width: 100vw;
  background: radial-gradient(120% 120% at 10% 0%, rgba(29, 126, 222, 0.08) 0%, transparent 38%),
    radial-gradient(120% 120% at 90% 0%, rgba(13, 75, 163, 0.06) 0%, transparent 42%),
    linear-gradient(135deg, #e8f2ff 0%, #f7f9fc 52%, #eef4ff 100%);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  padding: clamp(32px, 6vw, 128px) 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 10px 30px rgba(15, 23, 42, 0.05);
}

.features-inner {
  width: min(1180px, 92vw);
  margin: 0 auto;
  display: grid;
  gap: 14px;
  text-align: center;
}

.features-inner h2 {
  margin: 0;
  font-size: var(--font-size-section);
  color: black;
  letter-spacing: 0.01em;
  font-weight: 800;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.feature-card {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #f0f6ff 100%);
  border: 1px solid rgba(29, 126, 222, 0.18);
  border-radius: 16px;
  padding: 16px;
  display: grid;
  gap: 8px;
  align-items: center;
  justify-items: center;
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.12);
  transition: transform 0.18s ease, box-shadow 0.22s ease, border-color 0.2s ease, background 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  border-color: rgba(29, 126, 222, 0.4);
  box-shadow: 0 22px 44px rgba(15, 23, 42, 0.16);
  background: linear-gradient(180deg, #ffffff 0%, #e4f0ff 100%);
}

.feature-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 35% 35%, rgba(67, 162, 255, 0.28), rgba(29, 126, 222, 0.2));
  border: 1px solid rgba(29, 126, 222, 0.45);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.12);
  font-size: 20px;
  color: var(--accent-strong);
}

.feature-card h3 {
  margin: 0;
  color: #0f172a;
  font-weight: 800;
}

.feature-card p {
  margin: 0;
  color: var(--text);
  font-size: var(--font-size-body);
}

:root[data-theme="dark"] .features-band {
  background: radial-gradient(140% 140% at 10% 0%, rgba(67, 162, 255, 0.08) 0%, transparent 40%),
    radial-gradient(140% 140% at 90% 0%, rgba(67, 162, 255, 0.06) 0%, transparent 42%),
    linear-gradient(135deg, #0b1320 0%, #0f172a 100%);
  border-bottom-color: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 16px 40px rgba(0, 0, 0, 0.45);
}

:root[data-theme="dark"] .features-inner h2 {
  color: #e2e8f0;
}

:root[data-theme="dark"] .feature-card {
  background: linear-gradient(180deg, rgba(26, 35, 52, 0.98) 0%, rgba(12, 18, 26, 0.96) 100%);
  border-color: rgba(67, 162, 255, 0.32);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.5);
}

:root[data-theme="dark"] .feature-card:hover {
  border-color: rgba(67, 162, 255, 0.6);
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.6);
  background: linear-gradient(180deg, rgba(34, 47, 70, 0.98), rgba(17, 24, 35, 0.96));
}

:root[data-theme="dark"] .feature-icon {
  background: radial-gradient(circle at 35% 35%, rgba(67, 162, 255, 0.32), rgba(47, 124, 216, 0.28));
  border-color: rgba(67, 162, 255, 0.55);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55);
}

:root[data-theme="dark"] .feature-card h3 {
  color: #e9f4ff;
}

:root[data-theme="dark"] .feature-card p {
  color: #dbeafe;
}

:root[data-theme="dark"] .header {
  color: #e2e8f0;
}

:root[data-theme="dark"] .header h1 {
  color: #f8fafc;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.5);
}

:root[data-theme="dark"] .header .subtitle {
  color: #cbd5e1;
}

:root[data-theme="dark"] h2,
:root[data-theme="dark"] h3 {
  color: #e2e8f0;
}

.meta-badge {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  font-weight: 700;
}

.steps {
  margin: 20px auto 22px;
  background: #fff;
  border: 1px dashed rgba(29, 126, 222, 0.3);
  border-radius: 18px;
  padding: clamp(18px, 3vw, 28px);
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.06);
}

.steps-head {
  text-align: center;
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
}

.steps-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: var(--font-size-body);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.step-card {
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  padding: 14px;
  background: #fff;
  display: grid;
  gap: 10px;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.06);
  text-align: center;
  justify-items: center;
}

.step-icon {
  font-size: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(67, 162, 255, 0.1);
  border: 1px solid rgba(67, 162, 255, 0.4);
  color: var(--accent-strong);
}

.step-card h3 {
  margin: 0;
  font-size: var(--font-size-section);
}

.step-card p {
  margin: 0;
  color: var(--muted);
  font-size: var(--font-size-body);
}

.header-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
}

.header h1 {
  margin: 0;
  font-size: var(--font-size-title);
  letter-spacing: 0.01em;
  line-height: 1.4;
  text-align: start;
  text-transform: none;
}

h2,
h3 {
  color: #0a1b2f;
  font-weight: 800;
  letter-spacing: 0.01em;
  font-size: var(--font-size-section);
  line-height: 1.5;
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: var(--font-size-body);
  line-height: 1.5;
  text-align: start;
}

h2,
h3 {
  font-size: var(--font-size-section);
  line-height: 1.5;
}

.lang-switcher {
  align-self: auto;
  display: inline-flex;
  align-items: center;
  background: rgba(24, 121, 221, 0.12);
  border: 1px solid rgba(67, 162, 255, 0.3);
  border-radius: 999px;
  padding: 6px 6px 6px 14px;
  gap: 6px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(8px);
  position: relative;
  cursor: pointer;
}

.lang-select {
  border: none;
  background: transparent;
  color: var(--text);
  font-weight: 700;
  font-size: var(--font-size-body);
  padding: 6px 32px 6px 6px;
  border-radius: 999px;
  outline: none;
  cursor: pointer;
  min-width: 96px;
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24'%3E%3Cpath fill='%234f46e5' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  text-align: center;
}

.lang-select:focus {
  outline: none;
  box-shadow: none;
}

.lang-select:focus-visible {
  box-shadow: var(--glow);
}

.lang-switcher::after {
  content: "";
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: var(--panel-bg);
  color: var(--text);
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
  transition: transform 0.15s ease, box-shadow 0.2s ease, border-color 0.2s ease,
    background 0.2s ease;
  backdrop-filter: blur(8px);
}

.theme-toggle:hover {
  transform: translateY(-1px);
  box-shadow: var(--glow);
}

.theme-toggle:active {
  transform: translateY(0);
}

.theme-toggle-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  padding: 0;
  overflow: visible;
  clip: auto;
  white-space: nowrap;
  border: 0;
  font-weight: 700;
  color: var(--text);
}

.theme-toggle-track {
  position: relative;
  width: 56px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(79, 70, 229, 0.18), rgba(14, 165, 233, 0.2));
  box-shadow: inset 0 1px 4px rgba(15, 23, 42, 0.08);
}

.theme-toggle-track::before,
.theme-toggle-track::after {
  content: "";
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.theme-toggle-track::before {
  content: "☀";
  left: 8px;
  color: #d97706;
  opacity: 0.9;
}

:root[data-theme="dark"] .theme-toggle-track::before {
  opacity: 0.35;
}

.theme-toggle-track::after {
  content: "☾";
  right: 8px;
  color: #475569;
  opacity: 0.6;
}

:root[data-theme="dark"] .theme-toggle-track::after {
  opacity: 0.9;
}

:root[data-theme="dark"] .theme-toggle-track {
  border-color: rgba(255, 255, 255, 0.16);
  background: linear-gradient(135deg, rgba(124, 155, 255, 0.3), rgba(14, 165, 233, 0.24));
}

.theme-toggle-text strong {
  color: var(--muted);
  font-weight: 700;
}

:root[data-theme="dark"] .theme-toggle-text strong {
  color: #cbd5e1;
}

.theme-toggle-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffffff, rgba(226, 232, 240, 0.85));
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12);
  transition: transform 0.25s ease, background 0.25s ease;
}

:root[data-theme="dark"] .theme-toggle-thumb {
  background: linear-gradient(135deg, #1f2937, #111827);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.45);
}

.theme-toggle.is-dark .theme-toggle-thumb {
  transform: translateX(26px);
}

.lang-btn {
  border: none;
  padding: 8px 14px;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.lang-btn.active {
  background: rgba(79, 70, 229, 0.12);
  color: var(--text);
  box-shadow: var(--glow);
}

.lang-btn:active {
  transform: translateY(1px);
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--panel-border);
  border-radius: var(--card-radius);
  padding: clamp(26px, 3vw, 34px);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  display: flex;
  flex-direction: column;
  gap: 22px;
  animation: floatIn 0.6s ease 0.04s backwards;
  position: relative;
}

/* Login overlay */
.card--requires-login {
  pointer-events: none;
}

.card--requires-login::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.65);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  backdrop-filter: blur(16px) saturate(180%);
  z-index: 4;
  border-radius: var(--card-radius);
}

.card--requires-login .card-content {
  filter: blur(8px);
  opacity: 0.5;
  pointer-events: none;
}

.login-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10001; /* higher than page-loader (9999) */
  filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  width: 90%;
  max-width: 360px;
  transform-style: preserve-3d; /* force new stacking context */
}
.stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  width: 100%;
}

@media (max-width: 600px) {
  .stepper {
    grid-template-columns: repeat(2, 1fr);
  }
}

.stepper-tab {
  border: 1px solid var(--panel-border);
  background: var(--panel-bg);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease, opacity 0.2s ease;
}

.stepper-tab.active {
  box-shadow: var(--glow);
  background: rgba(67, 162, 255, 0.12);
  transform: translateY(-1px);
}

.stepper-tab.disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.step-content {
  width: 100%;
}

.action-center {
  display: flex;
  justify-content: center;
  margin-top: 10px;
  margin-bottom: 6px;
}

#uploadForm {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  align-items: center;
}

.privacy-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  font-size: var(--font-size-body);
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  padding: 10px 12px;
  margin: 10px auto 16px;
  width: min(700px, 100%);
  text-align: center;
}

.note-icon {
  font-size: 1.1rem;
}

label {
  font-weight: 600;
  color: var(--text);
  font-size: var(--font-size-label);
}

.file-drop {
  position: relative;
  display: grid;
  place-items: center;
  width: min(700px, 100%);
  min-height: 240px;
  padding: 22px 18px;
  border-radius: 18px;
  border: 2px dashed var(--drop-border);
  background: linear-gradient(120deg, rgba(67, 162, 255, 0.08), transparent 60%), var(--drop-bg);
  color: var(--text);
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.15s ease, box-shadow 0.25s ease, background 0.3s ease;
}

.file-drop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(79, 70, 229, 0.16), transparent 35%);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.file-drop:hover {
  border-color: rgba(67, 162, 255, 0.9);
  transform: translateY(-1px);
  box-shadow: var(--glow);
  background: linear-gradient(120deg, rgba(67, 162, 255, 0.12), transparent 60%), var(--drop-bg);
}

.file-drop:hover::after {
  opacity: 1;
}

.file-drop:focus-within {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

.file-drop-text {
  display: grid;
  gap: 6px;
  text-align: center;
}

.file-drop-title {
  font-weight: 800;
  font-size: var(--font-size-body);
  text-transform: none;
  letter-spacing: 0;
}

.file-drop-file {
  color: var(--muted);
  font-size: var(--font-size-label);
}

.file-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.btn-primary {
  align-self: center;
  border: none;
  padding: 10px 22px;
  min-height: var(--button-height);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
  font-size: var(--font-size-button);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(67, 162, 255, 0.28);
  transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-primary:hover {
  box-shadow: 0 16px 40px rgba(79, 70, 229, 0.32);
  filter: brightness(1.04);
}

.btn-primary:active {
  transform: translateY(1px);
}

.btn-primary:disabled,
.btn-secondary:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  box-shadow: none;
  transform: none;
  filter: none;
}

.btn-secondary {
  align-self: flex-start;
  border: 1px dashed rgba(67, 162, 255, 0.5);
  padding: 10px 16px;
  min-height: var(--button-height);
  border-radius: 12px;
  background: rgba(67, 162, 255, 0.08);
  color: var(--text);
  font-size: var(--font-size-button);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-secondary:hover:not(:disabled) {
  box-shadow: var(--glow);
  background: rgba(79, 70, 229, 0.12);
}

.btn-secondary:active {
  transform: translateY(1px);
}

.ipfs-panel {
  width: 100%;
  border: 1px dashed var(--drop-border);
  border-radius: 16px;
  padding: 16px;
  background: var(--panel-bg);
  display: grid;
  gap: 10px;
}

.ipfs-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.ipfs-panel h3 {
  margin: 0;
  font-size: var(--font-size-section);
}

.ipfs-status {
  margin: 0;
  color: var(--muted);
  font-size: var(--font-size-status);
  line-height: 1.5;
}

.chain-panel {
  width: 100%;
  border: 1px dashed var(--drop-border);
  border-radius: 16px;
  padding: 16px;
  background: var(--panel-bg);
  display: grid;
  gap: 10px;
}

.certificate-action-box {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
  margin-top: 1rem;
  margin-bottom: 1rem;
}

.certificate-action-box .wallet-status {
  margin: 0;
  font-weight: 500;
}

.chain-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.chain-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.wallet-status {
  color: var(--muted);
  font-size: var(--font-size-status);
  font-weight: 600;
}

.chain-note {
  margin: 0;
  color: var(--muted);
}

.balance-warning {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(245, 158, 11, 0.45);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.22), rgba(251, 191, 36, 0.05));
  color: var(--text);
}

.balance-warning__content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1 1 240px;
}

.balance-warning__icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.2);
  color: #92400e;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.balance-warning__text {
  display: grid;
  gap: 2px;
  font-size: var(--font-size-body);
}

.balance-warning__text strong {
  font-weight: 700;
}

.balance-warning__link {
  color: var(--accent-strong);
  font-weight: 700;
  text-decoration: none;
}

.balance-warning__link:hover {
  text-decoration: underline;
}

:root[data-theme="dark"] .balance-warning {
  border-color: rgba(251, 191, 36, 0.32);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.14), rgba(251, 191, 36, 0.04));
}

:root[data-theme="dark"] .balance-warning__icon {
  background: rgba(251, 191, 36, 0.16);
  color: #fbbf24;
}

.tx-link {
  color: var(--accent-strong);
  font-weight: 700;
  text-decoration: none;
  word-break: break-all;
}

.tx-link:hover {
  text-decoration: underline;
}

.input {
  width: 100%;
  padding: 10px 12px;
  min-height: 44px;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: var(--panel-bg);
  color: var(--text);
  font-size: var(--font-size-body);
}

.result {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
  display: grid;
  gap: 10px;
}

.result:not(.hidden),
.error:not(.hidden) {
  animation: floatIn 0.32s ease;
}

.result h2 {
  margin: 0 0 4px;
  font-size: var(--font-size-section);
}

.result p {
  margin: 0;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.result span, .result code {
  word-break: break-all;
}

.result strong {
  color: var(--text);
  font-weight: 700;
}

.hash-box {
  margin-top: 6px;
  padding: 14px;
  border: 1px dashed var(--drop-border);
  border-radius: 14px;
  background: var(--hash-bg);
  color: var(--text);
  display: grid;
  gap: 6px;
  width: 100%;
}

.hash-box code {
  font-family: "JetBrains Mono", "SFMono-Regular", Menlo, Consolas, monospace;
  word-break: break-all;
  color: var(--text);
  font-size: var(--font-size-body);
  line-height: 1.5;
  background: rgba(0, 0, 0, 0.04);
  padding: 10px 12px;
  border-radius: 10px;
}

/* Verification Result Styles */
.verify-panel {
  display: grid;
  gap: 20px;
  width: 100%;
  max-width: 100%;
}

.verify-action-box {
  display: grid;
  gap: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  padding: 20px;
  border-radius: 16px;
}

.verify-input-group {
  display: grid;
  gap: 8px;
}

.verify-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.verify-result {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  padding: 20px;
  display: grid;
  gap: 16px;
  animation: floatIn 0.3s ease-out;
  max-width: 100%;
  overflow-x: hidden;
}

.verify-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}

.verify-result-header h4 {
  margin: 0;
  font-size: 1.1rem;
}

.verify-badge {
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.verify-badge.verified {
  background: #10b98120;
  color: #10b981;
  border: 1px solid #10b98140;
}

.verify-badge.not-verified {
  background: #ef444420;
  color: #ef4444;
  border: 1px solid #ef444440;
}

.verify-result-content {
  display: grid;
  gap: 12px;
}

.verify-result-content p {
  margin: 0;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

@media (max-width: 600px) {
  .verify-result-content p {
    flex-direction: column;
    gap: 4px;
  }
}

.verify-result-content strong {
  font-size: 0.8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.verify-result-content span,
.verify-result-content code {
  word-break: break-all;
  font-size: 0.95rem;
  color: var(--text);
}

.verify-result-content code {
  background: rgba(0, 0, 0, 0.03);
  padding: 4px 8px;
  border-radius: 6px;
  font-family: inherit;
}

:root[data-theme="dark"] .verify-result-content code {
  background: rgba(255, 255, 255, 0.05);
}

/* Pricing Section Styles */
.pricing-section {
  margin: 3rem 0;
}

.pricing-inner {
  width: min(1180px, 92vw);
  margin: 0 auto;
  padding: 2rem 0;
}

.pricing-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.pricing-card {
  background: var(--panel-bg);
  border-radius: var(--card-radius);
  border: 1px solid var(--panel-border);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative; /* Added positioning context */
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--glow);
}

.pricing-card--pro {
  border: 1px solid rgba(67, 162, 255, 0.4);
}

.pricing-card--premium {
  border: 1px solid rgba(124, 58, 237, 0.4);
}

.pricing-price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent-strong);
  margin: 1rem 0;
}

.price-period {
  font-size: 1rem;
  color: var(--muted);
  font-weight: 500;
}

.pricing-features {
  flex-grow: 1;
  padding-left: 0;
  margin: 1rem 0;
}

.pricing-features li {
  list-style: none;
  margin-bottom: 0.5rem;
  padding-left: 1.5rem;
  position: relative;
}

.pricing-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* Most Popular Badge */
.popular-badge {
  position: absolute;
  top: -0.75rem;
  right: 1.5rem;
  background: var(--accent);
  color: white;
  padding: 0.25rem 1rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.plan-button {
  margin-top: auto;
  width: 100%;
  display: block;
  text-align: center;
}

.upgrade-btn {
  text-transform: none;
  letter-spacing: normal;
  font-weight: 700;
}

@media (max-width: 720px) {
  .pricing-cards {
    grid-template-columns: 1fr;
  }
  
  .pricing-card {
    padding: 1.5rem;
  }
  
  .pricing-price {
    font-size: 1.75rem;
  }
}
:root[data-theme="dark"] .hash-box code {
  background: rgba(255, 255, 255, 0.04);
}

.admin-section {
  padding: clamp(22px, 3vw, 30px);
  background: radial-gradient(120% 120% at 10% 0%, rgba(67, 162, 255, 0.14) 0%, transparent 38%),
    radial-gradient(120% 120% at 90% 0%, rgba(13, 75, 163, 0.12) 0%, transparent 44%), var(--card-bg);
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

:root[data-theme="dark"] .admin-section {
  background: radial-gradient(120% 120% at 10% 0%, rgba(67, 162, 255, 0.16) 0%, transparent 38%),
    radial-gradient(120% 120% at 90% 0%, rgba(67, 162, 255, 0.12) 0%, transparent 44%),
    linear-gradient(180deg, #0f1624 0%, #0b111c 100%);
  border-color: rgba(255, 255, 255, 0.1);
}

.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
}

.admin-head__text {
  display: grid;
  gap: 8px;
  max-width: 520px;
}

.eyebrow {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 800;
  color: var(--accent-strong);
}

.admin-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border-radius: 999px;
  font-size: var(--font-size-status);
  font-weight: 700;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.64);
  color: var(--text);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

:root[data-theme="dark"] .status-pill {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
}

.status-pill::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.8;
}

.status-pill--hash {
  color: #2563eb;
  background: rgba(37, 99, 235, 0.08);
}

.status-pill--ipfs {
  color: #0ea5e9;
  background: rgba(14, 165, 233, 0.08);
}

.status-pill--chain {
  color: #16a34a;
  background: rgba(22, 163, 74, 0.08);
}

.status-pill--verified {
  color: #7c3aed;
  background: rgba(124, 58, 237, 0.08);
}

.status-pill--error {
  color: #dc2626;
  background: rgba(220, 38, 38, 0.08);
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
  min-width: 280px;
}

.stat-card {
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--panel-border);
  background: var(--panel-bg);
  display: grid;
  gap: 4px;
  min-height: 108px;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
}

.stat-card strong {
  font-size: 26px;
  line-height: 1.1;
  color: var(--text);
}

.stat-label {
  margin: 0;
  color: var(--muted);
  font-size: var(--font-size-label);
  letter-spacing: 0.02em;
  font-weight: 700;
}

.stat-hint {
  color: var(--muted);
  font-size: var(--font-size-status);
}

:root[data-theme="dark"] .stat-card {
  background: linear-gradient(180deg, rgba(34, 45, 64, 0.9), rgba(18, 26, 38, 0.95));
  border-color: rgba(255, 255, 255, 0.08);
}

.admin-table {
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  background: var(--panel-bg);
  overflow: hidden;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.08);
}

.admin-table__scroll {
  overflow-x: auto;
}

.admin-table__head {
  display: grid;
  grid-template-columns: 0.9fr 0.7fr 1fr 1fr 1fr;
  gap: 10px;
  padding: 12px 14px;
  font-weight: 800;
  background: linear-gradient(90deg, rgba(67, 162, 255, 0.1), rgba(67, 162, 255, 0.04));
  border-bottom: 1px solid var(--panel-border);
  min-width: 840px;
}

.admin-table__head span {
  font-size: var(--font-size-label);
  color: var(--text);
}

:root[data-theme="dark"] .admin-table__head {
  background: linear-gradient(90deg, rgba(67, 162, 255, 0.18), rgba(67, 162, 255, 0.08));
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.admin-table__body {
  display: flex;
  flex-direction: column;
  min-width: 840px;
}

:root[data-theme="dark"] .admin-table {
  background: linear-gradient(180deg, rgba(14, 18, 26, 0.96), rgba(9, 13, 22, 0.96));
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.5);
}

.record-row {
  display: grid;
  grid-template-columns: 0.9fr 0.7fr 1fr 1fr 1fr;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--panel-border);
  align-items: center;
}

:root[data-theme="dark"] .record-row {
  border-bottom-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
}

:root[data-theme="dark"] .record-row:nth-child(odd) {
  background: rgba(255, 255, 255, 0.04);
}

.record-cell {
  font-size: var(--font-size-body);
  color: var(--text);
  display: grid;
  gap: 6px;
  align-content: center;
}

:root[data-theme="dark"] .record-cell,
:root[data-theme="dark"] .record-file,
:root[data-theme="dark"] .record-link,
:root[data-theme="dark"] .record-meta {
  color: #e2e8f0;
}

.admin-table__body {
  display: flex;
  flex-direction: column;
  min-width: 840px;
}

.record-row:last-child {
  border-bottom: none;
}

.record-cell {
  font-size: var(--font-size-body);
  color: var(--text);
  display: grid;
  gap: 6px;
  align-content: center;
}

.record-cell--file {
  gap: 2px;
}

.record-file {
  font-weight: 800;
  color: var(--text);
  word-break: break-word;
}

.record-meta {
  color: var(--muted);
  font-size: var(--font-size-status);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.record-chip {
  padding: 4px 8px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.04);
  color: var(--muted);
  font-weight: 700;
  font-size: var(--font-size-status);
}

.record-link {
  color: var(--accent-strong);
  text-decoration: none;
  font-weight: 700;
  word-break: break-all;
}

.record-link:hover {
  text-decoration: underline;
}

.admin-empty {
  padding: 16px;
  text-align: center;
  color: var(--muted);
  font-weight: 700;
}

:root[data-theme="dark"] .record-chip {
  background: rgba(255, 255, 255, 0.04);
}

.admin-page {
  padding-top: 28px;
}

.admin-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.admin-hero__brand {
  display: flex;
  gap: 12px;
  align-items: center;
}

.admin-hero__brand img {
  height: 64px;
  width: auto;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.8);
  padding: 10px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.admin-toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: flex-end;
}

#refreshBtn {
  align-self: end;
}

.toolbar-field {
  display: grid;
  gap: 4px;
  font-size: var(--font-size-label);
  color: var(--muted);
}

.admin-page #rowLimit.input {
  color: #e6edf7;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
}

.admin-page .input {
  color: #e6edf7;
  background: rgba(15, 19, 30, 0.8);
  border-color: rgba(255, 255, 255, 0.12);
}

.admin-page .input::placeholder {
  color: #94a3b8;
}

.admin-page {
  background: radial-gradient(120% 120% at 50% 0%, rgba(25, 118, 210, 0.18), transparent 48%),
    radial-gradient(120% 120% at 20% 20%, rgba(67, 162, 255, 0.12), transparent 40%),
    #0c121d;
  color: #e6edf7;
}

.admin-page .admin-section {
  background: linear-gradient(180deg, rgba(18, 24, 35, 0.96) 0%, rgba(12, 18, 28, 0.98) 100%);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.55);
  padding: 0px;
}

.admin-page .admin-head__text h2,
.admin-page .admin-head__text .subtitle {
  color: #e6edf7;
}

.admin-page .admin-legend .status-pill {
  background: rgba(30, 41, 59, 0.8);
  border-color: rgba(255, 255, 255, 0.08);
  color: #c7d2fe;
}

.admin-page .stat-card {
  background: linear-gradient(180deg, rgba(26, 35, 52, 0.94), rgba(13, 19, 30, 0.96));
  border-color: rgba(255, 255, 255, 0.12);
  color: #e6edf7;
}

.admin-page .stat-label,
.admin-page .stat-hint {
  color: #cbd5e1;
}

.admin-page .admin-table {
  background: linear-gradient(180deg, rgba(15, 19, 30, 0.95), rgba(10, 14, 22, 0.97));
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
}

.admin-page .admin-table__head {
  background: linear-gradient(90deg, rgba(67, 162, 255, 0.26), rgba(67, 162, 255, 0.14));
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.admin-page .admin-table__head span {
  color: #f8fafc;
}

.admin-page .record-row {
  background: rgba(255, 255, 255, 0.02);
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.admin-page .record-row:nth-child(odd) {
  background: rgba(255, 255, 255, 0.05);
}

.admin-page .record-cell,
.admin-page .record-file,
.admin-page .record-link,
.admin-page .record-meta {
  color: #e6edf7;
}

.admin-page .record-link {
  color: #7cb7ff;
}

.admin-page .admin-empty {
  color: #cbd5e1;
}

/* Copyable text and copy button styles */
.copyable-text {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.copyable-text:hover {
  background-color: rgba(67, 162, 255, 0.1);
}

.text-truncated {
  display: inline;
  word-break: break-all;
}

.text-full {
  display: none;
  word-break: break-all;
}

.copyable-text:hover .text-truncated {
  display: none;
}

.copyable-text:hover .text-full {
  display: inline;
}

.copy-btn {
  background: none;
  border: none;
  padding: 4px 6px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  opacity: 0.7;
  transition: opacity 0.2s ease, background-color 0.2s ease;
  min-width: 28px;
  min-height: 28px;
  display: grid;
  place-items: center;
}

.copy-btn:hover {
  opacity: 1;
  background-color: rgba(67, 162, 255, 0.2);
}

.copy-btn.copied {
  background-color: rgba(34, 197, 94, 0.2);
  color: #16a34a;
  opacity: 1;
}

.record-cell--hash,
.record-cell--note {
  position: relative;
}

.record-cell--hash .copy-btn,
.record-cell--note .copy-btn {
  position: static;
  margin-left: 4px;
}

.record-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.record-link .text-truncated {
  display: inline;
}

.record-link .text-full {
  display: none;
}

.record-link:hover .text-truncated {
  display: none;
}

.record-link:hover .text-full {
  display: inline;
}

.admin-page .translations-section {
  padding: clamp(22px, 3vw, 30px);
}

.translations-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.translations-actions--bottom {
  justify-content: flex-end;
}

.translations-status {
  margin: 0;
  min-height: 18px;
  font-size: var(--font-size-status);
  color: var(--muted);
}

.translations-status.is-success {
  color: #16a34a;
}

.translations-status.is-error {
  color: #dc2626;
}

.admin-page .translations-status {
  color: #cbd5e1;
}

.admin-page .translations-status.is-success {
  color: #4ade80;
}

.admin-page .translations-status.is-error {
  color: #f87171;
}

.translations-table {
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  background: var(--panel-bg);
  overflow: hidden;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.08);
}

.translations-table__scroll {
  overflow-x: auto;
}

.translations-table__head {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  font-weight: 800;
  background: linear-gradient(90deg, rgba(67, 162, 255, 0.1), rgba(67, 162, 255, 0.04));
  border-bottom: 1px solid var(--panel-border);
  min-width: 840px;
}

.translations-table__head span {
  font-size: var(--font-size-label);
  color: var(--text);
}

.translations-table__body {
  display: flex;
  flex-direction: column;
  min-width: 840px;
}

.translations-row {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--panel-border);
  align-items: start;
}

.translations-row:last-child {
  border-bottom: none;
}

.translations-row.is-hidden {
  display: none;
}

.translations-cell {
  display: grid;
  gap: 6px;
}

.translations-cell--key {
  font-weight: 700;
  color: var(--text);
  word-break: break-word;
}

.translations-input {
  width: 100%;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: var(--panel-bg);
  color: var(--text);
  font-size: var(--font-size-body);
  resize: vertical;
  overflow: hidden;
}

.translations-input:focus {
  outline: none;
  border-color: rgba(67, 162, 255, 0.6);
  box-shadow: var(--glow);
}

.admin-page .translations-table {
  background: linear-gradient(180deg, rgba(15, 19, 30, 0.95), rgba(10, 14, 22, 0.97));
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
}

.admin-page .translations-table__head {
  background: linear-gradient(90deg, rgba(67, 162, 255, 0.26), rgba(67, 162, 255, 0.14));
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.admin-page .translations-table__head span {
  color: #f8fafc;
}

.admin-page .translations-row {
  background: rgba(255, 255, 255, 0.02);
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.admin-page .translations-row:nth-child(odd) {
  background: rgba(255, 255, 255, 0.05);
}

.admin-page .translations-cell--key {
  color: #e6edf7;
}

.admin-page .translations-input {
  background: rgba(15, 19, 30, 0.8);
  border-color: rgba(255, 255, 255, 0.12);
  color: #e6edf7;
}

#translationsReloadBtn {
  align-self: unset;
}

@media (max-width: 720px) {
  .admin-page {
    padding: 18px 0px 40px;
  }

  .admin-hero {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .admin-hero__brand {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-hero__brand img {
    margin-bottom: 6px;
  }

  .admin-toolbar {
    width: 100%;
    justify-content: flex-start;
  }

  .admin-page .admin-section {
    padding: 16px 14px;
  }

  .admin-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-stats {
    width: 100%;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }

  .admin-table__head,
  .admin-table__body {
    min-width: 720px;
  }
}
.error {
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

:root[data-theme="dark"] .error {
  background: rgba(239, 68, 68, 0.14);
  color: #fecdd3;
  border-color: rgba(239, 68, 68, 0.32);
}

.hidden {
  display: none;
}

.footer {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
  animation: floatIn 0.65s ease 0.08s both;
}

.info-section {
  margin-top: 32px;
  padding: clamp(30px, 4vw, 44px) 0;
  background: linear-gradient(135deg, #0d4ba3, #0b74d3);
  color: #e9f4ff;
  position: relative;
  overflow: hidden;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  box-shadow: 0 -6px 30px rgba(0, 0, 0, 0.28);
}

.info-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.22) 0, transparent 45%),
    radial-gradient(circle at 80% 40%, rgba(0, 0, 0, 0.18) 0, transparent 42%);
  opacity: 0.7;
}

.info-inner {
  width: min(1100px, 92vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  align-items: center;
  gap: clamp(18px, 4vw, 32px);
  position: relative;
  z-index: 1;
}

.info-text h2 {
  margin: 0 0 12px;
  letter-spacing: 0.02em;
  font-size: var(--font-size-section);
  color: #e9f4ff;
}

.info-text p {
  margin: 0;
  color: rgba(233, 244, 255, 0.92);
  line-height: 1.7;
  font-size: var(--font-size-body);
}

.info-visual {
  justify-self: center;
  width: clamp(180px, 26vw, 260px);
  aspect-ratio: 1;
  position: relative;
  overflow: hidden;
}

.info-visual__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.chain-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-weight: 700;
  margin-top: 10px;
}

.trust-visual {
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.04) 70%),
    conic-gradient(from 60deg, rgba(255, 255, 255, 0.24), rgba(0, 0, 0, 0.12), rgba(255, 255, 255, 0.24));
}

.footer {
  margin-top: 12px;
  padding: 16px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
  animation: floatIn 0.65s ease 0.08s both;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  align-items: center;
  justify-items: center;
}

.footer-item {
  display: flex;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: var(--font-size-body);
}

.footer-links {
  gap: 12px;
}

.footer a {
  color: var(--accent-strong);
  text-decoration: none;
}

.footer a:hover {
  text-decoration: underline;
}

@media (min-width: 720px) {
  .header {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
  }

  .card {
    padding: 30px;
  }
}

@media (max-width: 720px) {
  .topbar {
    padding: 10px 14px;
  }

  .topbar-inner {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    gap: 10px;
    align-items: center;
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
  }

  .brand {
    font-size: 14px;
    gap: 8px;
  }

  .brand img {
    width: 90%;
  }

  .topnav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .topnav a {
    font-size: 13px;
    padding: 2px 0;
    white-space: nowrap;
  }

  .topbar-actions {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    gap: 6px;
  }

  .lang-switcher {
    padding: 4px 4px 4px 10px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
  }

  .lang-select {
    font-size: 13px;
    min-width: 84px;
    padding: 4px 26px 4px 6px;
  }

  .theme-toggle {
    padding: 6px 10px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
  }
}

/* Login modal styles */
.login-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: grid;
  place-items: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

.login-modal:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

.login-modal__content {
  background: var(--surface);
  border-radius: var(--card-radius);
  padding: 24px;
  width: min(400px, 90vw);
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
}

.login-modal__content h2 {
  margin: 0;
  font-size: var(--font-size-section);
  color: var(--text);
  text-align: center;
}

.login-modal__content p {
  margin: 0;
  color: var(--muted);
  text-align: center;
}

.form-input {
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel-bg);
  color: var(--text);
  font-size: var(--font-size-body);
  width: 100%;
}

/* Fix for autofill background color inconsistency between LTR and RTL */
.form-input:-webkit-autofill,
.form-input:-webkit-autofill:hover,
.form-input:-webkit-autofill:focus,
.form-input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 30px var(--panel-bg) inset !important;
  -webkit-text-fill-color: var(--text) !important;
  background-color: var(--panel-bg) !important;
  background-image: none !important;
  color: var(--text) !important;
}

/* Ensure consistent focus styles for both LTR and RTL */
.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(29, 126, 222, 0.15);
}

/* Login step styles */
.login-step__content {
  display: grid;
  gap: 16px;
  text-align: center;
}

.login-step__actions {
  margin-top: 8px;
}

.btn-ghost {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
}

.btn-ghost:hover {
  color: var(--text);
}

.auth-container {
  display: flex;
  gap: 12px;
  align-items: center;
}

.auth-container > * {
  transition: opacity 0.3s ease;
}

.auth-container .hidden {
  display: none;
}

.user-profile {
  display: flex;
  gap: 12px;
  align-items: center;
}

.user-email {
  color: var(--text);
  font-weight: 700;
}

.user-plan-tag {
  background: var(--accent);
  color: white;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: var(--font-size-status);
}
