/* ============================================================
   CMP Club · assets/css/components.css
   Botões · Cards · Badges · Inputs · Alerts
   ============================================================ */

/* ── BOTÕES ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  padding: 10px 20px;
  min-height: 44px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: opacity 0.15s;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover   { opacity: 0.85; }
.btn:active  { opacity: 0.7; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

.btn-primary   { background: var(--gold);  color: #111; font-weight: 700; }
.btn-secondary { background: transparent; color: var(--gold); border: 1px solid var(--gold); }
.btn-ghost     { background: transparent; color: var(--gray); border: 1px solid var(--border); }
.btn-danger    { background: transparent; color: var(--red);  border: 1px solid var(--red-bdr); }
.btn-full      { width: 100%; }
.btn-sm        { font-size: 12px; padding: 7px 14px; min-height: 36px; }

/* ── CARDS ────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
}
.card-label {
  font-size: 10px;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.card-title { font-size: 16px; font-weight: 700; color: var(--white); margin-bottom: 4px; }
.card-sub   { font-size: 12px; color: var(--gray); }

/* ── BADGES ───────────────────────────────────────────────── */
.badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 4px;
  white-space: nowrap;
}
.badge-gold  { background: var(--gold-bg);  color: var(--gold);  border: 0.5px solid var(--gold-dim); }
.badge-green { background: var(--green-bg); color: var(--green); border: 0.5px solid var(--green-bdr); }
.badge-red   { background: var(--red-bg);   color: var(--red);   border: 0.5px solid var(--red-bdr); }
.badge-gray  { background: #1E1E1E;          color: var(--gray);  border: 0.5px solid var(--border); }

/* ── INPUTS ───────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 12px; color: var(--gray); font-weight: 500; }

.form-input,
.form-select,
.form-textarea {
  background: var(--surface);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 16px;   /* evita zoom no iOS */
  color: var(--white);
  font-family: 'Inter', sans-serif;
  outline: none;
  width: 100%;
  transition: border-color 0.15s;
  appearance: none;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus { border-color: var(--gold); }
.form-input::placeholder,
.form-textarea::placeholder { color: #555; }

.form-textarea { resize: vertical; min-height: 90px; }

/* ── ALERTS ───────────────────────────────────────────────── */
.alert {
  font-size: 13px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 0.5px solid;
}
.alert-error   { background: var(--red-bg);   color: var(--red);   border-color: var(--red-bdr); }
.alert-success { background: var(--green-bg); color: var(--green); border-color: var(--green-bdr); }
.alert-info    { background: var(--gold-bg);  color: var(--gold);  border-color: var(--gold-dim); }

/* ── PROGRESS BAR ─────────────────────────────────────────── */
.progress-wrap { height: 4px; background: var(--border); border-radius: 2px; }
.progress-fill { height: 4px; border-radius: 2px; background: var(--gold); transition: width 0.3s; }
.progress-fill.green { background: var(--green); }

/* ── CHECKBOX CUSTOM ──────────────────────────────────────── */
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 14px;
  color: var(--gray);
  user-select: none;
}
.checkbox-label input[type="checkbox"] { display: none; }
.checkbox-box {
  width: 20px; height: 20px;
  border: 0.5px solid var(--border);
  border-radius: 4px;
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: border-color 0.15s, background 0.15s;
}
.checkbox-label input:checked + .checkbox-box {
  border-color: var(--gold);
  background: var(--gold-bg);
}
.checkbox-label input:checked + .checkbox-box::after {
  content: '';
  width: 10px; height: 6px;
  border-left: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  transform: rotate(-45deg) translateY(-1px);
}
