/* ----------------------------------------------------------------------
   Reset and base styles
---------------------------------------------------------------------- */
html {
  scroll-behavior: auto;
  font-size: 62.5%;
}

/* Enable smooth scrolling only for manual clicks */
html.smooth-scroll {
  scroll-behavior: smooth;
}

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

body {
  font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  background-color: #fff;
  color: var(--secondary);
  font-size: 1.4rem;
}

img {
  display: block;
}

:root {
  --primary: #fd6051;
  --secondary: #40496d;
  --line: #06c755;
  --shadow-red: 2px 2px 0 #ede1d6;
  --alert: #f50f0f;
}

/* ----------------------------------------------------------------------
   Common layout classes
---------------------------------------------------------------------- */
.container {
  max-width: 430px;
  margin: 0 auto;
}

.mT10 {
  margin-top: 10px;
}
.mT15 {
  margin-top: 15px;
}
.mT20 {
  margin-top: 20px;
}
.mT30 {
  margin-top: 30px;
}
.mB5 {
  margin-bottom: 5px;
}
.mB10 {
  margin-bottom: 10px;
}
.mB15 {
  margin-bottom: 15px;
}
.mB20 {
  margin-bottom: 20px;
}
.mB30 {
  margin-bottom: 30px;
}
.pT5 {
  padding-top: 5px;
}
.pT10 {
  padding-top: 10px;
}
.pT15 {
  padding-top: 15px;
}
.pT20 {
  padding-top: 20px;
}
.pT30 {
  padding-top: 30px;
}
.pB5 {
  padding-bottom: 5px;
}
.pB10 {
  padding-bottom: 10px;
}
.pB15 {
  padding-bottom: 15px;
}
.pB20 {
  padding-bottom: 20px;
}
.pB30 {
  padding-bottom: 30px;
}

.weight {
  font-weight: bold;
  font-size: 1.4rem;
}

.text-alert {
  color: var(--alert);
}

/* ----------------------------------------------------------------------
   Header styles
---------------------------------------------------------------------- */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background-color: #fff;
  width: 100%;
  gap: 33px;
}

.header__logo {
  flex-shrink: 0;
}

.header__logo-link {
  display: block;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.header__logo-link:hover {
  opacity: 0.8;
}

.logo {
  display: block;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ----------------------------------------------------------------------
   LINE button styles
---------------------------------------------------------------------- */
.btn-line {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px 10px 4px 6px;
  background-color: var(--line);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.btn-line:hover {
  background-color: #05b04a;
}

.btn-line__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
}

.btn-line__text {
  color: #fff;
  font-weight: 500;
  font-size: 1.4rem;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
}

/* ----------------------------------------------------------------------
   Menu button styles
---------------------------------------------------------------------- */
.btn-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: opacity 0.2s ease;
}

.btn-menu:hover {
  opacity: 0.7;
}

/* ----------------------------------------------------------------------
   Hamburger menu styles
---------------------------------------------------------------------- */
.hamburger-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: #fef7f5;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease-in-out, visibility 0.4s ease-in-out;
  overflow-y: auto;
}

.hamburger-menu.is-open {
  opacity: 1;
  visibility: visible;
}

.hamburger-menu__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background-color: #fef7f5;
  border-bottom: 1px solid #e5e5e5;
}

.hamburger-menu__logo {
  flex-shrink: 0;
}

.hamburger-menu__logo-link {
  display: block;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.hamburger-menu__logo-link:hover {
  opacity: 0.8;
}

.hamburger-menu__close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 2.4rem;
  color: var(--secondary);
  font-weight: 300;
  transition: opacity 0.2s ease;
}

.hamburger-menu__close:hover {
  opacity: 0.7;
}

.hamburger-menu__content {
  padding: 40px 0;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.5s ease-out 0.1s, opacity 0.5s ease-out 0.1s;
}

.hamburger-menu.is-open .hamburger-menu__content {
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu__list {
  list-style: none;
  margin: 0;
  padding: 0;
  text-align: center;
}

.hamburger-menu__list li {
  margin-bottom: 16px;
  transform: translateY(15px);
  opacity: 0;
  transition: transform 0.4s ease-out, opacity 0.4s ease-out;
}

.hamburger-menu.is-open .hamburger-menu__list li:nth-child(1) {
  transition-delay: 0.2s;
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu.is-open .hamburger-menu__list li:nth-child(2) {
  transition-delay: 0.3s;
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu.is-open .hamburger-menu__list li:nth-child(3) {
  transition-delay: 0.4s;
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu.is-open .hamburger-menu__list li:nth-child(4) {
  transition-delay: 0.5s;
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu.is-open .hamburger-menu__list li:nth-child(5) {
  transition-delay: 0.6s;
  transform: translateY(0);
  opacity: 1;
}

.hamburger-menu__item {
  display: block;
  color: var(--secondary);
  text-decoration: none;
  font-size: 1.8rem;
  font-weight: 500;
  line-height: 1.4;
  padding: 12px 24px;
  transition: color 0.3s ease, transform 0.2s ease;
  border-radius: 8px;
}

.hamburger-menu__item:hover {
  color: var(--primary);
  transform: translateY(-2px);
}

/* Focus states for accessibility */
.btn-line:focus,
.btn-menu:focus {
  outline: 2px solid var(--line);
  outline-offset: 2px;
}

/* Active states */
.btn-line:active {
  transform: translateY(1px);
}

.btn-menu:active {
  transform: scale(0.95);
}

/* ----------------------------------------------------------------------
   Contact section styles
---------------------------------------------------------------------- */
.contact-section {
  background-color: #fff3f0;
  padding: 32px 24px 48px;
}

.contact-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding-bottom: 10px;
}

.contact-title {
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--secondary);
  text-align: center;
  line-height: 2.15;
}

.contact-subtitle {
  font-size: 2rem;
  font-weight: 600;
  color: var(--secondary);
  text-align: center;
  line-height: 1.6;
}

.contact-description {
  font-size: 1.6rem;
  line-height: 1.75;
  color: var(--secondary);
  text-align: left;
}

.contact-button-wrapper {
  display: flex;
  justify-content: flex-end;
  align-self: stretch;
  gap: 6px;
}

/* ----------------------------------------------------------------------
   Footer styles
---------------------------------------------------------------------- */
.footer {
  background-color: var(--secondary);
  padding: 40px 24px 20px;
}

.footer-content {
  position: relative;
}

.footer-content a {
  text-decoration: none;
}

.footer-logo h4 {
  color: #fff;
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 24px;
}

.footer-nav {
  margin-bottom: 32px;
}

.footer-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-nav-list li {
  margin-bottom: 12px;
}

.footer-nav-item {
  color: #fff;
  text-decoration: none;
  font-size: 1.6rem;
  font-weight: 400;
  transition: opacity 0.2s ease;
}

.footer-nav-item:hover {
  opacity: 0.8;
}

.footer-copyright {
  text-align: center;
}

.footer-copyright p {
  color: #fff;
  font-size: 1.4rem;
  margin: 0;
}

/* ----------------------------------------------------------------------
   Common button styles
---------------------------------------------------------------------- */
a.btn-line-top {
  position: absolute;
  color: #fff;
  left: 24px;
  right: 24px;
  bottom: 20px;
  border-radius: 12px;
  box-shadow: 4px 4px 0 #02a043;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  font-weight: 600;
  background-color: var(--line);
  padding: 20px 40px 14px;
  text-decoration: none;
}

a.btn-line-top img {
  padding-left: 4px;
}

a.btn-line-top span {
  position: absolute;
  top: -16px;
  background-color: #fff;
  padding: 0 10px;
  border: 2px var(--line) solid;
  color: var(--line);
  border-radius: 8px;
  font-size: 1.4rem;
}

/* ハンバーガーメニュー内のボタンエリア */
.hamburger-menu__button {
  max-width: 400px;
  margin: 60px auto 0;
  padding: 0 24px;
}

.hamburger-menu__button .btn-line-top {
  position: relative;
  left: auto;
  right: auto;
  bottom: auto;
  width: 100%;
  box-sizing: border-box;
}

.line-area {
  padding: 30px 24px;
  position: relative;
  z-index: 1;
}

.line-button-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 0 auto;
}

.completion-text-image {
  width: 183px;
  height: 53px;
}

.completion-text-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.button-wrapper {
  position: relative;
  width: 100%;
  height: 83px;
}

a.btn-line-normal {
  position: absolute;
  color: #fff;
  left: 0;
  right: 0;
  bottom: auto;
  border-radius: 12px;
  box-shadow: 4px 4px 0 #02a043;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  font-weight: 600;
  background-color: var(--line);
  padding: 24px 10px 16px;
  text-decoration: none;
  max-width: 360px;
  box-sizing: border-box;
  height: 69px;
  top: 14px;
  margin: 0 auto;
}

a.btn-line-normal img {
  padding-left: 4px;
}

a.btn-line-normal span {
  position: absolute;
  top: -16px;
  background-color: #fff;
  padding: 4px 10px;
  border: 2px var(--line) solid;
  color: var(--line);
  border-radius: 8px;
  font-size: 1.4rem;
}

/* ----------------------------------------------------------------------
   Check section styles
---------------------------------------------------------------------- */
.check-section {
  padding: 0 24px 30px;
  background: linear-gradient(#fff, #f8f9fa);
}

.check-content {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: var(--primary);
  border-radius: 0px;
  padding: 12px;
  box-shadow: 2px 2px 0px 0px rgba(214, 218, 237, 1);
  width: 289px;
  height: 109px;
  margin: 0 auto;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  cursor: pointer;
}

.check-content:hover {
  transform: translateY(-2px);
  box-shadow: 4px 4px 0px 0px rgba(214, 218, 237, 1);
  text-decoration: none;
  color: inherit;
}

.check-icon {
  width: 78px;
  height: 78px;
  flex-shrink: 0;
}

.check-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.check-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  flex: 1;
}

.check-title {
  font-family: "A P-OTF Shuei MaruGo Std", serif;
  font-weight: 500;
  font-size: 1.6rem;
  line-height: 1.48;
  color: #fff;
  margin: 0;
  width: 182px;
}

.check-description {
  font-family: "A P-OTF Shuei MaruGo Std", serif;
  font-weight: 400;
  font-size: 1.3rem;
  line-height: 1.54;
  color: #fff;
  margin: 0;
  width: 182px;
}

/* Contact section */

.anchor-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  line-height: 1.2;
  color: #0e82ed;
  text-decoration: none;
  margin: 0 0 6px;
  width: 100%;
}

.anchor-link img {
  width: 14px;
  height: 14px;
}

/* Common button styles with arrow */
.btn-secondary {
  background-color: #fff;
  border: 1px solid var(--secondary);
  border-radius: 16px;
  padding: 17px 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  width: auto;
  justify-content: flex-end;
}

.btn-secondary span {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  font-size: 1.6rem;
  line-height: 1.6;
  color: var(--secondary);
}

.btn-secondary img {
  width: 14px;
  height: 14px;
}

/* Button wrapper styles */
.counseling-button-wrapper {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.contact-button-wrapper {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

/* ----------------------------------------------------------------------
   Responsive design (全メディアクエリをまとめて管理)
---------------------------------------------------------------------- */

/* PC表示 (768px以上) */
@media (min-width: 768px) {
  body {
    background-color: #f5f5f5;
  }

  /* サイト全体を中央に配置し、境界線とシャドウを追加 */
  body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 430px;
    height: 100vh;
    background-color: #fff;
    border-left: 1px solid #e0e0e0;
    border-right: 1px solid #e0e0e0;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    z-index: -1;
    pointer-events: none;
  }

  /* ヘッダーとフッターの背景を透明にして境界線を表示 */
  .header,
  .footer {
    background-color: transparent;
  }

  /* フッターの背景色を再設定 */
  .footer {
    background-color: var(--secondary);
  }
}

/* 小さいスマホ (375px以下) */
@media (max-width: 375px) {
  .header {
    padding: 12px 16px;
    gap: 20px;
  }

  .btn-line__text {
    font-size: 1.2rem;
  }

  .contact-section {
    padding: 24px 16px 40px;
  }

  .footer {
    padding: 32px 16px 16px;
  }

  .contact-subtitle {
    font-size: 1.8rem;
  }

  .footer-logo h4 {
    font-size: 2rem;
  }
}

/* 非常に小さいスマホ (320px以下) */
@media (max-width: 320px) {
  .line-area {
    padding: 30px 0;
  }

  a.btn-line-normal span {
    font-size: 1.1rem;
  }
}
