* { box-sizing: border-box; }
body { font-family: system-ui, sans-serif; margin: 0; background: #f4f5f7; color: #1a1a1a; }
.container { max-width: 1000px; margin: 0 auto; padding: 1.5rem; }
.container.narrow { max-width: 560px; }
.topbar { display: flex; justify-content: space-between; align-items: center;
    background: #1f2937; color: #fff; padding: .8rem 1.5rem; }
.topbar a { color: #93c5fd; text-decoration: none; }
.card { background: #fff; border-radius: 10px; padding: 1.2rem 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,.1); margin-bottom: 1.5rem; }
h1, h2 { margin-top: 0; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .5rem .6rem; border-bottom: 1px solid #eee; vertical-align: top; }
th { font-size: .8rem; text-transform: uppercase; color: #6b7280; }
button, .btn { background: #2563eb; color: #fff; border: 0; border-radius: 6px;
    padding: .5rem .9rem; font-size: .9rem; cursor: pointer; text-decoration: none;
    display: inline-block; }
button:hover, .btn:hover { background: #1d4ed8; }
.grid-form { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem 1rem; align-items: end; }
.grid-form label { display: flex; flex-direction: column; font-size: .85rem; gap: .25rem; }
.grid-form .full { grid-column: 1 / -1; }
.grid-form input, .grid-form textarea, .login-card input {
    padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font: inherit; }
.grid-form button { grid-column: 1 / -1; justify-self: start; }

/* login */
.login-page { display: flex; min-height: 100vh; align-items: center; justify-content: center; }
.login-card { width: 320px; }
.login-card label { display: flex; flex-direction: column; gap: .25rem; margin-bottom: .8rem; }
.login-card button { width: 100%; }

/* tabs */
.tabs { display: flex; gap: .5rem; margin-bottom: 1rem; border-bottom: 1px solid #e5e7eb; }
.tabs a { padding: .5rem .9rem; text-decoration: none; color: #6b7280; border-bottom: 2px solid transparent; }
.tabs a.active { color: #2563eb; border-bottom-color: #2563eb; font-weight: 600; }

/* public trips */
.trip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.2rem; }
.trip-date { font-size: .85rem; color: #6b7280; }
.trip .price { font-size: 1.3rem; font-weight: 700; }
.trip .avail { font-size: .85rem; color: #059669; }

.actions { display: flex; gap: .4rem; flex-wrap: wrap; }
.actions form { margin: 0; }
.actions button { font-size: .78rem; padding: .3rem .5rem; background: #475569; }
.meta { color: #6b7280; }
.error { color: #b91c1c; } .ok, .price { color: #059669; }

/* editace / filtr – doplněk */
button.danger, .btn.danger { background: #b91c1c; }
button.danger:hover, .btn.danger:hover { background: #991b1b; }
.btn-secondary { background: #6b7280; }
.btn-secondary:hover { background: #4b5563; }
.filter-form select, .filter-form input { padding: .5rem; border: 1px solid #cbd5e1;
    border-radius: 6px; font: inherit; }
.filter-actions { display: flex; gap: .6rem; align-items: center; }
.filter-actions button { grid-column: auto; }

/* Quill editor + vykreslený obsah popisu */
.quill-editor { background: #fff; min-height: 180px; }
.ql-toolbar.ql-snow, .ql-container.ql-snow { border-color: #cbd5e1; }
.ql-container.ql-snow { border-bottom-left-radius: 6px; border-bottom-right-radius: 6px; }
.ql-toolbar.ql-snow { border-top-left-radius: 6px; border-top-right-radius: 6px; }
.rte-content img { max-width: 100%; height: auto; border-radius: 6px; }
.rte-content { line-height: 1.5; }
.rte-content h1, .rte-content h2, .rte-content h3 { margin: .6em 0 .3em; }
.rte-content p { margin: .4em 0; }

/* ============ VEŘEJNÝ WEB – vzhled podle hlavního webu ============ */
:root { --brand: #1f3a93; --brand-dark: #17296b; }

body.public { background: #eef0f3; color: #2a2a2a; }
body.public .container { max-width: 1080px; }
body.public .container.narrow { max-width: 760px; }
.page-title { color: #2a2a2a; font-size: 1.4rem; font-weight: 700; margin: 1rem 0 1.5rem; }

/* mřížka karet */
body.public .trip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.8rem; }
body.public .trip.card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.trip-thumb { display: block; aspect-ratio: 3/2; overflow: hidden; }
.trip-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.trip-body { padding: 1.1rem 1.3rem 1.4rem; display: flex; flex-direction: column; flex: 1; }
.trip-body h2 { font-size: 1.25rem; line-height: 1.25; margin: .2rem 0 .5rem; }
.trip-body h2 a { color: var(--brand); text-decoration: none; }
.trip-body h2 a:hover { text-decoration: underline; }
.trip-date { font-size: .8rem; color: #6b7280; text-transform: uppercase; letter-spacing: .02em; }
.trip-intro { font-size: .95rem; color: #374151; margin-bottom: .6rem; }
.trip-intro img { display: none; } /* obrázky vložené v intro textu v mřížce nezobrazujeme */
body.public .price { color: #e30016; font-size: 1.15rem; font-weight: 700; margin: .3rem 0; }
.avail-low { color: #d40000; font-weight: 700; font-size: .9rem; margin: .2rem 0 .4rem; }
.trip-actions { margin-top: auto; display: flex; flex-direction: column; gap: .6rem; align-items: flex-start; }
.readmore-link { color: var(--brand); font-weight: 600; text-decoration: none; border-bottom: 2px solid var(--brand); padding-bottom: 1px; }
.readmore-link:hover { color: var(--brand-dark); }
body.public .btn { background: var(--brand); }
body.public .btn:hover { background: var(--brand-dark); }

/* detail / článek */
.article.card { padding: 0; overflow: hidden; }
.article-hero { width: 100%; max-height: 460px; object-fit: cover; display: block; }
.article-body { padding: 1.5rem 1.8rem 2rem; }
.article-body h1 { color: var(--brand); font-size: 1.8rem; margin: .3rem 0 .6rem; }
.back-link { color: var(--brand); text-decoration: none; font-weight: 600; }
body.public #zajem h2 { color: var(--brand); }

/* oddělovač Číst dále v editoru */
.ql-editor hr.readmore, .rte-content hr.readmore { border: 0; border-top: 2px dashed #d40000; margin: 1em 0; position: relative; }
.ql-editor hr.readmore::after, .rte-content hr.readmore::after { content: "Číst dále"; position: absolute; top: -.7em; left: 50%; transform: translateX(-50%); background: #fff; color: #d40000; font-size: .7rem; padding: 0 .5rem; font-weight: 600; }

/* náhled úvodního obrázku v editaci */
.img-preview { margin-top: .6rem; }
.img-preview img { max-width: 220px; border-radius: 6px; display: block; margin-bottom: .4rem; }
.inline { display: inline-flex; align-items: center; gap: .4rem; font-size: .85rem; }

/* ===== Bod 1–5: doplňkové UI ===== */
/* sbalený formulář nového zájezdu */
details.new-trip > summary { display: inline-block; list-style: none; cursor: pointer; }
details.new-trip > summary::-webkit-details-marker { display: none; }
details.new-trip[open] > summary { margin-bottom: 1rem; }

/* klikací hlavičky řazení */
.sort-link { color: inherit; text-decoration: none; white-space: nowrap; }
.sort-link:hover { text-decoration: underline; }

/* image picker */
.field-label { display: block; font-size: .85rem; margin-bottom: .3rem; }
.image-picker-controls { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.file-btn { background: #2563eb; color: #fff; border-radius: 6px; padding: .5rem .9rem;
    font-size: .9rem; cursor: pointer; display: inline-block; }
.file-btn:hover { background: #1d4ed8; }
[data-image-preview] img { max-width: 240px; border-radius: 6px; margin-top: .6rem; display: block; }

/* galerie modal */
.gallery-modal { position: fixed; inset: 0; background: rgba(0,0,0,.5); display: flex;
    align-items: center; justify-content: center; z-index: 1000; }
.gallery-box { background: #fff; border-radius: 10px; width: min(760px, 92vw);
    max-height: 82vh; display: flex; flex-direction: column; overflow: hidden; }
.gallery-head { display: flex; justify-content: space-between; align-items: center;
    padding: .9rem 1.1rem; border-bottom: 1px solid #eee; }
.gallery-close { background: none; color: #6b7280; font-size: 1.1rem; padding: .2rem .5rem; }
.gallery-close:hover { color: #111; background: none; }
.gallery-grid { padding: 1rem; overflow-y: auto; display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .8rem; align-content: start; }
.gallery-item { padding: 0; border: 2px solid transparent; border-radius: 8px;
    overflow: hidden; background: #f4f5f7; cursor: pointer;
    display: flex; flex-direction: column; min-height: 150px; }
.gallery-item:hover { border-color: #2563eb; }
.gallery-item img { width: 100%; height: 120px; object-fit: contain; display: block; background: #fff; flex: none; }
.gallery-item-broken img { visibility: hidden; }
.gallery-item-broken::before { content: '⚠ obrázek nelze načíst'; display: flex; align-items: center;
    justify-content: center; height: 120px; font-size: .75rem; color: #999; background: #f0f0f0; }
.gallery-item-meta { font-size: .72rem; color: #444; padding: .3rem .4rem; word-break: break-all;
    line-height: 1.25; text-align: center; background: #fff; border-top: 1px solid #eee; }

/* ===== Modul plateb ===== */
.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; }
.flex-between { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.flex-between form { margin: 0; }
table.kv th { text-align: left; color: #6b7280; font-weight: 500; width: 40%; }
table.kv td { text-align: left; }
.pay-detail { display: flex; gap: 2rem; flex-wrap: wrap; align-items: flex-start; }
.pay-info { flex: 1 1 320px; }
.pay-qr { text-align: center; }
.pay-qr img { border: 1px solid #e5e7eb; border-radius: 8px; background: #fff; }
tr.pay-zaplaceno td { background: #f0fdf4; }
tr.pay-po_splatnosti td { background: #fef2f2; }
tr.pay-storno td { color: #9ca3af; text-decoration: line-through; }

/* nastavení – inline formuláře ve správcích */
.inline-form { display: inline-flex; gap: .3rem; align-items: center; margin: 0; }
.inline-form input[type=password] { padding: .35rem .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font: inherit; width: 130px; }

/* e-mailové šablony v nastavení */
label.block { display: block; margin-bottom: .8rem; font-size: .85rem; }
.wide { width: 100%; box-sizing: border-box; padding: .5rem; border: 1px solid #cbd5e1;
    border-radius: 6px; font: inherit; margin-top: .25rem; }
textarea.wide { font-family: ui-monospace, Menlo, monospace; font-size: .85rem; }
.card h3 { margin: 1.2rem 0 .4rem; }

/* e-mailový log u účastníků */
.email-log { white-space: nowrap; }
.mail-badge { display: inline-block; font-size: .72rem; padding: .1rem .35rem; border-radius: 4px;
    margin: 1px; white-space: nowrap; }
.mail-badge.ok { background: #dcfce7; color: #166534; }
.mail-badge.fail { background: #fee2e2; color: #991b1b; }

/* kompaktní filtr od–do */
.filter-row { display: flex; align-items: flex-end; gap: .8rem; flex-wrap: wrap; margin: 0; }
.filter-row label { display: flex; flex-direction: column; font-size: .8rem; gap: .2rem; }
.filter-row input[type=date] { padding: .4rem .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font: inherit; }
.filter-row button, .filter-row .btn { padding: .45rem .9rem; }

/* ===== Marketing mailing ===== */
.topnav { display: flex; gap: 1rem; }
.topnav a { color: #93c5fd; text-decoration: none; }
.topnav a:hover { color: #fff; }
.mailing-layout { display: grid; grid-template-columns: 260px 1fr; gap: 1.5rem; align-items: start; }
.sidebar h3 { margin-top: 0; }
.sidebar .all-link { display: block; padding: .3rem .4rem; border-radius: 6px; text-decoration: none; color: #1f2937; }
.sidebar .all-link.active, .folder-tree a.active { background: #e0e7ff; font-weight: 600; }
.folder-tree { list-style: none; margin: .3rem 0; padding-left: .6rem; }
.folder-tree li { margin: .1rem 0; }
.folder-tree a { text-decoration: none; color: #1f2937; padding: .2rem .4rem; border-radius: 6px; display: inline-block; }
.folder-tree a:hover { background: #f1f5f9; }
.folder-tree .cnt { color: #9ca3af; font-size: .8rem; }
.small { font-size: .85rem; padding: .35rem .7rem; }
.mt { margin-top: 1rem; }
.stack { display: flex; flex-direction: column; gap: .5rem; margin-top: .6rem; }
.stack label { display: flex; flex-direction: column; font-size: .85rem; gap: .2rem; }
.badge-btn { border: 0; border-radius: 12px; padding: .2rem .6rem; font-size: .78rem; cursor: pointer; }
.badge-btn.on { background: #dcfce7; color: #166534; }
.badge-btn.off { background: #f1f5f9; color: #6b7280; }
@media (max-width: 720px) { .mailing-layout { grid-template-columns: 1fr; } }

/* ===== Hlavní admin menu ===== */
.mainmenu { display: flex; gap: .2rem; }
.mainmenu a { color: #cbd5e1; text-decoration: none; padding: .5rem .9rem; border-radius: 6px; font-weight: 500; }
.mainmenu a:hover { background: rgba(255,255,255,.1); color: #fff; }
.mainmenu a.active { background: #2563eb; color: #fff; }
.topbar-user { color: #cbd5e1; font-size: .9rem; }
.topbar-user a { color: #93c5fd; }
.submenu { background: #fff; border-bottom: 1px solid #e5e7eb; }
.submenu .container { display: flex; gap: 1rem; padding-top: .6rem; padding-bottom: .6rem; }
.submenu a { color: #6b7280; text-decoration: none; padding: .3rem .6rem; border-radius: 6px; }
.submenu a:hover { background: #f1f5f9; color: #1f2937; }
.submenu a.active { color: #2563eb; font-weight: 600; }
.crumb { margin: 1rem 0 0; }
.crumb a { color: #2563eb; text-decoration: none; }

/* objednávkový formulář – bloky cestujících */
.pax-block { border: 1px solid #e5e7eb; border-radius: 8px; padding: .8rem 1rem; margin-bottom: 1rem; }
.pax-head { font-weight: 600; color: #1f3a93; margin-bottom: .5rem; }
.pax-fields { display: flex; flex-wrap: wrap; gap: .8rem; padding-top: .4rem; border-top: 1px dashed #e5e7eb; margin-top: .4rem; }

/* perex (úvodník) v detailu zájezdu */
.trip-perex { font-size: 1.05rem; color: #374151; font-weight: 500; margin-bottom: 1rem;
    padding-bottom: 1rem; border-bottom: 1px solid #eef0f3; }
/* dvě tlačítka na výpisu vedle sebe */
.trip-actions { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }

/* náhled CSV importu */
.table-scroll { overflow-x: auto; border: 1px solid #e5e7eb; border-radius: 8px; }
.table-scroll table { min-width: 100%; }
.table-scroll th, .table-scroll td { white-space: nowrap; font-size: .85rem; }

/* upozornění na nezletilého cestujícího */
.minor-notice { margin-top: .3rem; }
.minor-warning { background: #fef3c7; color: #92400e; border: 1px solid #fcd34d;
    padding: .5rem .7rem; border-radius: 8px; font-size: .9rem; font-weight: 500; }
.minor-hint { margin-top: .4rem; color: #6b7280; font-size: .85rem; }
.minor-copy { margin-top: .5rem; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.minor-copy span { font-size: .85rem; color: #374151; }

/* ===== Obsazovák autobusu ===== */
.seating-layout { display: grid; grid-template-columns: 280px 1fr; gap: 1.5rem; align-items: start; }
.bus-plan { border: 2px solid #5F5E5A; border-radius: 20px; padding: .6rem; max-width: 260px; }
.plan-driver { background: #F1EFE8; border: 0.5px solid #888; border-radius: 6px;
    text-align: center; font-size: .7rem; padding: .3rem; width: 40%; margin-bottom: .5rem; }
.plan-row { display: flex; gap: 4px; margin-bottom: 4px; align-items: center; }
.plan-seat { width: 34px; height: 26px; border-radius: 5px; background: #DBF3E4;
    border: 0.5px solid #0F6E56; color: #085041; font-size: .72rem; font-weight: bold;
    display: flex; align-items: center; justify-content: center; }
.plan-seat.taken { background: #F7CDCD; border-color: #B02020; color: #7A1414; }
.plan-seat.blocked { background: #D9DBDE; border-color: #8A8D91; color: #55585C; }
.plan-aisle { width: 16px; }
.plan-fac-cell { flex: 1; background: #F1EFE8; border: 0.5px solid #888; border-radius: 5px;
    font-size: .6rem; color: #444; display: flex; align-items: center; justify-content: center; min-height: 26px; }
.plan-facility { background: #F1EFE8; border: 0.5px solid #888; border-radius: 4px;
    text-align: center; font-size: .6rem; color: #444; padding: .2rem; margin-bottom: 4px; }
.plan-deck { background: #1f3a93; color: #fff; border-radius: 4px; text-align: center;
    font-size: .68rem; font-weight: bold; padding: .3rem; margin: .5rem 0 .4rem; }
.seat-table { width: 100%; }
.seat-table th { font-size: .8rem; }
.seat-table td { font-size: .85rem; }
.seat-table tr.group-sep td { border-top: 2px solid #94a3b8; }
.seat-select { padding: .2rem .3rem; }
.seat-actions { margin-top: 1rem; display: flex; gap: .6rem; align-items: center; }
@media (max-width: 800px) { .seating-layout { grid-template-columns: 1fr; } }

/* ===== Karta klienta ===== */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-box { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 1rem; text-align: center; }
.stat-num { font-size: 1.6rem; font-weight: bold; color: #1f3a93; }
.stat-label { font-size: .8rem; color: #6b7280; margin-top: .2rem; }
tr.clickable { cursor: pointer; }
tr.clickable:hover td { background: #f1f5f9; }

/* stornovaný cestující v seznamu */
tr.row-storno td { background: #fef2f2; color: #991b1b; text-decoration: line-through; }
tr.row-storno .mail-badge { text-decoration: none; }

/* storno volby */
.storno-options { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1rem; }
.storno-options .card { margin: 0; }
.btn-danger { background: #dc2626; color: #fff; }
.btn-danger:hover { background: #b91c1c; }
@media (max-width: 700px){ .storno-options { grid-template-columns: 1fr; } }

/* editor vyřazených míst */
.blocked-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(56px, 1fr)); gap: .3rem; margin-top: .5rem; }
.blocked-item { display: flex; align-items: center; gap: .25rem; font-size: .85rem;
    border: 1px solid #e5e7eb; border-radius: 5px; padding: .2rem .35rem; }
.blocked-item input { margin: 0; }

/* ============ VEŘEJNÝ WEB (site) ============ */
body.site { margin: 0; background: #f4f4f5; color: #2b2b2b;
    font-family: -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
.site-wrap { display: grid; grid-template-columns: 320px 1fr; min-height: 100vh; }
.site-side { background: #fff; padding: 2.2rem 2rem; display: flex; flex-direction: column; }
.site-logo img { max-width: 180px; height: auto; }
.site-menu { margin-top: 2.5rem; display: flex; flex-direction: column; gap: .35rem; }
.site-menu a { font-size: 1.5rem; color: #2b2b2b; text-decoration: none; padding: .35rem 0;
    transition: color .15s; }
.site-menu a:hover { color: #1f3a93; }
.site-menu a.active { color: #6b7ec8; }
.site-menu a { position: relative; }
.site-social { margin-top: 2rem; display: flex; gap: .6rem; }
.fb-btn, .ig-btn, .review-btn { display: inline-flex; width: 46px; height: 46px; border-radius: 50%; background: #eceef5;
    align-items: center; justify-content: center; font-weight: bold; font-family: Georgia, serif;
    color: #1a2b8c; text-decoration: none; font-size: 1.3rem; transition: all .15s; }
.fb-btn:hover { background: #1a2b8c; color: #fff; }
.ig-btn:hover { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); color: #fff; }
.review-btn:hover { background: #f5a623; color: #fff; }
.site-contact { margin-top: auto; padding-top: 2rem; font-size: 1rem; color: #333; line-height: 1.7; }
.site-contact address { font-style: normal; }
.site-contact a, .site-contact .hyper-link { color: #1a2b8c; text-decoration: none; }
.site-contact a:hover { text-decoration: underline; }
.site-contact abbr { text-decoration: none; }
.site-main { display: flex; flex-direction: column; }
.site-content { flex: 1; padding: 3.2rem 4rem; max-width: 1100px; }
.site-content h1 { font-size: 3rem; font-weight: 400; color: #3a3a4a; margin: 0 0 2rem; }
.site-footer { padding: 1.4rem 4rem; background: #fdece0; color: #6b5544; font-size: .95rem; }
.rte-content { font-size: 1.15rem; line-height: 1.75; color: #3a3a3a; }
.rte-content a { color: #1f3a93; }
.rte-content p { margin: 0 0 1.3rem; }

/* kolotoč */
.carousel { position: relative; width: 100%; aspect-ratio: 16/7; border-radius: 12px;
    overflow: hidden; margin-bottom: 2rem; background: #e5e7eb; }
.carousel-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.carousel-slide.active { opacity: 1; }
.carousel-slide img { width: 100%; height: 100%; object-fit: cover; }
.carousel-caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 1rem 1.5rem;
    background: linear-gradient(transparent, rgba(0,0,0,.6)); color: #fff; font-size: 1.1rem; }

/* karty zájezdů na webu */
.trip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.5rem; margin-top: 1.5rem; }
.trip-card { display: block; background: #fff; border-radius: 12px; overflow: hidden; text-decoration: none;
    color: inherit; box-shadow: 0 1px 4px rgba(0,0,0,.08); transition: box-shadow .15s, transform .15s; }
.trip-card:hover { box-shadow: 0 6px 18px rgba(0,0,0,.12); transform: translateY(-2px); }
.trip-card img { width: 100%; height: 170px; object-fit: cover; }
.trip-card-body { padding: 1rem 1.2rem; }
.trip-card-body h3 { margin: .2rem 0 .4rem; font-size: 1.2rem; }
.trip-card .trip-date { color: #6b7ec8; font-size: .9rem; }
.trip-card .price { font-weight: bold; color: #e30016; margin: .3rem 0; }

/* seznam autobusů na webu */
.bus-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.bus-item { background: #fff; border-radius: 10px; padding: 1.2rem; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.bus-item h3 { margin: 0 0 .3rem; }

@media (max-width: 800px) {
    .site-wrap { grid-template-columns: 1fr; }
    .site-side { flex-direction: column; }
    .site-content { padding: 2rem 1.5rem; }
    .site-content h1 { font-size: 2.2rem; }
    .site-footer { padding: 1.2rem 1.5rem; }
}

/* CMS admin doplňky */
.linklike { background: none; border: none; color: #1f3a93; cursor: pointer; text-decoration: underline; font-size: .9rem; padding: 0 .2rem; }
label.check { display: flex; align-items: center; gap: .4rem; }
label.check input { width: auto; margin: 0; }
.cms-gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; margin-top: 1rem; }
.cms-gallery-item { position: relative; border: 1px solid #e5e7eb; border-radius: 8px; overflow: hidden; background: #fff; }
.cms-gallery-item.inactive { opacity: .5; }
.cms-gallery-item img { width: 100%; height: 130px; object-fit: cover; display: block; }
.gi-caption { padding: .3rem .5rem; font-size: .8rem; color: #444; }
.gi-actions { padding: .3rem .5rem; display: flex; flex-wrap: wrap; gap: .3rem; border-top: 1px solid #f0f0f0; }

.pax-extras { font-size: .8rem; color: #555; }

/* dostupnost v kartách/detailu */
.avail-full { color: #888; font-weight: 600; }
.trip-card .avail-low { color: #d40000; font-weight: 700; }
.trip-card .avail-full { color: #888; }

/* upozornění k platbám */
.alert-dot { font-size: .85rem; vertical-align: middle; }
.alert-dot-red { color: #d40000; }
.alert-dot-yellow { color: #e0a800; }
.row-alert-cervena { background: #fff5f5; }
.row-alert-zluta { background: #fffbea; }
.alerts-box { border: 1px solid #f0d000; background: #fffdf3; border-radius: 8px; padding: 1rem 1.2rem; margin: 1rem 0; }
.alert-item { display: flex; justify-content: space-between; align-items: center; gap: 1rem;
    padding: .5rem 0; border-bottom: 1px solid #f0e8c0; }
.alert-item:last-of-type { border-bottom: none; }
.alert-item.alert-cervena .alert-text { color: #a11; }
.alert-item.alert-zluta .alert-text { color: #7a5c00; }

/* veřejný filtr zájezdů */
.trip-filter { background: #fff; border-radius: 10px; padding: 1.2rem 1.4rem; margin: 1.2rem 0;
    box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.tf-row { margin-bottom: .9rem; }
.tf-group { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; }
.tf-label { font-weight: 600; color: #333; min-width: 110px; }
.tf-radio, .tf-check { display: inline-flex; align-items: center; gap: .3rem; font-size: .95rem; cursor: pointer; }
.tf-radio input, .tf-check input { width: auto; margin: 0; }
.tf-price input[type=number] { width: 100px; }
.tf-sliders { position: relative; width: 100%; max-width: 340px; margin-top: .8rem; height: 24px; }
.tf-sliders::before { content: ''; position: absolute; left: 0; right: 0; top: 50%;
    height: 4px; transform: translateY(-50%); background: #d6d9e6; border-radius: 4px; }
.tf-sliders input[type=range] { position: absolute; left: 0; width: 100%; margin: 0; height: 24px;
    pointer-events: none; background: none; -webkit-appearance: none; appearance: none; }
.tf-sliders input[type=range]::-webkit-slider-runnable-track { background: transparent; height: 24px; }
.tf-sliders input[type=range]::-moz-range-track { background: transparent; height: 24px; }
.tf-sliders input[type=range]::-webkit-slider-thumb { pointer-events: auto; -webkit-appearance: none; appearance: none; width: 18px; height: 18px; border-radius: 50%; background: #1a2b8c; cursor: pointer; margin-top: 3px; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.tf-sliders input[type=range]::-moz-range-thumb { pointer-events: auto; width: 18px; height: 18px; border-radius: 50%; background: #1a2b8c; cursor: pointer; border: 2px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.tf-actions { display: flex; gap: .6rem; margin-top: .4rem; }

/* tagy kategorií na kartě */
.trip-tags { display: flex; flex-wrap: wrap; gap: .3rem; margin: .3rem 0; }
.trip-tag { background: #eef0f8; color: #1a2b8c; font-size: .72rem; padding: .12rem .5rem; border-radius: 20px; }

/* admin: checkboxy kategorií */
.cat-checkboxes { display: flex; flex-wrap: wrap; gap: .6rem; margin: .4rem 0; }

/* detail zájezdu v novém layoutu */
.trip-detail { max-width: 760px; }
.trip-detail .article-hero { width: 100%; max-height: 380px; object-fit: cover; border-radius: 12px; margin-bottom: 1.2rem; }
.trip-detail h1 { font-size: 2.2rem; font-weight: 400; color: #3a3a4a; margin: .3rem 0 .6rem; }
.trip-detail .trip-date { color: #6b7ec8; font-size: .95rem; }
.trip-detail .price { font-size: 1.4rem; font-weight: bold; color: #e30016; margin: .5rem 0; }
.trip-detail .trip-perex { font-weight: 600; margin-bottom: 1rem; }
.trip-interest { max-width: 760px; background: #fff; border-radius: 12px; padding: 1.5rem 1.8rem;
    margin-top: 2rem; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.trip-interest h2 { margin-top: 0; }
.back-link { color: #1a2b8c; text-decoration: none; }
.back-link:hover { text-decoration: underline; }

/* graf typů zájezdů */
.cat-chart { display: flex; flex-direction: column; gap: .6rem; margin: 1rem 0; }
.cat-bar-row { display: grid; grid-template-columns: 130px 1fr auto; align-items: center; gap: .8rem; }
.cat-bar-label { font-weight: 600; font-size: .9rem; text-align: right; }
.cat-bar-track { background: #eceef5; border-radius: 6px; height: 22px; overflow: hidden; }
.cat-bar-fill { background: linear-gradient(90deg, #1a2b8c, #4257c4); height: 100%; border-radius: 6px; transition: width .3s; }
.cat-bar-value { font-size: .88rem; white-space: nowrap; }
@media (max-width: 600px) {
    .cat-bar-row { grid-template-columns: 90px 1fr; }
    .cat-bar-value { grid-column: 2; }
}

/* skrytý (nezveřejněný) zájezd v admin seznamu */
.row-hidden { opacity: .6; background: #f7f7f9; }
.badge-hidden { display: inline-block; background: #888; color: #fff; font-size: .68rem;
    padding: .1rem .45rem; border-radius: 10px; margin-left: .4rem; vertical-align: middle; }

/* autobusy – veřejný přehled */
.bus-cta, .bus-detail-cta { margin: 1.2rem 0; }
.bus-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.2rem; margin-top: 1rem; }
.bus-card { display: block; background: #fff; border-radius: 12px; overflow: hidden; text-decoration: none;
    color: inherit; box-shadow: 0 1px 4px rgba(0,0,0,.1); transition: transform .15s, box-shadow .15s; }
.bus-card:hover { transform: translateY(-3px); box-shadow: 0 4px 14px rgba(0,0,0,.15); }
.bus-card img { width: 100%; height: 175px; object-fit: cover; display: block; }
.bus-card-noimg { height: 175px; display: flex; align-items: center; justify-content: center; font-size: 3rem; background: #eceef5; }
.bus-card-body { padding: 1rem 1.2rem; }
.bus-card-body h3 { margin: 0 0 .3rem; }
.bus-nick { color: #6b7ec8; font-weight: 400; font-size: .9em; }

/* autobus – detail + galerie */
.bus-detail { max-width: 820px; }
.bus-detail .article-hero { width: 100%; max-height: 400px; object-fit: cover; border-radius: 12px; margin-bottom: 1.2rem; }
.bus-detail h1 { font-weight: 400; color: #3a3a4a; }
.bus-seatmap-dl { margin: 1.2rem 0; }
.bus-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: .6rem; margin: 1rem 0; }
.bus-gallery-item { display: block; border-radius: 8px; overflow: hidden; aspect-ratio: 4/3; }
.bus-gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.bus-gallery-item:hover img { transform: scale(1.05); }

/* autobusy – admin galerie náhled */
.bus-admin-gallery { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0; }
.bus-admin-gallery img { width: 90px; height: 68px; object-fit: cover; border-radius: 6px; }

/* strukturovaný obsah zájezdu */
.trip-perex-box { border-left: 3px solid #e30016; padding: 2px 0 2px 14px; margin: 1rem 0 1.2rem; }
.trip-perex-box .rte-content { font-weight: 600; font-size: 1.1rem; line-height: 1.55; color: #2a2a3a; }
.trip-teaser { margin-bottom: 1.2rem; line-height: 1.7; }
.trip-maindesc { margin: 1.2rem 0; line-height: 1.7; }

.trip-block { background: #f5f6fa; border-radius: 12px; padding: 1rem 1.2rem; margin: 1rem 0; }
.trip-block-title { font-size: 1.05rem; font-weight: 600; margin: 0 0 .7rem; display: flex; align-items: center; gap: .5rem; color: #1a2b8c; }
.tb-ico { width: 20px; height: 20px; fill: none; stroke: #1a2b8c; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.trip-route-table, .trip-price-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.trip-route-table td { padding: .25rem 0; color: #444; }
.route-time { width: 60px; font-weight: 600; color: #1a2b8c; white-space: nowrap; }
.route-place { padding-left: .8rem; }
.route-return td { padding-top: .5rem; color: #555; font-style: italic; }
.route-return .route-time { color: #555; }
.route-back-arrow { font-style: normal; color: #1a2b8c; margin-right: .2rem; }
.trip-price-table td { padding: .3rem 0; color: #444; border-bottom: 1px solid #e8eaf2; }
.trip-price-table tr:last-child td { border-bottom: none; }
.trip-price-table .price-val { text-align: right; font-weight: 600; white-space: nowrap; }

.trip-section { margin: 1.4rem 0; }
.trip-section-title { font-size: 1.15rem; font-weight: 600; color: #1a2b8c; margin: 0 0 .5rem; }

/* perex v přehledu zájezdů */
.trip-card-perex { font-size: .9rem; color: #555; line-height: 1.5; margin: .3rem 0 .5rem; }

/* editor strukturovaných bloků v adminu */
.block-editor { margin: 1rem 0; padding: 1rem; background: #fafbfd; border: 1px solid #e8eaf2; border-radius: 10px; }
.block-editor .field-label { font-weight: 600; display: block; margin-bottom: .3rem; }
.block-table { width: 100%; border-collapse: collapse; margin: .5rem 0; }
.block-table th { text-align: left; font-size: .8rem; color: #888; font-weight: 600; padding: .2rem .3rem; }
.block-table td { padding: .2rem .3rem; }
.block-table input { width: 100%; }
.section-row { display: flex; flex-direction: column; gap: .3rem; padding: .7rem; margin-bottom: .6rem; background: #fff; border: 1px solid #e8eaf2; border-radius: 8px; }
.section-row .section-heading-input { font-weight: 600; }

/* přepínač zveřejnění (stav, ne akce) */


/* picker – procházení složek */
.gallery-path { display: flex; align-items: center; gap: .8rem; padding: .5rem 1rem; border-bottom: 1px solid #eee; font-size: .85rem; }
.gallery-crumb { color: #555; }
.gallery-up { border: 1px solid #ccc; background: #f5f5f5; border-radius: 6px; padding: .2rem .6rem; cursor: pointer; font-size: .8rem; }
.gallery-up:hover { background: #e8e8e8; }
.gallery-folder { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .2rem;
    border: 1px solid #e0e3ee; background: #fafbff; border-radius: 8px; padding: .8rem .5rem; cursor: pointer; min-height: 90px; }
.gallery-folder:hover { background: #eef1fb; border-color: #1a2b8c; }
.gf-icon { font-size: 1.8rem; }
.gf-name { font-size: .82rem; font-weight: 600; color: #333; word-break: break-all; }

/* poptávky dopravy – ticket + karty */
.ticket-badge { display: inline-block; background: #1a2b8c; color: #fff; font-weight: 700;
    font-family: monospace; padding: .15rem .6rem; border-radius: 6px; letter-spacing: .5px; }
.inquiry-success { background: #f0f9f2; border: 1px solid #b7e0c2; border-radius: 12px; padding: 1.5rem; margin-top: 1rem; }
.inquiry-success .ok { font-size: 1.1rem; color: #1c7a3a; font-weight: 600; margin-top: 0; }
.inquiry-success .ticket-badge { font-size: 1.15rem; }

.filter-bar { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0; }
.filter-bar a { padding: .3rem .8rem; border-radius: 20px; background: #eceef5; color: #333;
    text-decoration: none; font-size: .85rem; }
.filter-bar a.active { background: #1a2b8c; color: #fff; }

.inquiry-card { background: #fff; border: 1px solid #e3e6ef; border-left: 4px solid #999;
    border-radius: 10px; padding: 1rem 1.2rem; margin-bottom: 1rem; }
.inquiry-card.status-nova { border-left-color: #e0a020; }
.inquiry-card.status-v_reseni { border-left-color: #2b7de0; }
.inquiry-card.status-nabidnuto { border-left-color: #9b59b6; }
.inquiry-card.status-vyrizena { border-left-color: #27ae60; }
.inquiry-card.status-zamitnuta { border-left-color: #c0392b; }
.inquiry-head { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; margin-bottom: .6rem; }
.inquiry-status-tag { font-size: .8rem; color: #555; background: #f0f1f6; padding: .1rem .6rem; border-radius: 12px; }
.inquiry-date { font-size: .8rem; color: #999; margin-left: auto; }
.inquiry-message { background: #f7f8fb; border-radius: 8px; padding: .6rem .8rem; margin: .5rem 0; font-size: .92rem; }
.inquiry-actions { display: grid; grid-template-columns: auto 1fr auto; gap: .6rem; align-items: end; margin-top: .8rem; }
.inquiry-actions .full { grid-column: 1 / -1; }
.inquiry-delete { margin-top: .4rem; }
.btn-danger-link { background: none; border: none; color: #c0392b; cursor: pointer; font-size: .82rem; text-decoration: underline; padding: 0; }

/* tabulka stavu migrací v nastavení */
.mig-table { width: 100%; border-collapse: collapse; margin-top: .5rem; }
.mig-table td { padding: .35rem .5rem; border-bottom: 1px solid #eee; vertical-align: top; }
.mig-table td:first-child { width: 30px; text-align: center; }

/* nápověda k proměnným v šablonách e-mailů */
.tpl-vars-help { background: #f5f7fc; border: 1px solid #dde3f0; border-radius: 10px; padding: 1rem 1.2rem; margin-bottom: 1.2rem; }
.tpl-vars-help ul { columns: 2; margin: .5rem 0; padding-left: 1.2rem; }
.tpl-vars-help li { margin: .2rem 0; break-inside: avoid; }
.tpl-vars-help code { background: #fff; padding: .1rem .35rem; border-radius: 4px; border: 1px solid #dde3f0; }
@media (max-width: 600px) { .tpl-vars-help ul { columns: 1; } }

/* výzva odeslána v přehledu předpisů */
.reminder-sent { color: #27ae60; font-size: .82rem; white-space: nowrap; }

/* galerie fotek u popisné sekce zájezdu */
.trip-section-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .5rem; margin-top: .7rem; }
.tsg-item { display: block; border-radius: 8px; overflow: hidden; aspect-ratio: 4/3; }
.tsg-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.tsg-item:hover img { transform: scale(1.05); }

/* editor fotek u sekce v admin */
.section-photos { margin: .5rem 0; }
.section-photos-preview { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .4rem; }
.sp-thumb { position: relative; display: inline-block; }
.sp-thumb img { width: 70px; height: 55px; object-fit: cover; border-radius: 6px; display: block; }
.sp-del { position: absolute; top: -6px; right: -6px; background: #c0392b; color: #fff; border: none;
    border-radius: 50%; width: 18px; height: 18px; font-size: .7rem; cursor: pointer; line-height: 1; padding: 0; }
.btn.small { padding: .25rem .6rem; font-size: .82rem; }

/* lightbox pro galerii autobusu */
.bus-gallery-item { border: none; padding: 0; background: none; cursor: zoom-in; }
.article-hero.lb-open { cursor: zoom-in; }
.lb-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.92); z-index: 9999;
    display: none; align-items: center; justify-content: center; }
.lb-overlay.open { display: flex; }
.lb-stage { max-width: 92vw; max-height: 88vh; display: flex; align-items: center; justify-content: center; }
.lb-img { max-width: 92vw; max-height: 88vh; object-fit: contain; border-radius: 4px;
    box-shadow: 0 4px 30px rgba(0,0,0,.5); }
.lb-btn { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: none;
    cursor: pointer; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    transition: background .15s; }
.lb-btn:hover { background: rgba(255,255,255,.25); }
.lb-close { top: 16px; right: 16px; width: 44px; height: 44px; font-size: 1.4rem; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 2rem; }
.lb-prev { left: 16px; }
.lb-next { right: 16px; }
.lb-counter { position: absolute; top: 20px; left: 20px; color: #fff; font-size: .95rem;
    background: rgba(0,0,0,.4); padding: .25rem .7rem; border-radius: 20px; }
@media (max-width: 600px) {
    .lb-close { top: 10px; right: 10px; width: 40px; height: 40px; }
    .lb-prev, .lb-next { width: 44px; height: 44px; font-size: 1.6rem; }
    .lb-prev { left: 6px; }
    .lb-next { right: 6px; }
    .lb-img { max-width: 98vw; max-height: 82vh; }
}

/* obsazovák na veřejném detailu autobusu */
.bus-obsazovak-box { margin: 1.5rem 0; padding: 1rem 1.2rem; background: #f7f9fc; border: 1px solid #dde3f0; border-radius: 10px; }
.bus-obsazovak-box h2 { margin: 0 0 .2rem; font-size: 1.1rem; }
.bus-obsazovak-actions { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .6rem; }

/* výběr fotek z knihovny do galerie autobusu */
.bus-lib-preview { display: flex; flex-wrap: wrap; gap: .4rem; margin: .4rem 0; }
.bus-lib-thumb { position: relative; display: inline-block; }
.bus-lib-thumb img { width: 70px; height: 55px; object-fit: cover; border-radius: 6px; display: block; }
.bus-lib-thumb button { position: absolute; top: -6px; right: -6px; background: #c0392b; color: #fff;
    border: none; border-radius: 50%; width: 18px; height: 18px; font-size: .7rem; cursor: pointer; line-height: 1; padding: 0; }

/* editor galerie autobusu (odkazy na images, drag pořadí) */
.bus-gallery-editor { display: flex; flex-wrap: wrap; gap: .5rem; margin: .5rem 0; min-height: 20px; }
.bg-thumb { position: relative; display: inline-block; cursor: grab; border-radius: 8px; overflow: hidden; border: 1px solid #e0e3ee; }
.bg-thumb:active { cursor: grabbing; }
.bg-thumb img { width: 90px; height: 68px; object-fit: cover; display: block; }
.bg-del { position: absolute; top: 3px; right: 3px; background: rgba(192,57,43,.92); color: #fff;
    border: none; border-radius: 50%; width: 20px; height: 20px; font-size: .75rem; cursor: pointer; line-height: 1; padding: 0; }
/* tlačítko Nová složka v pickeru */
.gallery-head-actions { display: flex; gap: .5rem; align-items: center; }
.gallery-mkdir { background: #eef1fb; border: 1px solid #c5cdf0; color: #1a2b8c; border-radius: 6px;
    padding: .3rem .7rem; cursor: pointer; font-size: .85rem; }
.gallery-mkdir:hover { background: #e0e5fb; }

/* výběr více fotek v pickeru */
.gallery-item-selected { outline: 3px solid #2563eb; outline-offset: -3px; }
.gallery-item-selected::after { content: '✓'; position: absolute; top: 4px; right: 4px;
    background: #2563eb; color: #fff; width: 20px; height: 20px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: bold; }
.gallery-item { position: relative; }
.gallery-confirm { background: #2563eb; color: #fff; border: none; border-radius: 6px;
    padding: .3rem .8rem; cursor: pointer; font-size: .85rem; font-weight: 600; }
.gallery-confirm:hover { background: #1d4ed8; }

/* panel a zvýraznění neschválených poptávek na zájezdech */
.inquiry-panel { display: flex; align-items: center; gap: .8rem; background: #fff8e1;
    border: 1px solid #ffe082; border-left: 4px solid #ffb300; border-radius: 10px;
    padding: .9rem 1.1rem; margin-bottom: 1rem; }
.inquiry-panel-icon { font-size: 1.4rem; }
.inquiry-panel-text { font-size: .95rem; color: #5d4200; }
.inquiry-panel-text strong { color: #b26a00; }
tr.row-inquiry { background: #fffdf4; }
tr.row-inquiry:hover { background: #fff8e1; }
.cell-inquiry { font-weight: bold; color: #b26a00; }
.badge-inquiry { display: inline-block; background: #fff3cd; color: #8a6100; font-size: .72rem;
    padding: .1rem .5rem; border-radius: 10px; margin-left: .4rem; border: 1px solid #ffe082; white-space: nowrap; }

/* zaškrtávátko ve filtru + odkaz v panelu poptávek */
.filter-check { display: inline-flex; align-items: center; gap: .35rem; white-space: nowrap; }
.filter-check input { margin: 0; }
.inquiry-panel-text a { color: #b26a00; font-weight: 600; text-decoration: underline; margin-left: .3rem; }
.inquiry-panel-text a:hover { color: #8a5200; }

/* bloky historie (rok + text + fotka vpravo) */
.history-intro { margin-bottom: 1.5rem; font-size: 1.05rem; }
.history-blocks { display: flex; flex-direction: column; gap: 1.5rem; }
.history-block { overflow: hidden; padding-bottom: 1.2rem; border-bottom: 1px solid #eef0f5; }
.history-block:last-child { border-bottom: none; }
.history-year { font-weight: 700; font-size: 1.3rem; color: #0C447C; margin: 0 0 .5rem; }
.history-text { line-height: 1.6; }
/* fotka vpravo, text ji obtéká; miniatura v tmavém rámečku */
.history-photo { float: right; display: block; margin: 0 0 12px 20px; max-width: 260px; width: 42%;
    border: 4px solid #111; border-radius: 4px; cursor: zoom-in; box-shadow: 0 2px 8px rgba(0,0,0,.2);
    line-height: 0; }
.history-photo img { width: 100%; height: auto; display: block; }
@media (max-width: 640px) {
    .history-photo { float: none; width: 100%; max-width: none; margin: 0 0 12px; }
}

/* editor bloků historie */
.hblock-edit { display: flex; gap: .6rem; align-items: flex-start; background: #f7f9fc;
    border: 1px solid #dde3f0; border-radius: 10px; padding: .8rem; margin-bottom: .8rem; }
.hblock-drag { cursor: grab; font-size: 1.3rem; color: #99a; padding: .2rem .3rem; user-select: none; }
.hblock-fields { flex: 1; display: flex; flex-direction: column; gap: .5rem; }
.hblock-fields label { display: flex; flex-direction: column; font-size: .85rem; color: #555; gap: .2rem; }
.hblock-fields input, .hblock-fields textarea { font-size: .95rem; padding: .4rem .5rem; border: 1px solid #cbd5e1; border-radius: 6px; }
.hblock-year input { font-weight: 700; max-width: 160px; }
.hblock-photo { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.hblock-thumb .hthumb { display: inline-block; border: 3px solid #111; border-radius: 3px; line-height: 0; }
.hblock-thumb img { width: 90px; height: 68px; object-fit: cover; display: block; }
.hblock-del { background: none; border: none; color: #c0392b; font-size: 1.1rem; cursor: pointer; padding: .2rem .4rem; }
.hblock-del:hover { color: #a02216; }

/* ===== DISPEČERSKÝ KALENDÁŘ ===== */
.dispatch-wrap { max-width: 1200px; }
.dispatch-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.dt-left { display: flex; align-items: center; gap: .5rem; }
.dt-period { font-size: 1.15rem; margin-left: .5rem; }
.dt-right { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.dt-right select { padding: .45rem .6rem; border: 1px solid #cbd5e1; border-radius: 6px; }
.dt-viewswitch { display: inline-flex; gap: .3rem; }
.dispatch-legend { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: .8rem; font-size: .9rem; }
.dl-item { display: inline-flex; align-items: center; gap: .4rem; }
.dl-dot { width: 14px; height: 14px; border-radius: 3px; display: inline-block; }

/* měsíční mřížka */
.cal-month { border: 1px solid #dde3f0; border-radius: 10px; overflow: hidden; }
.cal-head { display: grid; grid-template-columns: repeat(7, 1fr); background: #f1f5f9; }
.cal-hcell { padding: .5rem; text-align: center; font-weight: 600; font-size: .85rem; color: #555; border-right: 1px solid #e2e8f0; }
.cal-hcell:last-child { border-right: none; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-cell { min-height: 100px; border-right: 1px solid #eef0f5; border-bottom: 1px solid #eef0f5; padding: .3rem; cursor: pointer; transition: background .1s; position: relative; }
.cal-cell:hover { background: #f8fafc; }
.cal-cell:nth-child(7n) { border-right: none; }
.cal-other { background: #fafbfc; color: #aab; }
.cal-other .cal-daynum { color: #bbc; }
.cal-today { background: #eff6ff; }
.cal-today .cal-daynum { background: #2563eb; color: #fff; border-radius: 50%; width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; }
.cal-daynum { font-size: .85rem; font-weight: 600; margin-bottom: .2rem; }
.cal-events { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cal-ev { cursor: pointer; border-radius: 4px; overflow: hidden; border: 2px solid #888; max-width: 100%; }
.cal-ev:hover { filter: brightness(1.06); }
.cal-ev-main { display: flex; gap: 4px; align-items: baseline; font-size: .72rem;
    padding: 2px 5px; white-space: nowrap; overflow: hidden; min-width: 0; }
.cal-ev-time { font-weight: 700; opacity: .95; flex-shrink: 0; }
.cal-ev-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
/* kolejnice vytížení dne pod událostí: šířka výplně ~ jak dlouho je autobus pryč (5–23 h) */
.cal-ev-bar { position: relative; height: 5px; background: #e6e8ee; }
.cal-ev-bar span { position: absolute; top: 0; height: 100%; min-width: 4px; opacity: 1; }

/* týdenní pohled */
.cal-week { border: 1px solid #dde3f0; border-radius: 10px; overflow: hidden; --hpx: 44px; }
.cw-head { display: grid; grid-template-columns: 60px repeat(7, 1fr); background: #f1f5f9; }
.cw-timecol { }
.cw-daycol-head { padding: .5rem; text-align: center; font-weight: 600; font-size: .85rem; border-left: 1px solid #e2e8f0; }
.cw-daycol-head span { display: block; font-weight: 400; color: #777; font-size: .8rem; }
.cw-today { background: #eff6ff; color: #2563eb; }
.cw-body { display: grid; grid-template-columns: 60px repeat(7, 1fr); position: relative; }
.cw-body .cw-timecol { display: flex; flex-direction: column; }
.cw-hour { height: var(--hpx); font-size: .72rem; color: #999; text-align: right; padding-right: .4rem; border-bottom: 1px solid #f0f2f7; }
.cw-daycol { position: relative; border-left: 1px solid #eef0f5; cursor: pointer; }
.cw-slot { height: var(--hpx); border-bottom: 1px solid #f0f2f7; }
.cw-slot:hover { background: #f8fafc; }
.cw-ev { position: absolute; left: 2px; right: 2px; border-radius: 5px; padding: 2px 5px; font-size: .72rem; overflow: hidden; cursor: pointer; box-shadow: 0 1px 3px rgba(0,0,0,.2); border: 2px solid #888; }
.cw-ev strong { display: block; font-size: .74rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cw-ev span { display: block; opacity: .9; font-size: .68rem; }
.cw-ev-bus { font-style: italic; }

/* modal obsazení */
.disp-modal { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 1000; align-items: center; justify-content: center; }
.disp-modal-box { background: #fff; border-radius: 12px; width: 92%; max-width: 480px; max-height: 90vh; overflow: auto; }
.disp-modal-head { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.2rem; border-bottom: 1px solid #eef0f5; }
.disp-modal-close { background: none; border: none; font-size: 1.2rem; cursor: pointer; color: #888; }
#dispatch-form { padding: 1.2rem; display: flex; flex-direction: column; gap: .7rem; }
#dispatch-form label { display: flex; flex-direction: column; gap: .25rem; font-size: .9rem; color: #555; }
#dispatch-form input, #dispatch-form select, #dispatch-form textarea { padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .95rem; }
.dm-check { flex-direction: row !important; align-items: center; gap: .5rem !important; }
.dm-check input { width: auto; }
.dm-times { display: flex; gap: .8rem; }
.dm-times label { flex: 1; }
.dm-conflict { background: #fff8e1; border: 1px solid #ffe082; border-radius: 6px; padding: .5rem .7rem; font-size: .85rem; color: #8a6100; }
.disp-modal-actions { display: flex; gap: .5rem; align-items: center; margin-top: .5rem; }
.btn-danger { background: #c0392b; color: #fff; }
.btn-danger:hover { background: #a02216; }

@media (max-width: 720px) {
    .cal-cell { min-height: 70px; }
    .cw-head, .cw-body { grid-template-columns: 40px repeat(7, 1fr); font-size: .7rem; }
    .dispatch-toolbar { flex-direction: column; align-items: stretch; }
}

/* dispečink – rozcestník dlaždice */
.dispatch-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.2rem; margin-top: 1.5rem; }
.disp-tile { display: flex; gap: 1rem; padding: 1.4rem; background: #fff; border: 1px solid #dde3f0;
    border-radius: 12px; text-decoration: none; color: inherit; transition: all .15s; align-items: flex-start; }
.disp-tile:hover { border-color: #2563eb; box-shadow: 0 4px 14px rgba(37,99,235,.12); transform: translateY(-2px); }
.disp-tile-icon { font-size: 2.4rem; line-height: 1; flex-shrink: 0; }
.disp-tile-body { flex: 1; }
.disp-tile-body h2 { margin: 0 0 .3rem; font-size: 1.25rem; display: flex; align-items: center; gap: .5rem; }
.disp-tile-body p { margin: 0 0 .7rem; color: #666; font-size: .92rem; }
.disp-tile-badge { background: #c0392b; color: #fff; font-size: .8rem; font-weight: 700;
    border-radius: 999px; padding: .05rem .5rem; min-width: 1.4rem; text-align: center; }
.disp-tile-meta { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.disp-tile-count { color: #888; font-size: .85rem; }
.disp-badge { display: inline-block; background: #eef2fb; color: #1a3a8c; font-size: .8rem;
    padding: .15rem .6rem; border-radius: 6px; font-weight: 600; }
.disp-badge.warn { background: #fff8e1; color: #8a6100; border: 1px solid #ffe082; }

/* dispečink – upozornění na nepřiřazené jízdy */
.dispatch-warn { display: flex; gap: .8rem; align-items: center; background: #fff8e1;
    border: 1px solid #ffe082; border-left: 4px solid #ffb300; border-radius: 10px;
    padding: .9rem 1.1rem; margin: 1rem 0 1.5rem; }
.dispatch-warn-icon { font-size: 1.4rem; }
.dispatch-warn a { color: #b26a00; font-weight: 600; text-decoration: underline; margin-left: .5rem; }

/* karty jízd */
.rides-section { margin-top: 1.5rem; }
.rides-h { font-size: 1.2rem; display: flex; align-items: center; gap: .5rem; margin-bottom: .8rem; }
.rides-count { background: #eef2fb; color: #1a3a8c; font-size: .85rem; padding: .1rem .55rem; border-radius: 999px; font-weight: 700; }
.rides-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.ride-card { background: #fff; border: 1px solid #dde3f0; border-radius: 10px; padding: 1rem; }
.ride-unassigned { border: 1px solid #ffe082; background: #fffdf6; }
.ride-card-date { font-size: .8rem; color: #888; font-weight: 600; }
.ride-card-title { margin: .2rem 0 .5rem; font-size: 1.05rem; }
.ride-card-time, .ride-card-cap, .ride-card-bus { font-size: .88rem; color: #555; margin-bottom: .3rem; }
.ride-card-bus { font-weight: 700; }
.ride-assign-form { display: flex; gap: .4rem; margin-top: .7rem; flex-wrap: wrap; }
.ride-assign-form select { flex: 1; min-width: 120px; padding: .4rem; border: 1px solid #cbd5e1; border-radius: 6px; }
.ride-card-actions { display: flex; justify-content: space-between; align-items: center; margin-top: .6rem; gap: .5rem; flex-wrap: wrap; }
.ride-cal-link { font-size: .85rem; color: #2563eb; text-decoration: none; }
.ride-cal-link:hover { text-decoration: underline; }
.ride-unassign { background: none; border: none; color: #c0392b; font-size: .8rem; cursor: pointer; text-decoration: underline; padding: 0; }

/* flash hlášky (dispečink apod.) */
.flash-ok { background: #e8f5e9; border: 1px solid #a5d6a7; color: #1b5e20; padding: .7rem 1rem; border-radius: 8px; margin: 1rem 0; }
.flash-err { background: #fdecea; border: 1px solid #f5c6cb; color: #a02216; padding: .7rem 1rem; border-radius: 8px; margin: 1rem 0; font-weight: 600; }

/* legenda: autobus jako barevný prstenec (odpovídá rámečku události) */
.dl-dot-ring { background: #fff !important; border: 3px solid #888; box-sizing: border-box; }
.dispatch-legend-kinds { margin-top: -.4rem; padding-top: .4rem; border-top: 1px dashed #e0e3ee; }

/* výběr barvy u autobusu */
.bus-color-pick { display: inline-flex; align-items: center; gap: .6rem; }
.bus-color-pick input[type=color] { width: 48px; height: 34px; border: 1px solid #cbd5e1; border-radius: 6px; cursor: pointer; padding: 2px; }
.bus-color-preview { display: inline-block; padding: .3rem .7rem; border: 3px solid #888; border-radius: 6px; background: #fff; font-size: .85rem; }

/* barvy typů obsazení v nastavení */
.kindcolor-grid { display: flex; flex-direction: column; gap: .6rem; max-width: 420px; }
.kindcolor-row { display: flex; align-items: center; gap: .8rem; }
.kindcolor-label { flex: 1; font-weight: 600; }
.kindcolor-row input[type=color] { width: 48px; height: 34px; border: 1px solid #cbd5e1; border-radius: 6px; cursor: pointer; padding: 2px; }
.kindcolor-preview { display: inline-block; padding: .25rem .7rem; border-radius: 5px; font-size: .8rem; min-width: 70px; text-align: center; }

/* filtr autobusů zaškrtávátky v kalendáři */
.bus-filter-form { display: inline-block; }
.bus-filter { display: inline-flex; gap: .5rem; align-items: center; flex-wrap: wrap;
    background: #f1f5f9; border: 1px solid #dde3f0; border-radius: 8px; padding: .35rem .5rem; }
.bus-chk { display: inline-flex; align-items: center; gap: .3rem; font-size: .88rem; cursor: pointer;
    padding: .2rem .4rem; border-radius: 5px; white-space: nowrap; }
.bus-chk:hover { background: #e8edf5; }
.bus-chk input { margin: 0; cursor: pointer; }
.bus-chk-all { font-weight: 600; border-right: 1px solid #cbd5e1; padding-right: .6rem; margin-right: .1rem; }
.bus-chk-dot { width: 13px; height: 13px; border-radius: 3px; background: #fff; border: 3px solid #888; box-sizing: border-box; display: inline-block; }
.bus-filter-apply { padding: .3rem .7rem; font-size: .82rem; }


/* ===== TISK KALENDÁŘE (A4) – barevně / černobíle ===== */
.print-header { display: none; }
.cal-ev-print { display: none; }

@media print {
    @page { size: A4 landscape; margin: 8mm; }
    * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }

    /* --- SPOLEČNÉ: skryj ovládání, uprav layout --- */
    .topbar, .submenu, .dispatch-toolbar, .dispatch-warn, .dispatch-tiles,
    .meta, footer, .site-footer, .disp-modal { display: none !important; }
    body { background: #fff !important; }
    .container { max-width: none !important; margin: 0 !important; padding: 0 !important; }

    .print-header { display: block !important; font-size: 11pt; margin-bottom: 4mm; padding-bottom: 2mm;
        border-bottom: 1.5pt solid #000; color: #000; }
    .print-header strong { font-size: 13pt; }
    .print-header-date { float: right; font-weight: normal; font-size: 9pt; }

    .dispatch-legend { display: flex !important; gap: 10px; font-size: 8pt; margin-bottom: 2mm; }

    .cal-week { border-radius: 0 !important; page-break-inside: avoid; }
    .cal-ev-bar { display: none !important; }

    /* MĚSÍC: roztáhni na celou výšku A4 (landscape), řádky týdnů rovnoměrně vysoké */
    html, body { height: auto !important; }
    .dispatch-wrap { display: flex; flex-direction: column; height: 100%; }
    .cal-month {
        border-radius: 0 !important;
        display: flex; flex-direction: column;
        height: 165mm;               /* vejde se na A4 landscape po hlavičce+legendě */
        page-break-inside: avoid;
    }
    .cal-head { flex: 0 0 auto; }
    .cal-grid {
        flex: 1 1 auto;
        display: grid !important;
        grid-template-columns: repeat(7, minmax(0, 1fr));
        grid-auto-rows: 1fr;          /* všechny řádky týdnů stejně vysoké, vyplní zbytek */
    }
    .cal-cell { min-height: 0 !important; overflow: hidden; }
    .cal-daynum { font-size: 10pt !important; }
    /* události čitelné – větší písmo, celá šířka buňky, název na 2 řádky */
    .cal-ev { max-width: 100% !important; }
    .cal-ev-main { font-size: 8pt !important; padding: 2px 4px !important; white-space: normal !important;
        display: block !important; }
    .cal-ev-time { font-size: 8pt !important; font-weight: 700; }
    .cal-ev-print { font-size: 7.5pt !important; }
    .cal-ev-title { white-space: normal !important; overflow: hidden; display: -webkit-box;
        -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.15; }

    /* týden na šířku A4: zmenši výšku hodiny */
    .cal-week { --hpx: 13px !important; }
    .cw-timecol { width: 34px; }
    .cw-head, .cw-body { grid-template-columns: 34px repeat(7, 1fr) !important; }
    .cw-hour { font-size: 6.5pt !important; }
    .cw-ev { font-size: 6pt !important; padding: 0 2px !important; line-height: 1.05 !important; }
    .cw-ev span { font-size: 5.5pt !important; }

    /* =================== BAREVNĚ =================== */
    body.print-color .cal-month, body.print-color .cal-week { border: 1px solid #999 !important; }
    body.print-color .cal-cell { border-color: #e0e0e0 !important; }
    /* barvy zůstávají jak jsou na obrazovce */

    /* =================== ČERNOBÍLE =================== */
    body.print-bw .dl-dot, body.print-bw .dl-dot-ring { border-color: #000 !important; background: #fff !important; }
    body.print-bw .cal-month, body.print-bw .cal-week { border: 1pt solid #000 !important; }
    body.print-bw .cal-head, body.print-bw .cw-head { background: #eee !important; }
    body.print-bw .cal-hcell, body.print-bw .cw-daycol-head { border-color: #000 !important; color: #000 !important; }
    body.print-bw .cal-cell { border-color: #000 !important; }
    body.print-bw .cal-today .cal-daynum { background: #000 !important; color: #fff !important; }
    body.print-bw .cal-other { color: #999 !important; }
    body.print-bw .cal-daynum { color: #000 !important; }

    /* událost ČB: bílé pozadí, černý text, značka autobus·typ, šrafování dle typu */
    body.print-bw .cal-ev, body.print-bw .cw-ev { background: #fff !important; color: #000 !important;
        border: 1.5pt solid #000 !important; box-shadow: none !important; }
    body.print-bw .cal-ev-main { background: #fff !important; color: #000 !important; padding: 1px 3px !important; }
    body.print-bw .cal-ev-time, body.print-bw .cw-ev strong, body.print-bw .cw-ev span { color: #000 !important; }
    body.print-bw .cal-ev-print { display: inline !important; font-weight: 700; margin-right: 3px;
        border: 0.5pt solid #000; padding: 0 2px; border-radius: 2px; font-size: 7pt; }

    /* šrafování typů (černobíle rozlišitelné) */
    body.print-bw .cal-ev.kind-servis .cal-ev-main, body.print-bw .cw-ev.kind-servis {
        background: repeating-linear-gradient(45deg, #fff, #fff 2px, #ccc 2px, #ccc 4px) !important; }
    body.print-bw .cal-ev.kind-porucha .cal-ev-main, body.print-bw .cw-ev.kind-porucha {
        background: repeating-linear-gradient(45deg, #fff, #fff 1px, #999 1px, #999 3px) !important; }
    body.print-bw .cal-ev.kind-blokace .cal-ev-main, body.print-bw .cw-ev.kind-blokace {
        background: repeating-linear-gradient(90deg, #fff, #fff 3px, #ddd 3px, #ddd 4px) !important; }
    body.print-bw .cw-hour { color: #000 !important; }
    body.print-bw .cw-daycol { border-color: #000 !important; }

    /* když se netiskne přes tlačítko (Ctrl+P) – default barevně */
    body:not(.print-bw) .cal-ev-print { display: none; }
}

/* klient dopravy – detail */
.tc-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; margin-top: 1rem; }
@media (max-width: 720px) { .tc-detail-grid { grid-template-columns: 1fr; } }
.kv-table { width: 100%; border-collapse: collapse; }
.kv-table td { padding: .35rem .5rem; border-bottom: 1px solid #eef0f5; font-size: .92rem; }
.kv-table td:first-child { color: #777; width: 110px; }
.tc-stat-row { display: flex; gap: 1.5rem; margin: .5rem 0 1rem; }
.tc-stat { text-align: center; }
.tc-stat-num { display: block; font-size: 1.8rem; font-weight: 700; color: #1a3a8c; }
.tc-stat-lbl { font-size: .82rem; color: #777; }

/* větší modal klienta dopravy se sekcemi */
.tc-modal-box { max-width: 640px !important; width: 94% !important; }
.tc-form { padding: 1.2rem 1.4rem; }
.tc-fieldset { border: 1px solid #e0e3ee; border-radius: 8px; padding: .8rem 1rem 1rem; margin: 0 0 1rem; }
.tc-fieldset legend { font-weight: 600; font-size: .92rem; color: #1a3a8c; padding: 0 .4rem; }
.tc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem 1rem; }
.tc-grid label { display: flex; flex-direction: column; gap: .25rem; font-size: .85rem; color: #555; }
.tc-grid .tc-col-2 { grid-column: 1 / -1; }
.tc-grid input, .tc-grid select { padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .95rem; width: 100%; }
.tc-form textarea { width: 100%; padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .95rem; }
.tc-hint { font-size: .8rem; color: #888; margin: 0 0 .6rem; }
@media (max-width: 560px) { .tc-grid { grid-template-columns: 1fr; } }

/* záložky na stránce Jízdy */
.rides-tabs { display: flex; gap: .3rem; border-bottom: 2px solid #e0e3ee; margin: 1.2rem 0 1.4rem; }
.rides-tab { padding: .6rem 1.1rem; text-decoration: none; color: #667; font-weight: 600; font-size: .95rem;
    border-bottom: 3px solid transparent; margin-bottom: -2px; display: inline-flex; align-items: center; gap: .4rem; }
.rides-tab:hover { color: #1a3a8c; }
.rides-tab.active { color: #1a3a8c; border-bottom-color: #2563eb; }
.rides-tab-badge { background: #c0392b; color: #fff; font-size: .72rem; font-weight: 700;
    border-radius: 999px; padding: .05rem .45rem; min-width: 1.3rem; text-align: center; }
.rides-tab-count { background: #eef2fb; color: #1a3a8c; font-size: .75rem; font-weight: 700;
    border-radius: 999px; padding: .05rem .45rem; }

/* řidiči na stážce (proměnný počet) */
.driver-row { display: flex; align-items: flex-end; gap: .5rem; margin-bottom: .4rem; }
.driver-row label { display: flex; flex-direction: column; gap: .25rem; font-size: .85rem; color: #555; }
.driver-row input { padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .95rem; width: 100%; }
.driver-del { background: none; border: none; color: #c0392b; font-size: 1.1rem; cursor: pointer; padding: .3rem .5rem; }

/* stazka: řádek vozidla – SPZ a kapacita užší, vše na jeden řádek */
.vehicle-row { display: grid; grid-template-columns: 2fr 1.2fr 0.8fr 2fr 1.5fr; gap: .7rem 1rem; align-items: end; }
.vehicle-row label { display: flex; flex-direction: column; gap: .25rem; font-size: .85rem; color: #555; }
.vehicle-row select, .vehicle-row input { padding: .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .95rem; width: 100%; }
@media (max-width: 720px) { .vehicle-row { grid-template-columns: 1fr 1fr; } }

/* filtry stazek */
.stazky-filters { display: flex; flex-direction: column; gap: .6rem; }
.sf-row { display: flex; gap: .8rem; align-items: flex-end; flex-wrap: wrap; }
.sf-row label { display: flex; flex-direction: column; gap: .2rem; font-size: .82rem; color: #555; }
.sf-row input, .sf-row select { padding: .4rem .5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: .9rem; }

/* panel nezaplacených záloh v Ekonomice */
.unpaid-panel { border-left: 4px solid #f5a623; }
.unpaid-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .8rem; margin-bottom: 1rem; }
.unpaid-stats { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .9rem; }
.unpaid-stat { background: #fff8e1; border: 1px solid #ffe082; border-radius: 6px; padding: .3rem .7rem; color: #7a5c00; }
.unpaid-stat.overdue { background: #fdecea; border-color: #f5c6cb; color: #a02216; }
.unpaid-table .num { text-align: right; }
.unpaid-table th.num { text-align: right; }
.row-overdue { background: #fff8f7; }
.badge-overdue { display: inline-block; background: #fdecea; color: #a02216; font-size: .78rem; padding: .1rem .5rem; border-radius: 10px; border: 1px solid #f5c6cb; white-space: nowrap; }
.badge-waiting { display: inline-block; background: #eef2fb; color: #1a3a8c; font-size: .78rem; padding: .1rem .5rem; border-radius: 10px; }
.btn-sm { padding: .25rem .6rem; font-size: .8rem; }

/* barevné stavové štítky ve správě plateb */
.pay-badge { display: inline-block; padding: .2rem .6rem; border-radius: 12px; font-size: .78rem;
    font-weight: 600; white-space: nowrap; line-height: 1.3; }
.st-waiting  { background: #e3eefc; color: #1a4a8c; }          /* čeká – modrá */
.st-paid     { background: #d7f3dd; color: #1b7a37; }          /* uhrazeno – zelená */
.st-overdue  { background: #fde2e0; color: #b0231a; }          /* po splatnosti – červená */
.st-unpaid   { background: #fdefd6; color: #9a6400; }          /* neuhrazeno – oranžová */
.st-storno   { background: #eceef2; color: #667; }             /* storno – šedá */
.st-sent     { background: #d7f3dd; color: #1b7a37; }          /* odesláno – zelená */
.st-notsent  { background: #eceef2; color: #667; }             /* neodesláno – šedá */

/* pruhovaná tabulka s modrou hlavičkou (zájezdy apod.) */
.striped-table { width: 100%; border-collapse: collapse; }
.striped-table thead th { background: #1a4a8c; color: #fff; padding: .6rem .7rem; text-align: left;
    font-size: .82rem; font-weight: 600; }
.striped-table thead th a { color: #fff; }
.striped-table tbody td { padding: .55rem .7rem; border-bottom: 1px solid #eef0f5; }
.striped-table tbody tr:nth-child(even) { background: #f4f6f9; }   /* každý druhý světle šedý */
.striped-table tbody tr:hover { background: #eaf1fb; }
/* zvýraznění má přednost před zebrou */
.striped-table tbody tr.row-inquiry, .striped-table tbody tr.row-inquiry:nth-child(even) { background: #fffdf4; }
.striped-table tbody tr.row-inquiry:hover { background: #fff8e1; }
.striped-table tbody tr.row-hidden td { opacity: .6; }

/* přepínač zveřejnění zájezdu – barevný, viditelný (přebíjí .actions button) */
.pub-toggle { border: none; border-radius: 6px; padding: .35rem .7rem; font-size: .8rem; font-weight: 600;
    cursor: pointer; transition: filter .15s; white-space: nowrap; }
.pub-toggle:hover { filter: brightness(0.93); }
.actions button.pub-on, .pub-toggle.pub-on { background: #2e9e4a; color: #fff; }
.actions button.pub-off, .pub-toggle.pub-off { background: #d64545; color: #fff; }
/* akce v tabulce zájezdů pod sebe, ať se vejdou do sloupce */
.trips-table td.actions { display: flex; flex-direction: column; align-items: flex-start; gap: .3rem; }
.trips-table td.actions form { display: block; margin: 0; }
.trips-table td.actions .pub-toggle { width: auto; }
/* Kopírovat jako odkaz (přebít .actions button tmavou) */
.actions button.linklike { background: none; color: #1f3a93; text-decoration: underline;
    padding: 0 .2rem; font-size: .85rem; border: none; }
.actions button.linklike:hover { color: #16296b; }

/* cena jízdy v modalu obsazení */
.dm-price { border: 1px solid #dde3f0; border-radius: 8px; padding: .6rem .8rem; margin: .3rem 0; }
.dm-price legend { font-size: .82rem; font-weight: 600; color: #1a3a8c; padding: 0 .4rem; }
.dm-price label { display: flex; flex-direction: column; gap: .2rem; font-size: .85rem; margin-bottom: .4rem; }
.dm-price input, .dm-price select { padding: .4rem; border: 1px solid #cbd5e1; border-radius: 6px; }
