html, body {
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    background: linear-gradient(180deg,
        #0f0f0f 0%, #101a2a 30%, #1a0f12 60%, #141414 100%);
    font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
    min-height: 100%;
}

html { overflow-y: scroll; }
* { box-sizing: border-box; margin: 0; padding: 0; }

.profile-container {
    max-width: 952px;
    margin: 0 auto;
    padding: 112px 16px 60px;
}

/* ── Header ──────────────────────────────────────────────── */
.profile-header {
    display: flex;
    align-items: flex-start;
    gap: 24px;
    margin-bottom: 32px;
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff3b3b, #ff7a18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 28px;
    font-weight: 700;
    flex-shrink: 0;
}

.profile-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.profile-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-username {
    color: #fff;
    font-size: 24px;
    font-weight: 700;
    margin: 0;
}

.profile-private-badge {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    color: #555;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
}

.profile-stats {
    display: flex;
    gap: 28px;
}

.profile-stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.stat-value {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}

.stat-label {
    color: #555;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

/* ── Botones follow ──────────────────────────────────────── */
.profile-follow {
    flex-shrink: 0;
    padding-top: 4px;
}

.btn-follow {
    padding: 8px 20px;
    background: linear-gradient(90deg, #ff3b3b, #ff7a18);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}

.btn-follow:hover { opacity: 0.85; }

.btn-unfollow {
    padding: 8px 20px;
    background: none;
    border: 1px solid #333;
    border-radius: 8px;
    color: #777;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.btn-unfollow:hover {
    border-color: #ff3b3b;
    color: #ff3b3b;
}

.btn-requested {
    padding: 8px 20px;
    background: none;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    color: #555;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: default;
}

/* ── Cuenta privada ──────────────────────────────────────── */
.profile-private {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 60px 0;
    text-align: center;
}

.profile-private p {
    color: #555;
    font-size: 15px;
    font-weight: 700;
}

.profile-private-sub {
    color: #333 !important;
    font-size: 13px !important;
    font-weight: 400 !important;
}

/* ── Contenido ───────────────────────────────────────────── */
.profile-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 40px;
    align-items: flex-start;
}

.profile-section-title {
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 16px;
}

/* ── Listas ──────────────────────────────────────────────── */
.profile-lists {
    display: flex;
    flex-direction: column;
}

.profile-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #161616;
}

.profile-list-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.profile-list-name {
    color: #ddd;
    font-size: 14px;
    font-weight: 700;
}

.profile-list-count {
    color: #444;
    font-size: 12px;
}

.profile-empty {
    color: #444;
    font-size: 13px;
    padding: 20px 0;
}

/* ── Actividad ───────────────────────────────────────────── */
.profile-activity {
    display: flex;
    flex-direction: column;
}

.activity-item {
    display: flex;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #161616;
    align-items: center;
}

.activity-img {
    width: 36px;
    height: 50px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.activity-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.activity-title {
    color: #ddd;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: color 0.15s;
}

.activity-title:hover { color: #ff3b3b; }

.activity-type {
    color: #555;
    font-size: 12px;
}

.activity-date {
    color: #333;
    font-size: 11px;
}

.separator {
    height: 2px;
    width: 100%;
    border-radius: 2px;
    background: linear-gradient(90deg,
        #ff3b3b 0%, #ff7a18 40%, rgba(255,255,255,0.05) 100%);
}

.profile-avatar-img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

/* ── Bio ─────────────────────────────────────────────────── */
.profile-bio {
    color: #666;
    font-size: 13px;
    line-height: 1.5;
    margin: 4px 0 0;
    max-width: 400px;
}

/* ── Edit profile ────────────────────────────────────────── */
.btn-edit-profile {
    padding: 8px 20px;
    background: none;
    border: 1px solid #333;
    border-radius: 8px;
    color: #777;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s;
    flex-shrink: 0;
    padding-top: 4px;
}

.btn-edit-profile:hover {
    border-color: #ff3b3b;
    color: #fff;
}

/* ── Deep stats ──────────────────────────────────────────── */
.profile-deep-stats {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}

.deep-stat-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #111;
    border: 1px solid #1a1a1a;
    border-radius: 10px;
    padding: 14px 18px;
    flex: 1;
    min-width: 180px;
}

.deep-stat-card > div {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.deep-stat-value {
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.deep-stat-link {
    text-decoration: none;
    transition: color 0.15s;
}

.deep-stat-link:hover { color: #ff3b3b; }

.deep-stat-label {
    color: #444;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

/* ── Géneros favoritos ───────────────────────────────────── */
.profile-genres {
    margin-bottom: 32px;
}

.genre-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}

.genre-bar-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.genre-bar-name {
    color: #aaa;
    font-size: 13px;
    font-weight: 700;
    width: 120px;
    flex-shrink: 0;
}

.genre-bar-track {
    flex: 1;
    height: 6px;
    background: #1a1a1a;
    border-radius: 3px;
    overflow: hidden;
}

.genre-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff3b3b, #ff7a18);
    border-radius: 3px;
    max-width: 100%;
    transition: width 0.4s ease;
}

.genre-bar-count {
    color: #444;
    font-size: 12px;
    font-weight: 700;
    width: 24px;
    text-align: right;
    flex-shrink: 0;
}

/* ── Lista de obligatorias con color ─────────────────────── */
.list-name--obligatory { color: #ff7a18; }
.list-name--custom     { color: #7b8cde; }

@media (max-width: 768px) {

    .profile-container {
        padding-top: 88px;
        padding-bottom: 40px;
    }

    /* Header del perfil */
    .profile-header {
        flex-wrap: wrap;
        gap: 16px;
        margin-bottom: 20px;
    }

    .profile-avatar {
        width: 56px;
        height: 56px;
        font-size: 22px;
    }

    .profile-avatar-img {
        width: 56px;
        height: 56px;
    }

    .profile-username {
        font-size: 18px;
    }

    .profile-bio {
        font-size: 12px;
    }

    /* Stats en scroll horizontal */
    .profile-stats {
        gap: 16px;
        overflow-x: auto;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
    }

    .profile-stat {
        flex-shrink: 0;
    }

    .stat-value {
        font-size: 15px;
    }

    .stat-label {
        font-size: 10px;
    }

    /* Botones follow */
    .btn-follow,
    .btn-unfollow,
    .btn-requested,
    .btn-edit-profile {
        padding: 7px 14px;
        font-size: 12px;
    }

    /* Deep stats */
    .profile-deep-stats {
        flex-direction: column;
        gap: 8px;
    }

    .deep-stat-card {
        min-width: 0;
        padding: 12px 14px;
        gap: 10px;
    }

    .deep-stat-value {
        font-size: 14px;
    }

    .deep-stat-label {
        font-size: 10px;
    }

    /* Géneros favoritos */
    .genre-bar-name {
        width: 90px;
        font-size: 12px;
    }

    .genre-bar-count {
        font-size: 11px;
    }

    /* Contenido — de 2 columnas a 1 */
    .profile-content {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .profile-section-title {
        font-size: 15px;
        margin-bottom: 12px;
    }

    /* Listas */
    .profile-list-name {
        font-size: 13px;
    }

    .profile-list-count {
        font-size: 11px;
    }

    /* Actividad */
    .activity-item {
        padding: 10px 0;
        gap: 12px;
    }

    .activity-img {
        width: 32px;
        height: 44px;
    }

    .activity-title {
        font-size: 12px;
    }

    .activity-type {
        font-size: 11px;
    }

    .activity-date {
        font-size: 10px;
    }

    /* Cuenta privada */
    .profile-private {
        padding: 40px 0;
    }

    .profile-private p {
        font-size: 14px;
    }

    /* Listas — más compactas */
    .profile-list-item {
        padding: 10px 0;
    }

    .profile-list-name {
        font-size: 13px;
        font-weight: 700;
    }

    .profile-list-count {
        font-size: 11px;
    }

    /* Géneros favoritos más compactos */
    .profile-genres {
        margin-bottom: 24px;
    }

    .genre-bars {
        gap: 8px;
        margin-top: 10px;
    }

    .genre-bar-item {
        gap: 8px;
    }

    .genre-bar-name {
        width: 80px;
        font-size: 11px;
    }

    .genre-bar-track {
        height: 5px;
    }

    .genre-bar-count {
        font-size: 11px;
        width: 20px;
    }

    /* Deep stats más compactas en móvil */
    .deep-stat-card {
        padding: 10px 12px;
        gap: 8px;
    }

    .deep-stat-value {
        font-size: 13px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 180px;
    }

    /* Private badge */
    .profile-private-badge {
        font-size: 10px;
        padding: 2px 6px;
    }

    /* Separador */
    .separator {
        margin-bottom: 20px;
    }
}

.stat-link {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-decoration: none;
    transition: opacity 0.15s;
}

.stat-link:hover { opacity: 0.8; }

.stat-link .stat-value { color: #fff; }
.stat-link .stat-label { color: #555; }

.activity-edit-btn {
    background: none;
    border: 1px solid #222;
    border-radius: 6px;
    color: #555;
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    cursor: pointer;
    margin-top: 4px;
    transition: border-color 0.2s, color 0.2s;
    display: inline-block;
}

.activity-edit-btn:hover {
    border-color: #ff3b3b;
    color: #fff;
}