/* Калькулятор лестницы */
.calc-app.str-app {
    max-width: 1080px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.str-app [hidden] {
    display: none !important;
}

.str-section--inputs {
    margin-bottom: 16px;
    padding: 16px 18px;
    background: #fff;
    border: 1px solid #e5e5ea;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.str-type-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin-bottom: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid #ececf0;
}

.str-type-label {
    font-size: 13px;
    font-weight: 600;
    color: #1d1d1f;
}

.str-type-switch {
    display: inline-flex;
    padding: 3px;
    background: #f0f0f5;
    border-radius: 12px;
    gap: 2px;
}

.str-type-btn {
    border: none;
    background: transparent;
    color: #555;
    font-size: 13px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}

.str-type-btn:hover {
    color: #1d1d1f;
}

.str-type-btn.is-active {
    background: #fff;
    color: #e65100;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.str-type-btn:focus-visible {
    outline: 2px solid #ff9800;
    outline-offset: 2px;
}

.str-inputs-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.str-inputs-grid .calc-field {
    margin-bottom: 0 !important;
    min-width: 0;
}

.str-check {
    margin-top: 14px;
    margin-bottom: 0;
}

.str-outcome {
    margin: 0;
}

.str-result-sheet {
    padding: 16px 18px;
    background: #fafafa;
    border: 1px solid #e5e5ea;
    border-radius: 16px;
    margin-bottom: 16px;
}

.str-result-hero {
    text-align: center;
    margin-bottom: 12px;
}

.str-explainer {
    margin-bottom: 14px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #e5e5ea;
    border-radius: 12px;
}

.str-explainer-title {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 700;
    color: #1d1d1f;
}

.str-explainer-list {
    margin: 0;
    padding: 0 0 0 18px;
    font-size: 13px;
    color: #333;
    line-height: 1.5;
}

.str-explainer-list li {
    margin-bottom: 6px;
}

.str-explainer-list li:last-child {
    margin-bottom: 0;
}

.str-app .calc-result-value--accent {
    color: #e85d04;
}

.str-hero-sub {
    margin: 6px 0 0;
    font-size: 14px;
    color: #6e6e73;
}

.str-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 12px;
}

.str-summary-col {
    padding: 12px 10px;
    background: #f5f5f7;
    border-radius: 12px;
    text-align: center;
}

.str-summary-col--highlight {
    background: linear-gradient(165deg, #fff4ec 0%, #fff8f5 100%);
    border: 1px solid #ffd6bf;
}

.str-summary-col--highlight .str-summary-big {
    color: #e85d04;
}

.str-summary-label {
    display: block;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #6e6e73;
    margin-bottom: 5px;
}

.str-summary-big {
    font-size: 16px;
    font-weight: 700;
    color: #1d1d1f;
}

.str-warnings {
    list-style: none;
    margin: 0 0 12px;
    padding: 0;
}

.str-warn {
    padding: 8px 12px;
    margin-bottom: 6px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.4;
}

.str-warn--error {
    background: #ffebee;
    color: #b71c1c;
}

.str-warn--warn {
    background: #fff8e1;
    color: #e65100;
}

.str-warn--info {
    background: #f5f5f7;
    color: #6e6e73;
}

.str-extra--compact {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.str-extra-row {
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #e5e5ea;
    border-radius: 10px;
    font-size: 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.str-extra-row strong {
    font-size: 15px;
    color: #1d1d1f;
}

.str-visual-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.str-draw-block {
    padding: 14px;
    background: #fff;
    border: 1px solid #e5e5ea;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    min-height: 360px;
}

.str-draw-title {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 700;
}

.str-3d-hint {
    margin: -4px 0 8px;
    font-size: 12px;
    color: #6e6e73;
}

.str-draw-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.str-draw-tab {
    padding: 6px 14px;
    border: 1px solid #e5e5ea;
    border-radius: 999px;
    background: #fff;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.str-draw-tab.is-active {
    border-color: #e85d04;
    color: #e85d04;
    background: #fff8f5;
}

.str-svg-wrap {
    flex: 1;
    min-height: 300px;
    background: #fafafa;
    border-radius: 12px;
    overflow: hidden;
}

.str-3d-wrap {
    flex: 1;
    min-height: 300px;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: #eef0f4;
}

.str-3d-wrap canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.str-materials-block {
    margin-bottom: 16px;
    padding: 16px 18px;
    background: #fff;
    border: 1px solid #e5e5ea;
    border-radius: 16px;
}

.str-materials-heading {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 700;
}

.str-materials-lead {
    margin: 0 0 12px;
    font-size: 13px;
    color: #6e6e73;
}

.str-materials-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.str-materials-row {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) auto;
    grid-template-rows: auto auto;
    gap: 2px 12px;
    padding: 10px 12px;
    background: #f5f5f7;
    border-radius: 10px;
}

.str-materials-title {
    grid-column: 1;
    font-size: 13px;
    font-weight: 600;
    color: #1d1d1f;
}

.str-materials-value {
    grid-column: 2;
    grid-row: 1 / 3;
    align-self: center;
    font-size: 15px;
    font-weight: 700;
    color: #e85d04;
    text-align: right;
    white-space: nowrap;
}

.str-materials-note {
    grid-column: 1;
    font-size: 12px;
    color: #6e6e73;
}

.str-result-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.str-action {
    min-height: 40px;
    padding: 8px 18px;
    border: 1px solid #e5e5ea;
    border-radius: 999px;
    background: #fff;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.str-action:hover {
    border-color: #e85d04;
    color: #e85d04;
}

.str-print-body {
    padding: 24px;
}

.str-export-wrap {
    position: fixed;
    left: -9999px;
    top: 0;
    width: 900px;
    padding: 16px;
    background: #fafafa;
}

@media (max-width: 720px) {
    .str-inputs-grid {
        grid-template-columns: 1fr;
    }

    .str-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .str-extra--compact {
        grid-template-columns: 1fr;
    }

    .str-visual-row {
        grid-template-columns: 1fr;
    }

    .str-draw-block {
        min-height: 280px;
    }
}
