/* ==========================================================================
   OSZ Player Full Profile — assets/css/osz-player-full-profile.css
   Dark club aesthetic. Strong table rules defeat theme bleed.
   ========================================================================== */

.osz-fp {
  --osz-fp-bg: #0c0c0c;
  --osz-fp-panel: #141414;
  --osz-fp-panel-2: #1d1d1d;
  --osz-fp-border: #2a2a2a;
  --osz-fp-red: #d0021b;
  --osz-fp-red-deep: #7a0110;
  --osz-fp-text: #f5f5f5;
  --osz-fp-muted: #9a9a9a;

  background: var(--osz-fp-bg);
  color: var(--osz-fp-text);
  font-size: 16px;
  line-height: 1.5;
}

.osz-fp *,
.osz-fp *::before,
.osz-fp *::after {
  box-sizing: border-box;
}

.osz-fp a {
  text-decoration: none;
}

/* Inline SVG icons */
.osz-fp .osz-fp-icon {
  display: inline-flex;
  color: var(--osz-fp-red);
}
.osz-fp .osz-fp-icon svg {
  width: 26px;
  height: 26px;
  display: block;
}

/* ── Hero ──────────────────────────────────────────────────── */

.osz-fp-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: 300px;
  padding: 48px 48px;
  overflow: hidden;
  background:
    radial-gradient(
      ellipse 60% 90% at 85% 40%,
      rgba(150, 5, 20, 0.55) 0%,
      rgba(150, 5, 20, 0) 65%
    ),
    radial-gradient(
      ellipse 50% 70% at 70% 100%,
      rgba(90, 3, 12, 0.6) 0%,
      rgba(90, 3, 12, 0) 70%
    ),
    linear-gradient(100deg, #0a0a0a 0%, #150607 55%, #2b090c 100%);
  border-bottom: 3px solid var(--osz-fp-red);
}

.osz-fp-hero-text {
  position: relative;
  z-index: 2;
}

.osz-fp-hero-name {
  margin: 0 0 24px;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 900;
  line-height: 0.98;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  color: var(--osz-fp-text);
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.6);
}

.osz-fp-hero-name span {
  display: block;
}

.osz-fp-hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
}

.osz-fp-hero-stat {
  display: flex;
  align-items: center;
  gap: 12px;
}

.osz-fp-hero-stat-body {
  display: flex;
  flex-direction: column;
}

.osz-fp-hero-stat-num {
  font-size: 1.85rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--osz-fp-text);
}

.osz-fp-hero-stat-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--osz-fp-muted);
}

.osz-fp-hero-photo {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.osz-fp-hero-photo img {
  display: block;
  max-height: 280px;
  width: auto;
  object-fit: cover;
  object-position: top;
  -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
  filter: drop-shadow(0 16px 40px rgba(0, 0, 0, 0.7));
}

/* ── Back bar ───────────────────────────────────────────────── */

.osz-fp-fullbar {
  padding: 12px 0;
}

.osz-fp-fullbar-back {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #d0021b;
  display: inline-block;
  padding: 4px 0;
}

.osz-fp-fullbar-back:hover {
  color: var(--osz-fp-text);
}

/* ── Body layout ────────────────────────────────────────────── */

.osz-fp-body {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 28px;
  padding: 0 40px 48px;
}

/* ── Sidebar ────────────────────────────────────────────────── */

.osz-fp-side {
  background: var(--osz-fp-panel);
  border: 1px solid var(--osz-fp-border);
  padding: 14px;
  align-self: start;
}

.osz-fp-side-photo img {
  display: block;
  width: 100%;
  height: auto;
}

.osz-fp-side-name {
  position: relative;
  z-index: 2;
  margin: -54px 0 8px;
  padding: 12px 14px;
  background: linear-gradient(
    100deg,
    rgba(208, 2, 27, 0.92),
    rgba(122, 1, 16, 0.92)
  );
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 2px;
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  font-weight: 800;
  line-height: 1.15;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

@supports (
  (backdrop-filter: blur(10px)) or (-webkit-backdrop-filter: blur(10px))
) {
  .osz-fp-side-name {
    background: linear-gradient(
      100deg,
      rgba(208, 2, 27, 0.55),
      rgba(122, 1, 16, 0.5)
    );
    -webkit-backdrop-filter: blur(10px) saturate(140%);
    backdrop-filter: blur(10px) saturate(140%);
  }
}

.osz-fp-side-name span {
  display: block;
}

.osz-fp-bio {
  list-style: none;
  margin: 0;
  padding: 0;
}

.osz-fp-bio-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 11px 4px;
  border-bottom: 1px solid var(--osz-fp-border);
  font-size: 0.85rem;
}

.osz-fp-bio-label {
  color: var(--osz-fp-muted);
}

.osz-fp-bio-value {
  font-weight: 700;
  text-align: right;
  color: var(--osz-fp-text);
}

.osz-fp-signature {
  margin-top: 14px;
  padding: 10px;
  border: 1px solid var(--osz-fp-text);
  background: #000;
}

.osz-fp-signature img {
  display: block;
  width: 100%;
  height: 100px !important;
  object-fit: contain;
}

.osz-fp-sponsor {
  padding: 20px 20px 0 20px;
}

.osz-fp-sponsor img {
  display: block;
  width: 100%;
}

/* ── Main column / sections ────────────────────────────────── */

.osz-fp-main {
  min-width: 0;
}

.osz-fp-section {
  background: var(--osz-fp-panel);
  border: 1px solid var(--osz-fp-border);
  padding: 22px 24px;
  margin-bottom: 24px;
}

.osz-fp-heading {
  margin: 0 0 18px;
  font-size: 1.15rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--osz-fp-text);
}

.osz-fp-heading span {
  color: var(--osz-fp-red);
}

.osz-fp-no-data {
  color: var(--osz-fp-muted);
  padding: 12px 0;
  margin: 0;
}

/* ── Side-by-side panel (Teammates + Goal Opponents) ────────── */

.osz-fp-sidebyside {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.osz-fp-sidebyside--full {
  grid-template-columns: 1fr;
}

.osz-fp-sidebyside-panel {
  min-width: 0;
}

.osz-fp-sidebyside-panel .osz-fp-heading {
  font-size: 1rem;
}

/* ── Tables — strong overrides to defeat ANY theme bleed ────── */

.osz-fp-table-wrap {
  overflow-x: auto;
}

.osz-fp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
  background: var(--osz-fp-panel-2) !important;
}

.osz-fp-table * {
  box-sizing: border-box;
}

/* Headers */
.osz-fp-table thead th,
.osz-fp-table thead td {
  padding: 12px 10px;
  text-align: center;
  font-size: 0.68rem !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--osz-fp-muted) !important;
  background: var(--osz-fp-panel-2) !important;
  border: 1px solid var(--osz-fp-border) !important;
}

/* All body cells — hard kill on any theme background */
.osz-fp-table tbody tr,
.osz-fp-table tbody tr:nth-child(odd),
.osz-fp-table tbody tr:nth-child(even),
.osz-fp-table tbody tr:nth-of-type(odd),
.osz-fp-table tbody tr:nth-of-type(even),
.osz-fp-table tbody tr:not(.osz-fp-table *) {
  background: var(--osz-fp-panel-2) !important;
}

.osz-fp-table tbody td,
.osz-fp-table tbody th {
  padding: 12px 10px;
  text-align: center;
  border: 1px solid var(--osz-fp-border) !important;
  color: var(--osz-fp-text) !important;
  background: var(--osz-fp-panel-2) !important;
  font-weight: 700;
  white-space: nowrap;
}

/* Kill hover */
.osz-fp-table tbody tr:hover,
.osz-fp-table tbody tr:hover td,
.osz-fp-table tbody tr:hover th {
  background: var(--osz-fp-panel-2) !important;
  color: var(--osz-fp-text) !important;
}

/* Links inside tables */
.osz-fp-table a {
  color: var(--osz-fp-text) !important;
}

.osz-fp-table a:hover {
  color: var(--osz-fp-red);
}

/* ── Opponent cell ──────────────────────────────────────────── */

.osz-fp-opponent {
  text-align: left !important;
}

.osz-fp-opponent-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}

.osz-fp-avatar {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  overflow: hidden;
  display: block;
}

.osz-fp-avatar img {
  width: 32px !important;
  height: 32px !important;
  max-width: 100% !important;
  object-fit: contain !important;
}

.osz-fp-opp-name {
  color: var(--osz-fp-text) !important;
  font-weight: 700;
  font-size: 0.84rem;
  text-decoration: none;
}

.osz-fp-opp-name:hover {
  color: var(--osz-fp-red) !important;
}

/* ── Season filter ──────────────────────────────────────────── */

.osz-fp-season-filter {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: var(--osz-fp-panel-2);
  padding: 16px 20px;
  border: 1px solid var(--osz-fp-border);
  margin-bottom: 18px;
}

.osz-fp-season-filter label {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--osz-fp-text);
}

#osz-fp-season-select {
  padding: 8px 16px;
  font-size: 0.85rem;
  border: 1px solid var(--osz-fp-border);
  background: var(--osz-fp-panel);
  color: var(--osz-fp-text);
  cursor: pointer;
  min-width: 200px;
  font-weight: 500;
}

#osz-fp-season-select:focus {
  outline: none;
  border-color: var(--osz-fp-red);
}

/* Spinner */
@keyframes osz-fp-spin {
  to {
    transform: rotate(360deg);
  }
}

.osz-fp-loading {
  color: var(--osz-fp-muted);
  font-style: italic;
  display: flex;
  align-items: center;
  gap: 6px;
}

.osz-fp-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid var(--osz-fp-border);
  border-top-color: var(--osz-fp-red);
  border-radius: 50%;
  animation: osz-fp-spin 0.6s linear infinite;
}

#osz-fp-matches-table-wrap.osz-fp-updating {
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 0.3s;
}

/* ── Teammates grid ─────────────────────────────────────────── */

.osz-fp-mates {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
}

.osz-fp-mate {
  background: var(--osz-fp-panel-2);
  border: 1px solid var(--osz-fp-border);
  padding: 10px 10px 12px;
  text-align: center;
  color: var(--osz-fp-text);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition:
    border-color 0.15s ease,
    transform 0.15s ease;
}

.osz-fp-mate:hover {
  border-color: var(--osz-fp-red);
  transform: translateY(-2px);
  color: var(--osz-fp-text) !important;
}

.osz-fp-mate-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
  object-position: top;
}

.osz-fp-mate-name {
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1.2;
}

.osz-fp-mate-count {
  font-size: 0.72rem;
  font-weight: 800;
}

.osz-fp-mate-count em {
  font-style: normal;
  color: var(--osz-fp-red);
  text-transform: uppercase;
  font-size: 0.64rem;
  letter-spacing: 0.06em;
}

/* ── Buttons ────────────────────────────────────────────────── */

.osz-fp-action {
  width: 120px;
}

.osz-fp-btn {
  display: inline-block;
  padding: 12px 28px;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px solid var(--osz-fp-red);
  color: #fff !important;
  transition: background 0.15s ease;
}

.osz-fp-btn-primary {
  background: var(--osz-fp-red);
}

.osz-fp-btn-primary:hover {
  background: #a00114;
}

.osz-fp-btn-ghost {
  background: transparent;
  padding: 7px 14px;
  border-color: var(--osz-fp-border);
  font-size: 0.68rem;
}

.osz-fp-btn-ghost:hover {
  background: var(--osz-fp-red);
  border-color: var(--osz-fp-red);
  color: #fff !important;
}

/* ── Responsive ─────────────────────────────────────────────── */

@media (max-width: 900px) {
  .osz-fp-body {
    grid-template-columns: 1fr;
    padding: 0 20px 40px;
  }

  .osz-fp-side {
    max-width: 380px;
  }

  .osz-fp-hero {
    padding: 36px 24px;
    flex-direction: column;
    align-items: flex-start;
    min-height: 0;
  }

  .osz-fp-hero-photo {
    align-self: center;
  }

  .osz-fp-sidebyside {
    grid-template-columns: 1fr;
  }

  .osz-fp-table th,
  .osz-fp-table td {
    padding: 10px 8px;
  }
}

@media (max-width: 520px) {
  .osz-fp-hero-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .osz-fp-mates {
    grid-template-columns: 1fr 1fr;
  }

  .osz-fp-hero-photo img {
    max-height: 180px;
  }
}
