/* ==========================================================================
   ZÁRUČÁK - APPLE iOS DESIGN SYSTEM
   ========================================================================== */

:root {
  --font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  --bg-color: #F8F9FB;
  --card-bg: #FFFFFF;
  --text-main: #1C1C1E;
  --text-secondary: #8E8E93;
  --text-tertiary: #C7C7CC;
  --apple-blue: #007AFF;
  --apple-blue-light: #EBF5FF;
  --apple-blue-border: #C8E3FE;
  --apple-green: #34C759;
  --apple-green-light: #EEFAF1;
  --apple-green-border: #C5EED0;
  --apple-yellow: #FF9500;
  --apple-yellow-light: #FFF7EC;
  --apple-yellow-border: #FEDBA9;
  --apple-purple: #AF52DE;
  --apple-purple-light: #F8EEFC;
  --apple-purple-border: #E8D0F8;
  --apple-cyan: #32ADE6;
  --apple-cyan-light: #E9F6FD;
  --apple-cyan-border: #BAE5FA;
  --apple-coral: #FF3B30;
  --apple-coral-light: #FEF0EF;
  --apple-coral-border: #FDC7C4;
  --timeline-line: #E2E4EB;
  --border-subtle: #E5E5EA;
  --safe-bottom: env(safe-area-inset-bottom, 20px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
  background-color: #E5E5EA;
  display: flex;
  justify-content: center;
}

body {
  font-family: var(--font-family);
  color: var(--text-main);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  user-select: none;
  overflow-x: hidden;
  scrollbar-width: none;
}

body::-webkit-scrollbar {
  display: none;
}

.app-container {
  width: 100%;
  max-width: 420px;
  min-height: 100vh;
  background-color: #FFFFFF;
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 35px rgba(0, 0, 0, 0.1);
  overflow-x: hidden;
  scrollbar-width: none;
}

.app-container::-webkit-scrollbar {
  display: none;
}

/* ==========================================================================
   HEADER
   ========================================================================== */

.app-header {
  padding: 16px 20px 10px 20px;
  background-color: #FFFFFF;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.header-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.header-title {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.6px;
  color: #000000;
}

.icon-btn {
  background: none;
  border: none;
  color: var(--apple-blue);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.15s;
}

.icon-btn:active {
  opacity: 0.6;
}

/* Search bar */
.search-icon {
  display: flex;
  align-items: center;
  color: #8E8E93;
  margin-right: 8px;
}.btn-clear {
  background: #C7C7CC;
  border: none;
  color: #FFFFFF;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Filter Chips */
.filter-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: none;
}

.filter-chips::-webkit-scrollbar {
  display: none;
}

.chip {
  padding: 7px 15px;
  border-radius: 20px;
  border: 1px solid #E5E5EA;
  background-color: #FFFFFF;
  color: #3C3C43;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
}

.chip.active {
  background-color: #1C1C1E;
  color: #FFFFFF;
  border-color: #1C1C1E;
}

/* ==========================================================================
   TIMELINE VIEW (MATCHING MOCKUP)
   ========================================================================== */

.timeline-container {
  flex: 1;
  padding: 12px 14px 100px 14px;
  position: relative;
  background-color: #F8F9FA;
}

.timeline-rail {
  display: none !important;
}

.timeline-items {
  position: relative;
  z-index: 2;
  width: 100%;
}

/* ==========================================================================
   APPLE REMINDERS LIST STYLE (VARIANTA 2)
   ========================================================================== */
.reminders-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid #EFEFF4;
  cursor: pointer;
  transition: background-color 0.12s ease;
  user-select: none;
}

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

.reminders-item:hover {
  background-color: #F9F9FB;
}

.reminders-item.selected-desktop,
.reminders-item.active {
  background-color: #EBF3FF;
}/* Year Marker */
.timeline-year-marker {
  display: flex;
  align-items: center;
  margin: 12px 0 4px 0;
  position: relative;
}
/* Today "DNES" marker */
.timeline-today-marker {
  display: flex;
  align-items: center;
  position: relative;
  margin: 8px 0;
  height: 38px;
}

.today-dot {
  position: absolute;
  left: 35px;
  width: 12px;
  height: 12px;
  background-color: var(--apple-blue);
  border-radius: 50%;
  border: 2px solid #FFFFFF;
  box-shadow: 0 0 0 2px var(--apple-blue);
  z-index: 4;
}

.today-flag {
  background-color: var(--apple-blue);
  color: #FFFFFF;
  padding: 5px 12px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
  margin-left: 56px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  line-height: 1.2;
  box-shadow: 0 3px 8px rgba(0, 122, 255, 0.35);
  position: relative;
}

.today-flag span:first-child {
  letter-spacing: 0.5px;
  background: rgba(255, 255, 255, 0.2);
  padding: 2px 5px;
  border-radius: 4px;
}

.today-flag span:last-child {
  font-size: 11px;
  font-weight: 600;
  opacity: 0.95;
}

/* Timeline Card */
.timeline-card-wrapper {
  display: flex;
  align-items: center;
  position: relative;
  width: 100%;
}

.timeline-connector-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #FFFFFF;
  border: 2px solid #B0B5C1;
  position: absolute;
  left: 36px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
}

.timeline-card {
  margin-left: 54px;
  flex: 1;
  min-width: 0;
  border-radius: 20px;
  padding: 14px 16px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.timeline-card:active {
  transform: scale(0.985);
}

.timeline-card.selected-desktop {
  outline: 2.5px solid var(--apple-blue);
  box-shadow: 0 4px 16px rgba(0, 122, 255, 0.25);
}

/* Pastel theme variations matching mockup */
.timeline-card.theme-blue {
  background-color: var(--apple-blue-light);
  border-color: var(--apple-blue-border);
}
.timeline-card.theme-blue .progress-fill {
  background-color: var(--apple-blue);
}

.timeline-card.theme-green {
  background-color: var(--apple-green-light);
  border-color: var(--apple-green-border);
}
.timeline-card.theme-green .progress-fill {
  background-color: var(--apple-green);
}

.timeline-card.theme-yellow {
  background-color: var(--apple-yellow-light);
  border-color: var(--apple-yellow-border);
}
.timeline-card.theme-yellow .progress-fill {
  background-color: var(--apple-yellow);
}

.timeline-card.theme-purple {
  background-color: var(--apple-purple-light);
  border-color: var(--apple-purple-border);
}
.timeline-card.theme-purple .progress-fill {
  background-color: var(--apple-purple);
}

.timeline-card.theme-cyan {
  background-color: var(--apple-cyan-light);
  border-color: var(--apple-cyan-border);
}
.timeline-card.theme-cyan .progress-fill {
  background-color: var(--apple-cyan);
}

.timeline-card.theme-coral {
  background-color: var(--apple-coral-light);
  border-color: var(--apple-coral-border);
}
.timeline-card.theme-coral .progress-fill {
  background-color: var(--apple-coral);
}

/* Card Header *//* Progress bar inside card */
.progress-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s ease;
}

/* Card Footer *//* Floating Alerts / Tags above cards *//* ==========================================================================
   FLOATING ACTION BUTTON (+)
   ========================================================================== */

.fab-btn {
  position: fixed;
  bottom: calc(75px + var(--safe-bottom));
  left: 50%;
  transform: translateX(130px);
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background-color: var(--apple-blue);
  border: none;
  box-shadow: 0 6px 18px rgba(0, 122, 255, 0.4);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 90;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s;
}

.fab-btn:active {
  transform: translateX(130px) scale(0.92);
  box-shadow: 0 3px 10px rgba(0, 122, 255, 0.3);
}

/* ==========================================================================
   BOTTOM NAVIGATION (APPLE STYLE)
   ========================================================================== */

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 420px;
  height: calc(56px + var(--safe-bottom));
  padding-bottom: var(--safe-bottom);
  background-color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 80;
}

.nav-item {
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: #8E8E93;
  cursor: pointer;
  padding: 4px 12px;
  transition: color 0.15s;
}

.nav-item span {
  font-size: 10px;
  font-weight: 600;
}

.nav-item.active {
  color: var(--apple-blue);
}

/* ==========================================================================
   MODALS & DIALOGS
   ========================================================================== */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-card {
  background-color: #FFFFFF;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  border-radius: 28px 28px 0 0;
  padding: 24px 20px calc(24px + var(--safe-bottom)) 20px;
  overflow-y: auto;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.15);
  animation: slideUp 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.modal-header h2 {
  font-size: 22px;
  font-weight: 700;
  color: #111827;
}

.btn-close-modal {
  background-color: #EFEFF4;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  font-weight: bold;
  color: #6B7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Form controls */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background-color: #F3F4F6;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 15px;
  font-family: inherit;
  color: #111827;
  outline: none;
  transition: border-color 0.15s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--apple-blue);
  background-color: #FFFFFF;
}

.form-row {
  display: flex;
  gap: 12px;
}

.form-row .form-group {
  flex: 1;
}

/* Duration Presets */
.duration-presets {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.preset-btn {
  flex: 1;
  padding: 10px 4px;
  background-color: #F3F4F6;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #4B5563;
  cursor: pointer;
  transition: all 0.15s;
}

.preset-btn.active {
  background-color: var(--apple-blue);
  border-color: var(--apple-blue);
  color: #FFFFFF;
}

/* Photo Picker */
.photo-picker-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-picker {
  background-color: #F3F4F6;
  border: 1.5px dashed #C7C7CC;
  border-radius: 12px;
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--apple-blue);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.receipt-preview-box {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  max-height: 180px;
  border: 1px solid #E5E7EB;
}

.receipt-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.btn-remove-photo {
  position: absolute;
  top: 8px;
  right: 8px;
  background-color: rgba(0, 0, 0, 0.65);
  color: #FFFFFF;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 14px;
  cursor: pointer;
}

/* Modal Actions */
.modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.btn-cancel {
  flex: 1;
  padding: 14px;
  background-color: #EFEFF4;
  border: none;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 600;
  color: #4B5563;
  cursor: pointer;
}

.btn-save {
  flex: 2;
  padding: 14px;
  background-color: var(--apple-blue);
  border: none;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  color: #FFFFFF;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

/* ==========================================================================
   DETAIL MODAL & SHARING
   ========================================================================== */

.detail-card {
  padding-top: 20px;
}

.detail-category-badge {
  background-color: #F2F2F7;
  padding: 5px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  color: #4B5563;
}

.detail-hero {
  margin-bottom: 20px;
}

.detail-hero h2 {
  font-size: 24px;
  font-weight: 800;
  color: #111827;
}

.detail-subtitle {
  font-size: 15px;
  color: #6B7280;
  margin-top: 3px;
}

/* Countdown Widget */.info-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.info-row strong {
  color: #111827;
}

/* Detail progress */
.detail-progress-wrapper {
  margin-bottom: 18px;
}

.detail-progress-bar {
  height: 8px;
  background-color: #E5E7EB;
  border-radius: 6px;
  overflow: hidden;
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #8E8E93;
  margin-top: 4px;
  font-weight: 500;
}

/* Detail blocks */
.detail-info-block {
  background-color: #F9FAFB;
  border: 1px solid #F3F4F6;
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.detail-info-block label {
  font-size: 11.5px;
  font-weight: 700;
  color: #6B7280;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  display: block;
  margin-bottom: 4px;
}

.serial-copy-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  font-weight: 600;
  color: #111827;
}

.btn-small-action {
  background-color: #EBF5FF;
  color: var(--apple-blue);
  border: none;
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

/* Scanned receipt in detail */
.detail-receipt-section {
  margin-bottom: 18px;
}

.detail-receipt-section label {
  font-size: 12px;
  font-weight: 700;
  color: #4B5563;
  margin-bottom: 8px;
  display: block;
}

.receipt-zoom-container {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  max-height: 220px;
  border: 1.5px dashed #CBD5E1;
  cursor: pointer;
  background-color: #F8FAFC;
}

.receipt-zoom-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.receipt-overlay-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background-color: rgba(17, 24, 39, 0.75);
  color: #FFFFFF;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 600;
  backdrop-filter: blur(4px);
}

.no-receipt-box {
  background-color: #F9FAFB;
  border: 1px dashed #D1D5DB;
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  font-size: 13px;
  color: #6B7280;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* Claim Box */
.claim-box {
  background-color: #FEF3C7;
  border: 1px solid #FDE68A;
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 20px;
}

.claim-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.claim-header span {
  font-size: 13px;
  font-weight: 700;
  color: #92400E;
}

.btn-claim-toggle {
  background-color: #D97706;
  color: #FFFFFF;
  border: none;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.claim-content {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #FCD34D;
  font-size: 12.5px;
  color: #78350F;
}

.claim-warning {
  margin-top: 6px;
  font-weight: 700;
  color: #B45309;
}

/* Detail Footer Actions */
.detail-footer-actions {
  display: flex;
  gap: 10px;
}

.btn-action-primary {
  flex: 2;
  background-color: var(--apple-blue);
  color: #FFFFFF;
  border: none;
  padding: 14px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.btn-action-secondary {
  flex: 1;
  background-color: #EFEFF4;
  color: #111827;
  border: none;
  padding: 14px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.btn-action-danger {
  background-color: #FEE2E2;
  color: #DC2626;
  border: none;
  padding: 14px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

/* ==========================================================================
   ZOOM OVERLAY
   ========================================================================== */

.modal-overlay-zoom {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.95);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.btn-close-zoom {
  position: absolute;
  top: 30px;
  right: 20px;
  background: rgba(255, 255, 255, 0.2);
  color: #FFFFFF;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
}

.zoom-content img {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 8px;
}

/* Toast */
.toast-message {
  position: fixed;
  bottom: calc(75px + var(--safe-bottom));
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(28, 28, 30, 0.92);
  color: #FFFFFF;
  padding: 10px 20px;
  border-radius: 20px;
  font-size: 13.5px;
  font-weight: 600;
  z-index: 250;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  animation: fadeInOut 2.5s forwards;
}

@keyframes fadeInOut {
  0% { opacity: 0; transform: translate(-50%, 10px); }
  15% { opacity: 1; transform: translate(-50%, 0); }
  80% { opacity: 1; transform: translate(-50%, 0); }
  100% { opacity: 0; transform: translate(-50%, -10px); }
}

/* ==========================================================================
   DESKTOP & TABLET RESPONSIVE STYLES (macOS SPLIT VIEW)
   ========================================================================== */

/* Default Mobile States */
.desktop-top-toolbar {
  display: none;
}

.desktop-sidebar {
  display: none;
}

.desktop-detail-pane {
  display: none;
}

.workspace-body {
  width: 100%;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  position: relative;
}

.desktop-center-column {
  width: 100%;
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* Desktop Media Query (Koncept 1: Apple 2-Column Interface) */
@media (min-width: 900px) {
  html, body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    background: #FFFFFF;
    display: block;
  }

  .app-container {
    max-width: 100% !important;
    width: 100vw !important;
    height: 100vh !important;
    min-height: 0 !important;
    margin: 0 !important;
    border-radius: 0 !important;
    flex-direction: column !important;
    box-shadow: none !important;
    border: none !important;
    overflow: hidden !important;
  }

  /* 1. Desktop Top Toolbar */
  .desktop-top-toolbar {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    height: 52px;
    min-height: 52px;
    background: #FFFFFF;
    border-bottom: 1px solid #E5E7EB;
    padding: 0 16px;
    box-sizing: border-box;
    z-index: 100;
    user-select: none;
    overflow-x: auto;
    scrollbar-width: none;
    white-space: nowrap;
  }

  .desktop-top-toolbar::-webkit-scrollbar {
    display: none;
  }

  .desktop-toolbar-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .desktop-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    white-space: nowrap;
  }  .desktop-filter-pills {
    display: flex;
    gap: 4px;
    background: #F2F2F7;
    padding: 3px;
    border-radius: 10px;
    margin-left: 6px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .filter-pill {
    border: none;
    background: transparent;
    padding: 5px 10px;
    border-radius: 7px;
    font-size: 12px;
    font-weight: 600;
    color: #636366;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.15s ease;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .filter-pill span {
    white-space: nowrap;
  }

  .filter-pill:hover {
    color: #111827;
  }

  .filter-pill.active {
    background: #FFFFFF;
    color: #111827;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  }

  .filter-pill-badge {
    font-size: 10.5px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 8px;
    background: #E5E7EB;
    color: #4B5563;
    white-space: nowrap;
  }
  .filter-pill-badge.warning {
    background: #FEF3C7;
    color: #D97706;
  }

  .filter-pill-badge.danger {
    background: #FEE2E2;
    color: #DC2626;
  }

  .desktop-toolbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .desktop-stat-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    background: #F2F2F7;
    padding: 5px 10px;
    border-radius: 8px;
    color: #374151;
    white-space: nowrap;
    flex-shrink: 0;
  }
  .btn-toolbar-secondary {
    background: #F2F2F7;
    color: #374151;
    border: 1px solid #E5E5EA;
    padding: 6px 11px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.15s ease;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .btn-toolbar-secondary span {
    white-space: nowrap;
  }

  .btn-toolbar-secondary:hover {
    background: #E5E5EA;
    color: #111827;
  }

  .btn-toolbar-danger {
    color: #DC2626;
  }

  .btn-toolbar-danger:hover {
    background: #FEE2E2;
    color: #B91C1C;
    border-color: #FECACA;
  }

  .btn-toolbar-primary {
    background: var(--apple-blue);
    color: #FFFFFF;
    border: none;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 6px rgba(0, 122, 255, 0.35);
    transition: all 0.15s ease;
  }

  .btn-toolbar-primary:hover {
    background: #0062CC;
  }

  .icon-btn-round {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #F2F2F7;
    border: none;
    color: #4B5563;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease;
  }

  .icon-btn-round:hover {
    background: #E5E5EA;
    color: #111827;
  }

  /* 2. Workspace Body (2 Columns Split) */
  .workspace-body {
    flex-direction: row !important;
    height: calc(100vh - 52px) !important;
    width: 100vw !important;
    overflow: hidden !important;
  }

  /* 3. Left List Column (420px) */
  .desktop-center-column {
    flex: none !important;
    width: 420px !important;
    min-width: 420px !important;
    max-width: 420px !important;
    flex-shrink: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
    border-right: 1px solid #E5E7EB !important;
    background-color: #F8F9FA !important;
    overflow: hidden !important;
  }

  .desktop-center-column .app-header {
    padding: 10px 14px 10px 14px !important;
    background-color: #F8F9FA !important;
    border-bottom: 1px solid #E5E7EB !important;
    position: relative !important;
  }

  .desktop-center-column .header-top-row {
    display: none !important;
  }

  .desktop-center-column .filter-chips {
    display: none !important;
  }
  .desktop-center-column .timeline-container {
    flex: 1 !important;
    overflow-y: auto !important;
    padding: 8px 10px 24px 10px !important;
    scrollbar-width: thin !important;
  }

  /* Hide old desktop sidebar */
  .desktop-sidebar {
    display: none !important;
  }

  /* Hide mobile fab & bottom nav */
  .fab-btn {
    display: none !important;
  }

  .bottom-nav {
    display: none !important;
  }

  /* 4. Right Detail Pane (macOS Split View) */
  .desktop-detail-pane {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
    background-color: #FFFFFF !important;
    overflow-y: auto !important;
    padding: 28px 48px !important;
    box-sizing: border-box !important;
    scrollbar-width: thin !important;
  }

  .desktop-empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #8E8E93;
    max-width: 380px;
    margin: 0 auto;
  }

  .desktop-empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 14px;
  }

  .desktop-empty-state h3 {
    font-size: 18px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 6px;
  }

  .desktop-empty-state p {
    font-size: 13.5px;
    line-height: 1.5;
  }

  .desktop-detail-content {
    display: flex;
    flex-direction: column;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
  }
}

/* About Modal Styles */
.modal-about-card {
  max-width: 420px;
  text-align: center;
}

.about-brand-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 0 20px;
}

.about-app-icon {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  box-shadow: 0 10px 25px rgba(0, 122, 255, 0.25);
  margin-bottom: 14px;
}

.about-app-title {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #111827;
  margin: 0 0 4px;
}

.about-app-subtitle {
  font-size: 13.5px;
  color: #6B7280;
  margin: 0 0 12px;
}

.about-version-tag {
  display: inline-block;
  padding: 4px 12px;
  background-color: #F2F2F7;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  color: #007AFF;
}

.about-info-list {
  background-color: #F8FAFC;
  border-radius: 14px;
  padding: 12px 16px;
  margin-top: 14px;
  text-align: left;
}

.about-info-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  font-size: 13px;
  border-bottom: 1px solid #E2E8F0;
}

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

.about-info-item .info-label {
  color: #64748B;
}

.about-info-item .info-val {
  color: #0F172A;
  font-weight: 600;
}

/* Drag & Drop Fullscreen Overlay */
.drag-drop-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 122, 255, 0.14);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.drag-drop-box {
  background: rgba(255, 255, 255, 0.96);
  border: 3px dashed #007AFF;
  border-radius: 28px;
  padding: 44px 36px;
  text-align: center;
  max-width: 500px;
  box-shadow: 0 20px 50px rgba(0, 122, 255, 0.25);
  animation: pulseDrop 1.8s infinite ease-in-out;
}

@keyframes pulseDrop {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}

.drag-drop-icon {
  font-size: 64px;
  margin-bottom: 14px;
}

.drag-drop-box h2 {
  font-size: 22px;
  font-weight: 800;
  color: #111827;
  margin: 0 0 8px;
}

.drag-drop-box p {
  font-size: 14px;
  color: #4B5563;
  line-height: 1.5;
  margin: 0;
}

/* Modal Progress */
.modal-progress-card {
  max-width: 440px;
  padding: 24px;
  text-align: center;
}

.import-progress-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 12px;
}

.import-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid #E2E8F0;
  border-top-color: #007AFF;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.import-progress-status {
  font-size: 13.5px;
  color: #64748B;
  margin-bottom: 16px;
  min-height: 20px;
  word-break: break-word;
}

.import-progress-bar-wrap {
  width: 100%;
  height: 8px;
  background-color: #F1F5F9;
  border-radius: 6px;
  overflow: hidden;
}

.import-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #007AFF, #34C759);
  transition: width 0.25s ease;
}

/* Sidebar Actions Group */
.btn-sidebar-import {
  width: 100%;
  padding: 9px 12px;
  background-color: #F2F2F7;
  color: #1C1C1E;
  border: 1px solid #E5E5EA;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-sidebar-import:hover {
  background-color: #E5E5EA;
  color: #000000;
}

/* Document Pills in Detail Pane */
.doc-pills-container {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 6px 0 12px;
  scrollbar-width: none;
}

.doc-pills-container::-webkit-scrollbar {
  display: none;
}

.doc-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.doc-pill:hover, .doc-pill.active {
  background: #007AFF;
  border-color: #007AFF;
  color: #FFFFFF;
}

.doc-pill .doc-pill-icon {
  font-size: 13px;
}

/* About Modal Actions */
.about-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.btn-about-action {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s;
}

.btn-about-action.primary {
  background: #007AFF;
  color: #FFFFFF;
  box-shadow: 0 4px 12px rgba(0, 122, 255, 0.25);
}

.btn-about-action.primary:hover {
  background: #0062cc;
}

.btn-about-action.secondary {
  background: #F1F5F9;
  color: #1E293B;
  border: 1px solid #CBD5E1;
}

.btn-about-action.secondary:hover {
  background: #E2E8F0;
}

.btn-about-action.danger {
  background: #FEF2F2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.btn-about-action.danger:hover {
  background: #FEE2E2;
  color: #991B1B;
}

.btn-sidebar-clear {
  width: 100%;
  padding: 8px 12px;
  background-color: transparent;
  color: #94A3B8;
  border: 1px dashed #CBD5E1;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 6px;
}

.btn-sidebar-clear:hover {
  background-color: #FEF2F2;
  color: #DC2626;
  border-color: #FECACA;
  border-style: solid;
}

/* ==========================================================================
   EXPIRES! 3-COLUMN DESKTOP & IPAD DESIGN SYSTEM (NÁVRH 1)
   ========================================================================== */

:root {
  /* Pastel Palette */
  --pastel-blue-bg: #EAF2FD;
  --pastel-blue-txt: #1E65D6;
  --pastel-coral-bg: #FEECEC;
  --pastel-coral-txt: #E5484D;
  --pastel-amber-bg: #FEF3E6;
  --pastel-amber-txt: #D97706;
  --pastel-mint-bg: #E8F7F0;
  --pastel-mint-txt: #10B981;
  --pastel-purple-bg: #F3E8FF;
  --pastel-purple-txt: #8B5CF6;
  --pastel-gray-bg: #F1F3F5;
  --pastel-gray-txt: #4B5563;
}

/* Default / Mobile */
.expires-nav-sidebar {
  display: none;
}
.expires-list-head-desktop {
  display: none;
}

/* Donut Ring */
.donut-ring {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.donut-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.donut-bg {
  fill: none;
  stroke-width: 3.5;
}
.donut-fg {
  fill: none;
  stroke-width: 3.5;
  stroke-linecap: round;
  transition: stroke-dasharray 0.3s ease;
}
.donut-label {
  position: absolute;
  font-size: 10.5px;
  font-weight: 800;
  text-align: center;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}

/* Pastel Squircle Tiles */
.pastel-tile {
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 82px;
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
  user-select: none;
  border: 1px solid rgba(0,0,0,0.03);
}
.pastel-tile:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
}
.pastel-tile.active {
  outline: 2px solid var(--pastel-blue-txt);
  outline-offset: -1px;
}
.pt-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pt-icon {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.pt-icon-img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.08));
}
.pt-arrow {
  font-size: 14px;
  opacity: 0.4;
  font-weight: 700;
}
.pt-bottom {
  margin-top: 6px;
}
.pt-title {
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.2;
}
.pt-subtitle {
  font-size: 11px;
  opacity: 0.75;
  margin-top: 2px;
}

/* Year Tile - Návrh 4 (Velký rok v záhlaví vedle kalendáře) */
.pastel-tile.year-tile {
  padding: 9px 10px;
}
.pastel-tile.year-tile .yt-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 5px;
}
.pastel-tile.year-tile .yt-icon-img {
  width: 24px;
  height: 24px;
  object-fit: contain;
  display: block;
}
.pastel-tile.year-tile .yt-year {
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.2px;
  line-height: 1.15;
}
.pastel-tile.year-tile .yt-sub {
  font-size: 9.5px;
  opacity: 0.8;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tile-blue { background: var(--pastel-blue-bg); color: var(--pastel-blue-txt); }
.tile-coral { background: var(--pastel-coral-bg); color: var(--pastel-coral-txt); }
.tile-amber { background: var(--pastel-amber-bg); color: var(--pastel-amber-txt); }
.tile-mint { background: var(--pastel-mint-bg); color: var(--pastel-mint-txt); }
.tile-purple { background: var(--pastel-purple-bg); color: var(--pastel-purple-txt); }
.tile-gray { background: var(--pastel-gray-bg); color: var(--pastel-gray-txt); }

/* Item Row (Expires! List) */
.expires-row {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  gap: 12px;
  cursor: pointer;
  transition: background 0.12s ease;
}
.expires-row:hover {
  background: #F9FAFB;
}
.expires-row.selected-desktop {
  background: #F0F7FF;
  border-left: 3px solid #007AFF;
  padding-left: 13px;
}
.er-body {
  flex: 1;
  min-width: 0;
}
.er-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #111827;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.er-meta {
  font-size: 11.5px;
  margin-top: 2px;
  font-weight: 500;
  white-space: normal;
  overflow-wrap: anywhere;
}
.er-meta.active { color: #10B981; }
.er-meta.soon { color: #D97706; }
.er-meta.expired { color: #DC2626; }
.er-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.er-price {
  font-size: 12px;
  font-weight: 700;
  color: #4B5563;
}
.er-chevron {
  color: #D1D5DB;
  font-size: 13px;
  font-weight: 700;
}

/* Detail Elements (Expires! Style) */
.detail-card {
  background: #FFFFFF;
  border-radius: 16px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 1px 3px rgba(0,0,0,0.02);
  padding: 22px 24px;
  width: 100%;
  box-sizing: border-box;
}/* ==========================================================================
   KOMPAKTNÍ SPEC SHEET KARTA DETAILU (NÁVRH 3)
   ========================================================================== */
.cpc-left {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.cpc-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cpc-title {
  font-size: 20px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.02em;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.cpc-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.cpc-badge.badge-active {
  background: #E8F7F0;
  color: #10B981;
}

.cpc-badge.badge-soon {
  background: #FEF3E6;
  color: #D97706;
}

.cpc-badge.badge-expired {
  background: #FEECEC;
  color: #DC2626;
}

.cpc-badge.badge-claimed {
  background: #FEF3C7;
  color: #B45309;
}

.cpc-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: #6B7280;
  font-weight: 500;
  flex-wrap: wrap;
}

.cpc-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.cpc-meta-item strong {
  color: #111827;
  font-weight: 700;
}

.cpc-meta-item strong.alert {
  color: #DC2626;
}

.cpc-sep {
  color: #D1D5DB;
  font-weight: 700;
}

.cpc-expiry-sub {
  color: #6B7280;
  font-size: 11.5px;
  font-weight: 500;
}

.cpc-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.cpc-price-tag {
  font-size: 22px;
  font-weight: 800;
  color: #111827;
  background: #F3F4F6;
  padding: 6px 14px;
  border-radius: 10px;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

.cpc-price-tag.cpc-price-empty {
  font-size: 13px;
  font-weight: 600;
  color: #6B7280;
  padding: 6px 12px;
}

@media (max-width: 640px) {  .cpc-right {
    width: 100%;
    justify-content: flex-end;
  }
}

/* Status Alert *//* Timeline Box */
.timeline-box {
  background: #F9FAFB;
  border-radius: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}/* Receipt Preview Box */
.receipt-preview-box {
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 12px;
  padding: 12px;
  background: #FAFAFA;
  display: flex;
  align-items: center;
  gap: 14px;
}
.receipt-thumb {
  width: 64px;
  height: 80px;
  background: #FFF;
  border: 1px solid #E5E7EB;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #9CA3AF;
  flex-shrink: 0;
}
.receipt-info {
  flex: 1;
  min-width: 0;
}
.ri-title {
  font-size: 13px;
  font-weight: 700;
  color: #111827;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ri-meta {
  font-size: 11.5px;
  color: #6B7280;
  margin-top: 3px;
}
.ri-btn {
  margin-top: 8px;
  display: inline-block;
  padding: 5px 12px;
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
  transition: all 0.15s ease;
}
.ri-btn:hover {
  background: #F3F4F6;
  border-color: #9CA3AF;
}

/* Detail Actions */.btn-action {
  flex: 1;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: none;
  transition: all 0.15s ease;
}
.btn-action.btn-primary { background: #007AFF; color: #FFF; }
.btn-action.btn-primary:hover { background: #0062CC; }
.btn-action.btn-secondary { background: #E5E7EB; color: #374151; }
.btn-action.btn-secondary:hover { background: #D1D5DB; }
.btn-action.btn-danger { background: #FEECEC; color: #DC2626; }
.btn-action.btn-danger:hover { background: #FECDCD; }

/* Desktop 3-Column Override (min-width: 900px) */
@media (min-width: 900px) {
  .workspace-body.expires-workspace-layout {
    display: grid !important;
    grid-template-columns: 310px 440px 1fr !important;
    width: 100vw !important;
    height: 100vh !important;
    overflow: hidden !important;
    background: #F5F7FA !important;
  }

  /* 1. Left Nav Sidebar */
  .expires-nav-sidebar {
    display: flex !important;
    flex-direction: column !important;
    width: 310px !important;
    min-width: 310px !important;
    max-width: 310px !important;
    height: 100vh !important;
    background: #FFFFFF !important;
    border-right: 1px solid rgba(0,0,0,0.06) !important;
    padding: 20px 16px !important;
    gap: 16px !important;
    overflow-y: auto !important;
    box-sizing: border-box !important;
  }

  .ens-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .ens-brand {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  .ens-icon {
    font-size: 20px;
  }
  .ens-title {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #111827;
  }
  .ens-actions {
    display: flex;
    gap: 6px;
  }
  .ens-icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,0.06);
    background: #F9FAFB;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 13px;
    color: #4B5563;
    transition: all 0.15s ease;
  }
  .ens-icon-btn:hover {
    background: #F3F4F6;
    color: #111827;
  }
  .ens-icon-btn.primary {
    background: #007AFF;
    color: #FFF;
    border-color: #007AFF;
  }
  .ens-icon-btn.primary:hover {
    background: #0062CC;
  }
  .ens-icon-btn.danger {
    color: #DC2626;
  }
  .ens-icon-btn.danger:hover {
    background: #FEECEC;
  }

  .ens-search-box {
    background: #F3F4F6;
    border-radius: 10px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #9CA3AF;
  }
  .ens-search-box input {
    border: none;
    background: transparent;
    outline: none;
    font-size: 13px;
    color: #111827;
    width: 100%;
    font-family: inherit;
  }
  .ens-search-box input::placeholder {
    color: #9CA3AF;
  }

  .ens-section-heading {
    font-size: 11.5px;
    font-weight: 700;
    color: #6B7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
    margin-bottom: -6px;
  }

  .ens-status-grid, .ens-years-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .ens-footer {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid rgba(0,0,0,0.06);
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .ens-footer-label {
    font-size: 12px;
    color: #6B7280;
    font-weight: 600;
  }
  .ens-footer-val {
    font-size: 15px;
    font-weight: 800;
    color: #111827;
  }

  /* 2. Middle Column: Items */
  .expires-center-column {
    width: 440px !important;
    min-width: 440px !important;
    max-width: 440px !important;
    height: 100vh !important;
    background: #FFFFFF !important;
    border-right: 1px solid rgba(0,0,0,0.06) !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }

  .expires-mid-header {
    padding: 16px 18px !important;
    border-bottom: 1px solid rgba(0,0,0,0.06) !important;
    background: #FFFFFF !important;
    position: relative !important;
  }

  .expires-mid-header .header-top-row,
  .expires-mid-header .filter-chips {
    display: none !important;
  }

  .expires-list-head-desktop {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
  }
  .expires-head-title {
    font-size: 17px;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.02em;
  }
  .expires-head-subtitle {
    font-size: 12px;
    color: #6B7280;
    font-weight: 500;
    margin-top: 2px;
  }
  .expires-head-subtitle strong {
    color: #007AFF;
    font-weight: 700;
  }

  .sort-tile-c1 {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 10px;
    background: #F0F4FF;
    border: 1px solid #D0E1FD;
    color: #007AFF;
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,122,255,0.08);
    transition: all 0.15s ease;
  }
  .sort-tile-c1:hover {
    background: #E1EDFE;
  }

  .sort-menu-dropdown {
    position: absolute;
    top: 42px;
    right: 0;
    background: #FFFFFF;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15), 0 1px 4px rgba(0,0,0,0.08);
    border: 1px solid rgba(0,0,0,0.08);
    width: 220px;
    padding: 6px;
    z-index: 100;
  }
  .sort-menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.12s ease;
  }
  .sort-menu-item:hover {
    background: #F3F4F6;
    color: #111827;
  }
  .sort-menu-item.active {
    background: #EBF5FF;
    color: #007AFF;
    font-weight: 700;
  }
  .sort-check {
    font-weight: 800;
    color: #007AFF;
  }

  .expires-timeline-container {
    flex: 1 !important;
    overflow-y: auto !important;
    padding: 0 !important;
  }

  /* 3. Right Column: Detail */
  .expires-detail-column {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100vh !important;
    background: #F8FAFC !important;
    overflow-y: auto !important;
    padding: 24px 32px !important;
    gap: 18px !important;
    box-sizing: border-box !important;
    width: 100% !important;
  }

  .expires-detail-column .desktop-detail-content {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    gap: 16px !important;
  }

  .expires-detail-column .receipt-zoom-container {
    max-height: none !important;
    height: auto !important;
    overflow: visible !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: #F3F4F6 !important;
    padding: 24px 20px !important;
    border-radius: 14px !important;
    text-align: center !important;
  }

  .expires-detail-column .desktop-receipt-img {
    width: 100% !important;
    max-width: 880px !important;
    height: auto !important;
    object-fit: contain !important;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.09) !important;
    background: #FFFFFF !important;
    border-radius: 8px !important;
    margin: 0 auto !important;
    display: block !important;
  }
}

/* Výběr jazyka v modálu O aplikaci */
.about-lang-select {
  font-size: 14px;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 10px;
  border: 1px solid #D1D5DB;
  background: #FFFFFF;
  color: #111827;
  max-width: 55%;
}

/* ==========================================================================
   MĚNA U CENY, BANNER "CO BRZY KONČÍ", NASTAVENÍ UPOZORNĚNÍ (v0.10.0)
   ========================================================================== */
.price-row { display: flex; gap: 8px; min-width: 0; }
.price-row > * { box-sizing: border-box; }
.price-row input { flex: 1 1 0; width: auto !important; min-width: 0; }
.price-row .currency-select {
  flex: 0 0 auto;
  width: 72px !important;
  padding: 0 4px !important;
  border: 1px solid #D1D5DB;
  border-radius: 10px;
  background: #FFFFFF;
  font-size: 15px;
  font-weight: 700;
  color: #111827;
  padding: 0 8px;
}

.attention-banner {
  margin: 12px 14px 0;
  padding: 11px 14px;
  border-radius: 16px;
  background: #FEF3C7;
  border: 1px solid #FDE68A;
  color: #92400E;
  font-size: 13px;
  line-height: 1.35;
  cursor: default;
}
.attention-banner b { display: block; font-weight: 800; }
.attention-banner span { display: block; margin-top: 2px; font-weight: 600; opacity: 0.9; overflow-wrap: anywhere; }

.rem-settings {
  margin: 14px 0 6px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #F8FAFC;
  border: 1px solid #E5E7EB;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.rem-title { font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #6B7280; }
.rem-row { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: #111827; cursor: pointer; }
.rem-row input, .rem-chip input { width: 18px; height: 18px; accent-color: #3B82F6; }
.rem-offsets { display: flex; flex-wrap: wrap; gap: 8px; }
.rem-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 99px; background: #FFFFFF; border: 1px solid #E5E7EB; font-size: 13px; font-weight: 600; color: #374151; cursor: pointer; }
.rem-note { font-size: 12px; color: #6B7280; line-height: 1.4; }
.modal-about-card { max-height: 92vh; overflow-y: auto; }

/* Řádek formuláře: dva stejně široké sloupce, i když je uvnitř datum nebo měna */
.form-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.form-row > .form-group { min-width: 0; }
.form-row input[type="date"] { min-width: 0; width: 100%; }

/* Předvyplnění formuláře z dokladu (v0.11.0) */
.scan-status { margin-top: 10px; padding: 10px 12px; border-radius: 12px; font-size: 13px; line-height: 1.4; font-weight: 600; }
.scan-status.busy { background: #EFF6FF; color: #1D4ED8; }
.scan-status.ok { background: #ECFDF5; color: #047857; }
.scan-status.warn { background: #FFFBEB; color: #B45309; }
.scan-filled { box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.55) !important; border-color: #10B981 !important; }

/* ==========================================================================
   ÚVODNÍ OBRAZOVKA, UKÁZKOVÁ DATA, PRO (v0.13.0)
   ========================================================================== */
.onboarding { text-align: center; padding: 48px 24px 32px; }
.onboarding .onb-icon { font-size: 54px; margin-bottom: 10px; }
.onboarding h3 { font-size: 20px; font-weight: 800; color: #111827; margin-bottom: 8px; }
.onboarding p { font-size: 14px; line-height: 1.5; color: #4B5563; margin-bottom: 20px; }
.onb-btn { display: block; width: 100%; max-width: 320px; margin: 0 auto 10px; padding: 14px 18px; border-radius: 14px; font-size: 15px; font-weight: 700; cursor: pointer; }

.demo-banner { display: none; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 12px 14px 0; padding: 10px 14px; border-radius: 16px; background: #EFF6FF; border: 1px solid #BFDBFE; color: #1E40AF; font-size: 12.5px; font-weight: 600; }
.demo-remove { border: none; background: #FFFFFF; color: #1E40AF; font-weight: 700; font-size: 12.5px; padding: 6px 12px; border-radius: 10px; cursor: pointer; }

.modal-paywall-card { text-align: center; }
.paywall-sub { color: #4B5563; font-size: 14px; margin: -8px 0 14px; }
.paywall-list { list-style: none; text-align: left; margin: 0 0 14px; padding: 0; }
.paywall-list li { position: relative; padding: 8px 0 8px 28px; font-size: 14.5px; font-weight: 600; color: #111827; border-bottom: 1px solid rgba(0, 0, 0, 0.06); }
.paywall-list li:last-child { border-bottom: none; }
.paywall-list li::before { content: "✓"; position: absolute; left: 4px; color: #047857; font-weight: 800; }
.paywall-limit { font-size: 13px; color: #4B5563; margin-bottom: 14px; }
.paywall-btn { display: block; width: 100%; margin: 0 0 10px; padding: 14px 18px; border: none; border-radius: 14px; font-size: 15px; font-weight: 700; cursor: pointer; }

/* ==========================================================================
   JEDNOTNÉ IKONY, „CO ŘEŠIT TEĎ“, POHYB, ÚVODNÍ PRŮVODCE (v0.15.0)
   ========================================================================== */
.ic { display: inline-flex; vertical-align: -0.16em; margin-right: 0.4em; flex: none; }
.ic svg { width: 1.08em; height: 1.08em; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ic-dot svg { stroke: none; fill: currentColor; }
.ic-dot { color: #10B981; }
.ens-icon-btn .ic, .ens-search-icon .ic, .btn-close-modal .ic, .btn-close-zoom .ic, .btn-remove-photo .ic, .btn-clear .ic,
.sort-check .ic, .empty-icon .ic, .ens-icon .ic, .onb-icon .ic, .drag-drop-icon .ic, #detDocCardIcon .ic, .detail-category-badge .ic { margin-right: 0; }
.ens-icon-btn .ic svg { width: 18px; height: 18px; }
.ens-icon { color: #2563EB; font-size: 22px; display: inline-flex; }
.empty-icon { font-size: 48px; color: #94A3B8; }
.onb-icon { font-size: 54px; color: #2563EB; }
.drag-drop-icon { color: #2563EB; }
.cpc-badge .ic svg { width: 0.95em; height: 0.95em; }
.detail-category-badge .ic { margin-right: 0.35em; }

/* Co řešit teď */
.today-card { margin: 12px 14px 0; padding: 14px 14px 12px; border-radius: 22px; background: rgba(255, 255, 255, 0.78); border: 1px solid rgba(255, 255, 255, 0.95); box-shadow: 0 8px 26px rgba(60, 80, 140, 0.14); }
.today-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.today-title { font-size: 13px; font-weight: 800; color: #0F172A; display: inline-flex; align-items: center; }
.today-count { background: #FEF3C7; color: #92400E; border-radius: 99px; padding: 2px 9px; font-size: 12px; font-weight: 800; }
.today-all { margin-left: auto; border: none; background: none; color: var(--apple-blue); font-weight: 700; font-size: 12px; cursor: pointer; padding: 4px 2px; }
.today-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 4px; border: none; border-top: 1px solid rgba(15, 23, 42, 0.06); background: none; border-radius: 10px; cursor: pointer; font: inherit; text-align: left; color: inherit; transition: background 0.15s ease; }
.today-row:hover { background: rgba(15, 23, 42, 0.04); }
.td-dot { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; flex: none; font-size: 17px; }
.td-dot .ic { margin: 0; }
.td-dot.amber { background: #FEF3C7; color: #B45309; }
.td-dot.red { background: #FEE2E2; color: #B91C1C; }
.td-main { flex: 1; min-width: 0; }
.td-main b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 13.5px; color: #0F172A; overflow: hidden; line-height: 1.25; }
.td-main small { color: #4B5563; font-size: 12px; }
.td-chip { font-size: 12px; font-weight: 800; border-radius: 99px; padding: 4px 10px; white-space: nowrap; }
.td-chip.amber { background: #FEF3C7; color: #92400E; }
.td-chip.red { background: #FEE2E2; color: #991B1B; }
.td-go { color: #94A3B8; display: inline-flex; font-size: 16px; }
.td-go .ic { margin: 0; }
.today-ok { display: flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: #047857; padding: 4px 0 8px; }
.today-foot { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: 6px; padding-top: 9px; border-top: 1px solid rgba(15, 23, 42, 0.06); font-size: 12px; color: #4B5563; font-weight: 600; }

/* Pohyb */
@keyframes ringDraw { from { stroke-dasharray: 0.01, 100; } }
@keyframes rowIn { from { opacity: 0; transform: translateY(6px); } }
@keyframes obIn { from { opacity: 0; transform: translateY(10px); } }
.gl-ring-fg { animation: ringDraw 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; }
.expires-items-list.enter .expires-row { animation: rowIn 0.35s ease both; animation-delay: calc(var(--i, 0) * 35ms); }
.expires-row { transition: background 0.15s ease, box-shadow 0.2s ease, transform 0.2s ease; }
.expires-row:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(60, 80, 140, 0.16); }
.btn-action:active, .btn-save:active, .btn-cancel:active, .ob-next:active, .onb-btn:active, .today-row:active { transform: scale(0.96); }
.btn-action, .btn-save, .btn-cancel, .ob-next, .onb-btn { transition: transform 0.12s ease, filter 0.15s ease, background 0.15s ease; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Úvodní průvodce */
.ob-overlay { position: fixed; inset: 0; z-index: 300; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(700px 480px at 10% 0%, #cfe3ff 0, transparent 60%), radial-gradient(600px 420px at 100% 25%, #e6d6ff 0, transparent 55%), radial-gradient(600px 500px at 50% 100%, #c9f1e4 0, transparent 55%), #eef2f9; }
.ob-card { position: relative; width: 100%; max-width: 420px; height: 100%; max-height: 780px; padding: 64px 28px 28px; display: flex; flex-direction: column; align-items: center; animation: obIn 0.35s ease both; }
@media (min-width: 900px) {
  .ob-card { height: auto; min-height: 660px; background: rgba(255, 255, 255, 0.6); border: 1px solid rgba(255, 255, 255, 0.9); border-radius: 32px; box-shadow: 0 20px 60px rgba(60, 80, 140, 0.18); }
}
.ob-skip { position: absolute; top: 24px; right: 26px; border: none; background: none; font-size: 14px; font-weight: 700; color: #475569; cursor: pointer; padding: 6px; }
.ob-art { height: 300px; width: 100%; display: grid; place-items: center; }
.ob-title { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; text-align: center; margin-top: 10px; color: #0F172A; }
.ob-text { font-size: 15px; line-height: 1.5; color: #475569; text-align: center; margin-top: 10px; max-width: 300px; }
.ob-dots { display: flex; gap: 7px; margin-top: auto; margin-bottom: 18px; }
.ob-dots i { width: 8px; height: 8px; border-radius: 99px; background: rgba(15, 23, 42, 0.2); display: block; transition: width 0.25s ease, background 0.25s ease; }
.ob-dots i.on { width: 24px; background: #2563EB; }
.ob-next { width: 100%; padding: 16px; border: none; border-radius: 16px; background: linear-gradient(135deg, #2563eb, #4f46e5); color: #FFFFFF; font-weight: 800; font-size: 16px; cursor: pointer; box-shadow: 0 10px 24px rgba(37, 99, 235, 0.35); }
.ob-later { margin-top: 10px; border: none; background: none; color: #475569; font-weight: 700; font-size: 14px; cursor: pointer; padding: 8px; }
.ob-paper { position: relative; width: 190px; height: 250px; background: #FFFFFF; border-radius: 16px; box-shadow: 0 18px 36px rgba(60, 80, 140, 0.25); padding: 22px 20px; transform: rotate(-4deg); display: flex; flex-direction: column; gap: 12px; }
.ob-paper b { font-size: 13px; color: #0F172A; }
.ob-paper i { display: block; height: 7px; border-radius: 9px; background: #E2E8F0; }
.ob-paper i.short { width: 60%; }
.ob-paper strong { margin-top: auto; font-size: 17px; color: #0F172A; }
.ob-scan { position: absolute; left: 12px; right: 12px; top: 96px; height: 3px; background: #10B981; box-shadow: 0 0 14px #10B981; border-radius: 9px; animation: obScan 2.2s ease-in-out infinite alternate; }
@keyframes obScan { from { top: 50px; } to { top: 190px; } }
.ob-cam { position: absolute; right: -26px; bottom: -18px; width: 74px; height: 74px; border-radius: 50%; background: linear-gradient(135deg, #2563eb, #4f46e5); display: grid; place-items: center; box-shadow: 0 10px 24px rgba(37, 99, 235, 0.4); color: #FFFFFF; }
.ob-cam svg { width: 34px; height: 34px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ob-form { width: 100%; background: rgba(255, 255, 255, 0.8); border: 1px solid #FFFFFF; border-radius: 22px; padding: 16px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 12px 30px rgba(60, 80, 140, 0.15); }
.ob-fld { border: 2px solid #10B981; background: #F0FDF4; border-radius: 12px; padding: 10px 12px; font-size: 13.5px; font-weight: 600; color: #0F172A; display: flex; justify-content: space-between; gap: 10px; }
.ob-fld small { color: #4B5563; font-weight: 600; }
.ob-notif { width: 100%; background: rgba(255, 255, 255, 0.9); border: 1px solid #FFFFFF; border-radius: 22px; padding: 14px; display: flex; gap: 12px; align-items: center; box-shadow: 0 14px 34px rgba(60, 80, 140, 0.22); }
.ob-notif img { width: 42px; height: 42px; border-radius: 11px; }
.ob-notif b { font-size: 14px; display: block; color: #0F172A; }
.ob-notif span { font-size: 13px; color: #475569; }
.ob-notif em { margin-left: auto; font-style: normal; font-size: 12px; color: #64748B; }

.pt-arrow .ic, .er-chevron .ic { margin-right: 0; }

/* ==========================================================================
   OCHRANA DAT (v0.16.0): okno potvrzení, „Vrátit zpět“, připomenutí zálohy
   ========================================================================== */
.confirm-overlay { z-index: 400; align-items: center; }
.confirm-card { max-width: 380px; border-radius: 24px !important; text-align: center; padding: 24px 22px !important; }
.confirm-card h2 { font-size: 19px; font-weight: 800; color: #111827; margin-bottom: 8px; }
.confirm-card p { color: #4B5563; font-size: 14px; line-height: 1.45; margin-bottom: 18px; }
.confirm-card .modal-actions { display: flex; gap: 10px; }
.confirm-card .modal-actions button { flex: 1; }
.btn-danger-fill { background: #B91C1C !important; color: #FFFFFF !important; }

.undo-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(24px + var(--safe-bottom)); z-index: 500; display: flex; align-items: center; gap: 14px; background: #0F172A; color: #FFFFFF; padding: 12px 14px 12px 18px; border-radius: 16px; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35); font-size: 14px; font-weight: 600; max-width: calc(100vw - 28px); animation: obIn 0.25s ease both; }
.undo-bar button { border: none; background: rgba(255, 255, 255, 0.14); color: #93C5FD; font-weight: 800; border-radius: 10px; padding: 8px 12px; cursor: pointer; font-size: 14px; }
@media (max-width: 899px) { .undo-bar { bottom: calc(92px + var(--safe-bottom)); } }

.backup-bar { display: none; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 12px 14px 0; padding: 10px 14px; border-radius: 16px; background: #ECFEFF; border: 1px solid #A5F3FC; color: #155E75; font-size: 12.5px; font-weight: 600; line-height: 1.4; }
.bk-actions { display: flex; gap: 8px; flex: none; }
.backup-bar button { border: none; border-radius: 10px; padding: 6px 12px; font-weight: 700; font-size: 12.5px; cursor: pointer; }
#btnBackupNow { background: #0E7490; color: #FFFFFF; }
#btnBackupLater { background: #FFFFFF; color: #155E75; }

/* ==========================================================================
   NASTAVENÍ (O aplikaci) - kompaktní symetrické rozložení (v0.17.0)
   ========================================================================== */
.modal-about-card .about-brand-badge { padding: 2px 0 4px; }
.modal-about-card .about-app-icon { width: 64px; height: 64px; border-radius: 15px; margin-bottom: 8px; }
.modal-about-card .about-app-title { font-size: 22px; margin-bottom: 2px; }
.modal-about-card .about-app-subtitle { margin: 0 0 8px; }
.about-info-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; background: none; padding: 0; margin-top: 12px; }
.about-info-item { flex-direction: column; justify-content: center; gap: 4px; padding: 10px 8px; background: #F8FAFC; border: 1px solid #E2E8F0; border-radius: 14px; text-align: center; min-width: 0; }
.about-info-item:last-child { border-bottom: 1px solid #E2E8F0; }
.about-info-wide { grid-column: 1 / -1; }
.about-info-item .info-label { font-size: 11px; font-weight: 600; }
.about-info-item .info-val { font-size: 13.5px; }
.about-info-item .about-lang-select { max-width: 100%; }
.rem-settings { margin: 12px 0 12px; padding: 12px; }
.rem-title { text-align: center; }
.rem-row { justify-content: center; }
.rem-offsets { display: grid; grid-template-columns: repeat(3, 1fr); }
.rem-chip { justify-content: center; padding: 8px 4px; min-width: 0; }
.rem-settings .rem-note { text-align: center; }
#remEnabled { appearance: none; -webkit-appearance: none; width: 40px; height: 24px; border-radius: 99px; background: #CBD5E1; position: relative; flex: none; cursor: pointer; transition: background 0.15s; }
#remEnabled::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #FFFFFF; transition: transform 0.15s; }
#remEnabled:checked { background: #2563EB; }
#remEnabled:checked::after { transform: translateX(16px); }
.about-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 0; }
.about-actions .btn-about-action { flex-direction: column; gap: 5px; padding: 12px 6px; font-size: 12.5px; line-height: 1.25; text-align: center; min-width: 0; }
.about-actions .btn-about-action > span:not(.ic) { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.about-actions .btn-about-action .ic { margin: 0; }
.about-actions .btn-about-action .ic svg { width: 20px; height: 20px; }
.about-actions .btn-about-action:last-of-type:nth-of-type(odd) { grid-column: 1 / -1; }
.about-danger { margin-top: 10px; }
.about-foot { margin-top: 12px; font-size: 12px; color: #64748B; text-align: center; }
.modal-about-card .modal-header { position: relative; justify-content: center; }
.modal-about-card .btn-close-modal { position: absolute; right: 0; top: 50%; transform: translateY(-50%); }
.rem-chip { flex-direction: column; gap: 4px; padding: 8px 4px; border-radius: 14px; font-size: 12.5px; text-align: center; line-height: 1.25; }

/* ==========================================================================
   REKLAMAČNÍ DOPIS (v0.19.0)
   ========================================================================== */
.claim-letter-btn { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; margin-top: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid #CBD5E1; background: #F1F5F9; color: #1E293B; font-weight: 700; font-size: 13px; cursor: pointer; }
.claim-letter-btn .ic { margin: 0; }
.claim-letter-btn:active { transform: scale(0.98); }
.modal-letter-card { max-width: 520px; max-height: 92vh; overflow-y: auto; }
#letPreview { width: 100%; min-height: 220px; line-height: 1.5; font-size: 13px; }
.modal-letter-card .modal-actions { margin-top: 12px; }

/* ==========================================================================
   KALENDÁŘ A EXPORT .ics (v0.20.0)
   ========================================================================== */
.cal-item-btn { margin-top: 12px; }
.modal-calendar-card { max-width: 460px; max-height: 88vh; overflow-y: auto; }
.cal-sub { text-align: center; margin: -6px 0 6px; }
.cal-month { text-align: center; font-size: 11.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #6B7280; margin: 14px 0 6px; }
.cal-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; margin-bottom: 6px; border-radius: 14px; background: #F8FAFC; border: 1px solid #E2E8F0; color: #111827; cursor: pointer; }
.cal-row:active { transform: scale(0.98); }
.cal-day { flex: none; width: 44px; text-align: center; display: flex; flex-direction: column; line-height: 1.1; }
.cal-day b { font-size: 20px; font-weight: 800; }
.cal-day small { font-size: 11px; font-weight: 700; color: #6B7280; text-transform: uppercase; }
.cal-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cal-main b { font-size: 14px; overflow-wrap: anywhere; }
.cal-main small { font-size: 12px; color: #6B7280; overflow-wrap: anywhere; }
.cal-chip { flex: none; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 99px; background: #DCFCE7; color: #166534; max-width: 38%; text-align: center; }
.cal-chip.soon { background: #FEF3C7; color: #92400E; }
.cal-empty { text-align: center; color: #6B7280; padding: 28px 8px; }
.cal-all { width: 100%; margin-top: 12px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.cal-row, .cal-row * { font-family: inherit; }
.cal-day { width: auto; min-width: 44px; }

/* Kontrast (v0.21.2): bílý text na tlačítku PRO v Nastavení a stavový text v tmavém detailu na telefonu */
.about-actions .btn-about-action.primary { background: #0A5FD1; }
:root[data-theme-resolved="dark"] #modalDetail .gl-state { color: #acb1b7; }
:root[data-theme-resolved="dark"] .about-actions .btn-about-action.primary { background: #0A5FD1; }
.letter-hint { font-weight: 600; color: #1D4ED8; margin: 0 0 6px; }
:root[data-theme-resolved="dark"] .letter-hint { color: #93c5fd; }

/* Záloha na jedno klepnutí a upozornění pro iPhone (v0.23.0) */
.stor-backup-btn { margin-top: 8px; border: none; border-radius: 10px; padding: 7px 14px; font-weight: 700; font-size: 12.5px; background: #0A5FD1; color: #FFFFFF; cursor: pointer; }
.backup-bar .bk-actions { flex-wrap: wrap; }
.backup-bar.bk-ios .bk-actions { width: 100%; }
.backup-bar.bk-ios .bk-actions button { flex: 1 1 auto; text-align: center; }

/* Výpis pro pojišťovnu (v0.24.0) */
.modal-ins-card { max-width: 440px; }
.ins-sub { text-align: center; margin: -6px 0 10px; font-weight: 600; }
.ins-opt { justify-content: flex-start; margin-bottom: 8px; }
.ins-create { width: 100%; margin-top: 8px; }

/* Aktivace licenčním kódem (v0.25.0) */
.code-box { margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(15, 23, 42, 0.1); display: flex; flex-direction: column; gap: 8px; text-align: center; }
.act-input { width: 100%; padding: 11px 12px; border: 1px solid #D1D5DB; border-radius: 12px; font-size: 15px; text-align: center; background: #FFFFFF; color: #111827; font-family: inherit; }
.act-input::placeholder { color: #6B7280; }
.act-msg { min-height: 1.2em; margin: 0; }
.act-msg.err { color: #B91C1C; font-weight: 600; }
.act-msg.ok { color: #047857; font-weight: 600; }
:root[data-theme-resolved="dark"] .code-box { border-top-color: rgba(255, 255, 255, 0.12); }
:root[data-theme-resolved="dark"] .act-input { background: #101217; border-color: #484f61; color: #e1e2e5; }
:root[data-theme-resolved="dark"] .act-msg.err { color: #fca5a5; }
:root[data-theme-resolved="dark"] .act-msg.ok { color: #6ee7b7; }
.code-box .rem-title { color: #4B5563; }

/* Tlačítko „Odemknout PRO“ na webu (odkaz na platbu) */
.paywall-buy { box-sizing: border-box; text-align: center; text-decoration: none; }

/* Odkazy na zásady soukromí a podmínky */
.about-legal a, .paywall-legal a { color: inherit; text-decoration: underline; }
.paywall-legal { text-align: center; }

/* Na telefonu je Nastavení v dolní liště, horní ikona panáčka by otevírala totéž (v počítači dolní lišta není) */
@media (max-width: 899px) { #btnProfile { display: none; } }

/* Dlaždice v Nastavení: popisek má vyhrazené dva řádky a hodnota je vždy ve stejné výšce,
   takže výběry jsou v jedné rovině a dlaždice při změně jazyka neskáčou */
.about-info-item { justify-content: flex-start; }
.about-info-item .info-label { display: flex; align-items: center; justify-content: center; min-height: 2.5em; line-height: 1.25; }
.about-info-item .info-val { display: flex; align-items: center; justify-content: center; min-height: 38px; }
.about-info-item.about-info-wide .info-label, .about-info-item.about-info-wide .info-val { min-height: 0; display: block; }

/* Doklad na celou obrazovku: přibližování prsty (zoomview.js), obraz využije celou obrazovku */
.modal-overlay-zoom { padding: 0; }
.modal-overlay-zoom .zoom-content { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; overflow: hidden; touch-action: none; -webkit-user-select: none; user-select: none; }
.modal-overlay-zoom .zoom-content img { max-width: 100%; max-height: 100%; border-radius: 0; transform-origin: 50% 50%; will-change: transform; touch-action: none; -webkit-user-drag: none; user-select: none; }
.modal-overlay-zoom .btn-close-zoom { z-index: 2; top: max(20px, env(safe-area-inset-top)); }

/* Okno Přidat/Upravit: žádný posun do stran (na iPhonu se vnitřek jinak dal tahat všemi směry) */
#modalAdd .modal-card { overflow-x: hidden; touch-action: pan-y; overscroll-behavior: contain; }

/* Vyhledávání na telefonu: pod nadpisem, nad filtry (na široké obrazovce je v levém sloupci) */
.phone-search { display: flex; align-items: center; gap: 8px; background: rgba(120, 120, 128, 0.12); border-radius: 12px; padding: 0 12px; margin: 2px 0 10px; min-height: 40px; }
.phone-search-icon { font-size: 15px; opacity: .7; }
.phone-search input { flex: 1; min-width: 0; border: none; background: transparent; outline: none; font-size: 16px; font-family: inherit; color: inherit; padding: 9px 0; -webkit-appearance: none; appearance: none; }
.phone-search input::-webkit-search-cancel-button { display: none; }
@media (min-width: 900px) { .phone-search { display: none !important; } }

/* Křížek na zavření oken: výraznější (tmavší kolečko i křížek), dotyková plocha o 4 px širší než vzhled */
.btn-close-modal { width: 36px; height: 36px; background-color: #D9DBE1; color: #1F2937; position: relative; }
.btn-close-modal::after { content: ''; position: absolute; inset: -4px; }
.btn-close-modal:active { background-color: #C4C7CF; }
.btn-close-modal .ic, .btn-close-modal svg { width: 17px; height: 17px; }
.btn-close-modal svg path, .btn-close-modal svg line { stroke-width: 2.6; }

/* Koš */
.trash-sub { text-align: center; margin: -6px 0 10px; }
.trash-row { background: #F8FAFC; border: 1px solid #E2E8F0; border-radius: 14px; padding: 10px 12px; margin-bottom: 8px; display: flex; flex-direction: column; gap: 8px; }
.trash-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.trash-main b { font-size: 14px; overflow-wrap: anywhere; color: #111827; }
.trash-main small { font-size: 12px; color: #6B7280; overflow-wrap: anywhere; }
.trash-btns { display: flex; gap: 8px; }
.trash-btn { flex: 1; min-width: 0; font-family: inherit; font-size: 13px; font-weight: 700; padding: 9px 8px; border-radius: 10px; border: none; cursor: pointer; overflow-wrap: anywhere; line-height: 1.2; }
.trash-btn.restore { background: #007AFF; color: #fff; }
.trash-btn.del { background: #FEE2E2; color: #B91C1C; }
.trash-btn:active { transform: scale(0.97); }
.trash-empty { width: 100%; margin-top: 8px; }
:root[data-theme-resolved="dark"] .trash-row { background: #1f2430; border-color: #2e3442; }
:root[data-theme-resolved="dark"] .trash-main b { color: #eceef1; }
:root[data-theme-resolved="dark"] .trash-main small { color: #9aa1ad; }
:root[data-theme-resolved="dark"] .trash-btn.del { background: #4a1f24; color: #fca5a5; }

/* Doživotní záruka, lhůta na vrácení, servis */
.duration-presets { flex-wrap: wrap; }
.preset-btn.preset-lifetime { flex: 1 1 100%; }
.ret-presets { flex-wrap: wrap; }
.ret-btn { flex: 1 1 0; min-width: 0; padding: 10px 4px; background-color: #F3F4F6; border: 1px solid #E5E7EB; border-radius: 10px; font-size: 13px; font-weight: 600; color: #4B5563; cursor: pointer; transition: all 0.15s; font-family: inherit; overflow-wrap: anywhere; line-height: 1.2; }
.ret-btn.active { background-color: var(--apple-blue); border-color: var(--apple-blue); color: #FFFFFF; }
.ret-banner { display: flex; align-items: center; gap: 10px; margin: 10px 0; padding: 12px 14px; border-radius: 14px; background: #FFF7ED; border: 1px solid #FED7AA; color: #9A3412; font-size: 14px; font-weight: 600; }
.ret-banner b { font-size: 15px; }
.ret-ic { font-size: 22px; flex: none; }
.svc-box { margin: 10px 0; }
.svc-title { font-weight: 700; font-size: 13px; margin-bottom: 6px; color: #374151; }
.svc-btns { display: flex; gap: 8px; }
.svc-btn { flex: 1 1 0; min-width: 0; text-align: center; padding: 12px 6px; border-radius: 12px; background: #EEF2FF; color: #3730A3; font-weight: 700; font-size: 14px; text-decoration: none; overflow-wrap: anywhere; }
.svc-btn:active { transform: scale(0.97); }
:root[data-theme-resolved="dark"] .ret-btn { background-color: #14161d; border: 1px solid #454c5d; color: #bec2c7; }
:root[data-theme-resolved="dark"] .ret-btn.active { background-color: var(--apple-blue); color: #FFFFFF; }
:root[data-theme-resolved="dark"] .ret-banner { background: #3a2a1c; border-color: #6b4a2a; color: #fdba74; }
:root[data-theme-resolved="dark"] .svc-title { color: #d1d5db; }
:root[data-theme-resolved="dark"] .svc-btn { background: #272a4d; color: #c7d2fe; }

/* První obrazovka a oslava první záruky */
.onboarding .onb-hero { width: 120px; height: 120px; border-radius: 27px; display: block; margin: 0 auto 16px; box-shadow: 0 14px 30px rgba(110, 20, 40, 0.28); animation: onbPop 0.6s ease both; }
@keyframes onbPop { 0% { transform: scale(0.6); opacity: 0; } 60% { transform: scale(1.06); opacity: 1; } 100% { transform: scale(1); } }
.onb-list { list-style: none; margin: 12px auto 20px; padding: 0; max-width: 320px; text-align: left; }
.onb-list li { display: flex; gap: 12px; align-items: center; padding: 8px 4px; font-size: 14.5px; font-weight: 600; color: #374151; }
.onb-list b { flex: none; width: 34px; height: 34px; border-radius: 10px; background: #fff; display: flex; align-items: center; justify-content: center; font-size: 18px; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); }
.empty-app .fab-btn { display: none !important; }
.first-joy { position: fixed; inset: 0; z-index: 3000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; background: rgba(15, 15, 25, 0.45); pointer-events: none; animation: joyIn 0.3s ease both; }
.first-joy img { border-radius: 22px; box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35); animation: onbPop 0.55s ease both; }
.first-joy span { color: #fff; font-weight: 800; font-size: 17px; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4); }
.first-joy.out { opacity: 0; transition: opacity 0.4s ease; }
@keyframes joyIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .onboarding .onb-hero, .first-joy img, .first-joy { animation: none; } }
:root[data-theme-resolved="dark"] .onb-list li { color: #d1d5db; }
:root[data-theme-resolved="dark"] .onb-list b { background: #1f2430; }

/* Detail záruky na telefonu: vše na jedné obrazovce (kruh vlevo, doklad jako náhled, tlačítka v řádku) */
.tile-action { cursor: pointer; }
.tile-action b { color: #2563EB !important; font-size: 13px !important; }
.tile-action::after { content: ''; }
.read-busy { bottom: 92px; }
@media (max-width: 899px) {
  #modalDetail .modal-card { padding: 12px 14px 14px !important; }
  #modalDetail .modal-header { margin-bottom: 8px !important; }
  #modalDetail .gl-hero-card { padding: 12px 12px 0 !important; }
  #modalDetail .gl-hero { flex-direction: row !important; align-items: center !important; text-align: left !important; gap: 12px !important; }
  #modalDetail .gl-ring { width: 92px !important; height: 92px !important; }
  #modalDetail .gl-ring-in { padding: 0 10px !important; }
  #modalDetail .gl-ring-in b { font-size: 30px !important; }
  #modalDetail .gl-ring-in small { font-size: 10px !important; margin-top: 2px !important; }
  #modalDetail .gl-hero-main { align-items: flex-start !important; }
  #modalDetail .gl-title { font-size: 20px !important; margin: 0 0 2px !important; }
  #modalDetail .gl-sub { font-size: 13px !important; }
  #modalDetail .gl-state { font-size: 12.5px !important; gap: 6px !important; flex-wrap: wrap; }
  #modalDetail .gl-meta { gap: 6px !important; margin: 10px -2px 12px !important; }
  #modalDetail .gl-meta div { padding: 7px 10px !important; border-radius: 12px !important; }
  #modalDetail .gl-meta b { font-size: 14px !important; margin-top: 1px !important; }
  #modalDetail .gl-meta small { font-size: 11px !important; }
  #modalDetail .detail-progress-wrapper { margin: 8px 0 6px !important; }
  #modalDetail #btnDetCal { padding: 9px !important; margin: 0 0 8px !important; font-size: 13px !important; }
  #modalDetail .detail-receipt-section label { font-size: 12.5px !important; margin-bottom: 4px !important; }
  #modalDetail .receipt-zoom-container { max-height: 170px !important; overflow: hidden !important; position: relative; }
  #modalDetail .claim-box { padding: 9px 12px !important; margin: 8px 0 !important; }
  #modalDetail .detail-footer-actions button { padding: 10px 4px !important; font-size: 13px !important; }
}

/* Okna musí jít vždy zavřít: výrazné tlačítko (světlé i tmavé téma) a druhé „Zavřít“ dole u dokladu */
.modal-overlay-zoom .btn-close-zoom, :root[data-theme-resolved="dark"] .modal-overlay-zoom .btn-close-zoom { top: calc(env(safe-area-inset-top, 0px) + 10px); right: 14px; width: 48px; height: 48px; background: #FFFFFF; color: #111827; font-size: 22px; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5); z-index: 5; }
.import-hide { display: block; margin: 14px auto 0; min-width: 140px; }

/* Hlášky a lišta čtení dokladů nesmí zachytávat klepnutí (dříve zakrývaly tlačítka pod sebou) */
.toast-message, .read-busy { pointer-events: none; }

/* Cena přečtená z dokladu je ke kontrole (≈), dokud ji člověk neuloží/nepotvrdí */
.tile-check b { color: #B45309 !important; }
.today-check { color: #B45309; font-weight: 700; }

/* Tlačítka v detailu na počítači: každé má svou přirozenou šířku, když se nevejdou vedle sebe, zalomí se na další řádek jako celek (nikdy se nerozlomí slovo, dříve „Reklamov / at“) */
#desktopDetailContent .gl-actions { display: flex !important; flex-wrap: wrap !important; gap: 8px !important; width: 100% !important; max-width: none !important; }
#desktopDetailContent .gl-actions .btn-action { flex: 1 1 auto !important; width: auto !important; min-width: 0 !important; flex-direction: row !important; align-items: center !important; justify-content: center !important; gap: 6px !important; white-space: nowrap !important; overflow-wrap: normal !important; word-break: normal !important; font-size: 13px !important; padding: 10px 12px !important; line-height: 1.2; }

/* Stav čtení dokladu nahoře v okně Upravit/Přidat (v běžném toku, nic nelepí) */
.scan-status-top { position: static; margin: 0 0 12px; font-size: 14px; }
.scan-status-top.busy::before { content: ''; display: inline-block; width: 12px; height: 12px; margin-right: 8px; vertical-align: -1px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite; }
@media (prefers-reduced-motion: reduce) { .scan-status-top.busy::before { animation: none; } }
:root[data-theme-resolved="dark"] .scan-status-top.busy { background: #172554; color: #93C5FD; }
:root[data-theme-resolved="dark"] .scan-status-top.ok { background: #052e22; color: #6ee7b7; }
:root[data-theme-resolved="dark"] .scan-status-top.warn { background: #3a2a1c; color: #fdba74; }

/* Náhled dokladu nahoře v okně Upravit (pro porovnání s předvyplněnými údaji) */
.edit-doc-preview { margin: 0 0 14px; border: 1px solid #E5E7EB; border-radius: 14px; background: #FFFFFF; overflow: hidden; cursor: zoom-in; }
.edit-doc-preview .edp-label { padding: 7px 12px; font-size: 12px; font-weight: 700; color: #6B7280; background: #F3F4F6; }
.edit-doc-preview img { display: block; width: 100%; max-height: 190px; object-fit: cover; object-position: top; background: #fff; }
:root[data-theme-resolved="dark"] .edit-doc-preview { background: #14161d; border-color: #2e3442; }
:root[data-theme-resolved="dark"] .edit-doc-preview .edp-label { background: #1f2430; color: #9aa1ad; }

/* Okno Přidat/Upravit: dole rezerva, aby tlačítka Zrušit / Uložit nikdy neležela těsně u spodního okraje a za lištou prohlížeče */
#modalAdd .modal-card { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)) !important; }

/* Okna se řídí SKUTEČNĚ VIDITELNOU výškou (bez spodní lišty Safari, klávesnice apod.), proměnná --app-h se počítá v app.js z visualViewport.
   Okno tak nikdy nezasáhne pod lištu; obsah, který se nevejde, se uvnitř okna posouvá a dole je rezerva. */
.modal-overlay { height: var(--app-h, 100dvh); top: var(--app-top, 0px); bottom: auto; }
.modal-overlay-zoom { height: var(--app-h, 100dvh); top: var(--app-top, 0px); bottom: auto; }
.modal-card { max-height: calc(var(--app-h, 100dvh) - 12px) !important; }
#modalAdd .modal-card { max-height: calc(var(--app-h, 100dvh) - 12px) !important; padding-bottom: calc(40px + env(safe-area-inset-bottom, 0px)) !important; }

/* Čitelnost: tlačítka „Zahájit reklamaci“ a „Smazat“ měla slabý kontrast textu */
.btn-claim-toggle { background-color: #B45309 !important; color: #FFFFFF !important; }
.btn-action-danger { color: #B91C1C !important; }

/* Plynulost na telefonu (iPhone Safari): drahé efekty jsou pryč nebo levnější. Rozmazání pozadí (backdrop-filter) přes posouvaný seznam,
   pevné pozadí z barevných přechodů a 67 velkých stínů nutí telefon při posouvání překreslovat stále dokola. */
@media (max-width: 899px) {
  .app-header, .bottom-nav, .modal-card, .modal-overlay, .modal-overlay-zoom, .toast-message, .undo-bar, .drag-drop-overlay {
    -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
  }
  .app-header { background: rgba(244, 247, 254, 0.97) !important; }
  .bottom-nav { background-color: rgba(255, 255, 255, 0.995) !important; box-shadow: 0 4px 14px rgba(60, 80, 140, 0.18) !important; }
  .modal-card { background-color: rgba(255, 255, 255, 0.99) !important; }
  .modal-overlay { background-color: rgba(15, 23, 42, 0.5) !important; }
  .expires-row { box-shadow: 0 2px 8px rgba(60, 80, 140, 0.07) !important; content-visibility: auto; contain-intrinsic-size: auto 78px; }
  html:not([data-theme-resolved="dark"]), html:not([data-theme-resolved="dark"]) body { background: #eef2f9 !important; background-attachment: scroll !important; }
  html:not([data-theme-resolved="dark"]) body::before {
    content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
    background: radial-gradient(700px 480px at 10% 0%, #cfe3ff 0, transparent 60%), radial-gradient(600px 420px at 100% 25%, #e6d6ff 0, transparent 55%), radial-gradient(600px 500px at 50% 100%, #c9f1e4 0, transparent 55%);
    transform: translateZ(0);
  }
  :root[data-theme-resolved="dark"] .app-header { background: rgba(16, 18, 23, 0.97) !important; }
  :root[data-theme-resolved="dark"] .bottom-nav { background-color: rgba(24, 27, 34, 0.97) !important; }
  :root[data-theme-resolved="dark"] .modal-card { background-color: rgb(24, 27, 34) !important; }
}

/* Při otevřeném okně je spodní lišta aplikace (Domů, Kalendář, Archiv, Nastavení) skrytá, aby neprobliknula pod oknem při vysouvání lišty Safari */
body:has(.modal-overlay[style*="flex"]) .bottom-nav, body:has(.modal-overlay-zoom[style*="flex"]) .bottom-nav { visibility: hidden !important; }

/* Rychlé tažení prstem: okno ani stránka pod ním se nesmí „odlepit“ a protáhnout (gumový efekt), stránka pod oknem stojí */
.modal-overlay, .modal-overlay-zoom, .modal-card { overscroll-behavior: none; }
html:has(.modal-overlay[style*="flex"]), body:has(.modal-overlay[style*="flex"]) { overflow: hidden !important; overscroll-behavior: none; }
.modal-overlay { touch-action: pan-y; }
.modal-overlay-zoom { touch-action: none; }

/* Upozornění na odhadnuté datum (import) */
.date-check-banner { background: #FEF3C7; border-color: #F59E0B; color: #78350F; }
.date-check-banner .date-check-btn { margin-top: 8px; min-height: 40px; padding: 8px 16px; border: 0; border-radius: 10px; background: #B45309; color: #fff; font-weight: 700; font-size: 15px; }
:root[data-theme-resolved="dark"] .date-check-banner { background: #3B2A0A; border-color: #B45309; color: #FDE68A; }

/* Telefon: pět filtrů pevně nahoře, stejně velkých, bez posouvání; krátká slova, barvy podle významu; nižší řádky záruk (písmo beze změny) */
@media (max-width: 899px) {
  .filter-chips { display: grid !important; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; overflow: visible !important; }
  .filter-chips .chip { padding: 11px 0 !important; text-align: center; font-size: 15px !important; font-weight: 700 !important; border-radius: 14px !important; min-width: 0; overflow: hidden; white-space: nowrap; }
  .filter-chips .chip[data-filter="active"]:not(.active) { color: #047857 !important; }
  .filter-chips .chip[data-filter="expiring"]:not(.active) { color: #8A6A00 !important; background: #FEF3B0 !important; border-color: #F2D45C !important; }
  .filter-chips .chip[data-filter="expired"]:not(.active) { color: #B91C1C !important; }
  .filter-chips .chip[data-filter="claimed"]:not(.active) { color: #6D28D9 !important; }
  .filter-chips .chip.active[data-filter="active"] { background: #047857 !important; color: #FFFFFF !important; border-color: transparent !important; }
  .filter-chips .chip.active[data-filter="expiring"] { background: #F5C400 !important; color: #3D2F00 !important; border-color: transparent !important; }
  .filter-chips .chip.active[data-filter="expired"] { background: #B91C1C !important; color: #FFFFFF !important; border-color: transparent !important; }
  .filter-chips .chip.active[data-filter="claimed"] { background: #6D28D9 !important; color: #FFFFFF !important; border-color: transparent !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="active"]:not(.active) { color: #34D399 !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="expiring"]:not(.active) { color: #FACC15 !important; background: rgba(250, 204, 21, 0.14) !important; border-color: rgba(250, 204, 21, 0.4) !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="expired"]:not(.active) { color: #F87171 !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="claimed"]:not(.active) { color: #A78BFA !important; }
  .expires-row { padding-top: 6px !important; padding-bottom: 6px !important; }
  .expires-items-list { gap: 8px !important; }
}
@media (max-width: 340px) { .filter-chips { gap: 4px; } .filter-chips .chip { font-size: 13px !important; } }

/* Telefon: nahoře čtyři filtry (Vše, Aktiv, Brzy, Vady), dole lišta ze čtyř stejných dlaždic (Domů, Kalendář, Konec, Nastavení) */
@media (max-width: 899px) {
  .filter-chips { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
  .filter-chips .chip[data-filter="expired"] { display: none !important; }
  nav.bottom-nav {
    left: 50% !important; right: auto !important; transform: translateX(-50%) !important; width: 100% !important; max-width: 420px !important; height: auto !important;
    display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; align-items: stretch;
    padding: 8px 14px calc(8px + var(--safe-bottom)) !important; margin: 0 !important; border: 0 !important; border-radius: 0 !important;
    background: rgba(238, 242, 249, 0.96) !important; box-shadow: 0 -6px 18px rgba(60, 80, 140, 0.10) !important;
  }
  nav.bottom-nav .nav-item { display: block !important; padding: 12px 0 !important; min-width: 0; text-align: center; font-size: 15px !important; font-weight: 700 !important; border-radius: 14px !important;
    background: rgba(255, 255, 255, 0.9) !important; border: 1px solid rgba(255, 255, 255, 0.95) !important; color: #334155 !important; gap: 0 !important; }
  nav.bottom-nav .nav-item svg { display: none !important; }
  nav.bottom-nav .nav-item span { font-size: 15px !important; font-weight: 700 !important; max-width: 100%; overflow: hidden; text-overflow: clip; white-space: nowrap; display: block; }
  nav.bottom-nav .nav-item.nav-expired { color: #B91C1C !important; }
  nav.bottom-nav .nav-item.active { background: linear-gradient(135deg, #2563eb, #4f46e5) !important; border-color: transparent !important; color: #FFFFFF !important; }
  nav.bottom-nav .nav-item.nav-expired.active { background: #B91C1C !important; color: #FFFFFF !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav { background: rgba(16, 18, 23, 0.97) !important; box-shadow: 0 -6px 18px rgba(0, 0, 0, 0.4) !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item { background: #1b1f29 !important; border-color: rgba(255, 255, 255, 0.10) !important; color: #cbd5e1 !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item.nav-expired { color: #F87171 !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item.active { background: linear-gradient(135deg, #2563eb, #4f46e5) !important; color: #FFFFFF !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item.nav-expired.active { background: #B91C1C !important; }
  .fab-btn { bottom: calc(84px + var(--safe-bottom)) !important; }
  .expires-items-list { padding-bottom: 150px !important; }
}
@media (max-width: 340px) { nav.bottom-nav { gap: 4px; } nav.bottom-nav .nav-item span { font-size: 13px !important; } }

/* Telefon: barevná pozadí dlaždic (pastel, text ve stejné barvě), písmo se přizpůsobí šířce displeje, aby se vešlo slovo „Reklamace“ */
@media (max-width: 899px) {
  .filter-chips .chip, nav.bottom-nav .nav-item, nav.bottom-nav .nav-item span { font-size: min(15px, 3.6vw) !important; }
  .filter-chips .chip[data-filter="all"]:not(.active) { background: #E0E7FF !important; border-color: #C7D2FE !important; color: #3730A3 !important; }
  .filter-chips .chip[data-filter="active"]:not(.active) { background: #D1FAE5 !important; border-color: #A7F3D0 !important; color: #047857 !important; }
  .filter-chips .chip[data-filter="expiring"]:not(.active) { background: #FEF3B0 !important; border-color: #F2D45C !important; color: #8A6A00 !important; }
  .filter-chips .chip[data-filter="claimed"]:not(.active) { background: #FEE2E2 !important; border-color: #FECACA !important; color: #B91C1C !important; }
  .filter-chips .chip.active[data-filter="claimed"] { background: #B91C1C !important; color: #FFFFFF !important; border-color: transparent !important; }
  nav.bottom-nav .nav-item[data-nav="home"]:not(.active) { background: #E0E7FF !important; border-color: #C7D2FE !important; color: #3730A3 !important; }
  nav.bottom-nav .nav-item[data-nav="calendar"] { background: #EDE9FE !important; border-color: #DDD6FE !important; color: #6D28D9 !important; }
  nav.bottom-nav .nav-item[data-nav="expired"]:not(.active) { background: #FEE2E2 !important; border-color: #FECACA !important; color: #B91C1C !important; }
  nav.bottom-nav .nav-item[data-nav="settings"] { background: #E5E7EB !important; border-color: #D1D5DB !important; color: #374151 !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="all"]:not(.active) { background: rgba(129, 140, 248, 0.18) !important; border-color: rgba(129, 140, 248, 0.4) !important; color: #C7D2FE !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="active"]:not(.active) { background: rgba(52, 211, 153, 0.16) !important; border-color: rgba(52, 211, 153, 0.4) !important; color: #6EE7B7 !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="expiring"]:not(.active) { background: rgba(250, 204, 21, 0.14) !important; color: #FACC15 !important; }
  :root[data-theme-resolved="dark"] .filter-chips .chip[data-filter="claimed"]:not(.active) { background: rgba(248, 113, 113, 0.16) !important; border-color: rgba(248, 113, 113, 0.4) !important; color: #FCA5A5 !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item[data-nav="home"]:not(.active) { background: rgba(129, 140, 248, 0.18) !important; border-color: rgba(129, 140, 248, 0.4) !important; color: #C7D2FE !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item[data-nav="calendar"] { background: rgba(167, 139, 250, 0.18) !important; border-color: rgba(167, 139, 250, 0.4) !important; color: #DDD6FE !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item[data-nav="expired"]:not(.active) { background: rgba(248, 113, 113, 0.16) !important; border-color: rgba(248, 113, 113, 0.4) !important; color: #FCA5A5 !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav .nav-item[data-nav="settings"] { background: #252a35 !important; border-color: rgba(255, 255, 255, 0.12) !important; color: #E5E7EB !important; }
}

/* Telefon: místo velké karty „Co řešit teď“ tři ploché dlaždice (tvar jako tlačítko „Zálohovat teď“), menší mezery nad seznamem */
.today-tiles { display: none; }
@media (max-width: 899px) {
  #attentionBanner.today-card { background: transparent !important; box-shadow: none !important; border: 0 !important; padding: 8px 0 0 !important; margin: 0 !important; }
  #attentionBanner .today-full { display: none !important; }
  #attentionBanner .today-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  #attentionBanner .tt { display: flex; align-items: center; justify-content: center; height: 26px; padding: 0 4px; border: 0; border-radius: 10px; font-size: min(12.5px, 3.3vw); font-weight: 700; font-family: inherit; white-space: nowrap; overflow: hidden; min-width: 0; cursor: pointer; }
  @media (max-width: 384px) { #attentionBanner .tt-ic { display: none; } }
  #attentionBanner .tt-ok { background: #D1FAE5; color: #047857; }
  #attentionBanner .tt-soon { background: #FEF3B0; color: #8A6A00; }
  #attentionBanner .tt-active { background: #E0E7FF; color: #3730A3; }
  #attentionBanner .tt-value { background: #E2E8F0; color: #334155; cursor: default; }
  :root[data-theme-resolved="dark"] #attentionBanner .tt-ok { background: rgba(52, 211, 153, 0.16); color: #6EE7B7; }
  :root[data-theme-resolved="dark"] #attentionBanner .tt-soon { background: rgba(250, 204, 21, 0.16); color: #FACC15; }
  :root[data-theme-resolved="dark"] #attentionBanner .tt-active { background: rgba(129, 140, 248, 0.18); color: #C7D2FE; }
  :root[data-theme-resolved="dark"] #attentionBanner .tt-value { background: #252a35; color: #E5E7EB; }
  .app-header.expires-mid-header { padding-bottom: 6px !important; }
  .filter-chips { padding-bottom: 0 !important; }
  .expires-timeline-container { padding-top: 0 !important; }
  .expires-items-list { padding-top: 8px !important; }
}

/* Telefon: všechno (vyhledávání, filtry, dlaždice, záruky, dolní lišta) začíná i končí 14 px od kraje; název uprostřed; štítky u záruk jsou obdélníky místo kruhů */
@media (max-width: 899px) {
  .app-header.expires-mid-header { padding-left: 14px !important; padding-right: 14px !important; padding-bottom: 8px !important; }
  .app-header .phone-search, .app-header .filter-chips { margin-left: 0 !important; margin-right: 0 !important; }
  .expires-timeline-container { padding-left: 0 !important; padding-right: 0 !important; }
  .expires-items-list { padding-left: 14px !important; padding-right: 14px !important; padding-top: 2px !important; }
  .app-header .header-top-row { justify-content: flex-start !important; }
  .app-header .header-title { text-align: left; width: auto; padding-left: 6px; }
  .expires-row { padding-top: 5px !important; padding-bottom: 5px !important; }
  .expires-row .donut-ring { width: 54px !important; height: 26px !important; flex: 0 0 54px !important; border-radius: 10px !important; display: flex !important; align-items: center; justify-content: center; }
  .expires-row .donut-ring svg { display: none !important; }
  .expires-row .donut-ring .donut-label { position: static !important; transform: none !important; font-size: 11px !important; letter-spacing: 0 !important; font-weight: 800 !important; white-space: nowrap; }
  .expires-row .donut-ring.rb-active { background: #D1FAE5; } .expires-row .donut-ring.rb-active .donut-label { color: #047857 !important; }
  .expires-row .donut-ring.rb-soon { background: #FEF3B0; } .expires-row .donut-ring.rb-soon .donut-label { color: #8A6A00 !important; }
  .expires-row .donut-ring.rb-expired { background: #FEE2E2; } .expires-row .donut-ring.rb-expired .donut-label { color: #B91C1C !important; }
  .expires-row .donut-ring.rb-unknown { background: #E5E7EB; } .expires-row .donut-ring.rb-unknown .donut-label { color: #475569 !important; }
  :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-active { background: rgba(52, 211, 153, 0.16); } :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-active .donut-label { color: #6EE7B7 !important; }
  :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-soon { background: rgba(250, 204, 21, 0.16); } :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-soon .donut-label { color: #FACC15 !important; }
  :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-expired { background: rgba(248, 113, 113, 0.16); } :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-expired .donut-label { color: #FCA5A5 !important; }
  :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-unknown { background: #252a35; } :root[data-theme-resolved="dark"] .expires-row .donut-ring.rb-unknown .donut-label { color: #CBD5E1 !important; }
}

/* Telefon (schválený vzhled): horní část a dolní lišta jsou velké zaoblené dlaždice stejné šířky jako záruky; každá záruka je jedna dlaždice (14 px zaoblení) stejné výšky,
   s barevným štítkem uvnitř; pod dolní lištou je čisté pozadí; záloha má mezery 8/6 px */
@media (max-width: 899px) {
  :root { --colw: calc((min(100vw, 420px) - 46px) / 4); --page-bg: #EEF2F9; }
  :root[data-theme-resolved="dark"] { --page-bg: #27303f; }
  .app-header.expires-mid-header { margin: 10px 14px 8px !important; padding: 10px !important; border-radius: 18px !important; background: rgba(255, 255, 255, 0.88) !important; box-shadow: 0 2px 12px rgba(60, 80, 140, 0.10) !important; border: 1px solid rgba(255, 255, 255, 0.95) !important; position: static !important; }
  :root[data-theme-resolved="dark"] .app-header.expires-mid-header { background: rgba(24, 27, 34, 0.94) !important; border-color: rgba(255, 255, 255, 0.08) !important; box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35) !important; }
  .app-header .header-top-row { margin-bottom: 6px; }
  .expires-row { border-radius: 14px !important; padding: 4px 12px 4px 4px !important; gap: 10px !important; align-items: stretch !important; min-height: 55px !important; box-sizing: border-box; }
  .expires-row .donut-ring { width: calc(var(--colw) - 8px) !important; flex: 0 0 calc(var(--colw) - 8px) !important; height: auto !important; min-height: 0 !important; border-radius: 10px !important; align-self: stretch !important; }
  .expires-row .er-body { align-self: center; padding: 2px 0 !important; }
  .expires-row .er-right { align-self: center; }
  .expires-items-list { gap: 6px !important; padding-top: 0 !important; }
  #backupBar { margin: 0 14px 6px !important; border-radius: 14px !important; }
  body::after { content: ''; position: fixed; left: 0; right: 0; bottom: 0; height: calc(10px + 62px + env(safe-area-inset-bottom, 0px) + 8px); background: var(--page-bg); z-index: 79; pointer-events: none; }
  nav.bottom-nav { left: 50% !important; transform: translateX(-50%) !important; width: calc(min(100vw, 420px) - 28px) !important; max-width: none !important; right: auto !important; bottom: calc(10px + env(safe-area-inset-bottom, 0px)) !important; padding: 8px !important; border-radius: 18px !important; background: rgba(255, 255, 255, 0.92) !important; box-shadow: 0 4px 18px rgba(60, 80, 140, 0.18) !important; border: 1px solid rgba(255, 255, 255, 0.95) !important; height: auto !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav { background: rgba(24, 27, 34, 0.96) !important; border-color: rgba(255, 255, 255, 0.08) !important; box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4) !important; }
  .fab-btn { bottom: calc(92px + var(--safe-bottom)) !important; }
  .expires-items-list { padding-bottom: 130px !important; }
}

/* Telefon: záruky zajíždějí přímo za dolní lištu; kolem a pod lištou je čisté pozadí (neviditelná podložka přesně od horní hrany lišty dolů) */
@media (max-width: 899px) {
  body::after { display: none !important; }
  nav.bottom-nav::before { content: ''; position: absolute; left: -100vw; right: -100vw; top: -1px; bottom: calc(-1 * (10px + env(safe-area-inset-bottom, 0px) + 40px)); background: var(--page-bg); z-index: -2; pointer-events: auto; }
  nav.bottom-nav::after { content: ''; position: absolute; inset: 0; border-radius: 18px; background: rgba(255, 255, 255, 0.96); border: 1px solid rgba(255, 255, 255, 0.95); box-shadow: 0 4px 18px rgba(60, 80, 140, 0.18); z-index: -1; pointer-events: none; }
  nav.bottom-nav { background: transparent !important; border-color: transparent !important; box-shadow: none !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav { background: transparent !important; box-shadow: none !important; }
  :root[data-theme-resolved="dark"] nav.bottom-nav::after { background: rgba(24, 27, 34, 0.98); border-color: rgba(255, 255, 255, 0.08); box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4); }
}

/* Telefon: dlaždice záruk jsou o 4 px na každé straně užší než dolní lišta (lišta je vidět jako širší vrstva, pod kterou záruky zajíždějí) */
@media (max-width: 899px) {
  .expires-items-list { padding-left: 18px !important; padding-right: 18px !important; }
}

/* Telefon: horní dlaždice zůstává na místě a záruky při posouvání zajíždějí za ni (stejný princip jako dole): neviditelná podložka od horního okraje obrazovky až po spodní hranu dlaždice */
@media (max-width: 899px) {
  .app-header.expires-mid-header { position: sticky !important; top: 10px !important; z-index: 100 !important; background: transparent !important; border-color: transparent !important; box-shadow: none !important; }
  .app-header.expires-mid-header::before { content: ''; position: absolute; left: -100vw; right: -100vw; top: -300px; bottom: 0; background: var(--page-bg); z-index: -2; pointer-events: auto; }
  .app-header.expires-mid-header::after { content: ''; position: absolute; inset: 0; border-radius: 18px; background: rgba(255, 255, 255, 0.92); border: 1px solid rgba(255, 255, 255, 0.95); box-shadow: 0 2px 12px rgba(60, 80, 140, 0.10); z-index: -1; pointer-events: none; }
  :root[data-theme-resolved="dark"] .app-header.expires-mid-header { background: transparent !important; }
  :root[data-theme-resolved="dark"] .app-header.expires-mid-header::after { background: rgba(24, 27, 34, 0.94); border-color: rgba(255, 255, 255, 0.08); box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35); }
}
@media (max-width: 899px) {
  .app-container { overflow: clip !important; }
}

/* Telefon: tlačítko „+“ je malý zaoblený obdélník v pravém horním rohu horní dlaždice (nic nepřekrývá záruky) */
@media (max-width: 899px) {
  .app-header .fab-btn { position: absolute !important; right: 11px !important; top: 9px !important; left: auto !important; bottom: auto !important; transform: none !important; width: 42px !important; height: 42px !important; border-radius: 14px !important; background: linear-gradient(135deg, #2563eb, #4f46e5) !important; box-shadow: 0 3px 10px rgba(37, 99, 235, 0.35) !important; z-index: 2; display: grid; place-items: center; }
  .app-header .fab-btn:active { transform: scale(0.94) !important; }
  .app-header .fab-btn svg { width: 22px; height: 22px; }
  .empty-app .app-header .fab-btn { display: none !important; }
}
