/* ===================================
   AVATAR VIEW PAGE - AIBIMB
   Aligned with base.css design system
   More welcoming and professional
   =================================== */

/* ===== HERO SECTION - Softer Background ===== */
.avatar-detail-hero {
    background: linear-gradient(180deg, var(--gray-50) 0%, #ffffff 100%);
    padding: 2.5rem 0;
    position: relative;
    overflow: hidden;
}

.avatar-detail-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(102, 126, 234, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(118, 75, 162, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

/* ===== PROFILE CARD ===== */
.avatar-profile-card {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    padding: 2.5rem;
    position: relative;
    z-index: 2;
    max-width: 1000px;
    margin: 0 auto;
    border: 1px solid var(--gray-200);
}

.avatar-header-grid {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 2.5rem;
    align-items: start;
    margin-bottom: 2rem;
}

/* ===== AVATAR IMAGE ===== */
.avatar-image-container {
    position: relative;
    width: 180px;
    height: 180px;
}

.avatar-image-container img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-xl);
    object-fit: cover;
    border: 4px solid white;
    box-shadow: var(--shadow-md);
}

/* ===== STATUS BADGE - Subtle Animation ===== */
.avatar-status-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: var(--success-500);
    border: 4px solid white;
    border-radius: var(--radius-full);
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
    animation: pulse-soft 3s infinite;
}

@keyframes pulse-soft {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.03);
        opacity: 0.95;
    }
}

/* ===== TYPOGRAPHY ===== */
.avatar-main-info {
    padding-top: 0.5rem;
}

.avatar-title {
    font-size: 2rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

/* ===== BADGES - Subtle Design ===== */
.avatar-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.9rem;
    border-radius: var(--radius-lg);
    font-size: 0.825rem;
    font-weight: 500;
    transition: var(--transition-normal);
    border: 1px solid;
}

.badge-pill:hover {
    transform: translateY(-1px);
}

.badge-category {
    background: var(--primary-50);
    color: var(--primary-700);
    border-color: var(--primary-200);
}

.badge-category:hover {
    background: var(--primary-100);
}

.badge-language {
    background: var(--warning-50);
    color: var(--warning-700);
    border-color: var(--warning-200);
}

.badge-language:hover {
    background: var(--warning-100);
}

.badge-experience {
    background: var(--gray-50);
    color: var(--gray-700);
    border-color: var(--gray-200);
}

.badge-experience:hover {
    background: var(--gray-100);
}

/* ===== DESCRIPTION ===== */
.avatar-description {
    color: var(--gray-600);
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

/* ===== RATING ===== */
.rating-display {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.rating-stars {
    color: var(--warning-400);
    font-size: 1.2rem;
    display: flex;
    gap: 0.25rem;
}

/* ===== STATS - Lighter Design ===== */
.avatar-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    padding: 2rem 0 1.5rem;
    border-top: 1px solid var(--gray-200);
}

.stat-card {
    text-align: center;
    padding: 1rem;
    border-radius: var(--radius-lg);
    background: white;
    transition: var(--transition-normal);
    border: 1px solid var(--gray-100);
}

.stat-card:hover {
    background: var(--gray-50);
    border-color: var(--primary-200);
}

.stat-number {
    display: block;
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--gray-900);
    line-height: 1.2;
    margin-bottom: 0.4rem;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* ===== CTA BUTTONS ===== */
.cta-section {
    margin-top: 2rem;
    text-align: center;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.btn-cta {
    padding: 1rem 2rem;
    border-radius: var(--radius-xl);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition-normal);
    border: none;
    min-width: 180px;
    justify-content: center;
    cursor: pointer;
}

.btn-cta.btn-primary {
    background: var(--primary-500);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
}

.btn-cta.btn-primary:hover {
    background: var(--primary-600);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: white;
}

.btn-cta.btn-secondary {
    background: white;
    color: var(--gray-600);
    border: 2px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
}

.btn-cta.btn-secondary:hover {
    border-color: var(--primary-500);
    color: var(--primary-600);
    background: var(--gray-50);
    transform: translateY(-1px);
}

/* ===== CONTENT SECTIONS ===== */
.content-wrapper {
    max-width: 1000px;
    margin: 0 auto;
}

.content-section {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--gray-200);
}

.section-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--gray-200);
}

.section-title {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    line-height: 1.3;
}

.section-icon {
    width: 36px;
    height: 36px;
    background: var(--primary-100);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-600);
    font-size: 1rem;
    flex-shrink: 0;
    border: 1px solid var(--primary-200);
}

/* ===== BIO TEXT ===== */
.bio-text {
    color: var(--gray-600);
    line-height: 1.7;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    text-align: left;
}

/* ===== EXPERTISE CARDS ===== */
.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 0.875rem;
    margin-top: 1.25rem;
}

.expertise-card {
    background: var(--gray-50);
    padding: 1rem 1.25rem;
    border-radius: var(--radius-lg);
    border-left: 3px solid var(--primary-500);
    transition: var(--transition-normal);
    border: 1px solid var(--gray-200);
    border-left-width: 3px;
    border-left-color: var(--primary-500);
}

.expertise-card:hover {
    background: white;
    border-left-color: var(--primary-600);
    box-shadow: var(--shadow-sm);
}

.expertise-card-text {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ===== EDUCATION & ACHIEVEMENTS ===== */
.education-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.education-item {
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    border-left: 3px solid var(--primary-500);
    display: block;
    transition: var(--transition-normal);
    border: 1px solid var(--gray-200);
    border-left-width: 3px;
    border-left-color: var(--primary-500);
}

.education-item:hover {
    background: white;
    box-shadow: var(--shadow-sm);
}

.education-text {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ===== EXPERIENCE HIGHLIGHT ===== */
.experience-highlight {
    margin-top: 1.5rem;
    padding: 1.25rem 1.5rem;
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    border-left: 3px solid var(--primary-500);
    border: 1px solid var(--gray-200);
    border-left: 3px solid var(--primary-500);
}

.experience-highlight-content {
    color: var(--gray-700);
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
}

.experience-highlight i {
    font-size: 1.2rem;
    color: var(--primary-600);
}

/* ===== AUDIENCE PERSONAS ===== */
.audience-personas-section {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--gray-200);
}

.personas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.persona-card {
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 1px solid var(--gray-200);
    transition: var(--transition-normal);
}

.persona-card:hover {
    background: white;
    border-color: var(--primary-200);
    box-shadow: var(--shadow-sm);
}

.persona-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.persona-icon {
    width: 30px;
    height: 30px;
    background: var(--primary-100);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-600);
    font-size: 0.85rem;
    border: 1px solid var(--primary-200);
}

.persona-description {
    color: var(--gray-500);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.25rem;
}

.persona-goals {
    list-style: none;
    padding: 0;
    margin: 0;
}

.persona-goal {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: white;
    border-radius: var(--radius-md);
    color: var(--gray-600);
    font-size: 0.9rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    line-height: 1.5;
}

.persona-goal::before {
    content: '✓';
    color: var(--success-500);
    font-weight: 700;
    flex-shrink: 0;
}

/* ===== CHANNEL SHOWCASE ===== */
.channel-showcase {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    padding: 2.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--gray-100);
}

.channel-grid {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 2rem;
    align-items: center;
}

.channel-avatar-large {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-xl);
    object-fit: cover;
    box-shadow: var(--shadow-lg);
    transition: var(--transition-slow);
}

.channel-avatar-large:hover {
    transform: scale(1.05);
}

.channel-info h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.channel-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.youtube-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: var(--danger-600);
    color: white;
    border-radius: var(--radius-lg);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-slow);
}

.youtube-link:hover {
    background: var(--danger-700);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(220, 38, 38, 0.3);
    color: white;
}

.channel-stats-grid {
    display: flex;
    gap: 2rem;
}

.channel-stat {
    text-align: center;
    padding: 1rem 1.5rem;
    background: var(--primary-50);
    border-radius: var(--radius-lg);
}

.stat-value {
    display: block;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--primary-600);
}

.stat-label-small {
    font-size: 0.875rem;
    color: var(--gray-600);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.topics-showcase {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--gray-200);
}

.topics-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.topic-tag {
    padding: 0.625rem 1.125rem;
    background: var(--gray-100);
    color: var(--gray-700);
    border-radius: var(--radius-xl);
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition-normal);
}

.topic-tag:hover {
    background: var(--primary-500);
    color: white;
    transform: translateY(-2px);
}

/* ===== SHARE MENU ===== */
.share-dropdown {
    position: relative;
    display: inline-block;
    z-index: 99999;
}

.share-menu {
    position: fixed;
    top: 0;
    left: 0;
    transform: translateX(-50%);
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--gray-200);
    min-width: 240px;
    z-index: 99999;
    display: none;
    padding: 0.75rem 0;
}

.share-menu.show {
    display: block;
}

.share-option {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.875rem 1.5rem;
    color: var(--gray-600);
    text-decoration: none;
    transition: var(--transition-normal);
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-weight: 600;
}

.share-option:hover {
    background: var(--gray-50);
    color: var(--gray-800);
}

.share-option.whatsapp {
    color: var(--success-500);
}

.share-option.whatsapp:hover {
    background: var(--success-500);
    color: white;
}

/* ===== STICKY CTA BAR ===== */
.sticky-cta-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    padding: 0.75rem 1rem calc(env(safe-area-inset-bottom) + 0.75rem);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: saturate(180%) blur(20px);
    border-top: 1px solid var(--gray-200);
    box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.08);
    z-index: 9999;
    display: none;
}

.sticky-cta-btn {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    min-height: 52px;
    padding: 0.875rem 1.25rem;
    border-radius: var(--radius-xl);
    font-weight: 600;
    font-size: 1rem;
    color: white;
    text-decoration: none;
    background: var(--primary-500);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
    transition: var(--transition-normal);
}

.sticky-cta-btn:active {
    transform: scale(0.98);
}

body.has-sticky-cta {
    padding-bottom: 100px;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 968px) {
    .avatar-header-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .avatar-image-container {
        margin: 0 auto;
    }

    .avatar-title {
        font-size: 1.75rem;
        text-align: center;
    }

    .avatar-badges {
        justify-content: center;
    }

    .avatar-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .channel-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1.5rem;
    }

    .channel-avatar-large {
        margin: 0 auto;
    }

    .channel-meta {
        justify-content: center;
    }

    .channel-stats-grid {
        justify-content: center;
    }

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

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

@media (max-width: 640px) {
    .avatar-detail-hero {
        padding: 2rem 0;
    }

    .avatar-profile-card {
        padding: 1.75rem 1.25rem;
        margin: 0 1rem;
        border-radius: var(--radius-lg);
    }

    .content-section,
    .audience-personas-section,
    .channel-showcase {
        padding: 1.5rem 1.25rem;
        margin: 0 1rem 1.25rem;
        border-radius: var(--radius-lg);
    }

    .avatar-image-container {
        width: 120px;
        height: 120px;
    }

    .avatar-title {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.15rem;
        justify-content: flex-start;
    }

    .section-header {
        text-align: left;
    }

    .section-icon {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }

    .cta-buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn-cta {
        width: 100%;
    }

    .avatar-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
        padding: 1.5rem 0;
    }

    .stat-card {
        padding: 0.75rem 0.5rem;
    }

    .stat-number {
        font-size: 1.5rem;
    }

    .stat-label {
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    .avatar-detail-hero {
        padding: 1.5rem 0;
    }

    .avatar-profile-card {
        padding: 1.5rem 1rem;
        margin: 0 0.5rem;
    }

    .content-section,
    .channel-showcase,
    .audience-personas-section {
        padding: 1.5rem 1rem;
        margin: 0 0.5rem 1.25rem;
    }

    .avatar-image-container {
        width: 100px;
        height: 100px;
    }

    .avatar-title {
        font-size: 1.4rem;
    }

    .section-title {
        justify-content: flex-start;
    }

    .section-header {
        text-align: left;
    }
}

@media (min-width: 968px) {
    .sticky-cta-bar {
        padding-left: 0;
        padding-right: 0;
    }

    .sticky-cta-bar .sticky-cta-btn {
        width: 360px;
        margin: 0 auto;
    }
}