/* -----------------------------------
  Base
----------------------------------- */
body {
  font-family: sans-serif;
  background-color: #121212;
  color: white;
  margin: 0;
  padding: 2rem;
}

section {
  margin-top: 3rem;
}

/* -----------------------------------
  Loader
----------------------------------- */
#loader {
  position: fixed;
  inset: 0;
  background-color: #121212;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  color: white;
}

.loader-name {
  font-size: 2rem;
  font-weight: bold;
  margin: 0;
}

.loader-subtitle {
  font-size: 1.2rem;
  opacity: 0.8;
  margin-top: 0.5rem;
}

/* -----------------------------------
  Header & Navigation
----------------------------------- */
header nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  padding: 0;
}

header nav a {
  color: white;
  text-decoration: none;
}

/* -----------------------------------
  Profile
----------------------------------- */
.profile-container {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.profile-img {
  width: 150px;
  border-radius: 50%;
  margin-bottom: 1rem;
}

/* -----------------------------------
  Works Section
----------------------------------- */
.works-grid {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 20px;
}

.work-item {
  background: #1e1e1e;
  padding: 1rem;
  border: 1px solid #333;
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.3s;
}

.work-item:hover {
  transform: scale(1.02);
}

.app-icon {
  width: 100px;
  height: 100px;
  border-radius: 22.5%;
  object-fit: cover;
  transition: transform 0.3s;
}

.app-icon:hover {
  transform: scale(1.05);
}

/* -----------------------------------
  Modal
----------------------------------- */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.show {
  display: block;
  opacity: 1;
}

.modal-content {
  background-color: #1e1e1e;
  margin: 10% auto;
  padding: 20px;
  width: 90%;
  max-width: 500px;
  border-radius: 10px;
  position: relative;
  color: white;
  transform: translateY(-30px);
  transition: transform 0.3s ease;
}

.modal.show .modal-content {
  transform: translateY(0);
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
}

.close:hover {
  color: #fff;
}

/* -----------------------------------
  Buttons
----------------------------------- */
.store-links {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
  /* 画面が狭いときは折り返し */
}

.store-button {
  height: 40px;
  /* App Storeバッジの高さを統一 */
}

.github-button {
  display: inline-flex;
  align-items: center;
  background-color: #24292e;
  color: white;
  padding: 8px 12px;
  margin: 5px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s;
}

.github-button:hover {
  background-color: #444;
}

.github-icon {
  width: 20px;
  height: 20px;
  margin-right: 8px;
}

/* -----------------------------------
  Skills
----------------------------------- */
.skill-icons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  margin-top: 15px;
}

.skill-icons img {
  height: 50px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.skill-icons img:hover {
  transform: scale(1.2);
}

.skill-icons img[alt="SAS"] {
  width: auto;
}

/* -----------------------------------
  Photo Gallery
----------------------------------- */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
  padding: 20px;
}

.photo-grid img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease;
}

.photo-grid img:hover {
  transform: scale(1.03);
}

img {
  -webkit-user-drag: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
