/* ===== Floating button ===== */
@keyframes itkin-callback-icon-wobble {
    0%, 10%, 100% {
        transform: rotate(0) scale(1) skew(1deg);
    }
    2%, 6% {
        transform: rotate(-15deg) scale(1) skew(1deg);
    }
    4%, 8% {
        transform: rotate(15deg) scale(1) skew(1deg);
    }
}

#itkin-callback-button {
    position: fixed;
    z-index: 999998;
    bottom: 90px;
    right: 10px;
    width: 80px;
    height: 80px;
    cursor: pointer;
}

#itkin-callback-button .itkin-callback-circle {
    width: 80px;
    height: 80px;
}

#itkin-callback-button .itkin-callback-circle-outside {
    fill: #2a405d;
    fill-opacity: 0.08;
}

#itkin-callback-button .itkin-callback-circle-inside {
    fill: var(--itkin-button-color, #21304E);
    transition: filter 0.2s ease-in-out;
}

#itkin-callback-button:hover .itkin-callback-circle-inside {
    filter: brightness(0.85);
}

#itkin-callback-button .itkin-callback-icon {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
    pointer-events: none;
}

#itkin-callback-button .itkin-callback-icon path {
    animation: itkin-callback-icon-wobble 5s ease-in-out infinite;
    transform-origin: 50% 50%;
}

/* Tooltip */
#itkin-callback-button .itkin-callback-tooltip {
    position: absolute;
    bottom: 50px;
    right: 100px;
    width: 170px;
    padding: 12px 16px;
    background: var(--itkin-button-color, #21304E);
    color: #fff;
    font: 400 13px/16px Arial, sans-serif;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out;
}

#itkin-callback-button:hover .itkin-callback-tooltip {
    opacity: 1;
}

#itkin-callback-button .itkin-callback-tooltip::after {
    content: "";
    position: absolute;
    bottom: 10px;
    right: -10px;
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-left: 10px solid var(--itkin-button-color, #21304E);
}

/* ===== Modal ===== */
.itkin-callback-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    padding: 20px 0;
}

.itkin-callback-overlay {
    position: fixed;
    inset: 0;
    background: rgba(23, 23, 30, 0.5);
    cursor: pointer;
}

.itkin-callback-box {
    position: relative;
    width: 90%;
    max-width: 380px;
    margin: 0 auto;
    background: #fff;
    padding: 40px 28px 28px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
}

.itkin-callback-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 24px;
    height: 24px;
    background: transparent;
    border: 0;
    font-size: 22px;
    line-height: 1;
    color: #999;
    cursor: pointer;
}

.itkin-callback-close:hover {
    color: #333;
}

.itkin-callback-message {
    font: 400 18px/24px Arial, sans-serif;
    color: #444;
    text-align: center;
    margin-bottom: 22px;
}

.itkin-callback-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.itkin-callback-input {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    font: 400 16px/48px Arial, sans-serif;
    border: 1px solid #ddd;
    box-sizing: border-box;
}

.itkin-callback-input.itkin-invalid {
    border-color: #e0405c;
}

.itkin-callback-honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.itkin-callback-submit {
    height: 48px;
    background: var(--itkin-modal-button-color, #21304E);
    color: #fff;
    border: 0;
    font: 400 16px/48px Arial, sans-serif;
    cursor: pointer;
    transition: filter 0.2s ease-in-out;
}

.itkin-callback-submit:hover {
    filter: brightness(0.85);
}

.itkin-callback-submit:disabled {
    background: #ccc;
    cursor: default;
}

.cf-turnstile {
    margin-top: 4px;
}

.itkin-callback-error {
    color: #e0405c;
    font: 400 13px/18px Arial, sans-serif;
    min-height: 18px;
}

.itkin-callback-success {
    text-align: center;
    font: 400 18px/24px Arial, sans-serif;
    color: #444;
    padding: 10px 0 4px;
}

@media all and (max-width: 480px) {
    #itkin-callback-button {
        bottom: 16px;
        right: 16px;
    }

    .itkin-callback-box {
        margin-top: 60px;
    }
}
