/* ========================================= */
/* GLOBÁLNÍ STYLY                            */
/* ========================================= */
body { background-color: var(--app-bg, #f4f6f9) !important; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; overscroll-behavior-y: contain; }

/* Plovoucí ostrov (PC Navigace) */
.floating-nav-wrapper {
    position: sticky;
    top: 15px;
    z-index: 1040;
    padding: 0 15px;
}
.floating-nav {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 100px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 0.4rem 0.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-pill {
    border-radius: 50px;
    padding: 0.4rem 1rem;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    color: #495057;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    border: 1px solid transparent;
}
.nav-pill:hover { background-color: rgba(0, 0, 0, 0.05); transform: translateY(-1px); color: #212529; }
.nav-pill-primary.active { background-color: #0d6efd; color: white !important; box-shadow: 0 4px 12px rgba(13, 110, 253, 0.3); }
.nav-pill-warning.active { background-color: #ffc107; color: #212529 !important; box-shadow: 0 4px 12px rgba(255, 193, 7, 0.3); }
.nav-pill-success.active { background-color: #198754; color: white !important; box-shadow: 0 4px 12px rgba(25, 135, 84, 0.3); }
.nav-icon-btn {
    width: 34px; height: 34px; 
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #6c757d; background: transparent; transition: all 0.2s; text-decoration: none;
}
.nav-icon-btn:hover { background-color: rgba(0,0,0,0.05); color: #212529; transform: translateY(-1px); }
.card, .collapse > .bg-white, #nav-store, .bg-light.rounded.p-2.border, .bg-white.border.shadow-sm.rounded, form.bg-light { background-color: var(--app-card, #ffffff) !important; }
.compact-card, .letak-card, .letak-compact, .list-group-item, .product-img-wrapper { background-color: var(--app-item, #ffffff) !important; }

.form-control, .form-select { border-radius: 8px; }
.btn { border-radius: 8px; font-weight: 500; }
.badge { border-radius: 6px; font-weight: 600; padding: 5px 8px; }

/* Zákaz označování textu (Mobily) */
body, a, button, .list-group-item { -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; }
input, textarea, select { -webkit-user-select: auto; -moz-user-select: auto; -ms-user-select: auto; user-select: auto; }

/* Skrytí nativního systémového křížku ve vyhledávání */
input[type="search"]::-webkit-search-decoration, input[type="search"]::-webkit-search-cancel-button, input[type="search"]::-webkit-search-results-button, input[type="search"]::-webkit-search-results-decoration { -webkit-appearance: none; display: none; }

/* JISTÍCÍ CSS PRO MOBILNÍ MENU */
#mobilni-menu-spodni { display: none !important; }
@media (max-width: 991.98px) { 
    body { padding-bottom: calc(85px + env(safe-area-inset-bottom)) !important; } 
    #mobilni-menu-spodni { display: flex !important; }
}
.bottom-nav-link { transition: color 0.2s; }
.dropdown-toggle-hide-arrow::after { display: none !important; }

/* ========================================= */
/* HLÍDAČE (Index)                           */
/* ========================================= */
.item-inactive { opacity: 0.6; filter: grayscale(80%); }
#kupiSearchResults { z-index: 9999 !important; max-height: 250px; overflow-y: auto; display: none; top: 100%; box-shadow: 0 10px 25px rgba(0,0,0,0.2) !important; border: 1px solid #ddd; }
#kupiSearchResults a:hover { background-color: #f0f0f0; }
.input-group-text { font-size: 0.85rem; }
.compact-card { font-size: 0.85rem; border: 1px solid #ebedf0; }
.compact-card-title { font-size: 0.95rem; line-height: 1.2; }
.store-header { border-bottom: 3px solid; padding-bottom: 0.5rem; margin-bottom: 1rem; }

/* Kupi Bublinky */
.store-bubble { width: 40px; height: 40px; flex: 0 0 40px; display: block; background-color: white; background-size: cover; background-position: center; transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275); cursor: pointer; box-shadow: 0 2px 5px rgba(0,0,0,0.08); border-radius: 50% !important; }
.store-bubble-check:checked + .store-bubble { border-color: #8b5cf6 !important; box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.25) !important; transform: scale(1.1); z-index: 5; }
.store-bubble-check:not(:checked) + .store-bubble { opacity: 0.5; filter: grayscale(100%); transform: scale(0.9); border-color: #dee2e6 !important; }
.store-bubble:hover { opacity: 1 !important; filter: grayscale(0%) !important; transform: scale(1.05); }

/* ========================================= */
/* LETÁK                                     */
/* ========================================= */
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
.letak-card { border: 1px solid #eaeaea; border-radius: 12px; transition: transform 0.2s, box-shadow 0.2s; background: white; overflow: hidden; display: flex; flex-direction: column; }
.letak-card:hover { transform: translateY(-3px); box-shadow: 0 10px 20px rgba(0,0,0,0.08) !important; }
.product-img-wrapper { height: 160px; padding: 1rem; display: flex; align-items: center; justify-content: center; background-color: #fff; }
.product-img { max-height: 100%; max-width: 100%; object-fit: contain; }
.price-tag { color: #e50000; font-size: 1.8rem; font-weight: 900; line-height: 1; margin: 0; }
.store-logo { height: 35px; width: 35px; object-fit: contain; border-radius: 8px; box-shadow: 0 2px 8px rgba(0,0,0,0.15); background: white; padding: 3px; }
.store-header-logo { height: 30px; width: 30px; object-fit: contain; border-radius: 6px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); background: white; padding: 2px; }
.section-toggle { cursor: pointer; user-select: none; }
.section-toggle:hover h4, .section-toggle:hover h5, .section-toggle:hover .collapse-icon { opacity: 0.7; }
.collapse-icon { transition: transform 0.3s ease; }
.section-toggle.collapsed .collapse-icon { transform: rotate(-180deg); }
.badge-jump { transition: all 0.2s; cursor: pointer; }
.badge-jump:hover { background-color: #e2e6ea !important; transform: translateY(-1px); }
@keyframes pulseHighlight { 0% { transform: scale(1); box-shadow: 0 4px 6px rgba(0,0,0,0.1); } 50% { transform: scale(1.05); box-shadow: 0 0 0 6px rgba(25, 135, 84, 0.4); border-color: #198754; z-index: 10; } 100% { transform: scale(1); box-shadow: 0 4px 6px rgba(0,0,0,0.1); } }
.highlight-target { animation: pulseHighlight 1.2s ease-in-out 2; border: 2px solid #198754 !important; }
.letak-compact { transition: transform 0.2s, box-shadow 0.2s; cursor: pointer; }
.letak-compact:hover { transform: translateY(-2px); box-shadow: 0 6px 15px rgba(0,0,0,0.08) !important; z-index: 1; }

/* ========================================= */
/* SEZNAM NÁKUPU                             */
/* ========================================= */
.list-group-item.bought { background-color: #f1f3f5; color: #adb5bd; text-decoration: line-through; border-color: #e9ecef; }
.list-group-item { transition: all 0.2s; border-radius: 8px !important; margin-bottom: 6px; border: 1px solid #eaeaea; }
.match-badge { font-size: 0.75rem; background-color: white; border: 1px solid #dee2e6; color: #212529; text-decoration: none; transition: transform 0.2s; }
.match-badge:hover { transform: scale(1.05); }
.list-compact-mode .list-group-item { padding-top: 0.25rem !important; padding-bottom: 0.25rem !important; margin-bottom: 3px !important; min-height: 42px; }
.list-compact-mode .match-container { display: none !important; }
.list-compact-mode .item-name-text { font-size: 0.9rem !important; font-weight: 600 !important; }
.list-compact-mode .action-btn { padding: 0rem 0.4rem !important; }
.list-compact-mode .bi-check-lg { font-size: 1.2rem !important; }

/* ========================================= */
/* ADMIN & LOGIN                             */
/* ========================================= */
.table th { font-size: 0.85rem; text-transform: uppercase; color: #6c757d; letter-spacing: 0.5px; border-bottom-width: 1px; }
.table td { vertical-align: middle; border-bottom-color: #f0f0f0; padding: 12px 10px; }
#consoleOutput { font-family: 'Courier New', Courier, monospace; font-size: 0.85rem; color: #00ff00; background-color: #121212; height: 400px; overflow-y: auto; white-space: pre-wrap; border-radius: 0 0 8px 8px; }
.input-group:focus-within { box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25); border-radius: 8px; }
.input-group:focus-within .form-control, .input-group:focus-within .input-group-text { border-color: #86b7fe; }
.form-control:focus { box-shadow: none; }