:root {
  --background: #ffffff;
  --foreground: #000000;
  --gray-50: #fafafa;
  --gray-100: #f5f5f5;
  --gray-200: #ebebeb;
  --gray-300: #d4d4d4;
  --gray-400: #999999;
  --gray-500: #777777;
  --gray-600: #555555;
  --gray-800: #1a1a1a;
  --border: rgba(0, 0, 0, 0.08);
  --max-width: 1100px;
  --radius: 8px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #000000;
    --foreground: #ededed;
    --gray-50: #0a0a0a;
    --gray-100: #111111;
    --gray-200: #1a1a1a;
    --gray-300: #2a2a2a;
    --gray-400: #555555;
    --gray-500: #888888;
    --gray-600: #aaaaaa;
    --gray-800: #ededed;
    --border: rgba(255, 255, 255, 0.1);
  }
}

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

html, body {
  background: var(--background);
  color: var(--foreground);
  font-family: "Geist", "Geist Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
code, pre, .mono {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
}
::selection { background: var(--foreground); color: var(--background); }

.container { max-width: var(--max-width); margin: 0 auto; padding: 32px 24px 96px; }

.site-header {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px 24px 0;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 14px;
}
.site-header .brand { font-weight: 600; letter-spacing: -0.01em; }
.site-header nav { color: var(--gray-500); }

.hero {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: 64px; align-items: center;
  padding: 64px 0 80px; border-bottom: 1px solid var(--border);
}
@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; padding: 32px 0 48px; gap: 32px; }
}
.hero h1 { font-size: clamp(40px, 6vw, 72px); font-weight: 600; letter-spacing: -0.045em; line-height: 1.05; margin-bottom: 20px; }
.hero .lead { font-size: 17px; color: var(--gray-600); max-width: 480px; line-height: 1.6; }

.hero-anim { display: flex; justify-content: center; align-items: center; }
.yoyo-svg { width: 100%; max-width: 380px; height: auto; aspect-ratio: 1; color: var(--foreground); }

.tricks-section { padding: 56px 0 0; display: flex; flex-direction: column; gap: 72px; }
.style-group .style-header { margin-bottom: 24px; display: flex; flex-direction: column; gap: 8px; }
.style-group h2 { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; display: flex; align-items: center; gap: 12px; }
.style-group .style-header p { color: var(--gray-600); font-size: 15px; max-width: 720px; line-height: 1.6; }

.tag {
  display: inline-flex; align-items: center; padding: 3px 10px;
  background: var(--gray-100); border: 1px solid var(--border);
  border-radius: 6px; font-family: "Geist Mono", monospace;
  font-size: 12px; font-weight: 500; color: var(--gray-800); letter-spacing: 0.02em;
}

.trick-grid { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.trick-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 18px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--background);
  transition: border-color 0.15s ease, transform 0.15s ease, background 0.15s ease;
}
.trick-card:hover { border-color: var(--gray-400); background: var(--gray-50); transform: translateY(-1px); }
.trick-name { font-size: 15px; font-weight: 500; letter-spacing: -0.005em; }

.level { font-size: 11px; padding: 2px 8px; border-radius: 100px; font-family: "Geist Mono", monospace; letter-spacing: 0.02em; }
.level-1 { background: rgba(34, 197, 94, 0.10); color: #15803d; }
.level-2 { background: rgba(101, 199, 80, 0.10); color: #3f7d20; }
.level-3 { background: rgba(163, 199, 65, 0.12); color: #5e7a14; }
.level-4 { background: rgba(202, 195, 50, 0.12); color: #7a740d; }
.level-5 { background: rgba(234, 179, 8, 0.12); color: #a16207; }
.level-6 { background: rgba(238, 142, 22, 0.12); color: #b45309; }
.level-7 { background: rgba(241, 105, 36, 0.12); color: #c2410c; }
.level-8 { background: rgba(241, 78, 50, 0.10); color: #c43020; }
.level-9 { background: rgba(239, 68, 68, 0.10); color: #b91c1c; }
@media (prefers-color-scheme: dark) {
  .level-1 { background: rgba(34, 197, 94, 0.15); color: #4ade80; }
  .level-2 { background: rgba(101, 199, 80, 0.15); color: #86d96b; }
  .level-3 { background: rgba(163, 199, 65, 0.15); color: #c4d953; }
  .level-4 { background: rgba(202, 195, 50, 0.15); color: #e2dc4a; }
  .level-5 { background: rgba(234, 179, 8, 0.15); color: #facc15; }
  .level-6 { background: rgba(238, 142, 22, 0.15); color: #fbb249; }
  .level-7 { background: rgba(241, 105, 36, 0.15); color: #fb923c; }
  .level-8 { background: rgba(241, 78, 50, 0.15); color: #fb7866; }
  .level-9 { background: rgba(239, 68, 68, 0.15); color: #f87171; }
}

.breadcrumbs { font-size: 14px; color: var(--gray-500); margin-bottom: 24px; }
.breadcrumbs a:hover { color: var(--foreground); }
.breadcrumbs .sep { margin: 0 8px; color: var(--gray-400); }

.trick-article { max-width: 720px; }
.trick-header { padding-bottom: 32px; border-bottom: 1px solid var(--border); margin-bottom: 40px; }
.trick-meta { display: flex; gap: 8px; margin-bottom: 16px; align-items: center; }
.trick-article h1 { font-size: clamp(32px, 5vw, 56px); font-weight: 600; letter-spacing: -0.04em; line-height: 1.1; margin-bottom: 12px; }
.trick-style-desc { color: var(--gray-600); font-size: 16px; line-height: 1.6; }
.trick-article section { margin-bottom: 40px; }
.trick-article h2 { font-size: 18px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 16px; color: var(--foreground); }
.trick-article p { color: var(--gray-600); font-size: 16px; line-height: 1.7; }

.execution-list { padding-left: 0; list-style: none; counter-reset: step; border-top: 1px solid var(--border); }
.execution-list li {
  counter-increment: step;
  padding: 14px 0 14px 48px; position: relative;
  color: var(--gray-800); font-size: 16px; line-height: 1.6;
  border-bottom: 1px solid var(--border);
}
.execution-list li::before {
  content: counter(step);
  position: absolute; left: 0; top: 14px;
  width: 28px; height: 28px;
  border: 1px solid var(--border); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: "Geist Mono", monospace; font-size: 12px;
  color: var(--gray-500); background: var(--background);
}

.element-list { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.element-list li code { padding: 4px 10px; background: var(--gray-100); border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }

.related-grid { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin-top: 8px; }

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 96px;
  padding: 24px;
  max-width: var(--max-width); margin-left: auto; margin-right: auto;
  font-size: 12px; color: var(--gray-500); text-align: center;
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px;
  line-height: 1.7;
}
.site-footer .sep { color: var(--gray-400); }
.site-footer a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.site-footer a:hover { color: var(--foreground); }
.site-footer .visits { color: #2563eb; font-weight: 600; font-variant-numeric: tabular-nums; }

.fire-btn {
  background: linear-gradient(180deg, #2a1410, #1a0a07);
  border: 1px solid #5a2412;
  color: #ffb38a;
  font: inherit; cursor: pointer;
  padding: 2px 10px; border-radius: 999px;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px;
  transition: transform 0.12s, box-shadow 0.2s;
}
.fire-btn:hover { transform: translateY(-1px); box-shadow: 0 0 18px #e6572233; }
.fire-btn:active { transform: scale(0.96); }
.fire-btn .flame { font-size: 13px; }
.fire-btn .fire-count { color: #e67e22; font-weight: 700; font-variant-numeric: tabular-nums; min-width: 1.5ch; }

.fire-fly {
  position: fixed; pointer-events: none;
  font-size: 1.6rem; z-index: 9999;
  animation: flyUp 1.3s ease-out forwards;
  will-change: transform, opacity;
}
@keyframes flyUp {
  0%   { opacity: 1; transform: translate(0, 0) scale(1) rotate(0deg); }
  40%  { opacity: 1; transform: translate(var(--dx), -60px) scale(1.4) rotate(var(--rot)); }
  100% { opacity: 0; transform: translate(calc(var(--dx) * 1.6), -200px) scale(2) rotate(var(--rot)); }
}
