:root {
  --bg: #050505;
  --bg-surface: rgba(30, 30, 35, 0.5);
  --bg-card: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.08);
  --stroke: rgba(255, 255, 255, 0.1);
  --text: #ffffff !important;
  --muted: rgba(255, 255, 255, 0.5);
  --accent: #0a84ff;
  --accent-text: #ffffff;
  --ok: #32d74b;
  --danger: #ff453a;
  --tab-bg: rgba(20, 20, 25, 0.65);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  /* Liquid glass gradient orbs background */
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(10, 132, 255, 0.15) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(94, 92, 230, 0.15) 0%, transparent 40%);
  background-attachment: fixed;
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow: hidden; 
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0; /* Let full width on mobile, or limited on desktop */
}

.app-shell {
  width: 100%;
  max-width: 500px;
  height: 100dvh;
  border-radius: 0;
  background: transparent;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

/* Animations */
@keyframes floatIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulseGlow {
  0% { box-shadow: 0 0 10px rgba(10, 132, 255, 0.3); }
  50% { box-shadow: 0 0 20px rgba(10, 132, 255, 0.6); }
  100% { box-shadow: 0 0 10px rgba(10, 132, 255, 0.3); }
}

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 20px 16px;
  background: transparent;
  z-index: 10;
  animation: floatIn 0.5s ease forwards;
}

.app-header h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.app-header p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.ghost-btn {
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border-radius: 16px;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.2s;
  backdrop-filter: blur(8px);
}

.ghost-btn:active {
  opacity: 0.7;
  transform: scale(0.95);
}

.content {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 16px 16px 120px; /* space for suspended tabbar */
}

/* Hide scrollbar for clean iOS look */
.content::-webkit-scrollbar {
  display: none;
}

.tab-screen {
  display: none;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

.tab-screen.active {
  display: block;
}

/* CARDS in Glassmorphism */
.card {
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: floatIn 0.5s ease-out forwards;
  opacity: 0; 
  /* So it triggers floatIn */
}

/* Stagger cards animation */
.card:nth-child(1) { animation-delay: 0.05s; }
.card:nth-child(2) { animation-delay: 0.1s; }
.card:nth-child(3) { animation-delay: 0.15s; }
.card:nth-child(4) { animation-delay: 0.2s; }

.hero-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.02) 100%);
  position: relative;
  overflow: hidden;
  border-top: 1px solid rgba(255,255,255,0.2);
}

.hero-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hero-card h2 {
  margin: 10px 0 4px;
  font-size: 24px;
  font-weight: 700;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: 0 0 8px rgba(255,255,255,0.2);
}

.status-dot.ok {
  background: var(--ok);
  box-shadow: 0 0 10px rgba(50, 215, 75, 0.4);
}

.status-dot.fail {
  background: var(--danger);
  box-shadow: 0 0 10px rgba(255, 69, 58, 0.4);
}

.label {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.value {
  margin: 6px 0 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
}

.split-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* TRAFFIC PROGRESS BAR */
.traffic-progress-container {
  margin-top: 16px;
  animation: floatIn 0.3s ease forwards;
}

.traffic-progress-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
}

.traffic-progress-bar {
  height: 8px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.traffic-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--ok);
  border-radius: 6px;
  transition: width 0.8s cubic-bezier(0.2, 0.8, 0.2, 1), background-color 0.4s ease;
  box-shadow: 0 0 10px rgba(50, 215, 75, 0.4);
}

.traffic-progress-fill.yellow {
  background: #ffcc00;
  box-shadow: 0 0 10px rgba(255, 204, 0, 0.4);
}

.traffic-progress-fill.red {
  background: var(--danger);
  box-shadow: 0 0 10px rgba(255, 69, 58, 0.4);
}

.muted {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}

.longtext {
  margin: 8px 0 0;
  white-space: pre-wrap;
  color: #e5e5ea;
  font-size: 14px;
  line-height: 1.6;
}

.mono-line {
  margin: 12px 0 8px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13px;
}

/* BUTTONS */
.button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.button-row.single-column {
  grid-template-columns: 1fr;
}

.button-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.button-row.compact {
  margin-top: 10px;
}

button {
  cursor: pointer;
  outline: none;
  font-family: inherit;
}

.pill {
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08); /* slightly brighter than card */
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  padding: 14px 16px;
  text-align: center;
  transition: transform 0.1s, opacity 0.1s, background 0.2s;
  width: 100%;
  backdrop-filter: blur(8px);
}

/* Add margin when a generic pill sits directly under text inside a card */
.card > .pill {
  margin-top: 16px;
}

.pill:active {
  transform: scale(0.96);
  background: rgba(255, 255, 255, 0.15);
}

.pill.primary {
  background: var(--accent);
  color: var(--accent-text);
  border: none;
  box-shadow: 0 4px 14px rgba(10, 132, 255, 0.4);
}

.pill.danger {
  background: rgba(255, 69, 58, 0.15);
  color: var(--danger);
}

/* PLANS */
.plans-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.plan {
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  padding: 16px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
  text-align: left;
  color: #ffffff;
}

.plan:active {
  transform: scale(0.98);
}

.plan.active {
  border-color: var(--accent);
  background: rgba(10, 132, 255, 0.15);
  box-shadow: 0 0 20px rgba(10, 132, 255, 0.2);
}

.plan-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
}

.plan-sub {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
}

.plan-price {
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
}

.segmented {
  margin-top: 12px;
  display: flex;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.segment {
  flex: 1;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
  padding: 8px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.segment.active {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* INPUTS */
.input-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin-top: 12px;
}

.input-row.input-row-stack {
  grid-template-columns: 1fr;
}

.quick-amounts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.quick-amount {
  padding: 12px 10px;
}

.quick-amount.active {
  border-color: var(--accent);
  background: rgba(10, 132, 255, 0.18);
  box-shadow: 0 0 18px rgba(10, 132, 255, 0.18);
}

input {
  width: 100%;
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.2);
  color: #ffffff;
  padding: 14px 16px;
  font-size: 15px;
  outline: none;
  transition: all 0.2s;
}

input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

input:focus {
  border-color: var(--accent);
  background: rgba(0, 0, 0, 0.4);
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.3);
}

textarea {
  width: 100%;
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.2);
  color: #ffffff;
  padding: 14px 16px;
  font-size: 15px;
  outline: none;
  margin-top: 12px;
  resize: vertical;
  min-height: 110px;
  transition: all 0.2s;
}

textarea:focus {
  border-color: var(--accent);
  background: rgba(0, 0, 0, 0.4);
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.3);
}

select {
  width: 100%;
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.2);
  color: #ffffff;
  padding: 14px 16px;
  font-size: 15px;
  outline: none;
  appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; background-size: 16px;
}

/* LISTS */
.log-list {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.log-item {
  border-radius: 16px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--glass-border);
  font-size: 13px;
  color: #e5e5ea;
  line-height: 1.5;
}

/* ADMIN GRID */
.admin-grid {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.admin-stat {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 12px;
  text-align: center;
}

.admin-stat .k {
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
  font-weight: 500;
}

.admin-stat .v {
  margin-top: 6px;
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
}

.mirror-item-actions {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.partner-box {
  margin-top: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 14px;
  font-size: 14px;
  line-height: 1.5;
  color: #e5e5ea;
}

.partner-application-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.modal-copy {
  margin-top: 10px;
}

/* MODAL */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 100;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.modal-backdrop[hidden] {
  display: none !important;
  opacity: 0;
}

.modal-card {
  width: 100%;
  max-width: 480px;
  max-height: 85dvh;
  border-radius: 28px;
  background: rgba(30, 30, 35, 0.7);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--glass-border);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { transform: translateY(40px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* LOADER */
.loader-card {
  width: 100%;
  max-width: 320px;
  background: rgba(30, 30, 35, 0.7);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--glass-border);
  border-radius: 28px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.loader-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 20px;
}

.loader-card h3 {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 600;
  color: #fff;
}

.loader-progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
}

.loader-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  border-radius: 6px;
  transition: width 0.1s linear;
  box-shadow: 0 0 10px rgba(10, 132, 255, 0.4);
}

.loader-percent {
  margin: 12px 0 0;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px 12px;
  background: transparent;
  z-index: 2;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.modal-head h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

.modal-close {
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: transform 0.2s;
}
.modal-close:active { transform: scale(0.9); }

.modal-scroll {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 16px 20px 20px;
}

.modal-inner-card {
  background: transparent;
  border: none;
  padding: 0;
  box-shadow: none;
  margin-bottom: 24px;
}

.modal-card input[readonly] {
  opacity: 0.7;
}

/* TABBAR - FLOATING LIQUID GLASS */
.tabbar {
  position: absolute;
  bottom: 24px;
  left: 16px;
  right: 16px;
  display: flex;
  justify-content: space-around;
  padding: 8px 8px;
  background: rgba(20, 20, 25, 0.6);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
  z-index: 10;
  animation: floatIn 0.5s ease-out forwards;
}

.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.5);
  font-size: 11px;
  font-weight: 500;
  padding: 10px 4px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  border-radius: 20px;
  position: relative;
}

/* Dot indicator for active tab */
.tab::after {
  content: '';
  position: absolute;
  top: 4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  transform: translateY(4px);
}

.tab::before {
  content: '';
  display: block;
  width: 24px;
  height: 24px;
  margin-bottom: 4px;
  border-radius: 6px;
  background-color: currentColor;
  opacity: 0.8;
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  transition: all 0.3s;
}

/* Fallback icons via CSS masks */
.tab[data-tab-target="home"]::before {
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M12 3L4 9V21H9V14H15V21H20V9L12 3Z" fill="currentColor"/></svg>');
}
.tab[data-tab-target="plans"]::before {
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20 4H4C2.89 4 2.01 4.89 2.01 6L2 18C2 19.11 2.89 20 4 20H20C21.11 20 22 19.11 22 18V6C22 4.89 21.11 4 20 4ZM20 18H4V12H20V18ZM20 8H4V6H20V8Z" fill="currentColor"/></svg>');
}
.tab[data-tab-target="balance"]::before {
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21 18V19C21 20.1 20.1 21 19 21H5C3.89 21 3 20.1 3 19V5C3 3.9 3.89 3 5 3H19C20.1 3 21 3.9 21 5V6H12C10.89 6 10 6.9 10 8V16C10 17.1 10.89 18 12 18H21ZM12 16H22V8H12V16ZM16 13.5C15.17 13.5 14.5 12.83 14.5 12C14.5 11.17 15.17 10.5 16 10.5C16.83 10.5 17.5 11.17 17.5 12C17.5 12.83 16.83 13.5 16 13.5Z" fill="currentColor"/></svg>');
}
.tab[data-tab-target="partners"]::before {
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M16 11C17.66 11 18.99 9.66 18.99 8C18.99 6.34 17.66 5 16 5C14.34 5 13 6.34 13 8C13 9.66 14.34 11 16 11ZM8 11C9.66 11 10.99 9.66 10.99 8C10.99 6.34 9.66 5 8 5C6.34 5 5 6.34 5 8C5 9.66 6.34 11 8 11ZM8 13C5.67 13 1 14.17 1 16.5V19H15V16.5C15 14.17 10.33 13 8 13ZM16 13C15.71 13 15.38 13.02 15.03 13.05C16.19 13.89 17 15.02 17 16.5V19H23V16.5C23 14.17 18.33 13 16 13Z" fill="currentColor"/></svg>');
}
.tab[data-tab-target="admin"]::before {
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M19.14,12.94c0.04-0.3,0.06-0.61,0.06-0.94c0-0.32-0.02-0.64-0.06-0.94l2.03-1.58c0.18-0.14,0.23-0.41,0.12-0.61 l-1.92-3.32c-0.12-0.22-0.37-0.29-0.59-0.22l-2.39,0.96c-0.5-0.38-1.03-0.7-1.62-0.94L14.4,2.81c-0.04-0.24-0.24-0.41-0.48-0.41 h-3.84c-0.24,0-0.43,0.17-0.47,0.41L9.25,5.35C8.66,5.59,8.12,5.92,7.63,6.29L5.24,5.33c-0.22-0.08-0.47,0-0.59,0.22L2.73,8.87 C2.62,9.08,2.66,9.34,2.86,9.48l2.03,1.58C4.84,11.36,4.8,11.69,4.8,12s0.02,0.64,0.06,0.94l-2.03,1.58 c-0.18,0.14-0.23,0.41-0.12,0.61l1.92,3.32c0.12,0.22,0.37,0.29,0.59,0.22l2.39-0.96c0.5,0.38,1.03,0.7,1.62,0.94l0.36,2.54 c0.05,0.24,0.24,0.41,0.48,0.41h3.84c0.24,0,0.43-0.17,0.47-0.41l0.36-2.54c0.59-0.24,1.13-0.56,1.62-0.94l2.39,0.96 c0.22,0.08,0.47,0,0.59-0.22l1.92-3.32c0.12-0.22,0.07-0.49-0.12-0.61L19.14,12.94z M12,15.6c-1.98,0-3.6-1.62-3.6-3.6 s1.62-3.6,3.6-3.6s3.6,1.62,3.6,3.6S13.98,15.6,12,15.6z" fill="currentColor"/></svg>');
}

/* Active tab styles */
.tab.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.tab.active::after {
  opacity: 1;
  transform: translateY(0);
}

.tab.active::before {
  opacity: 1;
}

.tab[hidden] {
  display: none !important;
}

@media (max-width: 520px) {
  body {
    padding: 0;
  }

  .app-shell {
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
    border: none;
    box-shadow: none;
  }

  .admin-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}


/* Custom Toast Notifications */
.toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 99999;
  pointer-events: none;
  width: 90%;
  max-width: 400px;
}

.toast {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  color: #fff;
  padding: 12px 20px;
  border-radius: 12px;
  font-weight: 500;
  font-size: 14px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  animation: floatIn 0.3s ease-out forwards;
  transition: opacity 0.4s ease, transform 0.4s ease;
  pointer-events: auto;
}

.toast.fade-out {
  animation: fadeOutToast 0.4s ease-in forwards;
}

@keyframes fadeOutToast {
  to {
    opacity: 0;
    transform: translateY(-20px);
  }
}


/* Admin Mirror Cards */
.mirror-admin-card { display: flex; flex-direction: column; gap: 12px; }
.mirror-admin-header { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 15px; color: var(--text-main); }
.mirror-admin-username { display: flex; align-items: center; gap: 8px; }
.mirror-admin-username svg { width: 18px; height: 18px; color: var(--brand-blue); }
.mirror-admin-badge { font-size: 11px; padding: 4px 8px; border-radius: 8px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.mirror-admin-badge.active { background: rgba(48, 209, 88, 0.15); color: #30d158; }
.mirror-admin-badge.paused { background: rgba(255, 69, 58, 0.15); color: #ff453a; }
.mirror-admin-badge.stopped { background: rgba(255, 159, 10, 0.15); color: #ff9f0a; }
.mirror-admin-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.mirror-admin-stat { display: flex; align-items: center; gap: 8px; background: rgba(255, 255, 255, 0.05); padding: 8px 12px; border-radius: 12px; font-size: 13px; color: var(--text-sec); }
.mirror-admin-stat svg { width: 16px; height: 16px; opacity: 0.6; }
.mirror-item-actions { margin-top: 4px !important; margin-bottom: 4px; }


/* Select Overrides */
select option { background: #1a1a1e; color: #fff; padding: 12px; }
select:focus { border-color: var(--accent); background-color: rgba(0, 0, 0, 0.4); box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.3); }
.editor-hints { font-size: 13px; color: rgba(255,255,255,0.5); margin: 6px 0 12px; display: block; }



/* Partner Bot Overrides */
.partner-box.mirror-admin-card { padding: 0; background: transparent; border: none; margin-top: 16px; margin-bottom: 20px; }
.partner-box .mirror-admin-stats { grid-template-columns: 1fr; gap: 10px; margin-top: 18px; }
.partner-box .mirror-admin-stat { background: rgba(0, 0, 0, 0.2); padding: 12px 14px; border: 1px solid var(--glass-border); justify-content: space-between; font-size: 14px; }
.partner-box .mirror-admin-stat div { display: flex; align-items: center; gap: 10px; }
.partner-box .mirror-admin-stat strong { color: #fff; font-weight: 600; }
