<template>
  <section class="home">
    <h1>Utility App for TTRPGs</h1>
    <p class="lead">Small, focused tools to speed up tabletop prep: generate names, balance attributes, and connect to Foundry VTT resources.</p>

    <p class="intro">This app collects lightweight utilities for GMs and players. Use the sidebar to navigate between tools — each page offers quick controls and sensible defaults so you can get results without fumbling through settings.</p>

    <ul class="tools-list">
      <li>
        <div class="tool-card">
          <h3>Name Generator</h3>
          <p class="muted">Generate character names by race, language and gender. Create reusable lists and quickly copy results into your notes.</p>
        </div>
      </li>
      <li>
        <div class="tool-card">
          <h3>Attribute Calculator</h3>
          <p class="muted">Experiment with point-buy and rolled stats, see derived modifiers, and compare different allocation strategies.</p>
        </div>
      </li>
      <li>
        <div class="tool-card">
          <h3>Foundry</h3>
          <p class="muted">Quick link and notes for integrating with Foundry VTT (external). Use this as a launch/reference point rather than a full integration.</p>
        </div>
      </li>
    </ul>
  </section>
</template>

<script setup>
// Home page with links to utilities
</script>

<style scoped>
.home {
  text-align: center;
  padding: var(--spacing-2xl) 0;
  max-width: 720px;
  margin: 0 auto;
}

.home h1 {
  margin-bottom: var(--spacing-sm);
  font-size: 2rem;
  letter-spacing: -0.02em;
}

.home p {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: var(--spacing-lg);
  line-height: 1.6;
}

.tools-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
}

.tools-list li {
  transform: translateY(0);
  transition: transform 0.16s ease;
}

.tools-list li:hover {
  transform: translateY(-4px);
}

.tools-list .tool-card {
  display: block;
  font-size: 1.05rem;
  color: var(--text-primary);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  text-decoration: none;
  font-weight: 700;
  box-shadow: var(--shadow-md);
  transition: all 0.16s ease;
  position: relative;
  overflow: hidden;
}

.tools-list .tool-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--color-primary),
    var(--color-accent-hover)
  );
  transition: left 0.28s ease;
}

.tools-list li:hover .tool-card::before {
  left: 0;
}

.tools-list li:hover .tool-card {
  background: var(--surface-hover);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-lg);
  color: var(--color-primary);
}

@media (max-width: 768px) {
  .tools-list {
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
  }

  .tools-list .tool-card {
    padding: var(--spacing-md);
  }
}
</style>
