/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Hiragino Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
  line-height: 1.5;
  background: #fff;
  min-height: 100vh;
  scroll-behavior: smooth;
}

.container {
  max-width: 940px;
  margin: 0 auto;
  padding: 0 20px;
}

.header {
  background-color: #ef8b76;
  color: #fff;
  padding-top: 25px;
  padding-bottom: 25px;
  position: relative;
  margin: auto;
  width: 100%;
}

.header_contents {
  text-align: center;
  align-items: center;
}

.header_title {
  font-size: 40px;
  font-weight: 200;
}

.header_text {
  font-size: 24px;
  margin-left: 10px;
}

.step {
  list-style-type: none;
  display: table;
  width: 60%;
  padding: 0;
  overflow: hidden;
  font-size: 14px;
  margin: auto;
  margin-top: 30px;
  margin-bottom: 50px;
  text-align: center;
}

.step li {
  display: table-cell;
  position: relative;
  background: #f8f1ee;
  padding: 10px 0 10px 20px;
  color: #a87763;
  font-weight: 400;
}

.step li:first-child {
  padding-right: 5px;
  padding-left: 20px;
}

.step li:last-child {
  padding-right: 20px;
  padding-left: 30px;
}

.step li:last-child:after,
.step li:last-child:before {
  display: none;
}

.step li:after,
.step li:before {
  content: "";
  position: absolute;
  width: 0;
  height: 0;
  margin: auto;
}

.step li:before {
  right: -2em;
  border-color: transparent transparent transparent #fff;
}

.step li:after,
.step li:before {
  top: -10px;
  border-style: solid;
  border-width: 40px 0 40px 30px;
  z-index: 5;
}

.step li:after {
  right: -1.8em;
  border-color: transparent transparent transparent #f8f1ee;
}

.step li.is-current {
  background: #ef8b76;
  color: #fff;
}

.step li.is-current:after {
  border-color: transparent transparent transparent #ef8b76;
}

.bar_left {
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
}

.bar_right {
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
}

@media screen and (max-width: 768px) {
  .step {
    font-size: 8px;
    width: 100%;
    margin-bottom: 30px;
  }

  .step li {
    padding: 10px 0 10px 10px;
  }

  .step li:first-child {
    padding-right: 3px;
    padding-left: 0;
  }

  .step li:last-child {
    padding-right: 5px;
    padding-left: 15px;
  }

  .step li:before {
    top: -15px;
    right: -2.3em;
    border-width: 40px 0 40px 30px;
  }

  .step li:after {
    top: -15px;
    right: -2.1em;
    border-width: 40px 0 40px 30px;
  }
}

.form-content {
  padding: 30px 0;
}

.form-group {
  margin-bottom: 50px;
}

.question {
  font-size: 22px;
  color: #a77865;
  border-bottom: 1px solid;
  border-bottom-color: #a77865;
  position: relative;
  font-weight: 500;
  margin-bottom: 25px;
}

.required {
  font-size: 14px;
  font-weight: 400;
  background-color: #c80000;
  color: #fff;
  padding: 1px 8px;
  margin-left: 16px;
  vertical-align: middle;
}

.small-text {
  font-size: 14px;
  font-weight: 400;
  color: #a77865;
  margin-left: 10px;
}

.note {
  margin-top: 4px;
  font-size: 14px;
  font-weight: 200;
}

input[type="text"],
input[type="email"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 12px 16px;
  border: none;
  font-size: 18px;
  transition: all 0.3s ease;
  background: #f8f1ee;
  height: 50px;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border: none;
}

select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 12px center;
  background-repeat: no-repeat;
  background-size: 16px;
  padding-right: 40px;
}

textarea {
  resize: vertical;
  min-height: 200px;
  background: none;
  border: 1px solid #00000080;
  border-radius: 4px;
}
textarea:focus {
  border: 1px solid #a77865;
}

.date-time-group {
  display: flex;
  gap: 15px;
  align-items: flex-start;
}
.date-input {
  margin-bottom: -22px;
  width: 35%;
}
.time-radio-group {
  display: flex;
  gap: 8px;
  padding-top: 4px;
}

.radio-group {
  display: flex;
  gap: 26px;
  padding: 0 20px;
}
.radio-item {
  display: flex;
  align-items: center;
  cursor: pointer;
  padding: 8px;
}

.radio-item label {
  display: block;
  font-size: 18px;
  cursor: pointer;
  padding-left: 15px;
}

input[type="radio"] {
  cursor: pointer;
  transform: scale(1.4);
  accent-color: #a77865;
}

input[type="radio"]:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

input[type="radio"]:disabled + label {
  cursor: not-allowed;
  opacity: 0.5;
}

.name-group {
  display: flex;
  gap: 24px;
}

.birth-date-group {
  display: flex;
  gap: 10px;
  align-items: center;
}
.birth-date-group-item {
  width: 15%;
}
.birth-date-group-separator {
  font-size: 18px;
  font-weight: 300;
}

.submit-btn {
  color: white;
  font-size: 28px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 80%;
  margin: 0 10% 40px;
  padding: 20px;
  border-radius: 20px;
  background: #ef8b76;
}

.submit-btn:not(.disabled):hover {
  background: #cb7463;
}

.submit-btn.disabled {
  background: #a77865;
  cursor: not-allowed;
}

.privacy-policy {
  height: 200px;
  border: 1px solid #000;
  overflow-y: scroll;
  padding: 20px;
  margin-top: 20px;
  font-weight: 300;
  line-height: 2;
}

.privacy-policy-inner {
  padding: 10px;
}

.privacy-policy-inner h3 {
  padding: 20px;
  font-weight: 400;
}
.privacy-policy-inner ol {
  padding-left: 20px;
}
.privacy-policy-inner ol > li:not(ol > li > ol > li) {
  margin-bottom: 1rem;
}

.error {
  color: #e74c3c;
  font-size: 14px;
  margin-top: 4px;
  height: 14px;
}

.confirm-message {
  border: 3px solid #a77865;
  margin: -30px 0 60px;
  text-align: center;
}

.confirm-message p {
  font-size: 18px;
}

.confirm-message p:first-child {
  font-size: 18px;
  padding: 10px;
  background: #a77865;
  color: #fff;
}
.confirm-message p:last-child {
  padding: 10px 30px;
}

.confirm-details {
  width: 100%;
  margin-bottom: 30px;
  border-collapse: collapse;
}

.confirm-item {
  border: 1px solid #a77865;
  margin-bottom: 20px;
  padding: 15px;
  height: 60px;
  text-align: left;
}

.confirm-item th {
  font-weight: 600;
  font-size: 18px;
  background: #f8f1ee;
  width: 35%;
  padding: 0 30px;
}

.confirm-item th div {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.confirm-value {
  padding: 0 30px;
  color: #333;
  font-size: 16px;
  line-height: 1.5;
  word-break: break-word;
}

.confirm-actions {
}

.back-btn {
  border: 1px solid #a77865;
  padding: 20px;
  margin: 0 10% 40px;
  font-size: 28px;
  font-weight: 700;
  border-radius: 20px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  color: #a77865;
  text-align: center;
  transition: all 0.3s ease;
}

.back-btn:hover {
  background: #dedede;
}

.button-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.thanks-container {
  text-align: center;
  max-width: 540px;
  margin: 0 auto;
}

.thanks-title {
  font-size: 28px;
  font-weight: 200;
  text-align: center;
  padding: 10px;
  margin-bottom: 41px;
  border-top: 3px solid;
  border-bottom: 3px solid;
  color: #ef8b76;
}

.thanks-message {
  font-size: 18px;
  font-weight: 300;
  line-height: 1.8;
  margin-bottom: 1.3em;
}

.thanks-contact-title {
  font-size: 20px;
  width: inherit;
  text-align: center;
  padding: 14px 0;
  background-color: #a77865;
  color: #fff;
}

.thanks-contact-body {
  font-size: 18px;
  padding: 10px 50px;
  background-color: #f8f1ee;
}

.thanks-contact-item {
  height: 41px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #a77865;
}

.thanks-contact-item:last-child {
  border-bottom: none;
}

.thanks-contact-item > span {
  display: flex;
  align-items: center;
  gap: 10px;
}

.thanks-contact-item > span > span:first-child {
  min-width: 3em;
}

.thanks-contact-item a {
  color: #000;
}

.thanks-contact-note {
  font-size: 14px;
  font-weight: 300;
  color: red;
}

.thanks-link {
  font-size: 18px;
  font-weight: 300;
  text-align: center;
  margin: 40px 0;
}

/* Responsive design */
@media (max-width: 768px) {
  .header {
    padding-top: 15px;
    padding-bottom: 15px;
  }

  .header_title {
    font-size: 25px;
  }

  .header_text {
    font-size: 15px;
  }

  .note {
    font-size: 12px;
  }
  .date-input {
    width: 60%;
  }

  .birth-date-group-item {
    width: 25%;
  }

  .privacy-policy {
    font-size: 14px;
  }

  .submit-btn {
    font-size: 20px;
    margin-bottom: 20px;
  }
  .back-btn {
    font-size: 20px;
    margin-bottom: 20px;
  }

  .confirm-message {
    margin-bottom: 20px;
  }

  .confirm-message p {
    font-size: 14px;
  }

  .confirm-message p:first-child {
    font-size: 14px;
  }

  .confirm-item th {
    font-size: 12px;
    width: auto;
    padding: 0 20px;
  }

  .confirm-item {
    padding: 12px;
  }

  .confirm-value {
    font-size: 12px;
  }

  .required {
    font-size: 12px;
  }

  .thanks-container {
    max-width: 480px;
  }

  .thanks-title {
    font-size: 18px;
  }

  .thanks-message {
    font-size: 14px;
  }

  .thanks-contact-title {
    font-size: 14px;
  }

  .thanks-contact-body {
    font-size: 16px;
    padding: 10px 30px;
  }

  .button-group {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .question {
    font-size: 18px;
  }
  .radio-item label {
    font-size: 14px;
  }

  input[type="text"],
  input[type="email"],
  input[type="date"],
  select,
  textarea {
    font-size: 14px;
  }

  select {
    padding-right: 10px;
  }

  .birth-date-group {
    justify-content: space-between;
    gap: 5px;
  }

  .date-time-group {
    flex-wrap: wrap;
  }
  .date-input {
    width: 100%;
  }

  .radio-group {
    flex-direction: column;
    gap: 10px;
  }

  .birth-date-group-separator {
    font-size: 14px;
  }

  .privacy-policy {
    font-size: 12px;
  }

  .confirm-item th {
    font-size: 10px;
    width: auto;
    padding: 0 15px;
  }

  .confirm-value {
    font-size: 10px;
    padding: 0 15px;
  }

  .required {
    font-size: 8px;
    padding: 1px 6px;
    margin-left: 10px;
  }

  .thanks-contact-body {
    font-size: 12px;
    padding: 10px 20px;
  }
  .thanks-contact-item > span {
    gap: 5px;
  }
  .thanks-contact-note {
    font-size: 12px;
  }
  .thanks-link {
    font-size: 14px;
  }
}

/* Animation for form loading */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.container {
  animation: fadeInUp 0.6s ease-out;
}
