/*
Theme: Peace Stress Care Clinic (仮称)
Description: Basic styles for the Peace Stress Care Clinic website. This stylesheet defines a clean, calming look with soft colors, modern typography and responsive layouts. It is designed with accessibility and medical advertising guidelines in mind: clear headings, ample white space and easily readable text.  The colors convey a sense of calm and trust.
*/

/* Variables */
:root {
  --color-primary: #2e6d7c; /* deep teal for headings and accents */
  --color-secondary: #9dc5c8; /* light teal for backgrounds and highlights */
  --color-accent: #f5a623; /* warm accent color for buttons */
  --color-background: #f7fbfc; /* very light gray-blue background */
  --color-text: #2f2f2f; /* dark gray for main text */
  --color-muted: #6b7b7e; /* muted text color */
  --font-sans: 'Noto Sans JP', sans-serif;
  --max-width: 1100px;
  --color-light: #ffffff; /* white for backgrounds and cards */
}

/* Global styles */
html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-background);
}

/* Container */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

/* Navigation */
header {
  background-color: #ffffff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* Top bar above the navigation for contact info */
.top-bar {
  background-color: var(--color-secondary);
  color: var(--color-primary);
  font-size: 0.875rem;
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  /* Prevent the phone and button from wrapping onto multiple lines */
  flex-wrap: nowrap;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  /* Keep the phone number text on one line */
  white-space: nowrap;
}

.small-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.small-btn {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  border-radius: 0.375rem;
  background-color: var(--color-accent);
  color: #fff;
  text-decoration: none;
}

.small-btn:hover,
.small-btn:focus {
  background-color: #d88a1c;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 0;
}

.navbar .logo {
  /* Reduce size slightly to help fit alongside the navigation on a single line */
  font-size: 1.25rem;
  color: var(--color-primary);
  font-weight: bold;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.navbar ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  /* Allow navigation items to wrap onto multiple rows on wide screens. */
  flex-wrap: wrap;
  /* Provide both row and column spacing for wrapped items. */
  gap: 0.5rem 1.5rem;
}

/* Navigation link styling */
.navbar a {
  text-decoration: none;
  color: var(--color-text);
  font-weight: 500;
  transition: color 0.2s ease;
  /* Prevent the text from wrapping onto multiple lines.  This ensures each navigation item remains on a single line even when the menu wraps across rows. */
  white-space: nowrap;
}

.navbar a:hover,
.navbar a:focus {
  color: var(--color-primary);
}

/* Hero Section */
.hero {
  background: linear-gradient(180deg, var(--color-secondary) 0%, var(--color-background) 100%);
  padding: 4rem 0;
  /* layout is defined by .hero-content */
  position: relative;
}

/* Layout for hero content: split into text and image */
.hero-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.5rem;
  color: var(--color-primary);
  margin: 0 0 1rem;
}

.hero-text p {
  font-size: 1.125rem;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

.hero-image img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}


.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--color-accent);
  color: #fff;
  border-radius: 0.375rem;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.2s ease;
}

.btn:hover,
.btn:focus {
  background-color: #d88a1c;
}

/* Outline style button */
.outline-btn {
  background-color: transparent;
  color: var(--color-accent);
  border: 2px solid var(--color-accent);
}

.outline-btn:hover,
.outline-btn:focus {
  background-color: var(--color-accent);
  color: #fff;
}

/* Sections */
section {
  padding: 3rem 0;
}

section h2 {
  font-size: 1.75rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
  position: relative;
}

section h2::after {
  content: '';
  width: 60px;
  height: 3px;
  background-color: var(--color-accent);
  display: block;
  margin-top: 0.25rem;
}

section p {
  max-width: 750px;
  margin-bottom: 1.5rem;
  color: var(--color-muted);
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.feature {
  background-color: #fff;
  padding: 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.feature h3 {
  margin-top: 0;
  font-size: 1.25rem;
  color: var(--color-primary);
}

/* Icon styling */
.icon {
  width: 48px;
  height: 48px;
  margin-bottom: 0.75rem;
  color: var(--color-primary);
}

.icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.feature p {
  margin-bottom: 0;
  color: var(--color-muted);
}

/* Schedule table & contact box */
.schedule-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 1.5rem;
}

.schedule-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 600px;
  background-color: #fff;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.schedule-table th,
.schedule-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #eaeaea;
  text-align: center;
  font-size: 0.875rem;
}

.schedule-table thead th {
  background-color: var(--color-secondary);
  color: var(--color-primary);
  font-weight: bold;
  font-size: 0.875rem;
}

.schedule-table tbody td {
  color: var(--color-muted);
}

.schedule-table tbody tr:last-child td {
  border-bottom: none;
}

.contact-box {
  flex: 1;
  background-color: #fff;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 250px;
}

.contact-box p {
  margin: 0.5rem 0;
  color: var(--color-muted);
  text-align: center;
}

.contact-box .big-phone {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

/* Call-to-action section used on the top page */
.cta {
  background-color: var(--color-secondary);
  padding: 3rem 0;
  text-align: center;
}

.cta h2 {
  font-size: 1.75rem;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

.cta p {
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.cta-buttons .btn {
  margin-bottom: 0.5rem;
}

/* CTA Section */
.cta-section {
  background-color: var(--color-secondary);
  padding: 3rem 0;
  text-align: center;
}

.cta-section h2 {
  margin-bottom: 1rem;
  color: var(--color-primary);
}

.cta-buttons {
  margin-top: 1.5rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Footer */
footer {
  background-color: #ffffff;
  border-top: 1px solid #e5e5e5;
  padding: 2rem 0;
  color: var(--color-muted);
  font-size: 0.875rem;
}

footer .footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

footer h4 {
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: var(--color-primary);
  font-size: 1rem;
}

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

footer a {
  text-decoration: none;
  color: var(--color-muted);
  transition: color 0.2s ease;
}

footer a:hover {
  color: var(--color-primary);
}

/* Doctor section styling */
.doctor-section {
  background-color: var(--color-secondary);
  color: var(--color-primary);
  text-align: center;
  padding: 3rem 0;
}
.doctor-section p {
  max-width: 800px;
  margin: 0 auto;
  color: var(--color-text);
  line-height: 1.7;
}

/* FAQ section styling */
.faq-section {
  background-color: #fff;
  padding: 3rem 0;
}
.faq-list dt {
  font-weight: 600;
  color: var(--color-primary);
  margin-top: 1.5rem;
}
.faq-list dd {
  margin-left: 0;
  margin-bottom: 1rem;
  color: var(--color-muted);
}

/* Convenience services section */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.service-card {
  background-color: #fff;
  padding: 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
.service-card .service-number {
  width: 48px;
  height: 48px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  background-color: var(--color-secondary);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
}

/* Steps section */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.step {
  background-color: #fff;
  padding: 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.step:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
.step-number {
  width: 48px;
  height: 48px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  background-color: var(--color-secondary);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
}

/* Gallery section */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}
.gallery img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* Map container */
.map-container {
  margin-top: 2rem;
  display: flex;
  justify-content: center;
}
.map-container img {
  width: 100%;
  max-width: 600px;
  height: auto;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* Responsive Typography */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  .hero p {
    font-size: 1rem;
  }
  .navbar ul {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
}

/* Banner for first‑time visitors */
.first-banner {
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.25rem 0.75rem;
  background-color: var(--color-accent);
  color: #fff;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
}

.first-banner a {
  color: #fff;
  text-decoration: none;
}

.first-banner a:hover,
.first-banner a:focus {
  text-decoration: underline;
}

/* Tagline styling */
.tagline {
  font-size: 1.2rem;
  color: var(--color-primary);
  margin-top: 0.5rem;
  margin-bottom: 1rem;
  line-height: 1.5;
}

/* Wave decoration below hero */
.wave {
  width: 100%;
  height: 80px;
  background: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxNDQwIDMyMCI+PHBhdGggZmlsbD0iI2Y3ZmJmYyIgZD0iTTAsOTZMNjAsOTZDMTIwLDk2LDI0MCw5NiwzNjAsMTIyLjdDNDgwLDE0OSw2MDAsMjAzLDcyMCwyMDhDODQwLDIxMyw5NjAsMTcxLDEwODAsMTU0LjdDMTIwMCwxMzksMTMyMCwxNDksMTM4MCwxNTQuN0wxNDQwLDE2MFYzMjBIMTM4MEMxMzIwLDMyMCwxMjAwLDMyMCwxMDgwLDMyMEM5NjAsMzIwLDg0MCwzMjAsNzIwLDMyMEM2MDAsMzIwLDQ4MCwzMjAsMzYwLDMyMEMyNDAsMzIwLDEyMCwzMjAsNjAsMzIwSDBaIj48L3BhdGg+PC9zdmc+") no-repeat bottom center;
  background-size: cover;
  position: absolute;
  bottom: -1px;
  left: 0;
}

/* Troubles section styling */
.troubles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.trouble-card {
  background-color: #fff;
  padding: 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.trouble-card h3 {
  margin-top: 0;
  color: var(--color-primary);
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
}

.trouble-card ul {
  margin: 0;
  padding-left: 1.25rem;
  color: var(--color-muted);
  line-height: 1.5;
}

.trouble-card ul li {
  margin-bottom: 0.5rem;
  list-style: disc;
}

/* Cards for each disorder on the services page */
.conditions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.condition-card {
  background-color: #fff;
  padding: 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.condition-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  color: var(--color-primary);
  font-size: 1.3rem;
}

.condition-card p {
  flex-grow: 1;
  color: var(--color-muted);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.condition-card a.btn {
  align-self: flex-start;
}

/* Responsive navigation (hamburger menu) */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  margin-left: auto;
}

.menu-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background-color: var(--color-primary, #333);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-toggle.open span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

@media (max-width: 768px) {
  .navbar {
    position: relative;
  }
  .navbar nav {
    position: absolute;
    top: 100%;
    right: 0;
    width: 100%;
    background-color: #ffffff;
    border-top: 1px solid #e5e5e5;
    display: none;
    flex-direction: column;
    padding: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    z-index: 10;
  }
  .navbar nav.open {
    display: flex;
  }
  .navbar nav ul {
    flex-direction: column;
    gap: 0;
  }
  .navbar nav ul li {
    margin-bottom: 0.5rem;
  }
  .menu-toggle {
    display: flex;
  }
  .navbar .logo {
    flex-grow: 1;
  }
}