@charset "utf-8";
/* CSS Document */

.headache-tabs {
  max-width: 900px;
  margin: 0 auto;
  font-family: "Noto Sans JP", sans-serif;
	padding-bottom: 50px;
}

/* ===== PC（769px以上） ===== */
@media screen and (min-width: 769px) {
  .tab-menu {
    display: flex;
  flex-wrap: wrap;
  border-bottom: 2px solid #ccc;
  list-style: none;
  padding: 0;
  margin: 0;
  }
.tab-content {
  position: relative;
    /* min-height: 140px; */
    border-left: 1px solid #cccccc;
    border-right: 1px solid #cccccc;
    border-bottom: 1px solid #cccccc;
    margin: 0;
    padding: 20px;
    background: white;
}

  .tab-menu li {
    flex: 1;
    text-align: center;
    padding: 12px;
    cursor: pointer;
    background: #f7f7f7;
    border: 1px solid #ddd;
    border-bottom: none;
    transition: background 0.3s, color 0.3s;
    font-weight: bold;
  }

  .tab-menu li:hover {
    background: #eaeaea;
  }

  .tab-menu li.active {
    background: #1E5500;
    color: #fff;
    border-color: #1E5500;
  }

  .tab-item {
    display: none;
  }

  .tab-item.active {
    display: block;
    animation: fadeIn 0.4s ease;
	  padding: 0;
  }

  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
  }

  /* PCではアコーディオンの見出しデザインを隠す */
  .tab-title {
    display: none;
  }
}

/* ===== スマホ（768px以下） ===== */
@media screen and (max-width: 768px) {
  .tab-menu {
    display: none; /* スマホではタブ非表示 */
  }
.headache-tabs {
    margin: 0 10px;
}
  .tab-item {
    border: 1px solid #ddd;
    margin-bottom: 10px;
    border-radius: 6px;
    overflow: hidden;
	  padding: 0;
  }

  .tab-title {
    margin: 0;
    padding: 12px 15px;
    font-size: 16px;
    background: #f7f7f7;
    cursor: pointer;
    position: relative;
  }

  .tab-title::after {
    content: "＋";
    position: absolute;
    right: 15px;
    transition: transform 0.3s;
  }

  .tab-item.open .tab-title::after {
    content: "?";
  }

  .tab-content {
    display: none;
    padding: 12px 15px;
    background: #fff;
  }

  .tab-item.open .tab-content {
    display: block;
    animation: fadeSlide 0.3s ease;
  }

  @keyframes fadeSlide {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
  }
}
