@charset "utf-8";

body {
  font-family: 'Segoe UI', sans-serif;
  background:#f8f8f8;
  margin:0;
  padding:2rem;
  color:#333;
}
nav {
  text-align: center;
  margin-bottom: 20px;
}
nav a {
  display: inline-block;
  margin: 0 6px;
  padding: 6px 12px;
  background: #eee;
  border-radius: 6px;
  text-decoration: none;
  color: #333;
  transition: .3s;
}
nav a:hover { background: #333; color: #fff; }
h1 {
  text-align:center;
  margin-bottom:2rem;
}
.grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(300px,1fr));
  gap:1.5rem;
}
.card {
  background:#fff;
  border-radius:12px;
  padding:1rem;
  box-shadow:0 2px 8px rgba(0,0,0,0.08);
  transition:0.3s;
}
.card:hover {
  transform:translateY(-3px);
}
.preview {
  display:flex;
  justify-content:center;
  align-items:center;
  height:90px;
  border:1px solid #ddd;
  border-radius:8px;
  margin-bottom:1rem;
  background:#fafafa;
}
.tabs {
  display:flex;
  gap:6px;
  margin-bottom:0.5rem;
}
.tabs button {
  flex:1;
  border:none;
  background:#ddd;
  padding:4px;
  border-radius:4px;
  cursor:pointer;
}
.tabs button.active {
  background:#0078ff;
  color:white;
}
pre {
  background:#111;
  color:#0f0;
  padding:0.5rem;
  border-radius:6px;
  font-size:0.8rem;
  overflow-x:auto;
  min-height:60px;
}
button.copy {
  display:inline-block;
  margin-top:6px;
  background:#0078ff;
  color:#fff;
  border:none;
  border-radius:4px;
  padding:6px 10px;
  cursor:pointer;
}
button.copy:active {
  transform:scale(0.96);
}