/* 어르신을 위한 부드러운 색상 테마 */
:root {
  --background: hsl(0, 0%, 98%);
  --foreground: hsl(210, 20%, 20%);
  --card: hsl(0, 0%, 100%);
  --card-foreground: hsl(210, 20%, 20%);
  --primary: hsl(210, 50%, 40%);
  --primary-foreground: hsl(0, 0%, 98%);
  --secondary: hsl(210, 20%, 90%);
  --secondary-foreground: hsl(210, 20%, 20%);
  --muted: hsl(210, 20%, 95%);
  --muted-foreground: hsl(210, 20%, 50%);
  --accent: hsl(210, 30%, 85%);
  --accent-foreground: hsl(210, 20%, 20%);
  --border: hsl(210, 20%, 85%);
  --radius: 1rem;
  --soft-blue: hsl(210, 30%, 95%);
  --soft-green: hsl(120, 30%, 95%);
  --soft: hsl(210, 20%, 40%);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 20px; /* 기본 폰트 크기를 크게 */
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.7;
  color: var(--foreground);
  background: var(--background);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* 제목 크기들 - 부드러운 폰트 웨이트 */
h1 { font-size: 2.5rem; font-weight: 700; }
h2 { font-size: 2rem; font-weight: 600; }
h3 { font-size: 1.5rem; font-weight: 600; }
h4 { font-size: 1.25rem; font-weight: 500; }

/* Header */
.header {
  background: white;
  border-bottom: 4px solid var(--primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem;
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.header-icon {
  font-size: 2.5rem;
  color: var(--primary);
}

.header h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--foreground);
}

/* Navigation */
.navigation {
  background: white;
  border-bottom: 2px solid hsl(210, 20%, 95%);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.nav-items {
  display: flex;
  justify-content: center;
  gap: 0.25rem;
}

.nav-item {
  text-decoration: none;
  font-size: 1.25rem;
  font-weight: 500;
  padding: 1rem 2rem;
  display: block;
  transition: all 0.2s ease;
  color: hsl(210, 20%, 40%);
}

.nav-item:hover {
  color: var(--primary);
  background: hsl(210, 20%, 98%);
}

.nav-item.active {
  color: var(--primary);
  background: var(--soft-blue);
  border-bottom: 4px solid var(--primary);
}

/* Main Content */
.main-content {
  flex: 1;
}

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

/* Hero Section */
.hero-section {
  text-align: center;
  margin-bottom: 3rem;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.hero-description {
  font-size: 1.5rem;
  color: var(--soft);
}

/* Guides Grid */
.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.guide-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
  overflow: hidden;
}

.guide-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.guide-header {
  padding: 1.5rem 1.5rem 0 1.5rem;
}

.guide-image {
  width: 100%;
  height: 12rem;
  object-fit: cover;
  border-radius: calc(var(--radius) - 4px);
  margin-bottom: 1rem;
}

.guide-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.guide-content {
  padding: 0 1.5rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.guide-description {
  font-size: 1.25rem;
  color: var(--soft);
}

.guide-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 4rem;
  padding: 1rem 1.5rem;
  background: var(--primary);
  color: var(--primary-foreground);
  text-decoration: none;
  font-size: 1.25rem;
  font-weight: 500;
  border-radius: var(--radius);
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.guide-button:hover {
  background: hsl(210, 50%, 35%);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* Tips Section */
.tips-section {
  background: var(--soft-green);
  padding: 2rem;
  border-radius: var(--radius);
}

.tips-title {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 2rem;
  text-align: center;
}

.tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.tip-column {
  padding: 0 1rem;
}

.tip-heading {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.tip-list {
  list-style: none;
  font-size: 1.25rem;
}

.tip-list li {
  margin-bottom: 0.75rem;
}

/* Footer */
.footer {
  background: var(--muted);
  padding: 2rem 0;
  margin-top: auto;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  text-align: center;
}

/* Button Styles */
button, .button {
  min-height: 3.5rem;
  font-size: 1.1rem;
  font-weight: 500;
  border-radius: var(--radius);
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
}

button:hover, .button:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.btn-secondary {
  background: var(--secondary);
  color: var(--secondary-foreground);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--border);
  color: var(--foreground);
}

/* Focus Styles - 접근성 */
button:focus-visible,
a:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* 모바일 최적화 */
@media (max-width: 768px) {
  html {
    font-size: 18px; /* 모바일에서 폰트 약간 작게 */
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.5rem; }

  .container {
    padding: 1.5rem;
  }

  .header-container {
    padding: 1rem;
  }

  .nav-items {
    flex-wrap: wrap;
    gap: 0.25rem;
  }

  .nav-item {
    font-size: 1rem;
    padding: 0.75rem 1rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-description {
    font-size: 1.25rem;
  }

  .guides-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .tips-grid {
    grid-template-columns: 1fr;
  }

  button, .button {
    min-height: 3rem;
    font-size: 1rem;
    padding: 0.75rem 1rem;
  }

  .guide-button {
    min-height: 3.5rem;
    font-size: 1.125rem;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 16px; /* 작은 화면에서 더 작게 */
  }

  .container {
    padding: 1rem;
  }

  .header-container {
    padding: 0.75rem;
  }

  .header h1 {
    font-size: 1.25rem;
  }

  .nav-item {
    font-size: 0.9rem;
    padding: 0.5rem 0.75rem;
  }

  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }

  .hero-title {
    font-size: 1.75rem;
  }

  .guide-image {
    height: 10rem;
  }
}