/* Edge Hub — earning opportunities tracker. Loaded only on the owner Edge
 * season room. Prefix: eo-. Dark surface, same gold/ember language as the
 * wallet. Mobile-first: the i disclosure is a native tap target, never hover. */

.eo {
  --eo-ink: var(--wl-ink, #f7f4ea);
  --eo-dim: var(--wl-muted, #a9a396);
  --eo-faint: var(--wl-muted-2, #6f6a60);
  --eo-line: var(--wl-line, rgba(247, 244, 234, 0.13));
  --eo-panel: var(--wl-card, #121216);
  --eo-panel-2: var(--wl-card-2, #17171c);
  --eo-gold: #a87c1f;
  --eo-good: var(--wl-ok, #8fb98a);
  display: grid;
  gap: 14px;
  margin: 0 0 18px;
  color: var(--eo-ink);
}

.eo * { box-sizing: border-box; }
html[data-theme="dark"] .eo,
body.is-dark .eo { --eo-gold: #f2d27c; }

.eo-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.42fr);
  gap: 18px;
  padding: 20px 22px;
  border: 1px solid var(--eo-line);
  border-radius: 16px;
  background:
    radial-gradient(120% 160% at 100% 0%, color-mix(in srgb, var(--eo-gold) 12%, transparent), transparent 58%),
    var(--eo-panel-2);
}

.eo-hero-main small { display: block; color: var(--eo-gold); font: 800 10px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.16em; }
.eo-hero-main > strong { display: flex; align-items: baseline; gap: 8px; min-height: 1.18em; margin: 6px 0 8px; font: 900 clamp(42px, 6vw, 68px)/1.18 var(--pd-font-league, "Rubik", "Arial Narrow", "Roboto Condensed", "Segoe UI", sans-serif); letter-spacing: -0.03em; }
.eo-hero-main > strong em { font: 800 11px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; color: var(--eo-dim); font-style: normal; }
.eo-hero-main p { margin: 0; color: var(--eo-dim); font: 600 13px/1.5 system-ui, sans-serif; }
.eo-hero-main p b { color: var(--eo-ink); }

.eo-hero-side { display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; }
.eo-hero-label { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.eo-hero-label small { color: var(--eo-faint); font: 800 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; }
.eo-hero-label b { font: 800 18px/1 system-ui, sans-serif; }
.eo-hero-meter { display: block; height: 10px; border-radius: 999px; background: rgba(247, 244, 234, 0.08); overflow: hidden; }
.eo-hero-meter i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #b9742a, var(--eo-gold)); }
.eo-hero-spent { color: var(--eo-faint); font: 700 10px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.08em; text-transform: uppercase; }

.eo-lanes { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.eo-chip { display: grid; gap: 7px; padding: 10px 11px; border: 1px solid var(--eo-line); border-radius: 11px; background: var(--eo-panel); }
.eo-chip.is-complete { opacity: 0.62; }
.eo-chip-top { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; }
.eo-chip-top b { font: 800 12px/1.2 system-ui, sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.eo-chip-top em { color: var(--eo-gold); font: 800 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; font-style: normal; letter-spacing: 0.04em; white-space: nowrap; }
.eo-chip-meter { display: block; height: 5px; border-radius: 999px; background: rgba(247, 244, 234, 0.09); overflow: hidden; }
.eo-chip-meter i { display: block; height: 100%; background: var(--eo-gold); }
.eo-chip-fig { color: var(--eo-dim); font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }

.eo-scale { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 4px; color: var(--eo-faint); }
.eo-scale small { font: 700 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.eo-scale b { font: 800 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; text-transform: uppercase; color: var(--eo-dim); }

.eo-group { border: 1px solid var(--eo-line); border-radius: 14px; background: var(--eo-panel); overflow: hidden; }
.eo-group-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 14px 16px 12px; border-bottom: 1px solid var(--eo-line); background: linear-gradient(180deg, rgba(247, 244, 234, 0.03), transparent); }
.eo-group-head h3 { margin: 0; font: 900 15px/1.2 system-ui, sans-serif; letter-spacing: -0.01em; }
.eo-group-head p { margin: 4px 0 0; color: var(--eo-faint); font: 600 11px/1.4 system-ui, sans-serif; }
.eo-group-fig { display: grid; justify-items: end; gap: 3px; white-space: nowrap; }
.eo-group-fig b { font: 800 12px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; }
.eo-group-fig em { color: var(--eo-good); font: 800 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; font-style: normal; letter-spacing: 0.06em; text-transform: uppercase; }

.eo-actions { display: grid; }
.eo-action { display: grid; grid-template-columns: 44px minmax(0, 1fr) 30px; gap: 12px; align-items: start; padding: 13px 16px; border-bottom: 1px solid var(--eo-line); }
.eo-action:last-child { border-bottom: 0; }
.eo-action:hover { background: rgba(247, 244, 234, 0.02); }
.eo-mark { display: grid; place-items: center; width: 40px; height: 30px; border-radius: 7px; border: 1px solid color-mix(in srgb, var(--eo-gold) 42%, var(--eo-line)); background: color-mix(in srgb, var(--eo-gold) 9%, transparent); color: var(--eo-gold); font: 900 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.05em; }
.eo-action-main { min-width: 0; display: grid; gap: 6px; }
.eo-action-top { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.eo-action-top b { font: 800 14px/1.2 system-ui, sans-serif; }
.eo-parent { color: var(--eo-faint); font: 800 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.12em; }
.eo-left { margin-left: auto; color: var(--eo-gold); font: 800 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; font-style: normal; letter-spacing: 0.08em; }
.eo-left.is-complete { color: var(--eo-good); }
.eo-action-copy { margin: 0; color: var(--eo-dim); font: 500 12px/1.45 system-ui, sans-serif; }
.eo-meter { display: block; height: 6px; border-radius: 999px; background: rgba(247, 244, 234, 0.08); overflow: hidden; }
.eo-meter i { display: block; height: 100%; background: var(--eo-gold); }
.eo-action-meta { display: flex; justify-content: space-between; gap: 10px; color: var(--eo-faint); font: 700 10px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; }
.eo-action-meta b { color: var(--eo-ink); }

.eo-i { grid-column: 3; min-width: 0; }
.eo-i[open] { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) 30px; align-items: start; }
.eo-i[open] > summary { grid-column: 2; grid-row: 1; }
.eo-i > summary {
  list-style: none;
  width: 30px; height: 30px;
  margin-left: auto;
  display: grid; place-items: center;
  border: 1px solid var(--eo-line);
  border-radius: 999px;
  color: var(--eo-ink);
  font: 700 15px/1 Georgia, "Times New Roman", serif;
  cursor: pointer;
  user-select: none;
}
.eo-i > summary::-webkit-details-marker { display: none; }
.eo-i > summary:hover { color: var(--eo-ink); border-color: var(--eo-gold); }
.eo-i > summary:focus-visible { outline: 2px solid var(--eo-gold); outline-offset: 2px; }
.eo-i[open] > summary { color: #121216; background: var(--eo-gold); border-color: var(--eo-gold); }
.eo-i-body { grid-column: 1 / -1; grid-row: 2; margin: 4px 0 2px 56px; padding: 12px 14px; border: 1px solid var(--eo-line); border-left: 2px solid var(--eo-gold); border-radius: 9px; background: var(--eo-panel-2); }
.eo-i-body header { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.eo-i-body header small { color: var(--eo-gold); font: 800 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; }
.eo-i-body header b { font: 800 13px/1.2 system-ui, sans-serif; }
.eo-i-body header em { margin-left: auto; color: var(--eo-faint); font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; font-style: normal; }
.eo-i-body ol { margin: 0; padding-left: 18px; display: grid; gap: 6px; color: var(--eo-dim); font: 500 12px/1.45 system-ui, sans-serif; }
.eo-i-body li::marker { color: var(--eo-gold); font: 800 11px/1 ui-monospace, monospace; }
.eo-i-limit { margin: 10px 0 0; padding-top: 8px; border-top: 1px solid var(--eo-line); color: var(--eo-dim); font: 500 11px/1.4 system-ui, sans-serif; }
.eo-i-limit strong { color: var(--eo-ink); }

.eo-foot { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 13px 16px; border: 1px solid var(--eo-line); border-radius: 12px; background: var(--eo-panel); }
.eo-foot > span:first-child { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.eo-foot small { color: var(--eo-faint); font: 800 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; }
.eo-foot b { font: 800 12px/1.2 system-ui, sans-serif; }
.eo-foot em { color: var(--eo-gold); font: 700 11px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; font-style: normal; }
.eo-front-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin-top: 4px;
  padding: 11px 14px;
  border: 1px solid color-mix(in srgb, var(--eo-gold, #d7b256) 44%, var(--wl-line, #2b2e34));
  border-radius: 12px;
  background: color-mix(in srgb, var(--eo-gold, #d7b256) 7%, var(--wl-card-2, #17171c));
  color: var(--wl-ink, #f2f1ed);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.eo-front-cta b { color: var(--eo-gold, #d7b256); font: 800 13px/1.2 system-ui, sans-serif; }
.eo-front-cta span { color: var(--wl-muted, #a4a3a9); font: 700 11px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .04em; }
.eo-front-cta:hover { border-color: var(--eo-gold, #d7b256); }
.eo-front-cta:focus-visible { outline: 2px solid var(--eo-gold, #d7b256); outline-offset: 2px; }

.eo-foot-note { max-width: 460px; color: var(--eo-faint); font: 500 10px/1.4 system-ui, sans-serif; text-align: right; }

@media (max-width: 1100px) {
  .eo-lanes { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .eo-hero { grid-template-columns: 1fr; padding: 16px; }
  .eo-hero-main > strong { font-size: 44px; }
  .eo-lanes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .eo-action { grid-template-columns: 34px minmax(0, 1fr) 34px; gap: 10px; padding: 12px; }
  .eo-mark { width: 32px; height: 26px; font-size: 8px; }
  .eo-i > summary { width: 36px; height: 36px; font-size: 17px; }
  .eo-i-body { margin-left: 0; }
  .eo-foot { align-items: flex-start; flex-direction: column; gap: 8px; }
  .eo-foot-note { text-align: left; }
  .eo-group-head { padding: 12px; }
  .eo-actions { overflow: visible; }
}

.eo-note { margin: 0 2px; color: var(--eo-faint); font: 600 11px/1.45 system-ui, sans-serif; }
.eo-note b { color: var(--eo-ink); }

@media (max-width: 390px) {
  .eo-lanes { grid-template-columns: 1fr 1fr; }
  .eo-chip-top b { font-size: 11px; }
  .eo-action-top b { font-size: 13px; }
}
