/* ==========================================================================
   Variables & Theme Defaults
   ========================================================================== */
:root {
  /* Colors - Farsher, brighter green theme */
  --primary-color: #B2D8B6;   /* Fresher mint green */
  --primary-light: #F2F9F2;   /* Cleaner, lighter background green */
  --secondary-color: #79B486; /* Clearer, more vibrant green */
  --accent-color: #6C8E72;    /* Kept for depth */
  --accent-hover: #5A785E;
  
  --text-dark: #5A5A5A;       /* Softer charcoal for a lighter feel */
  --text-light: #8A8A8A;      /* Lighter secondary text */
  --bg-color: #FFFFFF;        /* Clean pure white background */
  --white: #FFFFFF;

  /* Typography */
  --font-main: 'Zen Maru Gothic', 'Noto Sans JP', sans-serif;

  /* Styling values */
  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 32px;

  /* Shadows - More subtle & Airy */
  --shadow-sm: 0 4px 10px rgba(178, 216, 182, 0.08);
  --shadow-md: 0 8px 20px rgba(178, 216, 182, 0.12);
  --shadow-lg: 0 15px 40px rgba(178, 216, 182, 0.15);

  /* Transitions */
  --transition-fast: 0.3s ease;
  --transition-normal: 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

ul {
  list-style: none;
}

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

/* ==========================================================================
   Typography
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 500;
  line-height: 1.3;
}

.section-title {
  text-align: center;
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 3rem;
  position: relative;
  display: block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 3px;
  background-color: var(--primary-color);
  border-radius: var(--border-radius-sm);
}

/* ==========================================================================
   Layout Containers
   ========================================================================== */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

section {
  padding: 5rem 0;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
header {
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
  padding: 10px 0;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.logo-text {
  font-size: 1.15rem;
  font-weight: 500;
  font-family: var(--font-serif);
  color: var(--secondary-color);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.logo img {
  height: 50px;
  object-fit: contain;
  border-radius: 8px;
  /* In case the logo has sharp edges */
}

/* Desktop Navigation */
.nav-menu ul {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-menu li a {
  font-size: 1rem;
  font-weight: 500;
  position: relative;
  padding: 5px 0;
}

.nav-menu li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition-fast);
}

.nav-menu li a:hover::after,
.nav-menu li a.active::after {
  width: 100%;
}

.btn-contact {
  background: linear-gradient(135deg, var(--accent-color), #84A98C);
  color: var(--white);
  padding: 12px 28px;
  border-radius: var(--border-radius-lg);
  font-weight: 500;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 20px rgba(108, 142, 114, 0.25);
  transition: var(--transition-fast);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.btn-contact:hover {
  background: linear-gradient(135deg, var(--accent-hover), #6C8E72);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(108, 142, 114, 0.4);
}

.btn-contact::after {
  display: none;
}

/* Mobile Hamburger Menu */
.hamburger {
  display: none;
  cursor: pointer;
  flex-direction: column;
  gap: 6px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background-color: var(--text-dark);
  border-radius: 3px;
  transition: var(--transition-fast);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  padding-top: 120px;
  /* Account for fixed header */
  padding-bottom: 4rem;
  background: linear-gradient(135deg, var(--white) 0%, var(--primary-light) 100%);
  position: relative;
  overflow: hidden;
}

/* Soft shape decorations */
.hero::before,
.hero::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  z-index: 0;
}

.hero::before {
  width: 400px;
  height: 400px;
  background: rgba(163, 201, 168, 0.2);
  top: -100px;
  right: -100px;
  filter: blur(40px);
}

.hero::after {
  width: 300px;
  height: 300px;
  background: rgba(163, 201, 168, 0.15);
  bottom: -50px;
  left: -100px;
  filter: blur(40px);
}

.hero .container {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 4rem;
}

.hero-content {
  flex: 1;
}

.hero-image {
  flex: 1;
  position: relative;
}

.hero-image img {
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
  object-fit: cover;
}

.hero-title {
  font-size: 2.5rem;
  color: var(--secondary-color);
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.hero-text {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: var(--text-dark);
}

/* ==========================================================================
   News Section
   ========================================================================== */
.news-banner {
  background-color: var(--white);
  padding: 1.5rem 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.news-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}

.news-date {
  color: var(--primary-color);
  font-weight: 500;
  font-size: 0.95rem;
  padding-right: 1.5rem;
  border-right: 1px solid var(--primary-light);
}

/* ==========================================================================
   Treatment Flow Section
   ========================================================================== */
.flow {
  background-color: var(--bg-color);
}

.flow-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
  justify-items: center;
  /* Center cards within grid cells if they aren't full width */
}

.flow-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--border-radius-md);
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  position: relative;
  transition: var(--transition-fast);
  height: 100%;
  width: 100%;
  /* Ensure it spans the grid cell */
  max-width: 320px;
  /* Prevent it from getting too wide to maintain the centered look */
  display: flex;
  flex-direction: column;
  align-items: center;
  /* Center children horizontally */
}

.flow-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.flow-step-num {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: bold;
  box-shadow: 0 4px 6px rgba(163, 201, 168, 0.4);
}

.flow-card h3 {
  font-size: 1.3rem;
  color: var(--secondary-color);
  margin-top: 1.5rem;
  margin-bottom: 1rem;
}

.flow-card p {
  color: var(--text-dark);
  font-size: 0.95rem;
  flex-grow: 1;
  text-align: center;
  width: 100%;
  /* Ensure text block takes full width to center text properly */
}

.flow-summary {
  background: linear-gradient(135deg, var(--white) 0%, var(--primary-light) 100%);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--border-radius-md);
  padding: 2.5rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  box-shadow: var(--shadow-sm);
}

.flow-time {
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.flow-message {
  font-size: 1.1rem;
}

/* ==========================================================================
   Owner's Message Section
   ========================================================================== */
.message {
  background-color: var(--white);
  position: relative;
}

.message-card {
  background: linear-gradient(to right bottom, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.3));
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: var(--shadow-lg);
  border-radius: var(--border-radius-md);
  padding: 4rem;
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 1;
}

/* Decorative leaf pattern background could be added here */
.message::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 10% 20%, rgba(163, 201, 168, 0.1) 0%, transparent 20%),
    radial-gradient(circle at 90% 80%, rgba(163, 201, 168, 0.1) 0%, transparent 20%);
  z-index: 0;
}

.quote-icon {
  font-size: 3rem;
  color: var(--primary-light);
  margin-bottom: 1rem;
  line-height: 1;
}

.message-text {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-dark);
  margin-bottom: 2rem;
  font-style: italic;
}

.message-author {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.author-name {
  font-size: 1.5rem;
  color: var(--secondary-color);
  font-weight: 500;
}

.author-title {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
footer {
  background-color: #2D3A31;
  /* Even darker, sophisticated forest green */
  color: var(--white);
  padding: 5rem 0 3rem;
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(163, 201, 168, 0.5), transparent);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.5rem;
  margin-bottom: 4rem;
}

.footer-logo {
  font-size: 1.8rem;
  font-family: var(--font-serif);
  letter-spacing: 0.1em;
  color: var(--accent-color);
}

.footer-nav ul {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-nav a {
  color: rgba(255, 255, 255, 0.8);
}

.footer-nav a:hover {
  color: var(--white);
}

.copyright {
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
}

/* ==========================================================================
   Animations
   ========================================================================== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.appear {
  opacity: 1;
  transform: translateY(0);
}

/* Add delays for grid items */
.flow-card:nth-child(1) {
  transition-delay: 0.1s;
}

.flow-card:nth-child(2) {
  transition-delay: 0.2s;
}

.flow-card:nth-child(3) {
  transition-delay: 0.3s;
}

.flow-card:nth-child(4) {
  transition-delay: 0.4s;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */
@media (max-width: 900px) {
  .hero .container {
    flex-direction: column;
    text-align: center;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 80px;
    /* Header height */
    left: -100%;
    width: 100%;
    height: calc(100vh - 80px);
    background-color: var(--white);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
    box-shadow: 0 10px 10px rgba(0, 0, 0, 0.05);
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-menu ul {
    flex-direction: column;
    gap: 2rem;
  }

  section {
    padding: 3rem 0;
  }

  .message-card {
    padding: 2rem;
  }
}

@media (max-width: 480px) {
  .logo-text {
    font-size: 1rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .news-item {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }

  .news-date {
    border-right: none;
    border-bottom: 1px solid var(--primary-light);
    padding-right: 0;
    padding-bottom: 0.5rem;
  }
}

/* ==========================================================================
   Floating LINE Button
   ========================================================================== */
.floating-line-wrapper {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

.line-tooltip {
  background-color: #ff6b6b; /* attention color */
  color: #fff;
  font-size: 0.9rem;
  font-weight: bold;
  padding: 8px 14px;
  border-radius: 20px;
  position: relative;
  box-shadow: 0 4px 8px rgba(255, 107, 107, 0.3);
  animation: bounce 2s infinite;
  white-space: nowrap;
  margin-right: -4px;
}

.line-tooltip::after {
  content: '';
  position: absolute;
  bottom: -6px;
  right: 28px;
  border-width: 6px 6px 0;
  border-style: solid;
  border-color: #ff6b6b transparent transparent transparent;
}

.floating-line-btn {
  background-color: #06C755;
  color: #fff;
  width: 68px;
  height: 68px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 6px 15px rgba(6, 199, 85, 0.4);
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.floating-line-btn:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 8px 20px rgba(6, 199, 85, 0.5);
  color: #fff;
}

.floating-line-btn svg {
  width: 40px;
  height: 40px;
  fill: currentColor;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-10px);
  }
  60% {
    transform: translateY(-5px);
  }
}

@media (max-width: 480px) {
  .floating-line-wrapper {
    bottom: 20px;
    right: 20px;
    gap: 10px;
  }
  .floating-line-btn {
    width: 60px;
    height: 60px;
  }
  .floating-line-btn svg {
    width: 36px;
    height: 36px;
  }
  .line-tooltip {
    font-size: 0.85rem;
    padding: 6px 12px;
    margin-right: -2px;
  }
  .line-tooltip::after {
    right: 24px;
  }
}
