/* Global Styles */
:root {
  --primary-color: #6f4e37; /* Coffee brown */
  --secondary-color: #f5f5f5; /* Off-white */
  --accent-color: #a1887f; /* Light brown */
  --text-color: #333;
  --light-text: #fff;
  --header-font: 'Playfair Display', serif;
  --body-font: 'Open Sans', sans-serif;
}

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

body {
  font-family: var(--body-font);
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--secondary-color);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--header-font);
  margin-bottom: 1rem;
  color: var(--primary-color);
}

h1 {
  font-size: 2.5rem;
  margin-top: 2rem;
}

h2 {
  font-size: 2rem;
  margin-top: 1.5rem;
}

h3 {
  font-size: 1.5rem;
  margin-top: 1.2rem;
}

p {
  margin-bottom: 1.2rem;
}

/* Header */
header {
  background-color: var(--primary-color);
  color: var(--light-text);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--header-font);
  font-size: 1.8rem;
  font-weight: bold;
}

/* Navigation */
nav ul {
  display: flex;
  list-style: none;
}

nav ul li {
  margin-left: 1.5rem;
}

nav ul li a {
  color: var(--light-text);
  text-decoration: none;
  transition: color 0.3s ease;
}

nav ul li a:hover {
  color: var(--accent-color);
}

/* Hero Section */
.hero {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../images/scene1_milk_composition.png');
  background-size: cover;
  background-position: center;
  height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--light-text);
  margin-bottom: 2rem;
}

.hero-content {
  max-width: 800px;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  color: var(--light-text);
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
}

/* Sections */
section {
  padding: 3rem 0;
}

.section-title {
  text-align: center;
  margin-bottom: 2rem;
}

/* Animation Gallery */
.animation-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.animation-item {
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.animation-item:hover {
  transform: translateY(-5px);
}

.animation-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.animation-content {
  padding: 1.5rem;
}

.animation-content h3 {
  margin-top: 0;
}

/* Overview Image */
.overview-image {
  width: 100%;
  max-width: 1000px;
  margin: 2rem auto;
  display: block;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Technical Content */
.technical-content {
  background-color: #fff;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: 2rem;
}

/* Footer */
footer {
  background-color: var(--primary-color);
  color: var(--light-text);
  padding: 2rem 0;
  text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
  }
  
  nav ul {
    margin-top: 1rem;
  }
  
  nav ul li {
    margin-left: 1rem;
    margin-right: 1rem;
  }
  
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .animation-gallery {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  nav ul {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .animation-gallery {
    grid-template-columns: 1fr;
  }
}

/* Animation Viewer */
.animation-viewer {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 2rem auto;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.animation-slide {
  display: none;
  text-align: center;
  padding: 2rem;
}

.animation-slide.active {
  display: block;
}

.animation-slide img {
  max-width: 100%;
  height: auto;
  margin-bottom: 1rem;
}

.animation-controls {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.animation-controls button {
  background-color: var(--primary-color);
  color: var(--light-text);
  border: none;
  padding: 0.5rem 1rem;
  margin: 0 0.5rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.animation-controls button:hover {
  background-color: var(--accent-color);
}

.animation-indicators {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.indicator {
  width: 12px;
  height: 12px;
  background-color: #ccc;
  border-radius: 50%;
  margin: 0 5px;
  cursor: pointer;
}

.indicator.active {
  background-color: var(--primary-color);
}
