  @import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;700&family=Share+Tech+Mono&display=swap');

  :root {
    --red:    #c1121f;
    --darkred:#7d0000;
    --green:  #2dc653;
    --yellow: #f4b942;
    --orange: #e07b39;
    --purple: #a970ff;
    --bg:     #0d0d0d;
    --card:   #161616;
    --border: #2a2a2a;
    --text:   #e8e8e8;
    --muted:  #888;
  }

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

  body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Rajdhani', sans-serif;
    min-height: 100vh;
    padding: 2rem 1rem;
  }

  .container { max-width: 860px; margin: 0 auto; }

  /* ── Header ── */
  .header {
    text-align: center;
    margin-bottom: 2.5rem;
    position: relative;
    padding-bottom: 1.5rem;
  }
  .header::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background: var(--red);
    margin: 1.25rem auto 0;
  }
  .header .eyebrow {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.75rem;
    color: var(--red);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
  }
  .header h1 {
    font-size: 2.6rem;
    font-weight: 700;
    line-height: 1.1;
    text-transform: uppercase;
    letter-spacing: 0.05em;
  }
  .header h1 span { color: var(--red); }
  .header .subtitle {
    margin-top: 0.6rem;
    color: var(--muted);
    font-size: 1rem;
    font-family: 'Share Tech Mono', monospace;
    letter-spacing: 0.05em;
  }

  .badge-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap; /* allows stacking on very small screens */
    width: 100%; 
  }

  .el-badge {
    width: 150px;
    height: auto;
    flex: 0 0 auto;
  }

  .badge-title {
    display: flex;
    text-align: left;
    flex-direction: column;
    align-items: flex-start; /* keeps title text left-aligned while the block is centered */
  }

  .goal-badge {
    display: inline-block;
    margin-top: 1rem;
    background: var(--darkred);
    border: 1px solid var(--red);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    padding: 0.4rem 1.2rem;
    text-transform: uppercase;
  }

  /* ── CTAs ── */
  .cta-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.25rem;
  }
  .cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    padding: 0.55rem 1.25rem;
    border-radius: 2px;
    font-weight: 700;
    transition: filter 0.2s, transform 0.15s;
  }
  .cta-btn:hover { filter: brightness(1.15); transform: translateY(-1px); }
  .cta-twitch    { background: #6441a5; border: 1px solid var(--purple); color: #fff; }
  .cta-extralife { background: #0d3320; border: 1px solid var(--green);  color: var(--green); }
  .cta-note {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.65rem;
    color: var(--muted);
    letter-spacing: 0.08em;
    text-align: center;
    margin-top: 0.5rem;
  }
  .cta-note span { color: var(--green); }

  /* ── Tier Headers ── */
  .tier-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 2rem 0 0.75rem;
  }
  .tier-dot  { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; }
  .tier-label {
    font-size: 0.7rem;
    font-family: 'Share Tech Mono', monospace;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--muted);
  }
  .tier-title {
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
  }

  /* ── Milestone Cards ── */
  .milestones { display: flex; flex-direction: column; gap: 0.5rem; }

  /* card-wrap is the data-milestone-id target — no visual styling */
  .card-wrap { display: contents; }

  .card {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 90px 1fr;
    align-items: start;
    background: var(--card);
    border: 1px solid var(--border);
    border-left: 3px solid var(--border);
    padding: 0.75rem 1rem;
    transition: border-color 0.2s;
  }
  .card .amount {
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    font-weight: 700;
    padding-top: 0.1rem;
    position: relative;
    z-index: 2;
  }
  .card .desc {
    font-size: 1rem;
    line-height: 1.4;
    position: relative;
    z-index: 2;
  }
  .card .desc .tag {
    display: inline-block;
    font-size: 0.75rem;
    font-family: 'Share Tech Mono', monospace;
    letter-spacing: 0.1em;
    padding: 0.1rem 0.4rem;
    margin-right: 0.4rem;
    border-radius: 2px;
    vertical-align: middle;
    position: relative;
    top: -1px;
  }
  .card .note {
    font-size: 0.78rem;
    color: var(--muted);
    margin-top: 0.3rem;
    font-family: 'Share Tech Mono', monospace;
  }

  /* ── Capstone Cards ── */
  .capstone-card {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1a0a0a, #161616);
    border: 1px solid #3a1010;
    border-left: 3px solid var(--red);
    padding: 1rem;
    margin-top: 0.25rem;
    transition: border-color 0.2s;
  }
  .capstone-card:hover { border-left-color: #ff4444; border-color: #5a1010; }
  .cap-top { display: grid; grid-template-columns: 90px 1fr; align-items: start; position: relative; z-index: 2; }
  .cap-top .amount {
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    font-weight: 700;
    color: var(--red);
    padding-top: 0.1rem;
  }
  .cap-name {
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #fff;
    letter-spacing: 0.05em;
  }
  .cap-desc {
    font-size: 0.9rem;
    color: #bbb;
    margin-top: 0.35rem;
    line-height: 1.5;
  }

  /* ── Tier color mappings ── */
  .tier-green .tier-dot  { background: var(--green); }
  .tier-green .tier-title { color: var(--green); }
  .tier-green .card      { border-left-color: #1a4a28; color: var(--text); }
  .tier-green .card:hover { border-left-color: var(--green); }
  .tier-green .amount    { color: var(--green); }
  .tier-green .tag       { background: #1a4a2880; color: var(--green); border: 1px solid #2dc65350; }

  .tier-yellow .tier-dot  { background: var(--yellow); }
  .tier-yellow .tier-title { color: var(--yellow); }
  .tier-yellow .card      { border-left-color: #4a3a10; color: var(--text); }
  .tier-yellow .card:hover { border-left-color: var(--yellow); }
  .tier-yellow .amount    { color: var(--yellow); }
  .tier-yellow .tag       { background: #4a3a1080; color: var(--yellow); border: 1px solid #f4b94250; }

  .tier-orange .tier-dot  { background: var(--orange); }
  .tier-orange .tier-title { color: var(--orange); }
  .tier-orange .card      { border-left-color: #4a2810; color: var(--text); }
  .tier-orange .card:hover { border-left-color: var(--orange); }
  .tier-orange .amount    { color: var(--orange); }
  .tier-orange .tag       { background: #4a281080; color: var(--orange); border: 1px solid #e07b3950; }

  .tier-red .tier-dot    { background: var(--red); }
  .tier-red .tier-title  { color: var(--red); }

  /* ── JS State Classes — currentColor anchors ── */
  .g-done, .g-active { color: var(--green);  }
  .y-done, .y-active { color: var(--yellow); }
  .o-done, .o-active { color: var(--orange); }
  .r-done, .r-active { color: var(--red);    }

  .g-done, .g-active { border-left-color: var(--green) !important; }
  .y-done, .y-active { border-left-color: var(--yellow) !important; }
  .o-done, .o-active { border-left-color: var(--orange) !important; }
  .r-done, .r-active { border-left-color: var(--red) !important; }

  .g-wait { border-left-color: #1a4a28; }
  .y-wait { border-left-color: #4a3a10; }
  .o-wait { border-left-color: #4a2810; }
  .r-wait { border-left-color: #4a0a0a; }

  /* ── Badge Wrap (lock / LIVE / check) ── */
  .badge-wrap {
    position: absolute;
    top: 0.55rem;
    right: 0.75rem;
    z-index: 3;
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.7rem;
    letter-spacing: 0.08em;
  }

  .live-pip {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--green);
    font-weight: 700;
  }
  .live-pip .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
  }
  .lock   { opacity: 0.3; font-size: 0.8rem; }
  .check  { font-size: 1rem; font-weight: 700; }

  /* ── Progress Row ── */
  .progress-row {
    min-height: 1.2rem;
    font-size: 0.75rem;
    font-family: 'Share Tech Mono', monospace;
    margin-top: 0.35rem;
    transition: opacity 0.4s ease;
    position: relative;
    z-index: 2;
  }
  .progress-row:empty { opacity: 0; }

  /* ── Rules Box ── */
  .rules-box {
    margin-top: 2.5rem;
    border: 1px solid #2a2a2a;
    border-top: 3px solid var(--red);
    padding: 1.25rem;
    background: #111;
  }
  .rules-box h3 {
    font-size: 0.75rem;
    font-family: 'Share Tech Mono', monospace;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--red);
    margin-bottom: 0.9rem;
  }
  .rules-box ul { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
  .rules-box ul li {
    font-size: 0.92rem;
    color: #ccc;
    padding-left: 1.2rem;
    position: relative;
    line-height: 1.45;
  }
  .rules-box ul li::before { content: '›'; color: var(--red); position: absolute; left: 0; font-weight: 700; }

  /* ── Footer ── */
  .footer {
    text-align: center;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.7rem;
    color: var(--muted);
    letter-spacing: 0.1em;
  }
  .footer span { color: var(--red); }

  /* ════════════════════════════════════════════
     milestones-animations.css — INLINED
     ════════════════════════════════════════════ */

  .fill {
    position: absolute;
    top: 0; left: 0; bottom: 0;
    z-index: 1;
    pointer-events: none;
    width: 0%;
    transition: width 1.4s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .g-active .fill { background: linear-gradient(90deg, #2dc65332 0%, #2dc65318 55%, transparent 100%); }
  .y-active .fill { background: linear-gradient(90deg, #f4b94232 0%, #f4b94218 55%, transparent 100%); }
  .o-active .fill { background: linear-gradient(90deg, #e07b3932 0%, #e07b3918 55%, transparent 100%); }
  .r-active .fill { background: linear-gradient(90deg, #c1121f32 0%, #c1121f18 55%, transparent 100%); }

  .g-done .fill { background: linear-gradient(90deg, #2dc65328 0%, #2dc65310 65%, transparent 100%); transition: none; }
  .y-done .fill { background: linear-gradient(90deg, #f4b94228 0%, #f4b94210 65%, transparent 100%); transition: none; }
  .o-done .fill { background: linear-gradient(90deg, #e07b3928 0%, #e07b3910 65%, transparent 100%); transition: none; }
  .r-done .fill { background: linear-gradient(90deg, #c1121f28 0%, #c1121f10 65%, transparent 100%); transition: none; }

  .active-card {
    box-shadow: 0 0 0 1px currentColor, 0 4px 24px -4px rgba(0,0,0,0.6);
  }
  .active-card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 2px;
    opacity: 0;
    animation: pulse-border 2.2s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
  }
  .g-active::before { border: 1px solid var(--green);  box-shadow: 0 0 14px #2dc65344; }
  .y-active::before { border: 1px solid var(--yellow); box-shadow: 0 0 14px #f4b94244; }
  .o-active::before { border: 1px solid var(--orange); box-shadow: 0 0 14px #e07b3944; }
  .r-active::before { border: 1px solid var(--red);    box-shadow: 0 0 14px #c1121f44; }

  @keyframes pulse-border {
    0%, 100% { opacity: 0;   }
    50%       { opacity: 0.7; }
  }
  .live-pip .dot { animation: blink 1.3s ease-in-out infinite; }
  @keyframes blink {
    0%, 100% { opacity: 1;    }
    50%       { opacity: 0.15; }
  }

  .ms-entering { animation: step-forward 0.6s cubic-bezier(0.2, 0, 0.3, 1) forwards; }
  @keyframes step-forward {
    0%   { opacity: 0.38; transform: translateY(4px) scale(0.995); filter: brightness(0.5); }
    100% { opacity: 1;    transform: translateY(0)  scale(1);      filter: brightness(1);   }
  }

  .ms-completing { animation: completion-flash 1s ease-out forwards; }
  @keyframes completion-flash {
    0%   { filter: brightness(1);   box-shadow: 0 0 0px  transparent; }
    20%  { filter: brightness(2.2); box-shadow: 0 0 40px currentColor; }
    50%  { filter: brightness(1.4); box-shadow: 0 0 20px currentColor; }
    100% { filter: brightness(0.85); box-shadow: none; }
  }

  .check { animation: check-pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4) forwards; transform-origin: center; }
  @keyframes check-pop {
    0%   { transform: scale(0);    opacity: 0; }
    70%  { transform: scale(1.25); opacity: 1; }
    100% { transform: scale(1);    opacity: 1; }
  }

  .waiting::after {
    content: '';
    position: absolute;
    top: 0; left: -100%; bottom: 0;
    width: 60%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.025) 50%, transparent 100%);
    animation: shimmer 8s ease-in-out infinite;
    z-index: 2;
    pointer-events: none;
  }
  @keyframes shimmer {
    0%        { left: -60%;  }
    20%, 100% { left: 120%;  }
  }