/* ========================================
   MAKOTO NO AI — Design System
   Theme: 全ての人の幸福 (Happiness for All)
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500&family=Noto+Sans+JP:wght@300;400;500;700&family=Noto+Serif+JP:wght@400;500;700&display=swap');

/* --- CSS Variables --- */
:root {
  --bg-cream: #FDF8F0;
  --bg-warm: #F7F0E6;
  --text-primary: #2C2C2C;
  --text-secondary: #5A5A5A;
  --text-light: #8A8A8A;
  --accent-gold: #C4A265;
  --accent-gold-light: #D4B87A;
  --accent-green: #7B9E87;
  --accent-green-light: #A3C4AD;
  --dark-bg: #1A1A2E;
  --dark-bg-lighter: #252540;
  --highlight-rose: #E8D5C4;
  --white: #FFFFFF;
  --border-light: rgba(0,0,0,0.06);
  --shadow-soft: 0 4px 30px rgba(0,0,0,0.05);
  --shadow-card: 0 8px 40px rgba(0,0,0,0.08);
  --shadow-hover: 0 12px 50px rgba(0,0,0,0.12);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 40px;
  --transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --transition-slow: 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: 'Noto Sans JP', 'Inter', sans-serif;
  background-color: var(--bg-cream);
  color: var(--text-primary);
  line-height: 1.8;
  font-weight: 300;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

ul, ol { list-style: none; }

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: 'Noto Serif JP', serif;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.5rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }
h4 { font-size: clamp(1rem, 2vw, 1.2rem); }

.section-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 1rem;
  display: block;
}

/* --- Layout --- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem;
}

.container--narrow {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: 6rem 0;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 1.2rem 0;
  transition: var(--transition);
  background: transparent;
}

.nav.scrolled {
  background: rgba(253, 248, 240, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 20px rgba(0,0,0,0.04);
  padding: 0.8rem 0;
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem;
}

.nav__logo {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.05em;
}

.nav__logo span {
  color: var(--accent-gold);
}

.nav__links {
  display: flex;
  gap: 2.5rem;
  align-items: center;
}

.nav__link {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--text-secondary);
  position: relative;
  padding: 0.3rem 0;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--accent-gold);
  transition: var(--transition);
}

.nav__link:hover,
.nav__link.active {
  color: var(--text-primary);
}

.nav__link:hover::after,
.nav__link.active::after {
  width: 100%;
}

/* Hamburger */
.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 5px;
  z-index: 1001;
}

.nav__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition);
  border-radius: 2px;
}

.nav__hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav__hamburger.open span:nth-child(2) {
  opacity: 0;
}
.nav__hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero Section --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(170deg, var(--bg-cream) 0%, var(--bg-warm) 50%, var(--highlight-rose) 100%);
}

.hero__bg-image {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.15;
}

.hero__particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero__particle {
  position: absolute;
  width: 6px;
  height: 6px;
  background: var(--accent-gold);
  border-radius: 50%;
  opacity: 0;
  animation: float-up 8s infinite ease-in-out;
}

@keyframes float-up {
  0% { opacity: 0; transform: translateY(100vh) scale(0); }
  20% { opacity: 0.4; }
  80% { opacity: 0.2; }
  100% { opacity: 0; transform: translateY(-20vh) scale(1); }
}

.hero__content {
  position: relative;
  z-index: 2;
  max-width: 700px;
  padding: 0 2rem;
}

.hero__title {
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.hero__title em {
  font-style: normal;
  color: var(--accent-gold);
}

.hero__subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 3rem;
  font-weight: 300;
  line-height: 2;
}

.hero__scroll-hint {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-light);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  animation: gentle-bounce 3s infinite;
}

.hero__scroll-hint svg {
  width: 20px;
  height: 20px;
  stroke: var(--accent-gold);
}

@keyframes gentle-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 2.2rem;
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  transition: var(--transition);
  border: none;
  cursor: pointer;
  font-family: 'Noto Sans JP', sans-serif;
}

.btn--primary {
  background: var(--accent-gold);
  color: var(--white);
}

.btn--primary:hover {
  background: var(--accent-gold-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(196, 162, 101, 0.3);
}

.btn--outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-light);
}

.btn--outline:hover {
  border-color: var(--accent-gold);
  color: var(--accent-gold);
}

.btn--dark {
  background: var(--dark-bg);
  color: var(--white);
}

.btn--dark:hover {
  background: var(--dark-bg-lighter);
  transform: translateY(-2px);
}

/* --- Cards --- */
.card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 2.5rem;
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
  border: 1px solid var(--border-light);
}

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

.card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  font-size: 1.4rem;
}

.card__icon--gold { background: rgba(196, 162, 101, 0.12); color: var(--accent-gold); }
.card__icon--green { background: rgba(123, 158, 135, 0.12); color: var(--accent-green); }
.card__icon--rose { background: rgba(232, 213, 196, 0.3); color: var(--accent-gold); }

.card__title {
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.card__text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.9;
}

/* --- Grid Layouts --- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

/* --- Section Styles --- */
.section--dark {
  background: var(--dark-bg);
  color: var(--white);
}

.section--dark .section-label {
  color: var(--accent-gold-light);
}

.section--dark .card {
  background: var(--dark-bg-lighter);
  border-color: rgba(255,255,255,0.06);
}

.section--dark .card__text {
  color: rgba(255,255,255,0.6);
}

.section--warm {
  background: var(--bg-warm);
}

.section__header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 4rem;
}

.section__header p {
  margin-top: 1rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* --- Divider --- */
.divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-gold), var(--accent-green));
  margin: 2rem auto;
  border-radius: 2px;
}

.divider--left {
  margin-left: 0;
}

/* --- Image Section --- */
.img-text {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.img-text__image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.img-text__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-slow);
}

.img-text__image:hover img {
  transform: scale(1.03);
}

.img-text__content h2 {
  margin-bottom: 1.5rem;
}

.img-text__content p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

/* --- Content Cards (YouTube/Blog) --- */
.content-card {
  display: flex;
  gap: 1.5rem;
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border-light);
  transition: var(--transition);
  align-items: center;
}

.content-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
}

.content-card__thumb {
  width: 120px;
  min-width: 120px;
  height: 80px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-warm);
}

.content-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.content-card__info h4 {
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
}

.content-card__info p {
  font-size: 0.8rem;
  color: var(--text-light);
}

.content-card__tag {
  display: inline-block;
  font-size: 0.65rem;
  padding: 0.2rem 0.7rem;
  border-radius: var(--radius-xl);
  font-weight: 500;
  letter-spacing: 0.05em;
  margin-top: 0.5rem;
}

.content-card__tag--youtube {
  background: rgba(255, 0, 0, 0.08);
  color: #cc0000;
}

.content-card__tag--blog {
  background: rgba(123, 158, 135, 0.12);
  color: var(--accent-green);
}

/* --- Form --- */
.form {
  max-width: 600px;
  margin: 0 auto;
}

.form__group {
  margin-bottom: 1.5rem;
}

.form__label {
  display: block;
  font-size: 0.85rem;
  font-weight: 400;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}

.form__input,
.form__textarea {
  width: 100%;
  padding: 1rem 1.2rem;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 0.9rem;
  color: var(--text-primary);
  background: var(--white);
  transition: var(--transition);
  outline: none;
}

.form__input:focus,
.form__textarea:focus {
  border-color: var(--accent-gold);
  box-shadow: 0 0 0 3px rgba(196, 162, 101, 0.1);
}

.form__textarea {
  min-height: 160px;
  resize: vertical;
  line-height: 1.8;
}

.form__note {
  font-size: 0.78rem;
  color: var(--text-light);
  margin-top: 0.4rem;
}

/* --- Profile --- */
.profile {
  display: flex;
  gap: 3rem;
  align-items: flex-start;
}

.profile__avatar {
  width: 140px;
  min-width: 140px;
  height: 140px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-green));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--white);
  font-family: 'Noto Serif JP', serif;
}

.profile__info h3 {
  margin-bottom: 0.5rem;
}

.profile__info p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
}

/* --- Footer --- */
.footer {
  background: var(--dark-bg);
  color: rgba(255,255,255,0.5);
  padding: 3rem 0;
  text-align: center;
  font-size: 0.8rem;
}

.footer__logo {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.2rem;
  color: var(--white);
  margin-bottom: 0.5rem;
}

.footer a {
  color: var(--accent-gold-light);
}

.footer a:hover {
  color: var(--accent-gold);
}

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

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

.fade-in-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* --- Page Header (inner pages) --- */
.page-header {
  padding: 10rem 0 4rem;
  text-align: center;
  background: linear-gradient(170deg, var(--bg-cream) 0%, var(--bg-warm) 100%);
  position: relative;
}

.page-header__title {
  margin-bottom: 1rem;
}

.page-header__subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 500px;
  margin: 0 auto;
}

/* --- Blockquote --- */
.quote {
  position: relative;
  padding: 2rem 2rem 2rem 3rem;
  font-family: 'Noto Serif JP', serif;
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 2;
  font-style: italic;
}

.quote::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--accent-gold), var(--accent-green));
  border-radius: 3px;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .img-text { grid-template-columns: 1fr; gap: 2rem; }
  .profile { flex-direction: column; align-items: center; text-align: center; }
  section { padding: 4rem 0; }
}

@media (max-width: 768px) {
  .nav__links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%;
    height: 100vh;
    background: rgba(253, 248, 240, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
    transition: var(--transition);
    box-shadow: -10px 0 40px rgba(0,0,0,0.08);
  }

  .nav__links.open {
    right: 0;
  }

  .nav__hamburger {
    display: flex;
  }

  .nav__link {
    font-size: 1.1rem;
  }

  .hero { min-height: 90vh; }
  .hero__title { font-size: 2rem; }
  .content-card { flex-direction: column; }
  .content-card__thumb { width: 100%; height: 160px; }
}
