﻿/* ========================================
   전역 스타일 및 기본 설정
   ======================================== */

/* CSS 변수 정의 - 다크 모드 (기본) */
:root {
  --bg-primary: 2 6 23; /* slate-950 */
  --bg-secondary: 15 23 42; /* slate-900 */
  --bg-tertiary: 30 41 59; /* slate-800 */
  --text-primary: 248 250 252; /* slate-50 */
  --text-secondary: 226 232 240; /* slate-200 */
  --text-tertiary: 203 213 225; /* slate-300 */
  --border-color: 255 255 255;
  --border-opacity: 0.1;
  --shadow-color: 0 0 0;
}

/* 라이트 모드 */
:root.light-mode {
  --bg-primary: 248 250 252; /* slate-50 */
  --bg-secondary: 241 245 249; /* slate-100 */
  --bg-tertiary: 226 232 240; /* slate-200 */
  --text-primary: 15 23 42; /* slate-900 */
  --text-secondary: 30 41 59; /* slate-800 */
  --text-tertiary: 51 65 85; /* slate-700 */
  --border-color: 0 0 0;
  --border-opacity: 0.1;
  --shadow-color: 0 0 0;
}

/* 라이트 모드 전체 적용 */
.light-mode body {
  background-color: rgb(248 250 252) !important;
  color: rgb(15 23 42) !important;
}

.light-mode main {
  color: rgb(15 23 42);
}

/* 라이트 모드 그라데이션 버튼 - 더 밝은 파스텔 톤 */
.light-mode .btn-gradient,
.light-mode [class*="bg-gradient-to-r"] {
  background: linear-gradient(to right, #fbbaf6, #fda4c8) !important;
}

.light-mode .btn-gradient:hover,
.light-mode [class*="bg-gradient-to-r"]:hover {
  background: linear-gradient(to right, #f9a8f2, #fc8eb8) !important;
}

/* 라이트 모드 그라데이션 텍스트는 조금 더 진하게 */
.light-mode .gradient-text {
  background: linear-gradient(to right, #c41e5e, #3b4fb8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 제목 색상 */
.light-mode h1,
.light-mode h2,
.light-mode h3 {
  color: rgb(15 23 42) !important;
}

/* 텍스트 색상 */
.light-mode p {
  color: rgb(30 41 59) !important;
}

/* 카드 배경 */
.light-mode .card-hover,
.light-mode [class*="bg-slate-900"],
.light-mode [class*="bg-slate-950"] {
  background-color: rgb(255 255 255) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

/* 헤더 */
.light-mode header {
  background-color: rgba(255, 255, 255, 0.95) !important;
  border-bottom-color: rgba(0, 0, 0, 0.1) !important;
}

/* 네비게이션 링크 */
.light-mode nav a {
  color: rgb(51 65 85) !important;
}

.light-mode nav a:hover {
  color: rgb(15 23 42) !important;
}

/* Badge */
.light-mode [class*="bg-slate-900/80"] {
  background-color: rgba(226, 232, 240, 0.8) !important;
  color: rgb(51 65 85) !important;
}

/* 입력 필드 */
.light-mode input,
.light-mode select,
.light-mode textarea {
  background-color: rgb(248 250 252) !important;
  color: rgb(15 23 42) !important;
  border-color: rgba(0, 0, 0, 0.2) !important;
}

/* 플레이스홀더 */
.light-mode input::placeholder,
.light-mode textarea::placeholder {
  color: rgb(100 116 139) !important;
}

/* 보조 버튼 */
.light-mode [class*="border-white/20"] {
  border-color: rgba(0, 0, 0, 0.2) !important;
  color: rgb(15 23 42) !important;
}

.light-mode [class*="border-white/20"]:hover {
  background-color: rgba(0, 0, 0, 0.05) !important;
  border-color: rgba(0, 0, 0, 0.3) !important;
}

/* FAQ details */
.light-mode details {
  background-color: rgb(255 255 255) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

.light-mode details summary {
  color: rgb(15 23 42) !important;
}

/* 리스트 텍스트 */
.light-mode li,
.light-mode ul,
.light-mode ol {
  color: rgb(30 41 59) !important;
}

/* 경고 박스 (빨간색 박스) */
.light-mode [class*="bg-red-950"] {
  background-color: rgba(254, 226, 226, 0.8) !important;
  border-color: rgba(220, 38, 38, 0.3) !important;
}

.light-mode [class*="text-red"] {
  color: rgb(153 27 27) !important;
}

/* 푸터 */
.light-mode footer {
  color: rgb(100 116 139) !important;
}

/* 모바일 메뉴 */

/* 모바일 메뉴 z-index */
#mobile-menu {
  position: relative;
  z-index: 40;
}

header {
  position: relative;
  z-index: 50;
}

/* 모바일 메뉴 확실하게 보이기 */
#mobile-menu {
  display: none;
}

#mobile-menu:not(.hidden) {
  display: block !important;
  background-color: rgba(2, 6, 23, 0.98) !important;
  backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.light-mode #mobile-menu:not(.hidden) {
  background-color: rgba(255, 255, 255, 0.98) !important;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.light-mode #mobile-menu {
  background-color: rgba(255, 255, 255, 0.98) !important;
}

.light-mode #mobile-menu a {
  color: rgb(51 65 85) !important;
}

/* 작은 텍스트 */
.light-mode [class*="text-slate-300"],
.light-mode [class*="text-slate-400"],
.light-mode [class*="text-slate-500"] {
  color: rgb(100 116 139) !important;
}

/* 폼 라벨 색상 */
.light-mode label,
.light-mode .text-slate-200 {
  color: rgb(51 65 85) !important;
}

/* 모바일 메뉴 버튼 */
.light-mode #mobile-menu-button {
  border-color: rgba(0, 0, 0, 0.2) !important;
  color: rgb(15 23 42) !important;
}

/* 아이콘 색상 */
.light-mode svg {
  color: currentColor;
}

/* 그림자 조정 */
.light-mode .shadow-2xl,
.light-mode .shadow-xl,
.light-mode .shadow-lg {
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.15) !important;
}

/* 언더라인 */
.light-mode [class*="decoration-brandCold"] {
  text-decoration-color: #4a61c3;
}

/* 강조 텍스트 */
.light-mode .font-semibold {
  color: rgb(15 23 42);
}

/* font-semibold가 블록이 되지 않도록 */
.font-semibold {
  display: inline;
}

/* span 요소는 기본적으로 inline */
span.font-semibold {
  display: inline;
}

/* 프로세스 단계 번호 원 */
.light-mode .bg-slate-800 {
  background-color: rgb(226 232 240) !important;
  color: rgb(15 23 42) !important;
}

/* 밝은 텍스트 색상 (다크 모드용이 light 모드에서 안 보임) */
.light-mode [class*="text-slate-50"],
.light-mode [class*="text-slate-100"] {
  color: rgb(15 23 42) !important;
}

/* 흰색 테두리들 */
.light-mode [class*="border-white/10"],
.light-mode [class*="border-white/5"] {
  border-color: rgba(0, 0, 0, 0.15) !important;
}

.light-mode [class*="border-white/10"]:hover,
.light-mode [class*="border-white/5"]:hover {
  border-color: rgba(0, 0, 0, 0.3) !important;
}

/* 흰색 배경 호버 */
.light-mode [class*="hover:bg-white/5"]:hover,
.light-mode [class*="hover:bg-white/10"]:hover {
  background-color: rgba(0, 0, 0, 0.05) !important;
}

/* 버튼 텍스트 - gradient 버튼은 진한 텍스트 */
.light-mode .btn-gradient {
  color: rgb(15 23 42) !important;
}

/* Brand 색상 아이콘 */
.light-mode [class*="text-brandHot"],
.light-mode [class*="text-brandCold"] {
  filter: brightness(0.7);
}

/* 모달 배경 */
.light-mode .modal-overlay {
  background-color: rgba(0, 0, 0, 0.5) !important;
}

.light-mode .modal-content {
  background-color: rgb(255 255 255) !important;
  color: rgb(15 23 42) !important;
}

/* 흰색 텍스트 (gradient 버튼 등에서 사용) */
.light-mode .btn-gradient.text-white,
.light-mode [class*="bg-gradient"].text-white,
.light-mode .text-white {
  color: rgb(15 23 42) !important;
}

/* 로고 텍스트 */
.light-mode .logo-shimmer .text-slate-100,
.light-mode .logo-shimmer .text-slate-300 {
  color: rgb(15 23 42) !important;
}

.light-mode .logo-shimmer .text-xs {
  color: rgb(71 85 105) !important;
}

/* 호버 효과 - text-white 호버 */
.light-mode [class*="hover:text-white"]:hover {
  color: rgb(15 23 42) !important;
}

/* 코드 블록 */
.light-mode code {
  background-color: rgba(0, 0, 0, 0.05);
  color: rgb(51 65 85);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ========================================
   모달 스타일
   ======================================== */

/* 모달 오버레이 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal-overlay.show {
  opacity: 1;
}

/* 모달 컨테이너 */
.modal-container {
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.modal-overlay.show .modal-container {
  transform: scale(1);
}

/* 모달 콘텐츠 */
.modal-content {
  background: linear-gradient(to bottom, rgb(15 23 42), rgb(2 6 23));
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

/* 모달 헤더 */
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
}

/* 모달 닫기 버튼 */
.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgb(226 232 240);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: white;
  transform: rotate(90deg);
}

/* 모달 본문 */
.modal-body {
  padding: 2rem;
  max-height: calc(90vh - 120px);
  overflow-y: auto;
}

/* 커스텀 스크롤바 */
.modal-body::-webkit-scrollbar {
  width: 8px;
}

.modal-body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.modal-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* 모달 블록 */
.modal-block {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 1.25rem 1.5rem;
}

.modal-block-title {
  font-size: 1rem;
  font-weight: 600;
  color: rgb(248 250 252);
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
}

.modal-block-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.modal-block-list li {
  font-size: 0.875rem;
  line-height: 1.6;
  color: rgb(226 232 240);
  margin-bottom: 0.5rem;
  padding-left: 0;
}

.modal-block-list li:last-child {
  margin-bottom: 0;
}

/* 숨김 상태 */
.hidden {
  display: none !important;
}

/* Body 스크롤 방지 */
body.modal-open {
  overflow: hidden;
}

/* 라이트 모드 모달 */
.light-mode .modal-overlay {
  background-color: rgba(0, 0, 0, 0.6);
}

.light-mode .modal-content {
  background: linear-gradient(to bottom, rgb(248 250 252), rgb(241 245 249));
  border-color: rgba(0, 0, 0, 0.1);
}

.light-mode .modal-header {
  border-bottom-color: rgba(0, 0, 0, 0.1);
  background: rgba(0, 0, 0, 0.02);
}

.light-mode .modal-header h2 {
  color: rgb(15 23 42);
}

.light-mode .modal-close {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.1);
  color: rgb(51 65 85);
}

.light-mode .modal-close:hover {
  background: rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.2);
  color: rgb(15 23 42);
}

.light-mode .modal-body {
  color: rgb(30 41 59);
}

.light-mode .modal-body::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
}

.light-mode .modal-body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
}

.light-mode .modal-body::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.3);
}

.light-mode .modal-block {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
}

.light-mode .modal-block-title {
  color: rgb(15 23 42);
}

.light-mode .modal-block-list li {
  color: rgb(51 65 85);
}

/* 모바일 최적화 */
@media (max-width: 640px) {
  .modal-header {
    padding: 1.25rem 1.5rem;
  }

  .modal-header h2 {
    font-size: 1.25rem;
  }

  .modal-body {
    padding: 1.5rem;
  }

  .modal-block {
    padding: 1rem 1.25rem;
  }
}

/* ========================================
   헤더 & 네비게이션
   ======================================== */

/* 데스크탑 네비게이션 */
header nav {
  display: none;
}

@media (min-width: 1024px) {
  header nav:not(#mobile-menu) {
    display: flex !important;
  }
}

/* 모바일 메뉴 버튼 */
@media (min-width: 1024px) {
  #mobile-menu-button {
    display: none !important;
  }
}

/* ========================================
   헤더 & 로고
   ======================================== */

/* 로고 번쩍이는 효과 */
@keyframes logoShimmer {
  0%,
  100% {
    opacity: 1;
    text-shadow: 0 0 0 rgba(177, 51, 88, 0);
  }
  50% {
    opacity: 0.85;
    text-shadow: 0 0 20px rgba(177, 51, 88, 0.4),
      0 0 30px rgba(74, 97, 195, 0.3);
  }
}

.logo-shimmer span {
  animation: logoShimmer 3s ease-in-out infinite;
}

/* 로고 호버 효과 */
.logo-shimmer:hover span {
  animation: logoShimmer 1s ease-in-out infinite;
}

/* ========================================
   Font Awesome 아이콘 스타일
   ======================================== */

/* 아이콘 기본 스타일 */
.fas,
.far,
.fab {
  display: inline-block;
  vertical-align: middle;
}

/* 섹션 제목 아이콘 */
h2 .fas {
  opacity: 0.9;
}

/* 버튼 아이콘 */
button .fas,
a .fas {
  transition: transform 0.3s ease;
}

button:hover .fas,
a:hover .fas {
  transform: translateX(2px);
}

/* 체크 아이콘 애니메이션 */
.fa-check-circle {
  animation: checkPulse 3s ease-in-out infinite;
}

@keyframes checkPulse {
  0%,
  100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

/* 브랜드 컬러 아이콘 */
.text-brandHot {
  color: #b13358;
}

.text-brandCold {
  color: #4a61c3;
}

/* 라이트 모드 아이콘 색상 조정 */
.light-mode .text-brandHot {
  color: #d14b6f;
}

.light-mode .text-brandCold {
  color: #5b73d4;
}

.light-mode .text-green-400 {
  color: #22c55e !important;
}

/* 라이트 모드 로고 */
.light-mode .logo-shimmer span {
  color: rgb(15 23 42) !important;
}

.light-mode .logo-shimmer .text-slate-300 {
  color: rgb(100 116 139) !important;
}

@keyframes logoShimmerLight {
  0%,
  100% {
    opacity: 1;
    text-shadow: 0 0 0 rgba(177, 51, 88, 0);
  }
  50% {
    opacity: 0.8;
    text-shadow: 0 0 15px rgba(177, 51, 88, 0.3),
      0 0 25px rgba(74, 97, 195, 0.2);
  }
}

.light-mode .logo-shimmer span {
  animation: logoShimmerLight 3s ease-in-out infinite;
}

/* 부드러운 스크롤 */
html {
  scroll-behavior: smooth;
}

/* 기본 폰트 크기 및 렌더링 최적화 */
body {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  transition: background-color 0.3s ease, color 0.3s ease;
  letter-spacing: -0.02em;
}

@media (min-width: 1024px) {
  body {
    font-size: 17px;
  }
}

/* ========================================
   타이포그래피 개선
   ======================================== */

/* 제목 개선 */
h1 {
  line-height: 1.15;
  letter-spacing: -0.02em;
}

h2 {
  line-height: 1.25;
  letter-spacing: -0.015em;
}

h3 {
  line-height: 1.3;
  letter-spacing: -0.01em;
}

/* 본문 텍스트 가독성 개선 */
p {
  line-height: 1.7;
  letter-spacing: -0.02em;
}

/* 리스트 항목 자간 조정 */
li {
  letter-spacing: -0.02em;
}

/* Hero 카드 및 카드 텍스트 자간 최적화 */
.card-hover li,
.card-hover p,
.card-hover span {
  letter-spacing: -0.025em;
}

/* ========================================
   카드 및 컴포넌트 스타일
   ======================================== */

/* 카드 호버 효과 */
.card-hover {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

/* 반짝이는 효과를 위한 가상 요소 */
.card-hover::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s ease;
}

.card-hover:hover::before {
  left: 100%;
}

.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.5);
  border-color: rgba(255, 255, 255, 0.15);
}

/* 라이트 모드 shimmer 효과 */
.light-mode .card-hover::before {
  background: linear-gradient(
    90deg,
    transparent,
    rgba(177, 51, 88, 0.1),
    transparent
  );
}

.light-mode .card-hover:hover {
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.15);
  border-color: rgba(177, 51, 88, 0.2);
}

/* 그라데이션 버튼 호버 효과 개선 */
.btn-gradient {
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

/* 반짝이는 효과 */
.btn-gradient::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.6s ease;
}

.btn-gradient:hover::before {
  left: 100%;
}

/* 호버 시 밝아지는 효과 */
.btn-gradient::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0.1)
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn-gradient:hover::after {
  opacity: 1;
}

.btn-gradient:active {
  transform: scale(0.98);
}

/* 버튼 텍스트가 위에 오도록 */
.btn-gradient span,
.btn-gradient a {
  position: relative;
  z-index: 1;
}

/* ========================================
   폼 요소 스타일 개선
   ======================================== */

/* 입력 필드 포커스 효과 개선 */
input:focus,
select:focus,
textarea:focus {
  transition: all 0.2s ease;
}

/* 체크박스 및 라디오 버튼 스타일 */
input[type="checkbox"],
input[type="radio"] {
  cursor: pointer;
  transition: all 0.2s ease;
}

input[type="checkbox"]:checked,
input[type="radio"]:checked {
  background: linear-gradient(to right, #b13358, #4a61c3);
  border-color: transparent;
}

/* ========================================
   애니메이션
   ======================================== */

/* 페이드인 애니메이션 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.6s ease-out;
  animation-fill-mode: both;
}

/* 순차적 페이드인을 위한 delay 클래스들 */
.fade-in-1 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.1s;
  animation-fill-mode: both;
}

.fade-in-2 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.fade-in-3 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.3s;
  animation-fill-mode: both;
}

.fade-in-4 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.4s;
  animation-fill-mode: both;
}

.fade-in-5 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.5s;
  animation-fill-mode: both;
}

.fade-in-6 {
  animation: fadeIn 0.6s ease-out;
  animation-delay: 0.6s;
  animation-fill-mode: both;
}

/* 카드 그리드용 순차 애니메이션 */
.stagger-1 {
  animation: fadeIn 0.5s ease-out;
  animation-delay: 0.1s;
  animation-fill-mode: both;
}

.stagger-2 {
  animation: fadeIn 0.5s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.stagger-3 {
  animation: fadeIn 0.5s ease-out;
  animation-delay: 0.3s;
  animation-fill-mode: both;
}

.stagger-4 {
  animation: fadeIn 0.5s ease-out;
  animation-delay: 0.4s;
  animation-fill-mode: both;
}

.stagger-5 {
  animation: fadeIn 0.5s ease-out;
  animation-delay: 0.5s;
  animation-fill-mode: both;
}

/* 펄스 애니메이션 (상태 표시용) */
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.pulse {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* 글로우 펄스 애니메이션 (테두리) */
@keyframes glowPulse {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(177, 51, 88, 0.3), 0 0 40px rgba(74, 97, 195, 0.2);
  }
  50% {
    box-shadow: 0 0 30px rgba(177, 51, 88, 0.5), 0 0 60px rgba(74, 97, 195, 0.3);
  }
}

.glow-pulse {
  animation: glowPulse 3s ease-in-out infinite;
}

/* 반짝이는 테두리 애니메이션 */
@keyframes shimmerBorder {
  0% {
    border-color: rgba(255, 255, 255, 0.1);
  }
  50% {
    border-color: rgba(177, 51, 88, 0.4);
  }
  100% {
    border-color: rgba(255, 255, 255, 0.1);
  }
}

.shimmer-border {
  animation: shimmerBorder 2s ease-in-out infinite;
}

/* 페이드 글로우 (호버 시) */
@keyframes fadeGlow {
  from {
    box-shadow: 0 0 0 rgba(177, 51, 88, 0);
  }
  to {
    box-shadow: 0 0 30px rgba(177, 51, 88, 0.4), 0 0 50px rgba(74, 97, 195, 0.2);
  }
}

.hover-glow:hover {
  animation: fadeGlow 0.3s ease-out forwards;
}

/* ========================================
   유틸리티 클래스
   ======================================== */

/* 그라데이션 텍스트 */
.gradient-text {
  background: linear-gradient(to right, #b13358, #4a61c3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 글래스모피즘 효과 */
.glass {
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* 섹션 구분선 */
.section-divider {
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  margin: 4rem 0;
}

/* 섹션 구분선 - 얇고 심플하게 */
.section-divider-shimmer {
  position: relative;
  height: 1px;
  margin: 5rem 0;
  background: linear-gradient(
    to right,
    transparent,
    rgba(177, 51, 88, 0.2),
    rgba(74, 97, 195, 0.2),
    rgba(177, 51, 88, 0.2),
    transparent
  );

  /* Container 밖으로 확장 */
  margin-left: calc(-50vw + 50%);
  margin-right: calc(-50vw + 50%);
  width: 100vw;
}

/* 라이트 모드 구분선 */
.light-mode .section-divider-shimmer {
  background: linear-gradient(
    to right,
    transparent,
    rgba(177, 51, 88, 0.15),
    rgba(74, 97, 195, 0.15),
    rgba(177, 51, 88, 0.15),
    transparent
  );
}

/* 대안: 두꺼운 구분선 스타일 */
.section-divider-thick {
  position: relative;
  height: 3px;
  margin: 6rem 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(177, 51, 88, 0.3) 20%,
    rgba(74, 97, 195, 0.3) 80%,
    transparent
  );
  border-radius: 10px;
  overflow: hidden;
}

.section-divider-thick::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 30%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.8),
    transparent
  );
  animation: dividerShimmer 4s ease-in-out infinite;
  animation-delay: 1s;
}

/* Details 요소 애니메이션 */
details summary {
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

details[open] summary {
  margin-bottom: 0.75rem;
}

details summary::-webkit-details-marker {
  display: none;
}

/* ========================================
   모바일 최적화
   ======================================== */

/* 모바일에서 테마 토글 스위치 크기 조정 */
@media (max-width: 1024px) {
  .theme-toggle-switch {
    width: 52px;
    height: 26px;
  }

  .toggle-thumb {
    width: 18px;
    height: 18px;
    top: 3px;
    left: 3px;
  }

  .toggle-thumb svg {
    width: 11px;
    height: 11px;
  }

  .light-mode .toggle-thumb {
    left: 29px;
  }
}

/* 터치 디바이스 최적화 */
@media (hover: none) {
  .card-hover:hover {
    transform: none;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
  }

  .btn-gradient:hover::before {
    opacity: 0;
  }

  .theme-toggle-switch:hover .toggle-thumb {
    transform: none;
  }

  .theme-toggle-switch:active .toggle-thumb {
    transform: scale(0.95);
  }
}

/* 작은 화면에서 여백 조정 */
@media (max-width: 640px) {
  body {
    font-size: 15px;
  }

  h1 {
    font-size: 2rem !important;
  }

  h2 {
    font-size: 1.5rem !important;
  }

  /* 모바일에서 섹션 여백 감소 */
  .section-divider-shimmer {
    margin: 3rem 0;
  }

  .section-divider-thick {
    margin: 4rem 0;
  }
}

/* ========================================
   접근성 개선
   ======================================== */

/* 포커스 표시 개선 */
*:focus-visible {
  outline: 2px solid #4a61c3;
  outline-offset: 2px;
}

/* 프리퍼 모션 감소 설정 */
@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;
  }
}

/* ========================================
   라이트/다크 모드 토글 스위치
   ======================================== */

.theme-toggle-switch {
  position: relative;
  width: 56px;
  height: 28px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  padding: 0;
  background: transparent;
  flex-shrink: 0;
  overflow: visible;
}

.toggle-track {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 14px;
  background: rgba(100, 116, 139, 0.3);
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
  display: block;
  backdrop-filter: blur(10px);
}

.toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fbbaf6, #fda4c8);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.toggle-thumb svg {
  width: 14px;
  height: 14px;
  transition: opacity 0.2s ease, transform 0.3s ease;
  stroke-width: 2;
}

/* Dark 모드 (기본) - Sun 아이콘 보임 */
.toggle-thumb .sun-icon {
  opacity: 1;
  transform: rotate(0deg);
  position: absolute;
  color: rgb(15, 23, 42);
}

.toggle-thumb .moon-icon {
  opacity: 0;
  transform: rotate(90deg);
  position: absolute;
  color: rgb(248, 250, 252);
}

/* Light 모드 - Moon 아이콘 보임, 스위치 우측으로 */
.light-mode .toggle-thumb {
  left: 31px;
  background: linear-gradient(135deg, #4a61c3, #3b4fb8);
}

.light-mode .toggle-thumb .sun-icon {
  opacity: 0;
  transform: rotate(-90deg);
}

.light-mode .toggle-thumb .moon-icon {
  opacity: 1;
  transform: rotate(0deg);
  color: rgb(248, 250, 252);
}

.light-mode .toggle-track {
  background: rgba(226, 232, 240, 0.5);
  border-color: rgba(0, 0, 0, 0.2);
}

/* 호버 효과 */
.theme-toggle-switch:hover .toggle-track {
  background: rgba(100, 116, 139, 0.4);
  border-color: rgba(255, 255, 255, 0.4);
}

.light-mode .theme-toggle-switch:hover .toggle-track {
  background: rgba(203, 213, 225, 0.7);
  border-color: rgba(0, 0, 0, 0.3);
}

.theme-toggle-switch:hover .toggle-thumb {
  transform: scale(1.05);
}

/* ========================================
   라이트 모드 배경 그라데이션 조정
   ======================================== */

.light-mode .bg-blur-hot {
  opacity: 0.08 !important;
}

.light-mode .bg-blur-cold {
  opacity: 0.08 !important;
}

/* 그라데이션 텍스트는 라이트 모드에서도 유지 */
.gradient-text {
  background: linear-gradient(to right, #b13358, #4a61c3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
