/* =========================================================
   MERAY UYDU SISTEMLERI - MASKOT WIDGET
   ========================================================= */

.meray-maskot {
    --maskot-blue: #0b5fad;
    --maskot-blue-dark: #084b89;
    --maskot-green: #25d366;
    --maskot-text: #183247;
    --maskot-muted: #607487;
    --maskot-border: #dce8f2;

    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 1450;

    display: flex;
    align-items: flex-end;
    gap: 10px;

    font-family: inherit;
    pointer-events: none;
}

.meray-maskot *,
.meray-maskot *::before,
.meray-maskot *::after {
    box-sizing: border-box;
}

/* ---------------------------------------------------------
   KONUŞMA BALONU
   --------------------------------------------------------- */

.meray-maskot__bubble {
    position: relative;

    width: min(252px, calc(100vw - 190px));
    min-height: 96px;

    padding: 12px 13px 11px;

    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--maskot-border);
    border-radius: 18px;

    box-shadow:
        0 12px 34px rgba(12, 48, 78, 0.18),
        0 3px 8px rgba(12, 48, 78, 0.08);

    pointer-events: auto;

    transform-origin: bottom right;
    animation: merayMaskotBubbleIn 0.42s ease both;
}

.meray-maskot__bubble::after {
    content: "";

    position: absolute;
    right: -9px;
    bottom: 34px;

    width: 18px;
    height: 18px;

    background: #ffffff;
    border-top: 1px solid var(--maskot-border);
    border-right: 1px solid var(--maskot-border);

    transform: rotate(45deg);
}

.meray-maskot__eyebrow {
    display: block;
    margin: 0 32px 5px 0;

    color: var(--maskot-blue);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.meray-maskot__title {
    margin: 0 30px 5px 0;

    color: var(--maskot-text);
    font-size: 15px;
    line-height: 1.25;
    font-weight: 800;
}

.meray-maskot__text {
    margin: 0;

    color: var(--maskot-muted);
    font-size: 12px;
    line-height: 1.38;
    font-weight: 500;
}

.meray-maskot__actions {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}

.meray-maskot__action {
    min-height: 36px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 7px 11px;

    border: 0;
    border-radius: 999px;

    font: inherit;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;

    text-decoration: none;
    cursor: pointer;

    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        background-color 0.18s ease;
}

.meray-maskot__action:hover {
    transform: translateY(-2px);
}

.meray-maskot__action--whatsapp {
    color: #ffffff;
    background: var(--maskot-green);
    box-shadow: 0 5px 14px rgba(37, 211, 102, 0.24);
}

.meray-maskot__action--call {
    color: #ffffff;
    background: var(--maskot-blue);
    box-shadow: 0 5px 14px rgba(11, 95, 173, 0.22);
}

.meray-maskot__close {
    position: absolute;
    top: 8px;
    right: 6px;

    width: 28px;
    height: 28px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    color: #718394;
    background: #f3f7fa;

    border: 0;
    border-radius: 50%;

    font-size: 20px;
    line-height: 1;

    cursor: pointer;

    transition:
        background-color 0.18s ease,
        color 0.18s ease,
        transform 0.18s ease;
}

.meray-maskot__close:hover {
    color: #263d50;
    background: #e7eff5;
    transform: rotate(5deg);
}

/* ---------------------------------------------------------
   KARAKTER
   --------------------------------------------------------- */

.meray-maskot__character {
    position: relative;

    width: 152px;
    min-width: 152px;

    display: flex;
    align-items: flex-end;
    justify-content: center;

    pointer-events: auto;
}

.meray-maskot__image-button {
    width: 100%;

    display: block;
    padding: 0;

    background: transparent;
    border: 0;

    cursor: pointer;
}

.meray-maskot__image {
    display: block;

    width: 100%;
    height: auto;
    max-height: 205px;

    object-fit: contain;
    object-position: bottom center;

    filter: drop-shadow(0 9px 10px rgba(23, 54, 77, 0.18));

    animation: merayMaskotFloat 3.4s ease-in-out infinite;
}

.meray-maskot__online {
    position: absolute;
    right: 4px;
    bottom: 7px;

    width: 15px;
    height: 15px;

    background: #25d366;

    border: 3px solid #ffffff;
    border-radius: 50%;

    box-shadow: 0 2px 7px rgba(0, 0, 0, 0.18);
}

/* ---------------------------------------------------------
   KÜÇÜLTÜLMÜŞ DURUM
   --------------------------------------------------------- */

.meray-maskot.is-minimized .meray-maskot__bubble {
    display: none;
}

.meray-maskot.is-minimized .meray-maskot__character {
    width: 82px;
    min-width: 82px;

    padding: 6px;

    background: rgba(255, 255, 255, 0.97);
    border: 1px solid var(--maskot-border);
    border-radius: 50%;

    box-shadow: 0 8px 24px rgba(12, 48, 78, 0.18);
}

.meray-maskot.is-minimized .meray-maskot__image {
    max-height: 74px;
}

/* ---------------------------------------------------------
   MESAJ DEĞİŞİMİ
   --------------------------------------------------------- */

.meray-maskot__content.is-changing {
    animation: merayMaskotMessage 0.34s ease both;
}

/* ---------------------------------------------------------
   ANİMASYONLAR
   --------------------------------------------------------- */

@keyframes merayMaskotBubbleIn {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.96);
    }

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

@keyframes merayMaskotFloat {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

@keyframes merayMaskotMessage {
    0% {
        opacity: 0.25;
        transform: translateY(4px);
    }

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

/* ---------------------------------------------------------
   TABLET / TELEFON
   --------------------------------------------------------- */

@media (max-width: 700px) {

    .meray-maskot {
        right: 10px;
        bottom: 10px;

        gap: 6px;
    }

    .meray-maskot__character {
        width: 96px;
        min-width: 96px;
    }

    .meray-maskot__image {
        max-height: 132px;
    }

    .meray-maskot__bubble {
        width: min(246px, calc(100vw - 125px));
        min-height: 0;

        padding: 14px 14px 13px;

        border-radius: 16px;
    }

    .meray-maskot__bubble::after {
        right: -7px;
        bottom: 28px;

        width: 14px;
        height: 14px;
    }

    .meray-maskot__eyebrow {
        margin-bottom: 4px;
        font-size: 9px;
    }

    .meray-maskot__title {
        margin-bottom: 4px;
        font-size: 15px;
    }

    .meray-maskot__text {
        font-size: 12px;
        line-height: 1.4;
    }

    .meray-maskot__actions {
        gap: 6px;
        margin-top: 9px;
    }

    .meray-maskot__action {
        min-height: 35px;
        padding: 7px 10px;
        font-size: 11px;
    }

    .meray-maskot__close {
        top: 6px;
        right: 6px;

        width: 27px;
        height: 27px;

        font-size: 18px;
    }

    .meray-maskot.is-minimized .meray-maskot__character {
        width: 65px;
        min-width: 65px;
    }

    .meray-maskot.is-minimized .meray-maskot__image {
        max-height: 57px;
    }
}

@media (max-width: 420px) {

    .meray-maskot__bubble {
        width: min(220px, calc(100vw - 112px));
    }

    .meray-maskot__character {
        width: 88px;
        min-width: 88px;
    }

    .meray-maskot__actions {
        flex-direction: column;
    }

    .meray-maskot__action {
        width: 100%;
    }
}

/* ---------------------------------------------------------
   ERİŞİLEBİLİRLİK
   --------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {

    .meray-maskot__image,
    .meray-maskot__bubble,
    .meray-maskot__content {
        animation: none !important;
        transition: none !important;
    }
}

/* MERAY MASKOT MASAUSTU DENGE AYARI START */
@media (min-width: 701px) {

    .meray-maskot {
        gap: 6px;
    }

    /* Konuşma balonu daha kompakt */
    .meray-maskot__bubble {
        width: 220px;
        min-height: 0;
        padding: 10px 11px 9px;
        border-radius: 15px;
    }

    .meray-maskot__eyebrow {
        margin-bottom: 3px;
        font-size: 9px;
    }

    .meray-maskot__title {
        margin-bottom: 3px;
        font-size: 14px;
        line-height: 1.18;
    }

    .meray-maskot__text {
        font-size: 12px;
        line-height: 1.32;
    }

    .meray-maskot__actions {
        gap: 5px;
        margin-top: 7px;
    }

    .meray-maskot__action {
        min-height: 32px;
        padding: 6px 9px;
        font-size: 11px;
    }

    .meray-maskot__close {
        top: 5px;
        right: 5px;
        width: 25px;
        height: 25px;
        font-size: 17px;
    }

    /* Maskot karakter daha büyük */
    .meray-maskot__character {
        width: 170px;
        min-width: 170px;
    }

    .meray-maskot__image {
        max-height: 225px;
    }
}
/* MERAY MASKOT MASAUSTU DENGE AYARI END */


/* MERAY MASKOT MOBIL DENGE AYARI START */
@media (max-width: 700px) {

    .meray-maskot {
        right: 6px;
        bottom: 6px;
        gap: 5px;
    }

    .meray-maskot__bubble {
        width: 190px;
        min-height: 0;
        padding: 9px 10px 8px;
        border-radius: 14px;
    }

    .meray-maskot__bubble::after {
        right: -6px;
        bottom: 24px;
        width: 12px;
        height: 12px;
    }

    .meray-maskot__eyebrow {
        margin: 0 24px 3px 0;
        font-size: 8px;
    }

    .meray-maskot__title {
        margin: 0 22px 3px 0;
        font-size: 13px;
        line-height: 1.16;
    }

    .meray-maskot__text {
        font-size: 10.5px;
        line-height: 1.3;
    }

    .meray-maskot__actions {
        flex-direction: row;
        gap: 4px;
        margin-top: 6px;
    }

    .meray-maskot__action {
        width: auto;
        flex: 1;
        min-height: 30px;
        padding: 5px 6px;
        font-size: 9px;
        white-space: nowrap;
    }

    .meray-maskot__character {
        width: 108px;
        min-width: 108px;
    }

    .meray-maskot__image {
        max-height: 150px;
    }

    .meray-maskot__close {
        top: 4px;
        right: 4px;
        width: 23px;
        height: 23px;
        font-size: 16px;
    }
}

/* 420px alti: butonlari yine yan yana tut */
@media (max-width: 420px) {

    .meray-maskot__bubble {
        width: 190px;
    }

    .meray-maskot__character {
        width: 104px;
        min-width: 104px;
    }

    .meray-maskot__actions {
        flex-direction: row;
    }

    .meray-maskot__action {
        width: auto;
    }
}
/* MERAY MASKOT MOBIL DENGE AYARI END */
