/* --- Reset & Base Styles --- */
:root {
  --color-primary: #24c692; /* 明るい緑 */
  --color-primary-dark: #007a50;
  --color-primary-soft: #e5f8f1;
  --color-primary-muted: #64cfa9;
  --primary-green: #00B374; /* メインの緑 */
  --accent-brown: #cba876; /* ボタン等の茶色 */
  --text-dark: #333333;
  --text-gray: #666666;
  --bg-beige: #fbfbf8; /* 全体の背景色 */
  --card-bg: #ffffff;
  --font-main: "Noto Sans JP", sans-serif;
  --font-rounded: "Zen Maru Gothic", sans-serif;
}

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-beige);
  color: var(--text-dark);
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
  transition: opacity 0.3s;
}

a:hover {
  opacity: 0.8;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.sp {
    display: none;
}
@media screen and (max-width:768px) {
    .sp {
        display: block;
    }
}

/* --- Layout Utility --- */
.section {
  max-width: 1200px;
  margin: 0 auto 60px;
  padding: 0 20px;
}

/* --- Header --- */
.header {
  background-color: #fff; /* もしくは透明 */
  padding: 15px 0;
  position: absolute;
  width: 100%;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.9);
}

@media (max-width: 768px) {
  .header {
    position: relative;
  }
}

.header__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
}

.header__logo {
  font-family: var(--font-rounded);
  color: var(--primary-green);
  font-size: 1.2rem;
}

.header__logo img {
    display: inline;
    width: 30px;
    vertical-align: text-bottom;
    margin-right: 3px;
}

.header__nav ul {
  display: flex;
  gap: 20px;
}

.header__nav a {
  font-size: 1rem;
  color: var(--text-dark);
  font-weight: 500;
}

/* --- Hero Section --- */
.hero {
  position: relative;
  width: 100%;
  height: 750px;
  overflow: hidden;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .hero {
    height: 400px;
  }
}

.hero__bg {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
}

.hero__bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.08);
  animation: heroFade 14s infinite;
  will-change: opacity, transform;
}

.hero__bg img:nth-child(1) {
  animation-delay: 0s;
}

.hero__bg img:nth-child(2) {
  animation-delay: 7s;
}

@keyframes heroFade {
  0% {
    opacity: 0;
    transform: scale(1.1);
  }
  10% {
    opacity: 1;
    transform: scale(1.05);
  }
  45% {
    opacity: 1;
    transform: scale(1.01);
  }
  55% {
    opacity: 0;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(1);
  }
}

/* Waves */
.wave-top,
.wave-bottom,
.wave-footer {
  position: absolute;
  width: 100%;
  left: 0;
  line-height: 0;
}

.wave-top {
  top: 0;
  z-index: 1;
}

.wave-bottom {
  bottom: -1px;
}

.wave-footer {
  top: -72px;
  height: 100px;
  overflow: hidden;
}

.wave-footer svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* Hero Overlay Card */
.hero__content {
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: end;
  position: relative;
  z-index: 2;
}

.hero__card {
  background-color: rgba(0, 179, 116, 0.9);
  padding: 20px 40px;
  border-radius: 8px;
  color: #fff;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.hero__card h2 {
  font-family: var(--font-rounded);
  font-size: 1.8rem;
  margin-bottom: 5px;
}

.hero__card p {
  font-size: 1rem;
}

/* --- Headings --- */
.section-title {
  position: relative;
  display: inline-flex;
  align-items: center;
  font-family: var(--font-rounded);
  font-size: clamp(1.25rem, 1.1rem + 0.7vw, 1.6rem);
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--color-primary-dark);
  padding: 0.2rem 0 0.65rem 1rem;
  margin-bottom: 24px;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 110%;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    var(--primary-green) 0%,
    var(--color-primary) 45%,
    rgba(0, 179, 116, 0.15) 100%
  );
}

/* --- Pharmacy Grid (Main) --- */
.pharmacy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.pharmacy-card {
  background: var(--card-bg);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.card-header {
  background-color: #a78e72; /* デフォルト（茶系） */
  color: #fff;
  padding: 10px;
  text-align: center;
  font-family: var(--font-rounded);
  font-size: 1.1rem;
}
.card-header.brown {
  background-color: #a78e72;
}
.pharmacy-card:first-child .card-header {
  background-color: var(--color-primary-muted); /* 左側の緑ヘッダー */
}
.card-image img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.card-body {
  padding: 20px;
}

/* DL List Style */
.info-list {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 10px 15px;
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.info-list dt {
  font-weight: 700;
  color: var(--color-primary-dark);
}

@media (max-width: 768px) {
  .info-list {
    grid-template-columns: 1fr; /* ラベルと内容を縦積みに */
  }
  .info-list dt {
    margin-top: 10px;
  }
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  color: var(--color-primary-dark);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(0, 122, 80, 0.3);
  margin-top: 5px;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    opacity 0.2s ease;
}

.tag:hover,
.btn-board:hover {
  background-color: var(--color-primary-soft);
  border-color: rgba(0, 122, 80, 0.45);
  opacity: 1;
}

.tag:hover {
  transform: translateY(-1px);
}

.map-link-small {
  display: inline-block;
  background: #f0f0f0;
  border: 1px solid #ccc;
  padding: 2px 8px;
  font-size: 0.7rem;
  border-radius: 4px;
  margin-top: 5px;
}

/* Hours Table */
.hours-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  margin-top: 5px;
}
.hours-table th,
.hours-table td {
  border: 1px solid #eee;
  padding: 4px;
  text-align: center;
}
.hours-table th {
  background-color: #f9f9f9;
  color: var(--color-primary-dark);
}

/* Action Buttons */
.btn-map {
  display: block;
  width: 100%;
  background: linear-gradient(to right, #d4b585, #cba876);
  color: #fff;
  text-align: center;
  padding: 12px;
  border-radius: 50px;
  font-weight: bold;
  margin-top: 20px;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}

.card-note {
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-gray);
  margin-top: 10px;
}

/* Right Card Specifics */
.service-list {
  background-color: #f4f4f4;
  padding: 20px 20px 18px 30px;
  border-radius: 8px;
  margin-bottom: 20px;
}
.service-list p {
  font-weight: 500;
  margin-bottom: 10px;
}
.service-list li {
  font-size: 1rem;
  margin-bottom: 5px;
}
.service-link {
  color: var(--color-primary-dark);
  text-decoration: underline;
  text-underline-offset: 0.16em;
  text-decoration-thickness: 2px;
  font-weight: 700;
  transition:
    color 0.2s ease,
    opacity 0.2s ease;
}
.service-link:hover,
.service-link:focus-visible {
  color: var(--primary-green);
  opacity: 1;
}
.service-link:focus-visible {
  outline: 2px solid rgba(0, 122, 80, 0.35);
  outline-offset: 2px;
  border-radius: 2px;
}
.service-list li::before {
  content: "✔";
  color: var(--color-primary);
  margin-right: 12px;
}

.card-actions {
  display: grid;
  gap: 10px;
  margin-top: 8px;
}

.card-action-btn {
  display: block;
  width: 100%;
  text-align: center;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 700;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
}

.card-action-btn:hover {
  opacity: 1;
  transform: translateY(-1px);
}

.btn-line {
  color: #fff;
  background: linear-gradient(
    90deg,
    var(--primary-green) 0%,
    var(--color-primary) 100%
  );
  box-shadow: 0 4px 10px rgba(0, 179, 116, 0.25);
}

.btn-board {
  color: var(--color-primary-dark);
  background: #fff;
  border: 1px solid rgba(0, 122, 80, 0.3);
  box-shadow: 0 2px 8px rgba(0, 122, 80, 0.08);
}

@media (max-width: 768px) {
    .service-list {
        padding: 14px;
    }
}

@media (min-width: 769px) {
  .pharmacy-card {
    display: flex;
    flex-direction: column;
  }

  .pharmacy-card .card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
  }

  .hours-cell {
    min-height: 102px;
  }

  .service-list {
    min-height: 288px;
  }

  .card-actions {
    margin-top: auto;
  }
}

.board-list li {
  font-size: 1rem;
  margin-bottom: 5px;
}
.board-list li::before {
  content: "✔";
  color: var(--color-primary);
  margin-right: 10px;
}
.board-list li a:hover {
  color: var(--color-primary-dark);
}

.icon-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 20px;
}

.icon-box {
  background: #f4f1ea;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 10px 5px;
  flex: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 80px;
}

.icon-box i {
  font-size: 1.5rem;
  color: var(--accent-brown);
  margin-bottom: 5px;
}

.icon-box span {
  font-size: 0.7rem;
  line-height: 1.2;
  font-weight: bold;
  color: var(--text-dark);
}

/* --- Wide Card (Info) --- */
.wide-card {
  background: #fff;
  border-radius: 15px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.wide-card__content {
  flex: 1;
}

.wide-card__illustration {
  width: 150px;
  text-align: right;
}

/* --- News Section --- */
.news-section {
  position: relative;
}

.news-list {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
}

.news-list li {
  border-bottom: 1px solid #eee;
  padding: 10px 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.news-date {
  font-weight: bold;
  margin-right: 15px;
  font-size: 1rem;
}

.illustration-bottom {
  position: absolute;
  bottom: 0;
  right: 20px;
  width: 120px;
}

/* --- Contact Section --- */
.contact-section {
  position: relative;
  max-width: none;
  margin: 0;
  padding: 90px clamp(16px, 4vw, 40px) 120px;
  border-radius: 0;
  overflow: hidden;
  isolation: isolate;
  box-shadow: none;
}

.contact-section__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.contact-section__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contact-section::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    135deg,
    rgba(0, 122, 80, 0.48) 0%,
    rgba(0, 122, 80, 0.22) 52%,
    rgba(0, 0, 0, 0.28) 100%
  );
}

.contact-section__inner {
  max-width: 1080px;
  margin: 0 auto;
}

.contact-box .section-title {
  justify-content: center;
  width: 100%;
  color: var(--color-primary-dark);
  text-shadow: none;
  padding: 0.2rem 0 0.65rem;
  margin: 0 auto 20px;
}

.contact-box .section-title::after {
  left: 50%;
  width: min(260px, 94%);
  transform: translateX(-50%);
  background: linear-gradient(
    90deg,
    var(--primary-green) 0%,
    var(--color-primary) 45%,
    rgba(0, 179, 116, 0.15) 100%
  );
}

.contact-box {
  background: rgba(255, 255, 255, 0.94);
  border-radius: 14px;
  padding: 26px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(1.5px);
}

.contact-lead {
  margin-bottom: 18px;
  font-size: 1rem;
}

.contact-methods {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 14px;
}

.contact-method {
  background: rgba(247, 253, 251, 0.9);
  border: 1px solid rgba(0, 122, 80, 0.16);
  border-radius: 10px;
  padding: 16px;
}

.contact-method h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--color-primary-dark);
  font-family: var(--font-rounded);
  margin-bottom: 12px;
  font-size: 1.05rem;
}

.contact-method h4 i {
  color: var(--primary-green);
}

.contact-phone-list {
  display: grid;
  gap: 10px;
}

.contact-phone-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px dashed rgba(0, 122, 80, 0.22);
  padding-bottom: 8px;
}

.contact-phone-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.contact-phone-list span {
  color: var(--text-gray);
  font-size: 0.95rem;
}

.contact-phone-list a {
  color: var(--color-primary-dark);
  font-weight: 700;
  font-size: 1.08rem;
}

.contact-line-links {
  display: grid;
  gap: 10px;
}

.contact-note {
  font-size: 0.93rem;
  color: #4a4a4a;
}

.contact-note a {
  color: var(--color-primary-dark);
  text-decoration: underline;
  text-underline-offset: 0.14em;
}

@media (min-width: 769px) {
  .contact-lead,
  .contact-note {
    text-align: center;
  }

  .contact-lead {
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
  }
}

/* --- DX Section --- */
.dx-box {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  font-size: 1rem;
}

/* --- Footer --- */
.footer {
  background-color: var(--primary-green);
  color: #fff;
  padding: 80px 0 20px;
  position: relative;
}

.footer__content {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 0 20px 40px;
  position: relative;
}

.footer__tagline {
  font-size: 0.9rem;
  margin-bottom: 5px;
}

.footer__logo {
  font-family: var(--font-rounded);
  font-size: 1.4rem;
}

.footer__contact {
  font-size: 1rem;
}
.footer__contact p {
  margin-bottom: 5px;
}
.footer__contact i {
  margin-right: 8px;
}

.footer__illustration {
  position: absolute;
  right: 20px;
  bottom: 40px;
  width: 80px;
}

.copyright {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  padding-top: 20px;
  font-size: 0.8rem;
}

/* --- Responsive (Mobile) --- */
@media (max-width: 768px) {
  .header__inner {
    flex-direction: column;
    gap: 10px;
  }

  .pharmacy-grid {
    grid-template-columns: 1fr; /* 縦積み */
  }

  .contact-section {
    padding: 54px 14px 92px;
    border-radius: 0;
    margin-bottom: 0;
  }

  .contact-box .section-title {
    margin-bottom: 16px;
  }

  .contact-box {
    padding: 18px;
  }

  .contact-methods {
    grid-template-columns: 1fr;
  }

  .contact-method {
    padding: 14px;
  }

  .contact-phone-list li {
    flex-direction: column;
    align-items: flex-start;
  }

  .wide-card {
    flex-direction: column;
    align-items: flex-start;
  }

  .wide-card__illustration {
    width: 100px;
    align-self: flex-end;
    margin-top: -20px;
  }

  .footer__content {
    flex-direction: column;
    align-items: flex-start;
    gap: 30px;
  }

  .hero__card {
    width: 90%;
    padding: 15px;
  }

  .hero__card h2 {
    font-size: 1.4rem;
  }
}
