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

body {
  background: #18150f;
  color: #ede8db;
  min-height: 100vh;
}

main {
  max-width: 520px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

h1 {
  font-family: "Boogaloo", "Impact", sans-serif;
  font-size: clamp(3rem, 10vw, 5rem);
  display: inline-block;
  transform: rotate(-1.5deg);
  border-bottom: 3px solid #d4824a;
  padding-bottom: 6px;
  margin-bottom: 1.5rem;
  color: #ede8db;
  line-height: 1;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.filter-btn {
  font-family: "Space Mono", monospace;
  font-size: 0.85rem;
  text-transform: uppercase;
  padding: 0.5rem 0.9rem 0.45rem;
  background: transparent;
  color: #ede8db;
  border: 2px solid #ede8db;
  border-radius: 0;
  cursor: pointer;
}

.filter-btn.active {
  background: #8b1a1a;
  color: #ede8db;
  border-color: #ede8db;
}

.trick-card {
  background-color: #201c14;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  outline: 2px solid #ede8db;
  outline-offset: -1px;
  box-shadow: 4px 5px 0 0 #8b1a1a;
  transform: rotate(0.5deg);
  padding: 2rem 1.5rem;
  margin-bottom: 2rem;
  text-align: left;
}

#trick-display {
  font-family: "Boogaloo", "Impact", sans-serif;
  font-size: clamp(3rem, 11vw, 5rem);
  color: #ede8db;
  line-height: 1.0;
  margin-bottom: 0.75rem;
  text-align: left;
}

.default-prompt {
  font-family: "Space Mono", monospace;
  font-size: 1.2rem;
  color: #ede8db;
  opacity: 0.4;
  text-transform: none;
}

#trick-difficulty {
  font-family: "Space Mono", monospace;
  font-size: 0.75rem;
  color: #8b1a1a;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  min-height: 1.2em;
}

#gimme {
  font-family: "Boogaloo", "Impact", sans-serif;
  font-size: clamp(2rem, 6vw, 2.5rem);
  width: 100%;
  background: #d4824a;
  color: #18150f;
  border: 1px solid #d4824a;
  border-radius: 0;
  cursor: pointer;
  padding: 1rem 2rem;
}

#gimme.pressed {
  transform: translate(2px, 3px);
  background: #b86835;
}

.history-label {
  font-family: "Space Mono", monospace;
  font-size: 0.7rem;
  color: #d4824a;
  text-transform: lowercase;
  display: none;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

#trick-history {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.history-slot {
  font-family: "Space Mono", monospace;
  padding-left: 0.6rem;
}

.history-slot:nth-child(1) {
  border-left: 3px solid #d4824a;
  font-size: 0.9rem;
  opacity: 1;
}

.history-slot:nth-child(2) {
  border-left: 2px solid #ede8db;
  font-size: 0.85rem;
  opacity: 0.7;
}

.history-slot:nth-child(3) {
  border-left: 2px solid #ede8db;
  font-size: 0.8rem;
  opacity: 0.45;
}

.history-slot.empty-slot {
  border-left: none;
  opacity: 0;
}

.history-name {
  color: #ede8db;
  text-transform: uppercase;
}

.history-difficulty {
  color: #8b1a1a;
}

@keyframes roll {
  from { transform: translateY(8px) rotate(-0.5deg); opacity: 0; }
  to { transform: translateY(0) rotate(0); opacity: 1; }
}

.roll {
  animation: roll 0.15s steps(2, end);
}
