/* ===================== GullyReels — App-specific UI ===================== */

/* ---------- Auth screens ---------- */
.auth-shell { min-height: calc(100vh - 74px); display: grid; place-items: center; padding: 48px 20px; }
.auth-card {
  width: 100%; max-width: 560px;
  background: var(--bg-panel); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 38px;
  box-shadow: var(--shadow);
}
.auth-card h1 { font-size: 1.75rem; margin-bottom: 8px; }
.auth-card > p { margin-bottom: 26px; font-size: 0.92rem; }
.auth-switch { margin-top: 20px; font-size: 0.87rem; color: var(--ink-dim); text-align: center; }
.auth-switch a { color: var(--gold); font-weight: 700; }
.auth-error {
  display: none; padding: 12px 15px; border-radius: 11px; margin-bottom: 18px;
  background: rgba(244,63,94,0.12); border: 1px solid rgba(244,63,94,0.35);
  color: #fda4af; font-size: 0.86rem;
}

/* ---------- Dashboard ---------- */
.dash-header {
  display: flex; align-items: center; gap: 20px; flex-wrap: wrap;
  padding: 30px; margin-bottom: 28px;
  background: var(--bg-panel); background-image: var(--grad-panel);
  border: 1px solid var(--line); border-radius: var(--radius);
}
.avatar-circle {
  width: 62px; height: 62px; border-radius: 50%;
  background: var(--grad-hot); color: #14131c;
  display: grid; place-items: center;
  font-size: 1.5rem; font-weight: 900; flex-shrink: 0;
}
.dash-header h2 { margin-bottom: 3px; font-size: 1.4rem; }
.dash-header p { font-size: 0.88rem; margin: 0; }

.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 28px; }
.stat-box {
  background: var(--bg-panel); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 18px;
}
.stat-box .label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-dim); font-weight: 700; margin-bottom: 6px; }
.stat-box .value { font-size: 1.3rem; font-weight: 850; color: var(--ink); }

.dash-section { margin-bottom: 34px; }
.dash-section > h3 {
  font-size: 1.05rem; margin-bottom: 14px; padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.form-section {
  margin-top: 22px; padding-top: 18px; border-top: 1px dashed var(--line);
}
.form-section:first-of-type { margin-top: 0; padding-top: 0; border-top: 0; }
.form-section > h4 {
  font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--gold); margin-bottom: 14px;
}

/* ---------- Rows / lists ---------- */
.list-row {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 15px 18px; margin-bottom: 10px;
  background: var(--bg-panel); border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.list-row strong { font-size: 0.94rem; }
.list-row .sub { font-size: 0.82rem; color: var(--ink-dim); }

.empty-state {
  padding: 34px 24px; text-align: center;
  background: rgba(255,255,255,0.03); border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm); color: var(--ink-dim); font-size: 0.9rem;
}
.empty-state a { color: var(--gold); font-weight: 700; }
.loading-row { padding: 26px; text-align: center; color: var(--ink-faint); font-size: 0.88rem; }

/* ---------- Badges ---------- */
.badge {
  display: inline-block; padding: 4px 12px; border-radius: 100px;
  font-size: 0.72rem; font-weight: 750; letter-spacing: 0.02em;
  text-transform: capitalize; white-space: nowrap;
}
.badge-info    { background: rgba(139,92,246,0.16); color: #c4b5fd; border: 1px solid rgba(139,92,246,0.34); }
.badge-success { background: rgba(45,212,191,0.14);  color: #5eead4; border: 1px solid rgba(45,212,191,0.32); }
.badge-warning { background: rgba(245,181,68,0.15);  color: var(--gold-soft); border: 1px solid rgba(245,181,68,0.34); }
.badge-error   { background: rgba(244,63,94,0.14);   color: #fda4af; border: 1px solid rgba(244,63,94,0.32); }
.badge-neutral { background: rgba(255,255,255,0.07); color: var(--ink-dim); border: 1px solid var(--line); }

/* ---------- Callout ---------- */
.callout {
  padding: 16px 20px; border-radius: var(--radius-sm);
  background: rgba(139,92,246,0.10); border: 1px solid rgba(139,92,246,0.30);
  font-size: 0.88rem; color: var(--ink-soft);
}
.callout.warn { background: rgba(245,181,68,0.10); border-color: rgba(245,181,68,0.32); }
.callout.danger { background: rgba(244,63,94,0.10); border-color: rgba(244,63,94,0.32); }
.callout a { color: var(--gold); font-weight: 700; }

/* ---------- Toggle ---------- */
.toggle-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 18px; background: var(--bg-panel);
  border: 1px solid var(--line); border-radius: var(--radius-sm);
}
.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
  position: absolute; cursor: pointer; inset: 0;
  background: rgba(255,255,255,0.14); border-radius: 100px; transition: background .2s;
}
.switch .slider::before {
  content: ""; position: absolute; height: 20px; width: 20px;
  left: 3px; bottom: 3px; background: #fff; border-radius: 50%; transition: transform .2s;
}
.switch input:checked + .slider { background: var(--gold); }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* ---------- Video embed ---------- */
.embed-wrap {
  position: relative; width: 100%; aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm); overflow: hidden;
  background: #000; border: 1px solid var(--line);
}
.embed-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
  margin-bottom: 26px; padding: 14px 16px;
  background: var(--bg-panel); border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.filter-bar input, .filter-bar select { width: auto; min-width: 170px; padding: 9px 13px; font-size: 0.86rem; }
.filter-bar .spacer { flex: 1; }
.result-count { font-size: 0.82rem; color: var(--ink-dim); }

/* ---------- Milestone timeline ---------- */
.timeline { position: relative; padding-left: 26px; }
.timeline::before {
  content: ""; position: absolute; left: 7px; top: 6px; bottom: 6px;
  width: 2px; background: var(--line-strong);
}
.timeline-item { position: relative; margin-bottom: 18px; }
.timeline-item::before {
  content: ""; position: absolute; left: -23px; top: 7px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--ink-faint);
}
.timeline-item.done::before   { background: var(--teal);    border-color: var(--teal); }
.timeline-item.active::before { background: var(--gold);    border-color: var(--gold); }
.timeline-item.revise::before { background: var(--crimson); border-color: var(--crimson); }

@media (max-width: 760px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .auth-card { padding: 26px; }
  .dash-header { padding: 22px; }
  .list-row { flex-direction: column; align-items: flex-start; }
}
