/* HAA Lab Static Website Styles */

:root {
  --background: hsl(40, 20%, 98%);
  --foreground: hsl(25, 35%, 15%);
  --card: hsl(0, 0%, 100%);
  --card-foreground: hsl(25, 35%, 15%);
  --primary: hsl(30, 90%, 55%);
  --primary-foreground: hsl(0, 0%, 100%);
  --secondary: hsl(210, 80%, 60%);
  --secondary-foreground: hsl(0, 0%, 100%);
  --muted: hsl(40, 30%, 95%);
  --muted-foreground: hsl(25, 20%, 45%);
  --accent: hsl(45, 95%, 65%);
  --accent-foreground: hsl(25, 35%, 15%);
  --border: hsl(40, 25%, 88%);
  --input: hsl(40, 25%, 88%);
  --ring: hsl(30, 90%, 55%);
  --radius: 0.75rem;
  --shadow-warm: 0 10px 40px -10px hsla(30, 90%, 55%, 0.3);
  --shadow-glow: 0 0 60px hsla(45, 95%, 65%, 0.4);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
}

.font-outfit {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background-color: rgba(252, 249, 243, 0.8);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 1.5rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--foreground);
}

.nav-logo-icon {
  width: 40px;
  height: 40px;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  font-size: 1.125rem;
  transition: transform 0.3s;
}

.nav-logo:hover .nav-logo-icon {
  transform: scale(1.05);
}

.nav-logo-text {
  display: none;
}

@media (min-width: 640px) {
  .nav-logo-text {
    display: block;
  }
}

.nav-title {
  font-size: 1.125rem;
  font-weight: bold;
  font-family: 'Outfit', sans-serif;
}

.nav-subtitle {
  font-size: 0.75rem;
  color: var(--muted-foreground);
  margin-top: -0.25rem;
}

/* 新增這個樣式給你的 logo 圖片 */
.nav-logo-img {
  height: 40px;        /* 設定高度，建議 40px 到 50px 之間 */
  width: auto;         /* 寬度自動，保持圖片比例 */
  margin-right: 0.75rem; /* 圖片跟右邊文字的距離 */
  border-radius: 4px;  /* 如果想要圖片有一點圓角可以加這行，不需要可刪除 */
}
.nav-links {
  display: none;
  gap: 0.25rem;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }
}

.nav-link {
  padding: 0.5rem 1rem;
  text-decoration: none;
  color: var(--foreground);
  font-weight: 500;
  border-radius: 0.375rem;
  transition: all 0.3s;
}

.nav-link:hover {
  color: var(--primary);
  background-color: hsla(30, 90%, 55%, 0.05);
}

.nav-link.active {
  color: var(--primary);
  background-color: hsla(30, 90%, 55%, 0.1);
}

.mobile-menu-btn {
  display: block;
  padding: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
}

@media (min-width: 768px) {
  .mobile-menu-btn {
    display: none;
  }
}

.mobile-menu {
  display: none;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
}

.mobile-menu.open {
  display: block;
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  background-color: var(--card);
  margin-top: 5rem;
}

.footer-container {
  padding: 3rem 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

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

.footer-section h3 {
  font-weight: bold;
  font-size: 1.125rem;
  margin-bottom: 0.75rem;
  font-family: 'Outfit', sans-serif;
}

.footer-section p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  line-height: 1.625;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: var(--muted-foreground);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.3s;
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-social {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.footer-social-link {
  width: 40px;
  height: 40px;
  border-radius: 0.5rem;
  background-color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--foreground);
  transition: all 0.3s;
}

.footer-social-link:hover {
  background-color: var(--primary);
  color: white;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding-top: 2rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

/* Card */
.card {
  background-color: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 1.5rem;
  transition: all 0.3s;
}

.card:hover {
  box-shadow: var(--shadow-warm);
}

/* Button */
.btn {
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  display: inline-block;
  transition: all 0.3s;
  border: none;
  cursor: pointer;
}

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

.btn-primary:hover {
  opacity: 0.9;
  box-shadow: var(--shadow-warm);
}

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

.btn-outline:hover {
  background-color: hsla(30, 90%, 55%, 0.05);
}

/* Page Sections */
.page-section {
  padding-top: 8rem;
  padding-bottom: 4rem;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title {
  font-size: 2.5rem;
  font-weight: bold;
  margin-bottom: 1.5rem;
  font-family: 'Outfit', sans-serif;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 3rem;
  }
}

@media (min-width: 1024px) {
  .section-title {
    font-size: 3.75rem;
  }
}

.section-description {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  max-width: 48rem;
  margin: 0 auto;
  line-height: 1.625;
}

/* Hero Section */
.hero {
  padding-top: 8rem;
  padding-bottom: 5rem;
  background: linear-gradient(180deg, var(--background) 0%, var(--muted) 100%);
}

.hero-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  background-color: hsla(30, 90%, 55%, 0.1);
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 500;
  width: fit-content;
}

.hero-title {
  font-size: 3rem;
  font-weight: bold;
  line-height: 1.1;
  font-family: 'Outfit', sans-serif;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3.75rem;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 4.5rem;
  }
}

.hero-title-gradient {
  display: block;
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  line-height: 1.625;
  max-width: 42rem;
}

.hero-note {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  opacity: 0.8;
  font-style: italic;
  line-height: 1.625;
  max-width: 42rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-visual {
  position: relative;
}

.hero-image {
  aspect-ratio: 1;
  border-radius: 1.5rem;
  background: linear-gradient(135deg, hsla(30, 90%, 55%, 0.2), hsla(45, 95%, 65%, 0.2), hsla(210, 80%, 60%, 0.2));
  backdrop-filter: blur(4px);
  border: 1px solid hsla(30, 90%, 55%, 0.2);
  overflow: hidden;
  position: relative;
}

.hero-image-bg {
  position: absolute;
  inset: 0;
  /* 原本是 Unsplash 的連結，現在換成本地圖片 */
  background-image: url('logo.png');
  background-size: cover;
  background-position: center;
  opacity: 0.4;
}

.hero-image-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: white;
  z-index: 10;
}

.hero-image-text {
  font-size: 3.75rem;
  font-weight: bold;
  margin-bottom: 1rem;
  font-family: 'Outfit', sans-serif;
}

.hero-image-subtitle {
  font-size: 1.25rem;
}

/* Grid Layouts */
.grid-2 {
  display: grid;
  gap: 2rem;
}

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

.grid-3 {
  display: grid;
  gap: 1.5rem;
}

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

@media (min-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Icon Containers */
.icon-box {
  width: 64px;
  height: 64px;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  margin-bottom: 1.5rem;
  transition: transform 0.3s;
}

.icon-box-primary {
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.icon-box-secondary {
  background: linear-gradient(135deg, var(--secondary), var(--primary));
}

.card:hover .icon-box {
  transform: scale(1.1);
}

/* Utility Classes */
.text-center {
  text-align: center;
}

.mb-4 {
  margin-bottom: 1rem;
}

.mb-6 {
  margin-bottom: 1.5rem;
}

.mb-8 {
  margin-bottom: 2rem;
}

.mt-12 {
  margin-top: 3rem;
}

.mt-16 {
  margin-top: 4rem;
}

.space-y-4 > * + * {
  margin-top: 1rem;
}

.space-y-6 > * + * {
  margin-top: 1.5rem;
}

/* Publications Filters */
.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 3rem;
}

.filter-btn {
  padding: 0.5rem 1.5rem;
  border-radius: 9999px;
  border: 2px solid var(--border);
  background-color: transparent;
  color: var(--foreground);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}

.filter-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

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

.publication-year {
  font-size: 1.875rem;
  font-weight: bold;
  margin-bottom: 1.5rem;
  font-family: 'Outfit', sans-serif;
  color: var(--primary);
}

.publication-card {
  padding: 1.5rem;
  margin-bottom: 1rem;
}

.publication-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  font-family: 'Outfit', sans-serif;
}

.publication-authors {
  color: var(--muted-foreground);
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.publication-venue {
  color: var(--muted-foreground);
  margin-bottom: 0.75rem;
  font-style: italic;
  font-size: 0.875rem;
}

.publication-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.badge-conference {
  background-color: hsla(30, 90%, 55%, 0.2);
  color: var(--primary);
}

.badge-journal {
  background-color: hsla(210, 80%, 60%, 0.2);
  color: var(--secondary);
}

.badge-workshop {
  background-color: hsla(45, 95%, 65%, 0.2);
  color: var(--accent-foreground);
}

.publication-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.publication-link:hover {
  text-decoration: underline;
}

/* Form Styles */
.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid var(--input);
  background-color: var(--background);
  font-size: 1rem;
  transition: all 0.3s;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px hsla(30, 90%, 55%, 0.1);
}

textarea.form-input {
  resize: vertical;
  min-height: 150px;
}

/* Event Cards */
.event-card {
  padding: 1.5rem;
}

@media (min-width: 768px) {
  .event-card {
    padding: 2rem;
  }
}

.event-date-badge {
  width: 80px;
  height: 80px;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
  transition: transform 0.3s;
}

.event-card:hover .event-date-badge {
  transform: scale(1.05);
}

.event-date-day {
  font-size: 1.5rem;
  font-weight: bold;
}

.event-date-month {
  font-size: 0.75rem;
  text-transform: uppercase;
}

.event-type-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: capitalize;
}

/* Responsive utilities */
@media (max-width: 767px) {
  .hide-mobile {
    display: none;
  }
}

@media (min-width: 768px) {
  .show-mobile {
    display: none;
  }
}

/* SVG Icons */
svg {
  width: 1.5rem;
  height: 1.5rem;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
