/* ═══════════════════════════════════════════════════════════════
   FIGHTER PROFILE — Complete Redesign
   DieOnYourFeet · Dark sports-editorial aesthetic
   ═══════════════════════════════════════════════════════════════ */

/* ── Base ─────────────────────────────────────────────────────── */
body {
    padding-top: 70px;
    background-color: #0a0a0a;
    color: #e0e0e0;
    font-family: 'Barlow Condensed', 'Oswald', sans-serif;
    letter-spacing: 0.02em;
}

/* ── HERO HEADER ─────────────────────────────────────────────── */
.fighter-header {
    position: relative;
    background: #0a0a0a;
    padding: 0;
    border-bottom: 3px solid var(--primary-red, #e50914);
    overflow: hidden;
}

/* Background image layer — set via inline style in PHP */
.fighter-header-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    z-index: 0;
    opacity: 0.35;
    transition: opacity 0.5s ease;
}

/* Dark gradient overlay for readability */
.fighter-header-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom,
            rgba(10, 10, 10, 0.3) 0%,
            rgba(10, 10, 10, 0.6) 40%,
            rgba(10, 10, 10, 0.95) 85%,
            #0a0a0a 100%);
}

/* Subtle red glow */
.fighter-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(ellipse 80% 60% at 50% 0%, rgba(229, 9, 20, 0.12) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

/* Diagonal red accent stripe */
.fighter-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-red, #e50914), transparent);
    z-index: 3;
}

.fighter-header-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 80px 16px 48px;
    min-height: 340px;
    justify-content: flex-end;
}

/* ── HERO FIGHTER IMAGE (16:9 banner style) ────────────────── */
.fighter-hero-image {
    width: 100%;
    max-width: 480px;
    aspect-ratio: 16 / 9;
    margin: 0 auto 28px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid rgba(229, 9, 20, 0.4);
    background: #111;
    box-shadow:
        0 0 0 4px rgba(229, 9, 20, 0.1),
        0 12px 40px rgba(0, 0, 0, 0.6);
    position: relative;
}

.fighter-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
}

/* Initials fallback inside the 16:9 box */
.fighter-hero-image .fighter-image-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    font-weight: 900;
    color: var(--primary-red, #e50914);
    background: rgba(229, 9, 20, 0.06);
    letter-spacing: 4px;
}

/* ── NAME + NICKNAME ────────────────────────────────────────── */
.fighter-name {
    font-size: clamp(2.2rem, 6vw, 4rem);
    font-weight: 900;
    text-transform: uppercase;
    color: #fff;
    letter-spacing: 0.06em;
    line-height: 1;
    margin: 0 0 8px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6);
}

.fighter-nickname {
    color: var(--primary-red, #e50914);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 28px;
    letter-spacing: 0.05em;
}

/* ── RECORD BAR ─────────────────────────────────────────────── */
.fighter-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0;
    margin: 0 0 28px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    backdrop-filter: blur(8px);
}

.stat-item {
    text-align: center;
    padding: 18px 32px;
    position: relative;
    flex: 1;
    min-width: 90px;
}

.stat-item+.stat-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.stat-value {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--primary-red, #e50914);
    line-height: 1;
    letter-spacing: 0.02em;
}

.stat-label {
    font-size: 0.7rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 5px;
    font-weight: 600;
}

/* ── PILLS ROW ──────────────────────────────────────────────── */
.profile-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    max-width: 700px;
}

.profile-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    padding: 5px 14px;
    font-size: 0.78rem;
    color: #aaa;
    letter-spacing: 0.5px;
    font-weight: 500;
    transition: all 0.2s;
}

.profile-pill strong {
    color: #fff;
    font-weight: 700;
}

.profile-pill:hover {
    border-color: rgba(229, 9, 20, 0.4);
    background: rgba(229, 9, 20, 0.08);
}

/* ── MAIN BODY CONTAINER ────────────────────────────────────── */
.profile-body {
    padding: 40px 0 60px;
}

/* ── SECTION TITLE ──────────────────────────────────────────── */
.section-title {
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--primary-red, #e50914);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin: 0 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(229, 9, 20, 0.3);
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title::before {
    content: '';
    display: inline-block;
    width: 3px;
    height: 14px;
    background: var(--primary-red, #e50914);
    border-radius: 2px;
    flex-shrink: 0;
}

/* ── INFO CARD ──────────────────────────────────────────────── */
.fighter-info-card {
    background: #111;
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 32px;
    border: 1px solid #1e1e1e;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
}

.info-item {
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
    transition: background 0.2s;
}

.info-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.info-label {
    font-size: 0.65rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    margin-bottom: 4px;
}

.info-value {
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.bio-text {
    color: #999;
    line-height: 1.7;
    font-size: 0.95rem;
    font-family: 'Barlow', sans-serif;
    border-top: 1px solid #1e1e1e;
    padding-top: 20px;
    margin-top: 16px;
}

/* ── QUICK STATS CARD ───────────────────────────────────────── */
.quick-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 0;
}

.quick-stat-box {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #1e1e1e;
    border-radius: 8px;
    padding: 16px 12px;
    text-align: center;
    transition: border-color 0.2s;
}

.quick-stat-box:hover {
    border-color: #333;
}

.quick-stat-number {
    font-size: 2.2rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 4px;
    letter-spacing: 0.02em;
}

.quick-stat-label {
    font-size: 0.62rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
}

/* ── MATCH CARDS ────────────────────────────────────────────── */
.match-card {
    background: #111;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 12px;
    border: 1px solid #1e1e1e;
    transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.match-card:hover {
    border-color: rgba(229, 9, 20, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.match-header {
    background: #161616;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #1e1e1e;
}

.match-date {
    font-size: 0.72rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
}

.match-event {
    font-size: 0.85rem;
    color: #bbb;
    font-weight: 600;
    text-align: right;
    max-width: 55%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.match-body {
    padding: 18px 20px;
}

/* Fighter vs Fighter row */
.match-fighters {
    display: grid;
    grid-template-columns: 1fr 48px 1fr;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.fighter-side {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.fighter-side.right {
    text-align: right;
    align-items: flex-end;
}

.fighter-name-small {
    font-size: 1.05rem;
    font-weight: 800;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.1;
}

.fighter-record-small {
    font-size: 0.72rem;
    color: #555;
    letter-spacing: 1px;
}

.result-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-top: 4px;
}

.result-badge.win {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.result-badge.loss {
    background: rgba(229, 9, 20, 0.15);
    color: #e55;
    border: 1px solid rgba(229, 9, 20, 0.3);
}

.result-badge.draw {
    background: rgba(170, 170, 170, 0.1);
    color: #888;
    border: 1px solid rgba(170, 170, 170, 0.2);
}

.result-badge.opp {
    background: transparent;
    color: #444;
    border: 1px solid #222;
}

.vs-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(229, 9, 20, 0.08);
    border: 1px solid rgba(229, 9, 20, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 900;
    color: var(--primary-red, #e50914);
    letter-spacing: 1px;
    flex-shrink: 0;
    margin: 0 auto;
}

/* Match details strip */
.match-details {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.match-detail-chip {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #1e1e1e;
    border-radius: 6px;
    padding: 7px 14px;
    flex: 1;
    min-width: 60px;
}

.match-detail-value {
    font-size: 0.88rem;
    font-weight: 700;
    color: #ddd;
    letter-spacing: 0.03em;
    line-height: 1.2;
    text-align: center;
}

.match-detail-label {
    font-size: 0.6rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-top: 3px;
    font-weight: 700;
}

/* ── SIDEBAR CARDS ──────────────────────────────────────────── */
.sidebar-card {
    background: #111;
    border: 1px solid #1e1e1e;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-red, #e50914);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: gap 0.2s, opacity 0.2s;
    margin-bottom: 20px;
}

.back-link:hover {
    opacity: 0.75;
    gap: 12px;
    color: var(--primary-red, #e50914);
}

.division-badge {
    background: rgba(229, 9, 20, 0.1);
    border: 1px solid rgba(229, 9, 20, 0.3);
    border-radius: 8px;
    padding: 14px 18px;
    text-align: center;
}

.division-name {
    font-size: 1rem;
    font-weight: 800;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.division-weight {
    font-size: 0.75rem;
    color: #666;
    letter-spacing: 1px;
    margin-top: 4px;
}

.api-status-box {
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    border: 1px solid #1a1a1a;
    background: #0d0d0d;
    color: #555;
}

.api-status-box.live {
    border-color: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.api-status-box.verified {
    border-color: rgba(245, 158, 11, 0.25);
    color: #f59e0b;
}

.api-status-box code {
    font-size: 0.7rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 1px 5px;
    border-radius: 3px;
    color: #888;
}

/* ── EMPTY STATE ────────────────────────────────────────────── */
.empty-fights {
    background: #111;
    border: 1px dashed #222;
    border-radius: 10px;
    padding: 50px 30px;
    text-align: center;
    color: #444;
    margin-bottom: 30px;
}

.empty-fights i {
    font-size: 2.5rem;
    margin-bottom: 16px;
    display: block;
    color: #2a2a2a;
}

.empty-fights a {
    color: var(--primary-red, #e50914);
}

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media (max-width: 991px) {
    .info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-item {
        padding: 16px 20px;
    }

    .fighter-hero-image {
        max-width: 400px;
    }
}

@media (max-width: 768px) {
    .fighter-header-content {
        padding: 60px 16px 36px;
        min-height: 280px;
    }

    .fighter-hero-image {
        max-width: 100%;
    }

    .fighter-name {
        font-size: 2.2rem;
    }

    .fighter-stats {
        flex-wrap: wrap;
        border-radius: 10px;
    }

    .stat-item {
        padding: 14px 16px;
        min-width: 80px;
    }

    .stat-value {
        font-size: 1.8rem;
    }

    .info-grid {
        grid-template-columns: 1fr 1fr;
    }

    .match-fighters {
        grid-template-columns: 1fr 36px 1fr;
    }

    .vs-circle {
        width: 36px;
        height: 36px;
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    .fighter-header-content {
        padding: 50px 12px 28px;
        min-height: 240px;
    }

    .fighter-hero-image {
        border-radius: 8px;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .match-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .match-event {
        max-width: 100%;
        text-align: left;
    }

    .match-detail-chip {
        padding: 6px 10px;
    }

    .profile-pills {
        gap: 6px;
    }

    .stat-item {
        min-width: 70px;
        padding: 12px 10px;
    }
}