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

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: 'Times New Roman', Times, serif;
  overflow: hidden;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: none;
}
main {
  flex: 1;
  background-size: 100%;
  padding-top: 40px;
}
.main-image {
  width: 100%;
  max-width: 100%;   
  height: 550px;
  max-height: auto; 
  display: block;
  object-fit: contain; 
  margin: 0 auto;
}
/*
.main {
  flex: 1;  
  padding-top: 40px; 
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 100vh;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}
*/
header {
  background: none;           
}

h2 {
  font-family: 'Times New Roman', Times, serif;
  color: black;
  text-align: center;
  margin-top: 0;
}

footer {
  background-color: white;
  color: black;
  text-align: center;
  padding: 10px 0;
}
/* Hamburger styles */
.hamburger {
  display: inline-block;
  cursor: pointer;
  z-index: 2;
}

.bar {
  width: 30px;
  height: 4px;
  margin: 6px 0;
  transition: 0.4s;
  display: block;
  background-color: #333; 
}

/* Hide menu by default */
.nav-links {
  display: none;
  position: absolute;
  right: 0;
  background: #e0e0e0;
  list-style: none;
  margin: 0;
  padding: 10px 0;
  min-width: 140px;
  color: black;
  right: 0;
  left: auto;
}
.nav-links li a {
  color: black;
  text-decoration: none;
  cursor: default; 
  pointer-events: none;
  padding: 10px 20px;
  display: block;
}
#openModal {
  cursor: pointer;
  pointer-events: auto;
}
/* Show menu on hover */
.hamburger-menu:hover .nav-links,
.hamburger-menu:focus-within .nav-links {
  display: block;
}

.hamburger-menu {
  position: absolute;
  top: 20px;   
  right: 20px;
  z-index: 10;
  display: inline-block;
}

/* Align navigation to the right */
.navigation, .nav-bar, .hamburger-menu {
  position: relative;
  display: flex;
  justify-content: flex-end;   
}

.main {
  position: relative; 
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
}
.modal-content {
  background: #fff;
  margin: 10% auto;
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  position: relative;
}
.close {
  position: absolute;
  right: 16px;
  top: 8px;
  font-size: 28px;
  cursor: pointer;
}

.container {
  position: relative;
}

/* ハンバーガーメニューを画像の右上に絶対配置 */
.hamburger-menu {
  position: absolute;
  top: 10px;     
  right: 10px;   
  z-index: 10;    
}

/* 画像の下に余白ができないように */
.main-image {
  display: block;
  max-width: 100vw;      
  max-height: 60vh;     
  width: auto;
  height: auto;
  margin: 0 auto;
  object-fit: contain;   
}

footer {
  position: static;
  margin-top: 20px;
}

/* 画面幅が600px以下のときのスタイル */
@media (max-width: 600px) {
  body {
    padding-top: 50px; 
    font-size: 16px;
  }

  .main-image {
    max-width: 100vw;
    max-height: 30vh; 
    width: 100%;
    height: auto;
  }

  .hamburger-menu {
    padding: 8px;
    top: 0;
    right: 0;
  }

  .nav-links {
    position: absolute;
    top: 50px; 
    right: 0;
    background: #fff;
    width: 100vw;
    display: none;
    flex-direction: column;
    text-align: right;
    z-index: 999;
  }
  .nav-links.active {
    display: flex;
  }
  .nav-links li {
    margin: 10px 20px;
  }
 
  footer {
    text-align: center;
    font-size: 14px;
    margin-top: 10px;
  }
}

body {
  padding-top: 60px; 
}

.container-image {
  position: relative;
}

.container-image-wrapper {
  position: relative;
  width: fit-content;
  margin: 0 auto;
  padding-top: 50px;
}

.hamburger-menu {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 10;
  background: none;
  padding: 10px;
}
/* modal form */
.modal-form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 16px;
}

.modal-form-group label {
  margin-bottom: 6px;
  font-size: 16px;
}

.modal-form-group input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 16px;
  box-sizing: border-box;
}

.modal-form-actions {
  display: flex;
  justify-content: flex-end;
}

.modal-form-actions button {
  padding: 8px 28px;
  font-size: 16px;
  background: #A6C0CD;
  color: #333;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}