/* ============================================================
   KLGW Plugin Modules CSS — przeniesione z pluginu do motywu Wyraj
   ============================================================ */

/* --- WYSZUKIWARKA AJAX (step-62) --- */
.klgw-srch-wrap { width: min(1200px, calc(100% - 40px)); margin: 0 auto 60px; }

/* Hero */
.klgw-srch-hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 60%, #004d40 100%);
    border-radius: 24px;
    padding: 56px 40px 48px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}
.klgw-srch-hero::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(0,150,136,0.15) 0%, transparent 60%),
                radial-gradient(circle at 10% 80%, rgba(37,99,235,0.1) 0%, transparent 50%);
    pointer-events: none;
}
.klgw-srch-hero-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 3px; color: rgba(255,255,255,0.5); margin: 0 0 10px; }
.klgw-srch-hero-title { font-size: clamp(28px, 5vw, 48px); font-weight: 900; color: #fff; margin: 0 0 32px; line-height: 1.15; }

/* Search bar */
.klgw-srch-bar {
    display: flex; align-items: center; gap: 0;
    background: #fff;
    border-radius: 16px;
    padding: 6px 6px 6px 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    margin-bottom: 20px;
}
.klgw-srch-bar-icon { width: 20px; height: 20px; color: #94a3b8; flex-shrink: 0; }
.klgw-srch-input {
    flex: 1; border: none; outline: none; background: transparent;
    font-size: 17px; font-family: 'Inter', sans-serif;
    color: var(--color-text); padding: 10px 14px;
}
.klgw-srch-input::placeholder { color: #94a3b8; }
.klgw-srch-clear {
    background: #f1f5f9; border: none; border-radius: 10px;
    width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
    cursor: pointer; color: #64748b; transition: 0.2s; flex-shrink: 0;
}
.klgw-srch-clear:hover { background: #e2e8f0; }

/* Selects in hero */
.klgw-srch-selects { display: flex; gap: 12px; flex-wrap: wrap; }
.klgw-srch-select-wrap {
    display: flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 12px; padding: 10px 16px;
    color: rgba(255,255,255,0.8);
    backdrop-filter: blur(10px);
    transition: background 0.2s;
}
.klgw-srch-select-wrap:hover { background: rgba(255,255,255,0.15); }
.klgw-srch-select-wrap svg { flex-shrink: 0; }
.klgw-srch-select {
    background: transparent; border: none; outline: none;
    font-size: 13px; font-weight: 600; font-family: 'Inter', sans-serif;
    color: #fff; cursor: pointer;
    appearance: none; -webkit-appearance: none;
}
.klgw-srch-select option { color: var(--color-text); background: #fff; }

/* Kategorie */
.klgw-srch-cats-wrap {
    display: flex; flex-wrap: wrap; gap: 8px;
    padding: 20px 0; margin-bottom: 8px;
}
.klgw-srch-cat {
    display: inline-flex; align-items: center;
    padding: 7px 16px; border-radius: 30px;
    border: 1.5px solid var(--color-border);
    background: #fff;
    font-size: 12px; font-weight: 700; font-family: 'Inter', sans-serif;
    color: var(--color-slate-dark); cursor: pointer;
    transition: all 0.15s; white-space: nowrap;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.klgw-srch-cat:hover {
    border-color: var(--cat-color, var(--color-blue));
    color: var(--cat-color, var(--color-blue));
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.klgw-srch-cat.is-active {
    background: var(--cat-color, #0f172a);
    border-color: var(--cat-color, #0f172a);
    color: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Status i wyniki */
.klgw-srch-status {
    font-size: 12px; font-weight: 800; text-transform: uppercase;
    letter-spacing: 1px; color: var(--color-slate-light);
    margin-bottom: 20px; min-height: 18px;
}
.klgw-srch-empty {
    text-align: center; padding: 80px 20px;
    color: var(--color-slate-light);
}
.klgw-srch-empty-icon { font-size: 48px; margin-bottom: 16px; opacity: 0.4; }
.klgw-srch-empty p    { font-size: 15px; margin: 0; }

@keyframes klgw-fadein { from { opacity:0; transform:translateY(8px); } to { opacity:1; transform:none; } }
#klgw-srch-results .klgw-s-card { animation: klgw-fadein 0.25s ease both; }
#klgw-srch-results .klgw-s-card:nth-child(2) { animation-delay: 0.04s; }
#klgw-srch-results .klgw-s-card:nth-child(3) { animation-delay: 0.08s; }
#klgw-srch-results .klgw-s-card:nth-child(4) { animation-delay: 0.12s; }

@media (max-width: 640px) {
    .klgw-srch-hero  { padding: 36px 20px 32px; border-radius: 16px; }
    .klgw-srch-selects { flex-direction: column; }
    .klgw-srch-select-wrap { width: 100%; }
}

/* --- ARCHIWUM taksonomii (step-17) --- */
.klgw-arch-scope { width: min(1200px, calc(100% - 40px)); margin: 40px auto; padding: 0; font-family: 'Inter', sans-serif; color: var(--color-text-mid); }
.klgw-arch-header { text-align: center; margin-bottom: 50px; }
.klgw-arch-label { font-size: 12px; text-transform: uppercase; color: var(--color-slate-light); font-weight: 800; letter-spacing: 1px; }
.klgw-arch-title { font-size: 2.5rem; font-weight: 800; color: var(--color-text-dark); margin: 10px 0; }

.klgw-sec-divider { border-bottom: 2px solid var(--color-border-light); margin: 60px 0 30px; display: flex; justify-content: space-between; align-items: center; padding-bottom: 10px; }
.klgw-sec-divider h2 { font-size: 1.4rem; font-weight: 800; margin: 0; color: var(--color-text); }
.klgw-sec-count { font-size: 11px; background: var(--color-border-light); padding: 4px 10px; border-radius: 20px; color: var(--color-slate-dark); font-weight: 700; }

.klgw-day-sep { display: flex; align-items: center; gap: 15px; margin: 40px 0 20px 0; padding: 15px 20px; background: #fff; border-radius: 12px; border-left: 5px solid var(--color-blue); box-shadow: 0 4px 12px rgba(0,0,0,0.04); }
.klgw-ds-sheet { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: 10px; padding: 10px 18px; text-align: center; min-width: 70px; }
.klgw-ds-day { font-size: 26px; font-weight: 900; color: var(--color-text); line-height: 1; display: block; }
.klgw-ds-month { font-size: 11px; text-transform: uppercase; color: var(--color-blue); font-weight: 800; display: block; margin-top: 4px; }
.klgw-ds-info { font-size: 15px; font-weight: 800; color: var(--color-text-dark); }

/* --- WYSZUKIWARKA (step-17) --- */
.klgw-search-wrap { width: min(1200px, calc(100% - 40px)); margin: 60px auto; padding: 0; font-family: 'Inter', sans-serif; color: var(--color-text-mid); }
.klgw-search-header { text-align: center; margin-bottom: 50px; padding-bottom: 30px; border-bottom: 1px solid var(--color-border); }
.klgw-search-label { font-size: 13px; text-transform: uppercase; letter-spacing: 2px; color: var(--color-slate-light); font-weight: 800; margin-bottom: 10px; display: block; }
.klgw-search-title { font-size: 2.2rem; font-weight: 900; color: var(--color-text-dark); margin: 0; }
.klgw-search-query { color: var(--color-blue); }
.klgw-sec-title { font-size: 1.6rem; font-weight: 900; color: var(--color-text); margin: 60px 0 30px 0; padding-bottom: 15px; border-bottom: 2px solid var(--color-blue); display: flex; align-items: center; justify-content: space-between; }
.klgw-sec-title span { font-size: 12px; font-weight: 800; color: var(--color-blue); background: #eff6ff; padding: 5px 15px; border-radius: 20px; }
.klgw-ds-title { font-size: 18px; font-weight: 800; color: var(--color-text-dark); margin: 0; }
.klgw-no-results { text-align: center; padding: 80px 20px; background: var(--color-surface); border-radius: 20px; border: 2px dashed var(--color-border); }

/* --- [event_slider] nagłówek (step-24) --- */
.klgw-native-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 2px solid var(--color-border-light); }
.klgw-native-title { font-size: 1.6rem; font-weight: 800; color: var(--color-text-dark); margin: 0; }

/* --- MIEJSCA — NOWOCZESNY WIDOK MIEJSCA (WYRAJ STANDARD) --- */
.klgw-place-container,
.klgw-place-main-wrap {
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto;
    padding: 24px 0 60px;
    color: #0f172a;
}

/* Ukryj ewentualny domyślny tytuł strony "miejsce" z szablonu WordPress */
body.page-id-miejsce .wp-block-post-title,
.klgw-place-main-wrap > .wp-block-post-title,
.klgw-place-container > .wp-block-post-title {
    display: none !important;
}

.klgw-place-view {
    width: 100%;
    margin: 0 auto;
}

/* Place Hero Card */
.klgw-place-hero {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 28px 32px;
    margin-bottom: 32px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 10px 25px -5px rgba(0, 0, 0, 0.03);
    position: relative;
}

.klgw-place-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 12px;
}

.klgw-place-label {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #0284c7;
    display: block;
    margin-bottom: 6px;
}

.klgw-place-title {
    font-family: var(--wp--preset--font-family--accent, 'Montserrat', sans-serif);
    font-size: clamp(26px, 4vw, 40px);
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: #0f172a;
    margin: 0 0 10px !important;
}

.klgw-place-addr {
    font-size: 14px;
    color: #64748b;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 14px;
}

.klgw-place-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.klgw-p-badge {
    background: #f8fafc;
    color: #475569;
    padding: 5px 12px;
    border-radius: 9999px;
    font-size: 12px;
    font-weight: 700;
    border: 1px solid #e2e8f0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.klgw-p-badge.featured {
    background: #fef9c3;
    color: #854d0e;
    border-color: #fef08a;
}

.klgw-place-desc {
    font-size: 15px;
    line-height: 1.6;
    color: #334155;
    margin: 16px 0 20px;
    max-width: 820px;
}

.klgw-place-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid #f1f5f9;
}

.klgw-action-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none !important;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1px solid transparent;
}

.klgw-action-pill:hover {
    transform: translateY(-2px);
}

.klgw-pill-nav {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}
.klgw-pill-nav:hover {
    box-shadow: 0 6px 16px rgba(2, 132, 199, 0.35);
}

.klgw-pill-social {
    background: #f8fafc;
    color: #334155 !important;
    border-color: #e2e8f0;
}
.klgw-pill-social:hover {
    background: #f1f5f9;
    color: #0f172a !important;
    border-color: #cbd5e1;
}

.klgw-pill-fb:hover { color: #1877f2 !important; border-color: #bae6fd; background: #f0f9ff; }
.klgw-pill-ig:hover { color: #e1306c !important; border-color: #fbcfe8; background: #fdf2f8; }
.klgw-pill-tt:hover { color: #000000 !important; }
.klgw-pill-www:hover { color: #0284c7 !important; border-color: #bae6fd; background: #f0f9ff; }

.klgw-pill-share {
    background: #0f172a;
    color: #ffffff !important;
}
.klgw-pill-share:hover {
    background: #1e293b;
}

/* Gallery Slider */
.klgw-place-gallery-slider {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    border-radius: 16px;
    margin-bottom: 24px;
}
.klgw-place-gallery-slide {
    flex: 0 0 calc(50% - 6px);
    scroll-snap-align: start;
    height: 280px;
    border-radius: 14px;
    overflow: hidden;
}
@media (max-width: 640px) {
    .klgw-place-gallery-slide {
        flex: 0 0 100%;
        height: 220px;
    }
}
.klgw-place-gallery-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Sekcje na stronie miejsca */
.klgw-p-sec-title {
    font-family: var(--wp--preset--font-family--accent, 'Montserrat', sans-serif);
    font-size: 22px;
    font-weight: 800;
    color: #0f172a;
    margin: 36px 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-left: 0;
    border-left: none;
}

.klgw-count-pill {
    font-size: 12px;
    font-weight: 800;
    background: #e0f2fe;
    color: #0284c7;
    padding: 4px 12px;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Visitor Guide Card */
.klgw-guide-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 26px 30px;
    margin: 32px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.klgw-guide-card h2.klgw-guide-main-title {
    font-family: var(--wp--preset--font-family--accent, 'Montserrat', sans-serif);
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 18px;
}

.klgw-guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.klgw-guide-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 16px 18px;
}

.klgw-guide-item h3 {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 800;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 6px;
}

.klgw-guide-item p {
    margin: 0;
    font-size: 13px;
    color: #475569;
    line-height: 1.5;
}

/* Map container */
.klgw-place-map-wrap {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    overflow: hidden;
    margin: 32px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.klgw-place-map-header {
    padding: 18px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.klgw-place-map-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.klgw-single-map-canvas {
    height: 340px;
    width: 100%;
}

/* Collapsible Past Archive */
.klgw-archive-accordion {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    margin: 32px 0;
    overflow: hidden;
}

.klgw-archive-accordion summary {
    padding: 18px 22px;
    cursor: pointer;
    font-weight: 800;
    font-size: 15px;
    color: #0f172a;
    background: #f8fafc;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    list-style: none;
}
.klgw-archive-accordion summary::-webkit-details-marker {
    display: none;
}

.klgw-archive-accordion[open] summary {
    border-bottom: 1px solid #e2e8f0;
}

.klgw-toggle-hint {
    font-size: 13px;
    font-weight: 700;
    color: #0284c7;
}

.klgw-no-events {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    padding: 24px;
    text-align: center;
    color: #64748b;
    font-weight: 600;
    font-size: 14px;
    margin: 20px 0;
}

/* Heatmap kalendarza */
.klgw-heatmap-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 24px;
    margin: 32px 0;
}
.klgw-cal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 16px; }
.klgw-cal-m-name { font-size: 11px; text-transform: uppercase; color: #64748b; margin-bottom: 8px; font-weight: 800; }
.klgw-heatmap { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.klgw-heatmap-cell { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; font-size: 10px; border-radius: 4px; font-weight: 700; text-decoration: none; }
.klgw-heatmap-cell.has-event { cursor: pointer; transition: 0.2s; }
.klgw-heatmap-cell.has-event:hover { transform: scale(1.2); z-index: 10; box-shadow: 0 4px 10px rgba(2,132,199,0.3); }

/* --- INDEKS MIEJSC [klgw_miejsca] (step-37) --- */
.klgw-places-index { width: min(1200px, calc(100% - 40px)); margin: 0 auto; font-family: 'Inter', sans-serif; }

.klgw-places-header {
    background: linear-gradient(135deg, #0f172a 0%, #1a3a52 60%, #004d40 100%);
    border-radius: 24px; padding: 56px 40px 48px;
    margin-bottom: 40px; text-align: center; position: relative; overflow: hidden;
}
.klgw-places-header::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 70% 30%, rgba(0,150,136,0.15) 0%, transparent 55%),
                radial-gradient(circle at 20% 70%, rgba(37,99,235,0.1) 0%, transparent 50%);
    pointer-events: none;
}
.klgw-places-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 3px; color: rgba(255,255,255,0.5); margin: 0 0 10px; }
.klgw-places-title { font-size: clamp(28px, 5vw, 46px); font-weight: 900; color: #fff; margin: 0 0 12px; line-height: 1.15; }
.klgw-places-sub   { font-size: 15px; color: rgba(255,255,255,0.6); margin: 0; }

.klgw-places-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

.klgw-place-card-idx {
    display: flex; align-items: center; gap: 16px;
    background: #fff; border: 1.5px solid var(--color-border);
    border-radius: 18px; padding: 20px;
    text-decoration: none; color: inherit;
    box-shadow: 0 4px 14px rgba(0,0,0,0.04);
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
    position: relative;
}
.klgw-place-card-idx:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.1);
    border-color: var(--color-blue);
}
.klgw-place-card-idx.no-events { opacity: 0.55; }
.klgw-place-card-idx.no-events:hover { opacity: 0.8; }

.klgw-place-card-idx-avatar {
    width: 52px; height: 52px; flex-shrink: 0;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--color-blue) 0%, #004d40 100%);
    display: flex; align-items: center; justify-content: center;
    font-size: 22px; font-weight: 900; color: #fff;
    text-transform: uppercase;
}
.klgw-place-card-idx.no-events .klgw-place-card-idx-avatar {
    background: linear-gradient(135deg, var(--color-slate-light) 0%, #94a3b8 100%);
}

.klgw-place-card-idx-body { flex: 1; min-width: 0; }
.klgw-place-card-idx-name { font-size: 15px; font-weight: 800; color: var(--color-text-dark); margin: 0 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.klgw-place-card-idx-desc { font-size: 12px; color: var(--color-slate-light); margin: 0 0 8px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.klgw-place-card-idx-foot { display: flex; align-items: center; gap: 8px; }

.klgw-place-badge-upcoming {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px;
    background: #eff6ff; color: var(--color-blue);
    padding: 3px 10px; border-radius: 20px;
}
.klgw-place-badge-none {
    font-size: 10px; font-weight: 700; color: var(--color-slate-light);
    background: var(--color-surface); padding: 3px 10px; border-radius: 20px;
}

.klgw-place-card-idx-arrow {
    color: var(--color-slate-light); font-size: 18px; flex-shrink: 0;
    transition: transform 0.2s, color 0.2s;
}
.klgw-place-card-idx:hover .klgw-place-card-idx-arrow { transform: translateX(4px); color: var(--color-blue); }

@media (max-width: 640px) {
    .klgw-places-header { padding: 36px 20px 32px; border-radius: 16px; }
    .klgw-places-grid   { grid-template-columns: 1fr; }
}

/* --- OSTATNIO DODANE [klgw_recent] / [klgw_updated] (step-28) --- */
.klgw-recent-scope {
    width: min(1200px, calc(100% - 32px));
    margin: 20px auto 40px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.klgw-recent-day { 
    margin-bottom: 32px; 
}

.klgw-recent-day-hdr {
    display: flex; 
    align-items: center; 
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 2px solid #e2e8f0;
    margin-bottom: 12px;
}
.klgw-recent-day-label {
    font-size: 14px; 
    font-weight: 800; 
    text-transform: uppercase;
    letter-spacing: 0.8px; 
    color: #0f172a;
}
.klgw-recent-day-count {
    font-size: 11px; 
    font-weight: 700;
    background: #f1f5f9; 
    color: #475569;
    padding: 4px 12px; 
    border-radius: 9999px;
    border: 1px solid #e2e8f0;
}

.klgw-recent-list { 
    display: flex; 
    flex-direction: column; 
    gap: 12px;
}

/* Karta wiersza — nowoczesny mobilny kafelek */
.klgw-recent-row {
    display: flex; 
    align-items: center; 
    gap: 16px;
    padding: 12px 14px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-left: 4px solid var(--accent, #0284c7);
    border-radius: 14px;
    text-decoration: none; 
    color: inherit;
    transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.18s ease, border-color 0.18s ease;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 2px 6px rgba(15, 23, 42, 0.02);
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}

.klgw-recent-row:hover {
    background: #ffffff;
    transform: translateY(-2px);
    border-color: #cbd5e1;
    border-left-color: var(--accent, #0284c7);
    box-shadow: 0 8px 20px -4px rgba(15, 23, 42, 0.08), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
}

.klgw-recent-row:active {
    transform: scale(0.99);
}

/* Miniaturka — kwadratowa lub 4:3 ze zbalansowanym kadrowaniem */
.klgw-recent-thumb {
    width: 84px; 
    height: 84px; 
    flex-shrink: 0;
    border-radius: 10px; 
    overflow: hidden;
    background: #0f172a;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
.klgw-recent-thumb img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    object-position: center 20%;
    display: block; 
}

/* Ciało kafelka */
.klgw-recent-body { 
    flex: 1; 
    min-width: 0; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

/* Data wydarzenia na samej górze kafelka */
.klgw-recent-when { 
    display: flex;
    align-items: center;
    gap: 4px;
}
.klgw-recent-when-date {
    font-size: 11px; 
    font-weight: 800; 
    color: #0284c7;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    line-height: 1.2;
}
.klgw-recent-calendar-icon {
    font-size: 11px;
    line-height: 1;
}
.klgw-recent-when-past {
    font-size: 11px; 
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

/* Tytuł wydarzenia — pełny lub 2 linie bez ucinania na jednym słowie */
.klgw-recent-title {
    font-size: 15px; 
    font-weight: 800; 
    color: #0f172a;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
    font-family: var(--wp--preset--font-family--accent, 'Montserrat', sans-serif);
}

/* Pasek meta z tagami i miejscem */
.klgw-recent-meta { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 6px; 
    align-items: center; 
    margin-top: 2px;
}

.klgw-recent-place {
    font-size: 11px; 
    font-weight: 600;
    color: #64748b;
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    max-width: 200px;
}

.klgw-recent-cat {
    font-size: 10px; 
    font-weight: 800; 
    text-transform: uppercase; 
    letter-spacing: 0.4px;
    padding: 3px 9px; 
    border-radius: 9999px; 
    white-space: nowrap;
    border: 1px solid currentColor;
    opacity: 0.92;
}

.klgw-recent-series {
    font-size: 10px; 
    font-weight: 800; 
    color: #2563eb;
    background: #eff6ff; 
    border: 1px solid #bfdbfe;
    padding: 3px 8px; 
    border-radius: 9999px;
    white-space: nowrap;
}

.klgw-recent-price {
    font-size: 10px; 
    font-weight: 800; 
    color: #047857;
    background: #ecfdf5; 
    border: 1px solid #a7f3d0;
    padding: 3px 8px; 
    border-radius: 9999px;
    white-space: nowrap;
}

/* Strzałka nawigacyjna z prawej strony */
.klgw-recent-arrow-wrap {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.klgw-recent-arrow {
    font-size: 18px;
    font-weight: 600;
    line-height: 1;
    margin-left: 1px;
}

.klgw-recent-row:hover .klgw-recent-arrow-wrap {
    background: #0284c7;
    border-color: #0284c7;
    color: #ffffff;
    transform: translateX(2px);
}

/* Optymalizacja mobilna pod telefony (≤640px) */
@media (max-width: 640px) {
    .klgw-recent-scope { 
        width: calc(100% - 20px); 
        margin: 14px auto 30px;
    }
    .klgw-recent-row {
        gap: 12px;
        padding: 10px 12px;
    }
    .klgw-recent-thumb {
        width: 76px;
        height: 76px;
        border-radius: 8px;
    }
    .klgw-recent-title {
        font-size: 13.5px;
        line-height: 1.28;
    }
    .klgw-recent-place {
        max-width: 150px;
    }
    .klgw-recent-arrow-wrap {
        display: none; /* Czysty widok na telefonie */
    }
}

@media (max-width: 380px) {
    .klgw-recent-thumb {
        width: 68px;
        height: 68px;
    }
    .klgw-recent-title {
        font-size: 12.5px;
    }
    .klgw-recent-place {
        max-width: 120px;
    }
}
