:root {
    --font-main: 'Plus Jakarta Sans', sans-serif;
    --font-code: 'JetBrains Mono', monospace;
}

body {
    font-family: var(--font-main);
    background-color: #07080d;
    background-image:
        radial-gradient(ellipse 80% 50% at 15% 0%, rgba(190, 18, 60, 0.07) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 85% 100%, rgba(109, 40, 217, 0.05) 0%, transparent 55%),
        radial-gradient(ellipse 50% 60% at 50% 50%, rgba(15, 15, 30, 0.8) 0%, transparent 100%);
    color: #e2e8f0;
    overflow: hidden;
    touch-action: manipulation;
}

::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #232434;
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3a3b52;
}

.tr-flag-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(227, 10, 23, 0.12), rgba(227, 10, 23, 0.04));
    border: 1px solid rgba(227, 10, 23, 0.35);
    color: #fecdd3;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.02em;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 0 20px rgba(227, 10, 23, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* Floating pill glassmorphism — top-right-bar */
#top-right-bar {
    background: transparent;
}

#top-right-bar>* {
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

/* Sidebar Glassmorphism & High-Performance Hardware-Accelerated Animation */
#sidebar {
    background: #090a10 !important;
    border-right: 1px solid rgba(255, 255, 255, 0.07) !important;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Mobile Sidebar: Pure Transform (60fps/120fps GPU accelerated, no reflow) */
@media (max-width: 767px) {
    #sidebar {
        will-change: transform;
        transition: transform 0.24s cubic-bezier(0.16, 1, 0.3, 1) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }

    #sidebar.-translate-x-full {
        transform: translate3d(-100%, 0, 0) !important;
    }

    #sidebar:not(.-translate-x-full) {
        transform: translate3d(0, 0, 0) !important;
    }
}

/* Desktop Sidebar: Smooth Width (Isolated without backdrop re-raster thrash) */
@media (min-width: 768px) {
    #sidebar {
        transform: none !important;
        will-change: width;
        transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1) !important;
        background: rgba(8, 9, 14, 0.88) !important;
        backdrop-filter: blur(12px) !important;
        -webkit-backdrop-filter: blur(12px) !important;
        contain: paint;
    }
}

.sidebar-text {
    transition: opacity 0.15s ease;
    white-space: nowrap;
    overflow: hidden;
}

.sidebar-is-collapsed .sidebar-text {
    opacity: 0 !important;
    display: none !important;
}

#sidebar-more-menu {
    z-index: 99999 !important;
    pointer-events: auto !important;
}

/* ==========================================
   CHAT INPUT ALANI - AVANT-GARDE & PREMIUM GLOW
   ========================================== */
#chat-input-container {
    background: rgba(12, 13, 22, 0.94) !important;
    border: 1px solid rgba(255, 255, 255, 0.09) !important;
    border-radius: 1.25rem !important;
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
    transition: border-color 0.24s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.24s cubic-bezier(0.16, 1, 0.3, 1), background 0.24s ease !important;
}

#chat-input-container:hover {
    border-color: rgba(255, 255, 255, 0.18) !important;
    box-shadow: 0 12px 35px -5px rgba(0, 0, 0, 0.7), 0 0 25px rgba(225, 29, 72, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}

#chat-input-container:focus-within {
    border-color: rgba(225, 29, 72, 0.65) !important;
    box-shadow: 0 0 0 1px rgba(225, 29, 72, 0.4), 0 14px 45px -5px rgba(225, 29, 72, 0.18), 0 0 30px rgba(225, 29, 72, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    background: rgba(14, 15, 25, 0.98) !important;
}

#user-input {
    caret-color: #f43f5e !important;
    color: #f4f4f5 !important;
    font-size: 0.875rem !important;
    line-height: 1.5 !important;
}

#user-input::placeholder {
    color: #71717a !important;
    transition: color 0.2s ease !important;
}

#chat-input-container:focus-within #user-input::placeholder {
    color: #52525b !important;
}

/* ==========================================
           HESAP PROFİLİ & DENEYİM MODAL DÜZENİ
           ========================================== */
.profile-modal-container {
    display: flex;
    flex-direction: row;
    gap: 1.25rem;
    flex: 1 1 0%;
    min-height: 400px;
    max-height: 68vh;
    overflow: hidden;
}

.profile-modal-nav {
    flex-shrink: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.4rem !important;
    padding-right: 0.85rem !important;
    border-right: 1px solid rgba(255, 255, 255, 0.08) !important;
    overflow-y: auto !important;
}

.profile-tab-btn {
    width: 100% !important;
    text-align: left !important;
    padding: 0.65rem 0.85rem !important;
    border-radius: 0.85rem !important;
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.6rem !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
    border: 1px solid transparent !important;
    color: #a1a1aa !important;
    background: transparent !important;
    flex-shrink: 0 !important;
    height: 40px !important;
    max-height: 40px !important;
    box-sizing: border-box !important;
}

.profile-tab-btn:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

.profile-tab-btn.active {
    color: #fda4af !important;
    background: rgba(225, 29, 72, 0.12) !important;
    border-color: rgba(225, 29, 72, 0.35) !important;
    font-weight: 600 !important;
    box-shadow: 0 2px 10px rgba(225, 29, 72, 0.15) !important;
}

.profile-modal-content-area {
    flex: 1 1 0% !important;
    min-width: 0 !important;
    overflow-y: auto !important;
    padding-right: 0.5rem !important;
}

@media (max-width: 640px) {
    .profile-modal-container {
        flex-direction: column !important;
        min-height: auto !important;
        max-height: 72vh !important;
        gap: 0.75rem !important;
    }

    .profile-modal-nav {
        width: 100% !important;
        flex-direction: row !important;
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
        padding-right: 0 !important;
        padding-bottom: 0.5rem !important;
        overflow-x: auto !important;
        overflow-y: visible !important;
    }

    .profile-tab-btn {
        width: auto !important;
        flex: 1 1 auto !important;
        justify-content: center !important;
        padding: 0.45rem 0.65rem !important;
        font-size: 0.7rem !important;
        white-space: nowrap !important;
        height: 36px !important;
        max-height: 36px !important;
    }
}

.beta-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(225, 29, 72, 0.15);
    border: 1px solid rgba(225, 29, 72, 0.35);
    color: #fda4af;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Pürüzsüz Modal Animasyonları */
.modal-backdrop {
    position: fixed !important;
    inset: 0 !important;
    z-index: 100 !important;
    display: flex !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s ease;
}

.modal-backdrop.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.modal-content-box {
    transform: scale(0.94) translateY(10px);
    opacity: 0;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.22s ease;
}

.modal-backdrop.open .modal-content-box {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Markdown Zengin Metin Stilleri & Taşma Önleme */
.user-msg-bubble {
    word-break: break-word;
    overflow-wrap: anywhere;
    word-wrap: break-word;
    hyphens: auto;
}

.prose-chat {
    line-height: 1.7;
    font-size: 0.84rem;
    color: #e2e8f0;
    word-break: break-word;
    overflow-wrap: anywhere;
    word-wrap: break-word;
}

.prose-chat strong,
.prose-chat b {
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 0 1px rgba(255, 255, 255, 0.4);
}

.prose-chat p {
    margin-bottom: 0.65rem;
}

.prose-chat p:last-child {
    margin-bottom: 0;
}

.prose-chat h1 {
    font-size: 1.45rem;
    line-height: 1.3;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.025em;
    margin-top: 1.25rem;
    margin-bottom: 0.6rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 0.35rem;
}

.prose-chat h2 {
    font-size: 1.25rem;
    line-height: 1.35;
    font-weight: 700;
    color: #fb7185;
    letter-spacing: -0.015em;
    margin-top: 1.1rem;
    margin-bottom: 0.5rem;
}

.prose-chat h3 {
    font-size: 1.08rem;
    line-height: 1.4;
    font-weight: 700;
    color: #f1f5f9;
    margin-top: 0.95rem;
    margin-bottom: 0.4rem;
}

.prose-chat h4 {
    font-size: 0.95rem;
    line-height: 1.4;
    font-weight: 600;
    color: #cbd5e1;
    margin-top: 0.8rem;
    margin-bottom: 0.35rem;
}

.prose-chat h5,
.prose-chat h6 {
    font-size: 0.82rem;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.65rem;
    margin-bottom: 0.3rem;
}

.prose-chat ul,
.prose-chat ol {
    padding-left: 1.25rem;
    margin-bottom: 0.65rem;
}

.prose-chat ul {
    list-style-type: disc;
}

.prose-chat ol {
    list-style-type: decimal;
}

.prose-chat li {
    margin-bottom: 0.25rem;
}

.prose-chat code:not(pre code) {
    font-family: var(--font-code);
    background: rgba(244, 63, 94, 0.12);
    color: #fda4af;
    border: 1px solid rgba(244, 63, 94, 0.25);
    padding: 0.15rem 0.35rem;
    border-radius: 0.375rem;
    font-size: 0.8em;
}

.prose-chat pre {
    background: #090a0f !important;
    border: 1px solid #272738;
    padding: 0.85rem;
    overflow-x: auto;
    font-family: var(--font-code);
    font-size: 0.8em;
    color: #f1f5f9;
}

/* Minimalist & Responsive Markdown Tablo Stilleri (ChatGPT Standardı) */
.prose-chat .table-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(18, 19, 26, 0.7);
    box-shadow: 0 4px 16px -2px rgba(0, 0, 0, 0.35);
}

.prose-chat table {
    width: 100%;
    min-width: 480px;
    /* sıkışmayı önle */
    border-collapse: collapse;
    text-align: left;
    font-size: 0.8rem;
    color: #d4d4d8;
}

.prose-chat thead th {
    background: rgba(26, 27, 36, 0.95);
    color: #f4f4f5;
    font-weight: 600;
    padding: 0.65rem 0.9rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.78rem;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.prose-chat tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.15s ease;
}

.prose-chat tbody tr:last-child {
    border-bottom: none;
}

.prose-chat tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.015);
}

.prose-chat tbody tr:hover {
    background: rgba(255, 255, 255, 0.04);
}

.prose-chat tbody td {
    padding: 0.6rem 0.85rem;
    color: #d4d4d8;
    vertical-align: top;
    line-height: 1.5;
    white-space: normal;
    word-break: break-word;
    min-width: 80px;
}

.prose-chat tbody tr:last-child td {
    border-bottom: none;
}

@media (max-width: 640px) {
    .prose-chat .table-wrapper {
        border-radius: 0.6rem;
        margin: 0.6rem -0.25rem;
        width: calc(100% + 0.5rem);
    }

    .prose-chat table {
        font-size: 0.72rem;
    }

    .prose-chat thead th,
    .prose-chat tbody td {
        padding: 0.5rem 0.6rem;
    }
}

.artifact-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.85rem;
    padding: 0.75rem 1rem;
    background: rgba(18, 19, 28, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    margin-top: 0.6rem;
    margin-bottom: 0.6rem;
    transition: all 0.2s ease;
    backdrop-filter: blur(8px);
}

.artifact-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(24, 25, 36, 0.9);
    transform: translateY(-1px);
}

.prose-chat tbody tr:last-child td {
    border-bottom: none;
}

.ambient-flag-layer {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.ambient-flag-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.045;
    filter: contrast(140%) grayscale(20%);
    mix-blend-mode: screen;
}

.ambient-glow {
    background: radial-gradient(circle at 50% 20%, rgba(227, 10, 23, 0.08), transparent 70%),
        radial-gradient(circle at 90% 80%, rgba(227, 10, 23, 0.05), transparent 60%);
}

.custom-tooltip {
    position: fixed;
    background: #141521;
    color: #f1f5f9;
    border: 1px solid #2a2b3d;
    padding: 5px 11px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 500;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.7);
    pointer-events: none !important;
    z-index: 999999 !important;
    opacity: 0;
    transform: scale(0.96);
    transition: opacity 0.15s ease, transform 0.15s ease;
    white-space: nowrap;
}

.custom-tooltip.show {
    opacity: 1;
    transform: scale(1);
}

@media (max-width: 768px),
(pointer: coarse) {

    .custom-tooltip,
    #app-tooltip {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

html.has-cached-auth #auth-unauthenticated {
    display: none !important;
}

html.has-cached-auth #auth-authenticated {
    display: block !important;
}

#voice-modal {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 99999 !important;
    background: rgba(6, 7, 13, 0.98) !important;
}

#voice-modal:not(.open) {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden !important;
}

#voice-modal.open {
    display: flex !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    visibility: visible !important;
}

.select-text,
.select-text * {
    user-select: text !important;
    -webkit-user-select: text !important;
}

.cursor-text,
.cursor-text * {
    cursor: text !important;
}

body.modal-open #top-right-bar,
body.modal-open #mobile-menu-btn {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.2s ease;
}

.toast-popup {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(18, 19, 30, 0.95);
    border: 1px solid rgba(225, 29, 72, 0.4);
    color: #fda4af;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(12px);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.toast-popup.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Canlı AI Sesli İletişim / Orb Animasyonları */
.voice-orb-wrapper {
    position: relative;
    width: 170px;
    height: 170px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.voice-orb-glow {
    position: absolute;
    inset: -25px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(225, 29, 72, 0.45) 0%, rgba(244, 63, 94, 0.15) 50%, transparent 70%);
    filter: blur(25px);
    animation: orbPulse 3s ease-in-out infinite alternate;
}

.voice-orb-ring {
    position: absolute;
    border-radius: 50%;
    border: 1.5px solid rgba(244, 63, 94, 0.4);
    animation: ringExpand 2.8s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.voice-orb-ring:nth-child(2) {
    animation-delay: 0.9s;
    border-color: rgba(251, 113, 133, 0.3);
}

.voice-orb-ring:nth-child(3) {
    animation-delay: 1.8s;
    border-color: rgba(225, 29, 72, 0.2);
}

.voice-orb-core {
    position: relative;
    width: 95px;
    height: 95px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #f43f5e, #be123c 60%, #4c0519 100%);
    box-shadow: 0 0 40px rgba(225, 29, 72, 0.65), inset 0 0 15px rgba(255, 255, 255, 0.4);
    transition: transform 0.12s ease, filter 0.2s ease;
}

.voice-visualizer-bar {
    width: 3.5px;
    border-radius: 999px;
    background: linear-gradient(to top, #be123c, #fda4af);
    transition: height 0.08s ease;
}

@keyframes orbPulse {
    0% {
        transform: scale(0.92);
        opacity: 0.6;
    }

    100% {
        transform: scale(1.15);
        opacity: 0.95;
    }
}

@keyframes ringExpand {
    0% {
        width: 95px;
        height: 95px;
        opacity: 0.85;
        transform: scale(0.9);
    }

    100% {
        width: 220px;
        height: 220px;
        opacity: 0;
        transform: scale(1.3);
    }
}

/* WebGL Sanatsal Görsel Kartları & Ambient Efektler */
#image-prompts-tray {
    background-size: 200% 200%;
    animation: gradientFlow 12s ease infinite;
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

#image-prompts-tray button {
    position: relative;
    backdrop-filter: blur(12px);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

#image-prompts-tray button:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px -4px rgba(6, 182, 212, 0.25);
}

/* Mobil Menü Butonu ve Sağ Üst Bar Tanıtım Sayfasında Gizleme */
html.route-landing #mobile-menu-btn,
.route-landing #mobile-menu-btn,
html.route-landing #top-right-bar,
.route-landing #top-right-bar {
    display: none !important;
}

/* Mobil Kenar Çubuğu (Sidebar) Açıkken Hamburger Menü Butonunu Kesin Olarak Gizle */
html.mobile-sidebar-open #mobile-menu-btn,
body.mobile-sidebar-open #mobile-menu-btn,
html.mobile-sidebar-open #top-right-bar,
body.mobile-sidebar-open #top-right-bar {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden !important;
}

/* Sağ Üst Bar & Bildirimlerin Daima Önde ve Tıklanabilir Kalması (sadece desktop) */
#top-right-bar {
    pointer-events: auto !important;
}

@media (min-width: 768px) {
    #top-right-bar {
        z-index: 70 !important;
    }
}

/* Bağlam Penceresi (Context Window) Popover */
.context-window-popover {
    animation: contextPopIn 0.22s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transform-origin: bottom left;
}

@keyframes contextPopIn {
    0% {
        opacity: 0;
        transform: translateY(8px) scale(0.95);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.animate-spin-slow {
    animation: spinSlow 4s linear infinite;
}

@keyframes spinSlow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* KaTeX Matematiksel Formül Stilleri */
.katex-display {
    margin: 0.85rem 0 !important;
    padding: 0.85rem 1.15rem !important;
    background: rgba(10, 11, 20, 0.9) !important;
    border: 1px solid rgba(63, 63, 70, 0.5) !important;
    border-radius: 1rem !important;
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.6) !important;
    overflow-x: auto !important;
    text-align: center !important;
}

.katex {
    font-size: 1.08em !important;
    text-rendering: auto !important;
}


/* ── Kod Bloğu İyileştirmeleri ───────────────────────────── */
.code-block-wrapper {
    box-shadow: 0 4px 32px -4px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.code-block-wrapper pre code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace !important;
    font-variant-ligatures: common-ligatures;
}

/* ── Chat mesaj alanı hafif derinlik ───────────────────────── */
#messages-container {
    background: transparent;
}

/* ── Input alanı glassmorphism ─────────────────────────────── */
#input-area-wrapper,
.input-card,
[id*="input-wrapper"]>div:first-child {
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

/* ── Kullanıcı mesaj balonu glow ───────────────────────────── */
.user-msg-bubble {
    box-shadow: 0 2px 20px -4px rgba(225, 29, 72, 0.15);
}

/* ── Model, Araçlar ve Ekler Açılır Menüleri (Tam Opak & Tutarlı Tasarım) ── */
#model-dropdown-menu,
#tools-dropdown-menu,
#attachment-dropdown-menu {
    background: #10111a !important;
    border: 1px solid #27283c !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.95) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    opacity: 1 !important;
}

/* ── Floating pill buton hover glow ──────────────────────── */
#bell-btn:hover {
    box-shadow: 0 0 16px rgba(255, 255, 255, 0.06);
}

/* ── Arka plan ambient derinlik katmanı ──────────────────── */
#chat-app-view::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(ellipse 70% 40% at 10% 5%, rgba(190, 18, 60, 0.055) 0%, transparent 55%),
        radial-gradient(ellipse 50% 50% at 90% 95%, rgba(109, 40, 217, 0.04) 0%, transparent 50%);
    z-index: 0;
}

/* ── Announcements tray glassmorphism ────────────────────── */
#announcements-tray {
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    background: rgba(10, 11, 22, 0.92) !important;
    box-shadow: 0 16px 48px -8px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.07) !important;
    z-index: 75 !important;
}

/* ── F12 / Desktop Responsive Güvenlik Kuralı: Mobil Karartma Asla Açık Kalamaz ── */
@media (min-width: 768px) {
    #mobile-backdrop {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* ── Hesap Profili & Deneyim Modalı (Masaüstü Sol Menü, Sağ İçerik) ────── */
.profile-modal-container {
    display: flex !important;
    flex-direction: row !important;
    gap: 1.5rem !important;
    min-height: 400px !important;
    max-height: calc(85vh - 120px) !important;
    width: 100% !important;
}

.profile-modal-nav {
    flex-shrink: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.5rem !important;
    padding-right: 1rem !important;
    border-right: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.profile-tab-btn {
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
    width: 100% !important;
    padding: 0.75rem 1rem !important;
    border-radius: 0.875rem !important;
    font-size: 0.8125rem !important;
    font-weight: 600 !important;
    color: #94a3b8 !important;
    background: transparent !important;
    border: 1px solid transparent !important;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
    text-align: left !important;
    cursor: pointer !important;
}

.profile-tab-btn:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.04) !important;
}

.profile-tab-btn.active {
    color: #ffffff !important;
    background: rgba(244, 63, 94, 0.12) !important;
    border-color: rgba(244, 63, 94, 0.3) !important;
    box-shadow: 0 4px 16px -4px rgba(225, 29, 72, 0.25) !important;
}

.profile-modal-content-area {
    flex: 1 1 0% !important;
    min-width: 0 !important;
    overflow-y: auto !important;
    padding-right: 0.5rem !important;
}

@media (max-width: 768px) {
    .profile-modal-container {
        flex-direction: column !important;
        gap: 1rem !important;
        min-height: auto !important;
        max-height: none !important;
    }

    .profile-modal-nav {
        width: 100% !important;
        flex-direction: row !important;
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
        padding-right: 0 !important;
        padding-bottom: 0.75rem !important;
        overflow-x: auto !important;
        white-space: nowrap !important;
    }

    .profile-tab-btn {
        width: auto !important;
        flex-shrink: 0 !important;
        padding: 0.6rem 0.875rem !important;
    }
}

/* ===================================================
   İŞ BİRLİKLERİ & ALTYAPI ORTAKLARI (FULL-WIDTH INFINITE LOGO MARQUEE)
   =================================================== */
#landing-partners-strip {
    width: 100vw !important;
    position: relative !important;
    left: 50% !important;
    right: 50% !important;
    margin-left: -50vw !important;
    margin-right: -50vw !important;
    overflow: hidden !important;
}

.partners-marquee-container {
    position: relative !important;
    width: 100% !important;
    overflow: hidden !important;
    padding: 1.25rem 0 !important;
    mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%) !important;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%) !important;
}

.partners-marquee-track {
    display: flex !important;
    align-items: center !important;
    gap: 4.5rem !important;
    width: max-content !important;
    animation: partners-marquee-spin 28s linear infinite !important;
    will-change: transform !important;
}

.partners-marquee-track:hover {
    animation-play-state: paused !important;
}

@keyframes partners-marquee-spin {
    0% {
        transform: translate3d(0, 0, 0);
    }

    100% {
        transform: translate3d(-33.333333%, 0, 0);
    }
}

.partner-logo-item {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0.75rem 1rem !important;
    flex-shrink: 0 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.partner-logo-img {
    height: 38px !important;
    max-height: 42px !important;
    max-width: 150px !important;
    width: auto !important;
    object-fit: contain !important;
    filter: grayscale(100%) opacity(0.35) !important;
    -webkit-filter: grayscale(100%) opacity(0.35) !important;
    transition: filter 0.35s ease, -webkit-filter 0.35s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.partner-logo-item:hover {
    transform: translateY(-2px) !important;
}

.partner-logo-item:hover .partner-logo-img {
    filter: grayscale(0%) opacity(1) drop-shadow(0 4px 16px rgba(255, 255, 255, 0.15)) !important;
    -webkit-filter: grayscale(0%) opacity(1) drop-shadow(0 4px 16px rgba(255, 255, 255, 0.15)) !important;
    transform: scale(1.15) !important;
}

@media (max-width: 640px) {
    .partners-marquee-track {
        gap: 3rem !important;
        animation-duration: 20s !important;
    }

    .partner-logo-img {
        height: 30px !important;
        max-height: 34px !important;
        max-width: 120px !important;
    }
}

/* ===================================================
   DONMA VE KASMAYI ÖNLEYEN KUSURSUZ SIDEBAR MİMARİSİ
   =================================================== */
#sidebar {
    will-change: width, transform;
    transform: translateZ(0);
    transition: width 0.18s cubic-bezier(0.16, 1, 0.3, 1), transform 0.18s cubic-bezier(0.16, 1, 0.3, 1) !important;
    overflow-x: hidden !important;
    contain: layout paint;
}

@media (min-width: 768px) {
    #sidebar {
        width: 16rem !important;
    }

    html.sidebar-is-collapsed #sidebar {
        width: 4.5rem !important;
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }

    html.sidebar-is-collapsed #brand-container {
        display: none !important;
    }

    html.sidebar-is-collapsed #sidebar-header {
        justify-content: center !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    html.sidebar-is-collapsed .sidebar-text {
        display: none !important;
    }

    html.sidebar-is-collapsed #new-chat-btn,
    html.sidebar-is-collapsed #temp-chat-btn {
        width: 2.25rem !important;
        height: 2.25rem !important;
        min-width: 2.25rem !important;
        padding: 0 !important;
        justify-content: center !important;
        margin: 0 auto 0.5rem auto !important;
        border-radius: 0.75rem !important;
    }

    html.sidebar-is-collapsed #auth-unauthenticated button,
    html.sidebar-is-collapsed #auth-authenticated>div,
    html.sidebar-is-collapsed #btn-sidebar-more {
        width: 2.25rem !important;
        height: 2.25rem !important;
        min-width: 2.25rem !important;
        padding: 0 !important;
        justify-content: center !important;
        margin: 0 auto !important;
        border-radius: 0.75rem !important;
    }

    html.sidebar-is-collapsed #auth-authenticated>div>div {
        padding: 0 !important;
        justify-content: center !important;
    }

    html.sidebar-is-collapsed #session-list {
        display: none !important;
    }
}

/* ========================================================
   UMAY ÇEKİRDEĞİ BAŞLATMA EKRANI (SPLASH SCREEN)
   ======================================================== */
#umay-splash-screen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 2147483647 !important;
    background: #06070d !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    opacity: 1;
    pointer-events: auto !important;
    transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1), transform 0.65s cubic-bezier(0.16, 1, 0.3, 1) !important;
    transform: scale(1);
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}

#umay-splash-screen.splash-dismissed {
    opacity: 0 !important;
    transform: scale(1.08) !important;
    pointer-events: none !important;
}

/* ========================================================
   İNTERAKTİF REHBERLİK & ODAK TURU (ONBOARDING SPOTLIGHT)
   ======================================================== */
#umay-tour-backdrop {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 2000000000 !important;
    background: rgba(5, 6, 11, 0.78) !important;
    backdrop-filter: blur(5px) !important;
    -webkit-backdrop-filter: blur(5px) !important;
    transition: opacity 0.4s ease;
    pointer-events: auto;
}

#umay-tour-spotlight {
    position: fixed !important;
    z-index: 2000000001 !important;
    border-radius: 16px !important;
    box-shadow: 0 0 0 9999px rgba(5, 6, 11, 0.8),
        0 0 35px rgba(168, 85, 247, 0.5),
        inset 0 0 0 2px rgba(192, 132, 252, 0.8) !important;
    pointer-events: none !important;
    transition: all 0.38s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

#umay-tour-card {
    position: fixed !important;
    z-index: 2000000002 !important;
    width: 320px !important;
    max-width: calc(100vw - 32px) !important;
    background: #0f101d !important;
    border: 1px solid rgba(168, 85, 247, 0.35) !important;
    border-radius: 20px !important;
    padding: 18px !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7), 0 0 30px rgba(147, 51, 234, 0.2) !important;
    backdrop-filter: blur(20px) !important;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
    color: #e2e8f0;
}

/* ========================================================
   AI MESAJ KARTI CANLI YANIT DÖNEN KIRMIZI BORDER ANİMASYONU
   ======================================================== */
@property --ai-card-angle {
    syntax: '<angle>';
    inherits: false;
    initial-value: 0deg;
}

@keyframes aiBorderRotate {
    0% {
        --ai-card-angle: 0deg;
    }
    100% {
        --ai-card-angle: 360deg;
    }
}

/* Yanıt üretilirken kartın etrafında dönen canlı kırmızı neon border */
.ai-message-card.is-streaming-active {
    position: relative;
    border: 1.5px solid transparent !important;
    background: linear-gradient(180deg, #131524 0%, #0d0e19 100%) padding-box,
                conic-gradient(from var(--ai-card-angle, 0deg), transparent 0%, rgba(225, 29, 72, 0.15) 20%, #f43f5e 50%, rgba(225, 29, 72, 0.15) 80%, transparent 100%) border-box !important;
    animation: aiBorderRotate 2.2s linear infinite;
    box-shadow: 0 10px 32px -4px rgba(0, 0, 0, 0.7), 0 0 24px -2px rgba(244, 63, 94, 0.35) !important;
}

/* Yanıt tamamlandığında iki yandan birleşip sabit kırmızıya oturan border */
.ai-message-card {
    position: relative;
    border: 1.5px solid rgba(244, 63, 94, 0.65) !important;
    background: linear-gradient(180deg, #131524 0%, #0d0e19 100%) !important;
    box-shadow: 0 10px 32px -4px rgba(0, 0, 0, 0.65), 0 0 14px -3px rgba(244, 63, 94, 0.22) !important;
    border-radius: 1.25rem !important;
    transition: border-color 0.4s ease, box-shadow 0.4s ease;
}