/* Live Event aggregator — page + widget styles */
:root {
    --le-bg: var(--ax-panel, #0a1018);
    --le-card: var(--ax-card, #0e1622);
    --le-card-hover: var(--ax-card-2, #101a27);
    --le-text: #c7d4e4;
    --le-muted: #8b9cb3;
    --le-head: var(--ax-text, #e6edf7);
    --le-accent: var(--ax-blue, #2f6bff);
    --le-green: var(--ax-green, #22c55e);
    --le-yellow: var(--ax-gold, #f0b429);
    --le-red: var(--ax-red, #ef4444);
    --le-border: var(--ax-line-2, #1d2a3c);
}

/* ---------- Page ---------- */
.le-container {
    background: var(--le-bg);
    color: var(--le-text);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.24);
    margin-bottom: 24px;
    border: 1px solid #1d2a3c;
}

.le-hero {
    background: linear-gradient(135deg, var(--ax-card, #0e1622) 0%, var(--ax-bg, #04070d) 100%);
    padding: 2rem;
    border-bottom: 1px solid var(--le-border);
    position: relative;
}

.le-hero-title {
    font-size: 1.9rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 .4rem;
}

.le-hero-desc {
    color: var(--le-muted);
    margin: 0;
}

.le-updated {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    font-size: .75rem;
    color: var(--le-muted);
}

.le-body {
    padding: 1.5rem;
}

.le-section {
    margin-bottom: 1.75rem;
}

.le-section-title {
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--le-muted);
    margin: 0 0 .85rem;
    font-weight: 700;
}

.le-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

/* ---------- Card ---------- */
.le-card {
    background: var(--le-card);
    border: 1px solid var(--le-border);
    border-radius: 8px;
    padding: 1rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: .55rem;
    transition: background .15s ease, transform .15s ease;
    text-decoration: none !important;
    color: var(--le-text) !important;
    cursor: pointer;
}

.le-card:hover {
    background: var(--le-card-hover);
    color: var(--le-text) !important;
}

.le-card-head {
    display: flex;
    align-items: center;
    gap: .65rem;
}

.le-card-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(88, 101, 242, 0.15);
    color: var(--le-accent);
    font-size: 1.05rem;
}

.le-card-title {
    font-weight: 700;
    color: var(--le-head);
    font-size: 1.02rem;
    line-height: 1.25;
}

.le-card-sub {
    color: var(--le-muted);
    font-size: .82rem;
}

.le-card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: .05rem;
}

.le-badge {
    font-size: .72rem;
    font-weight: 700;
    padding: 0rem .5rem;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    white-space: nowrap;
}

.le-badge.le-live {
    background: rgba(35, 165, 89, 0.18);
    color: var(--ax-green, #22c55e);
}

.le-badge.le-soon {
    background: rgba(240, 178, 50, 0.18);
    color: var(--le-yellow);
}

.le-badge.le-soon .le-dot,
.le-badge.le-live .le-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    animation: le-pulse 1.4s infinite;
}

.le-badge.le-upcoming {
    background: rgba(148, 155, 164, 0.18);
    color: var(--le-muted);
}

.le-badge.le-ongoing {
    background: rgba(88, 101, 242, 0.18);
    color: var(--ax-sky, #38a8f0);
}

.le-card.is-soon {
    border-color: rgba(240, 178, 50, 0.5);
    box-shadow: 0 0 0 1px rgba(240, 178, 50, 0.25);
}

.le-countdown {
    font-variant-numeric: tabular-nums;
    font-weight: 700;
    color: var(--le-head);
    font-size: .85rem;
}

.le-cta {
    background: var(--le-accent);
    color: #fff !important;
    text-decoration: none;
    font-size: .82rem;
    font-weight: 600;
    padding: .4rem .85rem;
    border-radius: 5px;
    transition: background .15s ease;
}

.le-cta:hover {
    background: var(--ax-blue, #2f6bff);
}

.le-empty {
    text-align: center;
    color: var(--le-muted);
    padding: 3rem 1rem;
}

.le-empty i {
    font-size: 2.5rem;
    display: block;
    margin-bottom: .75rem;
    opacity: .6;
}

.le-loading {
    text-align: center;
    color: var(--le-muted);
    padding: 2.5rem 1rem;
}

@keyframes le-pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: .25;
    }
}

/* ---------- Homepage widget ---------- */
.le-widget {
    margin-bottom: 1.25rem;
}

.le-widget .le-widget-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .6rem;
}

.le-widget .le-widget-title {
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: .45rem;
}

.le-widget .le-widget-all {
    font-size: .8rem;
}

.le-widget-list {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.le-widget-item {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: .55rem .65rem;
    border-radius: 6px;
    text-decoration: none;
    background: var(--le-card);
    border: 1px solid var(--le-border);
    color: var(--le-text);
    transition: background .15s ease;
}

.le-widget-item:hover {
    background: var(--le-card-hover);
    color: var(--le-text);
}

.le-widget-item .le-card-icon {
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    font-size: .9rem;
}

.le-widget-item .le-wi-body {
    flex: 1 1 auto;
    min-width: 0;
}

.le-widget-item .le-wi-title {
    font-weight: 600;
    color: var(--le-head);
    font-size: .9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.le-widget-item .le-wi-meta {
    font-size: .75rem;
    color: var(--le-muted);
}

/* ---------- Hape Events Widget Template ---------- */
.le-hape-section {
    width: 100%;
    margin-bottom: 1.5rem;
    font-family: inherit;
}

.le-hape-header {
    margin-bottom: 0.85rem;
}

.le-hape-subtitle {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #64748b;
    margin-bottom: 0.2rem;
}

.le-hape-title {
    font-size: 1.55rem;
    font-weight: 800;
    color: #ffffff;
    margin: 0;
    line-height: 1.2;
}

/* Horizontal scrollable track */
.le-hape-track {
    display: flex;
    flex-direction: row;
    gap: 0.85rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    cursor: grab;
    scrollbar-width: thin;
    scrollbar-color: #1e3352 rgba(4, 7, 13, 0.4);
}

.le-hape-track.is-dragging,
.le-widget-list.is-dragging {
    scroll-behavior: auto !important;
    cursor: grabbing !important;
    user-select: none !important;
}

.le-hape-track.is-dragging *,
.le-widget-list.is-dragging * {
    user-select: none !important;
    pointer-events: none !important;
}

.le-hape-track::-webkit-scrollbar,
.le-widget-list::-webkit-scrollbar {
    height: 5px;
}

.le-hape-track::-webkit-scrollbar-track,
.le-widget-list::-webkit-scrollbar-track {
    background: rgba(4, 7, 13, 0.4);
    border-radius: 6px;
}

.le-hape-track::-webkit-scrollbar-thumb,
.le-widget-list::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #162438 0%, #1e3352 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    transition: all 0.2s ease;
}

.le-hape-track::-webkit-scrollbar-thumb:hover,
.le-widget-list::-webkit-scrollbar-thumb:hover,
.le-hape-track.is-dragging::-webkit-scrollbar-thumb,
.le-widget-list.is-dragging::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #1d6bf3 0%, #2563eb 100%);
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 0 8px rgba(29, 107, 243, 0.4);
}

/* Single Card */
.le-hape-card {
    flex: 0 0 275px;
    min-width: 275px;
    height: 122px;
    background: linear-gradient(135deg, #090f18 0%, #0c1421 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
    text-decoration: none !important;
    color: inherit !important;
    display: block;
    cursor: pointer;
}

.le-hape-card:hover {
    border-color: rgba(59, 130, 246, 0.45);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.le-hape-card:hover .le-hape-btn {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(29, 107, 243, 0.5);
}

/* Background image overlay */
.le-hape-bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 60%;
    background-size: cover;
    background-position: center right;
    opacity: 0.45;
    mask-image: linear-gradient(to left, rgba(0, 0, 0, 1) 25%, transparent 100%);
    -webkit-mask-image: linear-gradient(to left, rgba(0, 0, 0, 1) 25%, transparent 100%);
    pointer-events: none;
    z-index: 1;
}

/* Card inner content layout */
.le-hape-card-content {
    position: relative;
    z-index: 2;
    height: 100%;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
}

.le-hape-card-head {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.le-hape-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 8px;
    background: rgba(37, 99, 235, 0.25);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.le-hape-meta {
    flex: 1;
    min-width: 0;
}

.le-hape-card-title {
    font-weight: 700;
    font-size: 0.92rem;
    color: #ffffff;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.le-hape-sub {
    font-size: 0.76rem;
    color: #94a3b8;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.le-hape-card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.le-hape-foot-left {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

.le-hape-foot-right {
    flex-shrink: 0;
}

/* Pills */
.le-hape-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 16px;
    white-space: nowrap;
}

.le-pill-green {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.le-pill-purple {
    background: rgba(139, 92, 246, 0.2);
    color: #c084fc;
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 6px;
    text-transform: uppercase;
    font-size: 0.68rem;
    padding: 3px 8px;
}

.le-pill-blue {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    text-transform: uppercase;
    font-size: 0.68rem;
    padding: 3px 8px;
}

.le-pill-dark {
    color: #cbd5e1;
    border-radius: 6px;
    font-size: 0.7rem;
    padding: 3px 8px;
}

/* VIEW Button */
.le-hape-btn {
    background: #1d6bf3;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    padding: 5px 16px;
    border-radius: 18px;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(29, 107, 243, 0.35);
}

.le-hape-btn:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(29, 107, 243, 0.5);
}

/* "View All Events" End Card */
.le-hape-card-more {
    flex: 0 0 165px;
    min-width: 165px;
    height: 122px;
    background: rgba(15, 23, 42, 0.4);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.le-hape-card-more:hover {
    background: rgba(30, 41, 59, 0.6);
    border-color: #2563eb;
    border-style: solid;
    transform:
}

.le-hape-more-icon {
    font-size: 1.35rem;
    color: #2563eb;
    transition: transform 0.2s ease;
}

.le-hape-card-more:hover .le-hape-more-icon {
    transform: translateX(4px);
}

.le-hape-more-text {
    font-weight: 700;
    font-size: 0.85rem;
    color: #ffffff;
}