/* Brani návody – Jipos.cz */

@page { size: A4 portrait; margin: 12mm; }
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Segoe UI', Arial, sans-serif;
  background: #fff; color: #2C3E50;
  max-width: 960px; margin: 0 auto; padding: 16px 24px 16px;
  -webkit-print-color-adjust: exact; print-color-adjust: exact;
}

/* ====== NAV ====== */
.tab-nav { position: sticky; top: 0; z-index: 100; background: #fff; border-bottom: 1px solid #E8ECF0; margin: -16px -24px 16px; }
.tab-nav-inner { max-width: 960px; margin: 0 auto; display: flex; align-items: center; gap: 6px; padding: 10px 24px; flex-wrap: wrap; }
.tab-btn { border: none; background: #F0F3F5; color: #5D6D7E; font-size: 13px; font-weight: 600; padding: 8px 16px; border-radius: 8px; cursor: pointer; transition: all .15s; font-family: inherit; white-space: nowrap; }
.tab-btn:hover { background: #E8ECF0; color: #2C3E50; }
.tab-btn.active { background: var(--accent, #1A5276); color: #fff; }
.print-btn { margin-left: auto; border: 1px solid #BDC3C7; background: #fff; color: #5D6D7E; font-size: 13px; font-weight: 600; padding: 7px 16px; border-radius: 8px; cursor: pointer; display: flex; align-items: center; gap: 6px; font-family: inherit; transition: all .15s; }
.print-btn:hover { background: #F0F3F5; color: #2C3E50; }
.print-btn svg { flex-shrink: 0; }

/* ====== PANELS ====== */
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ====== HEADER ====== */
.header { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; padding-bottom: 12px; border-bottom: 3px solid; }
.header-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.header-icon svg { width: 28px; height: 28px; }
.header h1 { font-size: 24px; font-weight: 700; line-height: 1.2; }
.header p { font-size: 12px; color: #7F8C8D; margin-top: 2px; }
.header-badge { margin-left: auto; font-size: 12px; font-weight: 600; padding: 6px 14px; border-radius: 8px; white-space: nowrap; }

/* ====== STEPS ====== */
.steps { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.step { display: flex; gap: 10px; padding: 12px 14px; border-radius: 10px; background: #F8F9FA; border: 1px solid #E8ECF0; }
.step-num {
  width: 34px; height: 34px; border-radius: 50%;
  background: #FDE8E8 !important;
  color: #CA1517 !important; font-size: 16px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; margin-top: 0;
  border: 2px solid #CA1517;
  letter-spacing: -0.5px;
}
.step-icon { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.step-icon svg { width: 22px; height: 22px; }
.step-content { flex: 1; min-width: 0; }
.step-title { font-size: 13px; font-weight: 700; color: #2C3E50; margin-bottom: 3px; line-height: 1.3; }
.step-desc { font-size: 11px; color: #5D6D7E; line-height: 1.5; }
.step-highlight { background: #FEF9E7; border-color: #F9E79F; }
.step-gift { background: #F5EEF8; border-color: #D2B4DE; }
.step-return { background: #F5EEF8; border-color: #D2B4DE; }
.step-danger { background: #FDEDEC; border-color: #F5B7B1; }
.step-full { grid-column: 1 / -1; }

/* ====== ICON BG ====== */
.ic-blue { background: #D6EAF8; } .ic-green { background: #D5F5E3; } .ic-orange { background: #FDEBD0; }
.ic-teal { background: #D1F2EB; } .ic-purple { background: #E8DAEF; } .ic-red { background: #FADBD8; } .ic-yellow { background: #FEF9E7; }

/* ====== FLOW DIAGRAM ====== */
.flow-diagram {
  display: flex; align-items: center; justify-content: center;
  gap: 6px; background: #F0F3F5; border-radius: 10px;
  padding: 10px 12px; margin-bottom: 12px; flex-wrap: wrap;
}
.flow-node { text-align: center; padding: 6px 10px; border-radius: 8px; font-size: 9.5px; font-weight: 600; line-height: 1.3; min-width: 72px; }
.flow-node svg { display: block; margin: 0 auto 3px; width: 24px; height: 24px; }
.fn-blue { background: #D6EAF8; color: #1A5276; } .fn-green { background: #D5F5E3; color: #1E8449; }
.fn-orange { background: #FDEBD0; color: #B7950B; } .fn-teal { background: #D1F2EB; color: #0E6655; }
.fn-purple { background: #E8DAEF; color: #6C3483; } .fn-red { background: #FADBD8; color: #922B21; }
.flow-arr { color: #95A5A6; font-size: 16px; flex-shrink: 0; }

/* ====== MODE NOTE ====== */
.mode-note { border-radius: 10px; padding: 10px 14px; margin-bottom: 12px; display: flex; align-items: flex-start; gap: 10px; }
.mode-note svg { flex-shrink: 0; margin-top: 1px; }
.mode-note-text { font-size: 12px; line-height: 1.5; }

/* ====== SECTION DIVIDER ====== */
.section-divider { font-size: 13px; font-weight: 700; margin: 10px 0 6px; padding: 4px 0; display: flex; align-items: center; gap: 6px; }
.section-divider svg { width: 16px; height: 16px; flex-shrink: 0; }

/* ====== INFO BOXES ====== */
.bottom-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; }
.info-box { padding: 12px 14px; border-radius: 10px; border: 1px solid; }
.info-box h3 { font-size: 12px; font-weight: 700; margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.info-box ul { list-style: none; padding: 0; }
.info-box li { font-size: 10.5px; line-height: 1.55; padding-left: 14px; position: relative; color: #34495E; }
.info-box li::before { content: ''; position: absolute; left: 0; top: 7px; width: 6px; height: 6px; border-radius: 50%; }

.box-warn { background: #FEF9E7; border-color: #F9E79F; } .box-warn h3 { color: #B7950B; } .box-warn li::before { background: #F39C12; }
.box-tip { background: #EBF5FB; border-color: #AED6F1; } .box-tip h3 { color: #1A5276; } .box-tip li::before { background: #2980B9; }
.box-error { background: #FDEDEC; border-color: #F5B7B1; } .box-error h3 { color: #922B21; } .box-error li::before { background: #E74C3C; }
.box-gift { background: #F5EEF8; border-color: #D2B4DE; } .box-gift h3 { color: #6C3483; } .box-gift li::before { background: #8E44AD; }
.box-return { background: #F5EEF8; border-color: #D2B4DE; } .box-return h3 { color: #6C3483; } .box-return li::before { background: #8E44AD; }
.box-purple { background: #F5EEF8; border-color: #D2B4DE; } .box-purple h3 { color: #6C3483; } .box-purple li::before { background: #8E44AD; }
.box-green { background: #D5F5E3; border-color: #A9DFBF; } .box-green h3 { color: #1E8449; } .box-green li::before { background: #27AE60; }

/* ====== FOOTER ====== */
.footer { text-align: center; font-size: 9px; color: #AEB6BF; padding-top: 8px; border-top: 1px solid #E8ECF0; margin-top: 6px; }


/* ============================================================
   TABLET (max 768px)
   ============================================================ */
@media (max-width: 768px) {
  body { padding: 12px 16px; }
  .tab-nav { margin: -12px -16px 14px; }
  .tab-nav-inner { padding: 8px 16px; gap: 4px; overflow-x: auto; -webkit-overflow-scrolling: touch; flex-wrap: nowrap; }
  .tab-btn { font-size: 12px; padding: 7px 12px; flex-shrink: 0; }
  .print-btn { font-size: 12px; padding: 6px 12px; flex-shrink: 0; }

  .header { flex-wrap: wrap; gap: 10px; }
  .header h1 { font-size: 20px; }
  .header-badge { margin-left: 0; }

  .steps { grid-template-columns: 1fr; }
  .step-full { grid-column: 1; }

  .bottom-row { grid-template-columns: 1fr; }

  .flow-diagram { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .flow-node { flex-shrink: 0; }
}


/* ============================================================
   MOBIL (max 480px)
   ============================================================ */
@media (max-width: 480px) {
  body { padding: 8px 12px; }
  .tab-nav { margin: -8px -12px 10px; }
  .tab-nav-inner { padding: 6px 12px; gap: 4px; }
  .tab-btn { font-size: 11px; padding: 6px 10px; border-radius: 6px; }
  .print-btn { font-size: 11px; padding: 5px 10px; }

  .header { gap: 10px; padding-bottom: 8px; margin-bottom: 8px; }
  .header-icon { width: 40px; height: 40px; border-radius: 10px; }
  .header-icon svg { width: 22px; height: 22px; }
  .header h1 { font-size: 17px; }
  .header p { font-size: 10px; }
  .header-badge { font-size: 10px; padding: 4px 10px; }

  .mode-note { padding: 8px 10px; gap: 8px; }
  .mode-note-text { font-size: 10.5px; }

  .step { padding: 10px; gap: 8px; border-radius: 8px; }
  .step-num { width: 36px; height: 36px; font-size: 17px; }
  .step-icon { width: 32px; height: 32px; border-radius: 6px; }
  .step-icon svg { width: 18px; height: 18px; }
  .step-title { font-size: 14px; margin-bottom: 3px; }
  .step-desc { font-size: 12px; }

  .flow-diagram { padding: 6px; gap: 3px; }
  .flow-node { min-width: 58px; padding: 5px 6px; font-size: 8px; }
  .flow-node svg { width: 20px; height: 20px; }

  .section-divider { font-size: 12px; }
  .info-box { padding: 8px 10px; }
  .info-box h3 { font-size: 11px; }
  .info-box li { font-size: 10.5px; }
  .footer { font-size: 8px; }
}


/* ============================================================
   PRINT
   ============================================================ */
@media print {
  .tab-nav { display: none !important; }
  .tab-panel { display: none !important; }
  .tab-panel.active { display: block !important; }
  body { padding: 0; margin: 0; max-width: 210mm; }
  .steps { grid-template-columns: 1fr 1fr; }
  .step-full { grid-column: 1 / -1; }
  .bottom-row { grid-template-columns: 1fr 1fr; }
  .step, .info-box, .flow-diagram, .section-divider { break-inside: avoid; }
}