/* =============================================
   common.css — 全ページ共通スタイル
   つおき高橋クリニック
   ============================================= */

/* --- CSS カスタムプロパティ --- */
:root {
  --color-main: #5BB8D4;
  --color-main-dark: #3d9ab8;
  --color-main-light: #e8f6fb;
  --color-sub: #6DBF87;
  --color-sub-dark: #4fa36b;
  --color-sub-light: #eaf7ee;
  --color-bg: #FFFFFF;
  --color-bg-gray: #F5F9FC;
  --color-text: #333333;
  --color-text-light: #666666;
  --color-text-muted: #999999;
  --color-accent: #F5A623;
  --color-border: #D8ECF4;
  --color-white: #FFFFFF;

  --font-family: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
  --font-size-base: 16px;
  --font-size-sm: 0.875rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.5rem;
  --font-size-2xl: 2rem;
  --font-size-3xl: 2.5rem;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 8px rgba(91, 184, 212, 0.12);
  --shadow-md: 0 4px 16px rgba(91, 184, 212, 0.18);
  --shadow-lg: 0 8px 32px rgba(91, 184, 212, 0.22);

  --transition: 0.25s ease;
  --container-width: 1100px;
  --header-height: 70px;
}

/* --- リセット & ベース --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: var(--font-size-base);
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* --- コンテナ --- */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* =============================================
   ヘッダー
   ============================================= */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background: var(--color-white);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  z-index: 1000;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.site-logo {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  line-height: 1.2;
}

.site-logo .logo-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-main-dark);
  letter-spacing: 0.03em;
}

.site-logo .logo-sub {
  font-size: 0.7rem;
  color: var(--color-text-light);
  letter-spacing: 0.05em;
}

/* グローバルナビ */
.global-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.global-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-text);
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
}

.global-nav a:hover,
.global-nav a.active {
  color: var(--color-main-dark);
  background: var(--color-main-light);
}

.global-nav a i {
  font-size: 1rem;
  margin-bottom: 2px;
  color: var(--color-main);
}

/* 電話番号ボタン */
.header-tel {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--color-main);
  color: var(--color-white) !important;
  border-radius: var(--radius-md);
  padding: 6px 14px !important;
  transition: background var(--transition) !important;
}

.header-tel:hover {
  background: var(--color-main-dark) !important;
  color: var(--color-white) !important;
}

.header-tel i {
  color: var(--color-white) !important;
}

/* ハンバーガーボタン */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: background var(--transition);
}

.hamburger:hover {
  background: var(--color-main-light);
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.hamburger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.is-open span:nth-child(2) {
  opacity: 0;
}

.hamburger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* =============================================
   フッター
   ============================================= */
.site-footer {
  background: #2a4a5e;
  color: rgba(255, 255, 255, 0.85);
  padding: 48px 0 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand .footer-logo {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 8px;
  display: block;
}

.footer-brand p {
  font-size: var(--font-size-sm);
  line-height: 1.7;
}

.footer-info h3,
.footer-hours h3 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-main);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.footer-info p {
  font-size: var(--font-size-sm);
  line-height: 2;
}

.footer-info a {
  color: rgba(255, 255, 255, 0.85);
  transition: color var(--transition);
}

.footer-info a:hover {
  color: var(--color-main);
}

.hours-table {
  font-size: var(--font-size-sm);
  width: 100%;
  border-collapse: collapse;
}

.hours-table td {
  padding: 3px 8px 3px 0;
  vertical-align: top;
}

.hours-table th {
  white-space: nowrap;
  color: var(--color-main);
  font-weight: 500;
  text-align: left;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
}

.page-top-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  transition: color var(--transition);
}

.page-top-btn:hover {
  color: var(--color-main);
}

/* =============================================
   共通セクション
   ============================================= */
.section {
  padding: 72px 0;
}

.section-alt {
  background: var(--color-bg-gray);
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-main);
  margin-bottom: 8px;
}

.section-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--color-text);
  position: relative;
  display: inline-block;
  padding-bottom: 16px;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-main), var(--color-sub));
  border-radius: 2px;
}

.section-desc {
  margin-top: 16px;
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* =============================================
   ページヒーロー（内ページ共通）
   ============================================= */
.page-hero {
  background: linear-gradient(135deg, var(--color-main) 0%, var(--color-sub) 100%);
  padding: 48px 0;
  text-align: center;
  color: var(--color-white);
}

.page-hero-label {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  opacity: 0.8;
  margin-bottom: 8px;
}

.page-hero-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
}

/* パンくず */
.breadcrumb {
  padding: 12px 0;
  background: var(--color-bg-gray);
  border-bottom: 1px solid var(--color-border);
}

.breadcrumb ol {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.breadcrumb ol li + li::before {
  content: '›';
  margin-right: 8px;
}

.breadcrumb ol a {
  color: var(--color-main-dark);
}

.breadcrumb ol a:hover {
  text-decoration: underline;
}

/* =============================================
   ボタン
   ============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 28px;
  font-size: var(--font-size-sm);
  font-weight: 600;
  border-radius: var(--radius-full);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-main);
  color: var(--color-white);
  border-color: var(--color-main);
}

.btn-primary:hover {
  background: var(--color-main-dark);
  border-color: var(--color-main-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: var(--color-white);
  color: var(--color-main-dark);
  border-color: var(--color-main);
}

.btn-secondary:hover {
  background: var(--color-main-light);
  transform: translateY(-2px);
}

.btn-sub {
  background: var(--color-sub);
  color: var(--color-white);
  border-color: var(--color-sub);
}

.btn-sub:hover {
  background: var(--color-sub-dark);
  border-color: var(--color-sub-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* =============================================
   カード
   ============================================= */
.card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* =============================================
   お知らせ共通
   ============================================= */
.news-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  background: var(--color-main-light);
  color: var(--color-main-dark);
}

.news-badge.badge-important {
  background: #fff0e8;
  color: #e07030;
}

/* =============================================
   レスポンシブ（768px以下）
   ============================================= */
@media (max-width: 768px) {
  :root {
    --header-height: 60px;
  }

  /* ハンバーガー表示 */
  .hamburger {
    display: flex;
  }

  /* グローバルナビ */
  .global-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: var(--color-white);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 16px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform var(--transition);
    box-shadow: var(--shadow-lg);
  }

  .global-nav.is-open {
    transform: translateX(0);
  }

  .global-nav a {
    flex-direction: row;
    justify-content: flex-start;
    padding: 14px 16px;
    font-size: 1rem;
    border-radius: var(--radius-md);
    gap: 12px;
    min-height: 44px;
  }

  .global-nav a i {
    width: 24px;
    text-align: center;
    margin-bottom: 0;
  }

  .header-tel {
    flex-direction: row;
    padding: 14px 16px !important;
  }

  /* フッター */
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  /* セクション */
  .section {
    padding: 48px 0;
  }

  .section-title {
    font-size: 1.6rem;
  }
}
