/* Metrekare Hesaplama - sayfa bazlı stiller */

.step-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #6c757d;
    font-weight: 600;
    font-size: 13px;
    min-width: 92px;
}

.step-badge.active {
    background: #0d6efd;
    border-color: #0d6efd;
    color: #fff;
}

.step-line {
    flex: 1;
    height: 2px;
    background: #e9ecef;
    border-radius: 999px;
    min-width: 18px;
}

.choice-tile {
    display: block;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    padding: 0;
    cursor: pointer;
    background: linear-gradient(145deg, #fff, #f8f9fa);
    transition: all .2s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.choice-tile input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    inset: 0;
}

.choice-tile-body {
    padding: 16px;
    border-radius: 14px;
    min-height: 86px;
}

.choice-title {
    font-weight: 800;
    font-size: 16px;
    color: #212529;
}

.choice-desc {
    font-size: 13px;
    margin-top: 4px;
}

/* :has() desteklenmeyen browser'larda sorun çıkarmasın diye fallback */
.choice-tile.is-checked,
.choice-tile:has(input:checked) {
    border-color: rgba(13,110,253,.6);
    box-shadow: 0 8px 24px rgba(13,110,253,.12);
    transform: translateY(-1px);
}

.result-card {
    border: 1px solid #e9ecef;
    border-radius: 14px;
    padding: 14px;
    background: #fff;
}

.result-label {
    color: #6c757d;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .4px;
}

.result-value {
    font-size: 22px;
    font-weight: 800;
    color: #0d6efd;
    margin-top: 8px;
    line-height: 1.1;
}

.result-unit {
    font-size: 14px;
    font-weight: 700;
    color: #1f2d3d;
}

.result-hint {
    margin-top: 6px;
    font-size: 12px;
}

/* 2. ürün select'i görünürken tıklanabilir olsun */
#patternOptions select.form-select {
    pointer-events: auto;
    opacity: 1;
}

/* pattern options içinde tıklanabilirlik garantisi */
#patternOptions,
#patternOptions * {
    pointer-events: auto;
}

#productSelect2:disabled {
    cursor: not-allowed;
}

#productSelect2:not(:disabled) {
    cursor: pointer;
}

#patternOptions {
    position: relative !important;
    z-index: 999 !important;
    pointer-events: auto !important;
}

#patternOptions .card,
#patternOptions .card-body {
    position: relative !important;
    z-index: 999 !important;
    pointer-events: auto !important;
}

#productSelect2 {
    position: relative !important;
    z-index: 10000 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
}

#productSelect2:disabled {
    pointer-events: none !important;
    cursor: not-allowed !important;
}

#patternOptions label.form-label {
    pointer-events: none !important;
}

.choice-tile,
.choice-tile-body {
    overflow: visible;
}

#patternOptions label {
    pointer-events: none !important;
}

#patternOptions select,
#patternOptions select * {
    pointer-events: auto !important;
}

.m2-calc-page .form-control,
.m2-calc-page .form-select {
    border-radius: 12px;
    min-height: 44px;
}

.m2-calc-page .input-group-text {
    border-radius: 12px;
    font-weight: 600;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.m2-calc-page .input-group > .form-control {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.preview-card .preview-canvas-wrapper {
    border: 1px solid #e5e5e5;
    border-radius: 14px;
    padding: 16px;
    background: #fff;
}

.preview-card .preview-canvas {
    width: 100%;
    height: auto;
    display: block;
    min-height: 420px;
}

@media (max-width: 991.98px) {
    .preview-card .preview-canvas {
        min-height: 300px;
    }
}
