/* ============================================
   FLATERO - Price Calculator Wizard
   Mobile-first responsive styling
   Phase 49: Calculator Wizard Frontend
   
   Components:
   1. Section & Container
   2. Wizard Container
   3. Progress Bar
   4. Step Container
   5. Selection Cards (services, house type)
   6. Size Presets & Slider
   7. Floor Buttons
   8. Email & GDPR
   9. Result Display
   10. Navigation Buttons
   11. Responsive Overrides
   12. Animations
   ============================================ */

/* ==========  1. SECTION & CONTAINER  ========== */
.calculator {
    padding: var(--section-padding) 0;
    background: var(--gray-50);
}

/* Section tag color variation - CTA orange for calculator */
.calculator .section-tag {
    color: var(--cta-dark);
    background: var(--cta-lighter);
    border-color: rgba(234, 88, 12, 0.2);
}

.calculator .section-subtitle {
    color: var(--gray-600);
    max-width: 600px;
    margin: 0 auto;
    font-size: var(--font-size-lg);
    line-height: var(--line-height-relaxed);
}

/* ==========  2. WIZARD CONTAINER  ========== */
.calculator-wizard {
    max-width: 680px;
    margin: 0 auto;
    background: var(--white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    padding: var(--space-5);
}

@media (min-width: 641px) {
    .calculator-wizard {
        padding: var(--space-8);
    }
}

/* ==========  3. PROGRESS BAR  ========== */
.calculator-progress {
    margin-bottom: var(--space-8);
}

.calculator-progress__track {
    height: 4px;
    background: var(--gray-200);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--space-4);
}

.calculator-progress__fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: var(--radius-full);
    transition: width 0.4s ease;
}

.calculator-progress__steps {
    display: flex;
    justify-content: space-between;
    margin-top: var(--space-3);
}

.calculator-progress__dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--gray-200);
    color: var(--gray-500);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-slow);
    line-height: 1;
}

.calculator-progress__dot--active {
    background: var(--primary);
    color: var(--white);
}

.calculator-progress__dot--done {
    background: var(--success);
    color: var(--white);
}

/* A11Y: aria-current indicator for screen readers + visual emphasis */
.calculator-progress__dot[aria-current="step"] {
    background: var(--primary);
    color: var(--white);
    font-weight: var(--font-weight-bold);
    box-shadow: 0 0 0 3px rgba(30, 41, 59, 0.15);
}

/* ==========  4. STEP CONTAINER  ========== */
.calculator-step {
    display: none;
}

.calculator-step--active {
    display: block;
    animation: calcFadeIn 0.3s ease forwards;
}

.calculator-step__title {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-bold);
    color: var(--gray-800);
    margin-bottom: var(--space-2);
}

@media (min-width: 641px) {
    .calculator-step__title {
        font-size: var(--font-size-xl);
    }
}

.calculator-step__desc {
    font-size: var(--font-size-sm);
    color: var(--gray-500);
    margin-bottom: var(--space-6);
}

/* ==========  5. SELECTION CARDS  ========== */
.calculator-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-3);
}

@media (min-width: 641px) {
    .calculator-cards {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-4);
    }
}

.calculator-card {
    position: relative;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: var(--space-3);
    min-height: 64px;
    padding: var(--space-4);
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-normal);
    text-align: left;
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    line-height: var(--line-height-normal);
}

@media (min-width: 641px) {
    .calculator-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: var(--space-6) var(--space-4);
        min-height: 140px;
    }
}

.calculator-card:hover {
    border-color: var(--gray-300);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.calculator-card:focus-visible {
    outline: none;
    border-color: var(--primary);
    box-shadow: var(--focus-ring-shadow);
}

.calculator-card--selected {
    border-color: var(--primary);
    background: var(--primary-bg);
}

.calculator-card--selected:hover {
    border-color: var(--primary);
}

.calculator-card__icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all var(--transition-normal);
}

@media (min-width: 641px) {
    .calculator-card__icon {
        width: 56px;
        height: 56px;
        margin-bottom: var(--space-3);
    }
}

.calculator-card--selected .calculator-card__icon {
    background: var(--primary-bg);
    color: var(--primary);
}

.calculator-card__label {
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-semibold);
    color: var(--gray-800);
}

.calculator-card__desc {
    font-size: var(--font-size-xs);
    color: var(--gray-500);
    margin-top: var(--space-1);
}

@media (max-width: 640px) {
    .calculator-card__desc {
        margin-top: 0;
    }
}

.calculator-card__check {
    position: absolute;
    top: var(--space-2);
    right: var(--space-2);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0);
    transition: all var(--transition-normal);
}

.calculator-card--selected .calculator-card__check {
    opacity: 1;
    transform: scale(1);
}

/* ==========  6. SIZE PRESETS & SLIDER  ========== */
.calculator-size__presets {
    display: flex;
    gap: var(--space-2);
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: var(--space-6);
}

.calculator-preset {
    padding: var(--space-2) var(--space-4);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-full);
    background: var(--white);
    font-family: inherit;
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    color: var(--gray-700);
    cursor: pointer;
    transition: all var(--transition-normal);
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calculator-preset:hover {
    border-color: var(--gray-300);
    background: var(--gray-50);
}

.calculator-preset:focus-visible {
    outline: none;
    border-color: var(--primary);
    box-shadow: var(--focus-ring-shadow);
}

.calculator-preset--active {
    border-color: var(--primary);
    background: var(--primary-bg);
    color: var(--primary);
    font-weight: var(--font-weight-semibold);
}

.calculator-size__slider {
    margin-top: var(--space-4);
}

/* Range input - Cross-browser styling */
.calculator-size__slider input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    background: var(--gray-200);
    border-radius: var(--radius-full);
    outline: none;
    cursor: pointer;
}

/* Chrome/Safari/Edge track */
.calculator-size__slider input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    border-radius: var(--radius-full);
    background: linear-gradient(
        to right,
        var(--primary) 0%,
        var(--primary) var(--range-progress, 22%),
        var(--gray-200) var(--range-progress, 22%),
        var(--gray-200) 100%
    );
}

/* Firefox track */
.calculator-size__slider input[type="range"]::-moz-range-track {
    height: 4px;
    border-radius: var(--radius-full);
    background: var(--gray-200);
}

.calculator-size__slider input[type="range"]::-moz-range-progress {
    height: 4px;
    border-radius: var(--radius-full);
    background: var(--primary);
}

/* Chrome/Safari/Edge thumb */
.calculator-size__slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid var(--primary);
    box-shadow: var(--shadow-md);
    cursor: pointer;
    margin-top: -10px;
    transition: transform var(--transition-fast), box-shadow 0.15s ease;
}

.calculator-size__slider input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow: var(--shadow-lg);
}

/* Firefox thumb */
.calculator-size__slider input[type="range"]::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid var(--primary);
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: transform var(--transition-fast), box-shadow 0.15s ease;
}

.calculator-size__slider input[type="range"]::-moz-range-thumb:hover {
    transform: scale(1.15);
    box-shadow: var(--shadow-lg);
}

/* Focus ring for accessibility */
.calculator-size__slider input[type="range"]:focus-visible {
    outline: none;
}

.calculator-size__slider input[type="range"]:focus-visible::-webkit-slider-thumb {
    box-shadow: var(--focus-ring-shadow), var(--shadow-md);
}

.calculator-size__slider input[type="range"]:focus-visible::-moz-range-thumb {
    box-shadow: var(--focus-ring-shadow), var(--shadow-md);
}

.calculator-size__value {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: var(--space-2);
    margin-top: var(--space-4);
}

/* Editable number input — styled to look like inline text with subtle pill affordance */
.calculator-kvm-input {
    font-size: var(--font-size-3xl);
    font-weight: var(--font-weight-bold);
    color: var(--primary);
    width: 4.5ch;
    text-align: center;
    border: 1px solid transparent !important;
    border-bottom: 1px solid transparent !important;
    background: var(--gray-50, #f8fafc);
    border-radius: var(--radius);
    padding: var(--space-1) var(--space-2);
    outline: none;
    text-decoration: none !important;
    -moz-appearance: textfield;
    appearance: textfield;
    font-family: inherit;
    line-height: 1.2;
    transition: background var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.calculator-kvm-input::-webkit-outer-spin-button,
.calculator-kvm-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.calculator-kvm-input:hover {
    background: var(--gray-100, #f1f5f9);
    border-color: var(--gray-200, #e2e8f0);
}

.calculator-kvm-input:focus {
    background: #fff;
    border-color: var(--primary);
    box-shadow: var(--focus-ring-shadow);
}

.calculator-size__unit {
    font-size: var(--font-size-xl);
    font-weight: var(--font-weight-semibold);
    color: var(--gray-500);
}

/* ==========  7. FLOOR BUTTONS  ========== */
.calculator-floors {
    display: flex;
    gap: var(--space-3);
    justify-content: center;
    flex-direction: column;
}

@media (min-width: 641px) {
    .calculator-floors {
        flex-direction: row;
        gap: var(--space-4);
    }
}

.calculator-floor-btn {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4) var(--space-6);
    min-height: 56px;
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-normal);
    font-family: inherit;
    color: inherit;
}

@media (min-width: 641px) {
    .calculator-floor-btn {
        flex-direction: column;
        align-items: center;
        padding: var(--space-6) var(--space-8);
        min-width: 100px;
        min-height: 100px;
        justify-content: center;
    }
}

.calculator-floor-btn:hover {
    border-color: var(--gray-300);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.calculator-floor-btn:focus-visible {
    outline: none;
    border-color: var(--primary);
    box-shadow: var(--focus-ring-shadow);
}

.calculator-floor-btn--selected {
    border-color: var(--primary);
    background: var(--primary-bg);
}

.calculator-floor-btn__number {
    font-size: var(--font-size-3xl);
    font-weight: var(--font-weight-bold);
    color: var(--gray-800);
    line-height: 1;
}

.calculator-floor-btn--selected .calculator-floor-btn__number {
    color: var(--primary);
}

.calculator-floor-btn__label {
    font-size: var(--font-size-xs);
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
}

/* ==========  8. EMAIL & GDPR  ========== */
.calculator-email {
    max-width: 440px;
    margin: 0 auto;
}

.calculator-gdpr {
    margin-top: var(--space-4);
}

.calculator-checkbox {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    cursor: pointer;
    font-size: var(--font-size-sm);
    line-height: var(--line-height-normal);
}

/* Visually hide the native checkbox */
.calculator-checkbox input[type="checkbox"] {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.calculator-checkbox__mark {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    transition: all var(--transition-normal);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2px;
    background: var(--white);
}

.calculator-checkbox input:checked + .calculator-checkbox__mark {
    background: var(--primary);
    border-color: var(--primary);
    /* Checkmark via CSS */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
    background-size: 14px;
    background-position: center;
    background-repeat: no-repeat;
}

.calculator-checkbox input:focus-visible + .calculator-checkbox__mark {
    box-shadow: var(--focus-ring-shadow);
    border-color: var(--primary);
}

.calculator-checkbox__text {
    color: var(--gray-600);
    font-size: var(--font-size-sm);
}

.calculator-checkbox__text a {
    color: var(--primary);
    text-decoration: underline;
}

.calculator-checkbox__text a:hover {
    color: var(--primary-dark);
}

/* ==========  9. RESULT DISPLAY  ========== */
.calculator-result {
    text-align: center;
    padding: var(--space-8) 0;
}

.calculator-result__loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-8) 0;
}

.calculator-result__loading p {
    color: var(--gray-500);
    font-size: var(--font-size-base);
}

.calculator-spinner {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary);
    animation: spin 0.8s linear infinite;
}

.calculator-result__heading {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-semibold);
    color: var(--gray-600);
    margin-bottom: var(--space-4);
}

.calculator-result__price {
    margin: var(--space-4) 0;
}

.calculator-result__prefix {
    font-size: var(--font-size-lg);
    color: var(--gray-500);
}

.calculator-result__amount {
    font-size: var(--font-size-4xl);
    font-weight: var(--font-weight-extrabold);
    color: var(--primary);
    display: inline-block;
    margin: 0 var(--space-2);
}

@media (min-width: 641px) {
    .calculator-result__amount {
        font-size: var(--font-size-5xl);
    }
}

.calculator-result__suffix {
    font-size: var(--font-size-lg);
    color: var(--gray-500);
}

.calculator-result__disclaimer {
    font-size: var(--font-size-sm);
    color: var(--gray-500);
    font-style: italic;
    margin-top: var(--space-2);
    padding: var(--space-3);
    background: var(--gray-50);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
}

.calculator-result__savings {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    justify-content: center;
    padding: var(--space-3) var(--space-4);
    background: var(--success-light);
    color: var(--color-success);
    border-radius: var(--radius);
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-sm);
    margin-top: var(--space-4);
}

.calculator-result__summary {
    margin-top: var(--space-6);
    text-align: left;
    font-size: var(--font-size-sm);
    color: var(--gray-600);
    line-height: var(--line-height-relaxed);
}

.calculator-result__actions {
    margin-top: var(--space-8);
    display: flex;
    gap: var(--space-4);
    justify-content: center;
    flex-wrap: wrap;
}

/* ==========  10. NAVIGATION BUTTONS  ========== */
.calculator-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: var(--space-8);
    padding-top: var(--space-6);
    border-top: 1px solid var(--gray-200);
    flex-direction: column-reverse;
    gap: var(--space-3);
}

@media (min-width: 641px) {
    .calculator-nav {
        flex-direction: row;
        gap: 0;
    }
}

.calculator-nav__back {
    background: none;
    border: none;
    color: var(--gray-500);
    font-family: inherit;
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-4);
    border-radius: var(--radius);
    transition: all var(--transition-normal);
    min-height: 48px;
    width: 100%;
    justify-content: center;
}

@media (min-width: 641px) {
    .calculator-nav__back {
        width: auto;
        justify-content: flex-start;
    }
}

.calculator-nav__back:hover {
    color: var(--gray-700);
    background: var(--gray-100);
}

.calculator-nav__back:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring-shadow);
}

.calculator-nav__next {
    min-width: 140px;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: var(--space-2);
    justify-content: center;
    width: 100%;
}

@media (min-width: 641px) {
    .calculator-nav__next {
        width: auto;
    }
}

.calculator-nav__next:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========  11. ANIMATIONS  ========== */
@keyframes calcFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* ==========  12. REDUCED MOTION  ========== */
@media (prefers-reduced-motion: reduce) {
    .calculator-step--active {
        animation: none;
    }

    .calculator-spinner {
        animation-duration: 2s;
    }

    .calculator-progress__fill {
        transition: none;
    }

    .calculator-card,
    .calculator-preset,
    .calculator-floor-btn,
    .calculator-card__check,
    .calculator-progress__dot {
        transition: none;
    }
}

/* ==========  13. RESUME NOTICE (mid-wizard restoration)  ========== */
.calculator-resume-notice {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    margin: 0 0 var(--space-4);
    background: var(--bg-cool, #eef5ff);
    border: 1px solid var(--sky-border-light, rgba(30, 41, 59, 0.15));
    border-radius: var(--radius-lg);
    color: var(--text-body, #475569);
    font-size: var(--font-size-sm);
    animation: calculator-resume-slide 0.3s ease-out;
}

.calculator-resume-notice span {
    flex: 1;
}

.calculator-resume-reset {
    appearance: none;
    background: transparent;
    border: 1px solid var(--primary-light, #1e3a5f);
    color: var(--primary, #1e293b);
    padding: var(--space-1) var(--space-3);
    border-radius: var(--radius);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    transition: background var(--transition-fast), color var(--transition-fast);
}

.calculator-resume-reset:hover,
.calculator-resume-reset:focus-visible {
    background: var(--primary, #1e293b);
    color: #fff;
}

@keyframes calculator-resume-slide {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .calculator-resume-notice { animation: none; }
}

/* ==========================================================================
   PER-SERVICE AREA ROWS  (Step 2)
   Each selected service gets its own slider + number input + presets.
   Generated dynamically by calculator.js — markup is just a container in HTML.
   ========================================================================== */
.calculator-areas {
    display: grid;
    gap: 18px;
    max-width: 720px;
    margin: 0 auto;
}

.calculator-area-row {
    background: #fdf8f3;                         /* warm paper */
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 14px;
    padding: 20px 22px;
}

@media (max-width: 600px) {
    .calculator-area-row { padding: 16px; }
}

.calculator-area-row__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.calculator-area-row__label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: var(--ink-800, #1e293b);
    font-size: 15.5px;
    letter-spacing: -0.01em;
}

.calculator-area-row__label .ic {
    width: 30px;
    height: 30px;
    border-radius: 7px;
    background: rgba(234, 88, 12, 0.12);
    color: var(--cta, #ea580c);
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.calculator-area-row__label .ic svg { width: 16px; height: 16px; }

.calculator-area-row__value {
    display: flex;
    align-items: baseline;
    gap: 6px;
    font-family: var(--font-display, "Inter"), system-ui, sans-serif;
}
.calculator-area-row__value .num {
    font-size: 22px;
    font-weight: 700;
    color: var(--ink-800, #1e293b);
    line-height: 1;
}
.calculator-area-row__value .unit {
    font-size: 13px;
    color: var(--slate-500, #64748b);
    font-weight: 500;
}

.calculator-area-row__hint {
    margin-top: -8px;
    margin-bottom: 12px;
    font-size: 12.5px;
    color: var(--slate-500, #64748b);
    line-height: 1.4;
}

/* Number input + presets row */
.calculator-area-row__controls {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
}
@media (max-width: 600px) {
    .calculator-area-row__controls {
        grid-template-columns: 1fr;
    }
}

.calculator-area-row__slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 5px;
    background: #e5e7eb;
    border-radius: 999px;
    outline: none;
    cursor: pointer;
    margin: 0;
}
.calculator-area-row__slider::-webkit-slider-runnable-track {
    height: 5px;
    border-radius: 999px;
    background: linear-gradient(
        to right,
        var(--cta, #ea580c) 0%,
        var(--cta, #ea580c) var(--range-progress, 22%),
        #e5e7eb var(--range-progress, 22%),
        #e5e7eb 100%
    );
}
.calculator-area-row__slider::-moz-range-track {
    height: 5px;
    border-radius: 999px;
    background: #e5e7eb;
}
.calculator-area-row__slider::-moz-range-progress {
    height: 5px;
    border-radius: 999px;
    background: var(--cta, #ea580c);
}
.calculator-area-row__slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--cta, #ea580c);
    border: 3px solid #fff;
    box-shadow: 0 2px 8px rgba(234, 88, 12, 0.35);
    cursor: grab;
    margin-top: -9px;
    transition: transform .15s ease;
}
.calculator-area-row__slider::-webkit-slider-thumb:hover { transform: scale(1.08); }
.calculator-area-row__slider::-webkit-slider-thumb:active { cursor: grabbing; transform: scale(1.15); }
.calculator-area-row__slider::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--cta, #ea580c);
    border: 3px solid #fff;
    box-shadow: 0 2px 8px rgba(234, 88, 12, 0.35);
    cursor: grab;
}
.calculator-area-row__slider:focus-visible {
    outline: 2px solid var(--cta, #ea580c);
    outline-offset: 4px;
}

/* Inline number input next to slider */
.calculator-area-row__input {
    width: 88px;
    padding: 8px 10px;
    border: 1.5px solid rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    color: var(--ink-800, #1e293b);
    text-align: center;
    background: #fff;
    -moz-appearance: textfield;
}
.calculator-area-row__input::-webkit-outer-spin-button,
.calculator-area-row__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.calculator-area-row__input:focus {
    outline: none;
    border-color: var(--cta, #ea580c);
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.15);
}

/* Quick preset chips below slider */
.calculator-area-row__presets {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 14px;
}
.calculator-area-row__preset {
    padding: 6px 12px;
    background: #fff;
    border: 1.5px solid rgba(15, 23, 42, 0.1);
    border-radius: 999px;
    font-family: inherit;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--slate-700, #334155);
    cursor: pointer;
    transition: all .15s ease;
}
.calculator-area-row__preset:hover {
    border-color: var(--cta, #ea580c);
    color: var(--cta, #ea580c);
}
.calculator-area-row__preset[aria-pressed="true"] {
    background: var(--cta, #ea580c);
    border-color: var(--cta, #ea580c);
    color: #fff;
}

/* Window-tier picker (vindusvask) — 3 columns: small / medium / large */
.calculator-windows-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 12px;
}
@media (max-width: 600px) {
    .calculator-windows-grid {
        grid-template-columns: 1fr;
    }
}
.calculator-window-tier {
    background: #fff;
    border: 1.5px solid rgba(15, 23, 42, 0.1);
    border-radius: 10px;
    padding: 12px 12px 10px;
    transition: border-color .15s ease;
}
.calculator-window-tier:hover {
    border-color: rgba(234, 88, 12, 0.4);
}
.calculator-window-tier__head {
    margin-bottom: 8px;
}
.calculator-window-tier__title {
    font-weight: 600;
    font-size: 14px;
    color: var(--ink-800, #1e293b);
}
.calculator-window-tier__sub {
    font-size: 11.5px;
    color: var(--slate-500, #64748b);
    margin-top: 2px;
    line-height: 1.35;
}
.calculator-window-tier__controls {
    display: grid;
    grid-template-columns: 32px 1fr 32px;
    gap: 6px;
    align-items: stretch;
}
.calculator-window-step {
    height: 36px;
    border: 1.5px solid rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    background: #fff;
    color: var(--ink-800, #1e293b);
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all .12s ease;
    padding: 0;
}
.calculator-window-step:hover {
    border-color: var(--cta, #ea580c);
    color: var(--cta, #ea580c);
}
.calculator-window-step:active {
    transform: scale(0.95);
}
.calculator-window-tier__input {
    height: 36px;
    width: 100%;
    border: 1.5px solid rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    text-align: center;
    font-family: var(--font-display, "Inter"), system-ui, sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: var(--ink-800, #1e293b);
    background: #fff;
    padding: 0;
    -moz-appearance: textfield;
}
.calculator-window-tier__input::-webkit-outer-spin-button,
.calculator-window-tier__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.calculator-window-tier__input:focus {
    outline: none;
    border-color: var(--cta, #ea580c);
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.15);
}

/* Flat-fee variant (takrennerens) */
.calculator-area-row--flat {
    background: rgba(234, 88, 12, 0.06);
    border-color: rgba(234, 88, 12, 0.18);
}
.calculator-area-row--flat .calculator-area-row__flatprice {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-family: var(--font-display, "Inter"), system-ui, sans-serif;
}
.calculator-area-row--flat .calculator-area-row__flatprice .from {
    font-size: 12.5px;
    color: var(--slate-500, #64748b);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
}
.calculator-area-row--flat .calculator-area-row__flatprice .price {
    font-size: 22px;
    font-weight: 700;
    color: var(--ink-800, #1e293b);
}
.calculator-area-row--flat .calculator-area-row__hint {
    margin-top: 6px;
    margin-bottom: 0;
}
