/* Shared checkbox, radio and switch geometry.
 * The control keeps its visual size; the surrounding label/card owns the
 * comfortable touch target.  This layer is loaded after page styles so old
 * Bootstrap/mobile overrides cannot stretch the input itself.
 */

.form-check,
.finance-inline-check,
.remember-box,
.personel-idle-other-remember,
.adasi-bulk-sms {
    min-width: 0;
}

.form-check > .form-check-input:not([role="switch"]),
.form-check-input[type="checkbox"]:not([role="switch"]),
.form-check-input[type="radio"],
input[type="checkbox"]:not([role="switch"]),
input[type="radio"],
.finance-inline-check > input[type="checkbox"],
.remember-box > input[type="checkbox"],
.personel-idle-other-remember > input[type="checkbox"],
.adasi-bulk-sms > input[type="checkbox"],
td > .form-check-input:not([role="switch"]) {
    box-sizing: border-box;
    flex: 0 0 20px;
    width: 20px !important;
    min-width: 20px !important;
    max-width: 20px !important;
    height: 20px !important;
    min-height: 20px !important;
    max-height: 20px !important;
    margin: 0 !important;
    flex-shrink: 0;
    border-radius: 5px;
}

.form-check > .form-check-input[type="radio"],
input[type="radio"].form-check-input,
input[type="radio"] {
    border-radius: 50%;
}

.form-check.form-switch,
.switch-row,
.form-check-input[role="switch"] {
    min-height: 44px;
}

.form-check.form-switch > .form-check-input,
.form-check-input[type="checkbox"][role="switch"],
input[type="checkbox"][role="switch"],
.form-check-input[role="switch"],
input[type="checkbox"].form-switch,
.switch-row > .form-check-input {
    box-sizing: border-box;
    flex: 0 0 44px;
    width: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
    height: 26px !important;
    min-height: 26px !important;
    max-height: 26px !important;
    margin: 0 !important;
    flex-shrink: 0;
    border-radius: 999px !important;
}

.form-check:not(.form-switch),
.finance-inline-check,
.remember-box,
.personel-idle-other-remember,
.adasi-bulk-sms {
    min-height: 44px;
}

.form-check:not(.form-switch) > .form-check-label,
.finance-inline-check > span,
.remember-box > label,
.personel-idle-other-remember > span,
.adasi-bulk-sms > label {
    min-width: 0;
    line-height: 1.35;
}

/* Custom card controls use the whole label as the touch target. */
.option-box,
.ui-style-card,
.brand-color-option,
.adasi-bulk-choice,
.choice-card,
.tenant-create-plan-option,
.md-package-pay-option,
.hatirlatma-option,
.option-box,
.bulk-sms-switch,
.passive-candidate-check,
.inline-ucret-plan > label,
.kra-day,
.kra-branch,
.kra-admin,
.new-perm-item,
.perm-item,
.md-branch-check,
.md-branch-primary {
    min-width: 0;
    min-height: 44px !important;
}

.option-box {
    height: auto !important;
}

.bulk-sms-switch,
.passive-candidate-check,
.inline-ucret-plan > label,
.kra-day,
.kra-branch,
.kra-admin {
    box-sizing: border-box;
    align-items: center;
}

.bulk-sms-switch,
.passive-candidate-check,
.inline-ucret-plan > label,
.kra-day,
.kra-branch,
.kra-admin,
.new-perm-item {
    overflow-wrap: anywhere;
}

.new-perm-item {
    align-items: center;
}

.md-branch-control {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    flex: 0 0 20px !important;
    border-radius: 5px !important;
}

.md-branch-radio {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    flex: 0 0 20px !important;
    border-radius: 50% !important;
    box-shadow: inset 0 0 0 4px #fff !important;
}

.choice-card span:before {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    flex: 0 0 20px !important;
    border-radius: 50% !important;
    box-shadow: inset 0 0 0 5px #fff !important;
}

.choice-card input:checked + span:before {
    background: var(--app-primary, #f59e0b) !important;
}

@media (max-width: 991.98px) {
    .form-check,
    .finance-inline-check,
    .remember-box,
    .personel-idle-other-remember,
    .adasi-bulk-sms {
        gap: 10px;
    }

    .form-check > .form-check-input:not([role="switch"]),
    .form-check-input[type="checkbox"]:not([role="switch"]),
    .form-check-input[type="radio"],
    input[type="checkbox"]:not([role="switch"]),
    input[type="radio"],
    .finance-inline-check > input[type="checkbox"],
    .remember-box > input[type="checkbox"],
    .personel-idle-other-remember > input[type="checkbox"],
    .adasi-bulk-sms > input[type="checkbox"],
    td > .form-check-input:not([role="switch"]) {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .form-check.form-switch > .form-check-input,
    .form-check-input[type="checkbox"][role="switch"],
    input[type="checkbox"][role="switch"],
    input[type="checkbox"].form-switch,
    .form-check-input[role="switch"],
    .switch-row > .form-check-input {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .form-check-label,
    .finance-inline-check,
    .remember-box > label,
    .personel-idle-other-remember,
    .adasi-bulk-sms > label {
        overflow-wrap: anywhere;
    }
}

/* Kasa, satış ve müşteri formlarında aynı kapalı gün kartı. */
html body details.kasa-closed-day-reason-card {
    padding: 10px 12px;
    border: 1px solid var(--bs-warning-border-subtle, #ffe69c);
    border-left: 3px solid var(--bs-warning, #ffc107);
    border-radius: 12px;
    background: var(--bs-warning-bg-subtle, #fff3cd);
    box-shadow: 0 3px 10px rgba(146, 105, 20, .06);
}

html body #app-content details.kasa-closed-day-reason-card > summary.small.text-muted {
    color: #475569 !important;
    font-size: .875rem !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
    cursor: pointer;
}

html body details.kasa-closed-day-reason-card[hidden] { display: none !important; }

html body #app-content details.kasa-closed-day-reason-card > label.form-label {
    display: block !important;
    width: 100% !important;
    color: #0f172a !important;
    font-size: .75rem !important;
    font-weight: 600 !important;
    margin: 0 0 7px !important;
    letter-spacing: .01em !important;
    line-height: 1.25 !important;
    text-transform: none !important;
}

html body #app-content details.kasa-closed-day-reason-card .form-control[name="kapali_gun_gerekce"] {
    color: #172033 !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 10px !important;
    min-height: 44px !important;
    padding: 10px 12px !important;
    font-size: .85rem !important;
    font-weight: 400 !important;
}

html body #app-content details.kasa-closed-day-reason-card .form-text {
    font-size: .875rem !important;
    line-height: 1.5 !important;
}

@media (max-width: 575.98px) {
    .option-box,
    .ui-style-card,
    .brand-color-option,
    .adasi-bulk-choice,
    .choice-card,
    .tenant-create-plan-option,
    .md-package-pay-option,
    .hatirlatma-option,
    .md-branch-check,
    .md-branch-primary {
        min-height: 44px;
    }
}
