/**
 * Twin3 Sovereign Agent Infrastructure: Standard Trading Card (TCG) Stylesheet
 * Specification: TCG-CARD-SPECIFICATION.md (Version 2.0.0-tcg-converged)
 * Targets: xHuman.ID (Personal Agent) & xAgent.ID (Business Agent)
 */

:root {
  --tcg-card-width: 340px;
  --tcg-card-height: 476px;
  --tcg-aspect-ratio: 2.5 / 3.5;
  --tcg-border-radius: 14px;
  --tcg-border: 1.5px solid rgba(255, 255, 255, 0.22);
  --tcg-box-shadow: 0 20px 48px rgba(0, 0, 0, 0.65), 0 2px 8px rgba(0, 0, 0, 0.4);
  --tcg-inner-glow: inset 0 1px 2px rgba(255, 255, 255, 0.4), inset 0 -1px 2px rgba(0, 0, 0, 0.4);
  --tcg-bg-card: #0d121b;
  --tcg-bg-back: linear-gradient(155deg, #131b28 0%, #0d121b 100%);
  --tcg-ink: #f1f5f9;
  --tcg-muted: #94a3b8;
  --tcg-muted-dim: #64748b;
  --tcg-accent-human: #65dfb4;
  --tcg-accent-agent: #60a5fa;
  --tcg-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* Card Outer Wrap & 3D Stage */
.tcg-card-stage {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.tcg-card-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  transform-origin: top center;
}

.tcg-card-perspective {
  perspective: 1200px;
  display: flex;
  justify-content: center;
}

/* Standard TCG Card Geometry */
.tcg-card {
  width: var(--tcg-card-width) !important;
  max-width: var(--tcg-card-width) !important;
  min-width: var(--tcg-card-width) !important;
  height: var(--tcg-card-height) !important;
  max-height: var(--tcg-card-height) !important;
  min-height: var(--tcg-card-height) !important;
  aspect-ratio: var(--tcg-aspect-ratio) !important;
  border-radius: var(--tcg-border-radius) !important;
  position: relative;
  box-sizing: border-box;
  margin: 0 auto;
}

.tcg-card-face {
  position: absolute;
  inset: 0;
  width: var(--tcg-card-width) !important;
  height: var(--tcg-card-height) !important;
  border-radius: var(--tcg-border-radius) !important;
  border: var(--tcg-border) !important;
  box-shadow: var(--tcg-box-shadow), var(--tcg-inner-glow) !important;
  box-sizing: border-box;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

/* Metallic Edge Rim & Corner Die-cuts */
.tcg-card-rim {
  position: absolute;
  inset: 0;
  border-radius: var(--tcg-border-radius);
  pointer-events: none;
  z-index: 10;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
}

/* Micro Flip Control */
.tcg-flip-control {
  display: flex;
  justify-content: center;
}

.tcg-flip-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--tcg-muted);
  border-radius: 999px;
  padding: 6px 16px;
  font: 600 12px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tcg-flip-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--tcg-ink);
  border-color: rgba(255, 255, 255, 0.24);
}

.tcg-footnote {
  margin: 0;
  text-align: center;
  font-size: 11px;
  color: var(--tcg-muted-dim);
}
