:root {
  --bg: #050508;
  --bg-card: rgba(26, 26, 38, 0.6);
  --border: rgba(255, 255, 255, 0.08);
  --text: #ffffff;
  --muted: #94a3b8;
  --accent: #ff0055;
  --accent2: #ff5500;
  
  --col-wc: #ef4444;      /* Red */
  --col-cl: #3b82f6;      /* Blue */
  --col-el: #f97316;      /* Orange */
  --col-ecl: #10b981;     /* Green */
  --col-summer: #eab308;  /* Gold */
  --col-winter: #06b6d4;  /* Cyan */
  --col-euro: #14b8a6;    /* Teal */
  --col-cwc: #a855f7;     /* Purple */
  --col-tv: #ec4899;      /* Pink */
  --col-nl: #6366f1;      /* Indigo */
  --col-sc: #f59e0b;      /* Amber */
  --col-fic: #8b5cf6;     /* Violet */
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background-color: var(--bg);
  background-image: 
    radial-gradient(circle at 20% 20%, rgba(99, 102, 241, 0.15) 0%, transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(168, 85, 247, 0.1) 0%, transparent 45%),
    radial-gradient(circle at center, #0d0d1a 0%, #050508 100%);
  background-attachment: fixed;
  background-size: cover;
  background-repeat: no-repeat;
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

html {
  background-color: #050508;
  height: 100%;
  scroll-behavior: smooth;
}

/* ── LAYOUT CONTAINERS ── */
header, main, footer {
  max-width: 1600px;
  margin: 0 auto;
  width: 100%;
  padding-left: 30px;
  padding-right: 30px;
}

/* ── TOPBAR (Sticky Tier 1) ── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: 64px;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 25px;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}
.topbar::-webkit-scrollbar { display: none; }

.topbar-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.3rem;
  letter-spacing: 0.12em;
  color: var(--text);
  white-space: nowrap;
  flex-shrink: 0;
}

.topbar-sep {
  width: 1px;
  height: 24px;
  background: var(--border);
  flex-shrink: 0;
  margin: 0 6px;
}

.nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 100px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
}
.nav-pill:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}
.nav-pill.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--nav-color, var(--accent));
  box-shadow: 0 0 14px rgba(255, 0, 85, 0.25);
}
.nav-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--nav-color, var(--accent));
  box-shadow: 0 0 6px var(--nav-color, var(--accent));
}

/* ── SUB-TOPBAR (Sticky Tier 2) ── */
.sub-topbar {
  position: sticky;
  top: 64px;
  z-index: 999;
  min-height: 48px;
  background: rgba(13, 13, 22, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  padding: 6px 25px;
  transition: all 0.3s ease;
}
.sub-topbar-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
}
.sub-topbar-inner::-webkit-scrollbar { display: none; }

.sub-pills-group {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.sub-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  font-family: inherit;
}
.sub-pill:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
}
.sub-pill.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--sub-color, var(--accent));
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.15);
}

/* ── HEADER SECTION ── */
header {
  padding-top: 50px;
  padding-bottom: 40px;
  position: relative;
}

.header-glow {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.1) 0%, transparent 50%);
  z-index: -1;
  pointer-events: none;
}

.header-title-wrapper {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 10px;
}

.header-logo {
  height: 120px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.header-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(48px, 7vw, 100px);
  line-height: 1;
  margin-bottom: 0;
}
.header-title span {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── MAIN CATEGORY GROUPS ── */
.main-category-group {
  margin-bottom: 70px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.main-category-group.hidden-group {
  display: none !important;
}

.main-group-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 30px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.main-group-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 10px 24px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.7rem;
  letter-spacing: 0.06em;
  color: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.main-group-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.15), transparent);
}

/* ── SUB-GROUPS ── */
.sub-group {
  margin-bottom: 50px;
  padding-left: 10px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.sub-group.hidden-subgroup {
  display: none !important;
}

.sub-group-header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 25px;
}
.sub-group-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 18px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--sub-color, rgba(255, 255, 255, 0.15));
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.03em;
}
.sub-group-desc {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 400;
}

/* ── CATEGORY & LOGOS ── */
.category {
  margin-bottom: 40px;
}

.category-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
  min-height: 64px;
}

.category-icon-img {
  height: 52px;
  width: 72px;
  object-fit: contain;
  object-position: center;
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.3)) drop-shadow(0 0 1px rgba(255, 255, 255, 0.6));
  transition: filter 0.3s ease, transform 0.3s ease;
}

.category-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.5rem;
  letter-spacing: 0.05em;
  color: var(--text);
  white-space: nowrap;
}

.category-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border), transparent);
}

/* ── GRID SYSTEM ── */
.cards-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(460px, 1fr));
  gap: 25px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 26px 30px;
  text-decoration: none;
  color: inherit;
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 255, 255, 0.2);
  background: #1a1a26;
  box-shadow: 0 16px 35px rgba(0, 0, 0, 0.4);
}

.card-year {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--card-color);
  letter-spacing: 0.1em;
  display: flex;
  align-items: center;
  gap: 6px;
}
.card-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}
.card-name {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.8rem;
  line-height: 1;
}
.card-location {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: auto;
}

.card-status {
  display: inline-block;
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.status-live {
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.3);
}
.card-dot.live-dot {
  color: #22c55e;
  animation: livePulse 1.6s ease-in-out infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

/* ── STADIUM BACKGROUND CARDS ── */
.card.has-bg {
  background-color: #0d0d16;
  min-height: 170px;
}
.card.has-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(10, 10, 18, 0.96) 0%, rgba(10, 10, 18, 0.82) 38%, rgba(10, 10, 18, 0.25) 75%, rgba(10, 10, 18, 0.1) 100%),
    var(--card-bg);
  background-size: cover;
  background-position: center;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 0;
}
.card.has-bg:hover::before { transform: scale(1.05); }
.card.has-bg > *:not(.card-edit-btn):not(.card-logo-badge) { position: relative; z-index: 1; }
.card.has-bg .card-location { color: rgba(255, 255, 255, 0.75); }

/* ── ARTWORK CARDS (competition colours) ── */
.card.has-art { background: #0b0b14; min-height: 170px; }
.card .card-art { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; transition: transform .6s cubic-bezier(.16,1,.3,1); }
.card.has-art:hover .card-art { transform: scale(1.05); }
.card .card-art-shade { position: absolute; inset: 0; z-index: 0; background: linear-gradient(90deg, rgba(8,8,16,.92) 0%, rgba(8,8,16,.7) 40%, rgba(8,8,16,.15) 80%); }
.card.has-art > *:not(.card-art):not(.card-art-shade):not(.card-edit-btn):not(.card-logo-badge) { position: relative; z-index: 1; }
.card.has-art .card-location { color: rgba(255,255,255,.78); }

/* ── WINNER FLAG CARDS (finished competitions) ── */
.card.has-winner::before { background-position: center; filter: saturate(1.05); }
.card.has-winner::after { content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: linear-gradient(90deg, rgba(8,8,16,.82) 0%, rgba(8,8,16,.55) 45%, rgba(8,8,16,0) 85%); }
.card.has-winner > *:not(.card-edit-btn):not(.card-logo-badge) { position: relative; z-index: 1; }
.card-winner { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 10px; border-radius: 100px;
  background: linear-gradient(90deg, #f5c542, #ffe28a); color: #1d1300; box-shadow: 0 6px 18px rgba(245,197,66,.3); }
.card-winner small { font-size: .62rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.card-winner .cw-flag { width: 20px; height: 14px; object-fit: cover; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0,0,0,.25); }
.card-winner b { font-family: 'Bebas Neue', sans-serif; font-weight: 400; font-size: 1.15rem; letter-spacing: .03em; line-height: 1; }

/* Competition logos sit on a light chip so dark logos stay visible */
.category-icon-img {
  background: #fff;
  padding: 6px 8px;
  border-radius: 12px;
  width: auto !important;
  max-width: 120px;
  height: 64px;
  filter: none !important;
  box-sizing: border-box;
}

/* ── STATUS ROWS (Ongoing / Upcoming / Finished) ── */
.cards-row.status-rows {
  display: flex;
  flex-direction: column;
  gap: 25px;
}
.status-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(460px, 1fr));
  gap: 25px;
}

/* ── QUICK ACCESS ── */
.quick-access {
  margin-bottom: 60px;
  padding: 26px 30px 30px;
  border-radius: 24px;
  border: 1px solid rgba(34, 197, 94, 0.25);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.06), rgba(255, 255, 255, 0.01));
}
.quick-access.empty { display: none; }
.quick-access-header { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.quick-access-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.6rem;
  letter-spacing: 0.05em;
  color: var(--text);
  white-space: nowrap;
}
.quick-access-count {
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 100px; white-space: nowrap;
  color: #22c55e; background: rgba(34, 197, 94, 0.15); border: 1px solid rgba(34, 197, 94, 0.3);
}
.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}
.qa-card {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border-radius: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--card-color);
  text-decoration: none; color: inherit;
  transition: all 0.25s ease;
}
.qa-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.2);
  border-left-color: var(--card-color);
  background: #1a1a26;
}
.qa-logo { width: 48px; height: 48px; object-fit: contain; flex-shrink: 0; background: #fff; border-radius: 10px; padding: 5px; box-sizing: border-box; }
.qa-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.qa-comp { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--card-color); }
.qa-name { font-family: 'Bebas Neue', sans-serif; font-size: 1.35rem; line-height: 1.05; }
.qa-live {
  margin-left: auto; display: flex; align-items: center; gap: 6px; flex-shrink: 0;
  font-size: 0.65rem; font-weight: 700; letter-spacing: 0.08em; color: #22c55e; text-transform: uppercase;
}
@media (max-width: 600px) {
  .status-row { grid-template-columns: 1fr; }
  .quick-access { padding: 20px 16px; }
}
.status-coming {
  background: rgba(234, 179, 8, 0.2);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.3);
}
.status-done {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

/* ── FOOTER ── */
footer {
  margin-top: auto;
  padding-top: 50px;
  padding-bottom: 40px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 0.85rem;
}

#scrollTopBtn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1000;
  background: rgba(26, 26, 38, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: white;
  transition: all 0.3s;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}
#scrollTopBtn:hover {
  background: var(--accent);
  transform: translateY(-3px);
}

/* ── EDIT MODAL ── */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(5, 5, 8, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal-content {
  background: #12121c;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  width: 90%;
  max-width: 500px;
  padding: 30px;
  box-shadow: 0 25px 50px rgba(0,0,0,0.6);
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.modal-header h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.6rem;
  letter-spacing: 0.05em;
}
#modalCloseBtn {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 1.8rem;
  cursor: pointer;
  line-height: 1;
}
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.form-group input[type="text"], .form-group select {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: white;
  padding: 10px 14px;
  font-size: 0.85rem;
  outline: none;
  transition: border-color 0.3s;
}
.form-group input[type="text"]:focus, .form-group select:focus {
  border-color: var(--accent);
}
.checkbox-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  text-transform: none;
  font-size: 0.85rem;
  color: white;
}
.modal-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 24px;
  gap: 12px;
}
.modal-footer button {
  padding: 12px 20px;
  border-radius: 12px;
  font-weight: bold;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s;
}
.btn-primary {
  background: var(--accent);
  color: white;
  border: none;
  flex: 1;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 0, 85, 0.4);
}
.btn-danger {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}
.btn-danger:hover { background: rgba(239, 68, 68, 0.3); }

/* Edit Mode helper classes */
body.is-editing .card {
  pointer-events: auto !important;
  opacity: 1 !important;
  border: 1px dashed rgba(255, 255, 255, 0.3);
}
.card-edit-btn {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 10;
  background: rgba(26, 26, 38, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s;
}
.card-edit-btn:hover {
  background: var(--accent);
  transform: scale(1.1);
}
.add-card-btn {
  background: rgba(255, 255, 255, 0.02);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  padding: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.3s;
  height: 100%;
  min-height: 150px;
}
.add-card-btn:hover {
  border-color: var(--accent);
  color: white;
  background: rgba(255, 255, 255, 0.05);
}

@media (max-width: 900px) {
  .cards-row { grid-template-columns: 1fr; }
  .header-title-wrapper { flex-direction: column; align-items: flex-start; }
  .header-logo { height: 90px; }
  header, main, footer { padding-left: 20px; padding-right: 20px; }
}
  
/* ── CARD LOGO BADGE (User request: right side of card) ── */
.card.has-logo {
  padding-right: 135px; /* Make room for right-side logo */
}
.card-logo-badge {
  position: absolute;
  right: 25px;
  top: 50%;
  transform: translateY(-50%);
  width: 95px;
  height: 95px;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 2;
}
.card-logo-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.25));
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.card:hover .card-logo-img {
  transform: scale(1.1);
  filter: drop-shadow(0 0 16px rgba(255, 255, 255, 0.5));
}
.logo-invert {
  filter: brightness(0) invert(1) drop-shadow(0 0 10px rgba(255, 255, 255, 0.35)) !important;
}
.card:hover .logo-invert {
  transform: scale(1.1);
  filter: brightness(0) invert(1) drop-shadow(0 0 18px rgba(255, 255, 255, 0.6)) !important;
}
.trophy-screen {
  mix-blend-mode: screen;
  filter: drop-shadow(0 0 12px rgba(255, 255, 255, 0.35));
  max-height: 115px !important;
}



/* ── CARDS WITHOUT A PAGE YET ── */
.card.no-link { cursor: not-allowed; }
.card.no-link:hover { transform: none; box-shadow: none; }
.coming-soon-tag {
  position: absolute !important;
  right: 18px;
  bottom: 16px;
  z-index: 3 !important;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(10, 10, 18, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 4px 10px;
  border-radius: 100px;
  opacity: 0;
  transform: translateY(4px);
  transition: all 0.2s ease;
  pointer-events: none;
}
.card.no-link:hover .coming-soon-tag { opacity: 1; transform: none; }
body.is-editing .card.no-link { cursor: pointer; }

/* ── CARDS WITHOUT PHOTO OR LOGO: gradient in the competition colour ── */
.card.gradient-fill {
  background:
    radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--card-color) 45%, transparent) 0%, transparent 55%),
    linear-gradient(135deg, var(--bg-card) 35%, color-mix(in srgb, var(--card-color) 30%, var(--bg-card)) 100%);
  min-height: 170px;
}

/* ── EDIT MODE BUTTON & SAVE STATUS ── */
.edit-mode-btn {
  position: fixed;
  top: 128px;
  right: 20px;
  z-index: 9999;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(26, 26, 38, 0.85);
  color: white;
  font-size: 0.85rem;
  font-weight: bold;
  cursor: pointer;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  font-family: inherit;
}
.edit-mode-btn:hover, .edit-mode-btn.on { background: var(--accent); }
.sync-status {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  padding: 10px 18px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #22c55e;
  background: rgba(13, 13, 22, 0.95);
  border: 1px solid rgba(34, 197, 94, 0.35);
}
.sync-status.error { color: #f87171; border-color: rgba(248, 113, 113, 0.4); }
.form-hint { font-size: 0.75rem; color: var(--muted); margin-top: 4px; }

/* ── SHORT LABELS IN THE TOP BAR (phones) ── */
.lbl-short { display: none; }

/* ── TABLET ── */
@media (max-width: 1100px) {
  .status-row { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
}

/* ── TABLET & PHONE: compact top bar ── */
@media (max-width: 1000px) {
  .topbar { padding: 0 12px; gap: 6px; height: 56px; }
  .sub-topbar { top: 56px; padding: 6px 12px; }
  .topbar-logo, .topbar-sep { display: none; }
  .nav-pill { padding: 7px 12px; font-size: 0.8rem; gap: 6px; }
  .nav-pill .nav-dot { display: none; }
  .lbl-long { display: none; }
  .lbl-short { display: inline; }
}

/* ── PHONE ── */
@media (max-width: 700px) {
  header { padding-top: 28px; padding-bottom: 24px; }
  .header-logo { height: 70px !important; }
  .status-row { grid-template-columns: 1fr; gap: 16px; }
  .cards-row.status-rows { gap: 16px; }
  .card { padding: 22px 20px; }
  .card.has-logo { padding-right: 100px; }
  .card-logo-badge { width: 70px; height: 70px; right: 16px; }
  .card-name { font-size: 1.55rem; }
  .category-title { font-size: 1.25rem; white-space: normal; }
  .category-icon-img { height: 52px; max-width: 90px; }
  .quick-access { padding: 18px 14px; margin-bottom: 40px; }
  .quick-access-grid { grid-template-columns: 1fr; gap: 12px; }
  .sub-group-header { flex-wrap: wrap; gap: 8px; }
  .edit-mode-btn { top: auto; bottom: 20px; right: auto; left: 16px; padding: 9px 14px; }
  #scrollTopBtn { bottom: 20px; right: 16px; }
  .coming-soon-tag { opacity: 1; transform: none; right: 12px; bottom: 12px; }
}


/* ── Competition logos on the top-bar pills ── */
.nav-logo {
  display: inline-flex; align-items: center; justify-content: center;
  height: 22px; padding: 2px 6px; border-radius: 7px; background: #fff; flex-shrink: 0;
}
.nav-logo img { height: 16px; width: auto; max-width: 46px; object-fit: contain; display: block; }
.nav-logo-flag { padding: 3px; background: rgba(255, 255, 255, 0.9); }
.nav-flag { width: 24px; height: 16px; display: block; border-radius: 2px; }
@media (max-width: 1000px) {
  .nav-logo { height: 20px; padding: 2px 5px; }
  .nav-logo img { height: 14px; max-width: 38px; }
}

/* ── A different backdrop for each category page ── */
body[data-page="uefa"] {
  background-image:
    radial-gradient(ellipse at 15% 0%, rgba(59, 130, 246, 0.22) 0%, transparent 50%),
    radial-gradient(ellipse at 90% 30%, rgba(30, 64, 175, 0.20) 0%, transparent 45%),
    radial-gradient(circle at 50% 110%, rgba(148, 163, 184, 0.10) 0%, transparent 50%),
    linear-gradient(180deg, #060b1f 0%, #04060f 100%);
}
body[data-page="fifa"] {
  background-image:
    radial-gradient(ellipse at 10% 0%, rgba(239, 68, 68, 0.20) 0%, transparent 50%),
    radial-gradient(ellipse at 90% 25%, rgba(234, 179, 8, 0.14) 0%, transparent 45%),
    radial-gradient(circle at 50% 110%, rgba(37, 99, 235, 0.12) 0%, transparent 50%),
    linear-gradient(180deg, #120808 0%, #07050a 100%);
}
body[data-page="olympics"] {
  background-image:
    radial-gradient(circle at 8% 5%, rgba(0, 129, 200, 0.20) 0%, transparent 32%),
    radial-gradient(circle at 30% 0%, rgba(252, 177, 49, 0.14) 0%, transparent 30%),
    radial-gradient(circle at 55% 5%, rgba(255, 255, 255, 0.06) 0%, transparent 30%),
    radial-gradient(circle at 78% 0%, rgba(0, 166, 81, 0.16) 0%, transparent 30%),
    radial-gradient(circle at 98% 8%, rgba(238, 51, 78, 0.16) 0%, transparent 32%),
    linear-gradient(180deg, #0a0c14 0%, #050608 100%);
}
body[data-page="statistics"] {
  background-image:
    radial-gradient(ellipse at 0% 20%, rgba(0, 43, 127, 0.35) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 0%, rgba(252, 209, 22, 0.12) 0%, transparent 40%),
    radial-gradient(ellipse at 100% 20%, rgba(206, 17, 38, 0.25) 0%, transparent 45%),
    linear-gradient(180deg, #08091a 0%, #050508 100%);
}

/* Custom icon set (replaces emoji icons) */
.ic { width: 1.05em; height: 1.05em; vertical-align: -0.17em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ic-big { width: 2.6rem; height: 2.6rem; }

/* Dark logos sit on a white chip */
.card-logo-badge.chip { background: #fff; border-radius: 20px; padding: 10px; box-shadow: 0 10px 26px rgba(0,0,0,.45); box-sizing: border-box; }
.card-logo-badge.chip .card-logo-img, .card:hover .card-logo-badge.chip .card-logo-img { filter: none; }
.category-icon-img.wide { max-width: 230px !important; padding: 10px 14px; }
.pill-logo { height: 14px; width: auto; background: #fff; border-radius: 6px; padding: 3px 6px; vertical-align: middle; box-sizing: content-box; }
