.funeral-calculator-apple {
    max-width: 1400px;
    margin: 40px auto;
    background: #f8f9fa;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.calc-section {
    background: white;
    padding: 30px;
    border-bottom: 1px solid #eee;
}

.calc-section:last-child { border-bottom: none; }

.calc-section h3 {
    margin: 0 0 24px 0;
    font-size: 24px;
    font-weight: 600;
    color: #0d4ea4;
}

.calc-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid #eee;
}

.calc-item:last-child { border-bottom: none; }

.calc-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    flex: 1;
}

.calc-checkbox input {
    opacity: 0;
    position: absolute;
}

.checkmark {
    width: 28px;
    height: 28px;
    border: 2px solid #d2d2d7;
    border-radius: 50%;
    margin-right: 16px;
    position: relative;
    transition: all 0.3s;
}

.calc-checkbox input:checked ~ .checkmark {
    background: #007aff;
    border-color: #007aff;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
    left: 9px;
    top: 5px;
    width: 6px;
    height: 12px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.calc-checkbox input:checked ~ .checkmark:after { display: block; }

.item-info {
    flex: 1;
}

.item-name {
    font-size: 17px;
    color: #1d1d1f;
    margin-bottom: 4px;
}

.item-price {
    font-size: 15px;
    color: #86868b;
}

.quantity-control {
    display: flex;
    align-items: center;
    background: #f2f2f7;
    border-radius: 14px;
    padding: 10px;
    padding-top: 5px;
    min-width: 140px;
    justify-content: space-between;
}

.qty-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #007aff;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover { background: #e5e5ea; }

.qty-input {
    width: 50px;
    text-align: center;
    border: none;
    background: transparent;
    font-size: 17px;
    font-weight: 600;
}

.unit-label {
    font-size: 15px;
    color: #86868b;
    margin-left: 8px;
    min-width: 80px;
    text-align: right;
}

.calc-total {
    background: linear-gradient(to bottom, #f8f9fa, #e5e5ea);
    padding: 30px;
    text-align: center;
    font-size: 32px;
    font-weight: 700;
    color: #1d1d1f;
}

.total-label {
    font-size: 18px;
    color: #86868b;
    margin-bottom: 8px;
}

.total-amount span {
    font-size: 24px;
    margin-left: 8px;
}

input.qty-input {
    margin-top: 7% !important;
}


/* Мобильные телефоны (до 600px) */
@media (max-width: 600px) {
    .funeral-calculator-apple {
        margin: 10px 5px;
        border-radius: 16px;
    }
    
    .calc-section {
        padding: 20px 16px;
    }
    
    .calc-section h3 {
        font-size: 20px;
        text-align: center;
    }
    
    .calc-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 20px 0;
        gap: 16px;
    }
    
    .calc-checkbox {
        min-width: auto;
        width: 100%;
    }
    
    .quantity-control {
        align-self: flex-end;
        min-width: 180px;
    }
    
    .item-name {
        font-size: 14px;
        padding-right: 40px; /* место под чекбокс */
    }
    
    .item-price {
        font-size: 12px;
    }
    
    .calc-total {
        font-size: 28px;
        padding: 30px 16px;
    }
    
    .total-amount span {
        font-size: 24px;
    }
    input.qty-input {
    width: 60px !important;
}
}

/* Очень маленькие экраны (до 380px) */
@media (max-width: 380px) {
    .quantity-control {
        min-width: 160px;
        padding: 6px 10px;
    }
    
    .qty-btn {
        width: 36px;
        height: 36px;
        font-size: 22px;
    }
    
    .qty-input {
        font-size: 17px;
        width: 44px;
    }
    input.qty-input {
    width: 40px !important;
}
}