/* ==========================================================================
   有限会社メダル コーポレートサイト
   ========================================================================== */

:root {
  --color-bg: #FFFFFF;
  --color-text: #111111;
  --color-border: #E5E5E5;
  --color-sub: #666666;
  --color-gold: #F2B705;
  --panel-bg: rgba(17, 17, 17, 0.72);
  --panel-bg-hero: rgba(17, 17, 17, 0.78);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: 'Noto Sans JP', 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: var(--color-text);
  text-decoration: none;
  transition: color 0.15s;
}

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

/* --------------------------------------------------------------------------
   背景装飾：星のきらめき
   -------------------------------------------------------------------------- */

@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(0.4); }
  50% { opacity: 1; transform: scale(1); }
}

.stars {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.star {
  position: absolute;
  background: var(--color-gold);
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  animation: twinkle 3s ease-in-out infinite;
}

/* --------------------------------------------------------------------------
   背景装飾：ロゴ大型ウォーターマーク
   -------------------------------------------------------------------------- */

.bg-medal {
  position: fixed;
  bottom: 0;
  left: -36vh;
  height: 120vh;
  width: auto;
  max-width: none;
  opacity: 0.5;
  z-index: 1;
  pointer-events: none;
  user-select: none;
}

/* --------------------------------------------------------------------------
   ヘッダー（ロゴ）
   -------------------------------------------------------------------------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 30;
  padding: 28px 32px;
}

.site-header__logo-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.site-header img {
  height: 58px;
  width: auto;
  object-fit: contain;
}

.site-header__name {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--color-text);
}

/* --------------------------------------------------------------------------
   ハンバーガーメニューボタン
   -------------------------------------------------------------------------- */

.menu-btn {
  position: fixed;
  top: 28px;
  right: 28px;
  z-index: 60;
  width: 48px;
  height: 48px;
  background: rgba(17, 17, 17, 0.6);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: background 0.15s;
}

.menu-btn:hover {
  background: var(--color-gold);
}

.menu-icon {
  position: relative;
  width: 20px;
  height: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
}

.menu-line {
  display: block;
  width: 20px;
  height: 2px;
  background: #FFFFFF;
  transition: transform 0.2s, opacity 0.2s, background 0.15s;
}

/* 開いている状態：バツ印に変形 */
.menu-btn.is-open .menu-icon {
  height: 20px;
}

.menu-btn.is-open .menu-line {
  position: absolute;
  top: 50%;
  left: 50%;
  height: 1.5px;
}

.menu-btn.is-open .menu-line:nth-child(1) {
  transform: translate(-50%, -50%) rotate(45deg);
}

.menu-btn.is-open .menu-line:nth-child(2) {
  opacity: 0;
}

.menu-btn.is-open .menu-line:nth-child(3) {
  transform: translate(-50%, -50%) rotate(-45deg);
}

/* --------------------------------------------------------------------------
   右端：スクロールレベル表示（デスクトップのみ）
   -------------------------------------------------------------------------- */

.scroll-nav {
  position: fixed;
  right: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 30;
}

.scroll-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 22px;
  align-items: center;
}

.scroll-nav li {
  position: relative;
  display: flex;
  align-items: center;
}

.scroll-nav__label {
  position: absolute;
  right: 22px;
  white-space: nowrap;
  background: var(--color-text);
  color: #FFFFFF;
  font-size: 11px;
  letter-spacing: 0.05em;
  padding: 6px 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}

.scroll-nav li:hover .scroll-nav__label {
  opacity: 1;
}

.scroll-nav__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1px solid var(--color-text);
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.scroll-nav__dot.is-active {
  border-color: var(--color-gold);
  background: var(--color-gold);
}

/* --------------------------------------------------------------------------
   フルスクリーン オーバーレイメニュー
   -------------------------------------------------------------------------- */

@keyframes menuFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
  display: none;
  align-items: center;
  justify-content: center;
  animation: menuFade 0.2s ease;
}

.menu-overlay.is-open {
  display: flex;
}

.menu-overlay ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 28px;
  text-align: center;
}

.menu-overlay button {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 28px;
  font-weight: 500;
  color: #FFFFFF;
  padding: 4px 0;
  transition: color 0.15s;
}

.menu-overlay button:hover,
.menu-overlay button.is-active {
  color: var(--color-gold);
}

/* --------------------------------------------------------------------------
   メインコンテンツ
   -------------------------------------------------------------------------- */

.main-content {
  position: relative;
  z-index: 10;
  margin-left: auto;
  width: min(560px, calc(100vw - 220px));
  margin-right: 110px;
  padding-top: 180px;
  display: flex;
  flex-direction: column;
}

.panel {
  background: var(--panel-bg);
  border-radius: 20px;
  color: #FFFFFF;
  padding: 48px 44px;
  margin-bottom: 40px;
}

.panel--hero {
  background: var(--panel-bg-hero);
  border-radius: 0;
  padding: 56px 44px;
  margin-bottom: 64px;
}

.eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  letter-spacing: 0.15em;
  color: var(--color-gold);
  margin: 0 0 20px;
}

.panel--hero h1 {
  font-size: 30px;
  line-height: 1.6;
  font-weight: 700;
  margin: 0;
}

.panel__head {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 28px;
}

.panel__num {
  font-family: 'Inter', sans-serif;
  font-size: 56px;
  line-height: 1;
  color: var(--color-gold);
  font-weight: 700;
}

.panel__head h2 {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
}

.panel__lead {
  font-size: 14px;
  line-height: 1.9;
  color: #DDDDDD;
  margin: 0 0 36px;
}

/* 会社概要 */

.about-list {
  margin: 0;
  display: flex;
  flex-direction: column;
}

.about-list__row {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.about-list__row--last {
  border-bottom: none;
}

.about-list dt {
  color: #AAAAAA;
  font-size: 13px;
}

.about-list dd {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

/* 事業内容／選ばれる理由 */

.service-list {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.service-item {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 20px;
}

.service-item--noborder {
  border-top: none;
  padding-top: 0;
}

.service-item h3 {
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 10px;
}

.service-item p {
  font-size: 13.5px;
  line-height: 1.9;
  color: #AAAAAA;
  margin: 0;
}

/* アクセス */

.map-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  filter: grayscale(1) contrast(1.05);
  margin-bottom: 20px;
}

.access-address {
  font-size: 14px;
  line-height: 1.8;
  margin: 0 0 8px;
}

.access-note {
  font-size: 13.5px;
  line-height: 1.8;
  color: #AAAAAA;
  margin: 0;
}

/* お問い合わせ */

.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #FFFFFF;
  padding: 16px 28px;
  font-size: 14px;
  color: #FFFFFF;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.contact-btn:hover {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--color-text);
}

/* フッター */

.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 32px 0 64px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer p {
  font-size: 12px;
  color: var(--color-sub);
  margin: 0;
}

.site-footer a {
  font-size: 12px;
  color: var(--color-sub);
}

.site-footer a:hover {
  color: var(--color-gold);
}

/* ==========================================================================
   レスポンシブ（タブレット・モバイル：〜1024px）
   ========================================================================== */

@media (max-width: 1024px) {
  .site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 64px;
    background: #FFFFFF;
    padding: 0 20px;
    box-shadow: 0 1px 0 var(--color-border);
    display: flex;
    align-items: center;
  }

  .site-header__logo-link {
    flex-direction: row;
    align-items: center;
    gap: 10px;
  }

  .site-header img {
    height: 32px;
  }

  .menu-btn {
    top: 8px;
    right: 16px;
    background: #FFFFFF;
    border: none;
  }

  .menu-btn .menu-line {
    background: var(--color-text);
  }

  .main-content {
    padding-top: 50vh;
    width: 95%;
    margin-right: auto;
    margin-left: auto;
  }

  .scroll-nav {
    display: none;
  }
}

@media (max-width: 640px) {
  .bg-medal {
    height: 90vh;
    left: -46vh;
  }
}
