:root {
  color-scheme: light;
  --ink: #172634;
  --muted: #59666d;
  --blue: #1971a8;
  --cream: #f3e5bf;
  --orange: #e66b39;
  --yellow: #f7c95c;
  --teal: #2b7f83;
}

* { box-sizing: border-box; }
body {
  min-height: 100vh;
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: "Segoe UI", Arial, sans-serif;
}
button, input, textarea { font: inherit; }
a { color: inherit; }

.site-shell {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: calc(100vh - 86px);
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin: 0 auto;
  padding: 16px 24px;
}

.landing-header { text-align: center; transform: translateY(-10px); }
.site-logo {
  display: inline-flex;
  width: clamp(240px, 18vw, 300px);
  height: 100px;
  margin: 0 0 9px;
  border-radius: 13px;
  transition: transform 150ms ease, opacity 150ms ease;
}
.site-logo:hover { opacity: .9; transform: translateY(-1px); }
.site-logo:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
.site-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.landing-header h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.85rem, calc(3vw - 2pt), 2.75rem);
  letter-spacing: -.025em;
  line-height: 1;
}

.instrument-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: minmax(360px, min(60vh, 520px));
  width: 82vw;
  max-width: 1600px;
  align-items: end;
  justify-content: center;
  column-gap: clamp(24px, 2vw, 42px);
  margin-top: 4px;
}
.instrument-card {
  --lift-distance: 38px;
  --shadow-width: clamp(74px, 8vw, 126px);
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 6px;
  background: #fff;
  text-decoration: none;
}
a.instrument-card:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.instrument-card::after {
  position: absolute;
  z-index: 0;
  width: var(--shadow-width);
  height: 18px;
  bottom: 1px;
  left: 50%;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(23, 38, 52, .42) 0%, rgba(23, 38, 52, .25) 46%, rgba(23, 38, 52, 0) 76%);
  content: "";
  filter: blur(3px);
  opacity: .9;
  transform: translateX(-50%) scaleX(1) scaleY(1);
  transform-origin: center;
  transition: filter 220ms ease, opacity 220ms ease, transform 220ms ease;
}
.instrument-card:nth-child(2) { --shadow-width: clamp(86px, 9.5vw, 150px); }
.instrument-card:nth-child(3) { --shadow-width: clamp(62px, 6vw, 96px); }
.instrument-card:nth-child(4) { --shadow-width: clamp(62px, 6.5vw, 105px); }
.instrument-card:nth-child(5) { --shadow-width: clamp(76px, 8.1vw, 132px); }
.instrument-card:nth-child(6) { --shadow-width: clamp(78px, 8.5vw, 138px); }
.instrument-card img {
  position: absolute;
  z-index: 1;
  display: block;
  width: 94%;
  height: 98%;
  top: auto;
  bottom: -10px;
  left: 50%;
  object-fit: contain;
  object-position: center bottom;
  transform: translateX(-50%);
  transform-origin: center bottom;
  transition: transform 220ms cubic-bezier(.2, .72, .26, 1);
}
.instrument-card:nth-child(5) img {
  width: 86%;
  height: 88%;
}
.instrument-card:hover img,
.instrument-card:focus-visible img {
  transform: translateX(-50%) translateY(calc(-1 * var(--lift-distance)));
}
.instrument-card:hover::after,
.instrument-card:focus-visible::after {
  filter: blur(7px);
  opacity: .46;
  transform: translateX(-50%) scaleX(1.22) scaleY(.7);
}
.tres-card {
  --tres-center-offset: 0px;
}
.tres-card::before {
  position: absolute;
  z-index: 0;
  width: 100%;
  top: 8%;
  bottom: 2%;
  left: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 160 240'%3E%3Cpath fill='%231167a8' d='M0 0h32v240H0zm64 0h32v240H64zm64 0h32v240h-32z'/%3E%3Cpath fill='%23cf202f' d='M0 0h160L80 139Z'/%3E%3Cpath fill='white' d='m80 31 9 18 20 3-15 14 4 20-18-10-18 10 4-20-15-14 20-3Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  content: "";
  opacity: .13;
  transform: translate(-50%, -10px) scale(.9);
  transform-origin: center;
}
.tres-card { overflow: visible; }
.tres-card img {
  width: 94%;
  height: 98%;
  left: calc(50% + var(--tres-center-offset));
}
.tres-card::after { left: calc(50% + var(--tres-center-offset)); }
.unavailable { cursor: default; }

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  width: min(1440px, calc(100% - 48px));
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 0 auto;
  border-top: 2px solid rgba(23,38,52,.18);
  color: var(--muted);
  font-size: .82rem;
  font-weight: 650;
}
.site-footer p { margin: 0; }
.site-footer nav { display: flex; align-items: center; justify-self: end; gap: 20px; }
.site-version { color: var(--ink-soft); font-size: .86rem; font-weight: 800; letter-spacing: .02em; }
.site-footer a { font-weight: 800; }
.site-footer button {
  min-height: 38px;
  padding: 5px 16px;
  border: 2px solid var(--blue);
  border-radius: 999px;
  background: transparent;
  color: var(--blue);
  font-weight: 850;
  cursor: pointer;
}
.site-footer button:hover,
.site-footer button:focus-visible { background: var(--blue); color: #fff; }

.feedback-dialog {
  width: min(92vw, 520px);
  padding: 0;
  border: 0;
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(23,38,52,.3);
}
.feedback-dialog::backdrop { background: rgba(23,38,52,.58); }
.feedback-form { display: grid; gap: 11px; padding: 25px; }
.feedback-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.feedback-heading h2 { margin: 0; font-size: 1.65rem; }
.feedback-close { border: 0; background: transparent; font-size: 1.8rem; cursor: pointer; }
.feedback-form > p { margin: 0 0 5px; color: var(--muted); }
.feedback-form label { font-size: .82rem; font-weight: 850; }
.feedback-form label span { color: var(--muted); font-weight: 600; }
.feedback-form input,
.feedback-form textarea { width: 100%; border: 1px solid #9babb4; border-radius: 8px; padding: 10px 11px; }
.feedback-form textarea { min-height: 130px; resize: vertical; }
.feedback-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 4px; }
.feedback-actions button { min-width: 100px; padding: 9px 14px; border: 1px solid #9babb4; border-radius: 8px; background: #fff; cursor: pointer; }
.feedback-actions .feedback-submit { border-color: var(--blue); background: var(--blue); color: #fff; font-weight: 800; }
.feedback-status { min-height: 1.25em; font-size: .82rem; }
.feedback-status.success { color: #216941; }
.feedback-status.error { color: #a32e25; }
.feedback-trap { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; }

@media (max-width: 1080px) {
  .site-shell { padding-inline: 12px; }
  .instrument-grid {
    grid-template-columns: repeat(3, minmax(190px, 1fr));
    grid-template-rows: repeat(2, min(29vh, 270px));
    width: min(100%, 820px);
    gap: 20px 14px;
  }
  .instrument-card { --lift-distance: 28px; }
}
@media (max-width: 620px) {
  .site-shell { min-height: calc(100vh - 174px); padding: 10px 6px; }
  .instrument-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(2, min(30vh, 230px));
    width: 100%;
  }
  .instrument-card img { width: 94%; height: 98%; }
  .instrument-card { --lift-distance: 20px; }
  .site-footer { grid-template-columns: 1fr; justify-items: center; gap: 12px; padding: 16px 0; text-align: center; }
  .site-footer nav { justify-self: center; }
}
@media (prefers-reduced-motion: reduce) {
  .instrument-card img,
  .instrument-card::after { transition: none; }
  .instrument-card:hover img,
  .instrument-card:focus-visible img { transform: translateX(-50%); }
  .instrument-card:hover::after,
  .instrument-card:focus-visible::after { filter: blur(3px); opacity: .9; transform: translateX(-50%); }
}
