/* Theme-agnostic: inherits fonts and text color from the active theme. */
.ubeh-list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.ubeh-card { border: 1px solid color-mix(in srgb, currentColor 18%, transparent); border-radius: 6px; overflow: hidden; display: flex; flex-direction: column; }
.ubeh-card.is-featured { border-color: var(--ubeh-accent, #c8102e); border-width: 2px; }
.ubeh-thumb img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.ubeh-body { padding: .85rem 1rem 1rem; }
.ubeh-body h3 { margin: .2rem 0 .4rem; font-size: 1.1rem; line-height: 1.3; }
.ubeh-meta { margin: 0; font-size: .9rem; opacity: .75; }
.ubeh-badge { display: inline-block; font-size: .75rem; padding: .1rem .5rem; background: var(--ubeh-accent, #c8102e); color: #fff; border-radius: 3px; }
.ubeh-details { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; padding: 1rem; margin: 0 0 1.5rem; border-left: 4px solid var(--ubeh-accent, #c8102e); background: color-mix(in srgb, currentColor 5%, transparent); }
.ubeh-details dt { font-weight: 600; } .ubeh-details dd { margin: 0; }
.ubeh-empty, .ubeh-notice { padding: .75rem 1rem; border-radius: 4px; background: color-mix(in srgb, currentColor 7%, transparent); }
.ubeh-ok { border-left: 4px solid #2e7d32; } .ubeh-error, .ubeh-limit, .ubeh-image { border-left: 4px solid var(--ubeh-accent, #c8102e); }
.ubeh-form { max-width: 640px; }
.ubeh-row label { display: block; } .ubeh-row span { display: block; font-weight: 600; margin-bottom: .25rem; }
.ubeh-form input[type=text], .ubeh-form input[type=url], .ubeh-form input[type=email], .ubeh-form input[type=date], .ubeh-form select, .ubeh-form textarea { width: 100%; box-sizing: border-box; padding: .5rem .6rem; }
.ubeh-hp { position: absolute; left: -9999px; }
.ubeh-btn { padding: .6rem 1.4rem; background: var(--ubeh-accent, #c8102e); color: #fff; border: 0; border-radius: 4px; cursor: pointer; font: inherit; }
.ubeh-btn:hover, .ubeh-btn:focus-visible { background: color-mix(in srgb, var(--ubeh-accent, #c8102e) 80%, #000); }
.ubeh-counter { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: .95rem; }
.ubeh-ad { text-align: center; margin: 1rem 0; position: relative; }
.ubeh-ad img { max-width: 100%; height: auto; }
.ubeh-ad-in-listing { grid-column: 1 / -1; }
.ubeh-ad-label { display: block; font-size: .7rem; opacity: .55; }
@media (prefers-reduced-motion: no-preference) { .ubeh-btn { transition: background .15s; } }

/* ---------- Home page/* ---------- Home dashboard [ub_home] ---------- */
body:has(.ubeh-home) { overflow-x: clip; }
body:has(.ubeh-home) .wp-block-post-title, body:has(.ubeh-home) .entry-title { display: none; }
.ubeh-home {
  --bg: #070d1c; --card: rgba(255,255,255,.05); --line: rgba(255,255,255,.13); --grid: rgba(120,160,255,.06);
  --text: #eef2ff; --muted: #a9b4d0; --blue: #3b82f6; --red: #f0584e; --green: #34d399; --accent: var(--ubeh-accent, #f0584e);
  width: 100vw; max-width: 100vw; margin-inline: calc(50% - 50vw); box-sizing: border-box;
  background-color: var(--bg); color: var(--text);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 44px 44px; scroll-behavior: smooth;
}
.ubeh-home[data-theme="light"] { --bg: #f3f5fb; --card: #fff; --line: rgba(15,23,42,.14); --grid: rgba(15,23,42,.04); --text: #0f172a; --muted: #475569; }
.ubeh-home a { color: inherit; }
.ubeh-wrap { max-width: 1180px; margin-inline: auto; padding-inline: 1.25rem; box-sizing: border-box; }
.ubeh-home .ubeh-btn { background: var(--accent); color: #fff; text-decoration: none; display: inline-block; padding: .65rem 1.25rem; border-radius: 8px; font-weight: 700; }
.ubeh-home .ubeh-btn:hover, .ubeh-home .ubeh-btn:focus-visible { filter: brightness(1.1); background: var(--accent); }

/* top bar */
.ubeh-bar { border-bottom: 3px solid var(--red); background: color-mix(in srgb, var(--bg) 92%, #000); position: sticky; top: 0; z-index: 20; }
.ubeh-bar-in { display: flex; align-items: center; gap: 1.5rem; padding-block: .8rem; }
.ubeh-brand { display: flex; flex-direction: column; line-height: 1.15; flex: none; }
.ubeh-brand strong { font-size: 1.25rem; font-weight: 800; }
.ubeh-brand span { font-size: .78rem; color: var(--muted); }
.ubeh-tabs { display: flex; gap: .25rem; overflow-x: auto; flex: 1; scrollbar-width: none; }
.ubeh-tabs a { text-decoration: none; padding: .55rem 1rem; border-radius: 8px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.ubeh-tabs a:hover { color: var(--text); }
.ubeh-tabs a.is-active { background: var(--blue); color: #fff; }
.ubeh-bar-actions { display: flex; align-items: center; gap: .6rem; flex: none; }
.ubeh-icon-btn { width: 2.6rem; height: 2.6rem; display: grid; place-items: center; border-radius: 8px; border: 1px solid var(--line); background: transparent; color: var(--text); cursor: pointer; }
.ubeh-icon-btn:hover { border-color: var(--blue); }

.ubeh-main { padding-block: 2rem 3rem; }
.ubeh-intro { margin-bottom: 1.75rem; }
.ubeh-title { margin: 0; padding-left: 1rem; border-left: 5px solid var(--red); font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.08; font-weight: 800; letter-spacing: -.02em; color: var(--text); }
.ubeh-sub { margin: .75rem 0 1.25rem 1.25rem; font-size: 1.1rem; color: var(--muted); max-width: 42em; }
.ubeh-search { display: flex; gap: .5rem; max-width: 600px; margin-left: 1.25rem; }
.ubeh-search input[type=search] { flex: 1; min-width: 0; padding: .8rem 1rem; font: inherit; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: 8px; }
.ubeh-search input::placeholder { color: var(--muted); }

/* cards and tiles */
.ubeh-card, .ubeh-tile, .ubeh-ev, .ubeh-emb, .ubeh-guide { background: var(--card); border: 1px solid var(--line); border-radius: 14px; }
.ubeh-card { border-top: 4px solid var(--blue); padding: 1.25rem 1.5rem; margin-bottom: 1.25rem; }
.ubeh-card h3 { margin: 0 0 .35rem; font-size: 1.25rem; }
.ubeh-card p { margin: 0 0 1rem; color: var(--muted); }
.ubeh-card.is-green { border-top-color: var(--green); } .ubeh-card.is-red { border-top-color: var(--red); } .ubeh-card.is-blue { border-top-color: var(--blue); }
.ubeh-card > p:last-child { margin-bottom: 0; }

.ubeh-tiles { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); margin-bottom: 1.25rem; }
.ubeh-tile { display: flex; flex-direction: column; gap: .35rem; padding: 1rem 1.15rem 1.1rem; border-top: 4px solid var(--blue); text-decoration: none; }
.ubeh-tile.is-green { border-top-color: var(--green); } .ubeh-tile.is-red { border-top-color: var(--red); }
a.ubeh-tile:hover, a.ubeh-tile:focus-visible { border-color: var(--red); transform: translateY(-2px); }
.ubeh-tile-label { color: var(--muted); font-size: .92rem; }
.ubeh-big { font-size: clamp(1.9rem, 3.4vw, 2.6rem); line-height: 1; font-weight: 800; letter-spacing: -.02em; color: var(--text); }
.ubeh-tile-sub { color: var(--muted); font-size: .85rem; font-weight: 600; }

.ubeh-sec { margin: 2.75rem 0; scroll-margin-top: 6rem; }
.ubeh-sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: 1rem; }
.ubeh-sec-head h2 { margin: 0; font-size: 1.6rem; font-weight: 800; color: var(--text); }
.ubeh-sec-head a, .ubeh-sec-head span { font-size: .92rem; color: var(--muted); }

.ubeh-ev-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); }
.ubeh-ev { display: flex; gap: 1rem; align-items: center; padding: .9rem; text-decoration: none; }
.ubeh-ev:hover, .ubeh-ev:focus-visible { border-color: var(--blue); }
.ubeh-ev.is-featured { border-color: var(--red); }
.ubeh-date { flex: none; width: 4.2rem; padding: .55rem 0; text-align: center; background: var(--red); color: #fff; border-radius: 10px; line-height: 1; }
.ubeh-date b { display: block; font-size: 1.9rem; font-weight: 800; }
.ubeh-date span { display: block; margin-top: .25rem; font-size: .85rem; }
.ubeh-ev-text { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.ubeh-ev-text strong { font-size: 1.08rem; line-height: 1.25; }
.ubeh-ev-text span { font-size: .9rem; color: var(--muted); }
.ubeh-ev-text .ubeh-price { color: var(--green); font-weight: 700; }

.ubeh-cl-list { display: grid; gap: 0 2rem; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
.ubeh-cl { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: .85rem 0; text-decoration: none; border-bottom: 1px solid var(--line); }
.ubeh-cl:hover strong, .ubeh-cl:focus-visible strong { text-decoration: underline; }
.ubeh-cl.is-featured strong::before { content: "Featured: "; color: var(--red); }
.ubeh-cl-text { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.ubeh-cl-text span { font-size: .88rem; color: var(--muted); }
.ubeh-cl-price { flex: none; font-weight: 800; color: var(--green); }

.ubeh-filterbar { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.ubeh-filter { flex: 1; max-width: 420px; padding: .7rem 1rem; font: inherit; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: 8px; }
.ubeh-count { color: var(--muted); font-size: .9rem; }
.ubeh-emb-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.ubeh-emb { padding: 1.1rem 1.25rem; border-top: 4px solid var(--blue); }
.ubeh-emb[hidden] { display: none; }
.ubeh-emb h3 { margin: 0 0 .6rem; font-size: 1.2rem; }
.ubeh-emb dl { display: grid; grid-template-columns: 5.5rem 1fr; gap: .35rem .75rem; margin: 0; font-size: .93rem; }
.ubeh-emb dt { color: var(--muted); } .ubeh-emb dd { margin: 0; overflow-wrap: anywhere; }
.ubeh-emb-foot { display: flex; justify-content: space-between; gap: 1rem; margin: .9rem 0 0; font-size: .85rem; color: var(--muted); }
.ubeh-emb-foot a { color: var(--blue); font-weight: 600; }
.ubeh-fineprint { margin-top: 1rem; font-size: .88rem; color: var(--muted); }

.ubeh-guide-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.ubeh-guide { display: flex; flex-direction: column; gap: .5rem; padding: 1.15rem 1.25rem; text-decoration: none; border-top: 4px solid var(--green); }
.ubeh-guide:hover, .ubeh-guide:focus-visible { border-color: var(--green); transform: translateY(-2px); }
.ubeh-guide strong { font-size: 1.12rem; line-height: 1.25; }
.ubeh-guide span { color: var(--muted); font-size: .93rem; }
.ubeh-guide .ubeh-more { color: var(--green); font-weight: 700; margin-top: auto; }

.ubeh-cta { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin: 3rem 0 2rem; }
.ubeh-cta .ubeh-card { margin: 0; }
.ubeh-home .ubeh-empty { background: var(--card); border: 1px dashed var(--line); color: var(--muted); }
.ubeh-home .ubeh-empty a { color: var(--blue); }
.ubeh-home .ubeh-ad-label { color: var(--muted); }
.ubeh-home a:focus-visible, .ubeh-home button:focus-visible, .ubeh-home input:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .ubeh-home { scroll-behavior: auto; } a.ubeh-tile:hover, .ubeh-guide:hover { transform: none; } }
@media (max-width: 820px) { .ubeh-bar-in { flex-wrap: wrap; gap: .6rem; } .ubeh-tabs { order: 3; flex-basis: 100%; } .ubeh-bar-actions { margin-left: auto; } }
@media (max-width: 560px) { .ubeh-search { flex-direction: column; margin-left: 0; } .ubeh-sub { margin-left: 0; } .ubeh-ev-grid, .ubeh-cl-list, .ubeh-emb-grid { grid-template-columns: 1fr; } .ubeh-bar-actions .ubeh-btn { display: none; } }
