:root {
  /* Design Tone: Trust & Professionalism x Local Warmth */
  /* Safe Green for Trust/Nature */
  --color-primary: #22AC38;
  /* Warm Wood/Earth for "Human Touch" */
  --color-accent: #D4A373;
  /* Deep Navy-Gray for Text/Structure */
  --color-secondary: #2C3E50;
  /* Clean White Base */
  --color-bg: #FFFFFF;
  /* Soft Off-white for sections */
  --color-bg-alt: #F9FAFB;

  --color-white: #ffffff;
  --color-text: #333333;
  --color-text-light: #555555;

  --font-main: 'Noto Sans JP', sans-serif;
  --font-serif: 'Noto Serif JP', serif;
  --font-accent: 'Outfit', sans-serif;

  --spacing-section: clamp(4rem, 10vw, 8rem);
  --container-width: 1200px;
  --transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.8;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4 {
  line-height: 1.4;
  font-weight: 700;
  color: var(--color-secondary);
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Utilities */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: var(--spacing-section) 0;
}

.bg-alt {
  background-color: var(--color-bg-alt);
}

.text-center {
  text-align: center;
}

.mb-5 {
  margin-bottom: 3rem;
}

.mt-5 {
  margin-top: 3rem;
}

.section-label {
  display: inline-block;
  font-family: var(--font-accent);
  color: var(--color-primary);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 2rem;
}

.grid {
  display: grid;
  gap: 4rem;
  align-items: flex-start;
  /* Changed from center to align text top */
}

.grid-3 {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

@media (min-width: 768px) {
  .grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  border-radius: 100px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  border: none;
}

.btn--primary {
  background-color: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 10px 30px rgba(58, 99, 81, 0.2);
}

.btn--primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(58, 99, 81, 0.3);
}

.btn--small {
  padding: 0.6rem 1.5rem;
  font-size: 0.875rem;
  background-color: var(--color-secondary);
  color: var(--color-white);
}

.btn--outline {
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
  background: transparent;
}

.btn--outline:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1.5rem 0;
  z-index: 1000;
  transition: var(--transition);
}

.header--scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 1rem 0;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header__logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-secondary);
}

.header__logo span {
  color: var(--color-primary);
}

.header__logo-img {
  height: 40px;
  width: auto;
  margin-right: 10px;
  vertical-align: middle;
}

.header__logo a {
  display: flex;
  align-items: center;
}

.header__nav ul {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.header__nav a:not(.btn) {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--color-secondary);
}

.header__nav a:hover {
  color: var(--color-primary);
}

/* Hero */
.hero {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding-top: 80px;
  background-image: url('public/philosophy_bg.jpg');
  background-size: cover;
  background-position: center;
  color: var(--color-white);
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(58, 99, 81, 0.75);
  z-index: 1;
}

.hero__content {
  max-width: 800px;
  text-align: center;
  z-index: 10;
}

.hero__title {
  color: var(--color-white);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  margin-bottom: 2rem;
  line-height: 1.2;
}

.hero__text {
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  color: rgba(255, 255, 255, 0.9);
}

.hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.hero__scroll-text {
  font-family: var(--font-accent);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.hero__scroll-line {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, var(--color-primary) 50%, transparent 50%);
  background-size: 100% 200%;
  animation: scrollLine 2s infinite;
}

@keyframes scrollLine {
  0% {
    background-position: 0 100%;
    opacity: 0;
  }

  20% {
    opacity: 1;
  }

  100% {
    background-position: 0 0%;
    opacity: 0;
  }
}

/* Strength Cards */
.strength-card {
  padding: 2.5rem;
  background-color: var(--color-white);
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
  text-align: center;
  border: 1px solid rgba(0, 0, 0, 0.03);
  transition: transform 0.3s;
}

.strength-card:hover {
  transform: translateY(-5px);
}

.strength-icon {
  margin-bottom: 1.5rem;
  color: var(--color-primary);
}

.strength-card h3 {
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

/* About Section */
.about {
  position: relative;
  padding: 8rem 0;
  background-color: var(--color-bg-alt);
}

.about>.container {
  position: relative;
  z-index: 1;
}

/* Text color overrides removed */

.about__message {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 3rem;
  line-height: 2;
  letter-spacing: 0.05em;
  padding: 2rem 0;
}

.rep-card {
  color: var(--color-secondary);
  background-color: var(--color-white);
  padding: 2rem;
  border-radius: 16px;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.reps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}

@media (min-width: 992px) {
  .reps-grid {
    grid-template-columns: 1fr 1fr;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
  }
}

.rep-img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid var(--color-white);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.rep-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rep-info h4 {
  font-size: 1.25rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
  text-align: center;
}

.rep-profile {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--color-text);
}

.about__partner {
  margin-top: 2rem;
  font-size: 0.95rem;
  color: var(--color-text);
  font-weight: 700;
}

.about__partner-highlight {
  display: inline-block;
  padding: 1.5rem 3rem;
  background-color: #fff;
  border: 2px solid var(--color-primary);
  border-radius: 100px;
  text-align: center;
  margin-top: 2rem;
  box-shadow: 0 4px 15px rgba(34, 172, 56, 0.1);
}

.about__partner-highlight a {
  color: var(--color-primary);
  text-decoration: underline;
}

/* Image stack styles removed */

/* Service Gov */
.service-header {
  max-width: 800px;
  margin: 0 auto 4rem;
}

.service-concept {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-top: 1rem;
}

.service-logic {
  background-color: var(--color-bg-alt);
  padding: 3rem;
  border-radius: 16px;
  text-align: center;
  margin-bottom: 3rem;
  border: 1px solid #eee;
}

.logic-img-container {
  margin: 2rem auto;
  max-width: 600px;
}

.logic-img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.service-logic h3 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.service-menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.menu-item {
  padding: 2rem;
  background-color: var(--color-white);
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
  border-left: 4px solid var(--color-primary);
}

.menu-item h4 {
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

/* Service Resident */
.service-card {
  padding: 2rem;
  background-color: var(--color-white);
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.service-card h3 {
  margin-bottom: 1rem;
  color: var(--color-accent);
}

/* Contact */
.contact-single {
  background-color: var(--color-bg-alt);
  padding: 4rem 2rem;
  border-radius: 20px;
  max-width: 800px;
  margin: 3rem auto 0;
  text-align: center;
}

.contact-desc {
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  line-height: 1.8;
  color: var(--color-text);
}

.contact-btn {
  min-width: 280px;
  padding: 1.2rem 3rem;
  font-size: 1.1rem;
}

.achievements .links a {
  display: inline-block;
  margin: 0 1rem;
  color: var(--color-text-light);
  font-weight: 500;
  border-bottom: 1px solid transparent;
}

.achievements .links a:hover {
  border-bottom-color: currentColor;
  color: var(--color-primary);
}

/* Footer */
.footer {
  background-color: var(--color-secondary);
  color: var(--color-white);
  padding: 4rem 0;
}

.footer__inner {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  align-items: center;
  text-align: center;
}

@media (min-width: 768px) {
  .footer__inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
    align-items: flex-start;
  }
}

.footer__logo {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.footer__links ul {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}

.copyright {
  font-size: 0.875rem;
  opacity: 0.6;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 1s forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__title .fade-in:nth-child(1) {
  animation-delay: 0.2s;
}

.hero__title .fade-in:nth-child(3) {
  animation-delay: 0.4s;
}

.hero__title .fade-in:nth-child(5) {
  animation-delay: 0.6s;
}

.hero__text {
  animation-delay: 0.8s;
}

.hero__actions {
  animation-delay: 1s;
}

/* Responsive Mobile */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

@media (max-width: 991px) {
  .header__nav {
    display: none;
  }

  .mobile-nav-toggle {
    display: block;
    width: 40px;
    height: 40px;
  }

  .mobile-nav-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-secondary);
    margin-bottom: 8px;
  }
}


/* Page Header */
.page-header {
  padding-top: 120px;
  padding-bottom: 3rem;
}

/* Works Page */
.section-subtitle {
  font-size: 1.5rem;
  border-left: 4px solid var(--color-primary);
  padding-left: 1rem;
  margin-bottom: 2rem;
}

.works-list,
.media-list {
  display: grid;
  gap: 1.5rem;
}

.work-item,
.media-item {
  background: var(--color-white);
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s;
}

.work-item:hover,
.media-item:hover {
  transform: translateX(5px);
}

.work-date,
.media-date {
  font-family: var(--font-accent);
  font-size: 0.9rem;
  color: var(--color-text-light);
  margin-bottom: 0.5rem;
}

.work-title,
.media-title {
  font-size: 1.1rem;
  font-weight: 500;
  line-height: 1.5;
}

.media-meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 0.5rem;
  align-items: center;
}

.media-name {
  font-size: 0.8rem;
  background-color: var(--color-bg-alt);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  color: var(--color-secondary);
  font-weight: 700;
}