/* ============================================================
   コアグリッドポイント株式会社 — Shared Stylesheet
   coregridpoint.com
   ============================================================ */

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

/* ===== CSS CUSTOM PROPERTIES ===== */
:root {
  --primary:        #1e3a5f;
  --primary-light:  #2a5085;
  --primary-dark:   #152b47;
  --secondary:      #4d7fa8;
  --accent:         #c9a96e;
  --accent-light:   #e8d5b0;
  --accent-pale:    #f7f0e4;
  --bg:             #f8f7f5;
  --bg-alt:         #f1ede7;
  --surface:        #ffffff;
  --text:           #1a1a2e;
  --text-muted:     #6b6b7b;
  --text-light:     #9a9aaa;
  --border:         #e2dfd9;
  --border-light:   #eeebe6;
  --grid-line:      rgba(30, 58, 95, 0.055);
  --shadow-sm:      0 1px 8px  rgba(30, 58, 95, 0.07);
  --shadow:         0 2px 20px rgba(30, 58, 95, 0.09);
  --shadow-md:      0 6px 32px rgba(30, 58, 95, 0.13);
  --shadow-lg:      0 12px 48px rgba(30, 58, 95, 0.16);
  --radius-sm:      2px;
  --radius:         4px;
  --radius-md:      6px;
  --radius-lg:      12px;
  --transition:     0.28s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow:0.5s cubic-bezier(0.4, 0, 0.2, 1);
  --container:      1200px;
  --header-h:       72px;
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Meiryo', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }
address { font-style: normal; }

/* ===== GRID BACKGROUND PATTERN ===== */
.grid-bg {
  background-image:
    linear-gradient(to right,  var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: 44px 44px;
}
.grid-bg-dense {
  background-image:
    linear-gradient(to right,  var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* ===== CONTAINER ===== */
.container { max-width: var(--container); margin: 0 auto; padding: 0 28px; }
.container-sm { max-width: 820px; margin: 0 auto; padding: 0 28px; }

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Shippori Mincho B1', 'Noto Serif JP', 'Georgia', serif;
  font-weight: 600;
  line-height: 1.45;
  color: var(--primary);
  letter-spacing: 0.02em;
}
h1 { font-size: clamp(1.9rem, 4.5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.15rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }
h4 { font-size: 1.05rem; }
p  { font-size: 0.95rem; line-height: 1.9; color: var(--text-muted); }

/* ===== SECTION BASE ===== */
section { padding: 88px 0; }

/* ===== SECTION HEADER ===== */
.section-header { text-align: center; margin-bottom: 60px; }
.section-header.left { text-align: left; }
.section-tag {
  display: inline-block;
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 10px;
  font-family: 'Noto Sans JP', sans-serif;
}
.section-line {
  display: block;
  width: 44px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  margin: 14px auto 0;
  border-radius: 2px;
}
.section-header.left .section-line { margin-left: 0; }

/* ===== BADGE ===== */
.badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  border-radius: 2px;
  background: var(--accent-pale);
  color: var(--accent);
  border: 1px solid var(--accent-light);
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 32px;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  font-weight: 500;
  border-radius: var(--radius);
  transition: var(--transition);
  text-decoration: none;
  border: none;
  font-family: 'Noto Sans JP', sans-serif;
  cursor: pointer;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 3px 12px rgba(30, 58, 95, 0.25);
}
.btn-primary:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(30, 58, 95, 0.3);
}
.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
}
.btn-accent {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 3px 12px rgba(201, 169, 110, 0.3);
}
.btn-accent:hover {
  background: #b8945a;
  transform: translateY(-2px);
}
.btn-white {
  background: #fff;
  color: var(--primary);
  box-shadow: var(--shadow);
}
.btn-white:hover {
  background: var(--bg);
  transform: translateY(-2px);
}
.btn svg { width: 16px; height: 16px; }

/* ===== CARDS ===== */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  border-color: var(--accent-light);
}
.card-img { width: 100%; height: 200px; object-fit: cover; }
.card-body { padding: 24px; }

/* ===== DIVIDER ===== */
.divider {
  width: 100%;
  height: 1px;
  background: var(--border);
  margin: 0;
}
.divider-accent {
  width: 64px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  margin: 20px 0;
}

/* ===== TAGS ===== */
.tag {
  display: inline-block;
  padding: 3px 10px;
  font-size: 11px;
  border-radius: 2px;
  background: var(--bg-alt);
  color: var(--text-muted);
  margin: 2px;
  border: 1px solid var(--border);
}

/* ===== SITE HEADER ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: var(--transition);
}
.site-header.scrolled { box-shadow: var(--shadow); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-mark {
  width: 40px; height: 40px;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  font-family: 'Georgia', serif;
  flex-shrink: 0;
  position: relative;
}
.logo-mark::after {
  content: '';
  position: absolute;
  bottom: -3px; right: -3px;
  width: 12px; height: 12px;
  background: var(--accent);
}
.logo-text-wrap { display: flex; flex-direction: column; }
.logo-name {
  font-family: 'Shippori Mincho B1', serif;
  font-size: 15px;
  font-weight: 600;
  color: var(--primary);
  line-height: 1.2;
  letter-spacing: 0.03em;
}
.logo-sub {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0.06em;
  font-family: 'Noto Sans JP', sans-serif;
}

/* ===== MAIN NAV ===== */
.main-nav ul {
  display: flex;
  align-items: center;
  gap: 2px;
}
.main-nav a {
  display: block;
  text-decoration: none;
  color: var(--text);
  font-size: 13.5px;
  padding: 8px 15px;
  border-radius: var(--radius);
  transition: var(--transition);
  letter-spacing: 0.03em;
  font-weight: 400;
  white-space: nowrap;
}
.main-nav a:hover { color: var(--primary); background: rgba(30, 58, 95, 0.05); }
.main-nav a.active { color: var(--primary); font-weight: 600; }
.nav-cta {
  background: var(--primary) !important;
  color: #fff !important;
  margin-left: 8px !important;
  padding: 8px 20px !important;
}
.nav-cta:hover {
  background: var(--primary-light) !important;
  transform: translateY(-1px);
}

/* ===== HAMBURGER ===== */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 8px;
  border-radius: var(--radius);
}
.hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--primary);
  transition: var(--transition);
  transform-origin: center;
}
.hamburger.active span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.active span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ===== PAGE HERO ===== */
.page-hero {
  padding: calc(var(--header-h) + 56px) 0 64px;
  text-align: center;
  background: var(--primary);
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right,  rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}
.page-hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}
.page-hero h1 { color: #fff; position: relative; }
.page-hero > .container > p { color: rgba(255,255,255,0.72); margin-top: 14px; font-size: 15px; position: relative; }
.page-hero .breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  position: relative;
}
.page-hero .breadcrumb a { color: rgba(255,255,255,0.6); }
.page-hero .breadcrumb a:hover { color: var(--accent); }
.page-hero .breadcrumb span { color: rgba(255,255,255,0.3); }

/* ===== SITE FOOTER ===== */
.site-footer {
  background: var(--primary);
  color: rgba(255,255,255,0.8);
  padding-top: 72px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr 1.1fr 1.5fr;
  gap: 56px;
  padding-bottom: 52px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.footer-brand-logo .logo-mark { background: rgba(255,255,255,0.1); }
.footer-brand-logo .logo-mark::after { background: var(--accent); }
.footer-brand-logo .logo-name { color: #fff; }
.footer-brand-logo .logo-sub { color: rgba(255,255,255,0.5); }
.footer-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  line-height: 1.85;
  margin-bottom: 16px;
}
.footer-url a {
  font-size: 13px;
  color: var(--accent);
  letter-spacing: 0.04em;
}
.footer-url a:hover { text-decoration: underline; }
.footer-col h4 {
  color: #fff;
  font-size: 12px;
  letter-spacing: 0.12em;
  margin-bottom: 18px;
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 600;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  text-transform: uppercase;
}
.footer-col ul li { margin-bottom: 9px; }
.footer-col ul a {
  color: rgba(255,255,255,0.58);
  font-size: 13px;
  transition: var(--transition);
}
.footer-col ul a:hover { color: var(--accent); padding-left: 4px; }
.footer-address p {
  font-size: 13px;
  color: rgba(255,255,255,0.58);
  line-height: 1.75;
  margin-bottom: 5px;
}
.footer-address a { color: var(--accent); }
.footer-address a:hover { text-decoration: underline; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  font-size: 11.5px;
  color: rgba(255,255,255,0.35);
  gap: 16px;
}
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: rgba(255,255,255,0.35); transition: var(--transition); font-size: 11.5px; }
.footer-links a:hover { color: var(--accent); }

/* ===== TOAST NOTIFICATION ===== */
.toast-container {
  position: fixed;
  top: 90px; right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 340px;
  width: calc(100% - 48px);
  pointer-events: none;
}
.toast {
  background: var(--surface);
  border-left: 3px solid var(--accent);
  box-shadow: var(--shadow-md);
  padding: 14px 20px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  color: var(--text);
  pointer-events: all;
  animation: toastIn 0.3s cubic-bezier(0.4,0,0.2,1) forwards;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  line-height: 1.6;
}
.toast.success { border-left-color: #4caf50; }
.toast.error   { border-left-color: #f44336; }
.toast.info    { border-left-color: var(--secondary); }
.toast-icon { font-size: 16px; flex-shrink: 0; margin-top: 1px; }
.toast-out { animation: toastOut 0.3s cubic-bezier(0.4,0,0.2,1) forwards !important; }
@keyframes toastIn  { from { transform: translateX(110%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes toastOut { from { transform: translateX(0);   opacity: 1; } to { transform: translateX(110%); opacity: 0; } }

/* ===== FORM ===== */
.form-group { margin-bottom: 22px; }
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
  letter-spacing: 0.04em;
}
.form-label .req { color: #e53935; margin-left: 3px; }
.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  color: var(--text);
  background: var(--surface);
  transition: var(--transition);
  outline: none;
}
.form-control:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(77, 127, 168, 0.12);
}
.form-control::placeholder { color: var(--text-light); }
textarea.form-control { resize: vertical; min-height: 130px; }

/* ===== UTILS ===== */
.text-center { text-align: center; }
.text-muted  { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.mt-8   { margin-top: 8px; }
.mt-16  { margin-top: 16px; }
.mt-24  { margin-top: 24px; }
.mt-32  { margin-top: 32px; }
.mt-48  { margin-top: 48px; }
.mb-0   { margin-bottom: 0; }
.mb-8   { margin-bottom: 8px; }
.mb-16  { margin-bottom: 16px; }
.mb-24  { margin-bottom: 24px; }
.bg-alt { background: var(--bg-alt); }
.bg-white { background: var(--surface); }
.bg-primary { background: var(--primary); }
.accent-line {
  display: inline-block;
  width: 3px;
  height: 1.2em;
  background: var(--accent);
  vertical-align: middle;
  margin-right: 10px;
  border-radius: 2px;
}

/* ===== STAT CARD ===== */
.stat-card {
  text-align: center;
  padding: 32px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
}
.stat-value {
  font-family: 'Shippori Mincho B1', serif;
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  display: block;
  margin-bottom: 6px;
}
.stat-label { font-size: 13px; color: var(--text-muted); }

/* ===== FEATURE ITEM ===== */
.feature-item {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.feature-item:hover { box-shadow: var(--shadow-md); border-color: var(--accent-light); }
.feature-icon {
  width: 48px; height: 48px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-content h3 { margin-bottom: 6px; }
.feature-content p { margin: 0; }

/* ===== GRID LAYOUTS ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2-1 { display: grid; grid-template-columns: 2fr 1fr; gap: 48px; align-items: start; }
.grid-1-2 { display: grid; grid-template-columns: 1fr 2fr; gap: 48px; align-items: start; }

/* ===== ARTICLE META ===== */
.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  font-size: 12.5px;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.article-meta time { letter-spacing: 0.04em; }
.article-cat {
  display: inline-block;
  padding: 2px 10px;
  background: var(--accent-pale);
  color: var(--accent);
  border-radius: 2px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  border: 1px solid var(--accent-light);
}

/* ===== PROCESS STEP ===== */
.process-step {
  position: relative;
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
.step-number {
  font-family: 'Shippori Mincho B1', serif;
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--accent-light);
  line-height: 1;
  margin-bottom: 12px;
}

/* ===== TIMELINE ===== */
.timeline { position: relative; padding: 0 0 0 48px; }
.timeline::before {
  content: '';
  position: absolute;
  left: 16px; top: 6px; bottom: 0;
  width: 1px;
  background: var(--border);
}
.timeline-item { position: relative; margin-bottom: 40px; }
.timeline-dot {
  position: absolute;
  left: -40px; top: 4px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 3px rgba(201,169,110,0.2);
}
.timeline-year {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}
.timeline-content h4 { margin-bottom: 4px; }
.timeline-content p { font-size: 13.5px; margin: 0; }

/* ===== CTA SECTION ===== */
.cta-section {
  background: var(--primary);
  color: #fff;
  text-align: center;
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right,  rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 44px 44px;
}
.cta-section h2 { color: #fff; position: relative; margin-bottom: 16px; }
.cta-section p { color: rgba(255,255,255,0.7); position: relative; margin-bottom: 32px; }
.cta-btns { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; position: relative; }

/* ===== GEOMETRIC DECORATION ===== */
.geo-circle {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(201, 169, 110, 0.15);
  pointer-events: none;
}
.geo-box {
  position: absolute;
  border: 1px solid rgba(201, 169, 110, 0.1);
  pointer-events: none;
}

/* ===== SCROLL ANIMATION ===== */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   RESPONSIVE STYLES
   ============================================================ */

@media (max-width: 1024px) {
  :root { --container: 960px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-2-1, .grid-1-2 { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 768px) {
  section { padding: 60px 0; }
  .hamburger { display: flex; }
  .main-nav {
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 20px;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
  }
  .main-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
  .main-nav ul { flex-direction: column; gap: 2px; }
  .main-nav a { padding: 12px 16px; border-radius: var(--radius); }
  .nav-cta { margin-left: 0 !important; display: block !important; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: 1fr; }
  .section-header { margin-bottom: 40px; }
  .cta-btns { flex-direction: column; align-items: center; }
}

@media (max-width: 480px) {
  .container { padding: 0 18px; }
  h1 { font-size: 1.7rem; }
  h2 { font-size: 1.4rem; }
  .stat-value { font-size: 2.2rem; }
}

/* ===== PRINT ===== */
@media print {
  .site-header, .hamburger, .toast-container { display: none !important; }
  body { padding-top: 0; }
}
