/* TRACECARD / HUNTER PNL — EXACT CARD STYLING */
@import url('https://fonts.googleapis.com/css2?family=Antonio:wght@400;500;600;700&family=Geist:wght@400;500;600;700;800;900&family=Roboto+Condensed:wght@700;800;900&family=Inter:wght@400;600;700;800;900&display=swap');

@font-face {
  font-family: 'Antonio';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/Antonio-Regular.ttf') format('truetype');
}

@font-face {
  font-family: 'Antonio';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/Antonio-Medium.ttf') format('truetype');
}


:root {
  --color-base: #041f18;
  --color-field: #0b3d30;
  --color-signal: #34d399;
  --bg-opacity: 0.7;
  --radius-card: 18px;
  --card-scale: 1;
}

/* Card Container */
.pnl-card {
  width: 100%;
  max-width: 1180px;
  margin: 0;
  aspect-ratio: 796 / 448;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--radius-card);
  background: linear-gradient(90deg, rgba(5,5,8,.9), rgba(5,5,8,.52) 62%, rgba(5,5,8,.42)),
              linear-gradient(135deg, var(--color-base), var(--color-field) 56%, var(--color-signal));
  border: 0;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.75), 0 0 45px rgba(0, 0, 0, 0.5);
  user-select: none;
}

/* Mode Switching (Simple vs Pro) */
.mode-card {
  display: none;
}
.mode-card.is-active {
  display: block;
}

/* Background Image Layer */
.pnl-card .bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  opacity: var(--bg-opacity);
  display: block;
  z-index: 1;
  pointer-events: none;
}

/* Scaled Content Surface */
.pnl-card .card-content {
  width: 796px;
  height: 448px;
  inset: 0 auto auto 0;
  padding: 24.456px;
  transform-origin: top left;
  transform: scale(var(--card-scale, 1));
  position: absolute;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-family: 'Geist', sans-serif;
  color: #ffffff;
  box-sizing: border-box;
}

/* Top Bar */
.pnl-card .card-top {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  font-size: 7.68px;
  letter-spacing: 0.15em;
  color: rgba(255, 255, 255, 0.65);
  font-weight: 600;
  text-transform: uppercase;
  min-height: 24px;
}
.pnl-card .card-brand-title {
  display: none !important;
  align-items: center;
  gap: 0.28em;
  font-family: 'Antonio', sans-serif;
  font-weight: 500;
  font-size: 18px;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: lowercase;
  user-select: none;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-top: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  padding: 1px 14px 7px 14px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}
.pnl-card .card-brand-title .brand-word-trace {
  color: #ffffff;
}
.pnl-card .card-brand-title .brand-word-hunters {
  color: #d8d8d8;
}
.pnl-card .card-top .card-credit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #ffffff;
}
.pnl-card .card-top-mark {
  width: 28px;
  height: 28px;
  object-fit: contain;
  border-radius: 6px;
  flex: none;
}

/* Body Grid */
.pnl-card .card-body {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(285px, 1.05fr);
  align-items: end;
  gap: 4%;
  min-height: 0;
  position: relative;
}

.pnl-card .performance-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

/* Collection Row */
.pnl-card .collection-row {
  display: flex;
  align-items: center;
  gap: 9.216px;
  margin-bottom: 6px;
}
.pnl-card .collection-art {
  width: 41.472px;
  height: 41.472px;
  min-width: 41.472px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}
.pnl-card .collection-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}
.pnl-card .collection-art img[src]:not([src=""]) {
  display: block;
}
.pnl-card .card-kicker {
  display: block;
  font: 700 8.5px/1.2 'Geist', sans-serif;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.75);
  margin-bottom: 2px;
}
.pnl-card .collection-name {
  display: flex;
  align-items: center;
  gap: 6px;
  font: 800 17.664px/1 'Inter', sans-serif;
  text-transform: uppercase;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
  letter-spacing: -0.02em;
}
.pnl-card .verified-tick {
  width: 14px;
  height: 14px;
  object-fit: contain;
  filter: drop-shadow(0 0 4px rgba(38, 145, 255, 0.45));
}

/* Net Profit & Loss Section */
.pnl-card .metric-label {
  font: 700 8px 'Geist', sans-serif;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.75);
  margin-top: 10.752px;
}
.pnl-card .pnl-lockup {
  display: flex;
  align-items: center;
  gap: 11.52px;
  white-space: nowrap;
}
.pnl-card .big-pnl {
  font: 900 80.64px/0.82 'Roboto Condensed', sans-serif;
  letter-spacing: -0.055em;
  color: var(--color-signal);
  margin-top: 4px;
  text-shadow: 0 0 35px rgba(217, 255, 67, 0.25);
}
.pnl-card .big-pnl.negative {
  color: #ff4d5e !important;
  text-shadow: 0 0 35px rgba(255, 77, 94, 0.25);
}
.pnl-card .main-eth {
  display: block;
  flex: 0 0 auto;
  width: 41.472px;
  height: 67.584px;
  color: var(--color-signal);
  overflow: visible;
  filter: none !important;
  box-shadow: none !important;
  text-shadow: none !important;
  transition: color 0.15s ease;
}
.pnl-card .main-eth.negative {
  color: #ff4d5e !important;
  filter: none !important;
  box-shadow: none !important;
  text-shadow: none !important;
}
.pnl-card .main-native {
  font: 800 32px 'Roboto Condensed', sans-serif;
  color: var(--color-signal);
  align-self: flex-end;
  margin-bottom: 8px;
  text-shadow: 0 0 18px currentColor;
  transition: color 0.15s ease, text-shadow 0.15s ease;
}
.pnl-card .main-native.negative {
  color: #ff4d5e !important;
  text-shadow: 0 0 18px rgba(255, 77, 94, 0.35) !important;
}
.pnl-card .sub-pnl {
  font: 700 23.75px 'Roboto Condensed', sans-serif;
  color: var(--color-signal);
  margin-top: 7.68px;
  letter-spacing: -0.01em;
}
.pnl-card .sub-pnl.negative {
  color: #ff4d5e !important;
}
.pnl-card .sub-pnl span {
  color: rgba(255, 255, 255, 0.75);
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.65);
}

/* Activity Stats (Minted, Buy, Hold, Sold) */
.pnl-card .activity-stats {
  position: relative;
  left: 9.216px;
  top: 7.68px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-self: end;
  padding-bottom: 18.432px;
  width: 100%;
}
.pnl-card .activity-stats > div {
  padding-left: 10%;
  border-left: 1px solid rgba(255, 255, 255, 0.16);
  min-width: 0;
  display: block;
}
.pnl-card .activity-stats > div:first-child {
  padding-left: 0;
  border-left: 0;
}
.pnl-card .activity-stats small {
  display: block;
  font: 700 8.2px 'Geist', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.75);
  white-space: nowrap;
}
.pnl-card .activity-stats b {
  display: block;
  margin-top: 3.84px;
  font: 800 19px/1 'Roboto Condensed', sans-serif;
  color: #ffffff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
  white-space: nowrap;
}

/* Bottom Stats Row (Spent, Realized, Unrealized, Floor, Wallet Scanned) */
.pnl-card .stats {
  position: relative;
  margin-top: 9.984px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding-top: 6.912px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
}
.pnl-card.pro-card .stats {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  padding-right: 120px;
  gap: 6px;
}
.pnl-card .stats > div {
  padding-left: 6.144%;
  border-left: 1px solid rgba(255, 255, 255, 0.16);
}
.pnl-card.pro-card .stats > div {
  padding-left: 8px;
  border-left: 1px solid rgba(255, 255, 255, 0.16);
}
.pnl-card .stats > div:first-child {
  padding-left: 0;
  border-left: 0;
}
.pnl-card .stats small {
  display: block;
  font: 700 7.5px 'Geist', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.75);
}
.pnl-card .stats b {
  display: block;
  margin-top: 3.84px;
  font: 700 12.288px 'Geist', sans-serif;
  color: #ffffff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
  white-space: nowrap;
}
.pnl-card.pro-card .stats b {
  font-size: 10.8px;
}
.pnl-card .stats-credit {
  position: absolute;
  right: 0;
  bottom: 0;
  font: 700 7.5px/1 'Geist', sans-serif;
  letter-spacing: 0.12em;
  text-transform: lowercase;
  color: #f1f5f9;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-top: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  padding: 4px 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

/* Flat Staging for 4K Export Canvas */
.pnl-card.export-flat {
  width: 796px !important;
  height: 448px !important;
  aspect-ratio: auto !important;
  border-radius: 0 !important;
  overflow: hidden !important;
  transform: none !important;
  box-shadow: none !important;
  --card-scale: 1 !important;
}
.pnl-card.export-flat .card-content,
.pnl-card.export-flat .bg-img {
  border-radius: 0 !important;
  transform: none !important;
}
