/* =========================
   RESET / BASE
========================= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  min-height: 100%;
  background: #fff;
  color: #000;
  font-family: Helvetica, Arial, sans-serif;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  padding: 20px;
}

a {
  color: #000;
  text-decoration: none;
}

a:link,
a:visited,
a:hover,
a:active {
  text-decoration: none;
}

img {
  display: block;
  width: 100%;
  height: auto;
  -webkit-user-drag: none;
  user-drag: none;
  pointer-events: none;
}

iframe {
  border: 0;
  display: block;
}

/* =========================
   COMMON UI
========================= */
.logo {
  position: fixed;
  top: 20px;
  left: 20px;
  width: 80px;
  z-index: 20;
}

.logo a,
.logo img {
  display: block;
  width: 100%;
  height: auto;
}

.side {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
}

.menu {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 20px;
}

.menu a {
  display: block;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.01em;
  color: #0000AA;
  text-decoration: none;
  border-bottom: none;
}

.menu a:link,
.menu a:visited,
.menu a:hover,
.menu a:active {
  color: #0000AA;
  text-decoration: none;
  border-bottom: none;
}

.status {
  font-size: 13px;
  line-height: 1.4;
}

/* =========================
   INDEX
========================= */
.site {
  display: flex;
  justify-content: center;
}

.main-index {
  width: 100%;
  max-width: 480px;
  margin-top: 30px;
}

.feed {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.post {
  width: 100%;
}

.post-media {
  width: 100%;
}

.post-media + .post-media {
  margin-top: 10px;
}

.post-media img {
  width: 100%;
  height: auto;
  object-fit: cover;
  background: #f4f4f4;
}

.post-media-link {
  display: block;
  cursor: pointer;
}

.post-text {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.3;
  white-space: pre-wrap;
  word-break: break-word;
}

.youtube-wrap {
  width: 100%;
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #f4f4f4;
}

.youtube-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* =========================
   VISUAL
========================= */
.main-visual {
  width: 100%;
  max-width: 980px;
  margin: 120px auto 0;
}

.groups {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.tiles {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 10px;
}

.tile {
  width: 180px;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #f4f4f4;
  border: 0;
  padding: 0;
  cursor: pointer;
  appearance: none;
}

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

/* modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.96);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 40px;
}

.modal.open {
  display: flex;
}

.modal-inner {
  max-width: min(92vw, 1200px);
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.modal-close {
  position: fixed;
  top: 20px;
  right: 20px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  background: none;
  border: 0;
  color: #000;
  cursor: pointer;
  font-family: Helvetica, Arial, sans-serif;
  z-index: 110;
}

.modal-nav {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 20px;
  z-index: 110;
}

.modal-nav button {
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  background: none;
  border: 0;
  color: #000;
  cursor: pointer;
  font-family: Helvetica, Arial, sans-serif;
}

/* =========================
   SHOP
========================= */
.main-shop {
  max-width: 486px;
  margin: 120px auto 0;
}

.section {
  margin-bottom: 80px;
}

.shop {
  margin-bottom: 40px;
}

.shop-name {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
}

.shop-info {
  font-size: 13px;
  line-height: 1.5;
  margin-top: 6px;
}

.shop-links {
  margin-top: 10px;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.shop-links a,
.shop-links a:link,
.shop-links a:visited,
.shop-links a:hover,
.shop-links a:active {
  color: #000;
  text-decoration: none;
}

/* =========================
   MOBILE
========================= */
@media (max-width: 800px) {
  body {
    padding: 16px;
  }

  .logo {
    top: 16px;
    left: 16px;
    width: 64px;
  }

  .side {
    position: fixed;
    right: 16px;
    top: 16px;
    transform: none;
    z-index: 20;
  }

  .menu {
    gap: 14px;
    align-items: flex-end;
  }

  .main-index {
    max-width: 100%;
    margin-top: 100px;
  }

  .main-visual {
    margin-top: 100px;
    max-width: 100%;
  }

  .main-shop {
    margin-top: 100px;
    max-width: 100%;
  }

  .tiles {
    gap: 6px;
  }

  .tile {
    width: calc(33.333% - 4px);
  }

  .modal {
    padding: 20px;
  }

  .modal-close {
    top: 16px;
    right: 16px;
  }

  .modal-nav {
    bottom: 18px;
  }
}