nav { font-family: monospace; font-size: 0.85em; padding: 12px 20px; }
nav a { color: inherit; text-decoration: none; }
nav a:hover { text-decoration: underline; }

body { margin: 0; font-family: monospace; background: #f8f8f8; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 24px;
  padding: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.label {
  font-size: 0.75em;
  color: #aaa;
}

/* Base button reset */
button {
  font-family: monospace;
  font-size: 0.9em;
  cursor: pointer;
  padding: 10px 20px;
  border: none;
  background: none;
  width: 100%;
}

/* 01 · Fill slide */
.btn-fill {
  border: 1px solid #222;
  color: #222;
  background: linear-gradient(to right, #222 50%, transparent 50%);
  background-size: 200% 100%;
  background-position: right;
  transition: background-position 0.3s ease, color 0.3s ease;
}
.btn-fill:hover {
  background-position: left;
  color: #fff;
}

/* 02 · Underline grow */
.btn-underline {
  border: 1px solid #ddd;
  color: #222;
  position: relative;
  overflow: hidden;
}
.btn-underline::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #222;
  transition: width 0.3s ease, left 0.3s ease;
}
.btn-underline:hover::after {
  width: 100%;
  left: 0;
}

/* 03 · Scale + shadow */
.btn-scale {
  border: 1px solid #222;
  color: #222;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-scale:hover {
  transform: scale(1.04);
  box-shadow: 4px 4px 0 #222;
}

/* 04 · Invert */
.btn-invert {
  background: #222;
  color: #fff;
  transition: background 0.2s ease, color 0.2s ease;
}
.btn-invert:hover {
  background: #fff;
  color: #222;
  outline: 1px solid #222;
}

/* 05 · Offset border */
.btn-offset {
  border: 1px solid #222;
  color: #222;
  position: relative;
  transition: transform 0.15s ease;
}
.btn-offset::before {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px solid #aaa;
  transform: translate(4px, 4px);
  transition: transform 0.15s ease;
  pointer-events: none;
}
.btn-offset:hover {
  transform: translate(2px, 2px);
}
.btn-offset:hover::before {
  transform: translate(2px, 2px);
}

/* 06 · Ripple */
.btn-ripple {
  border: 1px solid #222;
  color: #222;
  position: relative;
  overflow: hidden;
}
.ripple-circle {
  position: absolute;
  border-radius: 50%;
  background: rgba(0,0,0,0.12);
  transform: scale(0);
  animation: ripple-anim 0.5s linear;
  pointer-events: none;
}
@keyframes ripple-anim {
  to { transform: scale(4); opacity: 0; }
}
