@charset "utf-8";

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: #faf9f8;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 16px;
    color: #333;
    -webkit-font-smoothing: antialiased;
}

.captcha-page {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    min-height: 100vh;
    align-items: center;
    justify-content: center;
}

.captcha-wrapper {
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
    padding: 1.5rem 1.25rem 2rem;
}

.captcha-content {
    width: 100%;
}

.captcha-card {
    background: #fff;
    border: 1px solid #e8e6e3;
    border-radius: 6px;
    padding: 2rem 1.75rem 1.75rem;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.06);
}

.captcha-logo {
    display: block;
    width: 48px;
    height: 48px;
    margin-bottom: 1.25rem;
    line-height: 0;
    flex-shrink: 0;
}

.captcha-logo img {
    display: block;
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.captcha-title {
    font-weight: 700;
    font-size: 1.375rem;
    margin-bottom: 0.5rem;
    line-height: 1.35;
    color: #333;
}

.captcha-subtitle {
    font-size: 0.9375rem;
    line-height: 1.55;
    color: #666;
    margin-bottom: 1.5rem;
}

.captcha-alert-error {
    background: #fde8e4;
    color: #c0392b;
    border-radius: 4px;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    text-align: center;
}

.captcha-widget {
    background: #faf9f8;
    border: 1px solid #e8e6e3;
    border-radius: 6px;
    padding: 1.25rem 1.125rem 1.125rem;
}

.captcha-image-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.captcha-image-wrap {
    flex: 1;
    min-width: 0;
    border: 1px solid #e0deda;
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
    line-height: 0;
}

.captcha-img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 80px;
    object-fit: cover;
}

.captcha-refresh-btn {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: #fff;
    border: 1px solid #e0deda;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.18s, border-color 0.18s;
    color: #333;
}

.captcha-refresh-btn:hover {
    background: #fff8d6;
    border-color: #fc0;
}

.captcha-refresh-btn svg {
    width: 20px;
    height: 20px;
}

.captcha-refresh-btn.spinning svg {
    animation: captcha-spin 0.7s linear infinite;
}

@keyframes captcha-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

.captcha-input-label {
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #555;
}

.captcha-input-row {
    margin-bottom: 0.35rem;
}

.captcha-input {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-align: center;
    border: 1px solid #e0deda;
    border-radius: 4px;
    background: #fff;
    color: #333;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.captcha-input:focus {
    border-color: #fc0;
    box-shadow: 0 0 0 3px rgba(255, 204, 0, 0.2);
}

.captcha-input--error,
.captcha-input--error:focus {
    border-color: #c0392b;
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.12);
}

.captcha-input-error {
    display: block;
    color: #c0392b;
    font-size: 0.8125rem;
    font-weight: 600;
    min-height: 1.125rem;
    margin-bottom: 0.25rem;
}

.captcha-btn-row {
    margin-top: 0.875rem;
}

.captcha-btn-submit {
    display: block;
    width: 100%;
    padding: 0.9rem 1rem;
    background: #fc0;
    color: #333;
    font-size: 1rem;
    font-weight: 700;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
    font-family: inherit;
}

.captcha-btn-submit:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.captcha-btn-submit:not(:disabled):hover {
    background: #e6b800;
}

.captcha-badge {
    display: flex;
    justify-content: flex-end;
    margin-top: 1.125rem;
}

.captcha-badge-text {
    font-size: 0.75rem;
    color: #999;
    line-height: 1.5;
    text-align: right;
}
