/*
 * ============================================================
 *  Golden Memory — 골든 메모리
 *  프리미엄 AI 자서전 플랫폼 공통 스타일시트
 * ============================================================
 *  디자인 컨셉: 럭셔리 (화이트 + 골드 + 실버 + 블랙)
 *  고급 주얼리 브랜드를 연상시키는 세련된 디자인
 * ============================================================
 */

/* ─────────────────────────────────────────────
   0. 웹폰트 임포트
   ───────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Nanum+Myeongjo:wght@400;700;800&display=swap');

/* ─────────────────────────────────────────────
   1. CSS 변수 (디자인 토큰)
   ───────────────────────────────────────────── */
:root {
  /* ── 색상: 배경 ── */
  --gm-white: #FFFFFF;
  --gm-white-warm: #FAFAFA;
  --gm-gold-tint-bg: #F5F0E6;

  /* ── 색상: 골드 ── */
  --gm-gold-deep: #C5A55A;
  --gm-gold: #D4AF37;
  --gm-gold-light: #E8D5A3;
  --gm-gold-hover: #B8963E;
  --gm-gold-glow: rgba(212, 175, 55, 0.25);

  /* ── 색상: 실버 ── */
  --gm-silver: #C0C0C0;
  --gm-silver-dark: #A8A8A8;

  /* ── 색상: 블랙 / 텍스트 ── */
  --gm-black: #1A1A1A;
  --gm-black-heading: #2D2D2D;
  --gm-black-body: #4A4A4A;
  --gm-black-muted: #6E6E6E;
  --gm-black-subtle: #999999;

  /* ── 색상: 기능성 ── */
  --gm-success: #4A7C59;
  --gm-error: #C44536;
  --gm-info: #4A6FA5;

  /* ── 그라데이션 ── */
  --gm-gradient-gold: linear-gradient(135deg, #C5A55A 0%, #D4AF37 50%, #E8D5A3 100%);
  --gm-gradient-dark: linear-gradient(135deg, #1A1A1A 0%, #2D2D2D 100%);
  --gm-gradient-hero: linear-gradient(180deg, rgba(26, 26, 26, 0.7) 0%, rgba(26, 26, 26, 0.3) 100%);

  /* ── 서체 ── */
  --gm-font-serif: 'Nanum Myeongjo', 'Batang', Georgia, serif;
  --gm-font-sans: 'Pretendard', 'Spoqa Han Sans Neo', 'Spoqa Han Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* ── 글자 크기 (모바일 기준) ── */
  --gm-text-xs: 0.75rem;    /* 12px */
  --gm-text-sm: 0.875rem;   /* 14px */
  --gm-text-base: 1rem;     /* 16px → 데스크탑 18px */
  --gm-text-lg: 1.125rem;   /* 18px */
  --gm-text-xl: 1.25rem;    /* 20px */
  --gm-text-2xl: 1.5rem;    /* 24px */
  --gm-text-3xl: 1.875rem;  /* 30px */
  --gm-text-4xl: 2.25rem;   /* 36px */
  --gm-text-5xl: 3rem;      /* 48px */

  /* ── 줄간격 ── */
  --gm-leading-tight: 1.3;
  --gm-leading-normal: 1.6;
  --gm-leading-relaxed: 1.8;
  --gm-leading-loose: 2.0;

  /* ── 간격 ── */
  --gm-space-xs: 0.25rem;   /* 4px */
  --gm-space-sm: 0.5rem;    /* 8px */
  --gm-space-md: 1rem;      /* 16px */
  --gm-space-lg: 1.5rem;    /* 24px */
  --gm-space-xl: 2rem;      /* 32px */
  --gm-space-2xl: 3rem;     /* 48px */
  --gm-space-3xl: 4rem;     /* 64px */
  --gm-space-4xl: 6rem;     /* 96px */

  /* ── 모서리 둥글기 ── */
  --gm-radius-sm: 4px;
  --gm-radius-md: 8px;
  --gm-radius-lg: 12px;
  --gm-radius-xl: 16px;
  --gm-radius-full: 9999px;

  /* ── 그림자 ── */
  --gm-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --gm-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --gm-shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.1);
  --gm-shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.12);
  --gm-shadow-gold: 0 4px 16px rgba(197, 165, 90, 0.2);

  /* ── 전환 ── */
  --gm-transition-fast: 150ms ease;
  --gm-transition: 250ms ease;
  --gm-transition-slow: 400ms ease;

  /* ── 레이아웃 ── */
  --gm-max-width: 1200px;
  --gm-header-height: 72px;

  /* ── z-index 관리 ── */
  --gm-z-dropdown: 100;
  --gm-z-sticky: 200;
  --gm-z-header: 300;
  --gm-z-overlay: 400;
  --gm-z-modal: 500;
}


/* ─────────────────────────────────────────────
   2. 리셋 & 기본 스타일
   ───────────────────────────────────────────── */

/* 박스 모델 리셋 */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* HTML 기본 설정 — 시니어 접근성을 위한 큰 글자 */
html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--gm-font-sans);
  font-size: var(--gm-text-base);
  line-height: var(--gm-leading-normal);
  color: var(--gm-black-body);
  background-color: var(--gm-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  word-break: keep-all;            /* 한국어 줄바꿈 최적화 */
  overflow-wrap: break-word;
}

/* 이미지 리셋 */
img,
picture,
video,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* 링크 기본 스타일 */
a {
  color: var(--gm-gold-deep);
  text-decoration: none;
  transition: color var(--gm-transition-fast);
}
a:hover {
  color: var(--gm-gold-hover);
}

/* 목록 리셋 */
ul, ol {
  list-style: none;
}

/* 테이블 리셋 */
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* 버튼/입력 폰트 상속 */
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

/* 제목 기본 스타일 — 명조체 */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--gm-font-serif);
  color: var(--gm-black-heading);
  line-height: var(--gm-leading-tight);
  font-weight: 700;
}

h1 { font-size: var(--gm-text-4xl); }
h2 { font-size: var(--gm-text-3xl); }
h3 { font-size: var(--gm-text-2xl); }
h4 { font-size: var(--gm-text-xl); }
h5 { font-size: var(--gm-text-lg); }
h6 { font-size: var(--gm-text-base); }

/* 단락 간격 */
p + p {
  margin-top: var(--gm-space-md);
}

/* 선택 영역 골드 하이라이트 */
::selection {
  background-color: var(--gm-gold-light);
  color: var(--gm-black);
}


/* ─────────────────────────────────────────────
   3. 레이아웃: 컨테이너
   ───────────────────────────────────────────── */
.gm-container {
  width: 100%;
  max-width: var(--gm-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--gm-space-md);
  padding-right: var(--gm-space-md);
}

/* 좁은 컨테이너 (본문용) */
.gm-container--narrow {
  max-width: 800px;
}

/* 넓은 컨테이너 */
.gm-container--wide {
  max-width: 1400px;
}


/* ─────────────────────────────────────────────
   4. 헤더
   ───────────────────────────────────────────── */
.gm-header {
  position: sticky;
  top: 0;
  z-index: var(--gm-z-header);
  height: var(--gm-header-height);
  background-color: var(--gm-white);
  border-bottom: 1px solid var(--gm-gold-light);
  display: flex;
  align-items: center;
  transition: box-shadow var(--gm-transition);
}

/* 스크롤 시 그림자 효과 (JS로 .is-scrolled 클래스 추가) */
.gm-header.is-scrolled {
  box-shadow: var(--gm-shadow-md);
}

.gm-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--gm-max-width);
  margin: 0 auto;
  padding: 0 var(--gm-space-md);
}

/* 로고 */
.gm-header__logo {
  display: flex;
  align-items: center;
  gap: var(--gm-space-sm);
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-xl);
  font-weight: 800;
  color: var(--gm-black);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.gm-header__logo:hover {
  color: var(--gm-black);
}

/* 로고 골드 악센트 */
.gm-header__logo-accent {
  color: var(--gm-gold-deep);
}

/* 로고 아이콘/이미지 */
.gm-header__logo-icon {
  width: 36px;
  height: 36px;
}

/* 헤더 우측 영역 */
.gm-header__actions {
  display: flex;
  align-items: center;
  gap: var(--gm-space-md);
}


/* ─────────────────────────────────────────────
   5. 네비게이션
   ───────────────────────────────────────────── */
.gm-nav {
  display: flex;
  align-items: center;
  gap: var(--gm-space-lg);
}

.gm-nav__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: var(--gm-space-sm) 0;
  font-size: var(--gm-text-sm);
  font-weight: 500;
  color: var(--gm-black-body);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color var(--gm-transition-fast);
}

.gm-nav__link:hover {
  color: var(--gm-gold-deep);
}

/* 골드 밑줄 — 활성 상태 */
.gm-nav__link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--gm-gradient-gold);
  transition: width var(--gm-transition);
}

.gm-nav__link:hover::after,
.gm-nav__link.is-active::after {
  width: 100%;
}

.gm-nav__link.is-active {
  color: var(--gm-gold-deep);
  font-weight: 700;
}

/* 모바일 네비게이션 토글 */
.gm-nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--gm-space-sm);
  color: var(--gm-black);
}

.gm-nav-toggle__bar {
  display: block;
  width: 24px;
  height: 2px;
  background-color: currentColor;
  margin: 5px 0;
  transition: transform var(--gm-transition), opacity var(--gm-transition);
}


/* ─────────────────────────────────────────────
   6. 버튼
   ───────────────────────────────────────────── */

/* 공통 버튼 베이스 */
.gm-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--gm-space-sm);
  padding: 14px 28px;
  font-family: var(--gm-font-sans);
  font-size: var(--gm-text-sm);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: var(--gm-radius-sm);
  cursor: pointer;
  transition: all var(--gm-transition);
  white-space: nowrap;
  user-select: none;
}

.gm-btn:focus-visible {
  outline: 3px solid var(--gm-gold);
  outline-offset: 2px;
}

/* 골드 배경 + 블랙 텍스트 (기본) */
.gm-btn--gold,
.gm-btn {
  background: var(--gm-gradient-gold);
  color: var(--gm-black);
  border-color: var(--gm-gold-deep);
}
.gm-btn--gold:hover,
.gm-btn:hover {
  background: var(--gm-gold-hover);
  border-color: var(--gm-gold-hover);
  box-shadow: var(--gm-shadow-gold);
  transform: translateY(-1px);
  color: var(--gm-black);
}
.gm-btn--gold:active,
.gm-btn:active {
  transform: translateY(0);
  box-shadow: none;
}

/* 블랙 배경 + 골드 텍스트 */
.gm-btn--dark {
  background: var(--gm-gradient-dark);
  color: var(--gm-gold);
  border-color: var(--gm-black);
}
.gm-btn--dark:hover {
  background: var(--gm-black);
  color: var(--gm-gold-light);
  box-shadow: var(--gm-shadow-lg);
  transform: translateY(-1px);
}

/* 골드 아웃라인 버튼 */
.gm-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--gm-space-sm);
  padding: 12px 26px;
  font-family: var(--gm-font-sans);
  font-size: var(--gm-text-sm);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
  background: transparent;
  color: var(--gm-gold-deep);
  border: 2px solid var(--gm-gold-deep);
  border-radius: var(--gm-radius-sm);
  cursor: pointer;
  transition: all var(--gm-transition);
  white-space: nowrap;
  user-select: none;
}
.gm-btn-outline:hover {
  background-color: var(--gm-gold-deep);
  color: var(--gm-white);
  box-shadow: var(--gm-shadow-gold);
  transform: translateY(-1px);
}
.gm-btn-outline:active {
  transform: translateY(0);
}
.gm-btn-outline:focus-visible {
  outline: 3px solid var(--gm-gold);
  outline-offset: 2px;
}

/* 버튼 크기 변형 */
.gm-btn--sm {
  padding: 8px 18px;
  font-size: var(--gm-text-xs);
}
.gm-btn--lg {
  padding: 18px 40px;
  font-size: var(--gm-text-base);
}

/* 비활성 버튼 */
.gm-btn:disabled,
.gm-btn-outline:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}


/* ─────────────────────────────────────────────
   7. 카드
   ───────────────────────────────────────────── */
.gm-card {
  background: var(--gm-white);
  border: 1px solid var(--gm-gold-light);
  border-radius: var(--gm-radius-lg);
  box-shadow: var(--gm-shadow-sm);
  overflow: hidden;
  transition: box-shadow var(--gm-transition), transform var(--gm-transition);
}

.gm-card:hover {
  box-shadow: var(--gm-shadow-lg);
  transform: translateY(-2px);
}

/* 카드 내부 영역 */
.gm-card__header {
  padding: var(--gm-space-lg);
  background: var(--gm-gradient-dark);
  color: var(--gm-white);
}

.gm-card__header-title {
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-lg);
  color: var(--gm-gold-light);
  margin: 0;
}

.gm-card__body {
  padding: var(--gm-space-lg);
}

.gm-card__footer {
  padding: var(--gm-space-md) var(--gm-space-lg);
  border-top: 1px solid var(--gm-gold-light);
  background-color: var(--gm-white-warm);
}

/* 카드 이미지 */
.gm-card__image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

/* 골드 테두리 강조 카드 */
.gm-card--featured {
  border-color: var(--gm-gold-deep);
  border-width: 2px;
  box-shadow: var(--gm-shadow-gold);
}


/* ─────────────────────────────────────────────
   8. 배지 (시니어 이니셜용)
   ───────────────────────────────────────────── */
.gm-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--gm-radius-full);
  background: var(--gm-gradient-gold);
  color: var(--gm-black);
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-lg);
  font-weight: 800;
  letter-spacing: -0.02em;
  flex-shrink: 0;
  box-shadow: var(--gm-shadow-gold);
}

/* 배지 크기 변형 */
.gm-badge--sm {
  width: 36px;
  height: 36px;
  font-size: var(--gm-text-sm);
}

.gm-badge--lg {
  width: 64px;
  height: 64px;
  font-size: var(--gm-text-2xl);
}

.gm-badge--xl {
  width: 80px;
  height: 80px;
  font-size: var(--gm-text-3xl);
}

/* 실버 배지 변형 */
.gm-badge--silver {
  background: linear-gradient(135deg, var(--gm-silver) 0%, #E0E0E0 100%);
  color: var(--gm-black-heading);
  box-shadow: 0 4px 16px rgba(192, 192, 192, 0.3);
}


/* ─────────────────────────────────────────────
   9. 태그 (카테고리 칩)
   ───────────────────────────────────────────── */
.gm-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--gm-space-xs);
  padding: 4px 12px;
  font-size: var(--gm-text-xs);
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--gm-gold-deep);
  background: transparent;
  border: 1px solid var(--gm-gold-deep);
  border-radius: var(--gm-radius-full);
  white-space: nowrap;
  transition: all var(--gm-transition-fast);
}

.gm-tag:hover {
  background-color: var(--gm-gold-deep);
  color: var(--gm-white);
}

/* 채워진 태그 */
.gm-tag--filled {
  background: var(--gm-gold-tint-bg);
  border-color: var(--gm-gold-light);
  color: var(--gm-gold-deep);
}

/* 다크 태그 */
.gm-tag--dark {
  background-color: var(--gm-black);
  border-color: var(--gm-black);
  color: var(--gm-gold);
}


/* ─────────────────────────────────────────────
   10. 폼 입력 필드
   ───────────────────────────────────────────── */
.gm-input {
  display: block;
  width: 100%;
  padding: 14px 16px;
  font-size: var(--gm-text-base);
  line-height: var(--gm-leading-normal);
  color: var(--gm-black-body);
  background-color: var(--gm-white);
  border: 1px solid var(--gm-silver);
  border-radius: var(--gm-radius-md);
  transition: border-color var(--gm-transition-fast), box-shadow var(--gm-transition-fast);
  appearance: none;
}

.gm-input::placeholder {
  color: var(--gm-black-subtle);
}

/* 포커스 시 골드 링 */
.gm-input:focus {
  outline: none;
  border-color: var(--gm-gold-deep);
  box-shadow: 0 0 0 3px var(--gm-gold-glow);
}

/* 라벨 */
.gm-label {
  display: block;
  margin-bottom: var(--gm-space-sm);
  font-size: var(--gm-text-sm);
  font-weight: 600;
  color: var(--gm-black-heading);
}

/* 텍스트 영역 */
textarea.gm-input {
  min-height: 120px;
  resize: vertical;
}

/* 셀렉트 박스 */
select.gm-input {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23C5A55A' d='M6 8.825L0.375 3.175l0.85-0.85L6 7.125l4.775-4.8 0.85 0.85z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

/* 입력 필드 그룹 */
.gm-form-group {
  margin-bottom: var(--gm-space-lg);
}

/* 입력 오류 상태 */
.gm-input--error {
  border-color: var(--gm-error);
}
.gm-input--error:focus {
  box-shadow: 0 0 0 3px rgba(196, 69, 54, 0.2);
}

.gm-form-error {
  margin-top: var(--gm-space-xs);
  font-size: var(--gm-text-sm);
  color: var(--gm-error);
}


/* ─────────────────────────────────────────────
   11. 푸터
   ───────────────────────────────────────────── */
.gm-footer {
  margin-top: var(--gm-space-4xl);
  padding: var(--gm-space-3xl) 0 var(--gm-space-xl);
  background: var(--gm-gradient-dark);
  color: var(--gm-silver);
}

.gm-footer__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gm-space-xl);
  max-width: var(--gm-max-width);
  margin: 0 auto;
  padding: 0 var(--gm-space-md);
}

.gm-footer__brand {
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-xl);
  font-weight: 800;
  color: var(--gm-gold-light);
  margin-bottom: var(--gm-space-sm);
}

.gm-footer__desc {
  font-size: var(--gm-text-sm);
  line-height: var(--gm-leading-relaxed);
  color: var(--gm-silver-dark);
  max-width: 320px;
}

.gm-footer__heading {
  font-family: var(--gm-font-sans);
  font-size: var(--gm-text-sm);
  font-weight: 600;
  color: var(--gm-gold-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--gm-space-md);
}

.gm-footer__link {
  display: block;
  padding: var(--gm-space-xs) 0;
  font-size: var(--gm-text-sm);
  color: var(--gm-silver-dark);
  text-decoration: none;
  transition: color var(--gm-transition-fast);
}

.gm-footer__link:hover {
  color: var(--gm-gold);
}

/* 푸터 하단 저작권 영역 */
.gm-footer__bottom {
  margin-top: var(--gm-space-2xl);
  padding-top: var(--gm-space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: var(--gm-text-xs);
  color: var(--gm-black-subtle);
}

/* 푸터 골드 구분선 */
.gm-footer__gold-line {
  width: 60px;
  height: 2px;
  background: var(--gm-gradient-gold);
  margin-bottom: var(--gm-space-lg);
}


/* ─────────────────────────────────────────────
   12. 페이지 타이틀
   ───────────────────────────────────────────── */
.gm-page-title {
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-4xl);
  font-weight: 800;
  color: var(--gm-black);
  line-height: var(--gm-leading-tight);
  letter-spacing: -0.02em;
  margin-bottom: var(--gm-space-md);
}

.gm-page-title--gold {
  background: var(--gm-gradient-gold);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* 부제목 */
.gm-page-subtitle {
  font-family: var(--gm-font-sans);
  font-size: var(--gm-text-lg);
  font-weight: 400;
  color: var(--gm-black-muted);
  line-height: var(--gm-leading-relaxed);
}


/* ─────────────────────────────────────────────
   13. 구분선
   ───────────────────────────────────────────── */
.gm-divider {
  border: none;
  height: 1px;
  background: var(--gm-gold-light);
  margin: var(--gm-space-xl) 0;
}

/* 골드 그라데이션 구분선 */
.gm-divider--gold {
  height: 2px;
  background: var(--gm-gradient-gold);
}

/* 짧은 중앙 구분선 (장식용) */
.gm-divider--short {
  width: 80px;
  margin-left: auto;
  margin-right: auto;
}

/* 별표 장식 구분선 */
.gm-divider--ornament {
  display: flex;
  align-items: center;
  gap: var(--gm-space-md);
  border: none;
  height: auto;
  background: none;
}
.gm-divider--ornament::before,
.gm-divider--ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gm-gold-light);
}
.gm-divider--ornament::before { margin-right: 0; }
.gm-divider--ornament::after { margin-left: 0; }


/* ─────────────────────────────────────────────
   14. 히어로 섹션
   ───────────────────────────────────────────── */
.gm-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 480px;
  padding: var(--gm-space-4xl) var(--gm-space-md);
  background-color: var(--gm-black);
  background-size: cover;
  background-position: center;
  overflow: hidden;
  text-align: center;
}

/* 오버레이 (배경 이미지 위 어둡게) */
.gm-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gm-gradient-hero);
  z-index: 1;
}

.gm-hero__content {
  position: relative;
  z-index: 2;
  max-width: 720px;
}

.gm-hero__title {
  font-family: var(--gm-font-serif);
  font-size: var(--gm-text-5xl);
  font-weight: 800;
  color: var(--gm-white);
  line-height: var(--gm-leading-tight);
  margin-bottom: var(--gm-space-md);
  letter-spacing: -0.02em;
}

/* 히어로 타이틀 골드 강조 */
.gm-hero__title .gm-highlight {
  color: var(--gm-gold);
}

.gm-hero__subtitle {
  font-size: var(--gm-text-lg);
  color: var(--gm-silver);
  line-height: var(--gm-leading-relaxed);
  margin-bottom: var(--gm-space-xl);
}

/* 히어로 골드 장식선 */
.gm-hero__ornament {
  display: inline-block;
  width: 60px;
  height: 2px;
  background: var(--gm-gradient-gold);
  margin-bottom: var(--gm-space-lg);
}


/* ─────────────────────────────────────────────
   15. 유틸리티 클래스
   ───────────────────────────────────────────── */

/* 텍스트 색상 */
.text-gold       { color: var(--gm-gold-deep) !important; }
.text-gold-light { color: var(--gm-gold-light) !important; }
.text-silver     { color: var(--gm-silver) !important; }
.text-black      { color: var(--gm-black) !important; }
.text-muted      { color: var(--gm-black-muted) !important; }
.text-white      { color: var(--gm-white) !important; }

/* 배경 색상 */
.bg-gold-tint    { background-color: var(--gm-gold-tint-bg) !important; }
.bg-gold         { background: var(--gm-gradient-gold) !important; }
.bg-dark         { background: var(--gm-gradient-dark) !important; }
.bg-white        { background-color: var(--gm-white) !important; }
.bg-warm         { background-color: var(--gm-white-warm) !important; }

/* 서체 */
.serif           { font-family: var(--gm-font-serif) !important; }
.sans            { font-family: var(--gm-font-sans) !important; }

/* 텍스트 정렬 */
.text-center     { text-align: center !important; }
.text-left       { text-align: left !important; }
.text-right      { text-align: right !important; }

/* 글자 굵기 */
.font-normal     { font-weight: 400 !important; }
.font-medium     { font-weight: 500 !important; }
.font-bold       { font-weight: 700 !important; }
.font-extrabold  { font-weight: 800 !important; }

/* 간격 유틸리티 */
.mt-0  { margin-top: 0 !important; }
.mt-sm { margin-top: var(--gm-space-sm) !important; }
.mt-md { margin-top: var(--gm-space-md) !important; }
.mt-lg { margin-top: var(--gm-space-lg) !important; }
.mt-xl { margin-top: var(--gm-space-xl) !important; }

.mb-0  { margin-bottom: 0 !important; }
.mb-sm { margin-bottom: var(--gm-space-sm) !important; }
.mb-md { margin-bottom: var(--gm-space-md) !important; }
.mb-lg { margin-bottom: var(--gm-space-lg) !important; }
.mb-xl { margin-bottom: var(--gm-space-xl) !important; }

.pt-0  { padding-top: 0 !important; }
.pt-lg { padding-top: var(--gm-space-lg) !important; }
.pt-xl { padding-top: var(--gm-space-xl) !important; }

.pb-0  { padding-bottom: 0 !important; }
.pb-lg { padding-bottom: var(--gm-space-lg) !important; }
.pb-xl { padding-bottom: var(--gm-space-xl) !important; }

/* 섹션 간격 */
.gm-section {
  padding-top: var(--gm-space-3xl);
  padding-bottom: var(--gm-space-3xl);
}

/* 화면 읽기 전용 (스크린 리더) */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 플렉스 유틸리티 */
.flex          { display: flex !important; }
.flex-col      { flex-direction: column !important; }
.items-center  { align-items: center !important; }
.justify-center { justify-content: center !important; }
.justify-between { justify-content: space-between !important; }
.gap-sm        { gap: var(--gm-space-sm) !important; }
.gap-md        { gap: var(--gm-space-md) !important; }
.gap-lg        { gap: var(--gm-space-lg) !important; }


/* ─────────────────────────────────────────────
   16. 접근성 (포커스 & 고대비)
   ───────────────────────────────────────────── */

/* 키보드 포커스 시 명확한 골드 아웃라인 */
:focus-visible {
  outline: 3px solid var(--gm-gold);
  outline-offset: 2px;
}

/* 마우스 클릭 시 아웃라인 제거 */
:focus:not(:focus-visible) {
  outline: none;
}

/* 움직임 감소 선호 설정 존중 */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* 고대비 모드 지원 */
@media (forced-colors: active) {
  .gm-btn,
  .gm-btn-outline {
    border: 2px solid ButtonText;
  }
  .gm-badge {
    border: 2px solid ButtonText;
  }
}


/* ─────────────────────────────────────────────
   17. 반응형 — 모바일 우선
   ───────────────────────────────────────────── */

/* ── 480px 이상: 소형 모바일 → 일반 모바일 ── */
@media (min-width: 480px) {
  .gm-container {
    padding-left: var(--gm-space-lg);
    padding-right: var(--gm-space-lg);
  }

  .gm-hero__title {
    font-size: var(--gm-text-4xl);
  }
}

/* ── 768px 이상: 태블릿 ── */
@media (min-width: 768px) {
  html {
    font-size: 17px;
  }

  .gm-header__inner {
    padding: 0 var(--gm-space-lg);
  }

  .gm-footer__inner {
    grid-template-columns: 2fr 1fr 1fr;
    padding: 0 var(--gm-space-lg);
  }

  .gm-hero {
    min-height: 560px;
  }

  .gm-hero__title {
    font-size: var(--gm-text-5xl);
  }

  .gm-page-title {
    font-size: var(--gm-text-5xl);
  }
}

/* ── 1024px 이상: 데스크탑 ── */
@media (min-width: 1024px) {
  html {
    font-size: 18px;
  }

  :root {
    --gm-header-height: 80px;
  }

  .gm-nav {
    gap: var(--gm-space-xl);
  }

  .gm-nav__link {
    font-size: var(--gm-text-base);
  }

  .gm-footer__inner {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }

  .gm-hero {
    min-height: 640px;
    padding: var(--gm-space-4xl) var(--gm-space-xl);
  }

  .gm-card__body {
    padding: var(--gm-space-xl);
  }
}

/* ── 1200px 이상: 대형 데스크탑 ── */
@media (min-width: 1200px) {
  .gm-container {
    padding-left: var(--gm-space-xl);
    padding-right: var(--gm-space-xl);
  }
}

/* ── 768px 미만: 모바일 전용 ── */
@media (max-width: 767px) {
  /* 모바일 네비게이션 */
  .gm-nav-toggle {
    display: block;
  }

  .gm-nav {
    display: none;
    position: fixed;
    top: var(--gm-header-height);
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--gm-space-lg);
    background: var(--gm-white);
    border-top: 1px solid var(--gm-gold-light);
    z-index: var(--gm-z-overlay);
    overflow-y: auto;
  }

  .gm-nav.is-open {
    display: flex;
  }

  .gm-nav__link {
    padding: var(--gm-space-md) 0;
    font-size: var(--gm-text-lg);
    border-bottom: 1px solid var(--gm-gold-light);
  }

  .gm-nav__link::after {
    display: none;
  }

  /* 모바일에서 히어로 축소 */
  .gm-hero {
    min-height: 360px;
    padding: var(--gm-space-2xl) var(--gm-space-md);
  }

  .gm-hero__title {
    font-size: var(--gm-text-3xl);
  }

  /* 모바일에서 카드 간격 축소 */
  .gm-card__body {
    padding: var(--gm-space-md);
  }

  .gm-card__header {
    padding: var(--gm-space-md);
  }

  /* 모바일에서 버튼 전체 너비 */
  .gm-btn--block-mobile,
  .gm-btn-outline--block-mobile {
    width: 100%;
  }
}


/* ─────────────────────────────────────────────
   18. 인쇄 스타일 (A5 자서전 책 형식)
   ───────────────────────────────────────────── */
@media print {
  /* A5 용지 설정 (148mm x 210mm) */
  @page {
    size: A5 portrait;
    margin: 20mm 15mm 25mm 15mm;
  }

  /* 첫 페이지 여백 (타이틀 페이지) */
  @page :first {
    margin-top: 40mm;
  }

  /* 인쇄 시 불필요한 요소 숨김 */
  .gm-header,
  .gm-footer,
  .gm-nav,
  .gm-nav-toggle,
  .gm-btn,
  .gm-btn-outline,
  .gm-hero {
    display: none !important;
  }

  /* 기본 인쇄 스타일 */
  body {
    font-size: 11pt;
    line-height: 1.7;
    color: #000000;
    background: #FFFFFF;
  }

  /* 인쇄용 제목 서체 */
  h1, h2, h3, h4, h5, h6 {
    color: #000000;
    page-break-after: avoid;
    break-after: avoid;
  }

  h1 { font-size: 22pt; margin-bottom: 12pt; }
  h2 { font-size: 16pt; margin-bottom: 10pt; margin-top: 24pt; }
  h3 { font-size: 13pt; margin-bottom: 8pt; }

  /* 단락 */
  p {
    orphans: 3;
    widows: 3;
    text-align: justify;
  }

  /* 이미지 인쇄 최적화 */
  img {
    max-width: 100% !important;
    page-break-inside: avoid;
    break-inside: avoid;
  }

  /* 카드 인쇄 — 테두리만 표시 */
  .gm-card {
    border: 1px solid #CCCCCC;
    box-shadow: none;
    break-inside: avoid;
  }

  .gm-card__header {
    background: #F0F0F0 !important;
    color: #000000 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* 링크 URL 표시 */
  a[href]::after {
    content: ' (' attr(href) ')';
    font-size: 9pt;
    color: #666666;
  }

  /* 내부 링크는 URL 숨김 */
  a[href^="#"]::after,
  a[href^="javascript"]::after {
    content: '';
  }

  /* 구분선 인쇄 */
  .gm-divider {
    background: #CCCCCC;
  }

  /* 페이지 타이틀 인쇄 */
  .gm-page-title {
    font-size: 24pt;
    color: #000000;
    -webkit-text-fill-color: #000000;
    background: none;
  }

  /* 페이지 나눔 유틸리티 */
  .print-break-before {
    page-break-before: always;
    break-before: always;
  }

  .print-break-after {
    page-break-after: always;
    break-after: always;
  }

  .print-avoid-break {
    page-break-inside: avoid;
    break-inside: avoid;
  }
}


/* ─────────────────────────────────────────────
   19. 애니메이션 (부드러운 등장 효과)
   ───────────────────────────────────────────── */

/* 페이드 인 — 아래에서 위로 */
@keyframes gm-fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 페이드 인 */
@keyframes gm-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* 골드 빛남 효과 */
@keyframes gm-shimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}

/* 애니메이션 적용 클래스 */
.gm-animate-fade-in-up {
  animation: gm-fade-in-up 0.6s ease-out both;
}

.gm-animate-fade-in {
  animation: gm-fade-in 0.4s ease-out both;
}

/* 순차 등장 딜레이 */
.gm-delay-1 { animation-delay: 100ms; }
.gm-delay-2 { animation-delay: 200ms; }
.gm-delay-3 { animation-delay: 300ms; }
.gm-delay-4 { animation-delay: 400ms; }
.gm-delay-5 { animation-delay: 500ms; }

/* 골드 시머 텍스트 효과 */
.gm-shimmer-text {
  background: linear-gradient(
    90deg,
    var(--gm-gold-deep) 0%,
    var(--gm-gold-light) 40%,
    var(--gm-gold) 60%,
    var(--gm-gold-deep) 100%
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gm-shimmer 3s linear infinite;
}
