/* ============================================
   DEEP CHAT - CSS Stylesheet
   Based on BSDraft design system with ChatGPT-like UI
   ============================================ */

/* --- RESET & BASE --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    overflow-x: hidden;
    max-width: 100vw;
}

:root {
    --min-font-size: 14px;
    --max-font-size: 18px;
    --responsive-font-size: clamp(var(--min-font-size), 1.1vw, var(--max-font-size));
    --chat-bg: rgba(255, 255, 255, 0.05);
    --user-msg-bg: rgba(52, 152, 219, 0.2);
    --ai-msg-bg: rgba(255, 255, 255, 0.08);
    --input-bg: rgba(255, 255, 255, 0.1);
}

body {
    background-color: #231e3f;
    background-image: radial-gradient(ellipse at 50% 40%,
            rgba(115, 99, 218, 0.25) 0%,
            #231e3f 60%);
    font-family: 'Lilita One', cursive;
    min-height: 100vh;
    color: #fff;
    display: flex;
    flex-direction: column;
    font-size: var(--responsive-font-size);
    overflow-x: hidden;
    max-width: 100vw;
}

/* --- CONTAINER --- */
.container {
    max-width: 100%;
    margin: 0;
    padding: 10px 15px;
    flex-grow: 1;
    width: 100%;
    box-sizing: border-box;
}

/* --- HEADER & NAVIGATION --- */
.header {
    margin-bottom: 20px;
    position: relative;
}

.top-nav-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 25px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: clamp(55px, 5vw, 80px);
    position: relative;
    z-index: 1001;
    width: 98vw;
    left: 50%;
    transform: translateX(-50%);
}

.nav-links-right {
    position: relative;
    display: flex;
    align-items: center;
}

/* Discord Link */
.discord-link {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(88, 101, 242, 0.8);
    padding: 8px 12px;
    border-radius: 15px;
    border: 1px solid rgba(88, 101, 242, 1);
    color: #fff;
    text-decoration: none;
    font-size: clamp(0.9rem, 1.2vw, 1.0rem);
    margin-right: 10px;
    transition: background-color 0.3s ease;
}

.discord-link:hover {
    background-color: rgba(88, 101, 242, 1);
}

.discord-link .fab {
    font-size: 1.2rem;
}

.nav-center-title {
    text-align: center;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.header h1 {
    font-size: clamp(1.5rem, 2.5vw, 2.2rem);
    margin-bottom: 0;
    color: #fff;
    position: relative;
    text-align: center;
}

.author-credit {
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    color: rgba(255, 255, 255, 0.9);
    font-weight: normal;
    display: block;
    text-align: center;
    margin: -2px auto 0;
    width: fit-content;
}

/* --- BURGER MENU & OVERLAY --- */
.burger-menu {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 2.2rem;
    height: 2.2rem;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 2010;
    position: relative;
}

.burger-menu span {
    width: 2.2rem;
    height: 0.25rem;
    background: #fff;
    border-radius: 10px;
    transition: all 0.3s linear;
    position: relative;
    transform-origin: 1px;
}

.burger-menu.active span:nth-child(1) {
    transform: rotate(45deg);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(20px);
}

.burger-menu.active span:nth-child(3) {
    transform: rotate(-45deg);
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease-in-out;
}

.menu-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.menu-overlay a {
    color: #fff;
    text-decoration: none;
    font-size: 2.5rem;
    margin: 15px 0;
    transition: color 0.3s ease, transform 0.3s ease;
}

.menu-overlay a:hover,
.menu-overlay a.active {
    color: #f1c40f;
    transform: scale(1.05);
}

.menu-close {
    position: absolute;
    top: 30px;
    right: 50px;
    font-size: 3rem;
    color: #fff;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.3s ease;
    z-index: 2010;
}

.menu-close:hover {
    color: #f1c40f;
    transform: scale(1.1);
}

/* --- LANGUAGE SELECTOR --- */
#languageSelector {
    cursor: pointer;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    transition: background-color 0.2s ease;
    color: #fff;
}

.language-option:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.lang-flag {
    width: 24px;
    height: auto;
    border-radius: 4px;
    vertical-align: middle;
}

#selectedLanguage {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

#languageDropdown {
    display: none;
    position: absolute;
    top: 110%;
    right: 0;
    background: #2c2c2c;
    border-radius: 10px;
    overflow: hidden;
    z-index: 1001;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

#languageSelector.open #languageDropdown {
    display: block;
}

/* --- SUBTITLE SECTION --- */
.subtitle-section {
    text-align: center;
    margin-bottom: 30px;
}

.subtitle-section h2 {
    font-size: clamp(1.3rem, 2vw, 1.8rem);
    color: #f1c40f;
    margin-bottom: 8px;
}

.subtitle-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: clamp(0.95rem, 1.3vw, 1.1rem);
}

/* --- CHAT LAYOUT --- */
.chat-layout {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    width: 100%;
}

/* --- CHAT CONTAINER --- */
.chat-container {
    background: var(--chat-bg);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    flex-direction: column;
    flex: 1;
    height: calc(100vh - 95px);
    min-height: unset;
    max-height: none;
    overflow: hidden;
}

/* --- CHAT MESSAGES --- */
.chat-messages {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.chat-messages::-webkit-scrollbar {
    width: 8px;
}

.chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* --- MESSAGE STYLES --- */
.message {
    display: flex;
    gap: 12px;
    max-width: 85%;
    animation: messageSlideIn 0.3s ease-out;
}

@keyframes messageSlideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message-user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message-ai {
    align-self: flex-start;
}

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
}

.message-user .message-avatar {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.message-ai .message-avatar {
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
}

.message-content {
    background: var(--ai-msg-bg);
    border-radius: 18px;
    padding: 12px 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.message-user .message-content {
    background: var(--user-msg-bg);
    border-color: rgba(52, 152, 219, 0.3);
}

.message-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.message-author {
    font-weight: bold;
    font-size: 0.9rem;
    color: #f1c40f;
}

.message-user .message-author {
    color: #3498db;
}

.message-time {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.message-text {
    line-height: 1.5;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.95);
}

.message-text ul {
    margin: 10px 0;
    padding-left: 20px;
}

.message-text li {
    margin: 5px 0;
}

/* --- CHAT INPUT --- */
.chat-input-container {
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.chat-input-wrapper {
    display: flex;
    gap: 10px;
    align-items: flex-end;
    background: var(--input-bg);
    border-radius: 25px;
    padding: 8px 8px 8px 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.chat-input-wrapper:focus-within {
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.chat-input {
    flex-grow: 1;
    background: transparent;
    border: none;
    color: #fff;
    font-family: 'Lilita One', cursive;
    font-size: 1rem;
    resize: none;
    max-height: 120px;
    min-height: 24px;
    line-height: 1.5;
    padding: 8px 0;
}

.chat-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.chat-input:focus {
    outline: none;
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.chat-send-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(155, 89, 182, 0.4);
}

.chat-send-btn:active {
    transform: scale(0.95);
}

.chat-send-btn:disabled {
    background: linear-gradient(135deg, #555, #333);
    cursor: not-allowed;
    opacity: 0.6;
}

.chat-disclaimer {
    text-align: center;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 8px;
}

/* --- TEMPLATE AUTOCOMPLETE --- */
.template-autocomplete {
    background: var(--input-bg);
    border: 1px solid rgba(241, 196, 15, 0.5);
    border-radius: 15px;
    margin-top: 10px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.template-input-row {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    gap: 5px;
}

.template-prefix,
.template-suffix {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    white-space: nowrap;
}

.template-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #f1c40f;
    font-family: 'Lilita One', cursive;
    font-size: 0.95rem;
    outline: none;
    padding: 0;
    min-width: 80px;
}

.template-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.template-options {
    max-height: 200px;
    overflow-y: auto;
    padding: 5px;
}

.template-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.template-option:hover,
.template-option.selected {
    background: rgba(241, 196, 15, 0.15);
}

.template-option img {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.template-option span {
    color: #fff;
    font-size: 0.9rem;
}

.template-no-results {
    padding: 12px;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

/* --- AUTO-SUGGEST DROPDOWN --- */
.autosuggest-dropdown {
    background: var(--input-bg);
    border: 1px solid rgba(241, 196, 15, 0.5);
    border-radius: 12px;
    margin-top: 8px;
    max-height: 250px;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    z-index: 100;
}

.autosuggest-list {
    padding: 5px;
}

.autosuggest-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.autosuggest-item:hover,
.autosuggest-item.selected {
    background: rgba(241, 196, 15, 0.2);
}

.autosuggest-item img {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

.autosuggest-item .item-type {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    padding: 2px 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin-left: auto;
}

.autosuggest-no-results {
    padding: 12px;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

/* --- TYPING INDICATOR --- */
.typing-indicator {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 12px 16px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.typing-indicator .dots {
    display: flex;
    gap: 3px;
}

.typing-indicator .dot {
    width: 6px;
    height: 6px;
    background: rgba(241, 196, 15, 0.7);
    border-radius: 50%;
    animation: typingBounce 1.4s infinite ease-in-out both;
}

.typing-indicator .dot:nth-child(1) {
    animation-delay: -0.32s;
}

.typing-indicator .dot:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes typingBounce {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.4;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* --- SUGGESTED QUESTIONS --- */
.suggested-questions {
    width: 260px;
    flex-shrink: 0;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 15px;
    height: calc(100vh - 95px);
    min-height: unset;
    max-height: none;
    overflow-y: auto;
}

.suggested-questions h3 {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 10px;
}

.suggestions-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@media (max-width: 900px) {
    .chat-layout {
        flex-direction: column;
    }
    
    .suggested-questions {
        width: 100%;
        height: auto;
        min-height: auto;
        max-height: none;
    }
    
    .suggestions-list {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .suggestion-chip {
        flex: 1;
        min-width: 200px;
    }
}

.suggestion-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 10px 16px;
    color: #fff;
    font-family: 'Lilita One', cursive;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

.suggestion-chip:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(241, 196, 15, 0.5);
    transform: translateY(-2px);
}

.suggestion-chip i {
    color: #f1c40f;
    font-size: 0.85rem;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

/* --- TYPING INDICATOR --- */
.typing-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
}

.typing-indicator .typing-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
}

.typing-indicator .typing-dot {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    display: inline-block;
    animation: typingBounce 1.4s infinite ease-in-out both;
    flex-shrink: 0;
}

.typing-indicator .typing-dot:nth-child(2) {
    animation-delay: -0.32s;
}

.typing-indicator .typing-dot:nth-child(3) {
    animation-delay: -0.16s;
}

.typing-indicator .typing-dot:nth-child(4) {
    animation-delay: 0s;
}

@keyframes typingBounce {
    0%, 80%, 100% {
        transform: translateY(0);
        opacity: 0.6;
    }
    40% {
        transform: translateY(-4px);
        opacity: 1;
    }
}

/* --- RESPONSE STYLES --- */
.response-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.response-header .map-thumb,
.response-header .brawler-thumb {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    object-fit: cover;
}

.response-header .gamemode img {
    width: 20px;
    height: 20px;
}

.response-header.gamemode .gamemode-icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    object-fit: contain;
}

.response-title h3 {
    font-size: 1.1rem;
    color: #fff;
    margin: 0;
}

.response-title .subtitle {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

.response-title .gamemode {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Tierlist Results */
.tierlist-results {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 12px 0;
}

.tierlist-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border-left: 3px solid transparent;
}

.tierlist-item.tier-Splus { border-left-color: #ff6b6b; }
.tierlist-item.tier-S { border-left-color: #feca57; }
.tierlist-item.tier-A { border-left-color: #48dbfb; }
.tierlist-item.tier-B { border-left-color: #1dd1a1; }
.tierlist-item.tier-C { border-left-color: #a29bfe; }

.tierlist-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 24px;
}

.tierlist-item .brawler-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.tierlist-item .brawler-name {
    flex: 1;
    font-weight: 500;
}

.tierlist-item .tier-badge {
    background: rgba(241, 196, 15, 0.2);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
}

.tierlist-item .stats {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
}

/* Counter List Items */
.counter-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

.counter-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.counter-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 24px;
}

.counter-item .brawler-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.counter-item .brawler-name {
    flex: 1;
    font-weight: 500;
}

.counter-item .matchup-delta {
    font-size: 0.8rem;
    color: #1dd1a1;
    font-weight: 500;
}

/* Synergy List Styles */
.synergy-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 15px 0;
}

.synergy-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.synergy-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 24px;
}

.synergy-item .brawler-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.synergy-item .brawler-name {
    flex: 1;
    font-weight: 500;
}

.synergy-item .advantage {
    font-size: 0.85rem;
    font-weight: 500;
}

.synergy-item .advantage.positive {
    color: #2ecc71;
}

.synergy-item .advantage.negative {
    color: #e74c3c;
}

.synergy-tips {
    margin: 15px 0;
    padding-left: 20px;
}

.synergy-tips li {
    margin-bottom: 10px;
    line-height: 1.5;
}

/* Response Footer Links */
.response-footer {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.deep-link {
    color: #f1c40f;
    text-decoration: none;
    font-weight: 500;
}

.deep-link:hover {
    text-decoration: underline;
}

/* Comparison Styles */
.comparison-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin: 16px 0;
    flex-wrap: wrap;
}

.brawler-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    min-width: 140px;
    border: 2px solid transparent;
}

.brawler-card.winner {
    border-color: #f1c40f;
    background: rgba(241, 196, 15, 0.1);
}

.brawler-card .brawler-image {
    width: 64px;
    height: 64px;
    border-radius: 8px;
    margin-bottom: 8px;
}

.brawler-card h4 {
    margin: 0 0 8px 0;
    font-size: 1rem;
}

.brawler-card .stat {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.85rem;
    margin: 4px 0;
}

.brawler-card .stat .label {
    color: rgba(255, 255, 255, 0.6);
}

.brawler-card .stat .value {
    color: #f1c40f;
    font-weight: bold;
}

.vs-badge {
    background: rgba(241, 196, 15, 0.3);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    color: #f1c40f;
}

.comparison-analysis {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px;
    border-radius: 8px;
    margin-top: 12px;
}

/* Maps Grid */
.maps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
    margin: 12px 0;
}

.map-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 12px;
    text-align: center;
}

.map-card .map-image {
    width: 100%;
    aspect-ratio: 9/16;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 8px;
}

.map-card .map-name {
    display: block;
    font-size: 0.85rem;
    margin-bottom: 8px;
}

.map-card .map-links {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.map-card .map-links a {
    font-size: 0.75rem;
    color: #f1c40f;
    text-decoration: none;
    padding: 2px 8px;
    background: rgba(241, 196, 15, 0.1);
    border-radius: 4px;
}

/* Help Section */
.help-section {
    margin: 12px 0;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.help-section h4 {
    margin: 0 0 8px 0;
    color: #f1c40f;
    font-size: 1rem;
}

.help-section ul {
    margin: 0;
    padding-left: 20px;
}

.help-section li {
    margin: 6px 0;
    font-size: 0.9rem;
}

.help-section code {
    background: rgba(241, 196, 15, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.85rem;
}

.tip {
    background: rgba(241, 196, 15, 0.1);
    border-left: 3px solid #f1c40f;
    padding: 12px;
    margin-top: 12px;
    border-radius: 0 8px 8px 0;
    font-size: 0.9rem;
}

/* Upgrade List Styles */
.upgrade-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 15px 0;
}

.upgrade-list h4 {
    margin: 0 0 10px 0;
    color: #f1c40f;
    font-size: 1rem;
}

.upgrade-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.upgrade-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 24px;
}

.upgrade-item .brawler-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.upgrade-item .brawler-name {
    flex: 1;
    font-weight: 500;
}

.upgrade-item .score {
    font-size: 0.85rem;
    color: #1dd1a1;
    font-weight: 500;
}

/* Top Picks & Recommendation Lists */
.top-picks,
.recommendation-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 12px 0;
}

.pick-item,
.recommendation-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.pick-item .rank,
.recommendation-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 20px;
}

.pick-item .brawler-icon,
.recommendation-item .brawler-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.pick-item .brawler-name,
.recommendation-item .brawler-name {
    flex: 1;
}

.pick-item .winrate,
.recommendation-item .winrate {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Best Maps List */
.best-maps {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 12px 0;
}

.map-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.map-item .rank {
    font-weight: bold;
    color: #f1c40f;
    min-width: 20px;
}

.map-item .map-icon {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    object-fit: cover;
}

.map-item .map-name {
    flex: 1;
}

.map-item .winrate {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

.map-item .map-link {
    font-size: 0.8rem;
    color: #f1c40f;
    text-decoration: none;
}

.map-item .tier-badge {
    font-size: 0.75rem;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(241, 196, 15, 0.2);
    color: #f1c40f;
    min-width: 24px;
    text-align: center;
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 20px;
    margin-top: 40px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer a {
    color: inherit;
}

footer a:hover {
    color: #f1c40f;
}

#footer-data-credit {
    opacity: 0.8;
    font-size: 0.9em;
}

#footer-data-credit:empty {
    display: none;
}

/* --- UTILITY CLASSES --- */
.hidden {
    display: none !important;
}

/* --- RESPONSIVE DESIGN --- */
@media (max-width: 850px) {
    .discord-link span {
        display: none;
    }

    .discord-link {
        padding: 8px 10px;
        margin-right: 10px;
    }
}

@media (max-width: 768px) {
    .top-nav-bar {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 15px;
        height: auto;
        padding: 15px;
    }

    .nav-center-title {
        flex-direction: column;
        gap: 10px;
    }

    .chat-container {
        height: calc(100vh - 180px);
        min-height: 300px;
    }

    .message {
        max-width: 95%;
    }

    .message-content {
        overflow-x: auto;
        max-width: 100%;
    }

    .suggestions-grid {
        gap: 8px;
    }

    .suggestion-chip {
        padding: 8px 12px;
        font-size: 0.85rem;
        width: 100%;
    }

    /* Maps Grid - 2 columns on tablet */
    .maps-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 8px;
    }

    .map-card {
        padding: 8px;
    }

    .map-card .map-name {
        font-size: 0.75rem;
    }

    .map-card .map-links {
        flex-direction: column;
        gap: 4px;
    }

    .map-card .map-links a {
        font-size: 0.7rem;
        padding: 3px 6px;
    }

    /* Counter/Synergy lists */
    .counter-list,
    .synergy-list {
        gap: 6px;
    }

    .counter-item,
    .synergy-item {
        padding: 8px 10px;
        gap: 8px;
    }

    .counter-item .brawler-icon,
    .synergy-item .brawler-icon {
        width: 24px;
        height: 24px;
    }

    /* Tier list table responsive */
    .tier-list {
        min-width: 100%;
    }

    .tier-item {
        padding: 6px 10px;
    }

    .tier-item .brawler-icon {
        width: 28px;
        height: 28px;
    }

    /* Map items in brawler info */
    .map-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
        padding: 10px;
    }

    .map-item .map-name {
        font-size: 0.9rem;
    }

    .map-item .winrate {
        font-size: 0.8rem;
    }

    .map-item .tier-badge {
        font-size: 0.75rem;
        padding: 2px 6px;
    }

    .map-item .map-link {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .nav-center-title h1 {
        font-size: 1.5rem;
    }

    .author-credit {
        font-size: 0.8rem;
    }

    .chat-container {
        border-radius: 15px;
    }

    .chat-messages {
        padding: 10px;
    }

    .message {
        max-width: 100%;
    }

    .message-avatar {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .chat-input-wrapper {
        padding: 6px 6px 6px 15px;
    }

    .chat-send-btn {
        width: 40px;
        height: 40px;
    }

    /* Maps Grid - smaller cards on mobile */
    .maps-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    .map-card {
        padding: 6px;
    }

    .map-card .map-name {
        font-size: 0.7rem;
        margin-bottom: 6px;
    }

    .map-card .map-links a {
        font-size: 0.65rem;
        padding: 2px 4px;
    }

    /* Counter/Synergy items smaller */
    .counter-item,
    .synergy-item {
        padding: 6px 8px;
    }

    .counter-item .brawler-name,
    .synergy-item .brawler-name {
        font-size: 0.85rem;
    }

    .counter-item .matchup-delta,
    .synergy-item .advantage {
        font-size: 0.75rem;
    }

    /* Tier list items */
    .tier-item {
        padding: 5px 8px;
    }

    .tier-item .brawler-name {
        font-size: 0.85rem;
    }

    .tier-item .winrate {
        font-size: 0.75rem;
    }

    .tier-badge {
        font-size: 0.7rem;
        padding: 2px 5px;
        min-width: 24px;
    }

    /* Response header smaller */
    .response-header {
        padding: 10px 12px;
    }

    .response-header h3 {
        font-size: 1rem;
    }

    .response-header .subtitle {
        font-size: 0.8rem;
    }

    /* Map items */
    .map-item {
        padding: 8px;
    }

    .map-item img {
        width: 40px;
        height: 40px;
    }
}

/* ============================================
   CLARIFICATION & SUGGESTION UI
   ============================================ */

/* Clarification buttons */
.clarification-options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.clarification-btn {
    background: rgba(241, 196, 15, 0.15);
    border: 1px solid rgba(241, 196, 15, 0.5);
    border-radius: 6px;
    color: #f1c40f;
    padding: 8px 14px;
    font-family: 'Lilita One', cursive;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.clarification-btn:hover {
    background: rgba(241, 196, 15, 0.3);
    border-color: #f1c40f;
    transform: translateY(-1px);
}

/* Small suggestion chips */
.suggestion-chip-small {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(52, 152, 219, 0.2);
    border: 1px solid rgba(52, 152, 219, 0.4);
    border-radius: 15px;
    color: #3498db;
    padding: 6px 12px;
    font-family: 'Lilita One', cursive;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    margin: 4px;
}

.suggestion-chip-small:hover {
    background: rgba(52, 152, 219, 0.35);
    border-color: #3498db;
    transform: translateY(-1px);
}

/* Suggestion chips container */
.suggestion-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* Fuzzy match indicator */
.fuzzy-match-note {
    opacity: 0.6;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 8px;
    font-style: italic;
}
