
:root {
  --bg:       #000000;
  --surface:  #131211;
  --surface2: #1c1b1a;
  --border:   #2a2927;
  --accent:   #6e1225;
  --accent-d: rgba(255,7,58,0.12);
  --text:     #D0C9C3;
  --heading:  #F2EAE3;
  --muted:    #6b6560;
  --easy:     #3d8c5c;
  --medium:   #8c7a35;
  --hard:     #c0392b;
}

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

html { 
  scroll-behavior: smooth; 
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Vazirmatn', sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

/* Sticky footer: whichever view is showing (home/guitar/category/theory),
   #site-footer-mount is always the last flex item in body's column.
   margin-top:auto pushes it — and only it — to the bottom of the
   viewport when content is shorter than the screen, and lets it flow
   normally right after content when content is taller. This needs no
   changes to any individual page container, so it can't disturb their
   internal centering/grid layout. */
#site-footer-mount {
  margin-top: auto;
}

/* ════════════════════════════════════════════════
   HEADER
════════════════════════════════════════════════ */
.site-header {
  position: sticky; top: 0; z-index: 200;
  background: rgba(0,0,0,0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
}

.logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  letter-spacing: 3px;
  color: var(--accent);
  cursor: pointer;
  color: var(--muted);
  user-select: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.logo .dot { color: var(--accent); }

/* Static search bar */
.search-static {
  flex-grow: 1;
  max-width: 480px;
  margin: 0 16px;
  position: relative;
}
.search-static-input {
  width: 100%;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 36px 8px 14px;
  color: var(--heading);
  font-family: 'Vazirmatn', sans-serif;
  font-size: 13px;
  outline: none;
  transition: border-color 0.18s;
  direction: inherit;
}
html[dir="ltr"] .search-static-input { padding: 8px 14px 8px 36px; }
.search-static-input::placeholder { color: var(--muted); }
.search-static-input:focus { border-color: var(--accent); }
.search-static-icon {
  position: absolute;
  right: 12px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 13px; pointer-events: none;
}
html[dir="ltr"] .search-static-icon { right: auto; left: 12px; }

/* Right actions */
.hd-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.icon-btn {
  width: 34px; height: 34px;
  background: none; border: none;
  color: var(--muted); font-size: 14px;
  border-radius: 5px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: color 0.18s, background 0.18s;
  flex-shrink: 0;
}
.icon-btn:hover { color: var(--heading); background: var(--surface2); }

.lang-btn {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--muted);
  font-family: 'Vazirmatn', sans-serif;
  font-size: 11px; font-weight: 600;
  letter-spacing: 1px; text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 5px;
  cursor: pointer;
  transition: border-color 0.18s, color 0.18s;
  white-space: nowrap;
}
.lang-btn:hover { border-color: var(--accent); color: var(--heading); }

.avatar-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface2);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 14px;
  transition: border-color 0.18s, color 0.18s, background 0.18s;
  flex-shrink: 0;
}
.avatar-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-d); }

/* ════════════════════════════════════════════════
   MAIN BODY
════════════════════════════════════════════════ */
.main-body {
  padding: 36px 32px 48px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.body-label {
  font-size: 12px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
  font-weight: 600;
}

.section-heading {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px;
  letter-spacing: 2px;
  color: var(--heading);
  margin-bottom: 6px;
}
.section-sub {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 20px;
  line-height: 1.5;
}
.section-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 1px 0 36px;
}

.hero-logo-heading {
  margin: 0;
  display: contents;
}

/* 2-col desktop, 1-col mobile */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

/* Category card */
.cat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  min-height: 200px;
  position: relative;
}
.cat-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}
.cat-card:hover .cat-arrow { color: var(--accent); }

.cat-notation {
  background: #F2EAE3;
  height: 130px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; flex-shrink: 0;
  position: relative;
}
.cat-notation svg { width: 88%; max-height: 110px; }

.cat-stripe {
  height: 3px;
  background: var(--accent);
  flex-shrink: 0;
}

.cat-body {
  padding: 16px 18px 18px;
  flex: 1;
  display: flex; flex-direction: column;
}
.cat-title {
  font-size: 16px; font-weight: 700;
  color: var(--heading);
  margin-bottom: 6px;
  line-height: 1.3;
}
.cat-desc {
  font-size: 12px; color: var(--muted);
  line-height: 1.6; flex: 1;
  margin-bottom: 12px;
}
.cat-footer {
  display: flex; align-items: center; justify-content: space-between;
}
.cat-count {
  font-size: 11px; color: var(--muted);
  font-weight: 500;
}
.cat-arrow {
  font-size: 12px; color: var(--muted);
  transition: color 0.2s;
}

/* ════════════════════════════════════════════════
   SEARCH RESULTS
════════════════════════════════════════════════ */
#search-results { display: none; }
#search-results.visible { display: block; }
.search-label {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 18px; letter-spacing: 2px;
  color: var(--muted);
  margin-bottom: 20px;
}
.search-label span { color: var(--heading); }
.practice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}
.no-results { color: var(--muted); font-size: 14px; padding: 12px 0; }

/* Small practice cards */
.p-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.18s, transform 0.18s;
  display: flex; flex-direction: column;
}
.p-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.p-card-notation {
  background: #F2EAE3;
  height: 90px;
  display: flex; align-items: center; justify-content: center;
}
.p-card-notation svg { width: 88%; max-height: 80px; }
.p-card-stripe { height: 2px; background: var(--accent); }
.p-card-body { padding: 11px 13px 13px; flex: 1; display: flex; flex-direction: column; }
.p-card-title { font-size: 14px; font-weight: 600; color: var(--heading); margin-bottom: 3px; }
.p-card-sub { font-size: 12px; color: var(--muted); flex: 1; margin-bottom: 8px; line-height: 1.4; }
.diff-badge {
  font-size: 9px; font-weight: 700; letter-spacing: 0.5px;
  text-transform: uppercase; padding: 2px 7px; border-radius: 20px;
}
.diff-badge.easy   { background: rgba(61,140,92,0.15);  color: var(--easy); }
.diff-badge.medium { background: rgba(140,122,53,0.15); color: var(--medium); }
.diff-badge.hard   { background: rgba(192,57,43,0.12);  color: var(--hard); }
.p-card-mins { font-size: 10px; color: var(--muted); }

/* ════════════════════════════════════════════════
   GUITAR CATEGORY CHOOSER  (opens full-page from the
   hero "Guitar Practice" card — mirrors cat-page)
════════════════════════════════════════════════ */
#guitar-page { display: none; }
#guitar-page.visible { display: block; }

/* ════════════════════════════════════════════════
   CATEGORY DETAIL PAGE
════════════════════════════════════════════════ */
#cat-page { display: none; }
#cat-page.visible { display: block; }

/* ════════════════════════════════════════════════
   THEORY CATEGORY DETAIL PAGE (Notes / Rhythms)
════════════════════════════════════════════════ */
/* ════════════════════════════════════════════════
   THEORY CONTENT VIEWER PAGE
════════════════════════════════════════════════ */
#theory-view-page { display: none; }
#theory-view-page.visible { display: block; }

.theory-view-content {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}
.theory-view-media {
  width: 100%;
  max-width: 900px;
  border: none;
  border-radius: 8px;
  background: var(--surface2);
}
video.theory-view-media { display: block; }
.theory-view-pdf { height: 70vh; }
.cat-page-header {
  padding: 32px 32px 0;
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 24px;
}
.cat-back {
  background: none; border: 1px solid var(--border);
  color: var(--muted); font-size: 12px;
  padding: 7px 14px; border-radius: 5px; cursor: pointer;
  font-family: 'Vazirmatn', sans-serif;
  transition: border-color 0.18s, color 0.18s;
  white-space: nowrap;
  display: flex; align-items: center; gap: 6px;
}
.cat-back:hover { border-color: var(--accent); color: var(--heading); }
.cat-page-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px; letter-spacing: 2px; color: var(--heading);
}
.cat-page-body {
  padding: 0 32px 64px;
  max-width: 1200px; margin: 0 auto;
}

/* ════════════════════════════════════════════════
   THEORY PAGE (sub-page route)
════════════════════════════════════════════════ */
.sub-page { display: none; }
.sub-page.visible { display: block; }
.sub-page-inner {
  padding: 40px 32px 64px;
  max-width: 1200px; margin: 0 auto;
}
.page-back-row {
  display: flex; align-items: center; gap: 14px; margin-bottom: 28px;
}
.page-heading {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 30px; letter-spacing: 2px; color: var(--heading);
  margin-bottom: 6px;
}
.page-sub { font-size: 13px; color: var(--muted); margin-bottom: 28px; }
.theory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.theory-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 8px; overflow: hidden; cursor: pointer;
  transition: border-color 0.18s, transform 0.18s;
}
.theory-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.theory-notation { background: #F2EAE3; height: 100px; display: flex; align-items: center; justify-content: center; }
.theory-notation svg { width: 88%; max-height: 88px; }
.theory-body { padding: 13px 15px 15px; }
.theory-title { font-weight: 700; font-size: 13px; color: var(--heading); margin-bottom: 4px; }
.theory-desc { font-size: 11px; color: var(--muted); line-height: 1.5; }
.theory-link { color: var(--accent); text-decoration: none; font-weight: 600; }

/* ════════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════ */
.site-footer {
  margin-top: auto;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 40px 32px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 40px;
  align-items: start;
}
.footer-brand .logo {
  font-size: 22px;
  display: block;
  margin-bottom: 10px;
}
.footer-tagline {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
  max-width: 220px;
}
.footer-about-heading {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 16px;
  letter-spacing: 2px;
  color: var(--heading);
  margin-bottom: 12px;
}
.footer-about-text {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
}
.footer-about-text p { margin-bottom: 10px; }
.footer-about-text p:last-child { margin-bottom: 0; }
.footer-bottom {
  max-width: 1200px;
  margin: 28px auto 0;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 11px;
  color: var(--muted);
  text-align: center;
}

/* ════════════════════════════════════════════════
   LOGIN MODAL
════════════════════════════════════════════════ */
.modal-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,0.82);
  align-items: center; justify-content: center;
  padding: 20px;
  overflow-y: auto;
}
.modal-overlay.open {
  display: flex;
}
.modal-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 40px 36px 36px;
  width: 100%; max-width: 380px;
  position: relative;
  flex-shrink: 0;
  margin: auto;
}
.modal-close {
  position: absolute; top: 14px;
  left: 14px;
  background: none; border: none;
  color: var(--muted); cursor: pointer; font-size: 16px;
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 4px; transition: color 0.18s, background 0.18s;
}
html[dir="ltr"] .modal-close { left: auto; right: 14px; }
.modal-close:hover { color: var(--heading); background: var(--surface2); }
.modal-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px; letter-spacing: 3px;
  text-align: center; margin-bottom: 4px; color: var(--heading);
}
.modal-logo .dot { color: var(--accent); }
.modal-tagline { text-align: center; color: var(--muted); font-size: 12px; margin-bottom: 28px; }
.login-tabs {
  display: flex; background: var(--surface2); border-radius: 6px;
  padding: 3px; margin-bottom: 22px; gap: 3px;
}
.login-tab {
  flex: 1; padding: 8px; border-radius: 4px;
  border: none; background: none;
  color: var(--muted); font-family: 'Vazirmatn', sans-serif;
  font-size: 13px; font-weight: 500; cursor: pointer;
  transition: all 0.18s;
}
.login-tab.active { background: var(--bg); color: var(--heading); }
.form-group { margin-bottom: 14px; }
.form-label {
  display: block; font-size: 10px; font-weight: 600;
  letter-spacing: 0.5px; text-transform: uppercase;
  color: var(--muted); margin-bottom: 5px;
}
.form-input {
  width: 100%;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 6px; padding: 10px 12px;
  color: var(--heading); font-family: 'Vazirmatn', sans-serif;
  font-size: 13px; outline: none;
  transition: border-color 0.18s;
  direction: inherit; #phoneInput { direction: ltr; text-align: left; }
}
.form-input::placeholder { color: var(--muted); }
.form-input:focus { border-color: var(--accent); }

/* Phone input wrapper with flag */
.phone-input-wrap {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.phone-prefix {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 10px;
  color: var(--muted);
  font-family: 'Vazirmatn', sans-serif;
  font-size: 13px;
  white-space: nowrap;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 5px;
}
.phone-prefix-flag { font-size: 15px; }
.phone-input-wrap .form-input { flex: 1; }
.forgot-row { text-align: left; margin-top: -8px; margin-bottom: 14px; font-size: 11px; }
html[dir="rtl"] .forgot-row { text-align: right; }
.forgot-link { color: var(--muted); text-decoration: none; transition: color 0.18s; }
.forgot-link:hover { color: var(--accent); }
.form-submit {
  width: 100%; padding: 12px;
  background: var(--accent); border: none; border-radius: 6px;
  color: #fff; font-family: 'Vazirmatn', sans-serif;
  font-size: 14px; font-weight: 600; cursor: pointer;
  transition: opacity 0.18s, transform 0.1s;
  margin-top: 4px;
}
.form-submit:hover { opacity: 0.9; }
.form-submit:active { transform: scale(0.99); }
#register-fields { display: none; }
#register-fields.show { display: block; }

/* ════════════════════════════════════════════════
   HERO SECTION
════════════════════════════════════════════════ */
.hero {
  border-bottom: 1px solid var(--border);
  padding: 48px 32px 40px;
  text-align: center;
  background: linear-gradient(180deg, rgba(255,7,58,0.04) 0%, transparent 100%);
}
.hero-logo-img {
  display: block;
  width: min(88%, 460px);
  max-width: 100%;
  height: auto;
  margin: 0 auto 18px;
  /* img/gushkharash-logo.png has a real alpha channel (the flat black
     backdrop was cut to true transparency), so it composites cleanly
     against --bg with no blend-mode trick needed. */
}
.hero-sub {
  font-size: 15px; color: var(--muted);
  max-width: 480px; margin: 0 auto 36px;
  line-height: 1.7;
}
.hero-cards {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  max-width: 700px;
  margin: 0 auto;
}
.hero-card {
  flex: 1; min-width: 220px; max-width: 320px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px 24px 24px;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s, background 0.2s;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  text-align: center;
}
.hero-card:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  background: var(--surface2);
}
.hero-card-icon {
  width: 52px; height: 52px;
  background: var(--accent-d);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 22px;
  flex-shrink: 0;
}
.hero-card-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px; letter-spacing: 2px;
  color: var(--heading);
}
.hero-card-desc {
  font-size: 14px; color: var(--muted); line-height: 1.6;
}
.hero-card-cta {
  margin-top: auto;
  font-size: 13px; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; color: var(--accent);
  display: flex; align-items: center; gap: 5px;
}
html[dir="ltr"] .hero-card-cta i { transform: none; }
html[dir="rtl"] .hero-card-cta i { transform: scaleX(-1); }

/* ════════════════════════════════════════════════
   SHOP TEASER CARD
   (links out to shop.html — page not built yet.
   Same look/colors as .hero-card, but a single
   full-width banner instead of a flex item.)
════════════════════════════════════════════════ */
.shop-section {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px 22px 48px;
  
}
.shop-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px 24px 24px;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s, background 0.2s;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  text-align: center;
}
.shop-card:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  background: var(--surface2);
}
.shop-card-icon {
  width: 52px; height: 52px;
  background: var(--accent-d);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 22px;
  flex-shrink: 0;
}
.shop-card-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px; letter-spacing: 2px;
  color: var(--heading);
}
.shop-card-desc {
  font-size: 14px; color: var(--muted); line-height: 1.6;
  max-width: 480px;
}
.shop-card-cta {
  font-size: 13px; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; color: var(--accent);
  display: flex; align-items: center; gap: 5px;
}
html[dir="ltr"] .shop-card-cta i { transform: none; }
html[dir="rtl"] .shop-card-cta i { transform: scaleX(-1); }

/* ════════════════════════════════════════════════
   METRONOME CARD
   Same background/border/icon/title/desc look as the
   shop card above it, but this one isn't a navigation
   link — it's a self-contained play/pause + tempo
   control, so it has no cursor:pointer/hover-lift on
   the card itself (only its individual controls do).
════════════════════════════════════════════════ */
.metronome-section {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px 22px 48px;
}
.metronome-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px 24px 24px;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  text-align: center;
}
.metronome-card-icon {
  width: 52px; height: 52px;
  background: var(--accent-d);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 22px;
  flex-shrink: 0;
}
.metronome-card-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px; letter-spacing: 2px;
  color: var(--heading);
}
.metronome-card-desc {
  font-size: 14px; color: var(--muted); line-height: 1.6;
  max-width: 480px;
}

/* Controls are always laid out left-to-right (like the phone-number
   inputs elsewhere in the app) regardless of site language, since BPM
   numbers/sliders don't have a meaningful RTL reading order. */
.metronome-controls {
  width: 100%;
  max-width: 340px;
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

/* Play / pause */
.metronome-play-btn {
  width: 60px; height: 60px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: var(--accent-d);
  color: var(--accent);
  font-size: 18px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0;
  transition: background 0.15s, transform 0.1s;
}
.metronome-play-btn:hover { background: rgba(255,7,58,0.22); }
.metronome-play-btn:active { transform: scale(0.94); }
.metronome-play-btn.playing { background: var(--accent); color: #fff; }

/* Tempo block */
.metronome-tempo-block {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.metronome-bpm-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.metronome-beat-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.08s, box-shadow 0.08s;
  flex-shrink: 0;
}
.metronome-beat-dot.lit {
  background: var(--accent);
  box-shadow: 0 0 8px 2px rgba(255,7,58,0.55);
}
.metronome-bpm-input {
  width: 70px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 4px;
  color: var(--heading);
  font-family: 'Vazirmatn', sans-serif;
  font-size: 22px; font-weight: 700;
  text-align: center;
  outline: none;
  transition: border-color 0.15s;
  -moz-appearance: textfield;
}
.metronome-bpm-input::-webkit-inner-spin-button,
.metronome-bpm-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.metronome-bpm-input:focus { border-color: var(--accent); }
.metronome-bpm-unit {
  font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
}

.metronome-slider-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
}
.metronome-step {
  width: 30px; height: 30px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 16px; font-weight: 600;
  border-radius: 6px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.15s, color 0.15s;
  flex-shrink: 0;
  line-height: 1;
}
.metronome-step:hover { border-color: var(--accent); color: var(--accent); }

.metronome-slider {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 2px;
  background: var(--surface2);
  outline: none;
  cursor: pointer;
}
.metronome-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: 2px solid var(--heading);
}
.metronome-slider::-moz-range-thumb {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: 2px solid var(--heading);
}
.metronome-slider::-moz-range-track {
  height: 4px;
  border-radius: 2px;
  background: var(--surface2);
}

/* ════════════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .cat-grid { grid-template-columns: 1fr; }
  .main-body { padding: 24px 16px 40px; }
  .site-header { padding: 0 14px; gap: 10px; }
  .search-static { max-width: none; }
  .cat-page-header { padding: 20px 16px 0; }
  .cat-page-body { padding: 0 16px 48px; }
  .sub-page-inner { padding: 24px 16px 48px; }
  .modal-card { padding: 32px 22px 28px; }
  .footer-inner { grid-template-columns: 1fr; gap: 24px; }
  .site-footer { padding: 32px 16px; }
  .shop-section { padding: 32px 40px 40px; }
  .metronome-section { padding: 32px 40px 40px; }
  .metronome-controls { max-width: 300px; }
  .hero { padding: 36px 20px 32px; }
  .hero-logo-img { width: min(100%, 320px); margin-bottom: 14px; }
}