/* AI Támogatás oldal specifikus stílusok */

/* Splash Screen */
.splash-screen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--background-color);
    z-index: 9999;
    transition: opacity 0.8s ease-out, visibility 0.8s;
    opacity: 1;
    visibility: visible;
}

.splash-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.chat-header-title {
    display: flex;
    align-items: center;
    flex-direction: column; /* ÚJ: Elemek egymás alá rendezése */
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 900;
    text-align: center;
    gap: 4px;
    padding: 20px 0;
}

.animated-zoe-text {
    background: linear-gradient(90deg, #FF00FF, var(--primary-color), #FF00FF);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: logo-color-scroll 4s linear infinite;
    line-height: 1.1; /* Kisebb sormagasság */
    font-size: 2.5rem;
}

.greeting-text {
    font-size: 1rem; /* Kisebb betűméret az üdvözlésnek */
    font-weight: 500;
    color: var(--text-secondary);
    margin-top: -8px; /* Finomhangolás a jobb vizuális igazításért */
}

/* ÚJ: ZOÉ logó stílusa */
.chat-zoe-logo {
    height: 1.5em; /* Nagyobb logó a chat felületen */
    width: auto;
    vertical-align: middle;
    filter: drop-shadow(0 0 8px var(--glow-color));
}

.zoe-logo {
    height: 10em; /* Nagyobb logó a chat felületen */
    width: auto;
    vertical-align: middle;
    filter: drop-shadow(0 0 8px var(--glow-color));
}

.splash-zoe-text {
    font-size: 12rem;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(90deg, #FF00FF, var(--primary-color), #FF00FF);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: logo-color-scroll 4s linear infinite;
    text-shadow: 0 0 15px rgba(255, 0, 255, 0.5), 0 0 25px rgba(0, 170, 255, 0.5);
}

/* ÚJ: SVG animáció */
@keyframes svg-color-cycle {
    0% { filter: hue-rotate(-30deg) drop-shadow(0 0 8px var(--glow-color)); }
    50% { filter: hue-rotate(30deg) drop-shadow(0 0 12px var(--primary-hover)); }
    100% { filter: hue-rotate(-30deg) drop-shadow(0 0 8px var(--glow-color)); }
}

.zoe-logo, .chat-zoe-logo {
    animation: svg-color-cycle 10s linear infinite;
}


/* Fő tartalom */
.ai-main-view {
    padding: 40px 0;
    opacity: 1;
    transition: opacity 0.8s ease-in;
}

.main-content.hidden {
    opacity: 0;
    display: none;
}

.support-options-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.support-option-card {
    text-align: center;
    padding: 30px;
}

.support-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.support-option-card h3 {
    font-size: 1.6rem;
    margin-bottom: 15px;
}

.support-option-card p {
    margin-bottom: 25px;
    min-height: 80px; /* Segít azonos magasságban tartani a kártyákat */
}

@media (max-width: 768px) {
    .support-options-container {
        grid-template-columns: 1fr;
    }
}

/* --- ÚJ: AI Chat Felület Stílusok --- */
.ai-chat-container {
    position: fixed;
    inset: 0;
    background-color: var(--background-color);
    z-index: 100;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}

.ai-chat-container.hidden {
    opacity: 0;
    pointer-events: none;
}

.chat-back-button {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 10; /* A többi elem felett legyen */
}

.chat-layout-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
    max-width: 800px; /* Megakadályozza, hogy túl széles legyen */
    margin: 0 auto;
    position: relative;
}

.chat-layout-wrapper .animated-logo-text {
    font-size: 2.5rem; /* Kisebb méret, hogy jobban elférjen */
    text-align: center;
    flex-shrink: 0;
    padding: 20px 0;
}

.chat-messages {
    flex-grow: 1;
    overflow-y: auto;
    padding: 0 10px 20px 10px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    /* Finom átmenet a görgetősávnak */
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) transparent;
}

.message-bubble {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 15px;
    animation: message-fade-in 0.4s ease-out;
}

.message-bubble p {
    margin: 0;
    line-height: 1.5;
}

.message-bubble a {
    color: var(--primary-color);
    font-weight: 600;
}
.message-bubble code {
    background: #111; padding: 2px 6px; border-radius: 4px; border: 1px solid var(--panel-border);
}

@keyframes message-fade-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.ai-bubble {
    background-color: var(--panel-bg);
    border: 1px solid var(--panel-border);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.user-bubble {
    background: linear-gradient(45deg, var(--primary-color), #0077b3);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.message-bubble.embed-bubble {
    background: transparent;
    border: none;
    padding: 0;
    max-width: 520px;
    width: 100%;
}

.ai-embed {
    background: #1e1f22; /* Sötétebb, modernebb háttér */
    /* A régi border-left helyett egy animált pszeudo-elemet használunk */
    border-radius: 4px;
    padding: 12px 16px;
    display: flex;
    gap: 16px; /* Térköz a tartalom és a thumbnail között */
    position: relative; /* Szükséges a ::before pozicionálásához */
    overflow: hidden; /* Elrejti a túlnyúló gradienst */
    border: 1px solid rgba(233, 30, 99, 0.2); /* Finom keret az egész embednek */
    box-shadow: 0 0 15px rgba(233, 30, 99, 0.1);
}

.ai-embed::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px; /* A "keret" vastagsága */
    height: 100%;
    background: linear-gradient(180deg, #e91e63, #00aaff, #ff00ff, #00aaff, #e91e63);
    background-size: 100% 300%;
    animation: flow-glow 4s linear infinite;
    box-shadow: 0 0 8px #e91e63, 0 0 12px #e91e63;
}

@keyframes flow-glow {
    0% {
        background-position: 0% 0%;
    }
    100% {
        background-position: 0% 300%;
    }
}

.embed-main-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.embed-thumbnail img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.embed-author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--text-color);
}

.embed-author-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
}

.embed-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-color);
    margin-top: 4px;
}

.embed-description {
    color: var(--text-secondary);
    line-height: 1.6;
}

.embed-fields {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 8px;
}

.embed-field {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.embed-field.inline {
    /* A grid-template-columns a JS-ben lesz beállítva */
}

.embed-field-name {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 2px;
}

.embed-field-value {
    color: var(--text-secondary);
    line-height: 1.5;
}

.embed-footer {
    font-size: 0.8rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

/* ÚJ: Gombok az embeden belül */
.embed-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}
.chat-input-area-wrapper {
    flex-shrink: 0;
    padding: 40px 0 20px 0; /* 40px a középvonaltól lefelé */
}

.chat-input-area {
    display: flex;
    align-items: center;
    gap: 10px;
    /* grid-panel stílus */
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 0 20px var(--glow-color);
}

.chat-input-area textarea {
    flex-grow: 1;
    resize: none;
    max-height: 150px; /* Megakadályozza, hogy túl nagyra nőjön */
    background: transparent;
    border: none;
    color: var(--text-color);
    font-size: 1rem;
    padding: 10px;
}

.chat-input-area textarea:focus {
    outline: none;
}

.chat-input-area .button {
    flex-shrink: 0;
    border-radius: 10px;
    width: 44px;
    height: 44px;
    padding: 0;
    font-size: 1.2rem;
}

/* --- ÚJ: Parancs javaslatok stílusai --- */
.command-suggestions {
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    margin-bottom: 10px;
    max-height: 200px;
    overflow-y: auto;
    animation: fadeIn 0.2s ease-out;
}

.command-suggestions.hidden {
    display: none;
}

.suggestion-item {
    padding: 12px 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 15px;
    border-bottom: 1px solid var(--panel-border);
    transition: background-color 0.2s;
}

.suggestion-item:last-child,
.suggestion-item.selected {
    border-bottom: none;
}

.suggestion-item:hover {
    background-color: rgba(0, 170, 255, 0.1);
}

.suggestion-item.selected {
    background-color: rgba(0, 170, 255, 0.15);
}

.suggestion-command {
    font-weight: 600;
    color: var(--text-color);
}

.suggestion-description {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* --- ÚJ: Gépelési animáció --- */
.typing-indicator {
    padding: 15px;
}
.typing-indicator span {
    height: 8px;
    width: 8px;
    background-color: var(--text-secondary);
    border-radius: 50%;
    display: inline-block;
    animation: typing-bounce 1.4s infinite ease-in-out both;
}
.typing-indicator span:nth-of-type(1) {
    animation-delay: -0.32s;
}
.typing-indicator span:nth-of-type(2) {
    animation-delay: -0.16s;
}
@keyframes typing-bounce {
    0%, 80%, 100% {
        transform: scale(0);
    } 40% {
        transform: scale(1.0);
    }
}

/* --- ÚJ: Kezdő állapot és javasolt kérdések --- */
.chat-initial-state {
    padding: 0 10px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
}

.suggested-questions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-left: 10px;
}

.suggested-question-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
    color: var(--text-color);
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(5px);
}

.suggested-question-btn:hover {
    background: rgba(0, 170, 255, 0.15);
    border-color: var(--primary-color);
}

/* --- ÚJ: Oldalsó menü --- */
.chat-sidebar {
    position: fixed;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 101;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Tetejére és aljára rendezi a gombokat */
    height: calc(100% - 80px); /* Hogy ne érjen teljesen a széléig */
    max-height: 400px;
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    padding: 15px;
    border-radius: 12px;
}
.sidebar-top, .sidebar-bottom {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sidebar-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--panel-border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-btn:hover:not(:disabled) {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 0 10px var(--glow-color);
}

.sidebar-btn:disabled {
    color: #666;
    cursor: not-allowed;
    background: #222;
}

.profile-avatar-btn {
    padding: 0;
    overflow: hidden;
    border-color: var(--primary-color);
}

.profile-avatar-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.auth-container {
    position: relative;
}

.profile-dropdown-menu {
    position: absolute;
    bottom: 100%; /* A gomb fölött jelenik meg */
    left: 0;
    margin-bottom: 10px;
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    border-radius: 8px;
    padding: 5px;
    min-width: 180px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.profile-dropdown-menu.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 5px;
}

.dropdown-item:hover {
    background: rgba(0, 170, 255, 0.1);
    color: var(--text-color);
}

.sidebar-icon-img {
    width: 60%;
    height: 60%;
    object-fit: contain;
}

.profile-avatar-header {
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    box-shadow: 0 0 10px var(--glow-color);
}

.chat-layout-wrapper .animated-logo-text {
    display: flex;
    align-items: center;
}

/* --- ÚJ: Előzmények Modal stílusai --- */
.history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 10px; /* Hely a görgetősávnak */
}

.history-item {
    padding: 15px;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--panel-border);
    border-radius: 10px;
    cursor: pointer;
    transition: background .2s, border-color .2s;
}

.history-item:hover {
    background: rgba(0, 170, 255, 0.1);
    border-color: var(--primary-color);
}

.history-item__title {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
}

.history-item__snippet {
    font-size: 0.9rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.history-item__date {
    font-size: 0.8rem;
    color: var(--text-secondary);
    opacity: 0.7;
}

/* --- ÚJ: Beállítások Modal Fejléc --- */
.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--panel-border);
}

.version-tag {
    background: rgba(255, 255, 255, 0.1);
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    border: 1px solid var(--panel-border);
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.2);
}
