:root {
    --glass-bg: rgba(255, 255, 255, 0.5); --glass-border: rgba(255, 255, 255, 0.6);
    --text-heading: #18181b; --text-body: #4b5563;
    --btn-primary-bg: #18181b; --btn-primary-text: #ffffff;
    --btn-secondary-bg: rgba(255, 255, 255, 0.7); --btn-secondary-hover: rgba(255, 255, 255, 1); --btn-secondary-text: #18181b;
    --input-bg: rgba(255, 255, 255, 0.5); --placeholder: #6b7280; --dropdown-bg: rgba(255, 255, 255, 0.95);
}

body.dark-mode {
    --glass-bg: rgba(30, 30, 35, 0.5); --glass-border: rgba(255, 255, 255, 0.1);
    --text-heading: #f8fafc; --text-body: #cbd5e1;
    --btn-primary-bg: #f8fafc; --btn-primary-text: #0f172a;
    --btn-secondary-bg: rgba(255, 255, 255, 0.1); --btn-secondary-hover: rgba(255, 255, 255, 0.2); --btn-secondary-text: #f8fafc;
    --input-bg: rgba(0, 0, 0, 0.3); --placeholder: #94a3b8; --dropdown-bg: rgba(25, 25, 30, 0.95);
}

body.theme-keycoach { --bg-1: #a7f3d0; --bg-2: #10b981; --blob-1: rgba(167, 243, 208, 0.8); --blob-2: rgba(52, 211, 153, 0.6); }
body.theme-keycoach.dark-mode { --bg-1: #064e3b; --bg-2: #022c22; --blob-1: rgba(16, 185, 129, 0.2); --blob-2: rgba(5, 150, 105, 0.2); }
body.theme-coffee { --bg-1: #e8d5c4; --bg-2: #d1b399; --blob-1: rgba(255, 255, 255, 0.6); --blob-2: rgba(212, 184, 156, 0.8); }
body.theme-coffee.dark-mode { --bg-1: #38291f; --bg-2: #1f150f; --blob-1: rgba(168, 123, 81, 0.15); --blob-2: rgba(122, 85, 51, 0.15); }
body.theme-burgundy { --bg-1: #f1cdd7; --bg-2: #d48a9e; --blob-1: rgba(255, 230, 238, 0.7); --blob-2: rgba(255, 204, 218, 0.7); }
body.theme-burgundy.dark-mode { --bg-1: #3b1422; --bg-2: #1f0810; --blob-1: rgba(190, 24, 93, 0.2); --blob-2: rgba(159, 18, 57, 0.2); }
body.theme-slate { --bg-1: #e2e8f0; --bg-2: #cbd5e1; --blob-1: rgba(255, 255, 255, 0.8); --blob-2: rgba(241, 245, 249, 0.8); }
body.theme-slate.dark-mode { --bg-1: #2a303c; --bg-2: #171a21; --blob-1: rgba(148, 163, 184, 0.1); --blob-2: rgba(100, 116, 139, 0.1); }
body.theme-blue { --bg-1: #a1c4fd; --bg-2: #c2e9fb; --blob-1: rgba(255, 154, 158, 0.7); --blob-2: rgba(254, 207, 239, 0.7); }
body.theme-blue.dark-mode { --bg-1: #1a2c4c; --bg-2: #0d172a; --blob-1: rgba(59, 130, 246, 0.2); --blob-2: rgba(37, 99, 235, 0.2); }
body.theme-purple { --bg-1: #e0c3fc; --bg-2: #8ec5fc; --blob-1: rgba(250, 208, 196, 0.8); --blob-2: rgba(255, 209, 255, 0.8); }
body.theme-purple.dark-mode { --bg-1: #2a1c3d; --bg-2: #160d24; --blob-1: rgba(167, 139, 250, 0.2); --blob-2: rgba(139, 92, 246, 0.2); }
body.theme-orange { --bg-1: #f6d365; --bg-2: #fda085; --blob-1: rgba(255, 238, 238, 0.8); --blob-2: rgba(255, 154, 158, 0.5); }
body.theme-orange.dark-mode { --bg-1: #422012; --bg-2: #261007; --blob-1: rgba(251, 146, 60, 0.2); --blob-2: rgba(249, 115, 22, 0.2); }
body.theme-teal { --bg-1: #84fab0; --bg-2: #8fd3f4; --blob-1: rgba(168, 237, 234, 0.7); --blob-2: rgba(254, 214, 227, 0.7); }
body.theme-teal.dark-mode { --bg-1: #163a35; --bg-2: #0a221e; --blob-1: rgba(45, 212, 191, 0.2); --blob-2: rgba(20, 184, 166, 0.2); }
body.theme-indigo { --bg-1: #667eea; --bg-2: #764ba2; --blob-1: rgba(224, 195, 252, 0.5); --blob-2: rgba(142, 197, 252, 0.5); }
body.theme-indigo.dark-mode { --bg-1: #23204a; --bg-2: #111029; --blob-1: rgba(99, 102, 241, 0.2); --blob-2: rgba(79, 70, 229, 0.2); }
body.theme-pink { --bg-1: #ff9a9e; --bg-2: #fecfef; --blob-1: rgba(161, 196, 253, 0.8); --blob-2: rgba(194, 233, 251, 0.8); }
body.theme-pink.dark-mode { --bg-1: #3b1c28; --bg-2: #2a121d; --blob-1: rgba(200, 80, 120, 0.2); --blob-2: rgba(150, 50, 90, 0.2); }

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', system-ui, sans-serif; transition: background 0.4s ease, color 0.4s ease, border-color 0.4s ease; }

html { overflow-x: hidden; scroll-behavior: smooth; }
body { overflow-x: hidden; width: 100%; position: relative; background: linear-gradient(-45deg, var(--bg-1), var(--bg-2), var(--bg-1)); background-size: 400% 400%; min-height: 100vh; color: var(--text-body); animation: gradientShift 15s ease infinite; }

body::before, body::after { 
    content: ''; position: fixed; border-radius: 50%; filter: blur(70px); 
    z-index: -1; transition: background 0.8s ease; 
    pointer-events: none; will-change: transform; transform: translateZ(0); 
}
body::before { width: 450px; height: 450px; background: var(--blob-1); top: 5%; left: 10%; animation: float1 18s ease-in-out infinite alternate; }
body::after { width: 550px; height: 550px; background: var(--blob-2); bottom: 5%; right: 10%; animation: float2 22s ease-in-out infinite alternate; }

@keyframes gradientShift { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes float1 { 0% { transform: translate3d(0, 0, 0) scale(1); } 50% { transform: translate3d(50px, -30px, 0) scale(1.1); } 100% { transform: translate3d(-30px, 40px, 0) scale(0.95); } }
@keyframes float2 { 0% { transform: translate3d(0, 0, 0) scale(1); } 50% { transform: translate3d(-40px, 50px, 0) scale(1.05); } 100% { transform: translate3d(30px, -20px, 0) scale(0.9); } }

.container { max-width: 1200px; margin: 0 auto; padding: 2rem; position: relative; }

.glass-panel { 
    background: var(--glass-bg); 
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); 
    border: 1px solid var(--glass-border); border-radius: 24px; 
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.08); 
    transform: translateZ(0); 
}

h1, h2, h3, h4, h5, h6 { color: var(--text-heading); margin-bottom: 1rem; line-height: 1.2; }
a { color: inherit; text-decoration: none; }
p { margin-bottom: 1rem; line-height: 1.6; }

/* Menus */
.wp-menu-list, .footer-menu-list { list-style: none; display: flex; gap: 1.5rem; }
.wp-menu-list a, .footer-menu-list a { font-weight: 500; font-size: 1rem; padding: 0.5rem; transition: opacity 0.2s; }
.wp-menu-list a:hover, .footer-menu-list a:hover { opacity: 0.7; }
.footer-menu-list { flex-wrap: wrap; justify-content: center; margin: 0; padding: 0; }

nav.main-nav { display: flex; justify-content: space-between; align-items: center; padding: 1rem 2rem; margin-bottom: 2rem; position: relative; z-index: 100; }
.logo { font-weight: 800; font-size: 1.5rem; letter-spacing: -0.5px; z-index: 101; cursor: pointer;}
.hamburger-btn { display: none; background: none; border: none; font-size: 1.8rem; color: var(--text-heading); cursor: pointer; z-index: 101; padding: 0.5rem; }
.nav-controls { display: flex; align-items: center; gap: 0.5rem; }

.dropdown-wrapper { position: relative; }
.dropdown-menu { position: absolute; top: calc(100% + 10px); right: 0; background: var(--dropdown-bg); padding: 0.5rem; border-radius: 16px; list-style: none; min-width: 180px; opacity: 0; visibility: hidden; transform: translateY(-10px); transition: all 0.2s ease; z-index: 200; border: 1px solid var(--glass-border); box-shadow: 0 10px 40px rgba(0,0,0,0.15); pointer-events: none; }
.dropdown-menu.active { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }
.dropdown-menu li { padding: 0.6rem 1rem; cursor: pointer; border-radius: 8px; font-weight: 500; font-size: 0.95rem; display: flex; align-items: center; gap: 0.5rem; transition: 0.1s; }
.dropdown-menu li:hover { background: var(--glass-border); }
.dropdown-menu li.selected { background: var(--glass-border); font-weight: 700; color: var(--text-heading); }

.icon-btn { background: var(--btn-secondary-bg); color: var(--btn-secondary-text); border: 1px solid var(--glass-border); width: 42px; height: 42px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; transition: 0.2s; white-space: nowrap; }
.icon-btn:hover { background: var(--btn-secondary-hover); transform: translateY(-2px); }
.btn-primary { background: var(--btn-primary-bg); color: var(--btn-primary-text); padding: 0.8rem 2.5rem; border-radius: 50px; font-weight: 600; border: none; transition: 0.2s; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.btn-primary:hover { opacity: 0.85; transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
.btn-secondary { background: var(--btn-secondary-bg); color: var(--btn-secondary-text); padding: 0.8rem 2.5rem; border-radius: 50px; font-weight: 600; border: 1px solid var(--glass-border); transition: 0.2s; display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem; cursor:pointer;}
.btn-secondary:hover { background: var(--btn-secondary-hover); transform: translateY(-2px); }

.fade-up { opacity: 0; transform: translateY(30px); transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); will-change: opacity, transform; }
.fade-up.appear { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }

#spa-root { transition: opacity 0.2s ease; }
#spa-root.loading { opacity: 0.4; pointer-events: none; }

.hero-split { display: flex; align-items: center; gap: 3rem; padding: 2rem 3rem; margin-bottom: 2rem; position: relative; z-index: 10; }
.hero-text { flex: 1; text-align: left; }
.hero-text h1 { font-size: clamp(2rem, 3.5vw, 3.5rem); margin-bottom: 0.8rem; letter-spacing: -1px; }
.hero-buttons { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 1rem;}
.hero-visual { flex: 1.2; display: flex; align-items: center; justify-content: center; height: 280px; background: var(--input-bg); border: 2px dashed var(--glass-border); border-radius: 16px; overflow: hidden; }

/* === KEYCOACH PRO — HERO DEMO EMBED ===
   The demo box itself keeps the theme's original 280px height and flex:1.2
   side-by-side footprint next to .hero-text — now via .kc-demo-column, a
   wrapper that stacks the MIDI status alert directly above the box.
   #keycoach-wrapper is rendered at its natural "studio" design width inside
   .kc-demo-scale-inner and scaled down with a JS-computed transform (see
   assets/js/kc-demo-scale.js) using a "contain" fit — shrinking on whichever
   dimension (width or height) is tightest — so the full plugin UI always
   fits inside that original box without being cropped. */
.kc-demo-column {
    flex: 1.2;      /* the original side-by-side proportion with .hero-text */
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    min-width: 0;   /* prevents the 1000px-wide unscaled plugin content from
                       forcing this flex item wider than its 1.2 share —
                       the exact cause of the box getting stretched out */
}
.hero-visual.kc-demo-stage {
    position: relative;
    flex: none;
    width: 100%;
    align-items: center;
    justify-content: center;
    height: 280px;      /* original placeholder height, unchanged */
    min-height: 280px;
    max-height: 280px;
    padding: 0;
    border-style: solid;
    background: #1a1a1a;
}
.kc-demo-stage .kc-demo-scale-inner {
    width: 1000px;   /* KeyCoach Pro's natural "desktop" layout width */
    max-width: none;
    flex-shrink: 0;
    transform-origin: center center;
    transition: transform 0.15s ease-out;
    /* Demo-only preview: no mouse/touch/keyboard interaction with the
       embedded plugin UI. `inert` (set in front-page.php) is the primary
       guard; pointer-events is a CSS-only fallback for browsers/contexts
       where the attribute might not apply. */
    pointer-events: none;
    user-select: none;
}
/* FIX — "black notes before the actual color": the theme's own global
   `* { transition: background 0.4s ease, ... }` reset (see top of this
   file) applies to every element on the page, including the plugin's own
   piano key divs. That means pressing a key visibly fades its background
   from the resting black/white key color to the configured --active-color
   over 0.4s, instead of switching instantly like it does on other themes
   that don't add a global transition reset. This scoped override cancels
   the transition on just the key elements — the plugin's CSS never defines
   one for them itself, so this restores its real, immediate behavior
   without touching a single plugin file. */
#keycoach-wrapper .kc-key-white,
#keycoach-wrapper .kc-key-black {
    transition: none;
}
/* Neutralize the plugin's own centered spacing so it sits flush inside the stage */
.kc-demo-stage #keycoach-wrapper {
    margin: 0;
    max-width: none;
    border-radius: 0;
}
/* Defensive fallback: if the plugin's own internal fullscreen toggle is
   reachable (mouse/touch are blocked via inert, but its own keyboard
   shortcut isn't touched — see note above), a transform on
   .kc-demo-scale-inner would turn it into the containing block for
   #keycoach-wrapper's `position: fixed`, trapping "fullscreen" inside the
   demo box instead of covering the real viewport. kc-demo-scale.js toggles
   this class to bypass that the moment fullscreen activates. */
.kc-demo-stage.kc-fs-bypass {
    overflow: visible;
    height: auto !important;
    max-height: none !important;
    min-height: 0;
    background: transparent;
    border: none;
}
.kc-demo-stage.kc-fs-bypass .kc-demo-scale-inner {
    transform: none !important;
    width: auto;
    pointer-events: auto;
}

/* Overlay "open full interface" link — the only interactive element allowed
   inside the demo box. Set its text/link in Customizer → Hero Section. */
.kc-demo-fs-btn {
    position: absolute;
    right: 14px;
    bottom: 14px;
    z-index: 5;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 1rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    color: var(--text-heading);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.25);
    transition: 0.2s ease;
}
.kc-demo-fs-btn:hover {
    background: var(--btn-primary-bg);
    color: var(--btn-primary-text);
    border-color: transparent;
    transform: translateY(-2px);
}
.kc-demo-fs-icon { font-size: 1.05rem; line-height: 1; }
.flex-row { display: flex; gap: 2rem; margin-bottom: 2rem; }
.flex-col { flex: 1; padding: 2.5rem; }
.feature-list { list-style-position: inside; line-height: 2.2; font-size: 1.1rem; }

/* === FORCE VISIBLE CATEGORY FILTER === */
.category-filter { 
    display: flex; flex-wrap: wrap; gap: 0.8rem; justify-content: center; margin-bottom: 3rem; 
    position: relative; z-index: 20; 
}
.cat-pill { padding: 0.6rem 1.4rem; border-radius: 50px; background: var(--glass-bg); border: 1px solid var(--glass-border); color: var(--text-heading); font-size: 0.95rem; font-weight: 600; text-decoration: none; backdrop-filter: blur(10px); transition: 0.2s ease; box-shadow: 0 4px 15px rgba(0,0,0,0.05); }
.cat-pill:hover, .cat-pill.active { background: var(--btn-primary-bg); color: var(--btn-primary-text); border-color: transparent; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.1); }

/* === STRICT EXPERT GRID ENFORCEMENT === */
.posts-grid { display: grid; gap: 1.5rem; margin-bottom: 3rem; width: 100%; align-items: stretch; }
.posts-grid[data-columns="1"] { grid-template-columns: minmax(0, 1fr); }
.posts-grid[data-columns="2"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.posts-grid[data-columns="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.posts-grid[data-columns="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.grid-card { display: flex; flex-direction: column; height: 100%; padding: 0 !important; overflow: hidden; background: var(--dropdown-bg); transition: transform 0.2s ease, box-shadow 0.2s ease; }
.grid-card:hover { transform: translateY(-4px); box-shadow: 0 10px 30px rgba(0,0,0,0.08); }
.grid-card-img { width: 100%; height: 160px; background-size: cover; background-position: center; display: block; }
.grid-card-content { padding: 1.2rem; display: flex; flex-direction: column; flex: 1; }
.grid-card-content h2 { font-size: 1.25rem; line-height: 1.3; margin-bottom: 0.5rem; }
.grid-card-content .meta { font-size: 0.8rem; opacity: 0.7; margin-bottom: 0.8rem; }
.grid-card-content .excerpt { 
    font-size: 0.95rem; line-height: 1.5; margin-bottom: 1rem; 
    flex: 1; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.grid-card-content .excerpt p { margin: 0; }
.grid-card-content .btn-secondary { padding: 0.5rem 1rem; font-size: 0.9rem; margin-top: auto; }

/* === MINIMALIST PAGINATION === */
.pagination { text-align: center; margin-top: 2rem; }
.pagination h2 { display: none; }
.pagination .nav-links { display: inline-flex; gap: 0.5rem; justify-content: center; align-items: center; flex-wrap: wrap;}
.pagination .page-numbers { padding: 0.6rem 1rem; border-radius: 12px; background: var(--btn-secondary-bg); border: 1px solid var(--glass-border); color: var(--text-heading); font-weight: 600; text-decoration: none; transition: 0.2s; box-shadow: 0 4px 10px rgba(0,0,0,0.05); min-width: 45px; text-align: center;}
.pagination .page-numbers:hover { background: var(--btn-secondary-hover); transform: translateY(-2px); }
.pagination .page-numbers.current { background: var(--btn-primary-bg); color: var(--btn-primary-text); border-color: transparent; }
.pagination .page-numbers.dots { background: transparent; border: none; box-shadow: none; padding: 0; min-width: auto; }

/* === ASTRA-STYLE SINGLE PAGES === */
.page-wrapper { padding: 1.5rem 0; margin-bottom: 2rem; }
.Astra-style { padding: 3rem 0; width: 100%; overflow: hidden;}
.content-inner { max-width: 800px; margin: 0 auto; padding: 0 2rem; }
.single-header { text-align: center; margin-bottom: 2.5rem; }
.single-header h1 { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.2; margin-bottom: 1rem; letter-spacing: -0.5px; }

.single-hero-img { width: 100%; height: 400px; background-size: cover; background-position: center; border-radius: 16px; margin: 0 auto 2.5rem auto; max-width: 1000px; }

.entry-content { font-size: 1.15rem; line-height: 1.8; color: var(--text-body); overflow-wrap: break-word; word-wrap: break-word; }
.entry-content h2, .entry-content h3 { margin-top: 2.5rem; margin-bottom: 1rem; }
/* Aggressive content responsiveness */
.entry-content img, .entry-content iframe, .entry-content video { max-width: 100%; height: auto; border-radius: 12px; margin: 1.5rem 0; display: block; }
.entry-content table, .entry-content pre { max-width: 100%; overflow-x: auto; display: block; margin: 1.5rem 0; }
.entry-content p { margin-bottom: 1.5rem; }

.share-section { margin-top: 4rem; padding-top: 2rem; border-top: 1px solid var(--glass-border); text-align: center; }
.share-buttons { display: flex; gap: 1rem; justify-content: center; margin-top: 1rem; }

/* === NEW TEMPLATE ENHANCEMENTS === */
.video-enhanced iframe, .video-enhanced video { width: 100% !important; aspect-ratio: 16/9; border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.15); margin: 2rem 0; background: var(--input-bg); }
.audio-enhanced audio { width: 100% !important; border-radius: 50px; box-shadow: 0 4px 15px rgba(0,0,0,0.1); margin: 2rem 0; background: var(--glass-bg); }

/* Responsive Strict Enforcement */
@media(max-width: 960px) {
    .hero-split { flex-direction: column; text-align: center; padding: 2rem 1.5rem; }
    .hero-text { text-align: center; }
    .hero-buttons { justify-content: center; }
    .flex-row { flex-direction: column; }
    
    .posts-grid[data-columns="3"], .posts-grid[data-columns="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    
    .hamburger-btn { display: block; }
    .nav-controls {
        display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column;
        background: var(--dropdown-bg); backdrop-filter: blur(20px); padding: 1.5rem;
        border-radius: 16px; border: 1px solid var(--glass-border); box-shadow: 0 10px 40px rgba(0,0,0,0.15);
        animation: slideDown 0.3s ease forwards;
    }
    .nav-controls.active { display: flex; }
    .wp-menu-list { flex-direction: column; width: 100%; text-align: left; }
    .icon-btn { width: 100%; border-radius: 12px; justify-content: flex-start; padding: 0.8rem 1.2rem; gap: 0.8rem; font-size: 1rem; }
    #themeDropdownBtn::after { content: "Choose Theme"; font-weight: 500;}
    #darkBtn::after { content: "Toggle Mode"; font-weight: 500;}
    
    .dropdown-menu { position: static; transform: none; box-shadow: none; width: 100%; display: none; }
    .dropdown-menu.active { display: block; opacity: 1; visibility: visible; }
    @keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(10px); } }
}

@media(max-width: 650px) {
    /* Absolute override for mobile */
    .posts-grid { grid-template-columns: minmax(0, 1fr) !important; }
    
    /* Better spacing on tiny screens */
    .Astra-style { padding: 1.5rem 0; }
    .content-inner { padding: 0 1.2rem; }
    .single-hero-img { height: 250px; border-radius: 0; }
}

.floating-note { position: fixed; pointer-events: none; font-size: 1.8rem; color: var(--text-heading); font-weight: bold; z-index: 9999; transform: translate(-50%, -50%); text-shadow: 0 4px 15px rgba(0,0,0,0.15); animation: floatNoteBurst var(--duration) ease-out forwards; will-change: transform, opacity; }
@keyframes floatNoteBurst {
    0% { opacity: 1; transform: translate(-50%, -50%) scale(0.4) rotate(0deg); }
    20% { opacity: 1; }
    100% { opacity: 0; transform: translate(calc(-50% + var(--drift-x)), calc(-50% + var(--float-y))) scale(var(--end-scale)) rotate(var(--rot)); }
}

/* === KEYCOACH PRO — MIDI STATUS ALERT ===
   Sits directly above the demo box (see .kc-demo-column in front-page.php).
   Mirrors the plugin's own #kc-midi-status text via kc-midi-alert.js — it
   never re-implements MIDI detection, just reflects what the plugin already
   determined, so it's always accurate and hot-swap aware. */
.kc-midi-alert {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.9rem;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: var(--text-heading);
}
.kc-midi-alert-icon { font-size: 1rem; line-height: 1; flex-shrink: 0; }

.kc-midi-alert.kc-midi-none {
    border-color: rgba(214, 54, 56, 0.4);
    background: rgba(214, 54, 56, 0.08);
    color: #d63638;
}
.kc-midi-alert.kc-midi-none .kc-midi-alert-icon {
    animation: kc-midi-blink 1s step-start infinite;
}
@media (prefers-reduced-motion: reduce) {
    .kc-midi-alert.kc-midi-none .kc-midi-alert-icon { animation: none; }
}
@keyframes kc-midi-blink { 50% { opacity: 0; } }

.kc-midi-alert.kc-midi-connected {
    border-color: rgba(76, 175, 80, 0.4);
    background: rgba(76, 175, 80, 0.08);
    color: #4caf50;
}
