/* =====================================================
   買取のキクチ — common.css
   全ページ共通スタイル（ヘッダー・ナビ・フッター等）
   ===================================================== */

/* ===== CSS 変数（全ページのスーパーセット） ===== */
:root {
  /* ブランドカラー */
  --gold:             #F38D1B;
  --gold-dark:        #D07518;

  /* ダーク系 */
  --black:            #111111;
  --dark:             #1a1a1a;
  --bg-dark:          #1a1a1a;
  --dark2:            #222222;
  --dark3:            #2a2a2a;
  --dark-secondary:   #2a2a2a;

  /* ライト系 */
  --white:            #ffffff;
  --bg:               #f8f8f6;
  --bg-light:         #f7f7f7;
  --light-bg:         #f8f8f8;
  --gray-light:       #f7f7f7;
  --gray:             #e8e8e8;
  --border:           #e5e5e5;

  /* テキスト */
  --text:             #333333;
  --text-main:        #333333;
  --text-dark:        #222222;
  --text-mid:         #555555;
  --text-light:       #666666;
  --text-sub:         #666666;

  /* アクセント */
  --green:            #2e9b5e;
  --blue:             #0078D4;
  --red:              #e03e3e;

  /* ユーティリティ */
  --radius:           8px;
  --shadow:           0 4px 20px rgba(0,0,0,0.08);
  --max-width:        1100px;
}

/* ===== リセット & ベース ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', Meiryo, sans-serif;
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  max-width: 100%;
  padding-top: 64px; /* fixed header の高さ分 */
}
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
  overflow-wrap: break-word;
}
.layout > main,
.layout > aside { min-width: 0; }

/* ===== HEADER ===== */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: #ffffff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 64px;
  gap: 16px;
}
.header-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}
.header-logo-img {
  height: 36px;
  width: auto;
  display: block;
}
/* 旧テキストロゴ用（残存ページ向け後方互換） */
.header-logo .logo-icon,
.logo-icon {
  width: 40px;
  height: 40px;
  background: #F38D1B;
  clip-path: polygon(50% 0%, 93% 25%, 93% 75%, 50% 100%, 7% 75%, 7% 25%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
  color: #111;
}
.header-logo .logo-text,
.logo-text { line-height: 1.2; }
.header-logo .logo-text span,
.logo-text span {
  display: block;
  font-size: 0.5rem;
  color: #888;
  font-weight: 400;
  letter-spacing: 0.1em;
}
.header-nav {
  display: flex;
  gap: 24px;
  align-items: center;
  font-size: 0.88rem;
}
.header-nav a {
  color: #1a1a1a;
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s;
}
.header-nav a:hover { color: #F38D1B; }
.header-cta {
  background: #F38D1B;
  color: #111;
  font-weight: 800;
  padding: 10px 24px;
  border-radius: 6px;
  font-size: 0.9rem;
  transition: background 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
}
.header-cta:hover { background: #D07518; }

/* ===== HAMBURGER ===== */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-left: 8px;
  border-radius: 6px;
  transition: background 0.2s;
}
.hamburger:hover { background: #f5f5f5; }
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: #1a1a1a;
  border-radius: 2px;
  transition: all 0.3s ease;
}
.hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== MOBILE NAV OVERLAY ===== */
.mobile-nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1999;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  transition: opacity 0.3s;
}
.mobile-nav-overlay.is-open {
  display: block;
  opacity: 1;
}

/* ===== MOBILE NAV DRAWER ===== */
.mobile-nav-drawer {
  position: fixed;
  top: 0; right: 0;
  width: min(300px, 85vw);
  height: 100%;
  background: #fff;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0,0,0,0.18);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
}
.mobile-nav-overlay.is-open .mobile-nav-drawer {
  transform: translateX(0);
}
.mobile-nav-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #eee;
}
.mobile-nav-drawer-title {
  font-weight: 900;
  font-size: 0.95rem;
  color: #1a1a1a;
}
.mobile-nav-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #888;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 4px;
  transition: background 0.2s;
}
.mobile-nav-close:hover { background: #eee; color: #333; }
.mobile-nav-links {
  flex: 1;
  padding: 8px 0;
}
.mobile-nav-links a {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 15px 20px;
  font-size: 0.93rem;
  font-weight: 600;
  color: #1a1a1a;
  border-bottom: 1px solid #f5f5f5;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.mobile-nav-links a:hover,
.mobile-nav-links a:active { background: #fff3f0; color: #F38D1B; }
.mobile-nav-links a i {
  width: 20px;
  text-align: center;
  color: #F38D1B;
  font-size: 1rem;
}
.mobile-nav-cta-wrap {
  padding: 16px;
  border-top: 1px solid #eee;
  background: #fafafa;
}
.mobile-nav-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #F38D1B;
  color: #1a1a1a;
  font-weight: 900;
  padding: 15px 20px;
  border-radius: 8px;
  font-size: 0.95rem;
  text-align: center;
  text-decoration: none;
  transition: background 0.2s;
}
.mobile-nav-cta:hover { background: #D07518; color: #fff; }

/* ===== RESPONSIVE: ヘッダー ===== */
@media (max-width: 1080px) {
  .header-nav { display: none; }
  .hamburger    { display: flex; }
}
@media (max-width: 600px) {
  .header-cta { display: none; }
  .header     { padding: 0 16px; }
}

/* ===== FOOTER ===== */
.footer { background: #0d0d0d; padding: 56px 32px 24px; }
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand .logo-text { color: #ffffff; font-weight: 900; font-size: 1.1rem; margin-bottom: 8px; display: block; }
.footer-brand p { color: rgba(255,255,255,0.4); font-size: 0.82rem; line-height: 1.7; }
.footer-col h4 { color: #ffffff; font-weight: 700; font-size: 0.9rem; margin-bottom: 16px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a { color: rgba(255,255,255,0.45); font-size: 0.82rem; transition: color 0.2s; }
.footer-col ul li a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-copy { color: rgba(255,255,255,0.3); font-size: 0.78rem; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: rgba(255,255,255,0.3); font-size: 0.78rem; transition: color 0.2s; }
.footer-links a:hover { color: #ffffff; }

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; }
}
