/* Sub2API custom theme for sub.feige520.com */
:root {
  --feige-primary: #14b8a6;
  --feige-primary-dark: #0f766e;
  --feige-accent: #2563eb;
  --feige-purple: #8b5cf6;
  --feige-ink: #0f172a;
  --feige-muted: #64748b;
  --feige-card: rgba(255, 255, 255, 0.76);
  --feige-border: rgba(148, 163, 184, 0.22);
  --feige-shadow: 0 24px 70px rgba(15, 23, 42, 0.12);
  --feige-shadow-soft: 0 16px 38px rgba(15, 118, 110, 0.16);
}

html {
  scroll-behavior: smooth;
}

body {
  color: var(--feige-ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 18%, rgba(20, 184, 166, 0.22), transparent 30%),
    radial-gradient(circle at 86% 10%, rgba(37, 99, 235, 0.16), transparent 28%),
    radial-gradient(circle at 82% 84%, rgba(139, 92, 246, 0.14), transparent 28%),
    linear-gradient(135deg, #f8fafc 0%, #eefcf9 42%, #f5f7ff 100%);
}

.dark body::before {
  background:
    radial-gradient(circle at 12% 18%, rgba(20, 184, 166, 0.18), transparent 34%),
    radial-gradient(circle at 86% 10%, rgba(37, 99, 235, 0.18), transparent 30%),
    radial-gradient(circle at 82% 84%, rgba(139, 92, 246, 0.16), transparent 30%),
    linear-gradient(135deg, #020617 0%, #071d22 52%, #0f172a 100%);
}

.bg-gradient-to-br {
  background:
    linear-gradient(rgba(20, 184, 166, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 184, 166, 0.035) 1px, transparent 1px),
    radial-gradient(circle at 16% 20%, rgba(20, 184, 166, 0.18), transparent 34%),
    radial-gradient(circle at 86% 12%, rgba(37, 99, 235, 0.12), transparent 31%),
    linear-gradient(135deg, #f8fafc 0%, #effffb 42%, #f6f8ff 100%) !important;
  background-size: 72px 72px, 72px 72px, auto, auto, auto !important;
}

.dark .bg-gradient-to-br {
  background:
    linear-gradient(rgba(45, 212, 191, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 212, 191, 0.05) 1px, transparent 1px),
    radial-gradient(circle at 16% 20%, rgba(20, 184, 166, 0.16), transparent 34%),
    radial-gradient(circle at 86% 12%, rgba(37, 99, 235, 0.16), transparent 31%),
    linear-gradient(135deg, #020617 0%, #071d22 48%, #111827 100%) !important;
}

.text-gradient,
h1 {
  letter-spacing: -0.045em;
}

.text-gradient {
  background: linear-gradient(135deg, var(--feige-primary-dark), var(--feige-accent), var(--feige-purple)) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  color: transparent !important;
}

.card-glass,
[class*="bg-white/60"],
[class*="bg-white/80"],
[class*="bg-white/40"] {
  border: 1px solid var(--feige-border) !important;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.62)) !important;
  box-shadow: var(--feige-shadow) !important;
  backdrop-filter: blur(20px) saturate(145%) !important;
}

.dark .card-glass,
.dark [class*="dark:bg-dark-800"],
.dark [class*="dark:bg-dark-900"] {
  border-color: rgba(45, 212, 191, 0.16) !important;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.82), rgba(17, 24, 39, 0.62)) !important;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34) !important;
}

[class*="rounded-2xl"],
[class*="rounded-xl"] {
  border-radius: 22px !important;
}

.btn,
button,
a {
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease !important;
}

.btn-primary,
[class*="bg-primary-"],
[class*="from-primary-"] {
  background: linear-gradient(135deg, #2dd4bf 0%, #14b8a6 42%, #2563eb 100%) !important;
  box-shadow: 0 14px 30px rgba(20, 184, 166, 0.30) !important;
}

.btn-primary:hover,
a.btn:hover,
button:hover {
  transform: translateY(-1px);
}

.btn-primary:hover {
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.26) !important;
}

.input,
input,
textarea,
select {
  border-radius: 14px !important;
  border-color: rgba(148, 163, 184, 0.34) !important;
  background: rgba(255, 255, 255, 0.78) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7) !important;
}

.input:focus,
input:focus,
textarea:focus,
select:focus {
  border-color: rgba(20, 184, 166, 0.78) !important;
  box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.14) !important;
  outline: none !important;
}

.terminal-window {
  border: 1px solid rgba(45, 212, 191, 0.18) !important;
  border-radius: 18px !important;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.26), 0 0 0 1px rgba(255, 255, 255, 0.05) inset !important;
}

.terminal-header {
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.96)) !important;
}

.terminal-body {
  background:
    radial-gradient(circle at 90% 0%, rgba(20, 184, 166, 0.08), transparent 36%),
    #111827 !important;
}

.code-success {
  box-shadow: 0 8px 18px rgba(34, 197, 94, 0.22);
}

aside,
[role="complementary"] {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(240, 253, 250, 0.86)) !important;
  border-right: 1px solid rgba(148, 163, 184, 0.2) !important;
  box-shadow: 18px 0 55px rgba(15, 23, 42, 0.06) !important;
  backdrop-filter: blur(18px) saturate(145%) !important;
}

.dark aside,
.dark [role="complementary"] {
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.94), rgba(8, 47, 73, 0.56)) !important;
  border-right-color: rgba(45, 212, 191, 0.12) !important;
}

nav a,
nav button {
  border-radius: 14px !important;
}

nav a:hover,
nav button:hover {
  background: rgba(20, 184, 166, 0.10) !important;
}

header,
[role="banner"] {
  backdrop-filter: blur(16px) saturate(150%);
}

main [class*="shadow"],
main [class*="border"] {
  border-color: rgba(148, 163, 184, 0.20) !important;
}

table {
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

thead {
  background: rgba(20, 184, 166, 0.06) !important;
}

tbody tr {
  transition: background 160ms ease, transform 160ms ease;
}

tbody tr:hover {
  background: rgba(20, 184, 166, 0.055) !important;
}

[role="dialog"],
dialog,
.modal {
  border-radius: 22px !important;
  border: 1px solid rgba(148, 163, 184, 0.24) !important;
  box-shadow: 0 34px 90px rgba(15, 23, 42, 0.24) !important;
}

.navigation-progress-bar {
  background: linear-gradient(90deg, #2dd4bf, #2563eb, #8b5cf6) !important;
}

img[alt="Logo"] {
  filter: drop-shadow(0 12px 22px rgba(20, 184, 166, 0.22));
}

@media (max-width: 768px) {
  .card-glass {
    padding: 1.5rem !important;
  }

  h1 {
    letter-spacing: -0.035em;
  }
}

.feige-recharge-card {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 0 0 24px;
  padding: 22px;
  border: 1px solid rgba(20, 184, 166, 0.22);
  border-radius: 24px;
  background:
    radial-gradient(circle at 92% 10%, rgba(37, 99, 235, 0.14), transparent 28%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(240, 253, 250, 0.78));
  box-shadow: 0 22px 55px rgba(15, 23, 42, 0.10);
  backdrop-filter: blur(18px) saturate(145%);
}

.dark .feige-recharge-card {
  border-color: rgba(45, 212, 191, 0.20);
  background:
    radial-gradient(circle at 92% 10%, rgba(37, 99, 235, 0.18), transparent 28%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.88), rgba(17, 24, 39, 0.66));
}

.feige-recharge-card-icon {
  display: inline-flex;
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  color: white;
  background: linear-gradient(135deg, #2dd4bf, #2563eb);
  box-shadow: 0 16px 32px rgba(20, 184, 166, 0.28);
}

.feige-recharge-card-body {
  flex: 1 1 auto;
  min-width: 0;
}

.feige-recharge-card h3 {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.dark .feige-recharge-card h3 {
  color: #f8fafc;
}

.feige-recharge-card p {
  margin: 0 0 14px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.6;
}

.dark .feige-recharge-card p {
  color: #cbd5e1;
}

.feige-recharge-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px !important;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  background: linear-gradient(135deg, #14b8a6, #2563eb) !important;
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.24) !important;
}

.feige-modal-open {
  overflow: hidden;
}

.feige-recharge-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
}

.feige-recharge-modal.is-open {
  display: block;
}

.feige-recharge-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(10px);
}

.feige-recharge-panel {
  position: absolute;
  inset: 4vh 4vw;
  display: flex;
  min-height: 520px;
  overflow: hidden;
  flex-direction: column;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 32px 100px rgba(0, 0, 0, 0.35);
}

.feige-recharge-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: linear-gradient(135deg, rgba(240, 253, 250, 0.96), rgba(239, 246, 255, 0.96));
}

.feige-recharge-header h2 {
  margin: 0 0 4px;
  color: #0f172a;
  font-size: 18px;
  font-weight: 800;
}

.feige-recharge-header p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
}

.feige-recharge-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}

.feige-recharge-actions a,
.feige-recharge-actions button {
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px !important;
  color: #0f172a;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.82) !important;
  cursor: pointer;
}

.feige-recharge-actions button {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #14b8a6, #2563eb) !important;
}

.feige-recharge-panel iframe {
  width: 100%;
  flex: 1 1 auto;
  border: 0;
  background: #fff;
}

@media (max-width: 768px) {
  .feige-recharge-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .feige-recharge-panel {
    inset: 10px;
    min-height: 80vh;
    border-radius: 20px;
  }

  .feige-recharge-header {
    align-items: flex-start;
    flex-direction: column;
  }
}
