/* Mobil-only stiller — desktop (≥992px) etkilenmez */

@media (max-width: 991.98px) {
    body {
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }

    main.container {
        padding-left: max(0.75rem, env(safe-area-inset-left));
        padding-right: max(0.75rem, env(safe-area-inset-right));
    }

    .navbar .container {
        padding-left: max(0.75rem, env(safe-area-inset-left));
        padding-right: max(0.75rem, env(safe-area-inset-right));
    }

    .navbar-nav .nav-link {
        padding-top: 0.65rem;
        padding-bottom: 0.65rem;
    }

    .navbar-mobile-user {
        border-top: 1px solid rgba(255, 255, 255, 0.15);
        margin-top: 0.5rem;
        padding-top: 0.75rem;
    }

    .page-header-bar,
    main > .d-flex.justify-content-between.align-items-center.mb-3:not(.flex-wrap) {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.75rem;
    }

    main > .d-flex.justify-content-between.align-items-center.mb-3:not(.flex-wrap) > .btn,
    main > .d-flex.justify-content-between.align-items-center.mb-3:not(.flex-wrap) > a.btn {
        width: 100%;
    }

    .page-header-bar .btn,
    .page-header-bar .d-flex.gap-2 {
        width: 100%;
    }

    .page-header-bar .d-flex.gap-2 {
        flex-direction: column;
    }

    .page-header-bar .d-flex.gap-2 .btn {
        width: 100%;
    }

    .card-body .row.g-2.align-items-end > [class*="col-"],
    .card-body form.row.g-2 > [class*="col-"],
    .card-body form.row.g-2.align-items-end > [class*="col-"] {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .card-body .d-grid,
    .card-body .col-md-auto.d-grid {
        width: 100%;
    }

    .card-body .col-md-2.d-flex.align-items-end {
        flex-direction: column;
        align-items: stretch !important;
    }

    .table-responsive {
        -webkit-overflow-scrolling: touch;
    }

    .table-responsive::after {
        content: "Tabloyu yatay kaydırabilirsiniz →";
        display: block;
        font-size: 0.75rem;
        color: #6c757d;
        margin-top: 0.35rem;
    }

    .table-responsive.table-scroll-hint-off::after {
        display: none;
    }

    .table-responsive .table thead th:first-child,
    .table-responsive .table tbody td:first-child {
        position: sticky;
        left: 0;
        z-index: 2;
        background: #fff;
        box-shadow: 2px 0 4px rgba(0, 0, 0, 0.06);
    }

    .table-responsive .table.table-striped tbody tr:nth-of-type(odd) td:first-child {
        background: #f8f9fa;
    }

    .mobile-list-card {
        border: 1px solid #dee2e6;
        border-radius: 0.5rem;
        padding: 0.85rem;
        margin-bottom: 0.75rem;
        background: #fff;
    }

    .mobile-list-card:last-child {
        margin-bottom: 0;
    }

    .mobile-list-card .mobile-kv {
        display: flex;
        justify-content: space-between;
        gap: 0.5rem;
        padding: 0.2rem 0;
        font-size: 0.9rem;
    }

    .mobile-list-card .mobile-kv .label {
        color: #6c757d;
        flex-shrink: 0;
    }

    .mobile-list-card .mobile-kv .value {
        text-align: right;
        word-break: break-word;
    }

    .mobile-list-card .mobile-actions {
        margin-top: 0.75rem;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .mobile-list-card .mobile-actions .btn {
        width: 100%;
    }

    .mobile-list-card .mobile-actions form {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }

    .mobile-list-card .mobile-actions form .form-control {
        width: 100% !important;
        max-width: none !important;
    }

    .mobile-list-card .mobile-actions form.d-flex {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .item-row .d-flex.justify-content-between.align-items-center.mb-2 {
        flex-direction: column;
        align-items: stretch !important;
        gap: 0.5rem;
    }

    .item-row .d-flex.justify-content-between.align-items-center.mb-2 > .d-flex.gap-2 {
        flex-direction: column;
        width: 100%;
    }

    .item-row .d-flex.justify-content-between.align-items-center.mb-2 .btn {
        width: 100%;
    }

    #work-order-form .card-header.d-flex {
        flex-direction: column;
        align-items: stretch !important;
        gap: 0.5rem;
    }

    #work-order-form .card-header .btn {
        width: 100%;
    }

    .app-mobile-modal-panel {
        width: calc(100% - 1.5rem) !important;
        max-width: 420px !important;
        margin: 6vh auto 0 auto !important;
        max-height: 85vh;
        overflow-y: auto;
    }

    .finishing-list-desktop .text-end .d-flex.flex-column {
        align-items: stretch !important;
    }

    .finishing-list-desktop .text-end form.d-flex {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .finishing-list-desktop .text-end form .form-control {
        width: 100% !important;
    }

    .finishing-list-desktop .text-end .btn {
        width: 100%;
    }

    .row.justify-content-center > .col-12.col-md-4 {
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }

    main .card .row.g-2 > [class*="col-xl-"],
    main .card .row.g-2 > [class*="col-md-"],
    main .card .row.g-2 > [class*="col-sm-"] {
        flex: 0 0 100%;
        max-width: 100%;
    }

    main .table .btn-group {
        display: flex;
        flex-direction: column;
        width: 100%;
    }

    main .table .btn-group .btn {
        width: 100%;
        border-radius: var(--bs-btn-border-radius) !important;
        margin-left: 0 !important;
    }
}
