/* ============================================
   棲心尺度 Scale of Soul - 全站樣式表
   ============================================
   設計語彙：極簡主義、構造美學、光影連動
   核心色系：
   - 礦石深灰 (#1C1C1C)：主視覺線條與文字
   - 石灰白 (#FDFDFD)：全站背景
   - 古銅拉絲 (#B8860B)：強調色與按鈕
   ============================================ */

/* ========== 重置與基礎 ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #FDFDFD;
  color: #1C1C1C;
  line-height: 1.6;
  letter-spacing: 0.5px;
}

/* ========== 字型系統 ========== */
/* 標題使用襯線體 (Serif) */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Georgia', 'Garamond', serif;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1.5rem;
  color: #1C1C1C;
}

h1 {
  font-size: 3.5rem;
  letter-spacing: -1px;
}

h2 {
  font-size: 2.5rem;
  letter-spacing: -0.5px;
}

h3 {
  font-size: 1.8rem;
}

h4 {
  font-size: 1.4rem;
}

h5 {
  font-size: 1.1rem;
}

h6 {
  font-size: 1rem;
}

p {
  font-family: 'Segoe UI', sans-serif;
  font-size: 1rem;
  margin-bottom: 1rem;
  color: #1C1C1C;
}

a {
  color: #B8860B;
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: #1C1C1C;
  text-decoration: underline;
}

/* ========== 間距系統 ========== */
.section {
  padding: 150px 0;
}

.section-sm {
  padding: 80px 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

@media (max-width: 768px) {
  .container {
    padding: 0 20px;
  }
  
  h1 {
    font-size: 2.5rem;
  }
  
  h2 {
    font-size: 1.8rem;
  }
  
  .section {
    padding: 80px 0;
  }
}

/* ========== 按鈕樣式 ========== */
.btn {
  display: inline-block;
  padding: 12px 32px;
  background-color: transparent;
  color: #B8860B;
  border: 2px solid #B8860B;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
  letter-spacing: 1px;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background-color: #B8860B;
  z-index: -1;
  transition: left 0.4s ease;
}

.btn:hover {
  color: #FDFDFD;
  border-color: #B8860B;
}

.btn:hover::before {
  left: 0;
}

.btn-primary {
  background-color: #B8860B;
  color: #FDFDFD;
  border-color: #B8860B;
}

.btn-primary::before {
  background-color: #1C1C1C;
}

.btn-primary:hover {
  color: #FDFDFD;
  border-color: #1C1C1C;
}

/* ========== 導航列 ========== */
nav {
  background-color: #FDFDFD;
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid #E8E8E8;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

.navbar-brand {
  font-family: 'Georgia', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1C1C1C;
  text-decoration: none;
}

.navbar-brand small {
  display: block;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 2px;
  margin-top: 2px;
  color: #B8860B;
}

.navbar-menu {
  display: flex;
  list-style: none;
  gap: 40px;
}

.navbar-menu a {
  color: #1C1C1C;
  font-weight: 500;
  position: relative;
  padding-bottom: 5px;
}

.navbar-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #B8860B;
  transition: width 0.3s ease;
}

.navbar-menu a:hover::after {
  width: 100%;
}

.navbar-menu a.active {
  color: #B8860B;
}

.navbar-menu a.active::after {
  width: 100%;
}

@media (max-width: 768px) {
  .navbar {
    flex-direction: column;
    gap: 20px;
  }
  
  .navbar-menu {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }
}

/* ========== Hero Section ========== */
.hero {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-color: #FDFDFD;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.8;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  color: #1C1C1C;
  max-width: 800px;
  padding: 0 40px;
}

.hero-content h1 {
  font-size: 4rem;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.hero-content .tagline {
  font-size: 1.3rem;
  font-style: italic;
  margin-bottom: 2rem;
  color: #B8860B;
  font-weight: 500;
}

.hero-content p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  line-height: 1.8;
}

/* ========== 網格佈局 ========== */
.grid {
  display: grid;
  gap: 40px;
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* ========== 卡片樣式 ========== */
.card {
  background-color: #FDFDFD;
  border: 1px solid #E8E8E8;
  padding: 30px;
  transition: all 0.3s ease;
  position: relative;
}

.card:hover {
  box-shadow: 0 10px 40px rgba(28, 28, 28, 0.1);
  border-color: #B8860B;
}

.card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  margin-bottom: 20px;
}

.card-title {
  font-family: 'Georgia', serif;
  font-size: 1.3rem;
  margin-bottom: 10px;
  color: #1C1C1C;
}

.card-text {
  color: #666;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ========== 圖片懸停效果 ========== */
.image-hover {
  position: relative;
  overflow: hidden;
}

.image-hover img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.4s ease;
}

.image-hover:hover img {
  transform: scale(1.05);
}

.image-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(28, 28, 28, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 10;
}

.image-hover:hover .image-overlay {
  opacity: 1;
}

.overlay-text {
  color: #FDFDFD;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 500;
}

/* ========== 滾動揭示效果 ========== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ========== 表單樣式 ========== */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #1C1C1C;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px;
  border: 1px solid #E8E8E8;
  background-color: #FDFDFD;
  color: #1C1C1C;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: #B8860B;
  box-shadow: 0 0 0 3px rgba(184, 134, 11, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* ========== 頁尾 ========== */
footer {
  background-color: #1C1C1C;
  color: #FDFDFD;
  padding: 60px 0 20px;
  margin-top: 100px;
}

footer p {
  color: #FDFDFD;
  margin-bottom: 0.5rem;
}

footer a {
  color: #B8860B;
}

footer a:hover {
  color: #FDFDFD;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 40px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 40px;
}

.footer-section h3 {
  color: #B8860B;
  margin-bottom: 15px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #333;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 40px;
}

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

/* ========== 時間軸樣式 ========== */
.timeline {
  position: relative;
  padding: 20px 0;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 100%;
  background-color: #B8860B;
}

.timeline-item {
  margin-bottom: 50px;
  position: relative;
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-left: 0;
  margin-right: 52%;
  text-align: right;
}

.timeline-item:nth-child(even) .timeline-content {
  margin-left: 52%;
  margin-right: 0;
  text-align: left;
}

.timeline-dot {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  width: 16px;
  height: 16px;
  background-color: #B8860B;
  border: 3px solid #FDFDFD;
  border-radius: 50%;
  z-index: 10;
}

.timeline-content {
  background-color: #F5F5F5;
  padding: 20px;
  border-left: 2px solid #B8860B;
}

.timeline-content h4 {
  color: #B8860B;
  margin-bottom: 10px;
}

@media (max-width: 768px) {
  .timeline::before {
    left: 20px;
  }
  
  .timeline-item:nth-child(odd) .timeline-content,
  .timeline-item:nth-child(even) .timeline-content {
    margin-left: 60px;
    margin-right: 0;
    text-align: left;
  }
  
  .timeline-dot {
    left: 20px;
  }
}

/* ========== 動畫 ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-fade-in-up {
  animation: fadeInUp 0.8s ease forwards;
}

.animate-slide-in-left {
  animation: slideInLeft 0.8s ease forwards;
}

.animate-slide-in-right {
  animation: slideInRight 0.8s ease forwards;
}

/* ========== 響應式設計 ========== */
@media (max-width: 1024px) {
  .container {
    max-width: 960px;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 16px;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  .section {
    padding: 60px 0;
  }
  
  .hero {
    height: auto;
    min-height: 60vh;
    padding: 40px 0;
  }
  
  .hero-content h1 {
    font-size: 2rem;
  }
}

/* ========== 工具類 ========== */
.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

.hidden {
  display: none;
}

.visible {
  display: block;
}
