/* 球星卡 v7 · 内卡贴紧外框 + 修正 F 底部文字（transform 由内联 style 写入） */

/* —— 梅西参考图模式：内卡铺满 card-border 内区 —— */
.star-card--fc-ref .card-inner--fc-ref {
  background: transparent !important;
  padding: 0;
  box-sizing: border-box;
  position: relative;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  border-radius: 16px;
}

.star-card--fc-ref .fc-ref-stack {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
}

.star-card--fc-ref .fc-ref-visual {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  container-type: size;
}

.star-card--fc-ref .fc-ref-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Super + 参考内卡：铺满炫彩等级框，上移避免底部国籍/编号被裁切 */
.star-card--super.star-card--fc-ref .prism-card__slot {
  padding-top: 0 !important;
}

.star-card--super.star-card--fc-ref .prism-card__slot .star-card--prism-inner,
.star-card--super.star-card--fc-ref .prism-card__slot .card-border,
.star-card--super.star-card--fc-ref .card-inner--fc-ref,
.star-card--super.star-card--fc-ref .fc-ref-stack {
  height: 100%;
  min-height: 0;
}

.star-card--super.star-card--fc-ref .fc-ref-card-img {
  object-fit: cover;
}

.star-card--fc-ref .card-top {
  position: absolute;
  top: 5px;
  right: 5px;
  z-index: 6;
  padding: 0;
}

/* —— 模板模式（其他球星套用同一结构） —— */
.star-card--fc-style:not(.star-card--fc-ref) .card-inner--ut {
  background: transparent !important;
  padding: 0;
  overflow: visible;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-shell {
  position: relative;
  width: 100%;
  height: 100%;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-gold-frame {
  height: 100%;
  padding: 2px;
  border-radius: 15px;
  background: linear-gradient(150deg, #e2c56a 0%, #9a7b2e 22%, #f2dc8a 48%, #7a5e1e 72%, #c9a227 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 240, 200, 0.45),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-surface {
  height: 100%;
  border-radius: 13px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #080f1c;
  box-shadow: inset 0 0 0 1px rgba(220, 190, 120, 0.42);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-card-top {
  position: absolute;
  top: 5px;
  right: 5px;
  z-index: 8;
  padding: 0;
}

.star-card--fc-ref .card-lv,
.star-card--fc-style .card-lv {
  font-size: 0.54rem;
  padding: 3px 7px;
  letter-spacing: 0.02em;
  line-height: 1.15;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.42);
}

.star-card--fc-ref .card-lv--long,
.star-card--fc-style .card-lv--long {
  font-size: 0.48rem;
  padding: 2px 5px;
  letter-spacing: 0.01em;
}

.star-card--fc-ref .card-lv--super,
.star-card--fc-style .card-lv--super {
  font-size: 0.52rem;
  padding: 3px 8px;
  letter-spacing: 0.04em;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-portrait {
  position: relative;
  flex: 0 0 67%;
  min-height: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-portrait-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 100% 88% at 50% 40%, #1a2f55 0%, #0c1830 52%, #060d18 100%);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-portrait-halo {
  position: absolute;
  width: 76%;
  height: 50%;
  top: 12%;
  left: 12%;
  border-radius: 50%;
  filter: blur(24px);
  opacity: 0.8;
  z-index: 1;
  background: radial-gradient(circle, rgba(245, 196, 81, 0.85) 0%, rgba(217, 119, 6, 0.3) 48%, transparent 72%);
}

.star-card--fc-style.star-card--lv1:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(200, 210, 225, 0.7), rgba(100, 116, 139, 0.25) 50%, transparent 72%);
}
.star-card--fc-style.star-card--lv2:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(251, 191, 36, 0.82), rgba(180, 83, 9, 0.3) 48%, transparent 72%);
}
.star-card--fc-style.star-card--lv3:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(253, 224, 71, 0.88), rgba(217, 119, 6, 0.32) 48%, transparent 72%);
}
.star-card--fc-style.star-card--lv4:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(251, 146, 60, 0.85), rgba(194, 65, 12, 0.3) 48%, transparent 72%);
}
.star-card--fc-style.star-card--lv5:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(248, 113, 113, 0.85), rgba(185, 28, 28, 0.32) 48%, transparent 72%);
}
.star-card--fc-style.star-card--super:not(.star-card--fc-ref) .ut-portrait-halo {
  background: radial-gradient(circle, rgba(196, 181, 253, 0.8), rgba(56, 189, 248, 0.28) 48%, transparent 72%);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-portrait-sparkles {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(2px 2px at 16% 24%, rgba(255, 230, 150, 1), transparent),
    radial-gradient(1.5px 1.5px at 74% 18%, rgba(255, 245, 200, 0.95), transparent),
    radial-gradient(1px 1px at 44% 14%, rgba(255, 220, 120, 0.9), transparent),
    radial-gradient(1.5px 1.5px at 84% 36%, rgba(255, 235, 170, 0.85), transparent),
    radial-gradient(1px 1px at 28% 40%, rgba(255, 210, 100, 0.8), transparent),
    radial-gradient(2px 2px at 58% 28%, rgba(255, 240, 180, 0.75), transparent);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-portrait-glass {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.03) 16%, transparent 34%);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-player {
  position: relative;
  z-index: 4;
  width: 92%;
  max-height: 98%;
  object-fit: contain;
  object-position: bottom center;
  mix-blend-mode: multiply;
  filter: contrast(1.05) saturate(1.06) drop-shadow(0 8px 18px rgba(0, 0, 0, 0.55));
  pointer-events: none;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-beam {
  flex-shrink: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(245, 196, 81, 0.75) 18%, rgba(255, 255, 255, 0.95) 50%, rgba(245, 196, 81, 0.75) 82%, transparent);
  box-shadow: 0 0 14px rgba(245, 196, 81, 0.55);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-footer {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 8px 12px;
  background: linear-gradient(180deg, #0a1424 0%, #050a12 100%);
  text-align: center;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-footer-sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.07) 0%, transparent 30%);
  pointer-events: none;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-name {
  position: relative;
  z-index: 1;
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #dbb863;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.65);
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-nation {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  color: rgba(240, 244, 248, 0.95);
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-nation .star-flag {
  width: 17px;
  height: 11px;
}

.star-card--fc-style:not(.star-card--fc-ref) .ut-meta {
  position: relative;
  z-index: 1;
  font-size: 0.64rem;
  font-weight: 600;
  color: #c9a962;
  letter-spacing: 0.04em;
}

/* Super 炫彩外框内模板 */
.star-card--fc-style.star-card--super:not(.star-card--fc-ref) .prism-card__slot .card-inner--ut {
  background: transparent !important;
}
.star-card--fc-style.star-card--super:not(.star-card--fc-ref) .prism-card__slot .ut-shell {
  padding-top: 34px;
}

/* —— 预览页 —— */
.fc-preview-page {
  min-height: 100vh;
  padding: 32px 16px 48px;
}

.fc-preview-header {
  max-width: 880px;
  margin: 0 auto 28px;
  text-align: center;
}

.fc-preview-header h1 {
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  margin-bottom: 10px;
}

.fc-preview-header p {
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.65;
}

.fc-preview-note {
  margin-top: 10px;
  font-size: 0.8rem;
  color: #fbbf24;
}

.fc-preview-note a { color: #93c5fd; }

.fc-preview-section {
  max-width: 920px;
  margin: 0 auto 32px;
}

.fc-preview-section h2 {
  font-size: 0.88rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 16px;
  color: var(--muted);
}

.fc-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(156px, 1fr));
  gap: 20px 14px;
}

.fc-preview-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.fc-preview-item .star-card {
  width: 100%;
  max-width: 200px;
}

.fc-preview-item .cap {
  font-size: 0.72rem;
  color: var(--muted);
  text-align: center;
}

.fc-preview-item--gold .cap {
  color: #fbbf24;
}

.fc-preview-grid--hero {
  max-width: 920px;
  margin: 0 auto;
}

.messi-standard-wrap {
  max-width: 220px;
  margin: 0 auto;
}

.messi-standard-wrap .star-card:hover {
  transform: none !important;
  filter: none !important;
}

.fc-preview-section--pending {
  max-width: 920px;
  margin: 0 auto 32px;
  padding: 16px;
  border: 1px dashed rgba(251, 191, 36, 0.35);
  border-radius: 12px;
  background: rgba(251, 191, 36, 0.04);
}

.fc-preview-pending-list {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.8;
  text-align: center;
}

.fc-preview-item--redo .cap {
  color: #86efac;
}

.fc-preview-item--redo::before {
  content: "重做";
  font-size: 0.62rem;
  font-weight: 700;
  color: #86efac;
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.35);
  border-radius: 4px;
  padding: 1px 6px;
  margin-bottom: 2px;
}

.fc-preview-item--redo {
  position: relative;
}

.fc-preview-all .card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(156px, 1fr));
  gap: 20px 14px;
}
