@charset "UTF-8";

:root {
  --emerald-main: #2fa89a;
  --emerald-light: #e6f4f2;
  --emerald-dark: #1f6f66;
  --text-main: #2f3e3e;
  --text-sub: #6b7c7a;
  --bg-main: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Noto Serif JP', serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.9;
}

/* ===== Header ===== */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 48px;
  border-bottom: 1px solid var(--emerald-light);
  background: linear-gradient(
  135deg,
  rgba(255, 255, 255, 0),
  rgba(230, 244, 242, 0.6),
  rgba(47, 168, 154, 0.25)
  );
  backdrop-filter: blur(6px);
}

.site-title {
  font-size: 20px;
  letter-spacing: 0.12em;
  color: var(--emerald-dark);
}

.nav a {
  margin-left: 32px;
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 0.08em;
  color: var(--text-main);
}

.nav a:hover {
  color: var(--emerald-main);
}

.nav .current {
  color: var(--emerald-main);
}
/* ===== Emerald Sparkle ===== */

#sparkle-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.sparkle {
  position: absolute;
  top: -10px;
  width: 6px;
  height: 6px;
  background: radial-gradient(
    circle,
    rgba(47, 168, 154, 0.9),
    rgba(47, 168, 154, 0.4),
    rgba(47, 168, 154, 0)
  );
  border-radius: 50%;
  opacity: 0.8;
  animation: sparkle-fall linear forwards;
}

@keyframes sparkle-fall {
  to {
    transform: translateY(110vh);
    opacity: 0;
  }
}

/* ===== Hero ===== */
.hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 96px 24px 120px;
  text-align: center;
}

.hero-image img {
  max-width: 600px;
  width: 100%;
}

.hero-text {
  margin-top: 48px;
}

.catchcopy {
  font-size: 14px;
  letter-spacing: 0.2em;
  color: var(--emerald-main);
}

.description {
  margin-top: 24px;
  font-size: 15px;
  color: var(--text-sub);
}

/* ===== Section ===== */
.section {
  max-width: 960px;
  margin: 0 auto;
  padding: 120px 24px;
}

.section-title {
  font-size: 22px;
  letter-spacing: 0.12em;
  color: var(--emerald-main);
  margin-bottom: 48px;
}

/* ===== About ===== */
.about-text {
  margin-bottom: 32px;
}

.about-link {
  margin-top: 56px;
}

.about-block {
  max-width: 640px;
  margin-bottom: 72px;
}

.about-block h2 {
  font-size: 16px;
  letter-spacing: 0.12em;
  color: var(--emerald-dark);
  margin-bottom: 24px;
}

.about-block ul li {
  margin-bottom: 12px;
}

.about ul {
  list-style-type: disc;
  margin-left: 1.6em;
}


/* ===== Works ===== */
.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 72px 56px;
  max-width: 1000px;
  margin: 0 auto;  
}

.work-item {
  text-align: center;
}

/* ===== Works 改良 ===== */

.work-item {
  text-align: left;
  padding: 24px;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 12px 24px rgba(47, 168, 154, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.work-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(47, 168, 154, 0.12);
}

.work-image {
  background-color: var(--emerald-light);
  padding: 8px;
}


.work-item img {
  border-radius: 8px;
  width: 100%;
  max-height: 180px;
  object-fit: cover;
  cursor: zoom-in;  
}

.work-title {
  margin-top: 16px;
  font-size: 15px;
  letter-spacing: 0.08em;
  color: var(--emerald-dark);
}

.work-caption {
  margin-top: 20px;
  font-size: 13px;
  line-height: 1.7;
}

/* ===== 作品詳細モーダル ===== */
#work-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  z-index: 1000;

  justify-content: center;
  align-items: center;
}

/* モーダル本体 */
#work-modal .modal-inner {
  background: #fff;
  max-width: 520px;
  width: 90%;
  padding: 32px 36px;
  border-radius: 14px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);

  animation: modalFadeIn 0.35s ease-out;
}

/* タイトル */
#modal-title {
  font-size: 1.3rem;
  font-weight: 400;
  margin-bottom: 8px;
  letter-spacing: 0.04em;
}

/* 使用技術 */
#modal-tech {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 18px;
}

/* 説明文 */
#modal-desc {
  font-size: 0.95rem;
  line-height: 1.9;
  color: #333;
  margin-bottom: 28px;
}

/* アプリを見るリンク */
#modal-link {
  display: inline-block;
  font-size: 0.9rem;
  color: #1f6f5c;
  text-decoration: none;
  border-bottom: 1px solid rgba(31, 111, 92, 0.4);
  padding-bottom: 2px;
}

#modal-link:hover {
  opacity: 0.7;
}

/* 閉じるボタン */
#work-modal .modal-close {
  position: absolute;
  top: 18px;
  right: 20px;
  font-size: 1.5rem;
  color: #888;
  cursor: pointer;
}

#work-modal .modal-close:hover {
  color: #000;
}

/* 表示アニメーション */
@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Image Modal ===== */

.modal {
  display: none;
  position: fixed;
  z-index: 999;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(6px);
}

.modal-content {
  display: block;
  max-width: 90%;
  max-height: 90%;
  margin: auto;
  margin-top: 5vh;
  border-radius: 12px;
  box-shadow: 0 30px 60px rgba(47, 168, 154, 0.25);
}

.modal-close {
  position: absolute;
  top: 24px;
  right: 32px;
  font-size: 32px;
  color: var(--emerald-dark);
  cursor: pointer;
}
/* ===== Sparkle Effect ===== */
#sparkle-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
}

.sparkle {
  position: absolute;
  background: radial-gradient(
    circle,
    rgba(47, 168, 154, 0.8),
    rgba(47, 168, 154, 0.3),
    transparent 70%
  );
  border-radius: 50%;
  opacity: 0;
  animation: sparkle-fall linear forwards;
}

/* 上から静かに降る */
@keyframes sparkle-fall {
  0% {
    transform: translateY(0) scale(0.6);
    opacity: 0;
  }
  20% {
    opacity: 0.6;
  }
  100% {
    transform: translateY(120vh) scale(1);
    opacity: 0;
  }
}

/* マウス付近で一瞬光る */
.sparkle.mouse {
  animation: sparkle-pop 1.2s ease-out forwards;
}

@keyframes sparkle-pop {
  0% {
    transform: scale(0.3);
    opacity: 0;
  }
  30% {
    opacity: 0.7;
  }
  100% {
    transform: scale(1.2);
    opacity: 0;
  }
}

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 64px 24px;
  font-size: 12px;
  color: var(--text-sub);
  border-top: 1px solid var(--emerald-light);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .header {
    flex-direction: column;
    gap: 12px;
  }

  .nav a {
    margin-left: 4px;
    margin-right: 4px;
  }

  .hero {
    padding: 72px 16px 96px;
  }

  .section {
    padding: 96px 16px;
  }
  .work-image {
      height: 140px;
    }
}
