/* Celebrity Wealth Lab — premium financial dashboard UI */
.cwl-app {
  --cwl-bg: #0b1120;
  --cwl-panel: #131c31;
  --cwl-panel-2: #1a2440;
  --cwl-line: #2b3a5c;
  --cwl-text: #f5f8ff;
  --cwl-dim: #b9c6e4;
  --cwl-gold: #ffc94d;
  --cwl-green: #38e0a4;
  --cwl-red: #ff7a7a;
  --cwl-blue: #5aa9ff;
  color: var(--cwl-text);
  background: radial-gradient(1200px 600px at 15% -10%, #1d2c52 0%, transparent 60%), var(--cwl-bg);
  border-radius: 20px;
  padding: clamp(16px, 3vw, 32px);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  line-height: 1.5;
  box-shadow: 0 24px 60px rgba(6, 12, 26, 0.35);
}
.cwl-app *, .cwl-app *::before, .cwl-app *::after { box-sizing: border-box; }
.cwl-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.cwl-hero { text-align: center; padding: 8px 0 20px; }
.cwl-hero-badge {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: #0b1120; background: var(--cwl-gold);
  padding: 5px 12px; border-radius: 999px;
}
.cwl-hero-title { font-size: clamp(26px, 4.4vw, 42px); margin: 14px 0 6px; font-weight: 800; color: #fff; letter-spacing: -.02em; }
.cwl-hero-sub { margin: 0 auto 18px; max-width: 620px; color: var(--cwl-dim); font-size: 15px; }

.cwl-search { display: flex; gap: 10px; max-width: 620px; margin: 0 auto; flex-wrap: wrap; }
.cwl-search-sm { max-width: 100%; margin: 0 0 14px; }
.cwl-input {
  flex: 1 1 240px; min-width: 0; padding: 14px 16px; font-size: 16px;
  background: var(--cwl-panel-2); border: 1px solid var(--cwl-line); border-radius: 12px;
  color: var(--cwl-text); outline: none; transition: border-color .2s, box-shadow .2s;
}
.cwl-input::placeholder { color: #8fa0c6; }
.cwl-input:focus { border-color: var(--cwl-blue); box-shadow: 0 0 0 3px rgba(90, 169, 255, .25); }

.cwl-btn {
  cursor: pointer; border-radius: 12px; padding: 13px 20px; font-size: 15px; font-weight: 700;
  border: 1px solid transparent; transition: transform .15s ease, background .2s, opacity .2s;
}
.cwl-btn:active { transform: translateY(1px) scale(.99); }
.cwl-btn[disabled] { opacity: .6; cursor: progress; }
.cwl-btn-primary { background: linear-gradient(135deg, #ffd166, #ffb020); color: #14203a; }
.cwl-btn-primary:hover { background: linear-gradient(135deg, #ffdf8d, #ffc347); }
.cwl-btn-ghost { background: var(--cwl-panel-2); color: var(--cwl-text); border-color: var(--cwl-line); }
.cwl-btn-ghost:hover { background: #233054; }

.cwl-quick { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 14px; }
.cwl-chip {
  background: rgba(255,255,255,.06); border: 1px solid var(--cwl-line); color: var(--cwl-dim);
  border-radius: 999px; padding: 6px 13px; font-size: 13px; cursor: pointer;
}
.cwl-chip:hover { color: #fff; border-color: var(--cwl-blue); }

.cwl-status {
  margin: 16px auto; max-width: 720px; padding: 14px 18px; border-radius: 12px;
  background: var(--cwl-panel); border: 1px solid var(--cwl-line); color: var(--cwl-text); font-size: 15px;
}
.cwl-status.cwl-err { border-color: #7b2f2f; background: #2a1620; color: #ffd7d7; }
.cwl-status.cwl-load { display: flex; align-items: center; gap: 12px; }
.cwl-spin {
  width: 18px; height: 18px; border-radius: 50%; flex: none;
  border: 3px solid rgba(255,255,255,.2); border-top-color: var(--cwl-gold);
  animation: cwl-spin 0.8s linear infinite;
}
@keyframes cwl-spin { to { transform: rotate(360deg); } }

.cwl-card {
  background: var(--cwl-panel); border: 1px solid var(--cwl-line); border-radius: 18px;
  padding: clamp(16px, 2.4vw, 24px); margin-top: 18px;
  animation: cwl-rise .45s ease both;
}
@keyframes cwl-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.cwl-h4 { margin: 0 0 10px; font-size: 18px; font-weight: 800; color: #fff; }
.cwl-note { color: var(--cwl-dim); font-size: 13px; margin: 4px 0 12px; }

.cwl-profile { display: grid; grid-template-columns: 120px 1fr auto; gap: 20px; align-items: center; }
.cwl-profile-media img { width: 120px; height: 120px; object-fit: cover; border-radius: 16px; border: 2px solid var(--cwl-line); display: block; }
.cwl-avatar {
  width: 120px; height: 120px; border-radius: 16px; display: grid; place-items: center;
  font-size: 40px; font-weight: 800; color: #14203a;
  background: linear-gradient(135deg, #ffd166, #5aa9ff);
}
.cwl-name { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); font-weight: 800; color: #fff; }
.cwl-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.cwl-tag { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: #24325a; color: #dce6ff; }
.cwl-tag.high { background: #12503c; color: #9df3d2; }
.cwl-tag.medium { background: #4d3c11; color: #ffdf9a; }
.cwl-tag.low { background: #55232a; color: #ffc4c4; }
.cwl-summary { margin: 0; color: #e2e9fb; font-size: 14.5px; }

.cwl-networth { text-align: right; min-width: 230px; }
.cwl-networth-label { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: var(--cwl-dim); }
.cwl-networth-value {
  display: block; font-size: clamp(30px, 5.2vw, 52px); font-weight: 900; letter-spacing: -.02em;
  color: var(--cwl-gold); text-shadow: 0 0 26px rgba(255, 201, 77, .25); line-height: 1.1;
}
.cwl-networth-meta { display: block; color: var(--cwl-dim); font-size: 13px; margin-top: 4px; }
.cwl-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; margin-top: 12px; }
.cwl-actions .cwl-btn { padding: 9px 14px; font-size: 13px; }

.cwl-source-list { display: grid; gap: 10px; }
.cwl-source {
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  background: var(--cwl-panel-2); border: 1px solid var(--cwl-line); border-radius: 12px; padding: 11px 14px;
}
.cwl-source a { color: var(--cwl-blue); font-weight: 700; text-decoration: none; }
.cwl-source a:hover { text-decoration: underline; }
.cwl-source span { color: var(--cwl-dim); font-size: 13px; }
.cwl-source strong { color: #fff; }
.cwl-disc { background: #3b2d10; border: 1px solid #6b5312; color: #ffe4a8; padding: 12px 14px; border-radius: 12px; font-size: 14px; }
.cwl-related { display: inline-block; margin-top: 10px; color: var(--cwl-green); font-weight: 700; text-decoration: none; }
.cwl-related:hover { text-decoration: underline; }

.cwl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.cwl-stat { background: var(--cwl-panel-2); border: 1px solid var(--cwl-line); border-radius: 14px; padding: 14px; }
.cwl-stat b { display: block; font-size: clamp(17px, 2.2vw, 22px); color: #fff; font-weight: 800; word-break: break-word; }
.cwl-stat span { font-size: 12px; text-transform: uppercase; letter-spacing: .09em; color: var(--cwl-dim); }

.cwl-row { display: flex; gap: 14px; flex-wrap: wrap; }
.cwl-field { display: flex; flex-direction: column; gap: 6px; flex: 1 1 200px; }
.cwl-field span { font-size: 13px; color: var(--cwl-dim); font-weight: 600; }
.cwl-field input {
  padding: 12px 14px; font-size: 16px; border-radius: 12px; color: var(--cwl-text);
  background: var(--cwl-panel-2); border: 1px solid var(--cwl-line);
}
.cwl-field input:focus { outline: none; border-color: var(--cwl-blue); }
.cwl-goal { margin-top: 16px; display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }

.cwl-vs { display: grid; grid-template-columns: 1fr auto 1fr; gap: 14px; align-items: center; margin-top: 8px; }
.cwl-vs-side { background: var(--cwl-panel-2); border: 1px solid var(--cwl-line); border-radius: 14px; padding: 16px; text-align: center; }
.cwl-vs-side.win { border-color: var(--cwl-green); box-shadow: 0 0 0 1px rgba(56,224,164,.35); }
.cwl-vs-side b { display: block; font-size: clamp(20px, 3vw, 28px); color: var(--cwl-gold); font-weight: 900; }
.cwl-vs-side em { font-style: normal; color: #fff; font-weight: 700; display: block; margin-bottom: 6px; }
.cwl-vs-mid { font-weight: 900; color: var(--cwl-dim); font-size: 20px; }
.cwl-vs-note { margin-top: 12px; color: #e2e9fb; font-size: 14.5px; }

.cwl-game-head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: flex-end; }
.cwl-game-bal { text-align: right; min-width: 240px; flex: 1 1 240px; }
.cwl-game-bal span { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: var(--cwl-dim); }
.cwl-game-bal strong { font-size: clamp(20px, 3vw, 30px); color: var(--cwl-green); font-weight: 900; }
.cwl-bar { height: 8px; background: #22304f; border-radius: 999px; overflow: hidden; margin-top: 8px; }
.cwl-bar-fill { height: 100%; width: 100%; background: linear-gradient(90deg, var(--cwl-green), var(--cwl-gold)); transition: width .4s ease; }
.cwl-game-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0; }
.cwl-shop { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.cwl-item {
  background: var(--cwl-panel-2); border: 1px solid var(--cwl-line); border-radius: 14px;
  padding: 12px; text-align: center; transition: transform .15s ease, border-color .2s;
}
.cwl-item:hover { transform: translateY(-3px); border-color: var(--cwl-blue); }
.cwl-item .cwl-emoji { font-size: 30px; }
.cwl-item .cwl-item-name { font-weight: 700; color: #fff; font-size: 14px; margin: 4px 0; }
.cwl-item .cwl-item-price { color: var(--cwl-gold); font-weight: 800; font-size: 14px; }
.cwl-buyrow { display: flex; gap: 6px; margin-top: 8px; }
.cwl-buyrow button { flex: 1; padding: 8px; border-radius: 9px; font-weight: 800; cursor: pointer; border: 1px solid var(--cwl-line); }
.cwl-buy { background: #17694f; color: #d8ffee; }
.cwl-buy:hover { background: #1e8362; }
.cwl-buy[disabled] { opacity: .45; cursor: not-allowed; }
.cwl-sell { background: #5a2430; color: #ffd9d9; }
.cwl-sell:hover { background: #74303f; }
.cwl-sell[disabled] { opacity: .35; cursor: not-allowed; }
.cwl-owned { font-size: 12px; color: var(--cwl-dim); margin-top: 6px; }
.cwl-receipt { margin-top: 16px; display: grid; gap: 8px; }
.cwl-receipt-line {
  display: flex; justify-content: space-between; gap: 10px; font-size: 14px;
  background: rgba(255,255,255,.04); border-radius: 10px; padding: 9px 12px; color: #e6ecfb;
}
.cwl-receipt-line b { color: #fff; }

.cwl-toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%);
  background: #101a30; color: #fff; border: 1px solid var(--cwl-line);
  padding: 12px 18px; border-radius: 12px; z-index: 99999; font-weight: 700;
  box-shadow: 0 12px 30px rgba(0,0,0,.4); animation: cwl-rise .3s ease both;
}
.cwl-footer { margin: 20px 0 0; text-align: center; color: var(--cwl-dim); font-size: 12.5px; }

@media (max-width: 860px) {
  .cwl-profile { grid-template-columns: 88px 1fr; }
  .cwl-profile-media img, .cwl-avatar { width: 88px; height: 88px; font-size: 30px; }
  .cwl-networth { grid-column: 1 / -1; text-align: left; }
  .cwl-actions { justify-content: flex-start; }
  .cwl-game-bal { text-align: left; }
  .cwl-vs { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .cwl-app { border-radius: 14px; padding: 14px; }
  .cwl-btn, .cwl-input { width: 100%; }
  .cwl-actions .cwl-btn { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .cwl-app * { animation: none !important; transition: none !important; }
}
