/* OMERA MUSIC · Premium UI system v3 — shared visual layer, local preview only.
 * No framework, no external fonts, no layout animation forcing, motion opt-out supported.
 * Colors are tokens shared by home, catalog, lessons, reader, tools and forms. */
:root{
  --om-bg:#091625;--om-surface:#102439;--om-raised:#15314a;--om-border:#29475e;
  --om-accent:#63e5cb;--om-accent-strong:#38ccb7;--om-ink:#edf5fb;
  --om-subtle:#a9c0d1;--om-focus:#89f6e5;
  --om-elev:0 17px 46px rgba(2,11,23,.20);
  --om-radius:20px;
}
:root[data-theme="light"]{
  --om-bg:#f5f9fb;--om-surface:#ffffff;--om-raised:#eff7fa;--om-border:#d6e5eb;
  --om-accent:#087c74;--om-accent-strong:#0b8e82;--om-ink:#1c3043;
  --om-subtle:#586f7e;--om-focus:#057c79;--om-elev:0 12px 28px rgba(24,50,72,.08);
}
html{scroll-behavior:smooth}
html body{font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif!important;letter-spacing:0;font-weight:400;min-width:320px}
html:not([data-theme="light"]) body{background:var(--om-bg)!important;color:var(--om-ink)!important}
html[data-theme="light"] body{background:var(--om-bg)!important;color:var(--om-ink)!important}
html body :is(h1,h2,h3,h4){font-family:inherit;letter-spacing:-.032em;line-height:1.23;font-weight:570!important}
html body :is(strong,b){font-weight:600!important}
html body :is(p,li){line-height:1.66}
html body :is(button,input,select,textarea){font-family:inherit}
html body .wrap{max-width:1190px}
html body :is(a,button,input,select,textarea):focus-visible{outline:2px solid var(--om-focus)!important;outline-offset:3px}
html body button:not(:disabled){cursor:pointer}
/* unified chrome */
html:not([data-theme="light"]) body .portal-header{background:rgba(9,24,39,.96)!important;border-bottom:1px solid var(--om-border)!important;color:var(--om-ink)!important}
html[data-theme="light"] body .portal-header{background:rgba(253,255,255,.97)!important;border-bottom:1px solid var(--om-border)!important;color:var(--om-ink)!important}
html body .portal-header{position:sticky;top:0;z-index:1000;backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px)}
html body .portal-header .brand{letter-spacing:.025em;text-decoration:none}
html body .portal-header .brand .omera-brand-name{font-size:17px;font-weight:650!important;letter-spacing:.002em}
html body .portal-header .brand .omera-brand-name small{font-size:10px;font-weight:400;letter-spacing:.025em}
html body .portal-header .brand-icon{background:linear-gradient(140deg,#143f54,#176355)!important;color:#88ffdf!important;box-shadow:inset 0 0 0 1px #5bdfbc27}
html body .portal-header .nav a{font-size:12.5px!important;font-weight:510!important;letter-spacing:0;white-space:nowrap}
html body .portal-header .nav a[aria-current="page"]{color:var(--om-accent)!important}
html body .omera-header-search{border-radius:999px!important;border:1px solid var(--om-border)!important;background:var(--om-raised)!important;box-shadow:none!important}
html body .omera-header-search:focus-within{border-color:var(--om-accent)!important;box-shadow:0 0 0 3px color-mix(in srgb,var(--om-accent) 14%,transparent)!important}
html .portal-header .omera-header-search input{color:var(--om-ink)!important;background:transparent!important}
html .portal-header .omera-header-search input::placeholder{color:var(--om-subtle)!important}
html body .footer.portal-footer{background:var(--om-surface)!important;border-top:1px solid var(--om-border)!important;color:var(--om-subtle)!important}
html body .portal-footer .footbrand{font-weight:580!important;color:var(--om-ink)!important}
html body .portal-footer a{color:var(--om-subtle)!important;font-size:13px}
html body .portal-footer a:hover{color:var(--om-accent)!important}
/* consistent public section surfaces. Dedicated Studio editor internals unaffected */
html:not([data-theme="light"]) body :is(.portal-list-section,.portal-sidebar-card,.portal-lesson,.catalog-side,.chord-reader,.chord-reader-side,.song-chords-reference,.song-sheet-container,.song-about,.page-hero .card,.cards .card,.article,.aside,.ref-surface,.toolpanel,.tool-article,.form-card,.toolbox,.login-card,.practice-card,.step-card,.portal-empty,.reader,.band,.note,.omc-picker,.omc-playground,.studio-panel){background:var(--om-surface)!important;border-color:var(--om-border)!important;color:var(--om-ink)!important}
html[data-theme="light"] body :is(.portal-list-section,.portal-sidebar-card,.portal-lesson,.catalog-side,.chord-reader,.chord-reader-side,.song-chords-reference,.song-sheet-container,.song-about,.page-hero .card,.cards .card,.article,.aside,.ref-surface,.toolpanel,.tool-article,.form-card,.toolbox,.login-card,.practice-card,.step-card,.portal-empty,.reader,.band,.note,.omc-picker,.omc-playground,.studio-panel){background:var(--om-surface)!important;border-color:var(--om-border)!important;color:var(--om-ink)!important}
html body :is(.portal-list-section,.portal-sidebar-card,.portal-lesson,.catalog-side,.chord-reader,.chord-reader-side,.cards .card,.ref-surface,.toolpanel,.form-card,.omc-picker,.omc-playground,.login-card){border-radius:var(--om-radius)!important;box-shadow:var(--om-elev)}
html body :is(.portal-list-section,.portal-sidebar-card,.cards .card,.toolpanel,.chord-reader-side){transition:border-color .18s ease,transform .2s ease,box-shadow .2s ease}
html body :is(.portal-list-section,.portal-sidebar-card,.catalog-side,.chord-reader,.song-chords-reference,.song-sheet-container,.chord-reader-side){min-width:0}
html body :is(.portal-section-head h2,.portal-sidebar-card h2,.catalog-side h2,.song-section-head h2){font-size:clamp(19px,2vw,26px);font-weight:560!important;color:var(--om-ink)!important}
html body :is(.section-marker,.eyebrow,.omc-eyebrow,.song-eyebrow){letter-spacing:.11em;font-size:10px;font-weight:550!important;color:var(--om-accent)!important}
html body :is(.portal-section-head p,.portal-sidebar-card p,.catalog-count,.page-hero p,.article p,.card p){color:var(--om-subtle)!important}
html body .song-table-row{border-color:var(--om-border)!important;transition:background .16s ease,transform .18s ease}
html body .song-table-row:hover{transform:translateX(3px);background:var(--om-raised)!important}
html body .song-table-row .song-avatar{border-radius:13px;background:var(--om-raised)!important;color:var(--om-accent)!important}
html body .song-table-row .song-details strong{font-size:14px;font-weight:580!important}
html body .portal-more-link{font-weight:560!important;color:var(--om-accent)!important}
html body :is(.portal-lesson,.cards .card,.practice-card):hover{border-color:var(--om-accent)!important}
html body .portal-subnav{background:transparent!important;border-color:var(--om-border)!important}
html body .portal-subnav a{font-weight:450!important}
/* home hero stays centered as requested, with premium background and interactive strings */
html:not([data-theme="light"]) body.chord-portal .omera-home-hero{background:radial-gradient(ellipse at 79% 9%,#1a6a6650,transparent 48%),radial-gradient(ellipse at 8% 100%,#21476d44,transparent 49%),linear-gradient(128deg,#0a192c,#102942 63%,#0b2936)!important;border-color:var(--om-border)!important}
html[data-theme="light"] body.chord-portal .omera-home-hero{background:radial-gradient(ellipse at 75% 20%,#68d5c739,transparent 50%),linear-gradient(127deg,#e5f7f8,#f3f9fc)!important}
html body.chord-portal .omera-home-hero .portal-search-inner{min-height:398px;padding:65px 18px 46px}
html body.chord-portal .omera-home-hero .omera-hero-content{max-width:850px}
html body.chord-portal .omera-home-hero h1{font-weight:580!important;letter-spacing:-.043em;font-size:clamp(35px,4.1vw,59px)}
html:not([data-theme="light"]) body.chord-portal .omera-home-hero h1{color:var(--om-ink)!important}
html[data-theme="light"] body.chord-portal .omera-home-hero h1{color:var(--om-ink)!important}
html body.chord-portal .omera-home-hero h1 span{color:var(--om-accent)!important}
html body.chord-portal .omera-home-hero p{max-width:670px;font-size:14px;font-weight:400;color:var(--om-subtle)!important;line-height:1.7}
html body .omera-hero-eyebrow{font-weight:520!important;color:var(--om-accent)!important}
html body .omera-hero-primary{background:linear-gradient(110deg,#60e7c7,#a0edcc)!important;color:#103041!important;border:1px solid transparent!important;font-weight:590!important;border-radius:13px!important}
html body .omera-hero-secondary{background:var(--om-raised)!important;color:var(--om-ink)!important;border:1px solid var(--om-border)!important;font-weight:540!important;border-radius:13px!important}
html body .omera-hero-points{color:var(--om-subtle)!important;font-weight:430!important;gap:9px 24px}
html body .omera-hero-challenge-link{color:var(--om-accent)!important;font-weight:520!important}
.omera-hero-string-art{max-width:525px;margin:24px auto 0;display:flex;align-items:center;justify-content:center;gap:22px;opacity:.94}
.omera-hero-pick{display:grid;place-items:center;flex:0 0 55px;width:55px;height:55px;border-radius:50%;background:radial-gradient(circle at 30% 25%,#87ffe2,#27a897);box-shadow:0 0 0 10px #63e5cb12,0 0 35px #61d5bd28;color:#103144;font-size:25px;transform:rotate(-24deg)}
.omera-hero-strings{display:flex;flex-direction:column;gap:6px;flex:1;max-width:330px;transform:rotate(-2deg)}
.omera-hero-strings i{display:block;height:1px;background:linear-gradient(90deg,transparent,#60e3cc,#b5edeb,transparent);transform-origin:center;opacity:.65;box-shadow:0 0 8px #67f0df66}
.omera-hero-strings i:nth-child(-n+2){height:2px}
.omera-hero-strings.is-plucked i{animation:omera-string-twang .46s ease-in-out both;animation-delay:calc(var(--i)*40ms)}
@keyframes omera-string-twang{0%,100%{transform:translateY(0) scaleY(1)}25%{transform:translateY(3px) scaleY(2.2)}55%{transform:translateY(-2px) scaleY(.7)}}
/* demo chord — one action makes strings visibly move */
html body .omera-playground-copy h2,html body .omera-challenge-intro h2{font-weight:565!important;letter-spacing:-.033em;color:var(--om-ink)!important}
html body .omera-playground-copy h2 span,html body .omera-challenge-intro h2 span{color:var(--om-accent)!important}
html body .omera-playground-copy p,html body .omera-challenge-intro p{color:var(--om-subtle)!important}
html body .omera-play-label,html body .omera-playground-link{color:var(--om-accent)!important;font-weight:540!important}
html body .omera-try-card{background:var(--om-surface)!important;border-color:var(--om-border)!important;border-radius:var(--om-radius)!important;color:var(--om-ink)!important;box-shadow:var(--om-elev)}
html body .omera-try-card-header{border-color:var(--om-border)!important}
html body .omera-try-card-header strong{font-weight:570!important;color:var(--om-ink)!important}
html body .omera-try-diagram{background:var(--om-raised)!important;border-color:var(--om-border)!important}
html body .omera-try-choices button{font-weight:520!important}
html body .omera-try-strum{font-weight:570!important;background:var(--om-accent)!important;color:#0b2831!important}
.omera-try-diagram.is-plucked .omera-string{animation:omera-fretboard-pluck .50s cubic-bezier(.25,.7,.4,1) both;transform-origin:center}
.omera-try-diagram.is-plucked .omera-string:nth-of-type(2n){animation-delay:.045s}
@keyframes omera-fretboard-pluck{0%,100%{transform:translateX(0)}24%{transform:translateX(2.6px)}43%{transform:translateX(-1.6px)}65%{transform:translateX(1px)}}
/* Catalog and search: attractive but only real published songs, never fake trending. */
.omera-catalog-head{max-width:1190px;margin:27px auto 20px;padding:clamp(25px,4vw,42px);border:1px solid var(--om-border);border-radius:24px;background:radial-gradient(ellipse at 91% 10%,#1d7a7b3b,transparent 48%),var(--om-surface);box-shadow:var(--om-elev);position:relative;overflow:hidden}
.omera-catalog-head::after{content:'♪';position:absolute;right:7%;top:7%;font-size:clamp(75px,13vw,160px);color:var(--om-accent);opacity:.085;transform:rotate(-12deg);pointer-events:none}
.omera-catalog-head h1{margin:10px 0;font-size:clamp(29px,3.3vw,43px);font-weight:570!important;color:var(--om-ink)!important}
.omera-catalog-head p{color:var(--om-subtle)!important;margin:0 0 20px;max-width:560px;font-size:13px}
.omera-catalog-head .omera-catalog-search{display:flex;max-width:650px;background:var(--om-raised);border:1px solid var(--om-border);border-radius:15px;padding:5px;gap:5px;position:relative;z-index:1}
.omera-catalog-search input{flex:1;min-width:0;border:0!important;background:transparent!important;padding:10px 12px!important;color:var(--om-ink)!important;outline:none}
.omera-catalog-search button{border:0!important;background:var(--om-accent)!important;color:#103241!important;padding:10px 20px!important;border-radius:10px;font-weight:590!important}
html body .catalog-shell{align-items:start}
html body .catalog-side .letter-grid a{font-size:12px;min-height:34px}
/* Learning gallery chord stage gains depth without changing existing audio implementation */
html body .omc-studio{background:transparent!important}
html body .omc-studio-shell{gap:20px}
html body .omc-intro h1{font-weight:570!important;letter-spacing:-.045em}
html body .omc-stage{border-radius:17px!important;overflow:hidden;position:relative}
html body .omc-diagram{border-radius:15px}
html body .omc-diagram .omc-string{transition:stroke .18s ease}
html body .omc-diagram .omc-string.omc-string-pluck{filter:drop-shadow(0 0 4px var(--om-accent))}
html body .omc-actions button{font-weight:520!important;transition:transform .16s ease,border-color .16s ease}
html body .omc-actions button:active{transform:scale(.965)}
html body .omc-action-primary{background:var(--om-accent)!important;color:#103141!important}
/* chord reader: slimmer type, guided tools, visible string-player */
html body .chord-reader-wrap{max-width:1190px;gap:16px}
html body .chord-reader-header h1{font-weight:580!important;letter-spacing:-.04em;font-size:clamp(29px,3vw,43px)}
html body .song-artist{font-weight:460!important;color:var(--om-subtle)!important}
html body .song-chord-cards{gap:9px}
html body .song-diagram-card{border:1px solid var(--om-border)!important;border-radius:14px!important;background:var(--om-raised)!important;color:var(--om-ink)!important;transition:transform .18s ease,border-color .18s ease}
html body .song-diagram-card:hover{transform:translateY(-3px);border-color:var(--om-accent)!important}
html body .song-diagram-card strong{font-weight:530!important}
html body .song-editor .chord-token{color:var(--om-accent)!important;font-weight:580!important}
html body :is(.song-tools button,.song-reader-tools button,.song-chords-reference button,.song-header-actions button){font-weight:510!important;border-radius:10px}
.omera-strum-widget{background:var(--om-raised);border:1px solid var(--om-border);border-radius:17px;padding:17px;margin:5px 0 17px;color:var(--om-ink)}
.omera-strum-widget .omera-strum-caption{display:flex;align-items:center;justify-content:space-between;gap:7px;color:var(--om-subtle);font-size:11px}
.omera-strum-widget strong{font-size:23px;color:var(--om-accent);font-weight:570!important}
.omera-strum-widget .omera-strum-lines{display:flex;flex-direction:column;gap:8px;margin:17px 0 19px}
.omera-strum-widget .omera-strum-lines i{display:block;height:2px;border-radius:40px;background:linear-gradient(90deg,transparent,var(--om-accent),#d0f6ed,transparent);box-shadow:0 0 6px #67ebd159}
.omera-strum-widget.is-plucked .omera-strum-lines i{animation:omera-string-twang .45s ease-in-out;animation-delay:calc(var(--i)*30ms)}
.omera-strum-widget button{display:inline-flex;align-items:center;justify-content:center;gap:7px;width:100%;background:var(--om-accent)!important;color:#103141!important;font-weight:580!important;border:0;border-radius:10px;min-height:43px}
.omera-strum-widget small{display:block;color:var(--om-subtle)!important;margin-top:10px;font-size:10px;line-height:1.5}
/* Forms, tools, informational pages all use shared color system */
html body .page-hero{background:radial-gradient(ellipse at 85% 10%,#38cbb51e,transparent 55%),var(--om-bg)!important;border-color:var(--om-border)!important}
html body .page-hero h1{font-weight:570!important;font-size:clamp(28px,3vw,42px);color:var(--om-ink)!important}
html body :is(.cards .card,.portal-lesson,.practice-card,.tool-card){background:var(--om-surface)!important;color:var(--om-ink)!important;border-color:var(--om-border)!important}
html body :is(.cards .card,.portal-lesson,.practice-card,.tool-card) :is(h2,h3,strong){font-weight:560!important;color:var(--om-ink)!important}
html body :is(.cards .card,.portal-lesson,.practice-card,.tool-card) :is(p,small){color:var(--om-subtle)!important}
html body :is(.tools-heading,.tool-title,.ref-heading) {font-weight:560!important}
html body :is(.toolpanel,.form-card,.request-row,.ref-surface) button{font-weight:540!important}
html body .omera-theme-toggle{font-weight:520!important;background:var(--om-raised)!important;color:var(--om-ink)!important;border-color:var(--om-border)!important}
html body :is(.login-card,.studio-panel) h1{font-weight:560!important}
/* Quiet reveal: ordinary content always visible when JS is off. */
.omera-v3-visible{animation:omera-v3-rise .40s cubic-bezier(.18,.83,.3,1) both}
@keyframes omera-v3-rise{from{opacity:.80;transform:translateY(10px)}to{opacity:1;transform:none}}
@media(max-width:820px){
 html body .omera-catalog-head{margin:15px 16px;padding:24px 18px}
 html body .omera-home-playground{gap:16px}
 .omera-catalog-head::after{opacity:.045}
}
@media(max-width:600px){
 html body.chord-portal .omera-home-hero .portal-search-inner{padding:48px 18px 38px}
 html body .portal-header .brand .omera-brand-name{font-size:15px}
 .omera-hero-string-art{margin:21px auto 0;gap:14px}.omera-hero-pick{width:40px;height:40px;flex-basis:40px;font-size:19px}
 html body .omera-catalog-head .omera-catalog-search{width:100%}
 html body .omera-catalog-head h1{font-size:31px}
 html body .portal-list-section{border-radius:16px!important}
 html body .chord-reader-wrap{gap:11px}
}
@media(prefers-reduced-motion:reduce){
 html{scroll-behavior:auto}
 .omera-hero-strings.is-plucked i,.omera-try-diagram.is-plucked .omera-string,.omera-strum-widget.is-plucked .omera-strum-lines i,.omera-v3-visible{animation:none!important}
 html body :is(.song-table-row,.song-diagram-card,.cards .card,.portal-lesson){transition:none!important;transform:none!important}
}
/* Compact game entry on learning page. */
.omera-game-inline-link{display:flex;align-items:center;gap:15px;max-width:100%;padding:17px 22px;border-radius:17px;background:var(--om-surface);border:1px solid var(--om-border);color:var(--om-accent)!important;font-weight:570!important;box-shadow:var(--om-elev);text-decoration:none;transition:transform .17s,border-color .17s}
.omera-game-inline-link span{margin-left:auto}.omera-game-inline-link small{color:var(--om-subtle)!important;font-size:12px;font-weight:400}
.omera-game-inline-link:hover{transform:translateY(-2px);border-color:var(--om-accent)}
@media(max-width:520px){.omera-game-inline-link{flex-wrap:wrap;gap:6px 10px}.omera-game-inline-link small{width:100%;order:2}}
/* One accent color for chord names, labels and markers throughout the reader. */
html body :is(.song-editor .song-chord-row,.song-editor .song-section-title,.song-diagram-unavailable,.chord-diagram-name){color:var(--om-accent)!important}
html body .omc-diagram .omc-dot{fill:var(--om-accent)!important}

/* OMERA MUSIC v3.1 — readability and responsive finishing.
 * No new theme or feature changes. Never conceal headlines with truncation. */
html body{overflow-wrap:normal}
html body :is(.portal-feed,.portal-sidebar,.catalog-shell,.catalog-shell > *,
 .portal-list-section,.portal-lessons,.portal-sidebar-card,.portal-lesson,
 .omera-home-playground,.omera-home-playground > *, .omera-try-card,
 .omera-quest-section,.quest-shell,.quest-stage,.quest-stage > *,
 .song-table,.song-table-row,.song-details,.song-reader,.chord-reader,
 .chord-reader-wrap,.chord-reader-wrap > *, .chord-reader-header,
 .page-hero .wrap,.cards,.cards > *,.toolpage,.toolpage > *,
 .form-card,.studio-panel,.footer-flex,.footlinks){min-width:0;max-width:100%;box-sizing:border-box}
/* Let visible text occupy the full available space and wrap at word boundaries.
   Chord sheets / editor code retain their intentional preformatted spacing. */
html body :is(.portal-section-head,.portal-sidebar-card,.omera-catalog-head,
 .omera-playground-copy,.omera-try-card,.quest-shell,.quest-page-intro,
 .page-hero,.article,.toolpanel,.tool-article,.form-card,.studio-panel,
 .portal-lesson,.cards .card,.song-reader-header,.chord-reader-header)
 :is(h1,h2,h3,h4,p,small,strong,a){overflow-wrap:break-word;word-break:normal;hyphens:auto}
html body :is(.portal-section-head h2,.portal-sidebar-card h2,.page-hero h1,
 .omera-catalog-head h1,.chord-reader-header h1,.quest-shell h2){
 text-wrap:balance;white-space:normal;overflow:visible;text-overflow:clip;
}
html body :is(.portal-section-head p,.portal-sidebar-card p,.catalog-count,
 .omera-catalog-head p,.page-hero p){text-wrap:pretty;white-space:normal}
/* Keep section actions apart from the heading: no clipped text under CTA. */
html body .portal-section-head{
 display:grid;grid-template-columns:minmax(0,1fr) auto;
 align-items:end;column-gap:clamp(12px,2vw,22px);row-gap:9px;
}
html body .portal-section-head > :first-child{min-width:0;max-width:100%;}
html body .portal-section-head h2{
 margin:5px 0 6px;font-size:clamp(21px,2.2vw,26px);
 line-height:1.29;font-weight:550!important;letter-spacing:-.025em;
}
html body .portal-section-head p{font-size:clamp(12px,1.3vw,13px);line-height:1.58;margin:0}
html body .portal-section-head .section-marker{display:block;line-height:1.4;font-size:10px;letter-spacing:.07em}
html body .portal-section-head .portal-more-link{
 display:inline-flex;align-items:center;justify-content:flex-start;
 justify-self:end;align-self:end;min-width:0;max-width:100%;
 font-size:12px;line-height:1.45;font-weight:520!important;
 white-space:normal;overflow-wrap:break-word;padding:6px 0;
}
/* In tables and card grids, long titles wrap instead of being truncated. */
html body .song-table-row{max-width:100%;min-width:0}
html body .song-details{flex:1 1 0;min-width:0}
html body .song-details :is(strong,small){display:block;white-space:normal;overflow-wrap:break-word;word-break:normal;text-overflow:clip;line-height:1.5}
html body .song-tonic,html body .song-arrow,html body .song-avatar{flex-shrink:0}
html body :is(.quest-choice,.quest-mode button,.quest-controls button,
 .omera-try-choices button,.omera-hero-actions a,.omera-game-inline-link,
 .portal-more-link,.catalog-search button){white-space:normal;overflow-wrap:break-word;text-align:center}
html body .portal-lesson h3,html body .cards .card h3{line-height:1.35}
html body .omera-catalog-head{isolation:isolate}
html body .omera-catalog-head > *{position:relative;z-index:1;min-width:0;max-width:100%}
html body .omera-catalog-head .omera-catalog-search{box-sizing:border-box;max-width:100%;min-width:0}
html body .omera-catalog-search input{min-width:0;max-width:100%;text-overflow:ellipsis}
/* Real chord/lyric alignment is not touched; only the title and controls wrap. */
html body .chord-reader-header :is(h1,.song-artist){white-space:normal;overflow-wrap:break-word;max-width:100%}
html body .chord-reader-wrap :is(.song-tools,.song-reader-tools,.song-header-actions){max-width:100%;flex-wrap:wrap}
html body .omera-strum-widget{min-width:0;max-width:100%}
html body .omera-try-main > *{min-width:0;max-width:100%}
html body .omera-home-hero .omera-hero-content{min-width:0;width:100%;box-sizing:border-box}
html body .omera-home-hero h1{overflow-wrap:break-word;hyphens:auto}
/* Prevent decorative floating notes from creating a phantom horizontal scroll.
   Their visual effects remain and will never truncate the actual heading. */
html body .omera-home-hero{overflow-x:clip}
html body .omera-hero-decoration{max-width:100%;pointer-events:none}
@media(max-width:660px){
 html body .portal-section-head{grid-template-columns:minmax(0,1fr);align-items:start;row-gap:7px}
 html body .portal-section-head .portal-more-link{
  justify-self:start;align-self:start;font-size:12px;padding:5px 0;
 }
 html body .portal-section-head h2{font-size:clamp(21px,5.5vw,24px)}
 html body .portal-section-head p{font-size:12.5px;max-width:50ch}
 html body .portal-list-section{min-width:0;max-width:100%}
 html body .portal-sidebar-card{min-width:0}
 /* Make every catalog subnavigation link visible instead of clipping the last one. */
 html body .portal-subnav .subnav-inner{display:flex;flex-wrap:wrap;
  white-space:normal;overflow:visible;gap:5px 14px;
  justify-content:flex-start;padding-top:10px;padding-bottom:10px;min-height:0}
 html body .portal-subnav .subnav-inner a{white-space:normal;font-size:12px;line-height:1.4;padding:3px 0}
 html body .portal-subnav .subnav-inner .subnav-request{margin-left:0}
 html body .omera-catalog-head{border-radius:17px;margin-left:auto;margin-right:auto;padding:24px 19px}
 html body .omera-catalog-head h1{font-size:clamp(27px,7.5vw,36px);line-height:1.24}
 html body .omera-catalog-head .omera-catalog-search{gap:4px}
 html body .omera-catalog-search button{flex-shrink:0;padding:10px 12px!important}
 html body .quest-shell .quest-top{gap:9px}
 html body .quest-shell .quest-top > *{min-width:0}
 html body .quest-choice{min-width:0;font-size:clamp(17px,5vw,23px)}
}
@media(max-width:360px){
 html body .omera-catalog-head{padding:22px 16px}
 html body .portal-section-head h2{font-size:21px}
 html body .song-table-row{gap:8px;padding:10px}
 html body .song-avatar{width:37px;height:37px;font-size:13px}
 html body .song-tonic{font-size:11px}
 html body .omera-try-choices{gap:5px}
 html body .omera-try-choices button{min-width:0;padding:8px 5px}
}

/* Omera Music v3.2 — compact empty catalog states; no double boxes or fake pagination.
   This layer uses existing light/dark design tokens, without altering Studio or D1. */
html body .catalog-shell .catalog-is-empty{padding:clamp(18px,2.7vw,27px)!important}
html body .catalog-is-empty .portal-section-head{margin:0 0 8px!important}
html body .catalog-is-empty .portal-section-head h2{margin:0!important;line-height:1.28}
html body .catalog-empty{
 display:flex;align-items:flex-start;gap:14px;
 margin-top:10px;padding:16px 0 3px;
 background:transparent!important;border:0!important;
 border-top:1px solid var(--om-border)!important;
 border-radius:0!important;box-shadow:none!important;
 min-height:0;width:100%;max-width:100%;box-sizing:border-box;
}
html body .catalog-empty[hidden],html body #latestSongList[hidden]{display:none!important}
html body .catalog-empty-icon{
 width:38px;height:38px;flex:0 0 38px;display:grid;place-items:center;
 font-size:20px;line-height:1;border-radius:12px;
 color:var(--om-accent);background:var(--om-raised);border:1px solid var(--om-border)
}
html body .catalog-empty-content{min-width:0;flex:1 1 0}
html body .catalog-empty h3{margin:0 0 4px;font-size:15px;line-height:1.45;font-weight:550!important;letter-spacing:-.012em;color:var(--om-ink)!important}
html body .catalog-empty p{margin:0;color:var(--om-subtle)!important;font-size:12.5px;line-height:1.55;max-width:58ch}
html body .catalog-empty-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-top:13px}
html body .catalog-empty-action{
 display:inline-flex;justify-content:center;align-items:center;
 font-size:12px;line-height:1.4;font-weight:530!important;
 text-decoration:none!important;padding:8px 13px;border-radius:10px;
 color:var(--om-ink)!important;border:1px solid var(--om-border);background:transparent;
 transition:background-color .18s,border-color .18s,transform .18s;
}
html body .catalog-empty-action.catalog-empty-primary{background:var(--om-accent)!important;border-color:var(--om-accent)!important;color:#102a32!important}
html body .catalog-empty-action:hover{background:var(--om-raised);border-color:var(--om-accent);transform:translateY(-1px)}
html body .catalog-is-empty .catalog-pages{margin-top:13px}
/* Home uses the same single compact state instead of an empty song-table and another large card. */
html body #latestSongEmpty{margin-top:0;padding:16px 0 6px}
html body .portal-list-section #latestSongEmpty[hidden]{display:none!important}
@media(max-width:540px){
 html body .catalog-shell .catalog-is-empty{padding:17px!important}
 html body .catalog-empty{gap:10px;padding-top:13px}
 html body .catalog-empty-icon{width:33px;height:33px;flex-basis:33px;font-size:17px;border-radius:10px}
 html body .catalog-empty h3{font-size:14px}
 html body .catalog-empty-actions{margin-top:11px;gap:7px}
 html body .catalog-empty-action{padding:8px 10px;font-size:11.5px}
}
@media(prefers-reduced-motion:reduce){html body .catalog-empty-action{transition:none}html body .catalog-empty-action:hover{transform:none}}


/* Omera v3.3 — beranda: section katalog ditampilkan hanya bila lagu benar-benar tersedia.
   Menghindari heading+CTA kosong dan pesan gagal API pada local preview. */
html body #omeraHomeLatest[hidden]{display:none!important}
html body .omera-home-latest .portal-section-head,
html body .omera-home-practice .portal-section-head{
 display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;
 column-gap:12px;row-gap:3px;margin:0 0 15px;
}
html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head h2{
 margin:0;line-height:1.3;font-size:clamp(19px,2.2vw,24px);
}
html body .omera-home-practice .portal-section-head p{
 margin-top:5px;font-size:12px;line-height:1.45;max-width:44ch;
}
html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head .portal-more-link{
 justify-self:end;align-self:center;margin:0;padding:7px 0;
 white-space:nowrap;font-size:12px;
}
html body .omera-home-practice .song-tonic{display:none}
html body .omera-home-practice .song-table-row{min-height:62px}
@media(max-width:540px){
 html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head{
  grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:start;margin-bottom:12px;
 }
 html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head h2{font-size:21px}
 html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head .portal-more-link{
  white-space:nowrap;align-self:start;padding:4px 0;font-size:11.5px;
 }
 html body .omera-home-practice .portal-section-head p{font-size:11.5px;margin-top:5px}
 html body .omera-home-practice .song-table-row{min-height:60px;padding:9px 11px}
}
@media(max-width:340px){
 html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head h2{font-size:19px}
 html body :is(.omera-home-latest,.omera-home-practice) .portal-section-head .portal-more-link{font-size:11px}
}


/* OMERA MUSIC v3.4 — home practice list spacing and cleaner mobile rhythm. */
html body .omera-home-practice .song-table{padding:10px 10px 6px}
html body .omera-home-practice .song-table-row{padding:16px 18px;gap:14px;border-radius:16px;min-height:82px}
html body .omera-home-practice .song-table-row + .song-table-row{border-top:1px solid var(--om-border)!important}
html body .omera-home-practice .song-avatar{width:52px;height:52px;border-radius:16px;font-size:20px}
html body .omera-home-practice .song-details strong{font-size:15px;line-height:1.35}
html body .omera-home-practice .song-details small{font-size:12px;line-height:1.55}
html body .omera-home-practice .song-tonic{min-width:42px;display:inline-flex;align-items:center;justify-content:center}
html body .omera-home-practice .song-arrow{padding-left:6px}
@media(max-width:600px){
 html body .omera-home-practice .portal-section-head{margin-bottom:12px}
 html body .omera-home-practice .song-table{padding:8px 10px 4px}
 html body .omera-home-practice .song-table-row{padding:15px 14px;gap:12px;min-height:78px}
 html body .omera-home-practice .song-avatar{width:44px;height:44px;border-radius:14px;font-size:18px}
 html body .omera-home-practice .song-details strong{font-size:14px}
 html body .omera-home-practice .song-details small{font-size:11.5px}
 html body .omera-home-practice .song-tonic{min-width:36px;padding:4px 8px}
}
