/*
Theme Name: NCdesign
Theme URI: https://ncdesign.jp
Author: NCdesign
Author URI: https://ncdesign.jp
Description: カスタム企業サイトテーマ — 不動産管理・設備管理・アプリ開発
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: ncdesign
*/

/* =============================================
   RESET & BASE
============================================= */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --gold: #8a7a5a;
  --gold-light: #c8b88a;
  --gold-pale: #f5f2ec;
  --dark: #1a1a18;
  --dark-mid: #2d2b24;
  --dark-surface: #242420;
  --dark-border: #3a3830;
  --dark-muted: #6a6860;
  --dark-text: #f0ece4;
  --dark-text-sub: #9a968e;
  --white: #ffffff;
  --off-white: #faf9f6;
  --text: #1a1a18;
  --text-sub: #5a5850;
  --border: rgba(0,0,0,0.1);
  --radius: 12px;
  --radius-sm: 6px;
  --font-sans: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', sans-serif;
  --font-display: 'Cormorant Garamond', 'Noto Serif JP', serif;
  --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text);
  background: var(--off-white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* =============================================
   TYPOGRAPHY
============================================= */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: 0.03em;
}

.label {
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
}

/* =============================================
   LAYOUT
============================================= */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 40px;
}

section { padding: 96px 0; }

/* =============================================
   HEADER / NAV
============================================= */
#site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(250, 249, 246, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 0.5px solid var(--border);
  transition: var(--transition);
}

#site-header.scrolled {
  background: rgba(26, 26, 24, 0.95);
}

#site-header.scrolled .site-title a,
#site-header.scrolled .nav-menu a {
  color: var(--dark-text);
}

#site-header.scrolled .nav-cta {
  border-color: var(--gold);
  color: var(--gold);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 40px;
}

.site-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.site-title a { color: var(--text); }
.site-title span { color: var(--gold); }

.nav-menu {
  display: flex;
  gap: 36px;
  align-items: center;
}

.nav-menu a {
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--text-sub);
  transition: color var(--transition);
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0; right: 0;
  height: 0.5px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform var(--transition);
}

.nav-menu a:hover { color: var(--text); }
.nav-menu a:hover::after { transform: scaleX(1); }

.nav-cta {
  padding: 8px 22px;
  border: 0.5px solid var(--gold);
  color: var(--gold);
  font-size: 12px;
  letter-spacing: 0.1em;
  cursor: pointer;
  background: transparent;
  transition: all var(--transition);
  border-radius: var(--radius-sm);
}

.nav-cta:hover {
  background: var(--gold);
  color: var(--white);
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.menu-toggle span {
  display: block;
  width: 24px; height: 1px;
  background: var(--text);
  transition: var(--transition);
}

/* =============================================
   HERO
============================================= */
#hero {
  min-height: 100vh;
  background: var(--dark);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('<?php echo get_template_directory_uri(); ?>/assets/hero-bg.webp');
  background-size: cover;
  background-position: center;
  opacity: 0.25;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(26,26,24,0.95) 0%, rgba(45,43,36,0.7) 100%);
}

.hero-grain {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.4;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 120px 40px 80px;
  max-width: 1080px;
  margin: 0 auto;
  width: 100%;
}

.hero-eyebrow {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeUp 0.8s 0.2s forwards;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 400;
  color: var(--dark-text);
  line-height: 1.2;
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeUp 0.8s 0.4s forwards;
}

.hero-title em {
  font-style: normal;
  color: var(--gold-light);
}

.hero-desc {
  font-size: 15px;
  color: var(--dark-text-sub);
  line-height: 1.9;
  max-width: 520px;
  margin-bottom: 48px;
  opacity: 0;
  animation: fadeUp 0.8s 0.6s forwards;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.8s 0.8s forwards;
}

.btn-primary {
  display: inline-block;
  padding: 14px 36px;
  background: var(--gold);
  color: var(--white);
  font-size: 12px;
  letter-spacing: 0.12em;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
}

.btn-ghost {
  display: inline-block;
  padding: 14px 36px;
  background: transparent;
  color: var(--dark-text-sub);
  font-size: 12px;
  letter-spacing: 0.12em;
  border-radius: var(--radius-sm);
  border: 0.5px solid var(--dark-border);
  transition: all var(--transition);
  cursor: pointer;
}

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

.hero-scroll {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--dark-muted);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0;
  animation: fadeUp 1s 1.2s forwards;
}

.hero-scroll-line {
  width: 0.5px;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--gold));
  animation: scrollLine 2s 1.5s infinite;
}

/* =============================================
   SERVICES
============================================= */
#services {
  background: var(--off-white);
}

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

.section-header .label { margin-bottom: 16px; display: block; }

.section-title {
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 400;
  color: var(--text);
  line-height: 1.25;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: var(--border);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.service-card {
  background: var(--white);
  padding: 48px 36px;
  position: relative;
  transition: background var(--transition);
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform var(--transition);
}

.service-card:hover { background: var(--gold-pale); }
.service-card:hover::before { transform: scaleX(1); }

.service-number {
  font-family: var(--font-display);
  font-size: 40px;
  color: var(--gold-light);
  opacity: 0.4;
  line-height: 1;
  margin-bottom: 24px;
}

.service-icon {
  width: 48px; height: 48px;
  margin-bottom: 20px;
  color: var(--gold);
}

.service-card h3 {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 12px;
  color: var(--text);
}

.service-card p {
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.85;
  margin-bottom: 24px;
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  font-size: 11px;
  letter-spacing: 0.06em;
  padding: 4px 12px;
  background: var(--gold-pale);
  color: var(--gold);
  border-radius: 99px;
  border: 0.5px solid rgba(138,122,90,0.3);
}

/* =============================================
   STATS
============================================= */
#stats {
  background: var(--dark);
  padding: 80px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.stat-item {
  text-align: center;
  padding: 48px 24px;
  border-right: 0.5px solid var(--dark-border);
}

.stat-item:last-child { border-right: none; }

.stat-number {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 400;
  color: var(--dark-text);
  line-height: 1;
  margin-bottom: 8px;
}

.stat-number sup {
  font-size: 22px;
  color: var(--gold);
  vertical-align: super;
}

.stat-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--dark-muted);
  text-transform: uppercase;
}

/* =============================================
   ABOUT
============================================= */
#about {
  background: var(--white);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.about-visual-wrap {
  position: relative;
}

.about-visual {
  width: 100%;
  aspect-ratio: 4/5;
  background: var(--gold-pale);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
}

.about-visual img {
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0.8;
}

.about-badge {
  position: absolute;
  bottom: -24px;
  right: -24px;
  width: 120px; height: 120px;
  background: var(--dark);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.about-badge-num {
  font-family: var(--font-display);
  font-size: 28px;
  color: var(--gold-light);
  line-height: 1;
}

.about-badge-text {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--dark-muted);
  text-transform: uppercase;
}

.about-content .label { display: block; margin-bottom: 16px; }

.about-content h2 {
  font-size: clamp(24px, 3vw, 36px);
  margin-bottom: 28px;
}

.about-content p {
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.95;
  margin-bottom: 16px;
}

.strengths {
  margin-top: 36px;
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.strength-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border-bottom: 0.5px solid var(--border);
  font-size: 13.5px;
}

.strength-item:last-child { border-bottom: none; }

.strength-dot {
  width: 6px; height: 6px;
  background: var(--gold);
  border-radius: 50%;
  flex-shrink: 0;
}

/* =============================================
   WORKS / ACHIEVEMENTS
============================================= */
#works {
  background: var(--off-white);
}

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

.work-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px;
  border: 0.5px solid var(--border);
  transition: all var(--transition);
}

.work-card:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 12px 48px rgba(0,0,0,0.08);
}

.work-badge {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 12px;
  background: var(--gold-pale);
  color: var(--gold);
  border-radius: 99px;
  margin-bottom: 20px;
  border: 0.5px solid rgba(138,122,90,0.3);
}

.work-card h3 {
  font-size: 18px;
  margin-bottom: 10px;
}

.work-card p {
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.8;
}

/* =============================================
   CTA
============================================= */
#cta {
  padding: 0 0 96px;
}

.cta-inner {
  background: var(--dark);
  border-radius: var(--radius);
  padding: 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-inner::before {
  content: '';
  position: absolute;
  top: -100px; left: 50%;
  transform: translateX(-50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(138,122,90,0.12) 0%, transparent 70%);
}

.cta-inner .label { margin-bottom: 16px; display: block; }

.cta-inner h2 {
  font-size: clamp(28px, 4vw, 48px);
  color: var(--dark-text);
  margin-bottom: 16px;
  position: relative;
}

.cta-inner p {
  font-size: 14px;
  color: var(--dark-text-sub);
  margin-bottom: 40px;
  position: relative;
}

.cta-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}

.cta-email {
  font-size: 13px;
  color: var(--dark-muted);
  margin-top: 20px;
  position: relative;
}

.cta-email a { color: var(--gold); }

/* =============================================
   FOOTER
============================================= */
#site-footer {
  background: #111110;
  padding: 56px 0 32px;
}

.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 40px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 40px;
  border-bottom: 0.5px solid var(--dark-border);
  margin-bottom: 32px;
}

.footer-brand .site-title {
  font-size: 20px;
  margin-bottom: 12px;
  display: block;
}

.footer-brand p {
  font-size: 13px;
  color: var(--dark-muted);
  line-height: 1.7;
}

.footer-nav {
  display: flex;
  gap: 48px;
}

.footer-nav-col h4 {
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}

.footer-nav-col ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-nav-col a {
  font-size: 13px;
  color: var(--dark-muted);
  transition: color var(--transition);
}

.footer-nav-col a:hover { color: var(--dark-text); }

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

.footer-bottom p {
  font-size: 12px;
  color: var(--dark-border);
}

/* =============================================
   ANIMATIONS
============================================= */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scrollLine {
  0%, 100% { transform: scaleY(1); opacity: 1; }
  50% { transform: scaleY(0.5); opacity: 0.3; }
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s var(--transition), transform 0.8s var(--transition);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* =============================================
   RESPONSIVE
============================================= */
@media (max-width: 900px) {
  .services-grid { grid-template-columns: 1fr; gap: 0; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item:nth-child(2) { border-right: none; }
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .about-badge { display: none; }
  .works-grid { grid-template-columns: 1fr; }
  .cta-inner { padding: 56px 32px; }
  .footer-top { flex-direction: column; gap: 40px; }
}

@media (max-width: 640px) {
  .container { padding: 0 24px; }
  .header-inner { padding: 0 24px; }
  section { padding: 72px 0; }
  .nav-menu { display: none; }
  .nav-menu.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    background: var(--dark);
    justify-content: center;
    align-items: center;
    gap: 32px;
    z-index: 999;
  }
  .nav-menu.open a { font-size: 20px; color: var(--dark-text); }
  .menu-toggle { display: flex; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-nav { flex-direction: column; gap: 32px; }
}
