/*
Theme Name: Apartment
Theme URI: https://aptm.jp
Author: apartment
Description: 株式会社apartment official website theme
Version: 1.0
*/

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

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --black: #000000;
  --white: #ffffff;
  --off-black: #1a1a1a;
  --cream: #f0ede8;
  --gold: #c8b89a;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--black);
  color: var(--white);
  font-family: 'Inter', 'Noto Sans JP', sans-serif;
  font-weight: 200;
  cursor: none;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Custom Cursor */
.cursor-dot {
  position: fixed;
  width: 6px;
  height: 6px;
  background: var(--white);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  mix-blend-mode: difference;
}

.cursor-ring {
  position: fixed;
  width: 36px;
  height: 36px;
  border: 1px solid var(--white);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.2s ease, height 0.2s ease, opacity 0.2s ease;
  opacity: 0.5;
  mix-blend-mode: difference;
}

/* Nav */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 48px;
}

.nav-logo {
  text-decoration: none;
  display: flex;
  align-items: center;
}

.nav-logo-img {
  height: 22px;
  width: auto;
  filter: invert(1);
  opacity: 0.9;
}

.nav-links {
  display: flex;
  gap: 40px;
  list-style: none;
}

.nav-links a {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--white);
  text-decoration: none;
  opacity: 0.6;
  transition: opacity 0.3s ease;
}

.nav-links a:hover {
  opacity: 1;
}

/* Hero */
#hero {
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 48px 80px;
  position: relative;
}

.hero-en {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: clamp(52px, 8vw, 110px);
  letter-spacing: -0.02em;
  line-height: 0.95;
  color: var(--white);
  text-transform: uppercase;
}

.hero-en span {
  display: block;
}

.hero-ja {
  margin-top: 40px;
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 100;
  font-size: clamp(13px, 1.2vw, 16px);
  letter-spacing: 0.4em;
  color: var(--gold);
}

.hero-scroll {
  position: absolute;
  right: 48px;
  bottom: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.hero-scroll span {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: 0.4;
  writing-mode: vertical-rl;
}

.hero-scroll-line {
  width: 1px;
  height: 60px;
  background: var(--gold);
  opacity: 0.4;
  animation: scrollLine 2s ease infinite;
}

@keyframes scrollLine {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* Marquee */
.marquee-wrap {
  border-top: 1px solid rgba(255,255,255,0.12);
  border-bottom: 1px solid rgba(255,255,255,0.12);
  overflow: hidden;
  padding: 18px 0;
}

.marquee-track {
  display: flex;
  gap: 0;
  white-space: nowrap;
  animation: marquee 18s linear infinite;
}

.marquee-track span {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  padding: 0 40px;
}

.marquee-track span.sep {
  color: rgba(200,184,154,0.3);
  padding: 0;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* About */
#about {
  padding: 140px 48px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.about-label {
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 48px;
}

.about-text {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: clamp(28px, 3.5vw, 48px);
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--white);
}

.about-sub {
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 100;
  font-size: 13px;
  line-height: 2.2;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.05em;
}

/* Services */
#services {
  padding: 0 48px 140px;
}

.services-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 60px;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 40px;
}

.services-label {
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
}

.services-count {
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(255,255,255,0.3);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(255,255,255,0.08);
}

.service-item {
  background: var(--black);
  padding: 48px 40px;
  position: relative;
  transition: background 0.4s ease;
}

.service-item:hover {
  background: var(--off-black);
}

.service-num {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 40px;
  opacity: 0.6;
}

.service-name {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: 22px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 16px;
}

.service-desc {
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 100;
  font-size: 12px;
  line-height: 2;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.05em;
}

/* Company */
#company {
  padding: 140px 48px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.company-inner {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 80px;
  align-items: start;
}

.company-label {
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
}

.company-table {
  width: 100%;
  border-collapse: collapse;
}

.company-table tr {
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.company-table td {
  padding: 24px 0;
  vertical-align: top;
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 100;
}

.company-table td:first-child {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--gold);
  text-transform: uppercase;
  width: 140px;
  padding-right: 40px;
}

.company-table td:last-child {
  font-size: 13px;
  line-height: 2;
  color: rgba(255,255,255,0.7);
  letter-spacing: 0.05em;
}

/* Contact */
#contact {
  padding: 140px 48px;
  background: var(--off-black);
  text-align: center;
}

.contact-en {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: clamp(40px, 6vw, 80px);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 20px;
}

.contact-sub {
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 100;
  font-size: 13px;
  letter-spacing: 0.2em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 60px;
}

.contact-email {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: clamp(16px, 2vw, 22px);
  letter-spacing: 0.1em;
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid rgba(200,184,154,0.3);
  padding-bottom: 8px;
  transition: border-color 0.3s ease, color 0.3s ease;
}

.contact-email:hover {
  color: var(--white);
  border-color: rgba(255,255,255,0.5);
}

/* Footer */
footer {
  padding: 40px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-logo {
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}

.footer-copy {
  font-size: 10px;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.2);
}

/* Works */
#works {
  padding: 140px 48px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.works-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 48px;
}

.works-label {
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
}

.works-filters {
  display: flex;
  gap: 8px;
}

.filter-btn {
  background: none;
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.4);
  font-family: 'Inter', sans-serif;
  font-weight: 200;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 8px 18px;
  cursor: none;
  transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
  border-color: var(--gold);
  color: var(--gold);
}

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

.work-item {
  aspect-ratio: 1;
  overflow: hidden;
  position: relative;
}

.work-img-wrap {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.work-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
  display: block;
}

.work-item:hover .work-img-wrap img {
  transform: scale(1.05);
}

.work-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.work-item:hover .work-overlay {
  opacity: 1;
}

.work-cat {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 8px;
}

.work-title {
  font-family: 'Inter', sans-serif;
  font-weight: 200;
  font-size: 16px;
  letter-spacing: 0.05em;
  color: var(--white);
}

.work-item.hidden {
  display: none;
}

/* Footer logo */
.footer-logo-img {
  height: 18px;
  width: auto;
  filter: invert(1);
  opacity: 0.3;
}

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

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

/* Mobile */
@media (max-width: 768px) {
  nav {
    padding: 24px 24px;
  }

  .nav-links {
    display: none;
  }

  #hero {
    padding: 0 24px 60px;
  }

  #about {
    padding: 80px 24px;
    grid-template-columns: 1fr;
    gap: 40px;
  }

  #works {
    padding: 80px 24px;
  }

  .works-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
  }

  .works-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  #services {
    padding: 0 24px 80px;
  }

  .services-grid {
    grid-template-columns: 1fr 1fr;
  }

  .service-item {
    padding: 32px 24px;
  }

  #company {
    padding: 80px 24px;
  }

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

  #contact {
    padding: 80px 24px;
  }

  footer {
    padding: 32px 24px;
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}
