/* fluffy drums — web instrument */
@font-face { font-family: 'fd hand'; src: url('hand.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'fd skinny'; src: url('hand-skinny.ttf') format('truetype'); font-display: swap; }


.fd {
  --ink: #1b1b1b; --text: #232323; --paper: #f6f0e2; --lit: #4fc9f0;
  position: relative; color: var(--text); text-transform: none;
  background: #b7d8ee url(img/sky.jpg) center / cover no-repeat;
  border-radius: 22px; padding: clamp(12px, 1.6vw, 18px);
  box-shadow: inset 0 0 0 3px rgba(27,27,27,.85), 0 18px 40px rgba(40,80,120,.12);
  user-select: none; -webkit-user-select: none; touch-action: manipulation;
}
.fd-top { display: grid; grid-template-columns: minmax(210px, 250px) 1fr; gap: clamp(14px, 2vw, 22px); align-items: stretch; }
.fd-side { display: flex; flex-direction: column; gap: 10px; }
.fd-title { width: 100%; max-width: 185px; height: auto; margin: -4px auto 0; pointer-events: none; }

/* the presets card: the plugin's paper panel, "Factory ⌄" chooser and list */
.fd-presets { position: relative; border: 16px solid transparent; border-image: url(img/ui_presets.png) 40 fill / 16px stretch; margin: 0 -2px; }
.fd-presets-head { display: flex; align-items: center; justify-content: space-between; margin: -6px -2px 4px; padding-bottom: 4px; border-bottom: 1.5px solid rgba(27,27,27,.25); }
.fd-bank { font: 400 34px/1.1 'fd hand', var(--thin); color: var(--text); margin: 0; padding: 0 4px; display: inline-flex; align-items: center; gap: 8px; text-transform: none; }
.fd-bank img { width: 15px; height: auto; margin-top: 6px; transition: transform .2s; }
.fd-bank[aria-expanded="true"] img { transform: rotate(180deg); }
.fd-bankmenu { position: absolute; top: 34px; left: -10px; z-index: 5; min-width: 170px; border: 16px solid transparent; border-image: url(img/ui_menu.png) 44 fill / 16px stretch; filter: drop-shadow(0 8px 14px rgba(0,0,0,.12)); }
.fd-bankmenu[hidden] { display: none; }
.fd-bankmenu button { display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 18px; font: 400 25px/1.3 'fd skinny', var(--thin); color: var(--text); background: none; border: 0; padding: 2px 6px; border-radius: 6px; cursor: pointer; text-transform: none; }
.fd-bankmenu button:hover { background: rgba(79,201,240,.18); }
.fd-bankmenu img { width: 12px; height: auto; }
.fd-bankmenu .soon { color: rgba(35,35,35,.4); cursor: default; }
.fd-bankmenu .soon:hover { background: none; }
#fd-list { list-style: none; margin: 0; padding: 0; }
#fd-list button { display: block; width: 100%; text-align: left; font: 400 20px/1.25 'fd skinny', var(--thin); letter-spacing: .02em; text-transform: uppercase; color: var(--text); background: none; border: 0; border-radius: 6px; padding: 2px 8px; cursor: pointer; }
#fd-list button:hover { background: rgba(79,201,240,.13); }
#fd-list button.on { background: rgba(79,201,240,.28); }
#fd-list button:focus-visible { outline: 2px solid rgba(27,27,27,.5); outline-offset: -2px; }

/* the kit */
/* the kit fills whatever room the side column leaves it: as tall as the column, never wider than its space */
.fd-kitwrap { position: relative; container-type: size; min-height: 0; }
#fd-kit { display: block; position: absolute; top: 0; left: 50%; transform: translateX(-50%); height: min(100cqh, 100cqw * 962 / 1147); width: auto; aspect-ratio: 1147 / 962; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
/* "play me!" scrawled in the top-right corner of the kit */
.fd-callout { position: absolute; top: -8px; right: 0; z-index: 2; margin: 0; text-align: right; pointer-events: none;
  font: 400 clamp(30px, 3.1vw, 45px)/1.02 'fd skinny', var(--thin); color: var(--text); text-transform: none; }
#fd-status { position: absolute; left: 0; right: 0; bottom: 6px; text-align: center; font: 400 22px/1.2 'fd skinny', var(--thin); color: rgba(35,35,35,.7); pointer-events: none; }

/* transport: mode buttons, play, tempo, volume */
/* transport sits under the presets card: two stacked loop buttons, one big play button, then tempo + volume — all the card's width */
.fd-transport { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 -2px; }
.fd-loops { display: grid; grid-template-rows: 1fr 1fr; gap: 8px; }
.fd-loops .fd-btn { width: 100%; justify-content: center; text-align: center; }
.fd-big { width: 100%; height: 100%; flex-direction: column; justify-content: center; gap: 4px; font-size: 23px; padding: 4px 8px 6px; }
.fd-sliders { display: grid; gap: 4px; margin: 2px 0 0; }
.fd-btn { font: 400 21px/1 'fd skinny', var(--thin); color: var(--text); text-transform: lowercase; cursor: pointer; background: none;
  border: 10px solid transparent; border-image: url(img/ui_button.png) 16 fill / 10px stretch; padding: 1px 8px 3px; min-height: 42px;
  display: inline-flex; align-items: center; gap: 8px; transition: transform .12s; position: relative; }
.fd-btn::after { content: ""; position: absolute; inset: -6px; border-radius: 9px; background: transparent; transition: background .15s; pointer-events: none; }
.fd-btn:hover::after { background: rgba(79,201,240,.12); }
.fd-btn.on::after { background: rgba(79,201,240,.32); }
.fd-btn:active { transform: translateY(1px); }
.fd-btn:focus-visible { outline: 2px solid rgba(27,27,27,.5); outline-offset: 6px; }
#fd-play[hidden], #fd-tempo[hidden] { display: none; }
#fd-play .ico { width: 34px; height: 39px; position: relative; display: inline-block; }
#fd-play .ico img { position: absolute; inset: 0; width: 100%; height: 100%; }
#fd-play.playing .ico { width: 30px; height: 30px; margin: 4px 0; }
#fd-play.playing .ico img { display: none; }
#fd-play.playing .ico::before { content: ""; position: absolute; inset: 1px; border: 3px solid var(--ink); border-radius: 5px; background: #eba3af; }
.fd-slider { display: flex; align-items: center; gap: 8px; font: 400 20px/1 'fd skinny', var(--thin); text-transform: lowercase; }
.fd-slider input { -webkit-appearance: none; appearance: none; --thumb: 24px; width: 140px; height: 26px; padding: 0; margin: 0; border: 0; border-radius: 0; outline: none; cursor: pointer;
  /* the plugin's hand-drawn zoom line, its end ticks lined up with where the knob's centre can reach */
  background: url(img/slider_line.png) center / calc(100% - var(--thumb)) auto no-repeat; }
.fd-slider input::-webkit-slider-runnable-track { height: 26px; background: transparent; border: 0; }
.fd-slider input::-moz-range-track { height: 26px; background: transparent; border: 0; }
.fd-slider input::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: var(--thumb); height: var(--thumb); margin-top: 1px; border: 0; border-radius: 50%; background: url(img/slider_knob.png) center / contain no-repeat; cursor: grab; transition: transform .12s; }
.fd-slider input::-moz-range-thumb { width: var(--thumb); height: var(--thumb); border: 0; border-radius: 50%; background: url(img/slider_knob.png) center / contain no-repeat; cursor: grab; }
.fd-slider input:hover::-webkit-slider-thumb { transform: scale(1.1); }
.fd-slider input:active::-webkit-slider-thumb { cursor: grabbing; }
.fd-slider input:focus-visible { outline: 2px solid rgba(27,27,27,.4); outline-offset: 2px; border-radius: 6px; }
.fd-slider .val { min-width: 1.6em; text-align: right; }
.fd-slider input { flex: 1 1 auto; min-width: 80px; }
.fd-slider > input:last-child { margin-right: calc(1.6em + 10px); }

/* which key plays what (desktop only) */
.fd-keys { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px 9px; margin-top: 10px; font: 400 17px/1 'fd skinny', var(--thin); text-transform: lowercase; transition: opacity .2s; }
.fd-key { display: inline-flex; align-items: center; gap: 6px; }
.fd-key kbd { font: 400 18px/1 'fd hand', var(--thin); text-transform: uppercase; min-width: 26px; height: 26px; display: inline-flex; align-items: center; justify-content: center;
  background: var(--paper); border: 2px solid var(--ink); border-radius: 7px; box-shadow: 0 2px 0 var(--ink); }
.fd-key.hit kbd { animation: fd-key .25s ease-out; }
@keyframes fd-key { 0% { background: var(--lit); transform: translateY(2px); box-shadow: 0 0 0 var(--ink); } 100% { background: var(--paper); transform: none; } }
.fd-hint { text-align: center; margin-top: 5px; font: 400 16px/1.3 'fd skinny', var(--thin); color: rgba(35,35,35,.75); text-transform: lowercase; }
.fd-midi { color: var(--text); }
/* keeps its line even while empty, so a midi device showing up never shifts what sits below the kit */
.fd-midi { min-height: 1.3em; }
.fd-midi[hidden] { display: block; visibility: hidden; }
.fd-midi::before { content: ''; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--lit); border: 1.5px solid var(--ink); margin: 0 7px 0 0; vertical-align: 1px; }
@media (hover: none) and (pointer: coarse) { .fd-keys, .fd-hint.keys-only { display: none; } }

@media (max-width: 760px) {
  .fd { margin-top: 10px; }
  .fd-about .fd { margin-top: 20px; }
  .fd-top { grid-template-columns: 1fr; }
  .fd-kitwrap { container-type: normal; }
  #fd-kit { position: static; transform: none; height: auto; width: 100%; }
  .fd-side { display: grid; grid-template-columns: 1fr 1.25fr; align-items: center; gap: 10px; }
  .fd-title { max-width: 200px; margin: 0; }
  .fd-presets { border-width: 14px; border-image-width: 14px; }
  .fd-sliders { grid-column: 1 / -1; }
  .fd-presets-body { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; align-items: start; }
  .fd-presets-body .fd-transport { grid-template-columns: 1fr; gap: 6px; margin: 0; }
  .fd-presets-body .fd-loops { grid-template-rows: auto auto; gap: 6px; }
  .fd-presets-body .fd-big { height: auto; flex-direction: row; gap: 8px; }
  .fd-presets-body #fd-play .ico { width: 24px; height: 28px; }
  .fd-presets-body #fd-play.playing .ico { width: 24px; height: 24px; margin: 0; }
  .fd-callout { position: static; text-align: center; margin: 8px 0 2px; font-size: 32px; }
  .fd-big { font-size: 23px; }
  .fd-bank { font-size: 32px; }
  #fd-list button { font-size: 19px; padding: 3px 8px; }
  .fd-btn { font-size: 21px; min-height: 42px; border-width: 10px; border-image-width: 10px; padding: 0 6px 3px; }
}
@media (max-width: 420px) { .fd-side { grid-template-columns: 1fr; } .fd-title { margin: 0 auto; max-width: 150px; } }

/* ---------- about / features (between the playable kit and the buy button) ---------- */
.fd-about { margin-top: 28px; }
.fd-about .fd { margin-top: 28px; }
.fd-ledebar { display: grid; grid-template-columns: minmax(0, 62%) 1fr; align-items: stretch; gap: 32px; }
.fd-uiwrap { position: relative; }
.fd-ui { width: 100%; height: auto; display: block; border: 2px solid var(--bg); background: var(--bg); border-radius: 14px; }
/* the price star, pinned over the screenshot's top-right corner */
.fd-price { position: absolute; top: -10%; right: -4%; width: 24%; aspect-ratio: 632 / 700; display: grid; place-items: center; transform: rotate(-17deg); filter: drop-shadow(0 6px 10px rgba(0,0,0,.18)); pointer-events: none; }
.fd-price img { position: absolute; inset: 0; width: 100%; height: 100%; }
.fd-price span { position: relative; font: 400 clamp(34px, 5.3vw, 66px)/1 var(--thin); color: var(--text); transform: rotate(17deg) translate(-7%, -6%); }
.fd-ledetext { display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 18px; min-height: 0; }
.fd-store.fd-store-top a.gumroad-button { font-size: 24px !important; padding: 14px 40px !important; box-shadow: 5px 5px 0 #111 !important; }
.fd-lede { font: 400 clamp(22px, 2.3vw, 28px)/1.28 var(--thin); margin: 0; text-align: left; }
.fd-store.fd-store-top { margin: 0; flex: none; align-items: flex-end; gap: 22px; }
.fd-demo-link { display: flex; flex-direction: column; align-items: center; gap: 4px; font: 400 clamp(30px, 3vw, 40px)/1 var(--thin); color: var(--text); white-space: nowrap; text-transform: uppercase; transition: color .15s; }
.fd-demo-link .arrows { display: flex; gap: 10px; align-items: flex-end; }
.fd-demo-link .arrows img { height: 1.1em; width: auto; }
.fd-demo-link:hover { color: var(--muted); }
.fd-features { margin-top: 28px; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; grid-auto-flow: dense; }
.fd-feat.col1 { grid-column: 1; } .fd-feat.col2 { grid-column: 2; }
.fd-feat { border: 2px solid var(--text); border-radius: 14px; padding: 24px 26px 26px; background: #fff; }
.fd-feat.wide { grid-column: 1 / -1; }
.fd-feat h3 { font: 400 56px/1.05 var(--fat); margin: 0 0 10px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.fd-feat p, .fd-feat li { font: 400 25px/1.4 var(--thin); color: var(--text); }
.fd-feat p { margin: 0; }
.fd-feat p + p { margin-top: 10px; }
.fd-feat p + .fd-cols { margin-top: 12px; }
.fd-note { font-size: 21px !important; line-height: 1.4 !important; color: var(--muted) !important; }
.fd-feat ul { list-style: none; margin: 0; padding: 0; }
.fd-feat li { padding: 8px 0 8px 26px; position: relative; background: url(../img/rule-light.png) bottom left / 100% 5px no-repeat; }
.fd-feat li:last-child { background: none; }
.fd-feat li::before { content: ""; position: absolute; left: 2px; top: 19px; width: 11px; height: 11px; border-radius: 50%; background: #4fc9f0; border: 1.5px solid var(--text); }
.fd-feat b { font-weight: 400; background: rgba(79,201,240,.28); padding: 0 6px 1px; border-radius: 5px; margin-right: 4px; }
.fd-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 36px; }
.fd-feat.free { background: #fff0fb; border-color: var(--text); }
.fd-tag { font: 400 17px/1 var(--thin); text-transform: uppercase; letter-spacing: .08em; background: #ff90e8; border: 2px solid var(--text); border-radius: 999px; padding: 6px 11px 7px; }
/* screenshots, when you add them: <img class="fd-shot" ...> inside a card */
.fd-shot { display: block; width: 100%; height: auto; border-radius: 10px; border: 2px solid var(--text); margin: 4px 0 16px; }
.fd-stack { display: flex; flex-direction: column; gap: 20px; }
.fd-stack .fd-specs-card { flex: 1; }
.fd-store { margin-top: 48px; }
@media (max-width: 760px) {
  .fd-about { margin-top: 20px; } .fd-features { margin-top: 20px; }
  .fd-ledebar { grid-template-columns: 1fr; gap: 18px; }
  .fd-price { width: 28%; top: -8%; right: -2%; }
  .fd-price span { font-size: clamp(34px, 11vw, 50px); }
  .fd-ledetext { gap: 16px; }
  .fd-features, .fd-cols { grid-template-columns: 1fr; }
  .fd-feat.col1, .fd-feat.col2 { grid-column: auto; }
  .fd-cols { gap: 0; }
  .fd-cols ul:first-child li:last-child { background: url(../img/rule-light.png) bottom left / 100% 5px no-repeat; }
  .fd-feat { padding: 20px 20px 22px; }
  .fd-feat h3 { font-size: 44px; }
  .fd-feat p, .fd-feat li { font-size: 22px; }
  .fd-note { font-size: 19px !important; }
}

/* pictures beside the feature titles */
.fd-feat h3 .fd-ico { height: 1.9em; width: auto; margin-left: auto; }
.fd-sticks { display: flex; align-items: center; gap: 6px; margin-left: auto; flex: 1 1 auto; justify-content: flex-end; min-width: 0; }
.fd-sticks img { width: 15%; max-width: 120px; min-width: 0; height: auto; }
.fd-busblock { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: center; }
.fd-bus { width: 100%; height: auto; display: block; border: 2px solid var(--bg); background: var(--bg); border-radius: 14px; }
@media (max-width: 760px) {
  .fd-sticks { flex-basis: 100%; justify-content: center; margin-left: 0; }
  .fd-sticks img { width: 16%; }
  .fd-busblock { grid-template-columns: 1fr; }
  .fd-bus { max-width: 300px; margin: 0 auto; }
}
.fd-icos { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.fd-icos .fd-ico { margin-left: 0; }
@media (max-width: 900px) and (min-width: 761px) { .fd-lede { font-size: 19px; } .fd-store.fd-store-top a.gumroad-button { font-size: 21px !important; padding: 12px 30px !important; } }
