@property --yrl-border-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

@keyframes yrl-rotate-border-angle {
    to {
        --yrl-border-angle: 360deg;
    }
}

/* ===== Yolo AI Booking Agent - Dora — Widget Styles ===== */

:root {
    --yrl-teal: #2ec4b6;
    --yrl-teal-dark: #189c90;
    --yrl-black: #111111;
    --yrl-white: #ffffff;
}

* {
    box-sizing: border-box;
}

/* ---------- FLOATING BUBBLE (bottom-left) ---------- */
#yrl-bubble {
    position: fixed;
    bottom: 24px;
    left: 34px;
    transform: scale(1.2);
    height: 52px;
    padding: 0 20px 0 0;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 2px solid transparent;
    border-radius: 16px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
    z-index: 99999;
    overflow: visible;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    background:
        linear-gradient(90deg, var(--yrl-teal-dark), var(--yrl-teal)) padding-box,
        conic-gradient(from var(--yrl-border-angle), var(--yrl-black) 0deg, #0ABAB5 180deg, var(--yrl-black) 360deg) border-box;
    animation: yrl-rotate-border-angle 2.5s linear infinite;
}


@keyframes yrl-rotate-bubble-border {
    from {
        transform: rotate(0deg);
    }

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

#yrl-bubble:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.24);
}

#yrl-bubble:active {
    transform: translateY(0);
}

.yrl-bubble-logo {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-left: -8px;
    /* nudges it to overlap the pill's left edge */
    margin-right: 8px;
    box-sizing: border-box;
    border: 3px solid transparent;
    background:
        linear-gradient(var(--yrl-teal-dark), var(--yrl-teal-dark)) padding-box,
        conic-gradient(from var(--yrl-border-angle), var(--yrl-black) 0deg, #0ABAB5 180deg, var(--yrl-black) 360deg) border-box;
    animation: yrl-rotate-border-angle 2.5s linear infinite;
}

/* This inner ring is the ONLY thing that rotates */
.yrl-bubble-logo .yrl-glow-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    animation: yrl-rotate-logo 1.2s linear infinite;
    background-color: var(--yrl-teal-dark);
    background-image: linear-gradient(var(--yrl-teal-dark), var(--yrl-teal), #5eead4);
}

.yrl-bubble-logo .yrl-glow-ring span {
    position: absolute;
    border-radius: 50%;
    height: 100%;
    width: 100%;
    background-color: var(--yrl-teal-dark);
    background-image: linear-gradient(var(--yrl-teal-dark), var(--yrl-teal), #5eead4);
}

.yrl-bubble-logo .yrl-glow-ring span:nth-of-type(1) {
    filter: blur(4px);
}

.yrl-bubble-logo .yrl-glow-ring span:nth-of-type(2) {
    filter: blur(8px);
}

.yrl-bubble-logo .yrl-glow-ring span:nth-of-type(3) {
    filter: blur(18px);
}

.yrl-bubble-logo .yrl-glow-ring span:nth-of-type(4) {
    filter: blur(36px);
}

/* This sits OUTSIDE the rotating ring, so the picture stays still */
.yrl-bubble-logo .yrl-logo-img {
    position: absolute;
    top: 3px;
    left: 3px;
    right: 3px;
    bottom: 3px;
    border-radius: 50%;
    overflow: hidden;
    border: solid 2px black;
    box-sizing: border-box;
    z-index: 2;
}

.yrl-bubble-logo .yrl-logo-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

@keyframes yrl-rotate-logo {
    from {
        transform: rotate(0deg);
    }

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

.yrl-bubble-text {
    display: inline-flex;
    align-items: center;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.4px;
    color: var(--yrl-white);
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.35), 0 0 6px rgba(0, 0, 0, 0.15);
    white-space: nowrap;
    box-sizing: border-box;
    padding: 8px 14px;
}

.yrl-bubble-text strong {
    color: var(--yrl-white);
    font-weight: 800;
}

/* ---------- WIDGET PANEL (opens above bubble, bottom-left) ---------- */
#yrl-widget {
    position: fixed;
    bottom: 100px;
    left: 24px;
    width: 360px;
    max-width: calc(100vw - 32px);
    height: 520px;
    max-height: calc(100vh - 140px);
    background: #0ABAB5;
    border-radius: 16px;
    border: 2px solid var(--yrl-black);
    overflow: visible;
    display: none;
    flex-direction: column;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
    z-index: 99998;
    opacity: 0;
    transform: translateY(16px) scale(0.98);
    transition: opacity 0.18s ease, transform 0.18s ease;
    font-family: 'Segoe UI', Arial, sans-serif;
}

#yrl-widget.open {
    display: flex;
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* header */
.yrl-header {
    background: var(--yrl-black);
    color: var(--yrl-white);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    flex-shrink: 0;
    position: relative;
    /* needed for the logo's absolute positioning */
    border-top-left-radius: 14px;
    border-top-right-radius: 14px;
}

.yrl-logo {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 10px;
    color: var(--yrl-black);
    text-align: center;
    line-height: 1.1;
    flex-shrink: 0;
    overflow: hidden;
    position: absolute;
    top: -14px;
    left: -14px;
    z-index: 10;
    border: 5px solid transparent;
    background:
        linear-gradient(var(--yrl-teal), var(--yrl-teal)) padding-box,
        conic-gradient(from -45deg, var(--yrl-black) 0deg, #0ABAB5 180deg, var(--yrl-black) 360deg) border-box;
}

.yrl-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.yrl-title {
    font-weight: 700;
    font-size: 14px;
    flex: 1;
    margin-left: 45px;
}

.yrl-header-icons {
    display: flex;
    gap: 10px;
    align-items: center;
}

.yrl-header-icons button {
    background: none;
    border: none;
    color: var(--yrl-white);
    cursor: pointer;
    font-size: 16px;
    padding: 2px;
}

/* body / screens */
.yrl-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.yrl-screen-title {
    font-weight: 800;
    font-size: 15px;
    text-align: center;
    color: var(--yrl-black);
    margin-bottom: 10px;
}

.yrl-divider {
    border: none;
    border-top: 2px solid var(--yrl-black);
    margin-bottom: 14px;
}

.yrl-menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 1fr;
    gap: 12px;
}

.yrl-btn {
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 12px;
    padding: 16px 10px;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;

    font-weight: 700;
    font-size: 12.5px;
    line-height: 1.35;
    color: var(--yrl-black);

    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

#yrl-callback-cancel-btn {
    width: 100%;
    height: 48px;
}

.yrl-btn:hover {
    background: rgba(255, 255, 255, 0.85);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.16), 0 0 0 1px var(--yrl-teal-dark) inset;
}

.yrl-btn:active {
    transform: translateY(-1px) scale(0.98);
    transition: transform 0.08s ease;
}

.yrl-btn:focus-visible {
    outline: 2px solid var(--yrl-black);
    outline-offset: 2px;
}

.yrl-btn.full {
    grid-column: 1 / -1;
}

/* Loading spinner for submit button */
.yrl-btn.loading {
    color: transparent !important;
    pointer-events: none;
    position: relative;
}

.yrl-spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 3px solid rgba(255, 255, 255, 0.35);
    border-top-color: var(--yrl-white);
    border-radius: 50%;
    animation: yrl-spin 0.7s linear infinite;
    perspective: 800px;
    transform-style: preserve-3d;
}

@keyframes yrl-spin {
    0% {
        transform: rotate(0deg) rotateY(0deg);
    }

    100% {
        transform: rotate(360deg) rotateY(360deg);
    }
}

/* placeholder screen */
.yrl-placeholder {
    text-align: center;
    color: var(--yrl-black);
    font-size: 13px;
    font-weight: 600;
    padding: 40px 10px;
    opacity: 0.75;
}

.yrl-back-link {
    display: inline-block;
    margin-top: 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--yrl-black);
    text-decoration: underline;
    cursor: pointer;
}

/* title row: callback icon (left) + title + call/home icons (right) */
.yrl-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.yrl-title-row .yrl-screen-title {
    margin-bottom: 0;
    flex: 1;
}

.yrl-title-icons {
    display: flex;
    gap: 8px;
    align-items: center;
}

.yrl-icon-btn {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    padding: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.8);

    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    position: relative;
    overflow: visible;
}

.yrl-icon-btn svg {
    width: 16px;
    height: 16px;
}

.yrl-icon-btn:hover {
    background: rgba(255, 255, 255, 0.85);
    transform: translateY(-2px) scale(1.06);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.18), 0 0 0 1px var(--yrl-teal-dark) inset;
}

.yrl-icon-btn:active {
    transform: translateY(0) scale(0.9);
    transition: transform 0.08s ease;
}

.yrl-icon-btn:focus-visible {
    outline: 2px solid var(--yrl-black);
    outline-offset: 2px;
}

/* Continuous ripple-ring animation for callback / call / home icon buttons — runs always */
.yrl-icon-btn::before,
.yrl-icon-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1.5px solid rgba(17, 17, 17, 0.45);
    opacity: 0;
    pointer-events: none;
    animation: yrl-icon-ripple 1.6s ease-out infinite;
}

.yrl-icon-btn::after {
    animation-delay: 0.8s;
}

/* WhatsApp button gets its own green-tinted ripple to draw the eye */
#yrl-widget .yrl-title-icons .yrl-icon-btn:first-of-type::before,
#yrl-widget .yrl-title-icons .yrl-icon-btn:first-of-type::after {
    border-color: rgba(37, 211, 102, 0.55);
}

@keyframes yrl-icon-ripple {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }

    100% {
        transform: scale(1.9);
        opacity: 0;
    }
}
#yrl-screen-container input {
    box-sizing: border-box;
}

#yrl-screen-container input:focus {
    outline: 2px solid var(--yrl-teal-dark);
    outline-offset: 2px;
}

#yrl-callback-submit-btn {
    width: 100%;
    height: 48px;
    /* fixed height, won't change in any state */
    position: relative;
    background: #00B26A;
    color: var(--yrl-white);
    border: 2px solid black;
}

#yrl-callback-submit-btn:hover {
    background: #E85A3B;
}

#yrl-callback-submit-btn .btn-text {
    transition: opacity 0.15s ease;
}

#yrl-callback-submit-btn.loading .btn-text {
    opacity: 0;
}

/* ==========================================================
   MOBILE RESPONSIVE
   ========================================================== */

@media (max-width: 480px) {

    /* ---- Bubble ---- */
    #yrl-bubble {
        left: 16px;
        bottom: 16px;
        transform: scale(1);
        /* drop the 1.2x scale-up on small screens */
        height: 46px;
        padding: 0 14px 0 0;
        gap: 8px;
    }

    .yrl-bubble-logo {
        width: 58px;
        height: 58px;
        margin-left: -6px;
        margin-right: 6px;
    }

    .yrl-bubble-text {
        font-size: 12.5px;
    }

    /* ---- Widget panel ---- */
    #yrl-widget {
        left: 12px;
        right: 12px;
        bottom: 74px;
        width: auto;
        /* let left+right control width */
        max-width: none;
        height: auto;
        max-height: calc(100vh - 100px);
    }

    /* ---- Header ---- */
    .yrl-header {
        padding: 8px 10px;
        gap: 8px;
    }

    .yrl-logo {
        width: 34px;
        height: 34px;
    }

    .yrl-title {
        font-size: 12.5px;
        margin-left: 6px;
    }

    /* ---- Body content ---- */
    .yrl-body {
        padding: 12px;
    }

    .yrl-screen-title {
        font-size: 14px;
    }

    .yrl-btn {
        font-size: 11.5px;
        padding: 12px 8px;
        min-height: 40px;
    }

    .yrl-icon-btn {
        width: 30px;
        height: 30px;
    }

    .yrl-icon-btn svg {
        width: 14px;
        height: 14px;
    }
}

/* Extra-small phones: bubble becomes icon-only, grid stacks to 1 column */
@media (max-width: 360px) {
    .yrl-bubble-text {
        display: none;
    }

    #yrl-bubble {
        padding: 0;
        width: 46px;
        justify-content: center;
    }

    .yrl-bubble-logo {
        width: 46px;
        height: 46px;
        margin: 0;
    }

    .yrl-menu-grid {
        grid-template-columns: 1fr;
        /* stack buttons one per row */
    }
}

/* ---------- Menu buttons (Uiverse card style) ---------- */
.yrl-outer-cont {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 15px 14px;
    border: none;
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.35;
    text-align: left;
    min-height: 46px;
    cursor: pointer;
    position: relative;
    background: linear-gradient(90deg, #5bfcc4, #0ABAB5, #71a4f0);
    border-radius: 12px;
    color: #c9fcf6;
    text-shadow: 1px 1px 1px #000;
    box-shadow:
        inset 0px 0px 5px #c9fcf6,
        inset 0px 35px 30px #000,
        0px 5px 10px #000000cc;
    transition: all 0.3s ease;
    font-family: 'Segoe UI', Arial, sans-serif;
}

.yrl-outer-cont svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.yrl-outer-cont::before {
    content: "";
    position: absolute;
    inset: 0;
    margin: auto;
    border-radius: 12px;
    filter: blur(0);
    z-index: -1;
    box-shadow: none;
    background: conic-gradient(#00000000 80deg,
            #40baf7,
            #f34ad7,
            #5bfcc4,
            #00000000 280deg);
    transition: all 0.3s ease;
}

.yrl-outer-cont:hover::before {
    filter: blur(15px);
}

.yrl-outer-cont:active::before {
    filter: blur(5px);
    transform: translateY(1px);
}

.yrl-outer-cont:active {
    box-shadow:
        inset 0px 0px 5px #c9fcf6,
        inset 0px 35px 30px #000;
    transform: translateY(3px);
}

.yrl-outer-cont.full {
    grid-column: 1 / -1;
}

.yrl-outer-cont:focus-visible {
    outline: 2px solid var(--yrl-black);
    outline-offset: 2px;
}