
.overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(10px);
    /* Apply blur effect */
    -webkit-backdrop-filter: blur(10px);
    /* For Safari compatibility */
    background-color: rgba(0, 0, 0, 0);
    /* Semi-transparent background */
    z-index: -1;
    /* Position behind the overlay content */
}
.clickable-note {
    cursor: pointer;
}
.injected-svg {
    -webkit-touch-callout: none;
    /* iOS Safari */
    -webkit-user-select: none;
    /* Safari */
    -khtml-user-select: none;
    /* Konqueror HTML */
    -moz-user-select: none;
    /* Old versions of Firefox */
    -ms-user-select: none;
    /* Internet Explorer/Edge */
    user-select: none;
    /* Non-prefixed version, currently supported by Chrome, Opera, and Firefox */
}
/* .carousel-caption {
    position: relative;
    left: 0;
    top: 0;
} */
/* .carousel-indicators {
    li {
        text-indent: 0;
        margin: 0 2px;
        width: 30px;
        height: 30px;
        border: none;
        border-radius: 100%;
        line-height: 30px;
        color: #fff;
        background-color: #999;
        transition: all 0.25s ease;

        &.active,
        &:hover {
            margin: 0 2px;
            width: 30px;
            height: 30px;
            color: #fff;
        background-color: #337ab7;
        }
    }
} */

/* .carousel-controls-container {
    position: absolute;
    bottom: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 20px;

} */

/* .ReactPiano__NoteLabel{
    color:black;
} */

.injected-svg{
    max-height: 100%;
    max-width: 100%;
}
.lesson-description{
    margin-bottom: 1rem;
    margin-top: 1rem;
    font-size: 1.1rem;
}
.lesson-text {
    font-size: 1.2rem;
    font-weight: bold;
    color: #4477aa;
}
.lesson-hint {
    font-size: 1.1rem;
}
.page-title {
    /* typography (already in your sheet, repeated here for clarity) */
    color: var(--text-primary);
    font-weight: 700;
    /* font-bold          */
    letter-spacing: -0.025em;
    /* tracking-tight     */
    font-size: 1.875rem;
    /* text-3xl           */
    line-height: 2.25rem;
    text-align: center;

    /* responsive up-size */
    @media (min-width: 640px) {
        font-size: 2.25rem;
        /* text-4xl           */
        line-height: 2.5rem;
    }

    /* --- spacing --- */
    margin-top: 2.5rem;
    /* optional mt-5      */
    margin-bottom: 1rem;
    /* Tailwind mb-4      */
}

.summary {
    color: var(--text-secondary);
    font-size: 1rem;
    /* text-base          */
    line-height: 1.5rem;

    @media (min-width: 640px) {
        font-size: 1.125rem;
        /* text-lg            */
        line-height: 1.75rem;
    }

    max-width: 60rem;
    /* max-w-2xl          */
    margin: 0 auto 3rem;
    /* 0 top, auto sides, 3rem bottom (mb-12) */
    /* text-align: center; */
    display: block;
    /* ensures new line   */
}
.lesson-title {
    /* Example styling; adjust as needed */
    margin-top: 20px;
}
/*
.card-body a {
    color: inherit;
    text-decoration: none;
}

.card-body a:hover {
    text-decoration: underline;
}

.card-text a,
.card-title a {
    color: inherit;
    text-decoration: none;
}

.card-text a:hover,
.card-title a:hover {
    text-decoration: underline;
}
*/
.card a {
    color: inherit;
    /* Inherits the text color from the parent element */
    text-decoration: none;
    /* Removes the underline from links */
}

.card a:hover {
    text-decoration: underline;
    /* Optionally, add underline on hover */
}

.card-img-top { 
    height: 200px;
    /* Adjust this value as needed Card image */
    object-fit: cover;
    /* Keeps the image aspect ratio */
    width: 100%;
    /* Ensures the image covers the full width of the card */
}

.card-body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: #ffffff;
    /* Distributes space evenly */
}
.card-footer {
    background: #ffffff;
    /* Distributes space evenly */
}

.featured-exercises {
    margin-top: auto;
    /* Positions the featured exercises at the bottom of the card */
}

 .card-img-top {
     width: 100%;
     /* Image takes full width of the card */
     height: auto;
     /* Height is set to auto to maintain aspect ratio */
     object-fit: contain;
     /* Ensures the entire image fits inside the card */
 }
 .small-composer-photo {
     max-width: 70%;
 }
.copyright {
    text-align: center;
    font-size: 0.8rem;
    margin-top: 2rem;
    color: #666;
    font-family: serif;
}
.badge-circle {
    display: inline-flex;
    /* Use flexbox to easily center content */
    justify-content: center;
    /* Center horizontally */
    align-items: center;
    width: 22px;
    /* Slightly increased size */
    height: 22px;
    /* Slightly increased size */
    border: 1px solid #000;
    /* Add a border */
    border-radius: 50%;
    /* Make it round */
    margin: 0 2px;
    /* Add a little space between badges */
    box-sizing: border-box;
    /* Include padding and border in the element's total width and height */
    font-size: 0.8em;
    /* Adjust font size if needed */
    /* Added transition for a smoother hover/selection effect */
    transition: all 0.2s ease-in-out;
}

/* Optional: style the content inside */
.badge-content {
    /* You can add specific text styling here if needed */
}

/* Style for indicating something (e.g., making it bold) */
.badge-circle.bold .badge-content {
    font-weight: bold;
}

/* New style for 'achieved' state (inverted colors) */
.badge-circle.achieved {
    background-color: #000;
    /* Filled black */
    border-color: #000;
    /* Ensure border is also black */
    color: #fff;
    /* Text color white */
}

/* Ensure the content also becomes white when the parent has 'achieved' class */
.badge-circle.achieved .badge-content {
    color: #fff;
    /* Overrides potential default text color */
}
/*  Disable Bootstrap’s hover / focus darkening on coarse‑pointer devices
    while preserving the intentional .active colour.                    */
/* Touch devices: suppress the sticky hover/focus colour, keep real press feedback */

@media (hover: none) and (pointer: coarse) {

    .btn-outline-dark:hover:not(:active):not(.active),
    .btn-outline-dark:focus:not(:active):not(.active) {
        background-color: transparent !important;
        color: #212529 !important;
        border-color: #212529 !important;
        box-shadow: none !important;
    }
}
.abcjs-title {font-size: 20px;}
.abcjs-fingering {
    font-size: 13px;
}
.abcjs-annotation {
    font-size: 12px;
}
.qlavist-arrow {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.qlavist-arrow.visible {
    opacity: 1;
    visibility: visible;
}
.qlavist-check {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.qlavist-check.visible {
    opacity: 1;
    visibility: visible;
}
.qlavist-wave {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.qlavist-wave.visible {
    opacity: 1;
    visibility: visible;
}
.qlavist-check {
    fill: #008930;
    /* or #2e8540 / #2ecc71 style green */
}
.qlavist-arrow {
    fill: #000000;
    /* same as hintColor */
}
.qlavist-wave {
    fill: #000000;
    /* amber / honey yellow */
}
.vertical-switch {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    /* keep it compact next to buttons */
    padding: 0 .25rem;
}

.vertical-switch .form-check-input {
    transform: rotate(-90deg);
    transform-origin: center;
    margin: 0;
    /* kill BS default vertical margin */
    /* optional: slightly smaller */
    scale: 0.9;
    margin: 0 !important;
    margin-left: -6px !important;
}

.vertical-switch .form-check-label {
    line-height: 1;
    width: 15px;
}
.met-toggle {
    display: inline-flex;
    align-items: center;
}

.met-toggle__wrap {
    display: flex;
    align-items: center;
    gap: .4rem;
    cursor: pointer;
    user-select: none;
    line-height: 1;
}

/* verticalize the Bootstrap switch */
.met-toggle__input {
    transform: rotate(-90deg);
    transform-origin: center;
    margin: 0;
    scale: .9;
}

.met-icon {
    width: 29px;
    /* ensure size parity with other icons */
    height: 29px;
    color: #000;
}
/* .form-switch .form-check-input:checked {
    background-color: #000000 !important;
    border-color: #000000 !important;
} */
.met-icon,
/* the label */
.met-toggle .form-check-input,
/* the input */
.met-toggle .met-icon {
    /* the SVG */
    cursor: pointer;
}
.loop-btn {
    cursor: pointer;
}

.loop-btn svg {
    opacity: .8;
    transition: opacity .15s ease;
}

.loop-btn:hover svg,
.loop-btn:focus svg {
    opacity: 1;
}

.loop-btn .state-dot {
    width: 6px;
    height: 6px;
    border-radius: 30%;
    background: #adb5bd;
}

.loop-btn.active {
    background: #212529;
    color: #fff;
}

.loop-btn.active .state-dot {
    background: #2fca72;
}

.loop-btn:focus-visible {
    outline: 2px solid rgba(13, 110, 253, .8);
    outline-offset: 2px;
}
.ui-icon {
    width: 1em;
    height: 1em;
    display: inline-block;
    vertical-align: -.125em;
    flex-shrink: 0;
}

.icon-28 {
    font-size: 35px;
    line-height: 1;
}
.popup-overlay {
    pointer-events: none !important;
}

.popup-content {
    pointer-events: none !important;
}
.loop-btn.pulsing svg {
    animation: loopIconPulse 0.9s ease-in-out infinite;
}

@keyframes loopIconPulse {

    0%,
    100% {
        transform: scale(1.2);
        opacity: 1;
    }

    50% {
        transform: scale(1.32);
        opacity: 0.6;
    }
}

/* Respect reduced-motion */
@media (prefers-reduced-motion: reduce) {
    .loop-btn.pulsing svg {
        animation: none;
    }
}
/* ===== Dynamics tiles ===== */
/* ===== Dynamics tiles (neutral black/white) ===== */
.dyn-tile {
    --tile-bg: var(--bs-body-bg, #fff);
    --tile-br: rgba(0, 0, 0, 0.28);

    border: 1px solid var(--tile-br);
    border-radius: 12px;
    background: linear-gradient(180deg, var(--tile-bg), transparent);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .15rem;
    text-align: center;
    user-select: none;
    cursor: pointer;
    transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease, background .12s ease, color .12s ease;
    min-height: 72px;
    line-height: 1.05;
    color: #111;
}

.dyn-tile .glyph {
    font-size: 28px;
    line-height: 1;
}

.dyn-tile .caption {
    font-size: .8rem;
    letter-spacing: .02em;
    opacity: .75;
}

/* Hover / focus */
.btn-check+.dyn-tile:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .06), 0 2px 6px rgba(0, 0, 0, .04);
}

.btn-check:focus+.dyn-tile {
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .15);
}

/* Selected: invert */
.btn-check:checked+.dyn-tile {
    border-color: #000;
    background: #000;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .18), 0 2px 6px rgba(0, 0, 0, .12);
}

.btn-check:checked+.dyn-tile .caption {
    opacity: 1;
}

/* Disabled */
.btn-check:disabled+.dyn-tile {
    opacity: .55;
    cursor: not-allowed;
}

/* Mobile sizing tweaks */
@media (min-width: 576px) {
    .dyn-tile {
        min-height: 84px;
    }

    .dyn-tile .glyph {
        font-size: 32px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .dyn-tile {
        transition: none;
    }
}
/* Compact chip used in the control bar */



.dyn-inline-glyph {
    font-size: 35px;
    /* matches offcanvas xs size */
    line-height: 1;
    display: inline-block;
    vertical-align: middle;
    /* slight baseline tweak so it aligns with the label text */
    padding-left: 2px;
    transform: translateY(+3px);
}
.dyn-inline-glyph[data-dyn="none"] {
    transform: translateY(0);
    font-size: 31px;
}

/* Make SVGs not sit on the text baseline and allow a vertical tweak */
.key-icon-wrap {
    line-height: 0;
    display: inline-flex;
    align-items: center;
}

/* Default nudge up a hair; tweak per-use with --icon-nudge-y if needed */
.key-icon {
    display: block;
        overflow: visible;
        transform: translateY(var(--icon-nudge-y, -13px));
        transition: filter .12s ease, transform .12s ease;
}
/* Only bump labels inside the Key offcanvas */
#keySheet .key-label {
    font-size: 1.05rem;
    /* bigger than the old <small> */
    font-weight: 400;
    /* a bit bolder for readability */
    line-height: 1;
    /* keeps height tight with the icon */
    white-space: nowrap;
    /* avoid wrapping on narrow tiles */
}

/* Slightly larger on sm+ where you have 6 columns */
@media (min-width: 576px) {
    #keySheet .key-label {
        font-size: 1.12rem;
    }
}


/* make the flat sign larger and slightly higher */
#keySheet .accidental-flat {
    display: inline-block;
    transform: translateY(-0.08em) scale(1.2);
    margin-left: 0.02em;
    font-weight: 700;
    /* use a music-friendly glyph if available, with safe fallbacks */
    font-family: "Noto Music", "Bravura Text", "Leland Text", "Segoe UI Symbol", "Arial Unicode MS", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
/* smooth transitions on key pills */
#keySheet .btn {
    transition:
            transform .12s ease,
            box-shadow .12s ease,
            border-color .12s ease,
            background-color .12s ease,
            color .12s ease;
}

/* stronger idle border for unselected pills (keep selected as-is) */
#keySheet .border-200 {
    border-color: rgba(0, 0, 0, .28) !important;
}

/* same subtle lift + shadow as dyn-tile on hover */
@media (hover:hover) and (pointer:fine) {
    #keySheet .border-200:hover {
        transform: translateY(-1px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, .06), 0 2px 6px rgba(0, 0, 0, .04);
        border-color: rgba(0, 0, 0, .55) !important;
    }
}

/* keyboard focus gets a gentle lift too */
#keySheet .border-200:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .15);
    border-color: rgba(0, 0, 0, .55) !important;
    outline: none;
}
@media (hover:hover) and (pointer:fine) {
    .btn-check+.dyn-tile:hover {
        transform: translateY(-1px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, .06), 0 2px 6px rgba(0, 0, 0, .04);
        border-color: rgba(0, 0, 0, .55);
    }
}
.btn-check:focus-visible+.dyn-tile {
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .15);
}
#keySheet .btn {
    --bs-btn-focus-shadow-rgb: 0, 0, 0;
    /* no blue */
}
/* stays under the fixed ControlBar, across scrolls */
.score-fixed {
    position: fixed;
    top: calc(var(--bar-h, 120px) + 8px);
    /* ControlBar sets --bar-h */
    left: 0;
    right: 0;
    z-index: 95;
    /* ControlBar uses 100 */
    pointer-events: none;
    /* let clicks pass through by default */
}

/* re-enable clicks only for the badge */
.score-fixed .container-fluid {
    pointer-events: auto;
}
/* Phone: icon+tempo act as one centered block and fill the button */
@media (max-width: 420px) {
    .met-btn {
        align-self: stretch;
        /* match control-bar height */
        display: grid !important;
        place-content: center;
        /* center the block vertically & horizontally */
        place-items: center;
        grid-auto-rows: auto;
        width: 40px;
        /* compact footprint */
        padding: 0 4px !important;
    }

    .met-btn .met-icon {
        /* grow to fill available space above the text, but stay sensible */
        height: clamp(28px, calc(100% - 12px), 28px) !important;
        width: 100% !important;
        transform: none !important;
        /* neutralize inline scale */
        margin: 0 !important;
    }

    .met-btn .tempo-val {
        margin-top: 1px;
        /* tiny gap under icon */
        font-size: clamp(15px, 0.32em + 0.5vh, 11px);
        line-height: 1;
        padding-left: 0 !important;
        /* override inline */
        min-width: 0 !important;
        max-width: none !important;
        text-align: center !important;
    }
}
/* Keep the dynamics button as compact as the neighbors */
.btn-dyn {
    padding-left: 0rem !important;
    /* overrides px-3 */
    padding-right: 0rem !important;
    /* overrides px-3 */
}

/* Reserve just enough room for ∅ / 𝆏 / 𝆑 / "mf" without widening the button */
.dyn-inline-glyph {
    width: 2.2ch;
    /* tighter than 2.8ch */
    min-width: 2.1ch;
    text-align: center;
}
.dyn-inline-glyph[data-dyn="none"] {
    width: 47px;
        /* tighter than 2.8ch */
        min-width: 2.1ch;
}
/* Optional: tiny tuck for loud to equalize visual width */
.key-trigger {
    min-width: 60px;
    /* small bump; adjust to taste */
    justify-content: left;
    /* keeps icon centered within that width */
}

.key-trigger .key-icon-wrap {
    padding-right: .25rem;
}
:root {
    --score-bg: #7e6e32;
    --score-bg-hover: #26484c;
    --score-text: #ffffff;
    --score-accent: #f59e0b;
}

.btn-score {
    background: var(--score-bg) !important;
    color: var(--score-text) !important;
    border: none !important;
}

.btn-score:hover,
.btn-score:active {
    background: var(--score-bg-hover) !important;
    color: var(--score-text) !important;
}

.btn-score:focus-visible {
    outline: 3px solid var(--score-accent);
    outline-offset: 2px;
    box-shadow: none !important;
}

@keyframes scorePulseRing {
    0% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, .6);
    }

    100% {
        box-shadow: 0 0 0 14px rgba(245, 158, 11, 0);
    }
}

.btn-score.is-updated {
    animation: scorePulseRing 900ms ease-out 2;
}

@media (prefers-reduced-motion: reduce) {
    .btn-score.is-updated {
        animation: none;
    }
}
/* Drawer theme for ScoreBadge popover */
.tippy-box[data-theme~='score-drawer'] {
    background: #ffffff;
    /* not transparent */
    color: #0f172a;
    /* slate-900-ish for readability */
    border: 1px solid rgba(2, 6, 23, .06);
    border-top: none;
    /* looks attached to the badge */
    border-radius: 0 0 12px 12px;
    /* rounded bottom only */
    box-shadow: 0 10px 24px rgba(0, 0, 0, .18);
}

.tippy-box[data-theme~='score-drawer'] .tippy-content {
    padding: 12px 14px;
    min-width: 280px;
}

@media (prefers-color-scheme: dark) {
    .tippy-box[data-theme~='score-drawer'] {
        background: #26484c;
        /* deep navy */
        color: #e5e7eb;
        /* gray-200 */
        border-color: rgba(148, 163, 184, .16);
        box-shadow: 0 10px 24px rgba(0, 0, 0, .5);
    }
}
@media (min-width: 768px) {
    .opus-row .card.h-100 {
        display: flex;
        flex-direction: row;
    }

    .opus-row .card.h-100 .card-img-top {
        flex: 0 0 32%;
        max-width: 32%;
        height: 100%;
        object-fit: contain;
        align-self: stretch;
        background: #f8f9fa;
        border-right: 1px solid rgba(0, 0, 0, 0.06);
    }

    .opus-row .card.h-100 .card-body {
        flex: 1 1 auto;
    }
}