/* ============================================
   NEXIA PROPERTY — Design System (DESIGN.md準拠)
   Aesthetic: Stripe-style Brutally Minimal
   ============================================ */

/* --- CSS Variables --- */
:root {
  --primary-navy: #0a2540;
  --accent-blue: #1a73e8;
  --accent-hover: #1557b0;
  --surface: #ffffff;
  --surface-tinted: #f6f9fc;
  --border: #e3e8ee;
  --body-text: #425466;
  --muted: #8898aa;
  --success: #0cad56;
  --warning: #e6a117;
  --error: #cd3d64;
  --info: #1e40af;

  --shadow-rest: 0 2px 4px rgba(50,50,93,0.1), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-hover: 0 7px 14px rgba(50,50,93,0.1), 0 3px 6px rgba(0,0,0,0.08);
  --shadow-active: 0 13px 27px -5px rgba(50,50,93,0.25), 0 8px 16px -8px rgba(0,0,0,0.1);

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;

  --font-display: 'Noto Sans JP', sans-serif;
  --font-body: 'Noto Sans JP', sans-serif;
  --font-data: 'DM Sans', sans-serif;

  --space-2xs: 2px;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  --space-4xl: 96px;
  --space-5xl: 128px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--body-text);
  background-color: var(--surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: color 150ms ease-out;
}

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

/* --- Typography --- */
h1 {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1.2px;
  color: var(--primary-navy);
}

h2 {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.8px;
  color: var(--primary-navy);
}

h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.3px;
  color: var(--primary-navy);
}

.subtitle {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 300;
  line-height: 1.6;
  letter-spacing: 0;
  color: var(--body-text);
}

.label {
  font-family: var(--font-data);
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent-blue);
}

.small {
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--muted);
}

.data-value {
  font-family: var(--font-data);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.5px;
  color: var(--primary-navy);
}

/* --- Layout --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container--narrow {
  max-width: 720px;
}

.section {
  padding: var(--space-4xl) 0;
}

.section--tinted {
  background-color: var(--surface-tinted);
}

.section--navy {
  background-color: var(--primary-navy);
  color: rgba(255,255,255,0.8);
}

.section--navy h2,
.section--navy h3 {
  color: #ffffff;
}

.section--navy .label {
  color: rgba(255,255,255,0.5);
}

.grid {
  display: grid;
  gap: var(--space-lg);
}

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

.text-center { text-align: center; }

/* --- Header --- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 300ms ease-out, border-color 300ms ease-out;
}

.header.is-scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

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

.header__logo img {
  height: 36px;
  width: auto;
  object-fit: contain;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  list-style: none;
}

.header__nav a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--body-text);
  transition: color 150ms ease-out;
  position: relative;
}

.header__nav a:hover,
.header__nav a.active {
  color: var(--primary-navy);
}

.header__nav a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--accent-blue);
  border-radius: 1px;
}

.header__cta {
  display: inline-flex;
  align-items: center;
  padding: 8px 20px;
  background-color: var(--primary-navy);
  color: #ffffff !important;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  letter-spacing: 0.3px;
  transition: all 150ms ease-out;
}

.header__cta:hover {
  background-color: #0d3157;
  color: #ffffff !important;
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
}

.header__cta::after {
  display: none !important;
}

.header__menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
}

.header__menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--primary-navy);
  margin: 4px 0;
  transition: transform 200ms ease-out;
}

/* --- Hero --- */
.hero {
  position: relative;
  padding: var(--space-5xl) 0 var(--space-4xl);
  background: linear-gradient(135deg, #f6f9fc 0%, #eef3f9 50%, #e8eef6 100%);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -200px;
  right: -200px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(26,115,232,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -100px;
  left: -100px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(10,37,64,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.hero__inner {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 6px 16px;
  background-color: rgba(26,115,232,0.08);
  border: 1px solid rgba(26,115,232,0.15);
  border-radius: var(--radius-full);
  font-family: var(--font-data);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-blue);
  letter-spacing: 0.5px;
  margin-bottom: var(--space-xl);
}

.hero__badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent-blue);
}

.hero h1 {
  margin-bottom: var(--space-lg);
  font-size: 3rem;
}

.hero .subtitle {
  margin-bottom: var(--space-2xl);
  max-width: 560px;
}

.hero__actions {
  display: flex;
  gap: var(--space-md);
  align-items: center;
  flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 12px 28px;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 150ms ease-out;
  text-decoration: none;
}

.btn--primary {
  background-color: var(--accent-blue);
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(26,115,232,0.3);
}

.btn--primary:hover {
  background-color: var(--accent-hover);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(26,115,232,0.3);
  transform: translateY(-1px);
}

.btn--ghost {
  background-color: transparent;
  color: var(--body-text);
  padding: 12px 16px;
}

.btn--ghost:hover {
  color: var(--primary-navy);
}

.btn--ghost .arrow {
  transition: transform 150ms ease-out;
}

.btn--ghost:hover .arrow {
  transform: translateX(3px);
}

.btn--large {
  padding: 14px 32px;
  font-size: 1rem;
}

.btn--outline {
  background-color: transparent;
  color: var(--accent-blue);
  border: 1.5px solid var(--border);
}

.btn--outline:hover {
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  transform: translateY(-1px);
}

.btn--white {
  background-color: #ffffff;
  color: var(--primary-navy);
  box-shadow: var(--shadow-rest);
}

.btn--white:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
  color: var(--primary-navy);
}

/* --- Stats --- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

.stat {
  text-align: center;
  padding: var(--space-xl) var(--space-md);
}

.stat__number {
  font-family: var(--font-data);
  font-size: 3rem;
  font-weight: 700;
  color: var(--primary-navy);
  letter-spacing: -1.5px;
  line-height: 1;
}

.stat__label {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: var(--space-sm);
}

.stat--light .stat__number {
  color: #ffffff;
}

.stat--light .stat__label {
  color: rgba(255,255,255,0.5);
}

/* --- Card --- */
.card {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl) var(--space-lg);
  transition: all 250ms ease-out;
}

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

.card__number {
  font-family: var(--font-data);
  font-size: 2.5rem;
  font-weight: 700;
  color: rgba(26,115,232,0.1);
  letter-spacing: -1px;
  line-height: 1;
  margin-bottom: var(--space-md);
}

/* Strength cards - vertical layout */
.strength {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: var(--space-xl);
  padding: var(--space-2xl);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all 250ms ease-out;
}

.strength:hover {
  border-color: transparent;
  box-shadow: var(--shadow-active);
  transform: translateY(-4px);
}

.strength__number {
  font-family: var(--font-data);
  font-size: 3.5rem;
  font-weight: 700;
  color: rgba(26,115,232,0.12);
  line-height: 1;
  letter-spacing: -2px;
}

.strength h3 {
  font-size: 1.375rem;
  margin-bottom: var(--space-sm);
}

.strength p {
  font-size: 0.9375rem;
  line-height: 1.8;
}

.strengths-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

@media (max-width: 768px) {
  .strength {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .strength__number {
    font-size: 2.5rem;
  }
}

.card h3 {
  margin-bottom: var(--space-sm);
}

.card p {
  font-size: 0.9375rem;
  line-height: 1.7;
}

/* --- Section Header --- */
.section-header {
  margin-bottom: var(--space-2xl);
}

.section-header .label {
  margin-bottom: var(--space-sm);
}

.section-header p {
  margin-top: var(--space-md);
  max-width: 500px;
}

.section-header--center {
  text-align: center;
}

.section-header--center p {
  margin-left: auto;
  margin-right: auto;
}

/* --- Page Header --- */
.page-header {
  padding: var(--space-3xl) 0 var(--space-xl);
}

.page-header .label {
  margin-bottom: var(--space-sm);
}

.page-header h1 {
  font-size: 2.5rem;
}

.page-header p {
  margin-top: var(--space-md);
  max-width: 560px;
  font-size: 1.125rem;
  color: var(--body-text);
}

/* --- Timeline --- */
.timeline {
  position: relative;
  padding-left: var(--space-2xl);
}

.timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 4px;
  bottom: 4px;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent-blue), var(--border));
}

.timeline__item {
  position: relative;
  padding-bottom: var(--space-2xl);
}

.timeline__item:last-child {
  padding-bottom: 0;
}

.timeline__item::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--space-2xl) + 3px);
  top: 6px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: var(--accent-blue);
  box-shadow: 0 0 0 4px rgba(26,115,232,0.12);
}

.timeline__period {
  font-family: var(--font-data);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.5px;
  margin-bottom: var(--space-xs);
}

.timeline__title {
  font-weight: 700;
  color: var(--primary-navy);
  font-size: 1.0625rem;
  margin-bottom: var(--space-xs);
}

.timeline__desc {
  font-size: 0.9375rem;
  color: var(--body-text);
  line-height: 1.7;
}

/* --- Service Item --- */
.service-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: var(--space-lg);
  padding: var(--space-2xl) 0;
  border-bottom: 1px solid var(--border);
}

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

.service-item__number {
  font-family: var(--font-data);
  font-size: 3rem;
  font-weight: 700;
  color: rgba(26,115,232,0.15);
  line-height: 1;
  letter-spacing: -2px;
}

.service-item h3 {
  margin-bottom: var(--space-sm);
  font-size: 1.375rem;
}

.service-item p {
  margin-bottom: var(--space-md);
  font-size: 0.9375rem;
}

.service-item ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm) var(--space-lg);
}

.service-item li {
  position: relative;
  padding-left: 20px;
  font-size: 0.875rem;
  color: var(--body-text);
}

.service-item li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent-blue);
  opacity: 0.5;
}

/* --- Info Table --- */
.info-table {
  width: 100%;
  border-collapse: collapse;
}

.info-table th,
.info-table td {
  padding: var(--space-md) var(--space-lg);
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-size: 0.9375rem;
}

.info-table th {
  width: 140px;
  font-weight: 600;
  color: var(--primary-navy);
  white-space: nowrap;
}

/* --- Form --- */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--primary-navy);
  margin-bottom: var(--space-sm);
  letter-spacing: 0.3px;
}

.form-group .required {
  color: var(--error);
  font-size: 0.6875rem;
  font-weight: 500;
  margin-left: 4px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--body-text);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: all 150ms ease-out;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--muted);
  font-weight: 300;
}

.form-group textarea {
  min-height: 160px;
  resize: vertical;
  line-height: 1.7;
}

/* --- CTA Section --- */
.cta-section {
  text-align: center;
  padding: var(--space-3xl) var(--space-xl);
  background: linear-gradient(135deg, var(--primary-navy) 0%, #0d3157 100%);
  border-radius: var(--radius-lg);
  max-width: 880px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -80px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(26,115,232,0.15) 0%, transparent 70%);
  pointer-events: none;
}

.cta-badge {
  display: inline-block;
  padding: 8px 24px;
  background-color: rgba(26,115,232,0.2);
  border: 1px solid rgba(26,115,232,0.4);
  color: #5b9ef0;
  font-family: var(--font-data);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  border-radius: var(--radius-full);
  margin-bottom: var(--space-lg);
}

.cta-section h2 {
  margin-bottom: var(--space-md);
  color: #ffffff;
}

.cta-section p {
  margin-bottom: var(--space-xl);
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  color: rgba(255,255,255,0.65);
}

.cta-section .btn--primary {
  background-color: #ffffff;
  color: var(--primary-navy);
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
}

.cta-section .btn--primary:hover {
  background-color: #f0f4f8;
  color: var(--primary-navy);
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
  transform: translateY(-2px);
}

/* --- Flow --- */
.flow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
  counter-reset: flow;
}

.flow__step {
  position: relative;
  text-align: center;
  padding: var(--space-xl) var(--space-md);
}

.flow__number {
  font-family: var(--font-data);
  font-size: 2.5rem;
  font-weight: 700;
  color: rgba(26,115,232,0.15);
  line-height: 1;
  margin-bottom: var(--space-md);
}

.flow__step h3 {
  font-size: 1rem;
  margin-bottom: var(--space-sm);
}

.flow__step p {
  font-size: 0.8125rem;
  color: var(--muted);
  line-height: 1.5;
}

/* --- Partner Card --- */
.partner-card {
  background: linear-gradient(135deg, var(--surface-tinted) 0%, #ffffff 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
}

.partner-card h3 {
  margin-bottom: var(--space-md);
}

/* --- Footer --- */
.footer {
  background-color: var(--primary-navy);
  color: rgba(255, 255, 255, 0.6);
  padding: var(--space-3xl) 0 var(--space-xl);
}

.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-xl);
}

.footer__brand {
  font-family: var(--font-data);
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 1px;
  margin-bottom: var(--space-xs);
}

.footer__sub {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.4);
}

.footer__links {
  list-style: none;
  display: flex;
  gap: var(--space-xl);
}

.footer__links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9375rem;
  transition: color 150ms ease-out;
}

.footer__links a:hover {
  color: #ffffff;
}

.footer__copy {
  text-align: center;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.25);
  margin-top: var(--space-2xl);
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* --- Success Message --- */
.success-message {
  text-align: center;
  padding: var(--space-3xl) 0;
}

.success-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: var(--success);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-lg);
}

/* --- Name Origin --- */
.name-origin {
  max-width: 640px;
  margin: 0 auto;
}

.name-origin dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-sm) var(--space-lg);
}

.name-origin dt {
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
}

.name-origin dd {
  margin: 0;
}

.name-origin dd + dt,
.name-origin dd + dt + dd {
  padding-top: var(--space-md);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
    letter-spacing: -0.5px;
  }

  h2 {
    font-size: 1.75rem;
  }

  .hero {
    padding: var(--space-3xl) 0 var(--space-2xl);
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero .subtitle {
    font-size: 1rem;
  }

  .container {
    padding: 0 var(--space-md);
  }

  .section {
    padding: var(--space-3xl) 0;
  }

  .grid--2,
  .grid--3,
  .grid--4 {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-sm);
  }

  .stat__number {
    font-size: 2rem;
  }

  .header__nav {
    display: none;
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    background-color: rgba(255,255,255,0.98);
    backdrop-filter: blur(12px);
    padding: var(--space-xl) var(--space-lg);
    gap: var(--space-lg);
    z-index: 99;
  }

  .header__nav.is-open {
    display: flex;
  }

  .header__nav a {
    font-size: 1.125rem;
  }

  .header__menu-toggle {
    display: block;
  }

  .footer__inner {
    flex-direction: column;
    gap: var(--space-lg);
  }

  .footer__links {
    flex-wrap: wrap;
    gap: var(--space-md);
  }

  .page-header {
    padding: var(--space-2xl) 0 var(--space-lg);
  }

  .page-header h1 {
    font-size: 1.75rem;
  }

  .service-item {
    grid-template-columns: 1fr;
  }

  .service-item__number {
    font-size: 2rem;
  }

  .service-item ul {
    grid-template-columns: 1fr;
  }

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

  .info-table th {
    width: 100px;
    font-size: 0.8125rem;
  }

  .info-table td {
    font-size: 0.875rem;
  }
}
