:root {
  --color-bg: #fafaf7;
  --color-surface: #ffffff;
  --color-text: #1f2328;
  --color-muted: #6b7280;
  --color-border: #e5e7eb;
  --color-accent: #3a7d6b;
  --color-accent-hover: #2c6253;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.06);
  --radius: 12px;
  --max-width: 960px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--color-accent-hover);
}

/* Header / Navigation */
.site-header {
  background-color: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: saturate(180%) blur(8px);
}

.nav {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-brand {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  color: var(--color-text);
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 8px;
}

.nav-list a {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 8px;
  color: var(--color-muted);
  font-size: 0.95rem;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-list a:hover {
  background-color: var(--color-bg);
  color: var(--color-text);
}

.nav-list a.is-active {
  background-color: var(--color-accent);
  color: #fff;
}

.nav-list a.is-active:hover {
  background-color: var(--color-accent-hover);
  color: #fff;
}

/* Layout */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.page-title {
  font-size: 2rem;
  margin: 0 0 8px;
  letter-spacing: 0.01em;
}

.page-subtitle {
  color: var(--color-muted);
  margin: 0 0 40px;
}

section + section {
  margin-top: 56px;
}

h2 {
  font-size: 1.4rem;
  margin: 0 0 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--color-border);
}

h3 {
  font-size: 1.1rem;
  margin: 0 0 8px;
}

/* Hero (top page) */
.hero {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 32px;
  align-items: center;
  margin-bottom: 56px;
}

.hero-photo {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-name {
  font-size: 2.2rem;
  margin: 0 0 8px;
  letter-spacing: 0.02em;
}

.hero-role {
  color: var(--color-accent);
  font-weight: 500;
  margin: 0 0 16px;
}

.hero-lead {
  color: var(--color-muted);
  margin: 0;
  max-width: 36em;
}

/* Profile facts list */
.facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.facts li {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 16px 20px;
  box-shadow: var(--shadow-sm);
}

.facts dt {
  font-size: 0.8rem;
  color: var(--color-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.facts dd {
  margin: 0;
  font-weight: 500;
}

/* Works grid */
.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.work-card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.work-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.work-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.work-card-body {
  padding: 16px 20px 20px;
}

.work-card h3 {
  margin-bottom: 4px;
}

.work-card-tag {
  display: inline-block;
  font-size: 0.75rem;
  color: var(--color-accent);
  background-color: rgba(58, 125, 107, 0.1);
  padding: 2px 10px;
  border-radius: 999px;
  margin-bottom: 8px;
}

.work-card p {
  margin: 0;
  color: var(--color-muted);
  font-size: 0.95rem;
}

/* Hobbies */
.hobbies {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.hobby {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 16px 20px;
  box-shadow: var(--shadow-sm);
}

.hobby-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  background-color: rgba(58, 125, 107, 0.12);
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: 600;
}

.hobby h3 {
  font-size: 1rem;
  margin: 0 0 4px;
}

.hobby p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--color-muted);
}

/* Contact */
.contact-card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 16px;
  max-width: 540px;
}

.contact-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--color-border);
}

.contact-row:last-child {
  border-bottom: 0;
}

.contact-label {
  color: var(--color-muted);
  font-size: 0.9rem;
}

.contact-value {
  font-weight: 500;
  word-break: break-all;
}

.contact-note {
  color: var(--color-muted);
  font-size: 0.95rem;
  margin-top: 16px;
}

/* Form */
.contact-form {
  display: grid;
  gap: 16px;
}

.contact-form label {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
  color: var(--color-muted);
}

.contact-form input,
.contact-form textarea {
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background-color: var(--color-surface);
  color: var(--color-text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(58, 125, 107, 0.15);
}

.contact-form textarea {
  resize: vertical;
  min-height: 140px;
}

.btn {
  appearance: none;
  border: 0;
  background-color: var(--color-accent);
  color: #fff;
  font: inherit;
  font-weight: 500;
  padding: 12px 20px;
  border-radius: 8px;
  cursor: pointer;
  justify-self: start;
  transition: background-color 0.15s ease;
}

.btn:hover {
  background-color: var(--color-accent-hover);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 24px;
  text-align: center;
  color: var(--color-muted);
  font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 640px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 20px;
  }

  .nav-list {
    width: 100%;
    overflow-x: auto;
  }

  main {
    padding: 32px 20px 64px;
  }

  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 20px;
  }

  .hero-photo {
    margin: 0 auto;
    width: 160px;
    height: 160px;
  }

  .hero-name {
    font-size: 1.8rem;
  }

  .contact-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
