/* PianoBoss v2 look (REDESIGN_SPEC.md phase 1, 2026-11-24): navy + copper, serif display, the new menu and the
   "Your projects" home. Every rule is scoped to html.ui-v2, which is ON for every visitor since 2026-11-24 (?ui=v1 opts a browser out).
   Tokens: the 2026-11-20 mockups, as used in the approved blueprint. */
html.ui-v2 {
  --v2-navy-0: #0b1222; --v2-navy-1: #0f1628; --v2-navy-2: #161f36; --v2-navy-3: #1c2744; --v2-navy-4: #243150;
  --v2-copper: #c87a43; --v2-copper-hi: #e0a172; --v2-copper-lo: #8c5229;
  --v2-ivory: #f1e8d8; --v2-slate: #9aa3b8; --v2-line: rgba(241,232,216,.12); --v2-line-2: rgba(241,232,216,.22);
  --v2-serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;

  /* The v1 tokens, remapped, so every page (lessons, play screen, sounds) takes the new colours. */
  --bg-0: var(--v2-navy-1); --bg-1: var(--v2-navy-2); --bg-2: var(--v2-navy-3); --bg-3: var(--v2-navy-4);
  --line: var(--v2-line);
  --brass: var(--v2-copper); --brass-hi: var(--v2-copper-hi); --brass-lo: var(--v2-copper-lo); --brass-glow: rgba(200,122,67,.28);
  --ivory: var(--v2-ivory); --text: var(--v2-ivory); --text-dim: var(--v2-slate); --muted: #7d869b;
  --ebony: #1a120b;
  --black-key-active: var(--v2-copper);
  /* rgb triplets of the tokenised v1 literals (css/styles.css uses rgba(var(--brass-rgb), a) etc.) */
  --brass-rgb: 200,122,67; --brass-hi-rgb: 224,161,114; --ebony-rgb: 11,18,34;
  color-scheme: dark;
}
html.ui-v2 body { background: var(--v2-navy-1); font-variant-numeric: lining-nums; }   /* Cormorant's default old-style figures read '60' as '6o' */

/* Headings in the display serif. */
html.ui-v2 h2, html.ui-v2 h3, html.ui-v2 h1.brand-name { font-family: var(--v2-serif); font-weight: 600; letter-spacing: 0; }
html.ui-v2 h1.brand-name { font-size: 28px; }
html.ui-v2 h1.brand-name span { color: var(--v2-ivory); font-style: normal; font-weight: 600; }

/* Buttons: solid copper primary, quiet outline secondary. */
html.ui-v2 .btn { border-radius: 8px; border-color: var(--v2-line-2); background: transparent; }
html.ui-v2 .btn:hover { background: var(--v2-navy-3); color: var(--v2-ivory); border-color: var(--v2-copper); }
html.ui-v2 .btn-primary { background: var(--v2-copper); border-color: var(--v2-copper); color: #1a120b; box-shadow: none; }
html.ui-v2 .btn-primary:hover { background: var(--v2-copper-hi); border-color: var(--v2-copper-hi); color: #1a120b; transform: none; box-shadow: none; }

/* ---- header + menu ---- */
html.ui-v2 header { background: var(--v2-navy-0); backdrop-filter: none; -webkit-backdrop-filter: none; gap: 20px; justify-content: flex-start; padding: 14px 32px; }
html.ui-v2 header nav { background: transparent; border: 0; padding: 0; gap: 2px; margin-left: auto; }
html.ui-v2 .nav-btn, .v2-mp-btn, html.ui-v2 .user-menu .btn { white-space: nowrap; }
html.ui-v2 .nav-btn { color: var(--v2-slate); border: 0; border-radius: 0; padding: 10px 12px; font-size: 14px; border-bottom: 2px solid transparent; }
html.ui-v2 .nav-btn:hover { color: var(--v2-ivory); background: transparent; }
html.ui-v2 .nav-btn.active { color: var(--v2-ivory); background: transparent; box-shadow: none; border-bottom-color: var(--v2-copper); }
html.ui-v2 .nav-btn:focus-visible, html.ui-v2 .v2-mp-btn:focus-visible, html.ui-v2 #v2-home button:focus-visible { outline: 2px solid var(--v2-copper-hi); outline-offset: 2px; }
html.ui-v2 .user-menu .user-chip { background: transparent; border-color: var(--v2-line-2); }
.v2-mypractice { position: relative; }
.v2-mp-btn { font: 500 14px 'Inter', sans-serif; color: var(--v2-ivory); background: transparent; border: 1px solid var(--v2-line-2); border-radius: 8px; padding: 7px 12px; cursor: pointer; }
.v2-mp-btn:hover { border-color: var(--v2-copper); }
.v2-mp-menu { position: absolute; top: calc(100% + 6px); left: 0; z-index: 60; min-width: 200px; display: grid; padding: 6px; background: var(--v2-navy-2); border: 1px solid var(--v2-line-2); border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,.45); }
.v2-mp-menu[hidden] { display: none; }
.v2-mp-menu button { text-align: left; font: 500 14px 'Inter', sans-serif; color: var(--v2-ivory); background: transparent; border: 0; border-radius: 6px; padding: 9px 10px; cursor: pointer; }
.v2-mp-menu button:hover, .v2-mp-menu button:focus-visible { background: var(--v2-navy-3); outline: none; }

@media (max-width: 1100px) {
  html.ui-v2 header { flex-wrap: wrap; padding: 10px 16px; gap: 10px; }
  html.ui-v2 header nav { order: 3; width: 100%; margin-left: 0; flex-wrap: wrap; justify-content: flex-start; row-gap: 2px; }   /* wraps: every item stays visible on phones */
  html.ui-v2 header nav::-webkit-scrollbar { display: none; }
  html.ui-v2 .nav-btn { white-space: nowrap; padding: 8px 10px; }
  html.ui-v2 .user-menu { margin-left: auto; }
}

/* ---- the Projects home: hide the v1 home blocks (trial banner and the plan card stay) ---- */
html.ui-v2 #view-home > .hero,
html.ui-v2 #view-home > #featured-songs,
html.ui-v2 #view-home > #level-tiles { display: none; }
html.ui-v2 #view-home > .upgrade-card { margin-top: 28px; background: var(--v2-navy-2); border-color: var(--v2-line); }
html.ui-v2 #view-home { padding-bottom: 8px; }

#v2-home { display: grid; gap: 22px; color: var(--v2-ivory); }
#v2-library, #v2-lessons, #v2-progress { scroll-margin-top: 90px; }
#v2-home button { font: inherit; color: inherit; text-align: left; cursor: pointer; }
.v2-h { font-size: clamp(36px, 5vw, 52px); margin: 0; line-height: 1.05; }
.v2-h2 { font-size: 28px; margin: 10px 0 0; }
.v2-hello { margin: -14px 0 0; }
.v2-muted { color: var(--v2-slate); margin: 0; }
.v2-eyebrow { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--v2-copper-hi); }
.v2-btn { display: inline-block; justify-self: start; padding: 10px 18px; border-radius: 8px; background: var(--v2-copper); color: #1a120b; font-weight: 600; font-size: 14px; }

.v2-art { position: relative; overflow: hidden; border-radius: 10px; background: var(--v2-navy-3); }
.v2-fill { position: absolute; inset: 0; }

.v2-hero-row { display: grid; gap: 16px; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.v2-cont { position: relative; display: grid; min-height: 260px; border-radius: 12px; overflow: hidden; border: 1px solid var(--v2-line); background: var(--v2-navy-2); padding: 0; }
.v2-cont > .v2-art { position: absolute; inset: 0; border-radius: 0; }
/* the photo behind the card text (ArtCraft 2026-11-29): a navy wash from the left keeps the title readable */
.v2-cont > .v2-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(11,18,34,.9) 25%, rgba(11,18,34,.45) 65%, rgba(11,18,34,.1)); }
.v2-cont-body { position: relative; display: grid; align-content: center; gap: 8px; padding: 26px; max-width: 34em; }
.v2-cont .v2-eyebrow { color: var(--v2-ivory); opacity: .85; }
.v2-cont-title { font-family: var(--v2-serif); font-size: clamp(32px, 4vw, 44px); font-weight: 600; line-height: 1.05; }
.v2-cont-meta { color: var(--v2-slate); }
.v2-cont-sub { color: var(--v2-slate); font-size: 13px; }
.v2-cont:hover .v2-btn { background: var(--v2-copper-hi); }
.v2-cont-done { cursor: default; }

.v2-panel { background: var(--v2-navy-2); border: 1px solid var(--v2-line); border-radius: 12px; padding: 18px; min-width: 0; }
.v2-panel .v2-h2 { margin: 0 0 6px; font-size: 26px; }
.v2-upnext { display: grid; }
.v2-un { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px 0; background: transparent; border: 0; border-top: 1px solid var(--v2-line); }
.v2-un .v2-art { height: 58px; }
.v2-un-title { display: block; font-family: var(--v2-serif); font-size: 20px; font-weight: 600; line-height: 1.15; }
.v2-un-line { display: block; color: var(--v2-slate); font-size: 13px; margin-top: 2px; }
.v2-un:hover .v2-un-title { color: var(--v2-copper-hi); }

.v2-progress { display: grid; gap: 12px; grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(0, 2fr); }
.v2-progress > div { background: var(--v2-navy-2); border: 1px solid var(--v2-line); border-radius: 10px; padding: 12px 14px; display: grid; gap: 2px; min-width: 0; }
/* Figures in Inter: the display serif only has old-style figures, where 0 reads as "o". */
.v2-progress b { font-family: 'Inter', sans-serif; font-size: 24px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.v2-progress span { color: var(--v2-slate); font-size: 13px; }
.v2-progress .v2-goal span:last-child { color: var(--v2-ivory); font-size: 14px; }
.v2-progress .v2-goal.ok { border-color: color-mix(in srgb, #7fb37a 50%, transparent); }

.v2-tiles { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); }
.v2-tile { position: relative; display: block; min-height: 160px; padding: 0; border-radius: 10px; overflow: hidden; border: 1px solid var(--v2-line); background: var(--v2-navy-3); }
.v2-tile > .v2-art { position: absolute; inset: 0; border-radius: 0; }
.v2-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11,18,34,.1) 0%, rgba(11,18,34,.55) 38%, rgba(11,18,34,.94) 78%); }   /* titles stay readable over photos (2026-11-29) */
.v2-tile-cap { position: absolute; left: 14px; right: 14px; bottom: 10px; z-index: 1; display: grid; gap: 2px; }
.v2-tile-ttl { font-family: var(--v2-serif); font-size: 24px; font-weight: 600; line-height: 1.1; text-shadow: 0 2px 10px rgba(0,0,0,.6); }
.v2-tile-sub { font-size: 12.5px; color: var(--v2-ivory); opacity: .85; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.v2-tile:hover { border-color: var(--v2-copper); }

.v2-lessons { display: grid; gap: 10px; }
.v2-lessonbar { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto; gap: 14px; align-items: center; min-height: 60px; padding: 0 16px 0 0; border-radius: 10px; overflow: hidden; border: 1px solid var(--v2-line); background: var(--v2-navy-2); }
.v2-lessonbar .v2-art { align-self: stretch; border-radius: 0; min-height: 60px; }
.v2-lb-name { font-family: var(--v2-serif); font-size: 21px; font-weight: 600; }
.v2-lb-prog { display: flex; align-items: center; gap: 10px; color: var(--v2-slate); font-size: 13px; white-space: nowrap; }
.v2-bar { display: block; width: 110px; height: 6px; border-radius: 3px; background: var(--v2-navy-4); overflow: hidden; }
.v2-bar i { display: block; height: 100%; background: var(--v2-copper); }
.v2-lessonbar:hover { border-color: var(--v2-copper); }

@media (max-width: 820px) {
  .v2-hero-row { grid-template-columns: 1fr; }
  .v2-progress { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .v2-progress .v2-goal { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  html.ui-v2 .container { padding-left: 16px; padding-right: 16px; }
  .v2-cont { min-height: 230px; }
  .v2-cont-body { padding: 20px; }
  .v2-lessonbar { grid-template-columns: 64px minmax(0, 1fr); padding-right: 12px; }
  .v2-lessonbar .v2-art { grid-row: 1 / 3; }
  .v2-lb-prog { grid-column: 2; padding-bottom: 10px; }
  .v2-lb-name { padding-top: 10px; font-size: 19px; }
  .v2-bar { width: 90px; }
}
@media (prefers-reduced-motion: no-preference) {
  .v2-tile, .v2-lessonbar, .v2-cont .v2-btn { transition: border-color .15s, background-color .15s; }
}

/* Levels on the home (Jean 2026-11-24: only Beginner · Intermediate · Advanced · Expert) + the Styles page */
.v2-levels { display: grid; gap: 12px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.v2-level { position: relative; display: block; min-height: 150px; padding: 0; border-radius: 12px; overflow: hidden; border: 1px solid var(--v2-line); background: var(--v2-navy-3); }
.v2-level > .v2-art { position: absolute; inset: 0; border-radius: 0; }
.v2-level::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11,18,34,.15) 20%, rgba(11,18,34,.85)); }
.v2-level-body { position: absolute; left: 14px; right: 14px; bottom: 12px; z-index: 1; display: grid; gap: 6px; }
.v2-level-name { font-family: var(--v2-serif); font-size: 28px; font-weight: 600; line-height: 1; text-shadow: 0 2px 10px rgba(0,0,0,.6); }
.v2-level-line { font-size: 13px; color: var(--v2-ivory); opacity: .85; }
.v2-level .v2-bar { width: 100%; }
button.v2-level:hover { border-color: var(--v2-copper); }
.v2-level-soon { opacity: .7; }
.v2-styles-link { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 18px; border-radius: 10px; border: 1px solid var(--v2-line); background: var(--v2-navy-2); color: var(--v2-slate); }
.v2-styles-link span { color: var(--v2-copper-hi); font-weight: 600; }
.v2-styles-link:hover { border-color: var(--v2-copper); }
#v2-styles { display: grid; gap: 18px; color: var(--v2-ivory); }
#v2-styles button { font: inherit; color: inherit; text-align: left; cursor: pointer; }
#v2-styles .v2-h2 { margin-top: 18px; }
#v2-styles .v2-muted { margin-top: -10px; }
html.ui-v2 #v2-styles button:focus-visible { outline: 2px solid var(--v2-copper-hi); outline-offset: 2px; }
@media (max-width: 820px) { .v2-levels { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .v2-level { min-height: 130px; } .v2-level-name { font-size: 24px; } }

/* ---- phase 2 pages: Song Library + Lessons (REDESIGN_SPEC phase 2) ---- */
.v2-page { display: grid; gap: 18px; color: var(--v2-ivory); }
.v2-page > .v2-muted { margin-top: -10px; }
.v2-page button { font: inherit; text-align: left; cursor: pointer; }
.v2-page button:not(.v2-btn) { color: inherit; }
html.ui-v2 .v2-page button:focus-visible, html.ui-v2 .v2-page input:focus-visible, html.ui-v2 .v2-more:focus-visible { outline: 2px solid var(--v2-copper-hi); outline-offset: 2px; }
.v2-page .v2-btn { border: 0; color: #1a120b; text-align: center; }
.v2-page .v2-tile[hidden] { display: none; }
.v2-libtools { display: grid; gap: 12px; }
.v2-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.v2-chip { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--v2-line-2); background: transparent; font-size: 14px; }
.v2-chip:hover { border-color: var(--v2-copper); }
.v2-chip.on { background: var(--v2-copper); border-color: var(--v2-copper); color: #1a120b !important; font-weight: 600; }
.v2-search { width: 100%; max-width: 420px; box-sizing: border-box; padding: 10px 14px; border-radius: 8px; border: 1px solid var(--v2-line-2); background: var(--v2-navy-2); color: var(--v2-ivory); font: 15px 'Inter', sans-serif; }
.v2-search::placeholder { color: var(--v2-slate); }
.v2-libcount:empty { display: none; }
.v2-h2row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.v2-more { background: transparent; border: 0; padding: 4px 0; color: var(--v2-copper-hi) !important; font-weight: 600; font-size: 14px; }
.v2-more:hover { text-decoration: underline; }
.v2-lvcards { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.v2-lvcard { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: 120px auto; border-radius: 12px; overflow: hidden; border: 1px solid var(--v2-line); background: var(--v2-navy-2); }
.v2-lvcard > .v2-art { border-radius: 0; }
.v2-lvcard-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; min-width: 0; align-content: start; padding: 16px 18px 18px; }
.v2-lvcard-name { margin: 0; font-size: 30px; line-height: 1; }
.v2-lvcard-desc { margin: 0; color: var(--v2-slate); font-size: 14px; line-height: 1.45; }
.v2-lvcard-meta { margin: 0; font-size: 13px; }
.v2-lvcard .v2-bar { width: 100%; }
.v2-lvcard-acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.v2-lvcard-acts .v2-btn { min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v2-btn-ghost { padding: 9px 16px; border-radius: 8px; border: 1px solid var(--v2-line-2); background: transparent; font-size: 14px; font-weight: 500; }
.v2-btn-ghost:hover { border-color: var(--v2-copper); }
@media (max-width: 820px) { .v2-lvcards { grid-template-columns: minmax(0, 1fr); } .v2-lvcard { grid-template-rows: 90px auto; } }

/* ---- phase 3a: practice view, Free Play, Sounds (REDESIGN_SPEC phase 3) ----
   Most colours follow the tokens; these panels used neutral-black gradients that end at --ebony, which v2 keeps as the
   dark text colour on copper, so their backgrounds are set here. Layout and player logic are unchanged. */
html.ui-v2 .piano-wrap { background: var(--v2-navy-2); border-color: var(--v2-line); }
html.ui-v2 .falling-stage { background: linear-gradient(180deg, var(--v2-navy-0) 0%, var(--v2-navy-1) 100%); border-color: var(--v2-line); }
html.ui-v2 .falling-placeholder { color: var(--v2-slate); }
html.ui-v2 #view-play.active ~ #piano-shell .falling-placeholder { display: none; }   /* a lesson hint; in Free Play it named a difficulty picker that is not there and was cut off on phones */
html.ui-v2 .diff-btn { background: var(--v2-navy-3); border-color: var(--v2-line-2); }
html.ui-v2 .diff-btn:hover { border-color: var(--v2-copper); }
html.ui-v2 .diff-btn.active { border-color: var(--v2-copper); background: rgba(200,122,67,.14); }   /* the chosen arrangement */
html.ui-v2 .unlock-card:hover { background: var(--v2-navy-3); }
html.ui-v2 .patch-btn.active, html.ui-v2 .cat-btn.active { background: rgba(200,122,67,.14); border-color: var(--v2-copper); color: var(--v2-copper-hi); }
html.ui-v2 #pb-loader { background: radial-gradient(ellipse at center, var(--v2-navy-2) 0%, var(--v2-navy-1) 60%, var(--v2-navy-0) 100%); }
html.ui-v2 #pb-loader .pb-loader-brand .pb-loader-logo::before, html.ui-v2 #pb-loader .pb-loader-brand .pb-loader-logo::after { background: var(--v2-navy-2); }
html.ui-v2 .m31-stop-card { background: var(--v2-navy-2); border-color: rgba(200,122,67,.4); }

/* ---- phase 3b: practice screen layout (REDESIGN_SPEC phase 3b, blueprint screen 6) ----
   Layout only; the player and its markup are unchanged. The phone-landscape (m31) and iPad (t31) layouts keep their own
   drawers, so the fold-away list applies outside them. */
.v2-lesson-acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.v2-lesson-eyebrow:empty { display: none; }
html.ui-v2 .lesson-sidebar:empty { display: none; }   /* the player empties it when a lesson ends */
.v2-lesson-eyebrow { margin-bottom: 4px; }
html.ui-v2 body.m31-active #v2-ls-toggle, html.ui-v2 body.t31-active #v2-ls-toggle { display: none; }
html.ui-v2 body:not(.m31-active):not(.t31-active) #view-lesson.v2-ls-closed .lesson-sidebar { display: none; }
@media (min-width: 1024px) {
  html.ui-v2 body:not(.m31-active):not(.t31-active) #view-lesson.active.v2-ls-closed { padding-left: 0; }
  /* the keyboard always takes the full width (the list sits beside the lesson panel only), so opening or closing the
     list never moves a key: notes already falling keep lining up with their keys */
  html.ui-v2 body:not(.m31-active):not(.t31-active) #view-lesson.active ~ #piano-shell { padding-left: 0; }
}
html.ui-v2 .lesson-header { align-items: flex-start; gap: 12px; margin-bottom: 14px; }
/* song lessons (the ones with the arrangement picker): a compact toolbar instead of the big centred cards */
html.ui-v2 .lesson-prompt:has(#diff-bar, .play-hud) { text-align: left; padding: 18px 20px; }
html.ui-v2 .lesson-prompt .play-hud { justify-content: flex-start; }   /* the playing HUD keeps the picker's alignment */
html.ui-v2 #lesson-prompt-body:has(#diff-bar) { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
html.ui-v2 #lesson-prompt-body:has(#diff-bar) > .instruction { flex-basis: 100%; font-size: 14px; }
html.ui-v2 #lesson-prompt-body:has(#diff-bar) > * { margin: 0 !important; }
html.ui-v2 .difficulty-bar { justify-content: flex-start; gap: 6px; }
html.ui-v2 .diff-btn { flex-direction: column; align-items: flex-start; gap: 1px; min-width: 0; padding: 7px 14px; border-radius: 12px; }
html.ui-v2 .diff-btn .diff-name { font-size: 14px; }
html.ui-v2 .diff-btn .diff-desc { font-size: 12px; color: var(--v2-slate); }
html.ui-v2 .tempo-bar { padding: 0; border: 0; background: none; gap: 6px; }
html.ui-v2 .tempo-lbl { color: var(--v2-slate); }
html.ui-v2 .tempo-btn { border-radius: 999px; padding: 6px 12px; background: transparent; border-color: var(--v2-line-2); }
html.ui-v2 .tempo-btn:hover { border-color: var(--v2-copper); }
html.ui-v2 .tempo-btn.active { background: var(--v2-copper); border-color: var(--v2-copper); color: #1a120b; box-shadow: none; }
html.ui-v2 .v2-lesson-acts .btn { white-space: nowrap; }
html.ui-v2 .landscape-nudge { background: var(--v2-navy-3); color: var(--v2-ivory); border: 1px solid var(--v2-copper); }
html.ui-v2 .landscape-nudge .ln-dismiss { background: var(--v2-copper); color: #1a120b; }

/* ---- quiet palette (Jean 2026-11-24: "no cheap colors there, pink, oranges … The look has to stay professonal", then "Yes
   apply it to the main site too"). Every saturated literal in css/styles.css is a --q-* token; each maps to its quiet
   family at the same lightness: green → sage, red → brick, pink / orange / amber / gold → copper, blue / teal → steel,
   violet → slate. */
html.ui-v2 {
  --q-0f2747-rgb: 32,41,54;   /* steel */
  --q-14532d-rgb: 42,61,47;   /* sage */
  --q-16a34a-rgb: 76,109,84;   /* sage */
  --q-22c55e-rgb: 95,136,105;   /* sage */
  --q-376b95-rgb: 77,98,128;   /* steel */
  --q-3a2205-rgb: 49,29,14;   /* copper */
  --q-422006-rgb: 56,33,16;   /* copper */
  --q-4a2d0a-rgb: 65,38,19;   /* copper */
  --q-4a90e2-rgb: 124,146,176;   /* steel */
  --q-4ab09a-rgb: 102,148,114;   /* sage */
  --q-5aa0d6-rgb: 126,148,178;   /* steel */
  --q-6ab0ff-rgb: 162,177,199;   /* steel */
  --q-6ecb8a-rgb: 139,174,148;   /* sage */
  --q-6fc9b4-rgb: 138,174,147;   /* sage */
  --q-78350f-rgb: 98,43,37;   /* brick */
  --q-78c88c-rgb: 143,177,151;   /* sage */
  --q-7a4390-rgb: 90,99,121;   /* slate */
  --q-7ec8c8-rgb: 140,159,186;   /* steel */
  --q-7fc67f-rgb: 146,179,154;   /* sage */
  --q-86efac-rgb: 174,199,180;   /* sage */
  --q-8a6e3a-rgb: 138,91,58;   /* copper */
  --q-8bc6ee-rgb: 172,186,205;   /* steel */
  --q-8ec5ff-rgb: 184,196,213;   /* steel */
  --q-8fd0a3-rgb: 161,190,168;   /* sage */
  --q-8fd9a1-rgb: 166,193,173;   /* sage */
  --q-9fc7e8-rgb: 181,193,210;   /* steel */
  --q-9fd085-rgb: 155,186,163;   /* sage */
  --q-a87cea-rgb: 168,174,190;   /* slate */
  --q-b4e0e0-rgb: 189,200,215;   /* steel */
  --q-b6e5c2-rgb: 197,214,201;   /* sage */
  --q-b85a3f-rgb: 179,79,68;   /* brick */
  --q-b8860b-rgb: 151,89,44;   /* copper */
  --q-b96ad6-rgb: 146,154,174;   /* slate */
  --q-bbf7d0-rgb: 210,224,214;   /* sage */
  --q-c4e8d0-rgb: 207,221,210;   /* sage */
  --q-c7e3ff-rgb: 220,226,234;   /* steel */
  --q-c8a86a-rgb: 200,145,106;   /* copper */
  --q-d4af37-rgb: 200,122,67;   /* copper */
  --q-d97706-rgb: 173,101,50;   /* copper */
  --q-dc2626-rgb: 186,84,72;   /* brick */
  --q-dc6e6e-rgb: 206,133,125;   /* brick */
  --q-dc8c6e-rgb: 206,133,125;   /* brick */
  --q-dcfce7-rgb: 233,239,234;   /* sage */
  --q-e07b5a-rgb: 201,122,113;   /* brick */
  --q-e87f5a-rgb: 203,127,119;   /* brick */
  --q-e89080-rgb: 214,153,146;   /* brick */
  --q-e8a034-rgb: 204,132,80;   /* copper */
  --q-e8b87a-rgb: 220,170,134;   /* copper */
  --q-e8f5d5-rgb: 224,234,227;   /* sage */
  --q-ef4444-rgb: 199,117,108;   /* brick */
  --q-f0d399-rgb: 229,191,164;   /* copper */
  --q-f4c87a-rgb: 223,176,143;   /* copper */
  --q-f4d89a-rgb: 230,194,168;   /* copper */
  --q-f59e0b-rgb: 198,116,58;   /* copper */
  --q-f5d4c2-rgb: 235,207,204;   /* brick */
  --q-f87171-rgb: 214,154,147;   /* brick */
  --q-fbbf24-rgb: 205,133,82;   /* copper */
  --q-fbd987-rgb: 227,187,159;   /* copper */
  --q-fcd34d-rgb: 214,156,115;   /* copper */
  --q-fde68a-rgb: 228,190,163;   /* copper */
  --q-ff783c-rgb: 201,122,114;   /* brick */
  --q-ff7878-rgb: 218,163,157;   /* brick */
  --q-ff8ab5-rgb: 229,191,164;   /* copper */
  --q-ff8c5a-rgb: 210,143,135;   /* brick */
  --q-ff9562-rgb: 212,148,141;   /* brick */
  --q-ffaa78-rgb: 225,181,150;   /* copper */
  --q-ffc7b5-rgb: 235,205,201;   /* brick */
  --q-ffd68a-rgb: 229,191,164;   /* copper */
  --q-ffd6b5-rgb: 238,215,198;   /* copper */
  --q-ffd98a-rgb: 229,191,164;   /* copper */
  --q-ffdf87-rgb: 228,189,162;   /* copper */
  --advanced: #929aae;
  --black-key-target: #7e94b2;
  --error: #c97a71;
  --intermed: #7e94b2;
  --white-key-correct: #b8cebe;
  --white-key-target: #d7dee7;
  --white-key-wrong: #e6c0bc;
}
/* inline per-track accents (js/app.js levelArt, featured songs, song preview) and the confetti: copper / ivory / sage only */
html.ui-v2 [style*="--tile-accent"] { --tile-accent: var(--v2-copper) !important; }
html.ui-v2 [style*="--spm-accent"] { --spm-accent: var(--v2-copper) !important; }
html.ui-v2 [style*="--fs-accent"] { --fs-accent: var(--v2-copper) !important; }
html.ui-v2 .progress-fill { background: var(--v2-copper) !important; }
html.ui-v2 .confetti { background: var(--v2-copper) !important; }
html.ui-v2 .confetti:nth-child(3n) { background: var(--v2-ivory) !important; }
html.ui-v2 .confetti:nth-child(3n+1) { background: var(--v2-copper-hi) !important; }
html.ui-v2 header a.brand { color: inherit; }
/* the keyboard's learning cues stay clearly readable (quiet, but not pale): key to press = steel, correct = sage, wrong = brick */
html.ui-v2 .key.white.target { background: linear-gradient(180deg, #b4c6df, #8fa9cc); }
html.ui-v2 .key.white.correct { background: linear-gradient(180deg, #b3d1ba, #86ad90); }
html.ui-v2 .key.white.wrong { background: linear-gradient(180deg, #e0aaa2, #c0645a); }
html.ui-v2 .key.black.target { background: linear-gradient(180deg, #9fb5d3, #6f8fb5); }
/* inline amber hint text in the mic step / melody modes (js/lessons/player.js) */
html.ui-v2 #ms-note, html.ui-v2 #mm-next, html.ui-v2 #mic-shape-note { color: var(--v2-copper-hi) !important; }

/* ---- phase 4: the public welcome for signed-out visitors (blueprint screen 1) ---- */
.v2-welcome { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); border-radius: 14px; overflow: hidden; border: 1px solid var(--v2-line); min-height: 320px; }
.v2-welcome-copy { display: grid; align-content: center; gap: 14px; padding: 34px; background: linear-gradient(90deg, var(--v2-navy-0), var(--v2-navy-1)); }
.v2-welcome-h { font-size: clamp(40px, 5.5vw, 62px); line-height: 1.02; }
.v2-welcome-p { margin: 0; color: var(--v2-slate); font-size: 17px; max-width: 34ch; }
.v2-welcome-acts { display: flex; gap: 10px; flex-wrap: wrap; }
#v2-home .v2-welcome-acts .v2-btn { border: 0; color: #1a120b; text-align: center; padding: 11px 18px; }
.v2-welcome-pic { min-height: 260px; background: url('../img/site/welcome.webp') center / cover no-repeat, radial-gradient(120% 90% at 80% 30%, #e0a17255, transparent 60%), linear-gradient(120deg, #1c2744, #3a2a1f 70%, #c87a43); }
.v2-aud { display: grid; gap: 12px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.v2-audcard { display: grid; gap: 4px; padding: 16px 18px; border-radius: 12px; border: 1px solid var(--v2-line); background: var(--v2-navy-2); color: var(--v2-ivory); text-decoration: none; }
.v2-audcard:hover { border-color: var(--v2-copper); }
.v2-audname { font-family: var(--v2-serif); font-size: 24px; font-weight: 600; }
.v2-audline { color: var(--v2-slate); font-size: 14px; }
/* signed-in home: the same picture as a slim banner (Jean 2026-11-24: "sign in users should have graphics as well") */
.v2-welcome-in { min-height: 0; margin-bottom: 4px; }
.v2-welcome-in .v2-welcome-copy { padding: 24px 30px; gap: 6px; }
.v2-welcome-in .v2-hello { margin: 0; }
.v2-welcome-in .v2-welcome-pic { min-height: 170px; }
@media (max-width: 820px) { .v2-welcome { grid-template-columns: 1fr; } .v2-welcome-pic { min-height: 180px; } .v2-welcome-in .v2-welcome-pic { min-height: 120px; } .v2-aud { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .v2-aud { grid-template-columns: 1fr; } }

/* Your projects (PROJECTS_SPEC 5d, 2026-11-25): one card per song the learner added, Resume opens its section */
html.ui-v2 .v2-projects { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); margin-bottom: 22px; }
html.ui-v2 .v2-proj, html.ui-v2 .v2-proj-start { display: grid; gap: 8px; align-content: start; text-align: left; padding: 14px 16px; border-radius: 12px;
  border: 1px solid var(--v2-line); background: var(--v2-navy-2); color: var(--v2-ivory); font: inherit; }
html.ui-v2 .v2-proj-start { width: 100%; margin-bottom: 22px; cursor: pointer; }
html.ui-v2 .v2-proj-new { cursor: pointer; border-style: dashed; place-content: center; text-align: center; min-height: 120px; }
html.ui-v2 .v2-proj-new:hover, html.ui-v2 .v2-proj-start:hover { border-color: var(--v2-copper); }
html.ui-v2 .v2-proj-title { font-family: var(--v2-serif); font-size: 20px; font-weight: 600; line-height: 1.2; }
html.ui-v2 .v2-proj-meta { color: var(--v2-slate); font-size: 13px; }
html.ui-v2 .v2-proj-acts { display: flex; gap: 10px; align-items: center; margin-top: 4px; }
html.ui-v2 .v2-proj-acts .v2-btn { padding: 7px 16px; border: 0; color: #1a120b; }
html.ui-v2 .v2-proj-remove { background: none; border: 0; color: var(--v2-slate); font: 13px Inter, sans-serif; cursor: pointer; padding: 4px; }
html.ui-v2 .v2-proj-remove:hover { color: var(--v2-ivory); text-decoration: underline; }
.proj-add-btn.on { opacity: .75; cursor: default; }

/* Level test card on the home page (placement P2, Jean 2026-11-28) */
.v2-leveltest { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; border: 1px solid var(--v2-line); border-left: 4px solid var(--brass-hi, #c9a227); border-radius: 14px; padding: 18px 22px; margin: 14px 0; background: rgba(201, 162, 39, 0.06); }
.v2-leveltest .v2-lt-copy { flex: 1 1 320px; display: flex; flex-direction: column; gap: 4px; }
.v2-leveltest .v2-h2 { margin: 0; }
.v2-leveltest .v2-muted { margin: 0; }
.v2-leveltest .v2-lt-acts { display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 600px) { .v2-leveltest { padding: 14px 16px; } .v2-leveltest .v2-lt-acts { width: 100%; } .v2-leveltest .v2-lt-acts > * { flex: 1 1 auto; } }
