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

body.public-page {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #0a0e27 0%, #16213e 50%, #0f3460 100%);
  color: #e0e0e0;
  overflow-x: hidden;
  min-height: 100vh;
}

/* パーティクル背景 */
#particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.5;
}

/* コンテンツレイヤー */
.container-top {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
  padding: 60px 40px;
}

/* ヘッダー */
header {
  text-align: center;
  margin: 50px 0 40px;
  animation: slideDown 0.8s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

header img {
  width: 88%;
  height: auto;
  object-fit: cover;
  max-width: 1000px;
  position: relative;
  z-index: 10;
}

.subtitle {
  font-size: 1.2em;
  color: #00d9ff;
  opacity: 0.8;
  font-weight: bold;
  letter-spacing: 1px;
  font-family: "Tektur", sans-serif;
  font-style: normal;
  font-variation-settings: "wdth" 100;
  text-shadow: 0 0 6px #fff, 0 0 10px #fff, 0 0 21px #fff, 0 0 19px #0fa,
    0 0 10px #0fa, 0 0 4px #0fa, 0 0 25px #0fa, 0 0 4px #0fa;
  padding-top: 0.5em;
}

/* ギャラリーグリッド */
.gallery-top {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 80px;
  margin-bottom: 60px;
}

/* カード */
.card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
  border: 2px solid rgba(0, 217, 255, 0.2);
  background: rgba(15, 52, 96, 0.3);
  backdrop-filter: blur(10px);
  animation: fadeInUp 0.8s ease-out;
  animation-fill-mode: both;
  box-shadow: 0 0 0px #fff, 0 0 10px #fff, 0 0 20px #fff, 0 0 3px #228dff,
    0 0 5px #228dff, 0 0 10px #228dff, 0 0 10px #228dff, 0 0 20px #228dff;
}

/* カードのアクティブ状態（タップ時） */
.card:active {
  transform: scale(0.98);
}

.card:nth-child(1) {
  animation-delay: 0.1s;
}
.card:nth-child(2) {
  animation-delay: 0.2s;
}
.card:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* カード画像 */
.card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a2e, #16213e);
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease-out;
}

/* カード内容 */
.card-content {
  position: relative;
  z-index: 2;
  padding: 24px;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(
    180deg,
    rgba(15, 52, 96, 0.6) 0%,
    rgba(10, 14, 39, 0.8) 100%
  );
}

.card-title {
  font-size: 1.6rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: #00d9ff;
  font-family: "DotGothic16", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.card-description {
  font-size: 0.95rem;
  color: #b0b0b0;
  line-height: 1.5;
  opacity: 1;
  max-height: none;
  overflow: visible;
  margin-bottom: 12px;
}

.card-tag {
  display: inline-block;
  margin-top: 12px;
  padding: 6px 12px;
  background: rgba(0, 217, 255, 0.15);
  border: 1px solid rgba(0, 217, 255, 0.5);
  border-radius: 20px;
  font-size: 0.8rem;
  color: #00d9ff;
  font-weight: 500;
  opacity: 1;
  transform: translateX(0);
  width: fit-content;
}

/* カードリンク */
.card-link {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
  text-decoration: none;
}

/* フッター */
footer {
  text-align: center;
  padding: 40px 20px;
  border-top: 1px solid rgba(0, 217, 255, 0.2);
  color: #808080;
  font-size: 0.9rem;
  animation: fadeIn 1.2s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* 問い合わせボタン */
.contact-button {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, #00d9ff, #9d4edd);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  transition: all 0.3s ease-out;
  box-shadow: 0 0 20px rgba(0, 217, 255, 0.5);
  text-decoration: none;
  color: #0a0e27;
}

.contact-button svg {
  width: 24px;
  height: 24px;
  stroke: #0a0e27;
}

.contact-button:active {
  transform: scale(0.95);
}

/* レスポンシブ */
@media (max-width: 768px) {
  h1 {
    font-size: 2.5rem;
  }

  .gallery-top {
    grid-template-columns: 1fr;
    gap: 80px;
  }

  .container-top {
    padding: 40px;
  }

  .card {
    margin: 0 auto;
    max-width: 100%;
  }

  .contact-button {
    width: 50px;
    height: 50px;
    bottom: 20px;
    right: 20px;
  }

  .contact-button svg {
    width: 20px;
    height: 20px;
  }
}

/* スクロールアニメーション用 */
.fade-in-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease-out;
}

.fade-in-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}
