/* ==========================================================================
   Variables
   ========================================================================== */
:root {
  /* Colors */
  --color-white: #ffffff;
  --color-black: #303030;
  --color-text: #1d1d1d;
  --color-base: #e9e9e9;
  --color-border: #e6e6e6;
  --color-gray: #7c7c7c;

  /* Fonts */
  --font-japanese: "Zen Kaku Gothic Antique", sans-serif;
  --font-english: "Inter", sans-serif;

  /* Spacing */
  --spacing-xs: 8px;
  --spacing-sm: 16px;
  --spacing-md: 24px;
  --spacing-lg: 32px;
  --spacing-xl: 48px;
  --spacing-2xl: 64px;
  --spacing-3xl: 80px;
  --spacing-4xl: 112px;
  --spacing-5xl: 128px;

  /* Breakpoints */
  --bp-mobile: 375px;
  --bp-tablet: 768px;
  --bp-desktop: 1024px;
  --bp-wide: 1440px;
}

/* ==========================================================================
   Base Styles
   ========================================================================== */
html {
  overflow-x: hidden;
  width: 100%;
}

body {
  overflow-x: hidden;
  width: 100%;
  margin: 0;
  padding: 0;
  font-family: var(--font-japanese);
  color: var(--color-text);
  font-size: 16px;
  line-height: 1.7;
}

img,
svg,
iframe {
  max-width: 100%;
}

/* ==========================================================================
   Header
   ========================================================================== */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 40px 64px;
  background: var(--color-white);
  position: relative;
  z-index: 1000;
}

.header__logo {
  flex-shrink: 0;
}

.logo {
  width: 108px;
  max-width: 100%;
  height: 40px;
}

.header__nav {
  display: flex;
  gap: 28px;
  align-items: center;
}

.header__nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-family: var(--font-japanese);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0.04em;
  color: var(--color-text);
  transition: opacity 0.3s;
}

.header__nav-item:hover {
  opacity: 0.7;
}

.header__nav-plus {
  width: 12px;
  height: 12px;
  position: relative;
  flex-shrink: 0;
}

.header__nav-plus::before,
.header__nav-plus::after {
  content: "";
  position: absolute;
  background: var(--color-black);
}

.header__nav-plus::before {
  width: 1px;
  height: 12px;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
}

.header__nav-plus::after {
  width: 12px;
  height: 1px;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
}

.header__nav-wrapper {
  position: relative;
}

.header__dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 8px;
  background: var(--color-base);
  border-radius: 8px;
  padding: 24px;
  gap: 12px;
  min-width: 250px;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.header__dropdown.active {
  display: flex;
  flex-direction: column;
}

.header__dropdown-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--color-border);
}

.header__dropdown-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.header__dropdown-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-family: var(--font-japanese);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.7;
  letter-spacing: 0.04em;
  color: var(--color-black);
  cursor: pointer;
}

.header__dropdown-title svg {
  flex-shrink: 0;
}

.header__dropdown-sub {
  display: flex;
  flex-direction: column;
  padding-left: 16px;
}

.header__dropdown-subitem {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-japanese);
  font-weight: 500;
  font-size: 14px;
  line-height: 1.7;
  letter-spacing: 0.04em;
  color: var(--color-black);
}

.header__dropdown-subitem svg:first-child {
  flex-shrink: 0;
}

.header__dropdown-link {
  display: flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: inherit;
}

.header__dropdown-link:hover {
  opacity: 0.7;
}

.header__menu-toggle {
  display: none;
}

/* ==========================================================================
   Main Visual
   ========================================================================== */
.mv {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 100vw;
  background: url("../images/mv_bg.png") center/cover no-repeat;
}

.mv__tagline {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 46px;
  padding: 24px 72px;
  height: 789px;
  width: auto;
  background: rgba(255, 255, 255, 0.7);
}

.mv__tagline-ja {
  font-family: var(--font-japanese);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.7;
}

.mv__tagline-en {
  font-family: var(--font-english);
  font-weight: 300;
  font-size: 120px;
  line-height: 1;
  letter-spacing: -0.04em;
  max-width: 100%;
  word-break: break-word;
}

/* ==========================================================================
   Section Blocks
   ========================================================================== */
.sec-block {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

.sec-block--projects {
  background: var(--color-base);
  padding: var(--spacing-5xl) 0 280px;
  overflow-x: hidden;
}

.sec-block--company {
  background: var(--color-white);
  padding: var(--spacing-2xl) 0 40px;
  position: relative;
  border-radius: 60px 60px 0 0;
  margin-top: -80px;
  overflow-x: hidden;
}

.container {
  max-width: 1360px;
  width: 100%;
  margin: 0 auto;
  padding: 0 40px;
  box-sizing: border-box;
  overflow-x: hidden;
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-4xl);
}

.section-title {
  font-family: var(--font-english);
  font-weight: 300;
  font-size: 72px;
  line-height: 1.7;
  color: var(--color-text);
}

.section-subtitle {
  font-family: var(--font-japanese);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.7;
  color: var(--color-text);
}

/* ==========================================================================
   Projects
   ========================================================================== */
.projects {
  display: flex;
  flex-direction: column;
  gap: 160px;
}

.project {
  width: 100%;
}

.project--main {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.project__image {
  width: 100%;
  overflow: hidden;
}

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

.project--main .project__image {
  height: 660px;
}

.project__content {
  display: flex;
  justify-content: space-between;
  gap: var(--spacing-4xl);
  padding: 0 48px;
}

.project__text {
  display: flex;
  gap: var(--spacing-4xl);
}

.project__header {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-right: 40px;
  min-width: 308px;
}

.project__category {
  font-family: var(--font-japanese);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.7;
  color: var(--color-text);
}

.project__title {
  font-family: var(--font-japanese);
  font-weight: 700;
  font-size: 42px;
  line-height: 1.7;
  color: var(--color-text);
}

.project__services {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-item {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.service-item__bullet {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-text);
  margin-top: 10px;
  flex-shrink: 0;
}

.service-item__text {
  font-family: var(--font-japanese);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.7;
  color: var(--color-text);
}

.service-item--link {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  flex: 1;
  text-decoration: none;
  color: inherit;
}

.service-item__arrow {
  margin-left: auto;
  color: var(--color-text);
  font-size: 18px;
}

/* Button */
.btn {
  display: inline-flex;
  align-items: stretch;
  background: var(--color-black);
  border-radius: 4px;
  overflow: hidden;
  transition: opacity 0.3s;
  align-self: flex-end;
}

.btn:hover {
  opacity: 0.8;
}

.btn__text {
  padding: 20px 24px;
  font-family: var(--font-english);
  font-weight: 500;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-white);
}

.btn__arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 4px;
  color: var(--color-white);
  border-left: 1px solid rgba(255, 255, 255, 0.3);
  min-width: 40px;
}

/* Secondary Projects */
.projects__secondary {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.project--secondary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

.project__content--white {
  background: var(--color-white);
  padding: 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 44px;
}

.project__top {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.project--secondary .project__header {
  min-width: auto;
  padding-right: 0;
}

.project__description {
  font-family: var(--font-japanese);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
}

.service-item--compact {
  gap: 8px;
}

.service-item--compact .service-item__text {
  font-size: 18px;
}

/* Detailed Service Items */
.project__services--detailed {
  padding-top: 16px;
}

.service-item--detailed {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.service-item__header {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.service-item__detail {
  font-family: var(--font-japanese);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.7;
  color: var(--color-text);
  margin-top: 4px;
  padding-left: 20px;
}

/* ==========================================================================
   Company
   ========================================================================== */
.company {
  display: grid;
  grid-template-columns: minmax(0, 680px) 1fr;
  gap: 96px;
  margin-bottom: var(--spacing-4xl);
}

.company__map {
  width: 100%;
  height: 464px;
  overflow: hidden;
  border-radius: 8px;
}

.company__map img,
.company__map iframe {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.company__outline {
  padding-right: 56px;
}

.outline-list {
  display: flex;
  flex-direction: column;
}

.outline-item {
  display: flex;
  gap: 24px;
  padding: 18px 0;
  border-bottom: 1px solid var(--color-border);
}

.outline-item__label {
  font-family: var(--font-japanese);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.7;
  letter-spacing: 0.04em;
  color: var(--color-text);
  min-width: 130px;
  flex-shrink: 0;
}

.outline-item__value {
  font-family: var(--font-japanese);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  flex: 1;
}

.email-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  display: flex;
  flex-direction: column;
  gap: -2px;
  background: var(--color-white);
}

.footer__logo {
  padding-left: 40px;
  max-width: 100%;
  overflow: hidden;
}

.logo--large {
  width: 100%;
  max-width: 553px;
  height: auto;
}

.footer__copy {
  background: var(--color-black);
  padding: 24px 40px;
  display: flex;
  justify-content: flex-end;
}

.footer__copy p {
  font-family: var(--font-english);
  font-weight: 300;
  font-size: 14px;
  line-height: 1.7;
  color: var(--color-base);
}

/* ==========================================================================
   Responsive Design - Tablet
   ========================================================================== */
@media (max-width: 1024px) {
  .header {
    padding: 32px 40px;
  }

  .mv__tagline-en {
    font-size: 80px;
  }

  .sec-block--projects {
    padding: 80px 0 160px;
  }

  .container {
    padding: 0 32px;
  }

  .section-title {
    font-size: 56px;
  }

  .projects {
    gap: 120px;
  }

  .project--main {
    gap: 60px;
  }

  .project__content {
    flex-direction: column;
    padding: 0 32px;
    gap: 40px;
  }

  .project__text {
    flex-direction: column;
    gap: 32px;
  }

  .project__header {
    min-width: auto;
    padding-right: 0;
  }

  .project--secondary {
    grid-template-columns: 1fr;
  }

  .project__content--white {
    padding: 60px;
    order: 2;
  }

  .project__image {
    order: 1;
  }

  .company {
    grid-template-columns: 1fr;
    gap: 60px;
  }

  .company__map {
    height: 400px;
  }

  .company__outline {
    padding-right: 0;
  }

  .logo--large {
    width: 400px;
    height: 161px;
  }
}

/* PC用のドロップダウン */
@media (min-width: 769px) {
  .header__dropdown--sp {
    display: none !important;
  }

  .header__dropdown--pc {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 8px;
    background: var(--color-base);
    border-radius: 8px;
    padding: 24px;
    gap: 12px;
    min-width: 250px;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  }

  .header__dropdown--pc.active {
    display: flex;
    flex-direction: column;
  }

  .header__nav-wrapper {
    position: relative;
  }

  .header__dropdown--pc .header__dropdown-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0;
  }

  .header__dropdown--pc .header__dropdown-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-bottom: 12px;
    border-bottom: 1px dashed var(--color-border);
  }

  .header__dropdown--pc .header__dropdown-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
  }

  .header__dropdown--pc .header__dropdown-item--parent {
    padding-bottom: 12px;
  }
}

/* ==========================================================================
   Responsive Design - Mobile
   ========================================================================== */
@media (max-width: 768px) {
  .header {
    padding: 24px 24px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2000;
  }

  .logo {
    width: 80px;
    height: 30px;
  }

  .header__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--color-white);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 20px 24px;
  }

  .header__nav.active {
    display: flex;
  }

  .header__nav-item {
    width: 100%;
    padding: 16px 0;
    border-bottom: 1px solid var(--color-border);
  }

  .header__dropdown--pc {
    display: none !important;
  }

  .header__dropdown--sp {
    display: none;
    position: fixed;
    top: 78px;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0;
    border-radius: 0;
    padding: 32px 32px 48px;
    max-width: 100%;
    min-width: 100%;
    overflow-y: auto;
    background: var(--color-base);
    z-index: 1500;
  }

  .header__dropdown--sp.active {
    display: block;
  }

  .header__dropdown--sp .header__dropdown-item {
    padding: 12px 0px;
    border-bottom: none;
  }

  .header__dropdown--sp .header__dropdown-item--parent {
    border-bottom: 1px dashed var(--color-border);
    padding-bottom: 16px;
  }

  .header__dropdown-top {
    padding: 16px 0;
    border-bottom: 1px dashed var(--color-border);
    margin-bottom: 0;
  }

  .header__dropdown-top-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-japanese);
    font-weight: 700;
    font-size: 16px;
    line-height: 1.7;
    letter-spacing: 0.04em;
    color: var(--color-black);
  }

  .header__dropdown-bottom {
    padding: 16px 0;
    border-bottom: 1px dashed var(--color-border);
  }

  .header__dropdown-bottom .header__dropdown-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .header__dropdown--sp .header__dropdown-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 0 16px 24px;
  }

  .header__menu-toggle {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 30px;
    height: 24px;
    justify-content: center;
  }

  .header__menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--color-black);
    transition: all 0.3s;
  }

  .header__menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .header__menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .header__menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  body {
    padding-top: 78px;
  }

  .mv {
    height: auto;
  }

  .mv__tagline {
    justify-content: flex-end;
    align-items: stretch;
    height: auto;
    padding: 28px 24px;
    gap: 24px;
    background: rgba(255, 255, 255, 0.6);
  }

  .mv__tagline-ja {
    font-size: 14px;
    line-height: 1.2;
    width: 14px;
  }

  .mv__tagline-en {
    font-size: 58px;
    line-height: 1;
    letter-spacing: -0.04em;
  }

  .sec-block--projects {
    padding: 64px 0 120px;
  }

  .container {
    padding: 0 20px;
  }

  .section-header {
    margin-bottom: 60px;
  }

  .section-title {
    font-size: 48px;
  }

  .section-subtitle {
    font-size: 16px;
  }

  .projects {
    gap: 80px;
  }

  .project--main {
    gap: 40px;
  }

  .project--main .project__image {
    height: 400px;
    order: 1;
  }

  .project--main .project__content {
    order: 2;
  }

  .project__content {
    padding: 0 20px;
    gap: 32px;
  }

  .project__header {
    gap: 8px;
    min-width: auto;
    padding-right: 0;
  }

  .project__category {
    font-size: 16px;
  }

  .project__title {
    font-size: 32px;
  }

  .service-item__text {
    font-size: 16px;
  }

  .btn {
    width: 100%;
    justify-content: space-between;
  }

  .projects__secondary {
    gap: 60px;
  }

  .project__content--white {
    padding: 40px 24px;
    gap: 32px;
  }

  .project__top {
    gap: 24px;
  }

  .project__description {
    font-size: 14px;
  }

  .service-item--compact .service-item__text {
    font-size: 16px;
  }

  .service-item__detail {
    font-size: 13px;
  }

  .company {
    gap: 40px;
    grid-template-columns: 1fr;
  }

  .company__map {
    height: 300px;
    max-width: 100%;
  }

  .company__map iframe {
    max-width: 100%;
  }

  .outline-item {
    flex-direction: column;
    gap: 8px;
    padding: 16px 0;
  }

  .outline-item__label {
    min-width: auto;
    font-size: 14px;
  }

  .outline-item__value {
    font-size: 14px;
  }

  .company__object {
    height: 60px;
    bottom: -60px;
    border-radius: 60px 60px 0 0;
  }

  .footer__logo {
    padding-left: 20px;
    padding-top: 20px;
  }

  .logo--large {
    width: 280px;
    height: 113px;
  }

  .footer__copy {
    padding: 20px;
    justify-content: center;
  }

  .footer__copy p {
    font-size: 12px;
    text-align: center;
  }
}

/* Small mobile adjustments */
@media (max-width: 480px) {
  .mv__tagline-en {
    font-size: 32px;
  }

  .section-title {
    font-size: 36px;
  }

  .project__title {
    font-size: 28px;
  }
}
