@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800;900&display=swap');

:root {
  --bg-main: #0a0a0d;
  --bg-card: #13131a;
  --bg-card-hover: #1a1a24;
  --gold-primary: #d4af37;
  --gold-light: #f3e5ab;
  --gold-dark: #aa771c;
  --gold-gradient: linear-gradient(135deg, #bf953f 0%, #fcf6ba 25%, #b38728 50%, #fbf5b7 75%, #aa771c 100%);
  --gold-glow: 0 0 20px rgba(212, 175, 55, 0.25);
  --text-primary: #f8f9fa;
  --text-muted: #9ca3af;
  --border-gold: rgba(212, 175, 55, 0.25);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --danger: #ef4444;
  --success: #10b981;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Cairo', system-ui, -apple-system, sans-serif;
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  direction: rtl;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 20px 16px;
  background-image: radial-gradient(circle at 50% 0%, rgba(212, 175, 55, 0.08) 0%, transparent 70%);
}

.container {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
}

/* Card Component */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 20px;
  padding: 28px 20px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.7), var(--gold-glow);
  margin-bottom: 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gold-gradient);
}

.logo-badge {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid var(--border-gold);
  border-radius: 50px;
  color: var(--gold-primary);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: 1px;
}

h1 {
  font-size: 2rem;
  font-weight: 900;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 12px;
}

h2 {
  font-size: 1.5rem;
  color: var(--gold-primary);
  margin-bottom: 12px;
  font-weight: 800;
}

p.description {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 24px;
}

/* Pricing Box */
.price-box {
  background: rgba(20, 20, 28, 0.8);
  border: 1px solid var(--gold-primary);
  border-radius: 16px;
  padding: 20px 16px;
  margin: 20px 0;
  position: relative;
}

.price-box .title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.price-tag {
  font-size: 3rem;
  font-weight: 900;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
  margin: 10px 0;
}

.features-list {
  text-align: right;
  list-style: none;
  margin: 20px 0;
  padding: 0 10px;
}

.features-list li {
  margin-bottom: 12px;
  color: var(--text-primary);
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.features-list li::before {
  content: "★";
  color: var(--gold-primary);
  font-size: 0.9rem;
}

/* Buttons */
.btn-gold {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 16px;
  background: var(--gold-gradient);
  color: #0d0d11;
  font-weight: 800;
  font-size: 1.1rem;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.3);
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(212, 175, 55, 0.5);
  opacity: 0.95;
}

.btn-secondary {
  display: block;
  width: 100%;
  padding: 12px;
  background: transparent;
  border: 1px solid var(--border-gold);
  color: var(--gold-primary);
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: 10px;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s ease;
  margin-top: 12px;
}

.btn-secondary:hover {
  background: rgba(212, 175, 55, 0.1);
  border-color: var(--gold-primary);
}

.sub-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 12px;
}

/* Form Controls */
.form-group {
  text-align: right;
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.form-group input {
  width: 100%;
  padding: 14px;
  background: #09090c;
  border: 1px solid var(--border-gold);
  border-radius: 10px;
  color: #fff;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.form-group input:focus {
  border-color: var(--gold-primary);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
}

/* Balance Banner */
.balance-card {
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.12) 0%, rgba(19, 19, 26, 0.95) 100%);
  border: 1px solid var(--gold-primary);
}

.balance-title {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

.balance-value {
  font-size: 3.2rem;
  font-weight: 900;
  color: var(--gold-primary);
  margin: 8px 0;
  text-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

.user-badge {
  font-size: 0.82rem;
  color: var(--text-muted);
  word-break: break-all;
}

/* Tasks */
.task-card {
  background: var(--bg-card-hover);
  border: 1px solid var(--border-subtle);
  border-right: 4px solid var(--gold-primary);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  text-align: right;
  transition: transform 0.2s ease;
}

.task-info {
  flex: 1;
}

.task-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.task-reward {
  font-size: 0.8rem;
  color: var(--gold-primary);
  font-weight: 700;
}

.btn-done {
  background: var(--gold-gradient);
  color: #000;
  border: none;
  padding: 8px 20px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.15s ease;
  white-space: nowrap;
}

.btn-done:hover {
  transform: scale(1.05);
}

/* Admin Table */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  margin-top: 15px;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  text-align: center;
}

.admin-table th, .admin-table td {
  padding: 12px 8px;
  border: 1px solid var(--border-gold);
}

.admin-table th {
  background: rgba(212, 175, 55, 0.1);
  color: var(--gold-primary);
  font-weight: 700;
}

.btn-act {
  padding: 6px 12px;
  border-radius: 6px;
  border: none;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  margin: 2px;
}

.btn-vip-on { background: var(--success); color: #fff; }
.btn-vip-off { background: #d97706; color: #fff; }
.btn-reset-task { background: var(--danger); color: #fff; }

.status-box {
  padding: 10px;
  border-radius: 8px;
  font-size: 0.88rem;
  margin-top: 12px;
  display: none;
}

.status-box.error {
  display: block;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid var(--danger);
  color: #fca5a5;
}

.status-box.success {
  display: block;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--success);
  color: #6ee7b7;
}
