/* 在线尺子（screen-ruler） */
.srl-stage-wrap {
    margin: 1rem 0 1.25rem;
    padding: .9rem 1rem 1rem;
    border-radius: 12px;
    background: rgba(127, 127, 127, .07);
    border: 1px solid rgba(127, 127, 127, .18);
}

.srl-stage-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    flex-wrap: wrap;
    margin-bottom: .6rem;
}

.srl-info {
    font-size: 13px;
    opacity: .85;
}

/* 尺子画布区 */
.srl-stage {
    position: relative;
    height: 150px;
    border-radius: 10px;
    overflow: hidden;
    background: rgba(127, 127, 127, .10);
    touch-action: none;
    cursor: crosshair;
}

.srl-stage.is-v {
    height: 460px;
}

.srl-stage canvas {
    position: absolute;
    left: 0;
    top: 0;
    display: block;
}

/* 游标 */
.srl-mark {
    position: absolute;
    z-index: 3;
    background: #ef4444;
    touch-action: none;
}

.srl-mark-b {
    background: #3b82f6;
}

.srl-mark i {
    position: absolute;
    display: block;
    background: inherit;
    border-radius: 4px;
}

.srl-stage:not(.is-v) .srl-mark {
    top: 0;
    width: 2px;
    height: 100%;
    cursor: ew-resize;
}

.srl-stage:not(.is-v) .srl-mark i {
    left: -7px;
    top: 0;
    width: 16px;
    height: 26px;
}

.srl-stage.is-v .srl-mark {
    left: 0;
    height: 2px;
    width: 100%;
    cursor: ns-resize;
}

.srl-stage.is-v .srl-mark i {
    top: -7px;
    left: 0;
    height: 16px;
    width: 26px;
}

/* 校准条 */
.srl-calib-row {
    margin-top: .7rem;
}

.srl-bar {
    position: relative;
    height: 46px;
    border-radius: 8px;
    border: 2px dashed rgba(127, 127, 127, .55);
    display: flex;
    align-items: center;
    justify-content: center;
    background: repeating-linear-gradient(45deg, rgba(127, 127, 127, .12) 0 10px, transparent 10px 20px);
}

.srl-bar-label {
    font-size: 12px;
    opacity: .8;
    pointer-events: none;
    text-align: center;
    padding: 0 24px;
}

.srl-bar-handle {
    position: absolute;
    right: -10px;
    top: -2px;
    bottom: -2px;
    width: 22px;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: ew-resize;
    font-size: 14px;
    touch-action: none;
    user-select: none;
}

.srl-tip {
    margin: .6rem 0 0;
    font-size: 13px;
    opacity: .85;
    line-height: 1.7;
}

@media (max-width: 640px) {
    .srl-stage.is-v {
        height: 380px;
    }
}
