/**
 * ZSMH Dokumenty — Frontend Styles
 *
 * Preserves existing .zsmh-download-* classes from theme
 * and adds new layout styles.
 */

/* ─── SEARCH BAR ─────────────────────────────────────────────────────── */

.zsmh-dok-search-wrap {
	margin-bottom: 16px;
}

.zsmh-dok-search {
	width: 100%;
	max-width: 400px;
	padding: 10px 14px 10px 38px;
	border: 1px solid #ddd;
	border-radius: 8px;
	font-size: 14px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Ccircle cx='6.5' cy='6.5' r='5' stroke='%23999' stroke-width='1.5'/%3E%3Cpath d='M10 10l4.5 4.5' stroke='%23999' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: 12px center;
	transition: border-color 0.15s ease;
}

.zsmh-dok-search:focus {
	outline: none;
	border-color: #f19e00;
	box-shadow: 0 0 0 2px rgba(241, 158, 0, 0.15);
}

/* ─── EMPTY STATE ────────────────────────────────────────────────────── */

.zsmh-dok-empty {
	color: #999;
	font-style: italic;
	padding: 20px 0;
}

/* ─── FILE TYPE ICONS ────────────────────────────────────────────────── */

.zsmh-dok-ficon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 6px;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.5px;
	color: #fff;
	background-color: #94a3b8;
	flex-shrink: 0;
}

.zsmh-dok-ficon-pdf { background-color: #ef4444; }
.zsmh-dok-ficon-doc { background-color: #3b82f6; }
.zsmh-dok-ficon-xls { background-color: #22c55e; }
.zsmh-dok-ficon-ppt { background-color: #f97316; }
.zsmh-dok-ficon-zip { background-color: #8b5cf6; }
.zsmh-dok-ficon-mp3 { background-color: #ec4899; }
.zsmh-dok-ficon-img { background-color: #06b6d4; }
.zsmh-dok-ficon-txt { background-color: #64748b; }

/* ─── DOWNLOAD BUTTON ────────────────────────────────────────────────── */

a.zsmh-dok-btn,
.zsmh-dok-btn {
	display: inline-flex !important;
	align-items: center !important;
	gap: 6px;
	padding: 7px 18px !important;
	font-size: 13px !important;
	font-weight: 500 !important;
	border-radius: 6px !important;
	background-color: #f19e00 !important;
	border: none !important;
	color: #fff !important;
	text-decoration: none !important;
	transition: background-color 0.15s ease, transform 0.1s ease;
	white-space: nowrap;
	cursor: pointer;
	line-height: 1.4 !important;
}

a.zsmh-dok-btn:hover,
.zsmh-dok-btn:hover {
	background-color: #d98c00 !important;
	color: #fff !important;
	text-decoration: none !important;
	transform: translateY(-1px);
}

a.zsmh-dok-btn svg,
.zsmh-dok-btn svg {
	flex-shrink: 0;
	stroke: #fff !important;
}

a.zsmh-dok-btn-sm,
.zsmh-dok-btn-sm {
	padding: 5px 14px !important;
	font-size: 12px !important;
}

/* ─── LOCK ICON ──────────────────────────────────────────────────────── */

.zsmh-dok-locked {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	font-size: 18px;
	opacity: 0.5;
	cursor: default;
}

/* ─── DESCRIPTION LINE ───────────────────────────────────────────────── */
/* Shared 2-line clamp used by all layouts (list, compact, card, hub).
   Full text is still available via the native `title` tooltip on hover. */

.zsmh-dok-popis,
.zsmh-dok-compact-popis,
.zsmh-dok-card-popis,
.zsmh-dok-hub-file-desc {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: normal;
	word-break: break-word;
}

.zsmh-dok-popis {
	color: #888;
	font-size: 12px;
	line-height: 1.3;
	margin-top: 2px;
}

/* ─── LIST LAYOUT (default) ──────────────────────────────────────────── */

.zsmh-dok-layout-list .zsmh-download-row {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 12px 8px;
	border-bottom: 1px solid #eaeaea;
	transition: background-color 0.15s ease;
}

.zsmh-dok-layout-list .zsmh-download-row:last-child {
	border-bottom: none;
}

.zsmh-dok-layout-list .zsmh-download-row:hover {
	background-color: #f9f7f3;
}

.zsmh-dok-layout-list .zsmh-download-icon {
	flex-shrink: 0;
	width: 36px;
	height: 36px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.zsmh-dok-layout-list .zsmh-download-info {
	flex: 1;
	min-width: 0;
}

.zsmh-dok-layout-list .zsmh-download-title {
	font-weight: 500;
	font-size: 15px;
	color: #333;
	line-height: 1.3;
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.zsmh-dok-layout-list .zsmh-download-size {
	flex-shrink: 0;
	color: #999;
	font-size: 13px;
	min-width: 80px;
	text-align: right;
	white-space: nowrap;
}

.zsmh-dok-layout-list .zsmh-download-action {
	flex-shrink: 0;
}

/* ─── COMPACT LAYOUT ─────────────────────────────────────────────────── */

/* Remove gaps between consecutive inline shortcode wrappers */
.zsmh-dok-list + .zsmh-dok-list {
	margin-top: -1px; /* collapse borders */
}
.zsmh-doc__chapter-body .zsmh-dok-list:first-of-type {
	margin-top: 1em;
}
.zsmh-doc__chapter-body .zsmh-dok-list:last-of-type {
	margin-bottom: 0.5em;
}

.zsmh-dok-layout-compact {
	display: flex;
	flex-direction: column;
	gap: 0;
	overflow: hidden;
	max-width: 100%;
}

.zsmh-dok-compact-row {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 8px;
	border-bottom: 1px solid #f0f0f0;
	transition: background-color 0.15s ease;
}

.zsmh-dok-compact-row:last-child {
	border-bottom: none;
}

.zsmh-dok-compact-row:hover {
	background-color: #f9f7f3;
}

.zsmh-dok-compact-icon {
	flex-shrink: 0;
}

.zsmh-dok-compact-icon .zsmh-dok-ficon {
	width: 28px;
	height: 28px;
	font-size: 9px;
	border-radius: 4px;
}

.zsmh-dok-compact-info {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
}

a.zsmh-dok-compact-title {
	display: block;
	font-size: 14px !important;
	font-weight: 400 !important;
	color: #333 !important;
	text-decoration: none !important;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

a.zsmh-dok-compact-title:hover {
	color: #f19e00 !important;
	text-decoration: none !important;
}

span.zsmh-dok-compact-title {
	display: block;
	font-size: 14px;
	font-weight: 400;
	color: #999;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.zsmh-dok-compact-popis {
	color: #888;
	font-size: 12px;
	line-height: 1.3;
	margin-top: 2px;
}

.zsmh-dok-compact-meta {
	flex-shrink: 0;
	color: #bbb;
	font-size: 12px;
	white-space: nowrap;
}

/* ─── CARD LAYOUT ────────────────────────────────────────────────────── */

.zsmh-dok-layout-card {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 16px;
}

.zsmh-dok-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 24px 16px 18px;
	border: 1px solid #eaeaea;
	border-radius: 10px;
	transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.zsmh-dok-card:hover {
	border-color: #ddd;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.zsmh-dok-card-icon { margin-bottom: 12px; }
.zsmh-dok-card-icon .zsmh-dok-ficon { width: 48px; height: 48px; font-size: 13px; border-radius: 10px; }
.zsmh-dok-card-body { flex: 1; margin-bottom: 14px; }
.zsmh-dok-card-title { display: block; font-size: 14px; font-weight: 600; color: #333; line-height: 1.3; margin-bottom: 4px; }
.zsmh-dok-card-popis { color: #888; font-size: 12px; line-height: 1.3; margin-bottom: 4px; }
.zsmh-dok-card-meta { display: block; color: #bbb; font-size: 12px; }
.zsmh-dok-card-action { margin-top: auto; }

/* ─── HIDDEN ITEMS (search filter) ───────────────────────────────────── */

.zsmh-dok-item.zsmh-dok-hidden {
	display: none !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   HUB LAYOUT — [zsmh_dokumenty_hub] shortcode (Variant E)
   ═══════════════════════════════════════════════════════════════════════ */

.zsmh-dok-hub {
	--hub-font-heading: 'Trebuchet MS', 'Lucida Grande', sans-serif;
	--hub-font-body: 'Trebuchet MS', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
	--hub-font-display: 'Libre Bodoni', Georgia, serif;
	--hub-primary: #f19e00;
	--hub-primary-dark: #d38900;
	--hub-primary-light: #fdf2e1;
	--hub-cream: #fffbf5;
	--hub-text-dark: #1a1a1a;
	--hub-text: #333333;
	--hub-text-muted: #555555;
	--hub-text-light: #999999;
	--hub-border: #e8e8e8;
	--hub-radius: 12px;
}

/* ─── HUB HERO ──────────────────────────────────────────────────────── */

.zsmh-dok-hub-hero {
	background: linear-gradient(135deg, #faecd2 0%, #f5ddb3 100%);
	border-bottom: 1px solid var(--hub-border);
	padding: 36px 0 32px;
}

.zsmh-dok-hub-hero-inner {
	width: 80%;
	max-width: 1080px;
	margin: 0 auto;
}

/* ─── HUB BREADCRUMB ────────────────────────────────────────────────── */

.zsmh-dok-hub-breadcrumb {
	font-family: var(--hub-font-body);
	font-size: 12px; color: #999; margin-bottom: 12px;
}
.zsmh-dok-hub-breadcrumb a { color: #999; text-decoration: none; }
.zsmh-dok-hub-breadcrumb a:hover { color: var(--hub-primary); text-decoration: underline; }
.zsmh-dok-hub-breadcrumb .sep { color: #ccc; }
.zsmh-dok-hub-breadcrumb .current { color: #666; }

.zsmh-dok-hub-hero-row {
	display: flex; align-items: center; gap: 20px;
}

.zsmh-dok-hub-icon {
	width: 48px; height: 48px; border-radius: 12px;
	background: linear-gradient(135deg, var(--hub-primary), var(--hub-primary-dark));
	display: flex; align-items: center; justify-content: center;
	font-size: 22px; flex-shrink: 0;
	box-shadow: 0 4px 12px rgba(241, 158, 0, 0.15);
}

.zsmh-dok-hub-title {
	font-family: var(--hub-font-heading);
	font-size: 1.6rem; font-weight: 700;
	color: var(--hub-text-dark); line-height: 1.2;
	margin: 0 0 6px;
}

.zsmh-dok-hub-desc {
	font-family: var(--hub-font-body);
	font-size: 14px; color: var(--hub-text-muted);
	max-width: 520px; margin: 0;
}

/* ─── HUB CONTROLS ─────────────────────────────────────────────────── */

.zsmh-dok-hub-controls {
	flex-shrink: 0;
	display: flex; flex-direction: column;
	gap: 8px; align-items: flex-end;
}

.zsmh-dok-hub-search { position: relative; }

.zsmh-dok-hub-search input[type="text"] {
	width: 280px; padding: 12px 16px 12px 40px;
	border: 1px solid rgba(255,255,255,0.5); border-radius: 10px;
	font-size: 14px; font-family: var(--hub-font-body);
	background: rgba(255,255,255,0.7); transition: all 0.15s;
}

.zsmh-dok-hub-search input[type="text"]:focus {
	outline: none; border-color: var(--hub-primary);
	box-shadow: 0 0 0 3px rgba(241, 158, 0, 0.12);
	background: #fff;
}

.zsmh-dok-hub-search input[type="text"]::placeholder { color: var(--hub-text-light); }

.zsmh-dok-hub-search-icon {
	position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
	color: var(--hub-text-light); pointer-events: none; line-height: 0;
}

/* ─── HUB TWO-PANE LAYOUT ──────────────────────────────────────────── */

.zsmh-dok-hub-layout {
	width: 80%; max-width: 1080px; margin: 24px auto 60px;
	display: grid; grid-template-columns: 240px 1fr;
	background: #fff; border: 1px solid var(--hub-border);
	border-radius: var(--hub-radius); overflow: hidden;
	min-height: 480px;
}

/* ─── HUB SIDEBAR ──────────────────────────────────────────────────── */

.zsmh-dok-hub-sidebar {
	background: #f9f9f9; border-right: 1px solid var(--hub-border);
	display: flex; flex-direction: column;
}
.zsmh-dok-hub-sidebar-header {
	padding: 14px 16px 10px; font-size: 10px; font-weight: 700;
	text-transform: uppercase; letter-spacing: 1.5px;
	color: var(--hub-text-light); border-bottom: 1px solid var(--hub-border);
}

.zsmh-dok-hub-sidebar-item {
	display: flex; align-items: center; gap: 10px;
	padding: 10px 16px; cursor: pointer; transition: background 0.12s;
	border-bottom: 1px solid #f0f0f0; text-decoration: none !important;
	color: inherit !important;
}
.zsmh-dok-hub-sidebar-item:hover { background: var(--hub-cream); }
.zsmh-dok-hub-sidebar-item.active {
	background: var(--hub-primary-light);
	border-left: 3px solid var(--hub-primary);
	padding-left: 13px;
}

.zsmh-dok-hub-sidebar-emoji { font-size: 18px; flex-shrink: 0; }
.zsmh-dok-hub-sidebar-info { flex: 1; min-width: 0; }
.zsmh-dok-hub-sidebar-name {
	display: block; font-size: 13px; font-weight: 700;
	color: var(--hub-text-dark); white-space: nowrap;
	overflow: hidden; text-overflow: ellipsis;
}
.zsmh-dok-hub-sidebar-count { display: block; font-size: 11px; color: var(--hub-text-light); }
.zsmh-dok-hub-sidebar-badge {
	background: var(--hub-primary); color: #fff;
	font-size: 10px; font-weight: 700;
	padding: 2px 7px; border-radius: 10px; flex-shrink: 0;
}
.zsmh-dok-hub-sidebar-item.active .zsmh-dok-hub-sidebar-badge { background: var(--hub-primary-dark); }

.zsmh-dok-hub-sidebar-footer {
	padding: 12px 16px; border-top: 1px solid var(--hub-border); margin-top: auto;
}
.zsmh-dok-hub-sidebar-footer label {
	font-size: 12px; color: var(--hub-text-muted);
	display: flex; align-items: center; gap: 6px; cursor: pointer;
}

/* ─── MOBILE FOLDER TILES (hidden on desktop) ─────────────────────── */

.zsmh-dok-hub-mobile-tiles { display: none; }

.zsmh-dok-hub-folder-grid {
	display: grid; grid-template-columns: repeat(3, 1fr);
	gap: 10px; margin-bottom: 20px;
}

.zsmh-dok-hub-folder-tile {
	background: #fff; border: 1px solid var(--hub-border);
	border-radius: 10px; padding: 16px 10px 12px; text-align: center;
	cursor: pointer; transition: all 0.2s; text-decoration: none !important;
	color: inherit !important; display: block;
}
.zsmh-dok-hub-folder-tile:hover {
	border-color: var(--hub-primary);
	box-shadow: 0 2px 12px rgba(241, 158, 0, 0.12);
}
.zsmh-dok-hub-folder-tile.active {
	border-color: var(--hub-primary);
	background: var(--hub-primary-light);
}

/* CSS folder icon */
.zsmh-dok-hub-folder-visual {
	width: 48px; height: 40px; margin: 0 auto 8px; position: relative;
}
.zsmh-dok-hub-folder-back {
	width: 48px; height: 34px; background: #f5c842;
	border-radius: 0 5px 5px 5px; position: absolute; bottom: 0;
}
.zsmh-dok-hub-folder-tab {
	width: 22px; height: 8px; background: #e8b530;
	border-radius: 3px 3px 0 0; position: absolute; top: 0; left: 0;
}
.zsmh-dok-hub-folder-front {
	width: 48px; height: 28px; background: #fdd85d;
	border-radius: 0 3px 5px 5px; position: absolute; bottom: 0;
	box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.zsmh-dok-hub-folder-name {
	display: block; font-size: 12px; font-weight: 700;
	color: var(--hub-text-dark); white-space: nowrap;
	overflow: hidden; text-overflow: ellipsis;
}
.zsmh-dok-hub-folder-count { display: block; font-size: 10px; color: var(--hub-text-light); }

/* ─── HUB MAIN CONTENT ────────────────────────────────────────────── */

.zsmh-dok-hub-main { overflow: hidden; }

/* Section visibility: only active section is shown */
.zsmh-dok-hub-section { display: none; }
.zsmh-dok-hub-section.active { display: block; }
/* During search: JS manages visibility */
.zsmh-dok-hub.is-searching .zsmh-dok-hub-section.active { display: block; }

.zsmh-dok-hub-section-header {
	display: flex; align-items: center; gap: 10px;
	padding: 14px 24px; background: #fafafa;
	border-bottom: 1px solid var(--hub-border);
}
.zsmh-dok-hub-section-emoji { font-size: 18px; }
.zsmh-dok-hub-section-title {
	font-family: var(--hub-font-heading); font-size: 16px; font-weight: 700;
	color: var(--hub-text-dark); margin: 0;
}

/* ─── HUB FILE CARDS ───────────────────────────────────────────────── */

.zsmh-dok-hub-section-body { padding: 12px 16px; }

.zsmh-dok-hub-file {
	display: flex; align-items: center; gap: 14px;
	padding: 12px 16px; border: 1px solid var(--hub-border);
	border-radius: 8px; margin-bottom: 8px;
	transition: all 0.15s;
}
.zsmh-dok-hub-file:hover {
	border-color: var(--hub-primary);
	box-shadow: 0 2px 8px rgba(241, 158, 0, 0.08);
}
.zsmh-dok-hub-file .zsmh-dok-ficon { width: 38px; height: 38px; border-radius: 8px; font-size: 11px; }

.zsmh-dok-hub-file-info { flex: 1; min-width: 0; }
.zsmh-dok-hub-file-title {
	font-size: 13px; font-weight: 600; color: var(--hub-text-dark);
	display: block; line-height: 1.3; margin-bottom: 3px;
}
.zsmh-dok-hub-file-desc {
	font-size: 12px; color: var(--hub-text-light); line-height: 1.3;
}

.zsmh-dok-hub-file-meta {
	flex-shrink: 0; text-align: right; min-width: 70px;
	font-size: 12px; color: var(--hub-text-light);
}
.zsmh-dok-hub-file-date { display: block; font-size: 11px; margin-top: 2px; white-space: nowrap; }
.zsmh-dok-hub-file-action { flex-shrink: 0; }

/* ─── DESKTOP DOWNLOAD BUTTON (outlined with SVG) ─────────────────── */

a.zsmh-dok-hub-dl-btn {
	display: inline-flex; align-items: center; gap: 6px;
	padding: 7px 14px 7px 10px; font-size: 12px; font-weight: 700;
	font-family: var(--hub-font-body);
	color: var(--hub-primary-dark) !important; text-decoration: none !important;
	border-radius: 6px; border: 1.5px solid var(--hub-primary);
	background: #fff; transition: all 0.15s; white-space: nowrap;
}
a.zsmh-dok-hub-dl-btn:hover {
	background: var(--hub-primary); color: #fff !important;
}
a.zsmh-dok-hub-dl-btn svg {
	width: 16px; height: 16px; stroke: var(--hub-primary-dark);
	stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round;
	transition: stroke 0.15s;
}
a.zsmh-dok-hub-dl-btn:hover svg { stroke: #fff; }

/* ─── MOBILE ACTIONS (hidden on desktop) ───────────────────────────── */

.zsmh-dok-hub-mobile-actions { display: none; }

/* ─── LOCKED STATE ─────────────────────────────────────────────────── */

.zsmh-dok-hub-locked {
	display: inline-flex; align-items: center; gap: 4px;
	padding: 7px 14px; border-radius: 7px;
	background: #f3f4f6; color: var(--hub-text-light);
	font-size: 12px; border: none; cursor: default;
	font-family: var(--hub-font-body); white-space: nowrap;
}

/* ─── ARCHIVE: hidden by default ───────────────────────────────────── */

.zsmh-dok-hub-file[data-archiv="1"] { display: none !important; }
.zsmh-dok-hub.show-archiv .zsmh-dok-hub-file[data-archiv="1"] { display: flex !important; opacity: 0.55; border-style: dashed; }
.zsmh-dok-hub.show-archiv .zsmh-dok-hub-file[data-archiv="1"]:hover { opacity: 1; }
.zsmh-dok-hub.show-archiv .zsmh-dok-hub-file[data-archiv="1"].zsmh-dok-hidden { display: none !important; }

.zsmh-dok-hub-expired-badge {
	display: inline-block; margin-top: 3px; padding: 1px 6px; border-radius: 3px;
	font-size: 10px; font-weight: 600; background: #fce8e6; color: #c62828;
	text-transform: uppercase; letter-spacing: 0.3px;
}

/* ─── ARCHIVE NOTICE (per-section) ─────────────────────────────────── */

.zsmh-dok-hub-archiv-notice {
	display: flex; align-items: center; gap: 8px;
	padding: 12px 16px; margin-top: 4px;
	background: #f9f7f3; border: 1px dashed var(--hub-border);
	border-radius: 8px; font-size: 13px; color: var(--hub-text-muted);
}
.zsmh-dok-hub-archiv-notice-icon { font-size: 16px; flex-shrink: 0; }
.zsmh-dok-hub-archiv-notice-link {
	margin-left: auto; flex-shrink: 0;
	font-size: 12px; font-weight: 700; color: var(--hub-primary) !important;
	text-decoration: none !important; white-space: nowrap;
}
.zsmh-dok-hub-archiv-notice-link:hover { color: var(--hub-primary-dark) !important; text-decoration: underline !important; }
.zsmh-dok-hub.show-archiv .zsmh-dok-hub-archiv-notice { display: none; }

.zsmh-dok-hub-empty { text-align: center; padding: 32px 24px; color: var(--hub-text-light); font-style: italic; }

/* ─── DROPDOWN MENU ────────────────────────────────────────────────── */

.zsmh-dok-hub-btn-more { position: relative; }
.zsmh-dok-hub-dropdown {
	display: none; position: absolute; top: 100%; right: 0;
	margin-top: 4px; background: #fff; border: 1px solid var(--hub-border);
	border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,0.1);
	z-index: 10; min-width: 180px; overflow: hidden;
}
.zsmh-dok-hub-btn-more.open .zsmh-dok-hub-dropdown { display: block; }

.zsmh-dok-hub-dropdown a {
	display: flex; align-items: center; gap: 8px;
	padding: 10px 14px; font-size: 12px; color: var(--hub-text) !important;
	text-decoration: none !important; transition: background 0.1s;
	font-family: var(--hub-font-body);
}
.zsmh-dok-hub-dropdown a:hover { background: #f5f5f5; }
.zsmh-dok-hub-dropdown svg {
	width: 15px; height: 15px; stroke: var(--hub-text-muted);
	stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round;
	flex-shrink: 0;
}
.zsmh-dok-hub-dropdown-divider { height: 1px; background: var(--hub-border); }

/* ─── RESPONSIVE ─────────────────────────────────────────────────────── */

@media (max-width: 768px) {
	/* Switch to mobile layout */
	.zsmh-dok-hub-layout {
		display: block; border: none; background: transparent;
		width: 92%; border-radius: 0;
	}
	.zsmh-dok-hub-sidebar { display: none; }
	.zsmh-dok-hub-mobile-tiles { display: block; margin-bottom: 16px; }

	.zsmh-dok-hub-hero-row { flex-wrap: wrap; gap: 12px; }
	.zsmh-dok-hub-hero-inner { width: 92%; }
	.zsmh-dok-hub-controls { width: 100%; }
	.zsmh-dok-hub-search input[type="text"] { width: 100%; }
	.zsmh-dok-hub-title { font-size: 20px; }

	/* Main content */
	.zsmh-dok-hub-main {
		background: #fff; border: 1px solid var(--hub-border);
		border-radius: 10px; overflow: hidden;
	}

	/* File items on mobile */
	.zsmh-dok-hub-file { flex-wrap: wrap; gap: 8px; padding: 14px 16px; }
	.zsmh-dok-hub-file-info { flex: 1 1 calc(100% - 52px); }
	.zsmh-dok-hub-file-title { white-space: normal; }
	.zsmh-dok-hub-file-meta { text-align: left; min-width: auto; margin-left: 52px; font-size: 10px; }
	.zsmh-dok-hub-file-action { width: 100%; margin-left: 52px; }

	/* Hide desktop download, show mobile actions */
	a.zsmh-dok-hub-dl-btn { display: none !important; }
	.zsmh-dok-hub-mobile-actions {
		display: flex !important; align-items: center; gap: 6px;
	}

	/* Mobile "Otvoriť" button */
	.zsmh-dok-hub-btn-open {
		display: inline-flex; align-items: center; justify-content: center; gap: 4px;
		background: var(--hub-primary); color: #fff !important;
		border: none; border-radius: 8px; padding: 8px 12px;
		font-size: 11px; font-weight: 700; font-family: var(--hub-font-body);
		text-decoration: none !important; white-space: nowrap; cursor: pointer;
		transition: background 0.15s;
	}
	.zsmh-dok-hub-btn-open:hover { background: var(--hub-primary-dark); }
	.zsmh-dok-hub-btn-open svg {
		width: 14px; height: 14px; stroke: #fff;
		stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round;
	}

	/* Mobile "⋮" more button */
	.zsmh-dok-hub-btn-more {
		display: flex; align-items: center; justify-content: center;
		width: 36px; height: 36px; border-radius: 8px;
		border: 1.5px solid var(--hub-border); background: #fff;
		cursor: pointer; color: var(--hub-text-muted);
		font-size: 18px; line-height: 1; transition: all 0.15s;
		position: relative;
	}
	.zsmh-dok-hub-btn-more:hover,
	.zsmh-dok-hub-btn-more.open {
		border-color: var(--hub-primary); color: var(--hub-primary);
	}

	/* Folder tile responsive */
	.zsmh-dok-hub-folder-grid { gap: 8px; }
	.zsmh-dok-hub-folder-tile { padding: 12px 6px 10px; }
	.zsmh-dok-hub-folder-visual { width: 40px; height: 34px; }
	.zsmh-dok-hub-folder-back { width: 40px; height: 28px; border-radius: 0 4px 4px 4px; }
	.zsmh-dok-hub-folder-tab { width: 18px; height: 7px; }
	.zsmh-dok-hub-folder-front { width: 40px; height: 22px; }
	.zsmh-dok-hub-folder-name { font-size: 11px; }
	.zsmh-dok-hub-folder-count { font-size: 9px; }
}

@media (max-width: 600px) {
	/* List layout */
	.zsmh-dok-layout-list .zsmh-download-row { flex-wrap: wrap; gap: 8px; padding: 14px 8px; }
	.zsmh-dok-layout-list .zsmh-download-info { flex: 1 1 calc(100% - 50px); }
	.zsmh-dok-layout-list .zsmh-download-title { white-space: normal; font-size: 14px; }
	.zsmh-dok-layout-list .zsmh-download-size { order: 3; min-width: auto; text-align: left; margin-left: 50px; }
	.zsmh-dok-layout-list .zsmh-download-action { order: 4; margin-left: auto; }
	.zsmh-dok-compact-row { gap: 8px; overflow: hidden; }
	a.zsmh-dok-compact-title,
	span.zsmh-dok-compact-title { white-space: normal; font-size: 13px !important; }
	.zsmh-dok-compact-meta { font-size: 10px; white-space: nowrap; }
	.zsmh-dok-layout-card { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
	.zsmh-dok-card { padding: 16px 12px 14px; }
	.zsmh-dok-search { max-width: 100%; }
}

/* ─── EDIT BUTTON (only visible to logged-in editors/teachers) ─────── */
.zsmh-dok-edit-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 4px 8px;
	font-size: 11px;
	font-weight: 500;
	line-height: 1;
	color: #6b6b6b;
	background: transparent;
	border: 1px solid #d4d4d4;
	border-radius: 6px;
	text-decoration: none;
	transition: all 0.15s ease;
	cursor: pointer;
	margin-right: 6px;
	flex-shrink: 0;
}
.zsmh-dok-edit-btn:hover {
	color: #f19e00;
	border-color: #f19e00;
	background: #fff9ec;
	text-decoration: none;
}
.zsmh-dok-edit-btn:focus {
	outline: 2px solid #f19e00;
	outline-offset: 1px;
}
.zsmh-dok-edit-btn svg {
	display: block;
	flex-shrink: 0;
}

/* Hub layout: keep button small and aligned with file actions */
.zsmh-dok-edit-btn--hub {
	padding: 6px 10px;
	font-size: 11px;
}

/* Compact layout: icon-only (label hidden) to keep row tight */
.zsmh-dok-edit-btn--compact {
	padding: 3px 5px;
}
.zsmh-dok-edit-btn--compact .zsmh-dok-edit-btn-label {
	display: none;
}

/* Card layout: small button above download button */
.zsmh-dok-card-action {
	display: flex;
	flex-direction: column;
	gap: 6px;
	align-items: flex-end;
}
.zsmh-dok-edit-btn--card {
	padding: 3px 7px;
	font-size: 10px;
}
.zsmh-dok-edit-btn--card .zsmh-dok-edit-btn-label {
	display: none;
}

@media (max-width: 600px) {
	.zsmh-dok-edit-btn-label {
		display: none;
	}
	.zsmh-dok-edit-btn {
		padding: 4px 6px;
	}
}
