/* Tier Infographic Modal Styles */
.infographic-modal-content {
    max-width: 800px;
    width: 95vw;
    max-height: 90vh;
    height: 90vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(to bottom, rgba(30, 30, 30, 0.95) 10%, rgba(0, 0, 0, 1) 20%);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    position: relative;
    overflow-y: auto;
    padding-top: 0;
    padding-bottom: 20px;
    scrollbar-width: thin;
    scrollbar-color: var(--secondary-color) var(--semi-transparent-bg);
}

/* Close Button */
.infographic-modal-content .close-comment {
    position: absolute;
    right: 15px;
    top: 15px;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 28px;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    z-index: 10;
    transition: color 0.2s ease;
}

.infographic-modal-content .close-comment:hover {
    color: var(--primary-color);
}

/* Scrollbar styling for infographic modal */
.infographic-modal-content::-webkit-scrollbar {
    width: 8px;
}

.infographic-modal-content::-webkit-scrollbar-track {
    background: var(--semi-transparent-bg);
    border-radius: 4px;
}

.infographic-modal-content::-webkit-scrollbar-thumb {
    background: var(--secondary-color);
    border-radius: 4px;
}

.infographic-modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Main Content Area - Side by Side Layout */
.tier-main-content {
    display: flex;
    align-items: flex-start;
    flex: 1;
    min-height: 0;
}

/* Tier Selector Container */
.tier-selector-container {
    display: flex;
    align-items: center;
    align-self: center;
    justify-content: flex-start;
    gap: 15px;
    flex-shrink: 0;
    width: auto;
    border-top: 2px solid rgba(255, 255, 255, 0.1);
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    margin-top: 0;
}

.tier-nav-btn {
    display: none;
}

.tier-selector-track {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}


/* Right Content Area */
.tier-right-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-height: 0;
    position: relative;
}

/* Tier Description Wrapper */
.tier-description-wrapper {
    position: relative;
    padding-bottom: 10px;
}

/* Tier Benefits Heading */
.tier-benefits-heading {
    font-family: "Montserrat", sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
    margin: 0 0 15px 0;
}

/* Fixed down arrows positioned relative to tier description wrapper */
.tier-description-wrapper::before,
.tier-description-wrapper::after {
    content: '';
    border: solid var(--primary-color);
    border-width: 0 3px 3px 0;
    display: inline-block;
    padding: 5px;
    transform: rotate(45deg);
    position: absolute;
    top: 0px;
    z-index: 5;
    pointer-events: none;
}

.tier-description-wrapper::before {
    left: calc(50% - 170px);
}

.tier-description-wrapper::after {
    right: calc(50% - 170px);
}

/* Individual Tier Buttons */
.tier-button {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 2px solid rgba(255, 255, 255, 0.1);
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    border-left: none;
    border-right: none;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 120px;
    position: relative;
}

.tier-crest-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.tier-button::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 30px;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
    pointer-events: none;
    z-index: 1;
}

.tier-button:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.tier-button.active {
    border-color: var(--primary-color);
    background: rgba(215, 168, 78, 0.15);
}

.tier-crest {
    width: 36px;
    height: 36px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.tier-crest[src*="challengerplus"] {
    width: 50px;
    height: 36px;
}

.tier-roman {
    font-family: 'Times New Roman', Times, serif;
    font-variant: normal;
    letter-spacing: 0.05em;
    font-size: 1.0rem;
    font-weight: 700;
    color: var(--text-color);
    text-transform: uppercase;
    width: 30px;
    text-align: center;
    flex-shrink: 0;
}


.tier-button.active .tier-roman {
    color: var(--primary-color);
}

/* Current Tier Display */
.current-tier-display {
    text-align: center;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    padding: 10px;
}

/* Tier Description */
.tier-description {
    text-align: center;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    text-transform: none;
    font-style: italic;
    letter-spacing: 1px;
    padding: 0 60px;
    opacity: 0.9;
    position: relative;
    height: 4.5em;
    width: 100%;
    line-height: 1.4;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) transparent;
}

/* When content fits (no scrollbar needed) */
.tier-description.centered {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* When content overflows (scrollbar needed) */
.tier-description.scrollable {
    display: block;
}

/* Yellow scrollbar styling for tier description */
.tier-description::-webkit-scrollbar {
    width: 6px;
}

.tier-description::-webkit-scrollbar-track {
    background: transparent;
}

.tier-description::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

.tier-description::-webkit-scrollbar-thumb:hover {
    background: #f4d442;
}

.tier-description-content {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
}

/* Remove hyphens from tier-description - they'll be added to the parent container */

/* Removed ::before and ::after decorative elements for better multi-line display */

/* Profile Container */
.tier-profile-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0;
    height: auto;
    overflow: visible;
    container-type: inline-size;
}

.infographic-profile-container {
    background: rgba(30, 30, 30, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    width: calc(100% - 35px);
    max-width: calc(100% - 35px);
    box-sizing: border-box;
    height: auto;
    overflow: hidden;
    padding: 20px;
    transform-origin: top center;
    margin: 0 20px 20px 15px;
    /* Default for embedded - 3 cards */
    --items-per-view: 3;
    animation: profileDepthEffect 3s cubic-bezier(0.4, 0, 0.6, 1) infinite alternate;
    position: relative;
}

.infographic-profile-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 20px,
        rgba(255, 255, 255, 0.02) 22px,
        rgba(255, 255, 255, 0.02) 24px
    );
    pointer-events: none;
    border-radius: 12px;
}

@keyframes profileDepthEffect {
    0% {
        box-shadow:
            0 0 8px rgba(215, 168, 78, 0.2),
            0 0 16px rgba(215, 168, 78, 0.1),
            0 0 24px rgba(215, 168, 78, 0.05);
    }
    100% {
        box-shadow:
            0 0 12px rgba(215, 168, 78, 0.4),
            0 0 24px rgba(215, 168, 78, 0.2),
            0 0 36px rgba(215, 168, 78, 0.1);
    }
}

/* Dynamic scaling based on viewport width (converted from container queries) */

/* Fix for embedded profile modal root element */
.infographic-profile-container .profile-modal {
    height: auto;
    margin: 0;
    padding: 0;
}

/* Ensure embedded profile modal content fits within the container */
.infographic-profile-container .profile-modal-content {
    width: 100% !important;
    max-width: 100% !important;
    min-width: unset !important;
    height: auto !important;
    max-height: none !important;
    overflow: hidden !important;
    box-sizing: border-box;
}

/* Prevent any content from exceeding container bounds */
.infographic-profile-container * {
    max-width: 100%;
    box-sizing: border-box;
}

/* Exception for tooltips - they need to extend beyond parent boundaries */
.infographic-profile-container .arrow-unlock-tooltip,
.infographic-profile-container .custom-tooltip,
.infographic-profile-container .tab-lock-tooltip,
.infographic-profile-container .items-unlock-tooltip,
.infographic-profile-container .augments-unlock-tooltip,
.infographic-profile-container .match-history-unlock-tooltip {
    max-width: none;
}



/* Live game message */
.live-game-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

.live-game-message {
    text-align: center;
    color: var(--text-color);
    opacity: 0.7;
}

.live-game-message p {
    font-size: 1.1rem;
    font-weight: 500;
}

/* Top Section */
.infographic-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 20px;
    padding-bottom: 20px;
    position: relative;
}




.infographic-top > * {
    position: relative;
    z-index: 2;
}

.support-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
}
.benefits-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
    text-decoration: none;
    position: relative;
}

.benefits-text::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--primary-color), transparent);
}

.upgrade-btn-final {
    padding: 10px 20px;
    border: none;
    background: var(--secondary-color);
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0px;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    letter-spacing: 2px;
}

.upgrade-btn-final:hover {
    background: var(--primary-color);
    transform: scale(1.05);
    box-shadow: 0 5px 15px var(--highlight-color);
}

/* Mobile Responsive Styles */
@media screen and (max-width: 768px) {

    .tier-button {
        width: 90px;
        padding: 12px 0px;
        gap: 8px;
    }

    .tier-crest {
        width: 28px;
        height: 28px;
    }

    .tier-crest[src*="challengerplus"] {
        width: 39px;
        height: 28px;
    }

    .tier-roman {
        font-family: 'Times New Roman', Times, serif;
        font-variant: normal;
        letter-spacing: 0.05em;
        font-size: 0.9rem;
    }

    .current-tier-display {
        font-size: 1.2rem;
        letter-spacing: 1px;
    }

    .tier-description {
        font-size: 1rem;
        padding: 0 40px;
        height: 4em;
    }

    .tier-profile-container {
        height: auto;
        padding: 15px 0;
        margin-left: 0px;
        margin-bottom: -25px;
    }

    .infographic-profile-container {
        max-width: 100%;
        width: calc((100% - 35px) / 0.95);
        height: auto;
        padding: 15px;
        transform: scale(0.95);
    }

    .tier-nav-btn {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }

    .upgrade-btn-final {
        min-width: 180px;
        padding: 8px 15px;
        font-size: 0.9rem;
    }
}

/* Embedded container responsive breakpoints using media queries */
@media (max-width: 800px) {
    .infographic-profile-container {
        --items-per-view: 2;
    }
}

@media screen and (max-width: 700px) {
    .tier-profile-container {
        margin-left: 0px;
        margin-bottom: -25px;
    }

    .infographic-profile-container {
        width: calc((100% - 35px) / 0.95);
    }
}

@media screen and (max-width: 550px) {
    .tier-profile-container {
        margin-left: -10px;
        margin-bottom: -25px;
    }

    .infographic-profile-container {
        width: calc((100% - 35px) / 0.9);
        transform: scale(0.9);
        margin: 0;
        --items-per-view: 1;
    }
}

@media screen and (max-width: 480px) {
    .infographic-modal-content {
        width: 95vw;
        height: 100vh;
        padding: 15px;
        border-radius: 0;
        gap: 15px;
    }


    .tier-crest {
        width: 24px;
        height: 24px;
    }

    .tier-crest[src*="challengerplus"] {
        width: 33px;
        height: 24px;
    }

    .tier-roman {
        font-family: 'Times New Roman', Times, serif;
        font-variant: normal;
        letter-spacing: 0.05em;
        font-size: 0.9rem;
    }

    .current-tier-display {
        font-size: 1.1rem;
    }

    .tier-description {
        font-size: 0.9rem;
        padding: 0 20px;
        height: 3.5em;
    }

    .tier-profile-container {
        height: auto;
        padding: 10px 0;
    }

    .infographic-profile-container {
        height: auto;
        padding: 12px;
        transform: scale(0.9);
    }

    .upgrade-btn-final {
        width: 100%;
        min-width: unset;
    }
}



/* Animation for tier switching */
@keyframes tierSwitch {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

.tier-image-carousel img {
    animation: tierSwitch 0.3s ease;
}