/* Explain: Styles for the ST Destek digital assistant interface, including FAB positioning. */
/* --------------------------------------------------
   ST Destek dijital asistanı
-------------------------------------------------- */
.assistant-fab {
    position: absolute;
    inset-inline-end: 12px;
    bottom: 70px;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #ffffff;
    font-size: 1.05rem;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(234, 88, 12, 0.34);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.assistant-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 34px rgba(234, 88, 12, 0.44);
}
.assistant-fab:active {
    transform: scale(0.95);
}
.assistant-fab__smile,
.assistant-head__smile {
    position: absolute;
    inset-inline-end: -2px;
    bottom: -2px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    background: #1eb455;
    color: #ffffff;
    font-size: 0.68rem;
}
.assistant-head__smile {
    width: 18px;
    height: 18px;
    font-size: 0.56rem;
}

/* Panel */
.assistant-panel {
    position: absolute;
    inset: 0;
    z-index: 78;
    display: flex;
    align-items: flex-end;
}
.assistant-panel__scrim {
    position: absolute;
    inset: 0;
    background: rgba(20, 18, 14, 0.42);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.assistant-panel__sheet {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-top: 1px solid var(--border-color);
    border-radius: 20px 20px 0 0;
    background: var(--background-color);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    transform: translate3d(0, 102%, 0);
    transition: transform 0.34s cubic-bezier(0.22, 0.85, 0.3, 1);
}
.assistant-panel.is-open .assistant-panel__scrim {
    opacity: 1;
}
.assistant-panel.is-open .assistant-panel__sheet {
    transform: translate3d(0, 0, 0);
}

/* Başlık */
.assistant-head {
    display: flex;
    align-items: center;
    gap: 11px;
    flex-shrink: 0;
    padding: 14px 16px;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
}
.assistant-head__avatar {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    background: rgba(242, 106, 33, 0.12);
    color: var(--primary-color);
    font-size: 1.15rem;
}
.assistant-head__info {
    flex: 1;
    min-width: 0;
}
.assistant-head__title {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-color);
}
.assistant-head__status {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 1px;
    font-size: 0.72rem;
    color: var(--text-muted);
}
.assistant-head__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #1eb455;
    box-shadow: 0 0 0 3px rgba(30, 180, 85, 0.16);
}
.assistant-head__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    background: rgba(31, 36, 48, 0.04);
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.assistant-head__close:hover {
    background: rgba(31, 36, 48, 0.1);
    color: var(--text-color);
}

/* Sohbet */
.assistant-chat {
    display: flex;
    flex: 1;
    min-height: 0;
    flex-direction: column;
    gap: 10px;
    padding: 16px 16px 8px;
    overflow-y: auto;
    overscroll-behavior: contain;
}
.assistant-msg {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}
.assistant-msg--user {
    flex-direction: row-reverse;
}
.assistant-msg__avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 0.78rem;
}
.assistant-msg--bot .assistant-msg__avatar {
    background: rgba(242, 106, 33, 0.14);
    color: var(--primary-color);
}
.assistant-msg--user .assistant-msg__avatar {
    background: rgba(31, 36, 48, 0.08);
    color: var(--text-color);
}
.assistant-msg__bubble {
    max-width: 78%;
    padding: 11px 14px;
    border-radius: 16px;
    font-size: 0.88rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}
.assistant-msg--bot .assistant-msg__bubble {
    border: 1px solid var(--border-color);
    border-bottom-left-radius: 5px;
    background: #ffffff;
    color: var(--text-color);
    box-shadow: 0 1px 2px rgba(31, 36, 48, 0.06);
}
.assistant-msg--user .assistant-msg__bubble {
    border-bottom-right-radius: 5px;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #ffffff;
}
.assistant-msg--bot .assistant-msg__bubble--typing {
    font-style: italic;
    color: var(--text-muted);
}

/* Sorunumu Anla */
.assistant-understand {
    display: flex;
    justify-content: center;
    padding: 2px 0 4px;
}
.assistant-understand__btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 12px 18px;
    border: 1px solid rgba(242, 106, 33, 0.4);
    border-radius: 999px;
    background: rgba(242, 106, 33, 0.1);
    color: var(--primary-color);
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}
.assistant-understand__btn:hover {
    background: rgba(242, 106, 33, 0.18);
}
.assistant-understand__btn:active {
    transform: scale(0.97);
}

/* Kaydedilen talep + WhatsApp */
.assistant-ticket {
    display: grid;
    gap: 8px;
    padding: 14px;
    border: 1px solid rgba(30, 180, 85, 0.35);
    border-radius: 16px;
    background: rgba(30, 180, 85, 0.07);
}
.assistant-ticket__head {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.45;
    color: #1e9e4e;
}
.assistant-ticket__head i {
    margin-top: 2px;
    flex-shrink: 0;
}
.assistant-ticket__label {
    font-size: 0.74rem;
    font-weight: 600;
    color: var(--text-muted);
}
.assistant-ticket__text {
    width: 100%;
    min-height: 84px;
    padding: 11px 13px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #ffffff;
    color: var(--text-color);
    font-family: inherit;
    font-size: 0.86rem;
    line-height: 1.5;
    resize: vertical;
}
.assistant-ticket__text:focus {
    outline: none;
    border-color: rgba(30, 180, 85, 0.55);
    box-shadow: 0 0 0 3px rgba(30, 180, 85, 0.14);
}
.assistant-ticket__send {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 13px 18px;
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, #25d366, #1eb455);
    color: #ffffff;
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 12px 26px rgba(30, 180, 85, 0.28);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.assistant-ticket__send:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(30, 180, 85, 0.34);
}
.assistant-ticket__send:active {
    transform: scale(0.98);
}

/* Hızlı sorular */
.assistant-quick {
    display: flex;
    gap: 7px;
    flex-shrink: 0;
    padding: 8px 16px 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-top: 1px solid var(--border-color);
    background: #ffffff;
}
.assistant-chip {
    flex: 0 0 auto;
    padding: 8px 13px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #f8f6f1;
    color: var(--text-color);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.assistant-chip:hover {
    border-color: rgba(242, 106, 33, 0.4);
    background: rgba(242, 106, 33, 0.1);
    color: var(--primary-color);
}

/* Yazma alanı */
.assistant-form {
    display: flex;
    align-items: center;
    gap: 9px;
    flex-shrink: 0;
    padding: 10px 16px calc(14px + env(safe-area-inset-bottom, 0px));
    background: #ffffff;
    border-top: 1px solid var(--border-color);
}
.assistant-form input {
    flex: 1;
    min-width: 0;
    padding: 13px 15px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #f8f6f1;
    color: var(--text-color);
    font-family: inherit;
    font-size: 0.88rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.assistant-form input::placeholder {
    color: rgba(138, 133, 120, 0.8);
}
.assistant-form input:focus {
    outline: none;
    border-color: rgba(242, 106, 33, 0.55);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(242, 106, 33, 0.13);
}
.assistant-form__send {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #ffffff;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(234, 88, 12, 0.3);
    transition: transform 0.2s ease, opacity 0.2s ease;
}
.assistant-form__send:hover {
    transform: translateY(-1px);
}
.assistant-form__send:disabled {
    opacity: 0.6;
    cursor: progress;
    transform: none;
}