/* fanlinks_v2.css */

/* 1. Main Wrapper */
.fanlinks-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow-y: auto; 
    z-index: 1;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
    
    background-color: #000;
}


/* Page Title & Description */
.fan-page-title {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}
.fan-page-description {
    font-size: 0.9375rem;
    font-weight: 400;
    margin-top: 0.25rem;
    opacity: 0.85;
    line-height: 1.4;
}
.fan-title-block {
    margin-bottom: 0.75rem;
}

/* 2. Phone Container */
.fan-container {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100vh;
    padding-bottom: 80px;
    position: relative;
    z-index: 2;
}

/* 3. Header */
.fan-header {
    position: relative;
    width: 100%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    margin-bottom: 20px;
    padding-top: 20px;
}
.fan-header img {
    max-width: 90%;
    height: auto;
    max-height: 250px;
    -o-object-fit: contain;
       object-fit: contain;
    border-radius: 8px;
    -webkit-filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
            filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

/* 3B. Header Image Loading Skeleton */
.fan-header[dmx-show]::before {
    content: '';
    display: block;
    width: 80%;
    max-width: 350px;
    height: 100%;
    margin: 0 auto;
    background: -webkit-gradient(
        linear,
        left top, right top,
        from(rgba(255, 255, 255, 0.05)),
        color-stop(50%, rgba(255, 255, 255, 0.1)),
        to(rgba(255, 255, 255, 0.05))
    );
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 0%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 100%
    );
    background-size: 200% 100%;
    -webkit-animation: shimmer 1.5s infinite;
            animation: shimmer 1.5s infinite;
    border-radius: 8px;
    position: absolute;
    top: 20px;
    left: 50%;
    -webkit-transform: translateX(-50%);
            transform: translateX(-50%);
    z-index: 1;
}

.fan-header.loaded::before {
    display: none;
}

.fan-header img {
    position: relative;
    z-index: 2;
}

@-webkit-keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* 3C. Header Video (YouTube Facade) */
.fan-header-video {
    margin-bottom: 20px;
    width: 100%;
    display: flex;
    justify-content: center;
}
.fan-header-yt {
    max-width: 90%;
    width: 100%;
    aspect-ratio: 16 / 9;
    border: none;
    border-radius: 8px;
    -webkit-filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
            filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

/* 4. LINK STYLES */
.link-group {
    margin-bottom: 15px;
    position: relative;
    z-index: 10;
}

.link-btn {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    width: 100%;
    padding: 14px 20px; /* Legacy padding */
    text-decoration: none;
    color: var(--link-border, #fff);
    background-color: var(--link-bg, rgba(255,255,255,0.1));
    border: 2px solid var(--link-border, transparent);
    
    /* Legacy Transition for smoothness */
    -webkit-transition: background-color 0.2s ease-in-out, -webkit-transform 0.1s ease-in-out, -webkit-box-shadow 0.2s ease;
    transition: background-color 0.2s ease-in-out, -webkit-transform 0.1s ease-in-out, -webkit-box-shadow 0.2s ease;
    transition: background-color 0.2s ease-in-out, transform 0.1s ease-in-out, box-shadow 0.2s ease;
    transition: background-color 0.2s ease-in-out, transform 0.1s ease-in-out, box-shadow 0.2s ease, -webkit-transform 0.1s ease-in-out, -webkit-box-shadow 0.2s ease;
    
    cursor: pointer;
    -webkit-box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 2;
}

.link-btn:hover {
    -webkit-transform: translateY(-2px);
            transform: translateY(-2px);
    -webkit-box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    /* Optional: brighten bg on hover */
    -webkit-filter: brightness(1.1);
            filter: brightness(1.1);
}

/* Button Shapes */
.shape-rounded { border-radius: 12px; }
.shape-pill { border-radius: 50px; }
.shape-square { border-radius: 0px; }


.link-content {
    -webkit-box-flex: 1;
        -ms-flex-positive: 1;
            flex-grow: 1;
    text-align: left;
}
.link-title {
    font-weight: 700;
    font-size: 1.4rem;
    display: block;
    line-height: 1.2;
}
.link-desc {
    font-size: 0.95rem;
    opacity: 0.8;
    display: block;
    margin-top: 0px;
}

/* Icons */
.link-icon-left {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    font-size: 1.725rem;
    margin-right: 15px;
    color: currentColor;
}

/* SVG brand icons */
.brand-svg-icon {
    width: 1em;
    height: 1em;
    fill: currentColor;
    -ms-flex-negative: 0;
        flex-shrink: 0;
    vertical-align: middle;
}

/* ROTATION ANIMATION (Matches Legacy exactly) */
.link-toggle-icon { 
    font-size: 1.5rem; 
    margin-left: 10px;
    color: currentColor; 
    display: inline-block;
    
    /* Exact Legacy Timing */
    -webkit-transition: -webkit-transform 0.3s ease-in-out;
    transition: -webkit-transform 0.3s ease-in-out;
    transition: transform 0.3s ease-in-out;
    transition: transform 0.3s ease-in-out, -webkit-transform 0.3s ease-in-out;
    -webkit-transform: rotate(0deg);
            transform: rotate(0deg);
}

/* Rotate 90deg (Legacy Style) */
.link-btn.is-expanded .link-toggle-icon { 
    -webkit-transform: rotate(90deg); 
            transform: rotate(90deg); 
}

/* 5. CHILD CONTAINER (Legacy Logic) */
.child-container-wrapper {
    position: relative;
    padding-left: 25px;
    
    /* Margins moved here to be part of the transition flow */
    margin-top: 8px;
    margin-bottom: 8px;
}

/* The Vertical Line */
.child-connector {
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0; 
    width: 2px;
    background-color: var(--link-border, rgba(255, 255, 255, 0.2));
    opacity: 0.5;
    z-index: 0;
}

.child-link {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    padding: 12px 15px; /* Slightly smaller padding than parent */
    margin-top: 10px;
    
    /* MATCH PARENT STYLING */
    background-color: var(--link-bg, rgba(255,255,255,0.1));
    border: 2px solid var(--link-border, transparent);
    
    border-radius: 12px; /* Match standard rounded shape */
    text-decoration: none;
    
    /* Text Color matches Border Color */
    color: var(--link-border, #fff);
    
    -webkit-transition: all 0.3s ease;
    
    transition: all 0.3s ease;
}

.child-link:hover {
    /* Slight brightness increase on hover */
    -webkit-filter: brightness(1.1);
            filter: brightness(1.1);
    -webkit-transform: translateY(-1px);
            transform: translateY(-1px);
}


/* =========================================
   DESKTOP ENHANCEMENTS (Screens > 992px)
   ========================================= */

/* Default state: QR is hidden on mobile/tablet */
.desktop-qr { display: none; }

@media (min-width: 992px) {
    
    body {
        background-color: #111; 
    }

    /* 2. Constrain the Main Background/Wrapper */
    .fanlinks-wrapper {
        width: 100%;
        max-width: 650px; /* Constrain width (between phone and tablet landscape) */
        
        /* Center the fixed element */
        left: 50%;
        -webkit-transform: translateX(-50%);
                transform: translateX(-50%);
        
        /* Visual separation from the dark body */
        border-left: 1px solid rgba(255,255,255,0.1);
        border-right: 1px solid rgba(255,255,255,0.1);
        -webkit-box-shadow: 0 0 50px rgba(0,0,0,0.5);
                box-shadow: 0 0 50px rgba(0,0,0,0.5);
    }

    /* 3. QR Code Positioning */
    .desktop-qr {
        display: block;
        position: fixed;
        bottom: 30px;

        /* Position to the right of the centered 650px wrapper */
        /* Wrapper is centered at 50%, extends 325px to the right */
        /* QR starts at (50% + 325px + gap) */
        left: calc(50% + 325px + 30px);

        background: white;
        padding: 15px;
        border-radius: 12px;
        text-align: center;
        -webkit-box-shadow: 0 5px 20px rgba(0,0,0,0.4);
                box-shadow: 0 5px 20px rgba(0,0,0,0.4);
        z-index: 100;
    }

    /* Responsive QR sizing - max 150px, scale down on smaller screens */
    .desktop-qr img {
        width: 100px;
        height: 100px;
        max-width: 150px;
        max-height: 150px;
    }

    .desktop-qr p {
        color: #333;
        margin-top: 8px;
        font-weight: bold;
        font-size: 0.9rem;
        margin-bottom: 0;
    }
}

/* Scale up QR on medium screens */
@media (min-width: 1200px) {
    .desktop-qr img {
        width: 130px;
        height: 130px;
    }
}

/* Max size on large screens */
@media (min-width: 1400px) {
    .desktop-qr img {
        width: 150px;
        height: 150px;
    }
}

