/**
 * Hero Section - Animated Full Screen Background
 * 
 * @package Bargtunes
 */

/* Hero Container */
.bargtunes-hero {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000000;
    overflow: hidden;
    isolation: isolate;
}

/* Hero Background Image */
.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://images.unsplash.com/photo-1514320291840-2e0a9bf2a9ae?w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: scroll;
    opacity: 0;
    transform: scale(1.15) translateZ(0);
    border-radius: 0;
    z-index: 5;
    filter: blur(15px) brightness(0.5);
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
    transform-style: preserve-3d;
    will-change: auto;
}

/* Animated State - Locked positioning */
.hero-background.animated {
    position: absolute !important;
    width: calc(100% - 20px) !important;
    height: calc(100% - 20px) !important;
    border-radius: 24px !important;
    top: 10px !important;
    left: 10px !important;
    right: auto !important;
    bottom: auto !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 
                0 10px 30px rgba(0, 0, 0, 0.4),
                inset 0 0 120px rgba(0, 0, 0, 0.2) !important;
    background-attachment: scroll !important;
    transform: scale(1) translateZ(0) !important;
    will-change: auto !important;
}

/* Advanced Cinematic Gradient Overlay - Premium Effect */
.hero-gradient-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 50%;
    z-index: 15;
    opacity: 0;
    pointer-events: none;
    border-radius: 0 0 24px 24px;
    transform: translateZ(0);
    backface-visibility: hidden;
    will-change: auto;
    overflow: hidden;
    
    /* Multi-layer Cinematic Gradient */
    background: 
        /* Layer 1: Main Dark Gradient */
        linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0) 0%,
            rgba(0, 0, 0, 0.02) 5%,
            rgba(0, 0, 0, 0.08) 12%,
            rgba(0, 0, 0, 0.18) 20%,
            rgba(0, 0, 0, 0.32) 30%,
            rgba(0, 0, 0, 0.50) 42%,
            rgba(0, 0, 0, 0.68) 55%,
            rgba(0, 0, 0, 0.82) 68%,
            rgba(0, 0, 0, 0.92) 80%,
            rgba(0, 0, 0, 0.97) 90%,
            rgba(0, 0, 0, 1) 100%
        ),
        /* Layer 2: Radial Vignette from Bottom */
        radial-gradient(
            ellipse 80% 60% at 50% 100%,
            rgba(0, 0, 0, 0.6) 0%,
            rgba(0, 0, 0, 0.3) 40%,
            transparent 80%
        ),
        /* Layer 3: Subtle Side Darkening */
        radial-gradient(
            ellipse 120% 100% at 0% 100%,
            rgba(0, 0, 0, 0.4) 0%,
            transparent 50%
        ),
        radial-gradient(
            ellipse 120% 100% at 100% 100%,
            rgba(0, 0, 0, 0.4) 0%,
            transparent 50%
        );
}

/* Advanced Wave Effect - Top Edge Blur */
.hero-gradient-overlay::before {
    content: '';
    position: absolute;
    top: -40px;
    left: 0;
    right: 0;
    height: 120px;
    background: 
        /* Soft Wave Blur */
        radial-gradient(
            ellipse 150% 120px at 50% 50%,
            transparent 0%,
            transparent 25%,
            rgba(0, 0, 0, 0.03) 35%,
            rgba(0, 0, 0, 0.08) 45%,
            rgba(0, 0, 0, 0.15) 55%,
            rgba(0, 0, 0, 0.25) 70%,
            rgba(0, 0, 0, 0.35) 85%,
            rgba(0, 0, 0, 0.4) 100%
        );
    filter: blur(25px);
    pointer-events: none;
    z-index: 1;
}

/* Atmospheric Glow Effect - Bottom */
.hero-gradient-overlay::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 25%;
    background: 
        /* Deep Shadow at Bottom */
        linear-gradient(
            to bottom,
        transparent 0%,
            rgba(0, 0, 0, 0.3) 30%,
            rgba(0, 0, 0, 0.6) 60%,
            rgba(0, 0, 0, 0.85) 85%,
            rgba(0, 0, 0, 1) 100%
        ),
        /* Subtle Radial Glow */
        radial-gradient(
            ellipse 100% 100% at 50% 100%,
            rgba(0, 0, 0, 0.8) 0%,
            rgba(0, 0, 0, 0.5) 40%,
            transparent 70%
        );
    pointer-events: none;
    z-index: 2;
    border-radius: 0 0 24px 24px;
}

.hero-gradient-overlay.visible {
    opacity: 1;
}

/* Flash Effect */
.hero-flash {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%) scale(1) translateZ(0);
    background: radial-gradient(circle at center, rgba(255,255,255,1) 0%, rgba(255,255,255,0.6) 30%, rgba(255,255,255,0) 60%);
    opacity: 0;
    z-index: 100;
    pointer-events: none;
    backface-visibility: hidden;
}

/* Hero Content */
.hero-content {
    position: relative;
    z-index: 50;
    text-align: center;
    opacity: 0;
    transform: translateY(30px) translateZ(0);
    direction: ltr !important;
    backface-visibility: hidden;
}

/* Artist Name - Bold & Powerful */
.hero-artist-name {
    font-size: clamp(3.5rem, 10vw, 8rem);
    font-weight: 900;
    letter-spacing: 0.05em;
    color: #ffffff;
    margin: 0 0 60px 0;
    text-transform: uppercase;
    position: relative;
    text-shadow: 0 0 60px rgba(255, 255, 255, 0.8), 
                 0 0 30px rgba(255, 255, 255, 0.6);
    font-family: 'Poppins', sans-serif;
    line-height: 1.2;
    direction: ltr !important;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.hero-artist-name span {
    display: inline-block;
    backface-visibility: hidden;
    transform: translateZ(0);
}

/* Social Media Icons Container */
.hero-social {
    display: flex;
    gap: 24px;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transform: translateY(20px) translateZ(0);
    direction: ltr !important;
    backface-visibility: hidden;
}

/* Premium Glassmorphism Circular Social Icon */
.social-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: transparent;
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.85);
    font-size: 24px;
    text-decoration: none;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: visible;
}

/* Minimal Background Glow */
.social-icon::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.social-icon:hover::before {
    opacity: 1;
}

/* Minimal Ring Pulse */
.social-icon::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: -1;
}

.social-icon:hover::after {
    opacity: 1;
    transform: scale(1.15);
}

.social-icon:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.4);
    color: #ffffff;
    transform: translateY(-6px) scale(1.05);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.social-icon:active {
    transform: translateY(-3px) scale(0.98);
}

.social-icon i {
    position: relative;
    z-index: 2;
    font-size: 24px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Icon-specific colors on hover */
.social-icon[aria-label="Instagram"]:hover {
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.15) 0%, rgba(193, 53, 132, 0.15) 50%, rgba(131, 58, 180, 0.15) 100%);
    border-color: rgba(225, 48, 108, 0.5);
    color: #E1306C;
}

.social-icon[aria-label="Spotify"]:hover {
    background: rgba(30, 215, 96, 0.15);
    border-color: rgba(30, 215, 96, 0.5);
    color: #1DB954;
}

.social-icon[aria-label="YouTube"]:hover {
    background: rgba(255, 0, 0, 0.15);
    border-color: rgba(255, 0, 0, 0.5);
    color: #FF0000;
}

.social-icon[aria-label="SoundCloud"]:hover {
    background: rgba(255, 85, 0, 0.15);
    border-color: rgba(255, 85, 0, 0.5);
    color: #FF5500;
}

/* Clean Minimal Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    right: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    z-index: 50;
    opacity: 0;
    transform: translateY(20px) translateZ(0);
    direction: ltr !important;
    backface-visibility: hidden;
}

.scroll-text {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    font-size: 10px;
    font-weight: 300;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
}

.scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0));
    position: relative;
    overflow: hidden;
}

.scroll-line::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 1), transparent);
    animation: scrollLineMove 2.5s ease-in-out infinite;
}

@keyframes scrollLineMove {
    0% {
        top: -100%;
    }
    50%, 100% {
        top: 100%;
    }
}

/* ==========================================
   RESPONSIVE DESIGN - ULTRA ADVANCED
   ========================================== */

/* Large Desktop (1920px+) */
@media (min-width: 1920px) {
    .hero-artist-name {
        font-size: clamp(8rem, 10vw, 10rem);
        margin-bottom: 80px;
    }
    
    .hero-social {
        gap: 35px;
    }
    
    .social-icon {
        width: 60px;
        height: 60px;
        font-size: 26px;
    }
    
    .scroll-indicator {
        bottom: 50px;
        right: 50px;
    }
}

/* Desktop (1440px - 1919px) */
@media (min-width: 1440px) and (max-width: 1919px) {
    .hero-artist-name {
        font-size: clamp(6rem, 9vw, 8rem);
        margin-bottom: 70px;
    }
    
    .hero-social {
        gap: 30px;
    }
    
    .social-icon {
        width: 58px;
        height: 58px;
        font-size: 25px;
    }
}

/* Laptop (1024px - 1439px) */
@media (min-width: 1024px) and (max-width: 1439px) {
    .hero-artist-name {
        font-size: clamp(5rem, 8vw, 7rem);
        margin-bottom: 60px;
    }
    
    .hero-social {
        gap: 28px;
    }
    
    .social-icon {
        width: 54px;
        height: 54px;
        font-size: 23px;
    }
    
    .scroll-indicator {
        bottom: 35px;
        right: 35px;
    }
}

/* Tablet Landscape (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .hero-background {
        background-attachment: scroll;
        border-radius: 20px;
    }
    
    .hero-background.animated {
        width: calc(100% - 16px) !important;
        height: calc(100% - 16px) !important;
        top: 8px !important;
        left: 8px !important;
        right: auto !important;
        bottom: auto !important;
        border-radius: 20px !important;
        background-attachment: scroll !important;
    }
    
    .hero-gradient-overlay {
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: 48%;
        border-radius: 0 0 20px 20px;
    }
    
    .hero-gradient-overlay::after {
        border-radius: 0 0 20px 20px;
    }
    
    .hero-artist-name {
        font-size: clamp(4rem, 7vw, 6rem);
        margin-bottom: 50px;
    }
    
    .hero-social {
        gap: 24px;
    }
    
    .social-icon {
        width: 52px;
        height: 52px;
        font-size: 22px;
    }
    
    .scroll-indicator {
        bottom: 30px;
        right: 30px;
        gap: 12px;
    }
    
    .scroll-text {
        font-size: 9px;
    }
    
    .scroll-line {
        height: 55px;
    }
}

/* Tablet Portrait (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
    .hero-background {
        background-attachment: scroll;
        border-radius: 18px;
    }
    
    .hero-background.animated {
        width: calc(100% - 12px) !important;
        height: calc(100% - 12px) !important;
        top: 6px !important;
        left: 6px !important;
        right: auto !important;
        bottom: auto !important;
        border-radius: 18px !important;
        background-attachment: scroll !important;
    }
    
    .hero-gradient-overlay {
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: 50%;
        border-radius: 0 0 18px 18px;
    }
    
    .hero-gradient-overlay::after {
        border-radius: 0 0 18px 18px;
    }
    
    .hero-artist-name {
        font-size: clamp(3rem, 8vw, 5rem);
        margin-bottom: 45px;
    }
    
    .hero-social {
        gap: 20px;
    }
    
    .social-icon {
        width: 50px;
        height: 50px;
        font-size: 21px;
    }
    
    .scroll-indicator {
        bottom: 25px;
        right: 25px;
    }
    
    .scroll-line {
        height: 50px;
    }
}

/* Mobile Landscape (480px - 599px) */
@media (min-width: 480px) and (max-width: 599px) {
    .hero-background {
        background-attachment: scroll;
        border-radius: 16px;
    }
    
    .hero-background.animated {
        width: calc(100% - 10px) !important;
        height: calc(100% - 10px) !important;
        top: 5px !important;
        left: 5px !important;
        right: auto !important;
        bottom: auto !important;
        border-radius: 16px !important;
        background-attachment: scroll !important;
    }
    
    .hero-gradient-overlay {
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: 52%;
        border-radius: 0 0 16px 16px;
    }
    
    .hero-gradient-overlay::after {
        border-radius: 0 0 16px 16px;
    }
    
    .hero-artist-name {
        font-size: clamp(2.5rem, 9vw, 4rem);
        margin-bottom: 35px;
    }
    
    .hero-social {
        gap: 16px;
    }
    
    .social-icon {
        width: 48px;
        height: 48px;
        font-size: 20px;
    }
    
    .scroll-indicator {
        bottom: 20px;
        right: 20px;
        gap: 10px;
    }
    
    .scroll-line {
        height: 45px;
    }
}

/* Mobile Portrait (max 479px) */
@media (max-width: 479px) {
    .bargtunes-hero {
        height: 100vh;
        height: 100dvh; /* Dynamic viewport for mobile */
    }
    
    .hero-background {
        background-attachment: scroll;
        border-radius: 14px;
    }
    
    .hero-background.animated {
        width: calc(100% - 8px) !important;
        height: calc(100% - 8px) !important;
        top: 4px !important;
        left: 4px !important;
        right: auto !important;
        bottom: auto !important;
        border-radius: 14px !important;
        background-attachment: scroll !important;
    }
    
    .hero-gradient-overlay {
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: 55%;
        border-radius: 0 0 14px 14px;
    }
    
    .hero-gradient-overlay::after {
        border-radius: 0 0 14px 14px;
    }
    
    .hero-content {
        padding: 0 15px;
    }
    
    .hero-artist-name {
        font-size: clamp(2rem, 11vw, 3.5rem);
        margin-bottom: 30px;
        line-height: 1.1;
    }
    
    .hero-social {
        gap: 14px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .social-icon {
        width: 46px;
        height: 46px;
        font-size: 19px;
    }
    
    .scroll-indicator {
        bottom: 18px;
        right: 18px;
        gap: 8px;
    }
    
    .scroll-text {
        font-size: 7px;
    }
    
    .scroll-line {
        height: 42px;
        width: 1.5px;
    }
}

/* Extra Small Mobile (max 359px) */
@media (max-width: 359px) {
    .hero-artist-name {
        font-size: clamp(1.8rem, 12vw, 3rem);
        margin-bottom: 25px;
    }
    
    .hero-social {
        gap: 12px;
    }
    
    .social-icon {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }
    
    .scroll-indicator {
        bottom: 15px;
        right: 15px;
    }
    
    .scroll-line {
        height: 38px;
    }
}

/* Landscape Orientation (all devices) */
@media (orientation: landscape) and (max-height: 650px) {
    .hero-artist-name {
        font-size: clamp(2.5rem, 7vh, 4.5rem);
        margin-bottom: 25px;
    }
    
    .hero-social {
        gap: 18px;
    }
    
    .social-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    .scroll-indicator {
        bottom: 20px;
        right: 20px;
    }
    
    .hero-gradient-overlay {
        height: 58%;
    }
}

/* RTL Support */
body.rtl .scroll-indicator {
    right: 40px !important;
    left: auto !important;
}

@media (max-width: 768px) {
    body.rtl .scroll-indicator {
        right: 20px !important;
    }
}

/* High DPI Screens (Retina) */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-background {
        image-rendering: -webkit-optimize-contrast;
    }
    
    .social-icon,
    .hero-artist-name {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .social-icon:active {
        transform: scale(0.9);
        transition: transform 0.1s ease;
    }
    
    .hero-artist-name {
        user-select: none;
        -webkit-user-select: none;
        -webkit-touch-callout: none;
    }
}

/* Reduced Motion Preference */
@media (prefers-reduced-motion: reduce) {
    .hero-background,
    .hero-flash,
    .hero-gradient-overlay,
    .hero-content,
    .social-icon {
        animation: none !important;
        transition: none !important;
    }
}

/* Ensure icons display properly */
.social-icon i::before {
    display: inline-block;
    font-family: 'Phosphor' !important;
    font-style: normal;
    font-weight: 400;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Additional Premium Effects */
@supports (backdrop-filter: blur(40px)) or (-webkit-backdrop-filter: blur(40px)) {
    .social-icon:hover {
        backdrop-filter: blur(20px) saturate(150%);
        -webkit-backdrop-filter: blur(20px) saturate(150%);
    }
}

