.t4w-captcha {
    box-sizing: border-box;
    width: 100%;
    max-width: 320px;
    min-height: 74px;
    border: 1px solid #d3d3d3;
    border-radius: 4px;
    background: #fafafa;
    color: #222;
    font-family: Arial, Helvetica, sans-serif;
    user-select: none;
    isolation: isolate;
}

.t4w-captcha a,
.t4w-captcha a:visited {
    color: #1565c0 !important;
}

.t4w-captcha a:hover {
    color: #0d47a1 !important;
    text-decoration: underline;
}

.t4w-captcha--success {
    border-color: #4caf50;
}

.t4w-captcha--error {
    border-color: #e53935;
}

.t4w-captcha__compact {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 74px;
    padding: 0 14px;
}

.t4w-captcha__checkbox-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    margin: 0;
    cursor: pointer;
}

.t4w-captcha__checkbox {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.t4w-captcha__checkmark {
    display: block;
    width: 26px;
    height: 26px;
    border: 2px solid #c1c1c1;
    border-radius: 2px;
    background: #fff;
    transition: border-color 0.2s, background 0.2s;
}

.t4w-captcha__checkbox:focus-visible + .t4w-captcha__checkmark {
    outline: 2px solid #1a73e8;
    outline-offset: 2px;
}

.t4w-captcha__checkbox:checked + .t4w-captcha__checkmark,
.t4w-captcha--success .t4w-captcha__checkmark {
    border-color: #4caf50;
    background: #4caf50;
}

.t4w-captcha__checkbox:checked + .t4w-captcha__checkmark::after,
.t4w-captcha--success .t4w-captcha__checkmark::after {
    content: '';
    position: absolute;
    left: 9px;
    top: 4px;
    width: 7px;
    height: 14px;
    border: solid #fff;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.t4w-captcha__label {
    flex: 1;
    font-size: 14px;
    line-height: 1.2;
    color: #222 !important;
}

.t4w-captcha__brand {
    font-size: 10px;
    line-height: 1.2;
    color: #888;
    text-align: right;
    white-space: normal;
    max-width: 118px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.t4w-captcha__brand-caption {
    display: block;
    font-size: 10px;
    color: #666 !important;
}

.t4w-captcha__brand a {
    display: block;
    margin-top: 2px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.25;
    color: #1565c0 !important;
    text-decoration: none;
}

.t4w-captcha__brand a:hover {
    color: #0d47a1 !important;
    text-decoration: underline;
}

.t4w-captcha__spinner {
    width: 22px;
    height: 22px;
    border: 2px solid #ddd;
    border-top-color: #1a73e8;
    border-radius: 50%;
    animation: t4w-captcha-spin 0.8s linear infinite;
}

@keyframes t4w-captcha-spin {
    to { transform: rotate(360deg); }
}

.t4w-captcha__challenge {
    padding: 10px 10px 12px;
}

.t4w-captcha__puzzle {
    position: relative;
    width: 100%;
    max-width: 300px;
    margin: 0 auto 10px;
    overflow: hidden;
    border-radius: 4px;
    background: #1a1a2e;
}

.t4w-captcha__bg {
    display: block;
    width: 100%;
    height: auto;
}

.t4w-captcha__piece {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

.t4w-captcha__slider {
    max-width: 300px;
    margin: 0 auto;
}

.t4w-captcha__slider-track {
    position: relative;
    height: 38px;
    border-radius: 4px;
    background: #ececec;
    border: 1px solid #d0d0d0;
}

.t4w-captcha__slider-thumb {
    position: absolute;
    top: 0;
    left: 0;
    width: 46px;
    height: 36px;
    border-radius: 3px;
    background: #fff;
    border: 1px solid #c8c8c8;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #666;
    cursor: grab;
    touch-action: none;
}

.t4w-captcha__slider-thumb:active {
    cursor: grabbing;
}

.t4w-captcha__slider-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #777;
    text-align: center;
}

.t4w-captcha__message {
    margin: 8px 0 0;
    font-size: 12px;
    text-align: center;
    color: #e53935;
}

.t4w-captcha__refresh {
    display: block;
    margin: 8px auto 0;
    padding: 0;
    border: 0;
    background: none;
    color: #1a73e8;
    font-size: 12px;
    cursor: pointer;
    text-decoration: underline;
}

.t4w-captcha__refresh:hover {
    color: #0d47a1;
}

.smart-captcha:not([data-t4w-init]) {
    min-height: 74px;
}
