body.widget-id-stroke-open {
    overflow: hidden;
}

.widget-id-stroke-screen {
    position: fixed;
    inset: 0;
    z-index: 2147483646;
    display: flex;
    flex-direction: column;
    background: var(--bg-page, #FAF8F5);
    color: var(--text-primary, #111827);
    font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    overflow: hidden;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

.widget-id-stroke-screen[hidden] {
    display: none !important;
}

.widget-id-stroke-screen__header {
    position: relative;
    z-index: 4;
    padding: clamp(20px, 4vw, 40px) clamp(20px, 5vw, 48px) clamp(12px, 2vw, 20px);
    text-align: center;
    pointer-events: none;
}

.widget-id-stroke-screen__title {
    margin: 0;
    font-size: clamp(1.65rem, 4.8vw, 2.75rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text-primary, #111827);
}

.widget-id-stroke-screen__subtitle {
    margin: clamp(10px, 2vw, 16px) auto 0;
    max-width: 42rem;
    font-size: clamp(0.95rem, 2.2vw, 1.15rem);
    line-height: 1.5;
    color: var(--text-secondary, #6B7280);
}

.widget-id-stroke-screen__stage {
    position: relative;
    flex: 1 1 auto;
    min-height: 0;
}

.widget-id-stroke-screen__percent {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(5rem, 28vw, 14rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    color: rgba(0, 82, 255, 0.11);
    font-variant-numeric: tabular-nums;
    pointer-events: none;
}

.widget-id-stroke-screen.is-ready .widget-id-stroke-screen__percent {
    color: rgba(16, 185, 129, 0.16);
}

.widget-id-stroke-screen__canvas {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    cursor: crosshair;
    touch-action: none;
}

.widget-id-stroke-screen__footer {
    position: relative;
    z-index: 4;
    padding: 12px clamp(16px, 4vw, 32px) clamp(16px, 3vw, 28px);
    text-align: center;
}

.widget-id-stroke-screen__id {
    margin: 0 0 8px;
    font-size: 0.95rem;
    color: var(--text-secondary, #6B7280);
}

.widget-id-stroke-screen__id strong {
    color: var(--brand-main, #0052FF);
    font-size: 0.82rem;
    letter-spacing: 0.06em;
    word-break: break-all;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.widget-id-stroke-screen__error {
    margin: 0 0 10px;
    font-size: 0.9rem;
    color: #dc2626;
}

.widget-id-stroke-screen__reset {
    border: 1px solid var(--border-color, #E5E7EB);
    background: rgba(255, 255, 255, 0.85);
    color: var(--text-secondary, #6B7280);
    border-radius: 999px;
    padding: 10px 18px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    backdrop-filter: blur(6px);
}

.widget-id-stroke-screen__reset:hover {
    background: #fff;
    color: var(--text-primary, #111827);
}

.widget-id-stroke-screen.is-generating .widget-id-stroke-screen__canvas {
    pointer-events: none;
    opacity: 0.65;
}
