/* xeevents1 (30-11-2026): the tribes' own events, /events and the block on each tribe's page. Everything starts with
   .xev- ; --tc is the colour of the event's tribe. An element hidden with the `hidden` attribute stays hidden. */
.xev [hidden], .xev-modal[hidden], .xev-block [hidden] { display: none !important; }

.xev { max-width: 1040px; margin: 0 auto; padding: 0 20px 60px; color: #fff; }
.xev-hero { text-align: center; padding: 26px 10px 8px; }
.xev-hero h1 { margin: 0; font-size: clamp(2rem, 6vw, 3.2rem); font-weight: 900; letter-spacing: 0.04em; line-height: 1.05; }
.xev-hero h1 span { color: #f97316; }
.xev-hero p { margin: 12px auto 0; max-width: 620px; color: rgba(255, 255, 255, 0.78); font-size: 1.02rem; line-height: 1.55; }
.xev-hero p b { color: #fff; }
.xev-hero .xev-btn--add { margin-top: 18px; }

.xev-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 8px 16px; border-radius: 999px;
    font: inherit; font-size: 0.9rem; font-weight: 700; line-height: 1.2; color: rgba(255, 255, 255, 0.9); text-decoration: none; cursor: pointer;
    background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.16); transition: background 0.18s, border-color 0.18s, color 0.18s, transform 0.18s;
    -webkit-tap-highlight-color: transparent; }
.xev-btn:hover { background: rgba(255, 255, 255, 0.13); border-color: rgba(255, 255, 255, 0.3); color: #fff; }
.xev-btn:focus-visible, .xev-chip:focus-visible, .xev-x:focus-visible { outline: 2px solid #fb923c; outline-offset: 2px; }
.xev-btn--go { color: #10131f; background: linear-gradient(135deg, var(--tc, #f97316), color-mix(in srgb, var(--tc, #f97316) 60%, #fff)); border-color: transparent; }
.xev-btn--go:hover { color: #10131f; background: linear-gradient(135deg, color-mix(in srgb, var(--tc, #f97316) 85%, #fff), color-mix(in srgb, var(--tc, #f97316) 50%, #fff)); transform: translateY(-1px); }
.xev-btn--add { color: #1a0f05; background: linear-gradient(135deg, #f97316, #ffb155); border-color: transparent; box-shadow: 0 8px 22px rgba(249, 115, 22, 0.3); }
.xev-btn--add:hover { color: #1a0f05; background: linear-gradient(135deg, #fb8a3c, #ffc27a); transform: translateY(-1px); }
.xev-btn--team { border-style: dashed; color: rgba(255, 255, 255, 0.75); }
.xev-btn--down:hover, .xev-form .xev-btn--down { color: #fecaca; background: rgba(239, 68, 68, 0.16); border-color: rgba(239, 68, 68, 0.5); }
.xev-btn[disabled] { opacity: 0.55; cursor: default; transform: none; }

.xev-filter { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 22px 0 6px; }
.xev-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; padding: 6px 15px; border-radius: 999px; font: inherit; font-size: 0.9rem; font-weight: 700;
    color: rgba(255, 255, 255, 0.78); background: rgba(10, 14, 32, 0.55); border: 1px solid rgba(255, 255, 255, 0.14); cursor: pointer;
    transition: background 0.18s, border-color 0.18s, color 0.18s; -webkit-tap-highlight-color: transparent; }
.xev-chip:hover { color: #fff; border-color: rgba(255, 255, 255, 0.32); }
.xev-chip.is-on { color: #fff; background: color-mix(in srgb, var(--tc, #f97316) 24%, rgba(10, 14, 32, 0.7)); border-color: var(--tc, #f97316);
    box-shadow: 0 0 18px color-mix(in srgb, var(--tc, #f97316) 35%, transparent); }
.xev-tdot { display: inline-block; flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--tc, #f97316); box-shadow: 0 0 8px var(--tc, #f97316); }
.xev-dot { display: inline-block; flex: none; width: 9px; height: 9px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 10px #22c55e; animation: xev-pulse 1.8s infinite; }
.xev-ico { display: inline-block; font-style: normal; font-weight: 400; line-height: 1; margin-right: 5px; }

.xev-h2 { display: flex; align-items: center; gap: 10px; margin: 30px 4px 14px; font-size: 1.15rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(255, 255, 255, 0.85); }
.xev-list { display: grid; gap: 14px; }
.xev-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; padding: 20px; border-radius: 18px; position: relative; overflow: hidden; scroll-margin-top: 20px;
    background: linear-gradient(135deg, rgba(16, 22, 48, 0.9), rgba(8, 10, 26, 0.92)); border: 1px solid rgba(255, 255, 255, 0.09);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); transition: border-color 0.2s, box-shadow 0.2s; }
.xev-card::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--tc); box-shadow: 0 0 18px var(--tc); }
.xev-card:hover { border-color: color-mix(in srgb, var(--tc) 45%, transparent); }
.xev-card:target { border-color: var(--tc); box-shadow: 0 0 0 1px var(--tc), 0 0 34px color-mix(in srgb, var(--tc) 40%, transparent); }
.xev-card.is-live { border-color: rgba(34, 197, 94, 0.55); box-shadow: 0 0 30px rgba(34, 197, 94, 0.16); }
.xev-card.is-past { opacity: 0.72; }
.xev-date { display: grid; place-content: center; flex: none; width: 66px; height: 70px; border-radius: 14px; text-align: center; line-height: 1;
    background: color-mix(in srgb, var(--tc) 16%, rgba(10, 14, 32, 0.9)); border: 1px solid color-mix(in srgb, var(--tc) 45%, transparent); }
.xev-date b { font-size: 1.7rem; font-weight: 900; color: #fff; }
.xev-date span { margin-top: 5px; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.14em; color: var(--tc); }
.xev-body { min-width: 0; }
.xev-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.xev-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 0.74rem; font-weight: 700; white-space: nowrap;
    color: rgba(255, 255, 255, 0.82); background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.1); }
.xev-pill .xev-ico { margin-right: 0; }
.xev-pill--tribe { color: #fff; background: color-mix(in srgb, var(--tc) 18%, transparent); border-color: color-mix(in srgb, var(--tc) 45%, transparent); }
.xev-pill--live { color: #bbf7d0; background: rgba(34, 197, 94, 0.14); border-color: rgba(34, 197, 94, 0.5); }
.xev-title { margin: 10px 0 6px; font-size: 1.3rem; font-weight: 800; line-height: 1.25; color: #fff; overflow-wrap: anywhere; }
.xev-when { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; font-size: 0.98rem; font-weight: 600; color: rgba(255, 255, 255, 0.9); }
.xev-in { font-size: 0.82rem; font-weight: 700; color: var(--tc); }
.xev-where { margin: 6px 0 0; font-size: 0.92rem; color: rgba(255, 255, 255, 0.75); overflow-wrap: anywhere; }
.xev-desc { margin: 10px 0 0; font-size: 0.94rem; line-height: 1.55; color: rgba(255, 255, 255, 0.72); white-space: pre-line; overflow-wrap: anywhere; }
.xev-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.xev-host { margin: 10px 0 0; font-size: 0.78rem; color: rgba(255, 255, 255, 0.45); }

.xev-empty { display: grid; justify-items: center; gap: 8px; padding: 44px 20px; border-radius: 18px; text-align: center; color: rgba(255, 255, 255, 0.7);
    background: rgba(10, 14, 32, 0.5); border: 1px dashed rgba(255, 255, 255, 0.16); }
.xev-empty-ico { font-size: 2.2rem; line-height: 1; }
.xev-empty b { font-size: 1.1rem; color: #fff; }
.xev-empty span { max-width: 460px; font-size: 0.92rem; line-height: 1.5; }
.xev-empty a, .xev-more a { color: #fb923c; }

.xev-past { margin-top: 30px; border-radius: 16px; background: rgba(10, 14, 32, 0.4); border: 1px solid rgba(255, 255, 255, 0.08); }
.xev-past summary { padding: 14px 18px; font-weight: 800; cursor: pointer; color: rgba(255, 255, 255, 0.85); list-style-position: inside; }
.xev-past summary small { font-weight: 600; color: rgba(255, 255, 255, 0.5); }
.xev-past .xev-list { padding: 0 14px 14px; }
.xev-trashlist { margin: 0; padding: 0 18px 14px; list-style: none; display: grid; gap: 8px; }
.xev-trashlist li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; font-size: 0.88rem; color: rgba(255, 255, 255, 0.72); }

/* the form */
.xev-modal { position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; padding: 16px; }
.xev-modal-back { position: absolute; inset: 0; background: rgba(3, 6, 18, 0.72); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.xev-form { position: relative; width: min(560px, 100%); max-height: calc(100dvh - 32px); overflow-y: auto; display: grid; gap: 14px; padding: 22px; border-radius: 20px; color: #fff;
    background: linear-gradient(180deg, #121a3a, #080b1c); border: 1px solid rgba(0, 221, 235, 0.25); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); animation: xev-rise 0.22s ease; }
.xev-form--small { width: min(420px, 100%); }
.xev-form-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.xev-form-head h2 { margin: 0; font-size: 1.25rem; font-weight: 800; }
.xev-x { width: 38px; height: 38px; border-radius: 50%; font-size: 1rem; line-height: 1; color: rgba(255, 255, 255, 0.85); cursor: pointer;
    background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.12); }
.xev-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.xev-field { display: grid; gap: 6px; min-width: 0; }
.xev-field > span { font-size: 0.78rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255, 255, 255, 0.7); }
.xev-field > span small { font-weight: 600; letter-spacing: 0; text-transform: none; color: rgba(255, 255, 255, 0.45); }
.xev-field > span i { font-style: normal; }
.xev-field input, .xev-field select, .xev-field textarea { width: 100%; box-sizing: border-box; min-height: 44px; padding: 10px 12px; border-radius: 12px; font: inherit; font-size: 1rem;
    color: #fff; background: rgba(4, 6, 18, 0.7); border: 1px solid rgba(255, 255, 255, 0.16); color-scheme: dark; }
.xev-field textarea { resize: vertical; line-height: 1.5; }
.xev-field input:focus, .xev-field select:focus, .xev-field textarea:focus { outline: none; border-color: #fb923c; box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.2); }
.xev-error { margin: 0; padding: 10px 12px; border-radius: 12px; font-size: 0.9rem; font-weight: 600; color: #fecaca; background: rgba(239, 68, 68, 0.14); border: 1px solid rgba(239, 68, 68, 0.4); }
.xev-form-foot { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.xev-confirm-text { margin: 0; font-size: 0.96rem; line-height: 1.55; color: rgba(255, 255, 255, 0.8); }
.xev-confirm-text b { color: #fff; }
body.xev-locked { overflow: hidden; }
/* xeevents2: the preview step of the form */
.xev-step { display: grid; gap: 14px; min-width: 0; }
.xev-step[hidden], .xev-form-foot[hidden] { display: none; }
.xev-preview-note { margin: 0; display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 12px; font-size: 0.92rem; line-height: 1.5; color: rgba(255, 255, 255, 0.82);
    background: rgba(0, 221, 235, 0.08); border: 1px solid rgba(0, 221, 235, 0.3); }
.xev-preview-note b { color: #fff; }
.xev-preview-note .xev-ico { font-size: 1.15rem; line-height: 1.3; }
.xev-preview-card .xev-card { margin: 0; }
.xev-preview-shows { margin: 0; display: grid; gap: 4px; font-size: 0.88rem; line-height: 1.5; color: rgba(255, 255, 255, 0.7); }
.xev-preview-shows b { font-size: 0.78rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255, 255, 255, 0.7); }
.xev-btn.is-off { opacity: 0.5; cursor: default; }
.xev-form:has([data-xev-step="preview"]:not([hidden])) { width: min(720px, 100%); }

/* the block on a tribe's own page */
.xev-block-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.xev-block-head .section-title { margin-bottom: 0; }
.xev-mini-list { display: grid; gap: 10px; }
.xev-mini { display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: 16px; text-decoration: none; color: #fff;
    background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 255, 255, 0.08); transition: background 0.18s, border-color 0.18s; }
.xev-mini:hover { background: rgba(255, 255, 255, 0.08); border-color: color-mix(in srgb, var(--tc) 50%, transparent); }
.xev-mini.is-live { border-color: rgba(34, 197, 94, 0.5); }
.xev-mini .xev-date { width: 56px; height: 60px; }
.xev-mini .xev-date b { font-size: 1.4rem; }
.xev-mini-body { display: grid; gap: 5px; min-width: 0; }
.xev-mini-body > b { font-size: 1.05rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xev-mini-when { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 0.86rem; color: rgba(255, 255, 255, 0.72); }
.xev-more { margin: 14px 0 0; font-size: 0.88rem; color: rgba(255, 255, 255, 0.55); }

@media (max-width: 640px) {
    .xev { padding: 0 12px 44px; }
    .xev-card { grid-template-columns: 1fr; gap: 12px; padding: 16px 16px 16px 18px; }
    .xev-card .xev-date { width: auto; height: auto; padding: 8px 12px; display: inline-flex; align-items: baseline; gap: 8px; justify-self: start; }
    .xev-card .xev-date b { font-size: 1.25rem; }
    .xev-card .xev-date span { margin-top: 0; }
    .xev-title { font-size: 1.15rem; }
    .xev-actions .xev-btn { flex: 1 1 auto; }
    .xev-filter { justify-content: flex-start; flex-wrap: nowrap; overflow-x: auto; margin-left: -12px; margin-right: -12px; padding: 4px 12px 8px; scrollbar-width: none; }
    .xev-filter::-webkit-scrollbar { display: none; }
    .xev-chip { flex: none; }
    .xev-row { grid-template-columns: 1fr; }
    .xev-form { padding: 18px; }
    .xev-form-foot .xev-btn { flex: 1 1 auto; }
}
@keyframes xev-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
@keyframes xev-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .xev-dot, .xev-form { animation: none; } .xev-btn, .xev-chip, .xev-card, .xev-mini { transition: none; } }
