* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: sans-serif;
  line-height: 1.6;
  letter-spacing: 0.03em;
  color: #222;
}

img {
  width: 100%;
  display: block;
}

ul {
  list-style: none;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

section {
  padding: 80px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 40px;
}

.section-title::after {
  content: "";
  display: block;
  width: 40px;
  height: 3px;
  background: #4da3ff;
  margin: 10px auto 0;
}

.section-subtitle {
  text-align: center;
  margin-bottom: 8px;
  color: #777;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  background: #fff;
  border-bottom: 1px solid #ddd;
  z-index: 1000;
}

.header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  position: relative;
  background: #fff;
  z-index: 1001;
}

.header__logo {
  font-size: 20px;
}

.header__list {
  display: flex;
  gap: 30px;
}

.header__item a {
  font-size: 14px;
  font-weight: bold;
  transition: 0.3s;
}

.header__item a:hover {
  color: #4da3ff;
}

/* Hamburger */
.hamburger {
  display: none;
  width: 30px;
  height: 24px;
  background: none;
  border: none;
  position: relative;
  cursor: pointer;
  z-index: 1001;
}

.hamburger span {
  position: absolute;
  width: 100%;
  height: 2px;
  background: #222;
  left: 0;
  transition: 0.3s;
}

.hamburger span:nth-child(1) {
  top: 0;
}

.hamburger span:nth-child(2) {
  top: 10px;
}

.hamburger span:nth-child(3) {
  bottom: 0;
}

.header.menu-open .hamburger span:nth-child(1) {
  transform: translateY(10px) rotate(45deg);
}

.header.menu-open .hamburger span:nth-child(2) {
  opacity: 0;
}

.header.menu-open .hamburger span:nth-child(3) {
  transform: translateY(-12px) rotate(-45deg);
}

/* Overlay */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
  z-index: 999;
}

.header.menu-open+.overlay {
  opacity: 1;
  visibility: visible;
}

/* Hero */
.hero {
  background: url("../img/main1.png") center / cover no-repeat;
  height: 60vh;
  color: #fff;
  text-align: center;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero__title {
  font-size: 40px;
  font-weight: 700;
  margin-bottom: 20px;
  text-shadow: 0 3px 12px rgba(0, 0, 0, 0.6);
}

.hero__text {
  font-size: 16px;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}



.sp-br {
  display: none;
}

/* Works */
.works {
  background: #f7f7f7;
}

.works__list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.works__item {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transform: translateY(0);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    filter 0.25s ease;
}

.js-fade {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.js-fade.is-show {
  opacity: 1;
  transform: translateY(0);
}

.works__item.js-fade.is-show:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
  filter: brightness(1.03);
}

.works__item:active {
  transform: translateY(-3px);
}

.works__img {
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.works__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.works__body {
  padding: 16px;
}

.works__title {
  font-size: 18px;
  margin-bottom: 10px;
}

.works__text {
  font-size: 14px;
}

/* Skills */
.skills {
  background: #fff;
}

.skills__list {
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.skills__item {
  flex: 1;
  background: #f7f7f7;
  padding: 16px;
  text-align: center;
  font-weight: bold;
}

.skills__icon {
  width: 64px;
  height: 64px;
  object-fit: contain;
  margin: 0 auto 12px;
  mix-blend-mode: multiply;
}

.skills__title {
  font-size: 16px;
  margin-bottom: 8px;
}

.skills__sub {
  display: block;
  font-size: 12px;
  color: #666;
  margin-top: 5px;
  line-height: 1.7;
  font-weight: normal;
}

/* Flow */
.flow {
  background: #f7f7f7;
  padding: 80px 0;
}

.flow__img {
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

.flow__img img {
  width: 100%;
  height: auto;
}

.flow-img {
  cursor: pointer;
  max-width: 100%;
}

.flow-note {
  text-align: center;
  font-size: 13px;
  color: #666;
  margin-top: 12px;
}

.flow__lead {
  text-align: center;
  font-size: 14px;
  color: #666;
  margin: -20px 0 40px;
}

/* About */
.about {
  background: #f0f0f0;
}

.about__inner {
  display: flex;
  align-items: center;
  gap: 40px;
  max-width: 800px;
  margin: 0 auto;
}

.about__profile {
  flex-shrink: 0;
}

.about__icon {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ddd;
}

.about__text {
  line-height: 1.8;
}

/* Contact */
.contact {
  background: #444;
  color: #fff;
  text-align: center;
  padding: 120px 0;
}

.contact__title {
  font-size: 36px;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.contact__subtitle {
  font-size: 14px;
  margin-bottom: 30px;
  opacity: 0.8;
}

.contact__thanks {
  max-width: 600px;
  margin: 0 auto 30px;
  font-size: 14px;
  line-height: 2;
  opacity: 0.9;
}

.contact__form {
  max-width: 500px;
  margin: 0 auto;
}

.contact__field {
  margin-bottom: 15px;
}

.contact__field input,
.contact__field textarea,
.contact__field select {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
}

.contact__field textarea {
  height: 140px;
  resize: vertical;
}

.contact__submit {
  width: 100%;
  padding: 12px;
  background: #4da3ff;
  color: #fff;
  border: none;
  border-radius: 30px;
  cursor: pointer;
  transition: 0.3s;
}

.contact__submit:hover {
  background: #2f8ae6;
}

/* Fixed Button */
.fixed-contact {
  position: fixed;
  right: 20px;
  bottom: 20px;
  background: #4da3ff;
  color: #fff;
  padding: 12px 20px;
  border-radius: 30px;
  z-index: 998;
}

/* Footer */
.footer {
  padding: 20px 0;
  text-align: center;
  font-size: 12px;
  color: #666;
}

/* Work Modal */
.work-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.65);
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
  z-index: 2000;
  padding: 40px;
}

.work-modal.is-show {
  opacity: 1;
  visibility: visible;
}

.work-modal__content {
  position: relative;
  width: 100%;
  height: 100%;
  background: #fff;
  transform: scale(0.95);
  transition: 0.3s;
}

.work-modal.is-show .work-modal__content {
  transform: scale(1);
}

.work-modal__frame {
  width: 100%;
  height: 100%;
  border: none;
}

.work-modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #222;
  border: none;
  cursor: pointer;
  transition: 0.3s;
}

.work-modal__close::before,
.work-modal__close::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 2px;
  background: currentColor;
  top: 19px;
  left: 11px;
}

.work-modal__close::before {
  transform: rotate(45deg);
}

.work-modal__close::after {
  transform: rotate(-45deg);
}

.work-modal__close:hover {
  background: #222;
  color: #fff;
}

/* Image Modal */
.img-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.img-modal.is-show {
  display: flex;
}

.img-modal__content {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.img-modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #222;
  border: none;
  cursor: pointer;
  transition: 0.3s;
}

.img-modal__close::before,
.img-modal__close::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 2px;
  background: currentColor;
  top: 19px;
  left: 11px;
}

.img-modal__close::before {
  transform: rotate(45deg);
}

.img-modal__close::after {
  transform: rotate(-45deg);
}

.img-modal__close:hover {
  background: #222;
  color: #fff;
}

/* SP */
@media (max-width: 768px) {
  section {
    padding: 60px 0;
  }

  .sp-br {
    display: block;
  }

  .hamburger {
    display: block;
  }

  .header__nav {
    position: absolute;
    top: 100%;
    left: -100%;
    width: 70%;
    height: 100vh;
    background: #fff;
    padding: 80px 20px;
    transition: 0.3s;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    z-index: -1;
  }

  .header.menu-open .header__nav {
    left: 0;
  }

  .header__list {
    flex-direction: column;
    gap: 24px;
  }

  .header__item a {
    font-size: 16px;
  }

  .hero {
    height: 55vh;
  }

  .hero__title {
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
    font-size: 30px;
    line-height: 1.5;
  }

  .works__list {
    grid-template-columns: 1fr;
  }

  .skills__list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .skills__item {
    width: auto;
  }

  .about__inner {
    flex-direction: column;
    text-align: center;
  }

  .contact {
    padding: 80px 0;
  }

  .contact__title {
    font-size: 28px;
  }

  .contact__thanks {
    font-size: 13px;
    line-height: 1.8;
  }

  .work-modal {
    padding: 50px 15px 20px;
  }
}

@media (max-width: 480px) {
  .skills__list {
    grid-template-columns: 1fr;
  }
}