.license-type { display: block; margin-top: 4px; color: #526171; font-size: 12px; overflow-wrap: anywhere; }
@media (min-width: 1101px) and (hover: hover), (min-width: 1101px) and (pointer: fine) {
    .program-license { white-space: normal; }
    /* Full type names use compact text without affecting the column width. */
    .program-license .license-type {
        display: block;
        margin-top: 4px;
        font-size: 9px;
        line-height: 1.3;
        white-space: nowrap;
        overflow-wrap: normal;
        contain: inline-size;
    }
}
.mobile-sort, .card-controls { display: none; }
tr.recent-license, tr.recent-license > td { background-color: #fff2bd !important; }
tr.recent-license { outline: 2px solid #c79524; outline-offset: -2px; }
.filter-note { color: #526171; font-size: 14px; line-height: 1.5; margin: 8px 0; }
.nav-more { display: none; }
.nav-more > summary { display: none; }
/* JavaScript opens disclosures on desktop. Keep this query in sync with it. */
.other-actions > summary { display: none; }
@media (max-width: 1100px), (hover: none) and (pointer: coarse) {
    *, *::before, *::after { box-sizing: border-box; }
    body { padding: 8px; }
    body .container { padding: 16px 12px; min-width: 0; }
    h1 { font-size: 24px; overflow-wrap: anywhere; }
    h2 { font-size: 20px; }
    input, select, textarea, button { font: inherit; font-size: 16px !important; max-width: 100%; }
    input:not([type="hidden"]), select, button, summary { min-height: 44px; }
    button, summary { cursor: pointer; }
    a, td, span { overflow-wrap: anywhere; }
    .nav-menu { display: flex; flex-wrap: wrap; align-items: start; text-align: left; }
    .nav-menu > a { margin: 0; padding: 12px; }
    .nav-menu .nav-more { display: block; flex: 1; min-width: 70px; }
    .nav-more > summary { display: block; padding: 12px; color: #2c3e50; }
    .nav-more[open] > a { display: block; float: none; margin: 0; }
    .nav-menu .logout-link { float: none; margin: 0; }
    .container > div:has(> form[method="get"]),
    form[method="get"], form[method="get"] > div { display: flex !important; flex-wrap: wrap; gap: 10px; width: 100%; margin-right: 0 !important; }
    form[method="get"] input[type="text"] { width: 100% !important; }
    form[method="get"] select { flex: 1; min-width: 120px; }
    form[method="get"] a { padding: 12px 4px; margin: 0 !important; }
    #syncButton { margin-top: 10px; }
    .mobile-sort { display: grid; gap: 6px; margin-top: 16px; font-size: 14px; }
    .mobile-sort select { width: 100%; }
    .mobile-cards, .mobile-cards tbody { display: block; width: 100%; }
    .mobile-cards thead { display: none; }
    .mobile-cards tbody > tr { display: flex; flex-direction: column; background: #fff; border: 1px solid #dce3ea; border-radius: 10px; margin: 12px 0; padding: 10px; }
    .mobile-cards td { display: block; border: 0; padding: 7px 2px; width: 100%; font-size: 15px; overflow-wrap: anywhere; }
    .mobile-cards td[data-label]::before { content: attr(data-label); display: block; font-size: 12px; color: #637282; margin-bottom: 3px; }
    .mobile-cards td.card-title { order: -1; font-size: 18px; font-weight: 600; }
    .mobile-cards td.card-secondary { display: none; }
    .mobile-cards .card-expanded td.card-secondary { display: block; }
    .mobile-cards td.card-controls { display: block; }
    .card-controls button { width: 100%; border: 1px solid #cbd5df; background: #f5f8fb; border-radius: 6px; color: #24425e; }
    .mobile-cards .action-button { width: 100%; padding: 12px; margin: 5px 0; }
    .other-actions { margin-top: 8px; }
    .other-actions > summary {
        display: list-item; width: 100%; min-height: 48px; padding: 14px 16px;
        border: 1px solid #bac9d8; border-radius: 6px; background: #edf3f8;
        color: #24425e; font-size: 16px; font-weight: 600; line-height: 20px;
        list-style-position: inside; cursor: pointer;
    }
    .other-actions > summary:focus-visible { outline: 3px solid #2877b8; outline-offset: 2px; }
    .other-actions[open] > summary { margin-bottom: 8px; }
    .pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
    .pagination a, .pagination strong { margin: 0; min-height: 44px; }
    body .forma-grid { grid-template-columns: 1fr; }
    body .detalji-sekcija { padding: 12px; }
    .detalji-sekcija > div:has(> h3) { flex-wrap: wrap; gap: 12px; }
    .detalji-sekcija form { max-width: 100%; flex-wrap: wrap; }
    .forma-dodaj-kontakt { flex-direction: column; }
    .kontakti-lista li { gap: 10px; flex-wrap: wrap; }
    .kontakti-lista span { min-width: 0; }
    body .modal-overlay { padding: 12px; overflow-y: auto; }
    body .modal-content { width: 100%; max-width: 440px; max-height: calc(100dvh - 24px); overflow-y: auto; padding: 20px; }
    body.login-body { height: auto; min-height: 100dvh; padding: 16px; }
    body .login-wrapper { width: 100%; max-width: 360px; padding: 24px; }
    .status-label, .status-badge { font-size: 14px; }
}

/* Intrinsic containment keeps long notes from widening desktop columns. */
.license-action-note { contain:inline-size; max-width:220px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; font:11px/1.4 sans-serif; color:#667784; margin-top:2px; }
@media (max-width:1100px), (hover:none) and (pointer:coarse) {
    tr.card-expanded .license-action-note { contain:none; max-width:100%; white-space:pre-wrap; overflow-wrap:anywhere; }
}
